Changeset: 6bb1de020c99 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=6bb1de020c99
Modified Files:
        clients/mapilib/Makefile.ag
        configure.ag
        monetdb5/modules/mal/Makefile.ag
        tools/merovingian/daemon/Makefile.ag
Branch: Mar2011
Log Message:

build-sys: only enable _XOPEN_SOURCE=500 where necessary

When _XOPEN_SOURCE=500 is defined, madvise is no longer available, so
don't define it for everything (in particular gdk), but only for those
places that need msg_control and friends.

http://monetdb.cwi.nl/testing/projects/monetdb/testweb/logs//39333:21478937a073/GNU-Solaris-sparc/make.html#l778


diffs (54 lines):

diff --git a/clients/mapilib/Makefile.ag b/clients/mapilib/Makefile.ag
--- a/clients/mapilib/Makefile.ag
+++ b/clients/mapilib/Makefile.ag
@@ -17,7 +17,8 @@
 
 MTSAFE
 
-INCLUDES = ../../common/options ../../common/stream $(openssl_CFLAGS)
+INCLUDES = ../../common/options ../../common/stream \
+                  $(openssl_CFLAGS) $(MSGCONTROL_FLAGS)
 
 lib_mapi = {
        VERSION = $(MAPI_VERSION)
diff --git a/configure.ag b/configure.ag
--- a/configure.ag
+++ b/configure.ag
@@ -395,7 +395,11 @@
 case $host in
        *-solaris*)
         dnl Solaris needs this to get msg_control and msg_controllen
-               AC_DEFINE(_XOPEN_SOURCE, 500, [for msg_control and 
msg_controllen])
+               dnl it disables, however, the availability of madvise, which is
+               dnl in use use by GDK, so we cannot just AC_DEFINE this, but
+               dnl rather have to enable it where it is necessary
+               MSGCONTROL_FLAGS="_XOPEN_SOURCE=500"
+               AC_SUBST(MSGCONTROL_FLAGS)
        ;;
 esac
 
diff --git a/monetdb5/modules/mal/Makefile.ag b/monetdb5/modules/mal/Makefile.ag
--- a/monetdb5/modules/mal/Makefile.ag
+++ b/monetdb5/modules/mal/Makefile.ag
@@ -21,7 +21,7 @@
        ../../../common/stream \
        ../../../common/utils \
        ../../../gdk \
-       $(pcre_CFLAGS) $(zlib_CFLAGS) $(BZIP_INCS)
+       $(pcre_CFLAGS) $(zlib_CFLAGS) $(BZIP_INCS) $(MSGCONTROL_FLAGS)
 
 MTSAFE
 
diff --git a/tools/merovingian/daemon/Makefile.ag 
b/tools/merovingian/daemon/Makefile.ag
--- a/tools/merovingian/daemon/Makefile.ag
+++ b/tools/merovingian/daemon/Makefile.ag
@@ -22,7 +22,8 @@
                   ../../../monetdb5/misc \
                   ../../../common/stream \
                   ../../../common/utils \
-                  ../../../clients/mapilib
+                  ../../../clients/mapilib \
+                  $(MSGCONTROL_FLAGS)
 
 EXTRA_DIST = $(man_MANS) \
        merovingian.h \
_______________________________________________
Checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list

Reply via email to