]> sigrok.org Git - libsigrokdecode.git/commitdiff
srd: SRD_PACKAGE_VERSION_* for consistency.
authorUwe Hermann <redacted>
Sat, 31 Mar 2012 09:31:14 +0000 (11:31 +0200)
committerUwe Hermann <redacted>
Sat, 31 Mar 2012 09:35:47 +0000 (11:35 +0200)
No need to use the LIBSIGROKDECODE_ prefix here when we use SRD_ everywhere
else. Also, better distinction between package version and lib version.

Makefile.am
configure.ac
sigrokdecode.h.in

index fd5e0046d79664d6301a45dbd734ccd94ca63049..58ed2520f040c9aad6664ff8da97b56113a55850 100644 (file)
@@ -29,8 +29,7 @@ libsigrokdecode_la_SOURCES = controller.c decoder.c log.c util.c exception.c \
 
 libsigrokdecode_la_CPPFLAGS = $(CPPFLAGS_PYTHON) \
                              -DDECODERS_DIR='"$(DECODERS_DIR)"'
-libsigrokdecode_la_LDFLAGS = $(LIBSIGROKDECODE_LT_LDFLAGS) \
-                            $(LDFLAGS_PYTHON)
+libsigrokdecode_la_LDFLAGS = $(SRD_LIB_LDFLAGS) $(LDFLAGS_PYTHON)
 
 include_HEADERS = sigrokdecode.h
 noinst_HEADERS = sigrokdecode-internal.h
index 8fbfd451188525c2e4811ce4a1f0ce8fd9ae0b24..b3e3b60e6078a3b17b0e25ec8d25fa1d97c0715f 100644 (file)
 AC_PREREQ([2.63])
 
 # libsigrokdecode package version number (NOT the same as shared lib version!).
-m4_define([libsigrokdecode_major_version], [0])
-m4_define([libsigrokdecode_minor_version], [1])
-m4_define([libsigrokdecode_micro_version], [0])
-m4_define([libsigrokdecode_version],
-         [libsigrokdecode_major_version.libsigrokdecode_minor_version.libsigrokdecode_micro_version])
+m4_define([srd_package_version_major], [0])
+m4_define([srd_package_version_minor], [1])
+m4_define([srd_package_version_micro], [0])
+m4_define([srd_package_version], [srd_package_version_major.srd_package_version_minor.srd_package_version_micro])
 
-AC_INIT([libsigrokdecode], [libsigrokdecode_version],
+AC_INIT([libsigrokdecode], [srd_package_version],
        [sigrok-devel@lists.sourceforge.net], [libsigrokdecode],
        [http://www.sigrok.org])
 AC_CONFIG_HEADER([config.h])
@@ -38,9 +37,9 @@ AC_CONFIG_AUX_DIR([autostuff])
 AM_INIT_AUTOMAKE([1.11 -Wall -Werror foreign std-options])
 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
 
-AH_TOP([#ifndef LIBSIGROKDECODE_CONFIG_H
-#define LIBSIGROKDECODE_CONFIG_H    /* To stop multiple inclusions. */])
-AH_BOTTOM([#endif /* LIBSIGROKDECODE_CONFIG_H */])
+AH_TOP([#ifndef SRD_CONFIG_H
+#define SRD_CONFIG_H    /* To stop multiple inclusions. */])
+AH_BOTTOM([#endif /* SRD_CONFIG_H */])
 
 CFLAGS="-g -Wall -Wextra"
 
@@ -62,16 +61,16 @@ PKG_PROG_PKG_CONFIG([0.22])
 # Carefully read the libtool docs before updating these numbers!
 # The algorithm for determining which number to change (and how) is nontrivial!
 # http://www.gnu.org/software/libtool/manual/libtool.html#Updating-version-info
-LIBSIGROKDECODE_LT_CURRENT=0
-LIBSIGROKDECODE_LT_REVISION=0
-LIBSIGROKDECODE_LT_AGE=0
-LIBSIGROKDECODE_LT_VERSION="$LIBSIGROKDECODE_LT_CURRENT:$LIBSIGROKDECODE_LT_REVISION:$LIBSIGROKDECODE_LT_AGE"
-LIBSIGROKDECODE_LT_LDFLAGS="-version-info $LIBSIGROKDECODE_LT_VERSION"
-AC_SUBST(LIBSIGROKDECODE_LT_CURRENT)
-AC_SUBST(LIBSIGROKDECODE_LT_REVISION)
-AC_SUBST(LIBSIGROKDECODE_LT_AGE)
-AC_SUBST(LIBSIGROKDECODE_LT_VERSION)
-AC_SUBST(LIBSIGROKDECODE_LT_LDFLAGS)
+SRD_LIB_VERSION_CURRENT=0
+SRD_LIB_VERSION_REVISION=0
+SRD_LIB_VERSION_AGE=0
+SRD_LIB_VERSION="$SRD_LIB_VERSION_CURRENT:$SRD_LIB_VERSION_REVISION:$SRD_LIB_VERSION_AGE"
+SRD_LIB_LDFLAGS="-version-info $SRD_LIB_VERSION"
+AC_SUBST(SRD_LIB_VERSION_CURRENT)
+AC_SUBST(SRD_LIB_VERSION_REVISION)
+AC_SUBST(SRD_LIB_VERSION_AGE)
+AC_SUBST(SRD_LIB_VERSION)
+AC_SUBST(SRD_LIB_LDFLAGS)
 
 # Checks for libraries.
 
@@ -134,15 +133,15 @@ AC_SUBST(DECODERS_DIR, "$datadir/libsigrokdecode/decoders")
 AC_SUBST(MAKEFLAGS, '--no-print-directory')
 AC_SUBST(AM_LIBTOOLFLAGS, '--silent')
 
-LIBSIGROKDECODE_MAJOR_VERSION=libsigrokdecode_major_version
-LIBSIGROKDECODE_MINOR_VERSION=libsigrokdecode_minor_version
-LIBSIGROKDECODE_MICRO_VERSION=libsigrokdecode_micro_version
-LIBSIGROKDECODE_VERSION=libsigrokdecode_version
+SRD_PACKAGE_VERSION_MAJOR=srd_package_version_major
+SRD_PACKAGE_VERSION_MINOR=srd_package_version_minor
+SRD_PACKAGE_VERSION_MICRO=srd_package_version_micro
+SRD_PACKAGE_VERSION=srd_package_version
 
-AC_SUBST(LIBSIGROKDECODE_MAJOR_VERSION)
-AC_SUBST(LIBSIGROKDECODE_MINOR_VERSION)
-AC_SUBST(LIBSIGROKDECODE_MICRO_VERSION)
-AC_SUBST(LIBSIGROKDECODE_VERSION)
+AC_SUBST(SRD_PACKAGE_VERSION_MAJOR)
+AC_SUBST(SRD_PACKAGE_VERSION_MINOR)
+AC_SUBST(SRD_PACKAGE_VERSION_MICRO)
+AC_SUBST(SRD_PACKAGE_VERSION)
 
 AC_CONFIG_FILES([Makefile
                 sigrokdecode.h
@@ -169,8 +168,8 @@ AC_OUTPUT
 echo
 echo "libsigrokdecode configuration summary:"
 echo
-echo "  - Package version (major.minor.micro):    $LIBSIGROKDECODE_VERSION"
-echo "  - Library version (current:revision:age): $LIBSIGROKDECODE_LT_VERSION"
+echo "  - Package version (major.minor.micro):    $SRD_PACKAGE_VERSION"
+echo "  - Library version (current:revision:age): $SRD_LIB_VERSION"
 echo "  - Prefix: $prefix"
 echo
 echo "Detected libraries:"
index 37a225742367b9d9221385f09c5f529c07a7406e..7a435bc867c9e388b2b178cfc5bba7b158dd75cd 100644 (file)
@@ -35,32 +35,32 @@ extern "C" {
  */
 
 /** The libsigrokdecode package 'major' version number. */
-#define LIBSIGROKDECODE_MAJOR_VERSION @LIBSIGROKDECODE_MAJOR_VERSION@
+#define SRD_PACKAGE_VERSION_MAJOR @SRD_PACKAGE_VERSION_MAJOR@
 
 /** The libsigrokdecode package 'minor' version number. */
-#define LIBSIGROKDECODE_MINOR_VERSION @LIBSIGROKDECODE_MINOR_VERSION@
+#define SRD_PACKAGE_VERSION_MINOR @SRD_PACKAGE_VERSION_MINOR@
 
 /** The libsigrokdecode package 'micro' version number. */
-#define LIBSIGROKDECODE_MICRO_VERSION @LIBSIGROKDECODE_MICRO_VERSION@
+#define SRD_PACKAGE_VERSION_MICRO @SRD_PACKAGE_VERSION_MICRO@
 
 /** The libsigrokdecode package version ("major.minor.micro") as string. */
-#define LIBSIGROKDECODE_VERSION_STRING "@LIBSIGROKDECODE_VERSION@"
+#define SRD_PACKAGE_VERSION_STRING "@SRD_PACKAGE_VERSION@"
 
 /*
  * Library/libtool version macros (can be used for conditional compilation).
  */
 
 /** The libsigrokdecode libtool 'current' version number. */
-#define LIBSIGROKDECODE_LT_CURRENT @LIBSIGROKDECODE_LT_CURRENT@
+#define SRD_LIB_VERSION_CURRENT @SRD_LIB_VERSION_CURRENT@
 
 /** The libsigrokdecode libtool 'revision' version number. */
-#define LIBSIGROKDECODE_LT_REVISION @LIBSIGROKDECODE_LT_REVISION@
+#define SRD_LIB_VERSION_REVISION @SRD_LIB_VERSION_REVISION@
 
 /** The libsigrokdecode libtool 'age' version number. */
-#define LIBSIGROKDECODE_LT_AGE @LIBSIGROKDECODE_LT_AGE@
+#define SRD_LIB_VERSION_AGE @SRD_LIB_VERSION_AGE@
 
 /** The libsigrokdecode libtool version ("current:revision:age") as string. */
-#define LIBSIGROKDECODE_LT_VERSION_STRING "@LIBSIGROKDECODE_LT_VERSION@"
+#define SRD_LIB_VERSION_STRING "@SRD_LIB_VERSION@"
 
 /*
  * Status/error codes returned by libsigrokdecode functions.