summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/Makefile.am3
-rw-r--r--doc/yat2m.c6
2 files changed, 7 insertions, 2 deletions
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 849c661..d052283 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -35,7 +35,8 @@ myman_pages = gpg-error-config.1
man_MANS = $(myman_pages)
yat2m: yat2m.c
- $(CC_FOR_BUILD) -o $@ $(srcdir)/yat2m.c
+ $(CC_FOR_BUILD) -DPACKAGE_VERSION="\"$(PACKAGE_VERSION)\"" \
+ -o $@ $(srcdir)/yat2m.c
yat2m-stamp: $(myman_sources)
diff --git a/doc/yat2m.c b/doc/yat2m.c
index 184d27b..27db491 100644
--- a/doc/yat2m.c
+++ b/doc/yat2m.c
@@ -128,7 +128,11 @@
#define PGM "yat2m"
-#define VERSION "1.0"
+#ifdef PACKAGE_VERSION
+# define VERSION PACKAGE_VERSION
+#else
+# define VERSION "1.0"
+#endif
/* The maximum length of a line including the linefeed and one extra
character. */