Skip to content

Commit

Permalink
configure: use PACKAGE_VERSION variable instead of VERSION
Browse files Browse the repository at this point in the history
The AC_INIT macro will define the PACKAGE_VERSION variable:

http://www.gnu.org/savannah-checkouts/gnu/autoconf/manual/autoconf-2.69/html_node/Initializing-configure.html#AC%5fINIT

I kept the #define name `SYSLOG_NG_VERSION` for backward compatibility
with incubator.

Signed-off-by: Tibor Benke <[email protected]>
  • Loading branch information
Tibor Benke committed Mar 4, 2016
1 parent 06b881c commit b842b38
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 17 deletions.
6 changes: 3 additions & 3 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ fi
AM_INIT_AUTOMAKE([foreign no-define subdir-objects])
_AM_PROG_TAR([ustar])
if test -n "$SNAPSHOT_VERSION"; then
VERSION=$VERSION+$SNAPSHOT_VERSION
PACKAGE_VERSION=$PACKAGE_VERSION+$SNAPSHOT_VERSION
fi

if test "x$prefix" = "xNONE"; then
Expand Down Expand Up @@ -1404,7 +1404,7 @@ AC_DEFINE_UNQUOTED(JOURNALD_OPTIONAL, 1, ["Enable systemd-journal source if jour
AC_DEFINE_UNQUOTED(JOURNALD_SYSTEM, 2, ["Force systemd-journal source to use system's journald"])

AC_DEFINE_UNQUOTED(PACKAGE_NAME, "$PACKAGE_NAME", [package name])
AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [version number])
AC_DEFINE_UNQUOTED(VERSION, "$PACKAGE_VERSION", [version number])
AC_DEFINE_UNQUOTED(SOURCE_REVISION, "$SOURCE_REVISION", [source revision])
AC_DEFINE_UNQUOTED(LICENSE_VERSION, "$LICENSE_VERSION", [Required license version])

Expand Down Expand Up @@ -1535,7 +1535,7 @@ AC_OUTPUT(dist.conf
)

echo
echo "syslog-ng Open Source Edition $VERSION configured"
echo "syslog-ng Open Source Edition $PACKAGE_VERSION configured"
echo " Compiler options:"
echo " compiler : $CC"
echo " compiler options : $CFLAGS $CPPFLAGS"
Expand Down
2 changes: 1 addition & 1 deletion debian/changelog.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@PACKAGE_NAME@ (@VERSION@) @RELEASE_TAG@; urgency=low
@PACKAGE_NAME@ (@PACKAGE_VERSION@) @RELEASE_TAG@; urgency=low

* New upstream version.

Expand Down
2 changes: 1 addition & 1 deletion lib/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ include lib/debugger/Makefile.am
include lib/compat/Makefile.am
include lib/logmsg/Makefile.am

LSNG_RELEASE = $(shell echo @VERSION@ | cut -d. -f1,2)
LSNG_RELEASE = $(shell echo @PACKAGE_VERSION@ | cut -d. -f1,2)

# * Start with version information of ‘0:0:0’ for each libtool
# library.
Expand Down
2 changes: 1 addition & 1 deletion libtest/syslog-ng-test.pc.in
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ includedir=@includedir@

Name: syslog-ng-test
Description: Test helper package for syslog-ng modules
Version: @VERSION@
Version: @PACKAGE_VERSION@
Requires.private: glib-2.0 syslog-ng
Libs: -L${pkglibdir}/libtest -lsyslog-ng-test
Cflags: -I${includedir}/syslog-ng/libtest
2 changes: 1 addition & 1 deletion syslog-ng.pc.in
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ivykis=@with_ivykis@

Name: syslog-ng-dev
Description: Dev package for syslog-ng module
Version: @VERSION@
Version: @PACKAGE_VERSION@
Requires: glib-2.0 eventlog
Libs: -L${libdir} @GLIB_LIBS@ -lsyslog-ng
Cflags: -I${includedir}/syslog-ng @INTERNAL_IVYKIS_CFLAGS@
20 changes: 10 additions & 10 deletions syslog-ng.spec.in
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Summary: Next generation system logging daemon
Name: @PACKAGE_NAME@
Version: @VERSION@
Version: @PACKAGE_VERSION@
Release: 1
License: GPL
Group: System Environment/Daemons
Expand Down Expand Up @@ -94,21 +94,21 @@ elif [ "%{_host_vendor}" = "redhat" ] || [ "%{_host_vendor}" = "suse" ]; then
fi

# install documentation
[ -d "${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@VERSION@" ] || ./install-sh -d "${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@VERSION@"
[ -d "${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@PACKAGE_VERSION@" ] || ./install-sh -d "${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@PACKAGE_VERSION@"
./install-sh -o root -g root -m 0644 NEWS \
${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@VERSION@/NEWS
${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@PACKAGE_VERSION@/NEWS
./install-sh -o root -g root -m 0644 AUTHORS \
${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@VERSION@/AUTHORS
${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@PACKAGE_VERSION@/AUTHORS
./install-sh -o root -g root -m 0644 COPYING \
${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@VERSION@/COPYING
${RPM_BUILD_ROOT}/%{_prefix}/share/doc/syslog-ng-@PACKAGE_VERSION@/COPYING

%files
%defattr(-,root,root)
%{prefix}/sbin/syslog-ng
%{prefix}/bin/loggen
%{_mandir}/*
%docdir %{_prefix}/share/doc/syslog-ng-@VERSION@
%{_prefix}/share/doc/syslog-ng-@VERSION@/*
%docdir %{_prefix}/share/doc/syslog-ng-@PACKAGE_VERSION@
%{_prefix}/share/doc/syslog-ng-@PACKAGE_VERSION@/*
%config(noreplace) /etc/syslog-ng/syslog-ng.conf
%ifnos aix5.2
/etc/rc.d/init.d/syslog-ng
Expand Down Expand Up @@ -234,11 +234,11 @@ fi
[ $RPM_BUILD_ROOT = / ] || rm -rf $RPM_BUILD_ROOT

%changelog
* Mon Sep 14 2009 Balazs Scheidler <[email protected]> @VERSION@-1
* Mon Sep 14 2009 Balazs Scheidler <[email protected]> @PACKAGE_VERSION@-1
- Removed some more Premium Edition related cruft.
* Wed Sep 02 2009 Balazs Scheidler <[email protected]> @VERSION@-1
* Wed Sep 02 2009 Balazs Scheidler <[email protected]> @PACKAGE_VERSION@-1
- Removed the references to the documentation and libzlicense-devel
* Wed Apr 04 2007 Tamas Pal <[email protected]> @VERSION@-1
* Wed Apr 04 2007 Tamas Pal <[email protected]> @PACKAGE_VERSION@-1
- Added libnet-devel and libzlicense-devel to BuildRequires.
- Changed Packager to Tamas Pal.
- Changed license to BalaBit Proprietary one.
Expand Down

0 comments on commit b842b38

Please sign in to comment.