From: Arvin Schnell Date: Mon, 15 Jul 2013 12:52:36 +0000 (+0200) Subject: - added version header file X-Git-Tag: v0.1.6~12 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a601946fc410688e2f6f98dee2a3dd1a3aff61c7;p=thirdparty%2Fsnapper.git - added version header file --- diff --git a/configure.ac b/configure.ac index cc29ebe4..94ccd8e5 100644 --- a/configure.ac +++ b/configure.ac @@ -115,6 +115,8 @@ PKG_CHECK_MODULES(DBUS, dbus-1) AC_SUBST(VERSION) AC_SUBST(LIBVERSION_MAJOR) +AC_SUBST(LIBVERSION_MINOR) +AC_SUBST(LIBVERSION_PATCHLEVEL) AC_SUBST(LIBVERSION_INFO) AC_SUBST(docdir) AC_SUBST(fillupdir) @@ -122,6 +124,7 @@ AC_SUBST(fillupdir) AC_OUTPUT( Makefile snapper/Makefile + snapper/Version.h:snapper/Version.h.in examples/Makefile examples/c/Makefile examples/c++-lib/Makefile diff --git a/snapper/.gitignore b/snapper/.gitignore index 66a3f3fe..694c0b5a 100644 --- a/snapper/.gitignore +++ b/snapper/.gitignore @@ -1,2 +1,3 @@ *.lo *.la +Version.h diff --git a/snapper/Makefile.am b/snapper/Makefile.am index c68cdd0b..83bd5797 100644 --- a/snapper/Makefile.am +++ b/snapper/Makefile.am @@ -33,6 +33,7 @@ libsnapper_la_SOURCES = \ SnapperTmpl.h \ SnapperTypes.h \ SnapperDefines.h \ + Version.h \ $(TMP_XA) @@ -58,6 +59,7 @@ libsnapper_la_LIBADD = -lboost_thread-mt -lboost_system-mt -lxml2 -lz -lm pkgincludedir = $(includedir)/snapper pkginclude_HEADERS = \ + Version.h \ Factory.h \ Snapper.h \ Snapshot.h \ diff --git a/snapper/Version.h.in b/snapper/Version.h.in new file mode 100644 index 00000000..fa9c1f5f --- /dev/null +++ b/snapper/Version.h.in @@ -0,0 +1,36 @@ +/* + * Copyright (c) 2013 Novell, Inc. + * + * All Rights Reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of version 2 of the GNU General Public License as published + * by the Free Software Foundation. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, contact Novell, Inc. + * + * To contact Novell about this file by physical or electronic mail, you may + * find current contact information at www.novell.com. + */ + + +#ifndef SNAPPER_VERSION_H +#define SNAPPER_VERSION_H + + +#define LIBSNAPPER_MAJOR="@LIBVERSION_MAJOR@" +#define LIBSNAPPER_MINOR="@LIBVERSION_MINOR@" +#define LIBSNAPPER_PATCHLEVEL="@LIBVERSION_PATCHLEVEL@" + +#define LIBSNAPPER_VERSION ( LIBSNAPPER_MAJOR * 10000 + \\ + LIBSNAPPER_MINOR * 100 + \\ + LIBSNAPPER_PATCHLEVEL ) + + +#endif