Include a dissuader for odd numbered minor releases
authorJohn Darrington <john@darrington.wattle.id.au>
Mon, 18 Jan 2016 09:09:50 +0000 (10:09 +0100)
committerJohn Darrington <john@darrington.wattle.id.au>
Thu, 21 Jan 2016 20:37:03 +0000 (21:37 +0100)
src/language/utilities/set.q
src/libpspp/automake.mk
src/libpspp/version.h
src/ui/gui/help-menu.c
src/ui/terminal/terminal-reader.c

index 0be8c47010a7cf541501487456e3ba7eae686de8..126868dbdb52f107844200b75a9e41f8c8ff9507 100644 (file)
@@ -922,7 +922,7 @@ show_tempdir (const struct dataset *ds UNUSED)
 static char *
 show_version (const struct dataset *ds UNUSED)
 {
-  return strdup (version);
+  return strdup (announced_version);
 }
 
 static char *
index ca8bac6b4996ec71126c423113039c7c32c2d82b..29628596b33c52eedd7d10dd58be8ae4c7151ba7 100644 (file)
@@ -122,6 +122,12 @@ src/libpspp/version.c: $(top_srcdir)/AUTHORS Makefile
        $(AM_V_at)echo "#include \"version.h\"" >> $@,tmp
        $(AM_V_at)echo "const char bare_version[] = \"$(VERSION)\";" >> $@,tmp
        $(AM_V_at)echo "const char version[] = \"GNU $(PACKAGE) $(VERSION)\";" >> $@,tmp
+       $(AM_V_at)echo "const char announced_version[] = \"GNU $(PACKAGE) $(VERSION)\"" >> $@,tmp
+       @case `$(AM_V_at)echo $(VERSION) | $(AM_V_at)$(SED) -e 's/[0-9][0-9]*\.[0-9]*\([0-9]\)\.[0-9][0-9]*/\1/'` in \
+         [13579]) $(AM_V_at)echo "\"\nThis is an unreleased test version. It is not recommended for production use. Use at your own risk\"" >> $@,tmp \
+       ;;\
+       esac
+       $(AM_V_at)echo ";" >> $@,tmp
        $(AM_V_at)echo "const char host_system[] = \"$(host_triplet)\";" >> $@,tmp
        $(AM_V_at)echo "const char build_system[] = \"$(build_triplet)\";" >> $@,tmp
        $(AM_V_at)echo "const char locale_dir[] = \"$(datadir)/locale\";" >> $@,tmp
index a89480e549cd55d1b97214085e7df61e8b25bfb9..b1826910d871390cae85ca894db2ac1b4210a040 100644 (file)
@@ -23,6 +23,9 @@ extern const char bare_version[];
 /* "GNU PSPP A.B.C" */
 extern const char version[];
 
+/* Human readable version string */
+extern const char announced_version[];
+
 /* Canonical name of host system type. */
 extern const char host_system[];
 
index 279f5ef55d5238f73377f819e8bda347486ae9cc..61b9140d1e5e11b0e400b88f62d171188950659e 100644 (file)
@@ -46,7 +46,7 @@ about_new (GtkMenuItem *mmm, GtkWindow *parent)
   gtk_about_dialog_set_website (GTK_ABOUT_DIALOG (about), PACKAGE_URL);
 
   gtk_about_dialog_set_version (GTK_ABOUT_DIALOG (about),
-                               version);
+                               announced_version);
 
   gtk_about_dialog_set_authors (GTK_ABOUT_DIALOG (about),
                                (const gchar **) authors);
index 87fca837f9b331328793e9a7eb6d4f8269cf8a1f..141474a95bb9f77d18b5178403127cd8c2e5cbe9 100644 (file)
@@ -97,7 +97,7 @@ welcome (void)
         "it\nunder certain conditions; type \"show copying.\" to see the "
         "conditions.\nThere is ABSOLUTELY NO WARRANTY for PSPP; type \"show "
         "warranty.\" for details.\n", stdout);
-  puts (version);
+  puts (announced_version);
   journal_init ();
 }