From 767c0b39f49368423efc2730c013a66b48c0dd9e Mon Sep 17 00:00:00 2001 From: thib Date: Fri, 15 Sep 2000 20:16:41 +0000 Subject: [PATCH] bug corrected : VERSION used to be set uncorrectly --- config.h.in | 4 ++-- configure.in | 4 +++- fcron.c | 12 ++++++------ fcrontab.c | 6 +++--- 4 files changed, 14 insertions(+), 12 deletions(-) diff --git a/config.h.in b/config.h.in index c8e0b24..f7a2392 100644 --- a/config.h.in +++ b/config.h.in @@ -21,7 +21,7 @@ * `LICENSE' that comes with the fcron source distribution. */ - /* $Id: config.h.in,v 1.18 2000-09-13 15:39:08 thib Exp $ */ + /* $Id: config.h.in,v 1.19 2000-09-15 20:18:13 thib Exp $ */ /* *********************************************************** */ @@ -121,7 +121,7 @@ /* ****************************************************************** */ /* *** options which are set by configure script ******************** */ -#undef VERSION +#undef VERSION_QUOTED /* *** paths *** */ #undef ETC diff --git a/configure.in b/configure.in index e9ffaaf..a0e5394 100644 --- a/configure.in +++ b/configure.in @@ -7,7 +7,9 @@ AC_CONFIG_HEADER(config.h) AC_PREREQ(2.7) vers="0.9.2" -AC_DEFINE_UNQUOTED(VERSION, $version) +vers_quoted="\"$vers\"" +AC_DEFINE_UNQUOTED(VERSION, $vers) +AC_DEFINE_UNQUOTED(VERSION_QUOTED, $vers_quoted) VERSION="$vers" AC_SUBST(VERSION) diff --git a/fcron.c b/fcron.c index 19d1007..9c07a81 100644 --- a/fcron.c +++ b/fcron.c @@ -21,11 +21,11 @@ * `LICENSE' that comes with the fcron source distribution. */ - /* $Id: fcron.c,v 1.28 2000-09-13 15:45:14 thib Exp $ */ + /* $Id: fcron.c,v 1.29 2000-09-15 20:17:07 thib Exp $ */ #include "fcron.h" -char rcs_info[] = "$Id: fcron.c,v 1.28 2000-09-13 15:45:14 thib Exp $"; +char rcs_info[] = "$Id: fcron.c,v 1.29 2000-09-15 20:17:07 thib Exp $"; void main_loop(void); void check_signal(void); @@ -90,7 +90,7 @@ info(void) * version, license */ { fprintf(stderr, - "fcron " VERSION " - periodic command scheduler\n" + "fcron " VERSION_QUOTED " - periodic command scheduler\n" "Copyright 2000 Thibault Godouet \n" "This program is free software distributed WITHOUT ANY WARRANTY.\n" "See the GNU General Public License for more details.\n" @@ -105,7 +105,7 @@ void usage() /* print a help message about command line options and exit */ { - fprintf(stderr, "\nfcron " VERSION "\n\n" + fprintf(stderr, "\nfcron " VERSION_QUOTED "\n\n" "fcron [-d] [-f] [-b]\n" "fcron -h\n" " -d --debug Set Debug mode.\n" @@ -388,7 +388,7 @@ main(int argc, char **argv) break; default: /* parent */ - printf("\n%s[%d] " VERSION " : started.\n\n", + printf("\n%s[%d] " VERSION_QUOTED " : started.\n\n", prog_name, pid); exit(0); @@ -413,7 +413,7 @@ main(int argc, char **argv) * is running, otherwise update value of pid in lock file */ get_lock(); - explain("%s[%d] " VERSION " started", prog_name, daemon_pid); + explain("%s[%d] " VERSION_QUOTED " started", prog_name, daemon_pid); signal(SIGTERM, sigterm_handler); signal(SIGHUP, sighup_handler); diff --git a/fcrontab.c b/fcrontab.c index fb05713..c2ac9e9 100644 --- a/fcrontab.c +++ b/fcrontab.c @@ -22,7 +22,7 @@ * `LICENSE' that comes with the fcron source distribution. */ - /* $Id: fcrontab.c,v 1.15 2000-09-15 19:49:24 thib Exp $ */ + /* $Id: fcrontab.c,v 1.16 2000-09-15 20:17:12 thib Exp $ */ /* * The goal of this program is simple : giving a user interface to fcron @@ -42,7 +42,7 @@ #include "fcrontab.h" -char rcs_info[] = "$Id: fcrontab.c,v 1.15 2000-09-15 19:49:24 thib Exp $"; +char rcs_info[] = "$Id: fcrontab.c,v 1.16 2000-09-15 20:17:12 thib Exp $"; void info(void); void usage(void); @@ -87,7 +87,7 @@ info(void) * version, license */ { fprintf(stderr, - "fcrontab " VERSION " - user interface to daemon fcron\n" + "fcrontab " VERSION_QUOTED " - user interface to daemon fcron\n" "Copyright 2000 Thibault Godouet \n" "This program is free software distributed WITHOUT ANY WARRANTY.\n" "See the GNU General Public License for more details.\n" -- 2.40.0