On Fri, Feb 25, 2011 at 01:17:08AM -0500, Dennis Clarke wrote: > >> $ ls -l /dev/urandom > >> lrwxrwxrwx 1 root root 34 Feb 19 2008 /dev/urandom -> > >> ../devices/pseudo/random@0:urandom > > > > Which version of SunOS first introduced unconditional support for > > /dev/urandom? > > I don't know what you mean by "unconditional" but the feature was added to > Solaris 8 in : > Patch-ID# 112439-02
That's conditional on the SunOS patch. The question is which SunOS releases *always* have /dev/urandom. > > On Fri, Feb 25, 2011 at 12:35:48AM -0500, Dennis Clarke wrote: > > > >> /opt/studio/SOS11/SUNWspro/bin/cc -DNO_CLOSEFROM -DNO_DEV_URANDOM > >> -DNO_FUTIMESAT -Dstrcasecmp=fix_strcasecmp > >> -Dstrncasecmp=fix_strncasecmp -g -O -I. -I../../include -DSUNOS5 -c > >> postconf.c > >> "str_table.h", line 46: non-constant initializer involving a cast > >> cc: acomp failed for postconf.c > > > > What do you see on line 46 of str_table.h? > > $ cat -n str_table.h | head -46 | tail -1 > 46 VAR_TLS_BUG_TWEAKS, DEF_TLS_BUG_TWEAKS, &var_tls_bug_tweaks, 0, 0, Well, DEF_TLS_BUG_TWEAKS is defined as the constant expression: ((TLS_BUG_TWEAK_A TLS_BUG_TWEAK_B)+1) where TLS_BUG_TWEAK_A and TLS_BUG_TWEAK_B are string literals. In your case: "" and " ". So the expression is: (("" " ") + 1) which should be the constant pointer to the second (NUL) character of " ". Not quite sure why your compiler objects, but I guess the expression needs to be simplified. :-( Does the patch below solve the problem? Index: src/global/mail_params.h *** src/global/mail_params.h 23 Feb 2011 16:59:15 -0000 1.1.1.24.8.1 --- src/global/mail_params.h 25 Feb 2011 07:05:17 -0000 *************** *** 2988,3020 **** #define DEF_TLS_PREEMPT_CLIST 0 extern bool var_tls_preempt_clist; ! #ifdef USE_TLS ! ! /* ! * The tweak for CVE-2005-2969 is needed in some versions prior to 1.0.0 ! */ #if (OPENSSL_VERSION_NUMBER < 0x1000000fL) ! #define TLS_BUG_TWEAK_A " CVE-2005-2969" #else ! #define TLS_BUG_TWEAK_A "" #endif - - /* - * The tweak for CVE-2010-4180 is needed in some versions prior to 1.0.1 - */ - #if (OPENSSL_VERSION_NUMBER < 0x1000100fL) - #define TLS_BUG_TWEAK_B " CVE-2010-4180" #else ! #define TLS_BUG_TWEAK_B " " #endif - #else /* USE_TLS */ - #define TLS_BUG_TWEAK_A "" - #define TLS_BUG_TWEAK_B " " - #endif /* USE_TLS */ - #define VAR_TLS_BUG_TWEAKS "tls_disable_workarounds" ! #define DEF_TLS_BUG_TWEAKS ((TLS_BUG_TWEAK_A TLS_BUG_TWEAK_B)+1) extern char *var_tls_bug_tweaks; /* --- 2988,3007 ---- #define DEF_TLS_PREEMPT_CLIST 0 extern bool var_tls_preempt_clist; ! /* The tweak for CVE-2010-4180 is needed in some versions prior to 1.0.1 */ ! /* The tweak for CVE-2005-2969 is needed in some versions prior to 1.0.0 */ ! #if defined(USE_TLS) && (OPENSSL_VERSION_NUMBER < 0x1000100fL) #if (OPENSSL_VERSION_NUMBER < 0x1000000fL) ! #define TLS_BUG_TWEAKS "CVE-2005-2969 CVE-2010-4180" #else ! #define TLS_BUG_TWEAKS "CVE-2010-4180" #endif #else ! #define TLS_BUG_TWEAKS "" #endif #define VAR_TLS_BUG_TWEAKS "tls_disable_workarounds" ! #define DEF_TLS_BUG_TWEAKS TLS_BUG_TWEAKS extern char *var_tls_bug_tweaks; /* -- Viktor.