[PATCH] autogenerate include/version.h ...

Ken Cross kcross at nssolutions.com
Mon Aug 11 12:10:30 GMT 2003


That looks excellent -- I think it adds a lot of flexibility.  Thank you!

I presume samba_version_string() will be part of some common module?

Ken
________________________________

Ken Cross

Network Storage Solutions
Phone 865.675.4070 ext 31
kcross at nssolutions.com 

> -----Original Message-----
> From: Stefan (metze) Metzmacher [mailto:metze at metzemix.de] 
> Sent: Monday, August 11, 2003 7:59 AM
> To: Ken Cross; 'Gerald (Jerry) Carter'; 'Jelmer Vernooij'
> Cc: 'Multiple recipients of list SAMBA-TECHNICAL'; Alexander Bokovoy
> Subject: RE: [PATCH] autogenerate include/version.h ...
> 

> 
> will something like that be ok for you:
> 
> you can set in source/VERSION
> 
> SAMBA_VERSION_VENDOR_SUFFIX="-MYSUFFIX"
> or
> SAMBA_VERSION_VENDOR_SUFFIX=my_vendor_suffix()
> 
> #define SAMBA_VERSION_MAJOR 3
> #define SAMBA_VERSION_MINOR 0
> #define SAMBA_VERSION_RELEASE 0
> #define SAMBA_VERSION_RC_RELEASE 1
> #define SAMBA_VERSION_IS_CVS_SNAPSHOT 1
> #define SAMBA_VERSION_OFFICIAL_STRING "3.0.0rc1cvs"
> #define SAMBA_VERSION_VENDOR_SUFFIX my_vendor_suffix()
> #define SAMBA_VERSION_STRING samba_version_string()
> 
> 
> ...
> const char *samba_version_string(void)
> {
> #ifdef SAMBA_VERSION_VENDOR_SUFFIX
>          static fstring samba_version;
>          static BOOL init_samba_version;
> 
>          if (init_samba_version)
>                  return samba_version;
> 
>          fstr_printf("%s-%s",
>                  SAMBA_VERSION_OFFICIAL_STRING,
>                  SAMBA_VERSION_VENDOR_SUFFIX);
> 
>          init_samba_version = True;
>          return samba_version;
> #else
>          return SAMBA_VERSION_OFFICIAL_STRING;
> #endif
> }
> 
> 
> 
> metze
> --------------------------------------------------------------
> ---------------
> Stefan "metze" Metzmacher <metze at metzemix.de> 
> 




More information about the samba-technical mailing list