X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;ds=sidebyside;f=examples%2Fat91sam7s%2Fverstag.h;fp=examples%2Fat91sam7s%2Fverstag.h;h=e6163906f2915cdb3f5282fed73576cfb724631f;hb=24c21c92d29b76a3f0de0a107f4bafef7bb0f812;hp=0000000000000000000000000000000000000000;hpb=6b7a2e7b20bc7fe05a61c17d6d96eb70c67a09c9;p=bertos.git diff --git a/examples/at91sam7s/verstag.h b/examples/at91sam7s/verstag.h new file mode 100644 index 00000000..e6163906 --- /dev/null +++ b/examples/at91sam7s/verstag.h @@ -0,0 +1,94 @@ +/** + * \file + * + * + * \version $Id$ + * + * \author Bernie Innocenti + * + * \brief Declare application version strings + */ +#ifndef DEVLIB_VERSTAG_H +#define DEVLIB_VERSTAG_H + +#ifndef ARCH_CONFIG_H + #include "cfg/arch_config.h" +#endif + +#define APP_NAME "AT91SAM7S-EK porting test" +#define APP_DESCRIPTION "AT91SAM7S-EK porting test" +#define APP_AUTHOR "Develer" +#define APP_COPYRIGHT "Copyright 2007 Develer (http://www.develer.com/)" + +#define VERS_MAJOR 0 +#define VERS_MINOR 1 +#define VERS_REV 0 +#define VERS_LETTER "" + +/** + * If _SNAPSHOT is defined, \c VERS_TAG contains the build date + * date instead of a numeric version string. + */ +//#define _SNAPSHOT + +#ifdef _DEBUG + #define VERS_DBG "D" +#else + #define VERS_DBG "" +#endif + +#define __STRINGIZE(x) #x +#define _STRINGIZE(x) __STRINGIZE(x) + +/** Build application version string (i.e.: "1.7.0") */ +#define MAKE_VERS(maj,min,rev) _STRINGIZE(maj) "." _STRINGIZE(min) "." _STRINGIZE(rev) VERS_LETTER VERS_DBG +#ifdef _SNAPSHOT + #define VERS_TAG "snapshot" " " __DATE__ " " __TIME__ " " VERS_LETTER " " VERS_DBG +#else + #define VERS_TAG MAKE_VERS(VERS_MAJOR,VERS_MINOR,VERS_REV) +#endif + +/** Build application version string suitable for MS windows resource files (i.e.: "1, 7, 0, 1") */ +#define MAKE_RCVERS(maj,min,rev,bld) _STRINGIZE(maj) ", " _STRINGIZE(min) ", " _STRINGIZE(rev) ", " _STRINGIZE(bld) +#define RCVERSION_TAG MAKE_VERS(VERS_MAJOR,VERS_MINOR,VERS_REV) + +/** The revision string (contains VERS_TAG) */ +extern const char vers_tag[]; + +/** Sequential build number (contains VERS_BUILD) */ +extern const int vers_build_nr; +//extern const char vers_build_str[]; + +/** Hostname of the machine used to build this binary (contains VERS_HOST) */ +extern const char vers_host[]; + +#endif /* DEVLIB_VERSTAG_H */