Report the common package version for all the tools, in an attempt to be less confusing. This makes fcoeadm, fcoemon and fipvlan all report 1.0.8 now.
In adding the new autoconf generated fcoe_utils.h header file to .gitignore, I noticed that the resultant files for the passthrough tools (fcping, fcnsq, fcrls) were not listed there either, so I tacked that on here as well. Signed-off-by: Chris Leech <[email protected]> --- .gitignore | 4 ++++ Makefile.am | 7 ++++--- configure.ac | 4 ++-- fcoe_utils.h.in | 6 ++++++ fcoeadm.c | 5 +++-- fcoemon.c | 5 +++-- fipvlan.c | 4 ++-- 7 files changed, 24 insertions(+), 11 deletions(-) create mode 100644 fcoe_utils.h.in diff --git a/.gitignore b/.gitignore index a15894c..d492a09 100644 --- a/.gitignore +++ b/.gitignore @@ -15,12 +15,16 @@ missing # other autoconf generated files fcoe-utils.spec fcoeplumb +fcoe_utils.h # compile generated files *.o fcoeadm fcoemon fipvlan +fcping +fcnsq +fcrls etc/initd/fcoe # build.sh generated files diff --git a/Makefile.am b/Makefile.am index 0c28462..a94ca7b 100644 --- a/Makefile.am +++ b/Makefile.am @@ -12,7 +12,7 @@ AM_CFLAGS = -DSYSCONFDIR="\"${sysconfdir}\"" ## rules for building fcoeadm ## only listed sources get packaged, so must list all headers too -fcoeadm_SOURCES = fcoeadm_display.c fcoeadm.c fcoeadm.h \ +fcoeadm_SOURCES = fcoeadm_display.c fcoeadm.c fcoeadm.h fcoe_utils.h \ include/fc_scsi.h include/fc_types.h include/net_types.h ## fcoeadm uses HBAAPI, so get the right flags for compiling and linking @@ -30,7 +30,7 @@ fcping_LDFLAGS = $(HBAAPI_LIBS) -lrt ## rules for building fcoemon ## only listed sources get packaged, so must list all headers too fcoemon_SOURCES = fcoemon_utils.c fcoemon.c fcoemon.h fcoemon_utils.h \ -include/fc_scsi.h include/fc_types.h include/net_types.h +fcoe_utils.h include/fc_scsi.h include/fc_types.h include/net_types.h ## fcoemon needs headers from dcbd, get the right include path for them fcoemon_CFLAGS = $(DCBD_CFLAGS) @@ -38,7 +38,8 @@ fcoemon_LDFLAGS = -lrt ## rules for building fipvlan ## only listed sources get packaged, so must list all headers too -fipvlan_SOURCES = fipvlan.c include/fip.h log.c include/log.h include/list.h +fipvlan_SOURCES = fipvlan.c fcoe_utils.h include/fip.h \ +log.c include/log.h include/list.h ## install configuration file in $(prefix)/etc/fcoe fcoe_configdir = ${sysconfdir}/fcoe diff --git a/configure.ac b/configure.ac index f56820b..b3296b1 100644 --- a/configure.ac +++ b/configure.ac @@ -1,4 +1,4 @@ -AC_INIT([fcoe-utils], [1.0.7], [[email protected]]) +AC_INIT([fcoe-utils], [1.0.8], [[email protected]]) AM_INIT_AUTOMAKE([-Wall -Werror foreign]) AC_PROG_CC @@ -19,6 +19,6 @@ AS_IF([test "X$with_dcb" != Xno], [PKG_CHECK_MODULES([DCBD], [dcbd]) AC_SUBST([DCBD_CFLAGS])]) -AC_CONFIG_FILES([Makefile fcoeplumb fcoe-utils.spec]) +AC_CONFIG_FILES([Makefile fcoeplumb fcoe-utils.spec fcoe_utils.h]) AC_OUTPUT diff --git a/fcoe_utils.h.in b/fcoe_utils.h.in new file mode 100644 index 0000000..695ba87 --- /dev/null +++ b/fcoe_utils.h.in @@ -0,0 +1,6 @@ +#ifndef _FCOE_UTILS_H_ +#define _FCOE_UTILS_H_ + +#define FCOE_UTILS_VERSION "@VERSION@" + +#endif /* _FCOE_UTILS_H_ */ diff --git a/fcoeadm.c b/fcoeadm.c index c766921..c13f6b6 100644 --- a/fcoeadm.c +++ b/fcoeadm.c @@ -23,10 +23,11 @@ #include <errno.h> #include <getopt.h> #include <dirent.h> +#include "fcoe_utils.h" #include "fcoeadm.h" -static char *fcoeadm_version = \ - "fcoeadm v1.0.7\n Copyright (c) 2009, Intel Corporation.\n"; +static char *fcoeadm_version = +"fcoeadm v" FCOE_UTILS_VERSION "\n Copyright (c) 2009, Intel Corporation.\n"; #define SYSFS_MOUNT "/sys" #define SYSFS_NET SYSFS_MOUNT "/class/net" diff --git a/fcoemon.c b/fcoemon.c index a3a09b1..48e47ae 100644 --- a/fcoemon.c +++ b/fcoemon.c @@ -56,6 +56,7 @@ #include "net_types.h" #include "fc_types.h" +#include "fcoe_utils.h" #include "fcoemon_utils.h" #include "fcoemon.h" @@ -83,8 +84,8 @@ #define FCM_PING_REQ_LEN 1 /* byte-length of dcbd PING request */ #define FCM_PING_RSP_LEN 8 /* byte-length of dcbd PING response */ -static char *fcoemon_version = \ - "fcoemon v1.0.8\n Copyright (c) 2009, Intel Corporation.\n"; +static char *fcoemon_version = +"fcoemon v" FCOE_UTILS_VERSION "\n Copyright (c) 2009, Intel Corporation.\n"; /* * fcoe service configuration data diff --git a/fipvlan.c b/fipvlan.c index 639d5ec..ffdd8f9 100644 --- a/fipvlan.c +++ b/fipvlan.c @@ -36,6 +36,7 @@ #include <arpa/inet.h> #include <linux/netlink.h> #include <linux/rtnetlink.h> +#include "fcoe_utils.h" #include "fip.h" #include "log.h" #include "list.h" @@ -45,7 +46,6 @@ /* global configuration */ char *exe; -#define VERSION_STR "0.5" struct iff { int ifindex; @@ -532,7 +532,7 @@ int parse_cmdline(int argc, char **argv) help(0); break; case 'v': - printf("%s version %s\n", exe, VERSION_STR); + printf("%s version %s\n", exe, FCOE_UTILS_VERSION); exit(0); break; default: _______________________________________________ devel mailing list [email protected] http://www.open-fcoe.org/mailman/listinfo/devel
