svn commit: samba r18488 - in branches/SAMBA_4_0/source/lib/replace: .

tridge at samba.org tridge at samba.org
Wed Sep 13 22:31:26 GMT 2006


Author: tridge
Date: 2006-09-13 22:31:25 +0000 (Wed, 13 Sep 2006)
New Revision: 18488

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=18488

Log:

we have to make sure any extensions flags also make it into
confdefs.h, otherwise the real build and the configure tests will not
be significant

this change fixes the build of libreplace on hpux with gcc

Modified:
   branches/SAMBA_4_0/source/lib/replace/libreplace_cc.m4
   branches/SAMBA_4_0/source/lib/replace/libreplace_macros.m4


Changeset:
Modified: branches/SAMBA_4_0/source/lib/replace/libreplace_cc.m4
===================================================================
--- branches/SAMBA_4_0/source/lib/replace/libreplace_cc.m4	2006-09-13 17:39:21 UTC (rev 18487)
+++ branches/SAMBA_4_0/source/lib/replace/libreplace_cc.m4	2006-09-13 22:31:25 UTC (rev 18488)
@@ -45,17 +45,9 @@
 AC_C_BIGENDIAN
 AC_PROG_INSTALL
 
-AH_VERBATIM([_XOPEN_SOURCE_EXTENDED],
-[/* Enable XOPEN extensions on systems that have them.  */
-#ifndef _XOPEN_SOURCE_EXTENDED
-# define _XOPEN_SOURCE_EXTENDED 1
-#endif])
 
-AH_VERBATIM([_OSF_SOURCE],
-[/* Enable OSF extensions on systems that have them.  */
-#ifndef _OSF_SOURCE
-# define _OSF_SOURCE 1
-#endif])
+AC_EXTENSION_FLAG(_XOPEN_SOURCE_EXTENDED)
+AC_EXTENSION_FLAG(_OSF_SOURCE)
 
 LIBREPLACE_C99_STRUCT_INIT([],[AC_MSG_WARN([c99 structure initializer are not supported])])
 

Modified: branches/SAMBA_4_0/source/lib/replace/libreplace_macros.m4
===================================================================
--- branches/SAMBA_4_0/source/lib/replace/libreplace_macros.m4	2006-09-13 17:39:21 UTC (rev 18487)
+++ branches/SAMBA_4_0/source/lib/replace/libreplace_macros.m4	2006-09-13 22:31:25 UTC (rev 18488)
@@ -87,6 +87,19 @@
 rm -f conftest*
 ])])
 
+AC_DEFUN([AC_EXTENSION_FLAG],
+[
+  cat >>confdefs.h <<\EOF
+#ifndef $1
+# define $1
+#endif
+EOF
+AH_VERBATIM([$1], [#ifndef $1
+# define $1
+#endif])
+])
+
+
 dnl see if a declaration exists for a function or variable
 dnl defines HAVE_function_DECL if it exists
 dnl AC_HAVE_DECL(var, includes)



More information about the samba-cvs mailing list