From ce41fb71b4e1aac0b7e7b288fc363b9f77509e5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20W=C3=A4ckerlin?= Date: Thu, 9 Sep 2004 20:09:06 +0000 Subject: [PATCH] library versioning now works how i want it --- ChangeLog | 2 ++ configure.in | 30 +++++++++++++++++++++++------- makefile.am | 15 +++++++++------ mrw-c++-devel.spec.in | 11 +++++++---- mrw-c++.spec.in | 5 ++++- mrw/doxyfile.in | 5 ++++- mrw/makefile.am | 20 +++++++++++--------- mrw/mrw.hpp.in | 8 ++++---- mrw/version.cpp.in | 5 ++++- 9 files changed, 68 insertions(+), 33 deletions(-) diff --git a/ChangeLog b/ChangeLog index 08f3b00..a9ee0cf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,5 @@ +* Tue Sep 9 2004 Marc Wäckerlin - mrw-c++-0.94.0 (mrw) + - library version is now how I want it (equal to package) * Tue Aug 31 2004 Marc Wäckerlin - mrw-c++-0.93 (mrw) - test failed on Solaris (without stack trace) -> no -lbfd for --disable-stacktrace! diff --git a/configure.in b/configure.in index da50833..28d1068 100644 --- a/configure.in +++ b/configure.in @@ -9,6 +9,9 @@ ## @license LGPL, see file COPYING ## ## $Log$ +## Revision 1.9 2004/09/09 20:09:06 marc +## library versioning now works how i want it +## ## Revision 1.8 2004/08/31 16:24:55 marc ## no "if [];" but "if test;"! ## @@ -32,10 +35,26 @@ # init AC_INIT([mrw/mrw.hpp.in]) PACKAGENAME=mrw-c++ -MAJOR=0 -MINOR=93 -SUPPORT= -AM_INIT_AUTOMAKE(@PACKAGENAME@, @MAJOR@.@MINOR@, [marc@waeckerlin.org]) +m4_define(major, 1) +m4_define(minor, 94) +m4_define(least, 0) +AM_INIT_AUTOMAKE(@PACKAGENAME@, @MAJOR@.@MINOR@.@LEAST@, [marc@waeckerlin.org]) + +# copy M4 to shell +MAJOR=major +MINOR=minor +LEAST=least +AC_SUBST(MAJOR) +AC_SUBST(MINOR) +AC_SUBST(LEAST) + +# libtool versioning +LIB_MAJOR=m4_eval(major+minor) +AC_SUBST(LIB_MAJOR) +LIB_MINOR=least +AC_SUBST(LIB_MINOR) +LIB_LEAST=minor +AC_SUBST(LIB_LEAST) # macros README=README @@ -96,9 +115,6 @@ fi # export macros AC_SUBST(HAVE_DOT) -AC_SUBST(MAJOR) -AC_SUBST(MINOR) -AC_SUBST(SUPPORT) AC_SUBST(PACKAGENAME) AC_SUBST(AM_CXXFLAGS) AC_SUBST(AM_CPPFLAGS) diff --git a/makefile.am b/makefile.am index ce9c3dd..7a3123a 100644 --- a/makefile.am +++ b/makefile.am @@ -9,6 +9,9 @@ ## @license LGPL, see file COPYING ## ## $Log$ +## Revision 1.8 2004/09/09 20:09:06 marc +## library versioning now works how i want it +## ## Revision 1.7 2004/08/31 16:22:29 marc ## webserver now depends on tag and rpm ## added .PHONY @@ -38,8 +41,8 @@ infosdir = ${pkgdatadir} infos_DATA = AUTHORS NEWS README COPYING INSTALL ChangeLog \ @PACKAGENAME@.spec @PACKAGENAME@-devel.spec -RPMS = /usr/src/packages/RPMS/i586/@PACKAGENAME@-@MAJOR@.@MINOR@-1.i586.rpm \ - /usr/src/packages/RPMS/i586/@PACKAGENAME@-devel-@MAJOR@.@MINOR@-1.i586.rpm +RPMS = /usr/src/packages/RPMS/i586/@PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@-1.i586.rpm \ + /usr/src/packages/RPMS/i586/@PACKAGENAME@-devel-@MAJOR@.@MINOR@.@LEAST@-1.i586.rpm .PHONY: release tag rpm webserver distclean-local @@ -47,10 +50,10 @@ release: rpm tag webserver tag: cvs ci -R . - cvs tag -FR REL_@PACKAGENAME@-@MAJOR@-@MINOR@ . + cvs tag -FR REL_@PACKAGENAME@-@MAJOR@-@MINOR@-@LEAST@ . rpm: dist - cp @PACKAGENAME@-@MAJOR@.@MINOR@.tar.gz /usr/src/packages/SOURCES/ + cp @PACKAGENAME@-@MAJOR@.@MINOR@-@LEAST@.tar.gz /usr/src/packages/SOURCES/ rpmbuild -bb --clean @PACKAGENAME@.spec rpmbuild -bb --clean @PACKAGENAME@-devel.spec @@ -58,8 +61,8 @@ webserver: check tag all check dist rpm ssh root@waeckerlin.org bash -c \ '"rm -r /home/marc/mrw-c++; mkdir -p /home/marc/mrw-c++"' scp mrw/doc/html/* \ - mrw/doc/latex/@PACKAGENAME@-@MAJOR@.@MINOR@.pdf \ - @PACKAGENAME@-@MAJOR@.@MINOR@.tar.gz \ + mrw/doc/latex/@PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@.pdf \ + @PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@.tar.gz \ ${RPMS} \ root@waeckerlin.org:/home/marc/mrw-c++/ diff --git a/mrw-c++-devel.spec.in b/mrw-c++-devel.spec.in index d672606..eb34196 100644 --- a/mrw-c++-devel.spec.in +++ b/mrw-c++-devel.spec.in @@ -9,6 +9,9 @@ ## @license LGPL, see file COPYING ## ## $Log$ +## Revision 1.3 2004/09/09 20:09:06 marc +## library versioning now works how i want it +## ## Revision 1.2 2004/08/28 16:21:07 marc ## mrw-c++-0.92 (mrw) ## - new file: version.cpp @@ -26,19 +29,19 @@ # rpmbuild -bb --clean @PACKAGENAME@.spec Summary: MRW's C++ Class Library, facilities for ease and quality Name: @PACKAGENAME@-devel -Version: @MAJOR@.@MINOR@ +Version: @MAJOR@.@MINOR@.@LEAST@ Release: 1 License: LGPL Group: Development/Libraries/C++ URL: http://marc.waeckerlin.org/mrw-c++/index.html -Source0: @PACKAGENAME@-@MAJOR@.@MINOR@.tar.gz +Source0: @PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@.tar.gz BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot Prefix: /usr Requires: gcc-c++ >= 3.0 Requires: binutils -Requires: @PACKAGENAME@ = @MAJOR@.@MINOR@ +Requires: @PACKAGENAME@ = @MAJOR@.@MINOR@.@LEAST@ %description @README@ @@ -46,7 +49,7 @@ Requires: @PACKAGENAME@ = @MAJOR@.@MINOR@ This Package contains all files required for developement. %prep -%setup -q -n @PACKAGENAME@-@MAJOR@.@MINOR@ +%setup -q -n @PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@ ./configure --prefix=$RPM_BUILD_ROOT/usr %build diff --git a/mrw-c++.spec.in b/mrw-c++.spec.in index 89ce497..058982c 100644 --- a/mrw-c++.spec.in +++ b/mrw-c++.spec.in @@ -9,6 +9,9 @@ ## @license LGPL, see file COPYING ## ## $Log$ +## Revision 1.3 2004/09/09 20:09:06 marc +## library versioning now works how i want it +## ## Revision 1.2 2004/08/28 16:21:07 marc ## mrw-c++-0.92 (mrw) ## - new file: version.cpp @@ -26,7 +29,7 @@ # rpmbuild -bb --clean @PACKAGENAME@.spec Summary: MRW's C++ Class Library, facilities for ease and quality Name: @PACKAGENAME@ -Version: @MAJOR@.@MINOR@ +Version: @MAJOR@.@MINOR@.@LEAST@ Release: 1 License: LGPL Group: Development/Libraries/C++ diff --git a/mrw/doxyfile.in b/mrw/doxyfile.in index ab90d80..ff3172a 100644 --- a/mrw/doxyfile.in +++ b/mrw/doxyfile.in @@ -9,6 +9,9 @@ ## @license LGPL, see file COPYING ## ## $Log$ +## Revision 1.9 2004/09/09 20:09:06 marc +## library versioning now works how i want it +## ## Revision 1.8 2004/08/29 19:20:05 marc ## "Version" text in PROJECT_NUMBER ## @@ -54,7 +57,7 @@ PROJECT_NAME = "MRW C++ Library" # This could be handy for archiving the generated documentation or # if some version control system is used. -PROJECT_NUMBER = "Version @MAJOR@.@MINOR@@SUPPORT@" +PROJECT_NUMBER = "Version @MAJOR@.@MINOR@.@LEAST@" # The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) # base path where the generated documentation will be put. diff --git a/mrw/makefile.am b/mrw/makefile.am index 5f4f80a..c21fe90 100644 --- a/mrw/makefile.am +++ b/mrw/makefile.am @@ -9,6 +9,9 @@ ## @license LGPL, see file COPYING ## ## $Log$ +## Revision 1.8 2004/09/09 20:09:06 marc +## library versioning now works how i want it +## ## Revision 1.7 2004/08/31 16:23:57 marc ## added .PHONY ## @@ -32,13 +35,13 @@ if HAVE_STACKTRACE AM_CPPFLAGS += -DHAVE_STACKTRACE endif -CLEANFILES = doxygen.error +CLEANFILES = doxygen.errors examplesdir = ${pkgdatadir}/examples examples_DATA = examples/* htmldir = ${pkgdatadir}/doc/html html_DATA = doc/html/index.html doc/html/* pdfdir = ${pkgdatadir}/doc/pdf -pdf_DATA = doc/latex/@PACKAGENAME@-@MAJOR@.@MINOR@.pdf +pdf_DATA = doc/latex/@PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@.pdf EXTRA_DIST = test.dat ${examples_DATA} ${html_DATA} ${pdf_DATA} lib_LTLIBRARIES = libmrw.la @@ -57,16 +60,15 @@ libmrw_la_SOURCES = mrw.hpp \ if HAVE_STACKTRACE libmrw_la_SOURCES += stacktrace.hpp stacktrace.cpp endif -libmrw_la_LDFLAGS = -version-info @MAJOR@:@MINOR@ - +libmrw_la_LDFLAGS = -version-info @LIB_MAJOR@:@LIB_MINOR@:@LIB_LEAST@ if HAVE_STACKTRACE libmrwexcstderr_la_SOURCES = autostacktracestderr.cpp version.cpp - libmrwexcstderr_la_LDFLAGS = -version-info @MAJOR@:@MINOR@ + libmrwexcstderr_la_LDFLAGS = -version-info @LIB_MAJOR@:@LIB_MINOR@:@LIB_LEAST@ libmrwexcstderr_la_LIBADD = -lmrw if HAVE_LOG4CXX libmrwexclog4cxx_la_SOURCES = autostacktracelog4cxx.cpp version.cpp - libmrwexclog4cxx_la_LDFLAGS = -version-info @MAJOR@:@MINOR@ + libmrwexclog4cxx_la_LDFLAGS = -version-info @LIB_MAJOR@:@LIB_MINOR@:@LIB_LEAST@ libmrwexclog4cxx_la_LIBADD = -lmrw endif endif @@ -105,12 +107,12 @@ TESTS = ${check_PROGRAMS} .PHONY: doc clean-local distclean-local deps = ../COPYING ../README ../INSTALL ../NEWS ../ChangeLog -doc: doc/html/index.html doc/latex/@PACKAGENAME@-@MAJOR@.@MINOR@.pdf +doc: doc/html/index.html doc/latex/@PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@.pdf doc/html/index.html: doxyfile *.[ch]pp ${deps} doxygen doxyfile -doc/latex/@PACKAGENAME@-@MAJOR@.@MINOR@.pdf: doxyfile *.[ch]pp ${deps} +doc/latex/@PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@.pdf: doxyfile *.[ch]pp ${deps} cd doc/latex && make && \ - mv refman.pdf @PACKAGENAME@-@MAJOR@.@MINOR@.pdf + mv refman.pdf @PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@.pdf clean-local: - rm doxygen.err libmrw.doxytag distclean-local: diff --git a/mrw/mrw.hpp.in b/mrw/mrw.hpp.in index 6fedbab..ac7e903 100644 --- a/mrw/mrw.hpp.in +++ b/mrw/mrw.hpp.in @@ -12,13 +12,13 @@ Download this version from here: - Source TAR-Ball (./configure && make all install): - - http://marc.waeckerlin.org/mrw-c++/mrw-c++-@MAJOR@.@MINOR@.tar.gz + - http://marc.waeckerlin.org/mrw-c++/mrw-c++-@MAJOR@.@MINOR@.@LEAST@.tar.gz - RPM Packages (built on i586/SuSE): - - http://marc.waeckerlin.org/mrw-c++/mrw-c++-@MAJOR@.@MINOR@-1.i586.rpm - - http://marc.waeckerlin.org/mrw-c++/mrw-c++-devel-@MAJOR@.@MINOR@-1.i586.rpm + - http://marc.waeckerlin.org/mrw-c++/mrw-c++-@MAJOR@.@MINOR@.@LEAST@-1.i586.rpm + - http://marc.waeckerlin.org/mrw-c++/mrw-c++-devel-@MAJOR@.@MINOR@.@LEAST@-1.i586.rpm Download this documentation in PDF: - - http://marc.waeckerlin.org/mrw-c++/mrw-c++-@MAJOR@.@MINOR@.pdf + - http://marc.waeckerlin.org/mrw-c++/mrw-c++-@MAJOR@.@MINOR@.@LEAST@.pdf The homepage is on: - http://marc.waeckerlin.org/mrw-c++/index.html diff --git a/mrw/version.cpp.in b/mrw/version.cpp.in index d485f48..5090337 100644 --- a/mrw/version.cpp.in +++ b/mrw/version.cpp.in @@ -9,6 +9,9 @@ @license LGPL, see file COPYING $Log$ + Revision 1.2 2004/09/09 20:09:06 marc + library versioning now works how i want it + Revision 1.1 2004/08/28 16:13:42 marc mrw-c++-0.92 (mrw) - new file: version.cpp @@ -27,5 +30,5 @@ #include namespace mrw { - const std::string version("@(#)@PACKAGENAME@-@MAJOR@.@MINOR@@SUPPORT@"); + const std::string version("@(#)@PACKAGENAME@-@MAJOR@.@MINOR@.@LEAST@"); }