X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=configure.in;h=e6b0fefa505200f296f54cf376dde0826b975e31;hb=66a09fa7c3c8e4232b4225c49d01d9efb97458c9;hp=c4e36a9d824791e875b68f6486042ac9b16134be;hpb=f1b9aac417d8fb716d6ed19128fe429e8a41adba;p=platform%2Fupstream%2Fdbus.git diff --git a/configure.in b/configure.in index c4e36a9..e6b0fef 100644 --- a/configure.in +++ b/configure.in @@ -3,7 +3,7 @@ AC_PREREQ(2.52) m4_define([dbus_major_version], [1]) m4_define([dbus_minor_version], [4]) -m4_define([dbus_micro_version], [1]) +m4_define([dbus_micro_version], [3]) m4_define([dbus_version], [dbus_major_version.dbus_minor_version.dbus_micro_version]) AC_INIT(dbus, [dbus_version]) @@ -41,7 +41,7 @@ LT_CURRENT=8 ## increment any time the source changes; set to ## 0 if you increment CURRENT -LT_REVISION=2 +LT_REVISION=3 ## increment if any interfaces have been added; set to 0 ## if any interfaces have been changed or removed. removal has @@ -139,7 +139,7 @@ AC_ARG_ENABLE(console-owner-file, AS_HELP_STRING([--enable-console-owner-file],[ AC_ARG_ENABLE(userdb-cache, AS_HELP_STRING([--enable-userdb-cache],[build with userdb-cache support]),enable_userdb_cache=$enableval,enable_userdb_cache=yes) AC_ARG_ENABLE(launchd, AS_HELP_STRING([--enable-launchd],[build with launchd auto-launch support]),enable_launchd=$enableval,enable_launchd=auto) -AC_ARG_WITH(xml, AS_HELP_STRING([--with-xml=[libxml/expat]],[XML library to use])) +AC_ARG_WITH(xml, AS_HELP_STRING([--with-xml=[libxml/expat]],[XML library to use (libxml may be named libxml2 on some systems)])) AC_ARG_WITH(init-scripts, AS_HELP_STRING([--with-init-scripts=[redhat]],[Style of init scripts to install])) AC_ARG_WITH(session-socket-dir, AS_HELP_STRING([--with-session-socket-dir=[dirname]],[Where to put sockets for the per-login-session message bus])) AC_ARG_WITH(test-socket-dir, AS_HELP_STRING([--with-test-socket-dir=[dirname]],[Where to put sockets for make check])) @@ -302,7 +302,7 @@ AC_MSG_CHECKING([32-bit integer type]) case 4 in $ac_cv_sizeof_short) - dbusint32=int + dbusint32=short ;; $ac_cv_sizeof_int) dbusint32=int @@ -532,6 +532,8 @@ closedir(dirp); fi fi +AC_CHECK_HEADERS(sys/resource.h) + AC_CHECK_HEADERS(dirent.h) AC_CHECK_HEADERS(execinfo.h, [AC_CHECK_FUNCS(backtrace)]) @@ -694,6 +696,7 @@ AC_CACHE_CHECK([abstract socket namespace], #include ]], [[ + size_t slen; int listen_fd; struct sockaddr_un addr; @@ -708,9 +711,13 @@ AC_CACHE_CHECK([abstract socket namespace], memset (&addr, '\0', sizeof (addr)); addr.sun_family = AF_UNIX; strcpy (addr.sun_path, "X/tmp/dbus-fake-socket-path-used-in-configure-test"); + /* SUN_LEN uses strlen() so need to calculate it before adding \0 at the + * beginning. + */ + slen = SUN_LEN(&addr); addr.sun_path[0] = '\0'; /* this is what makes it abstract */ - if (bind (listen_fd, (struct sockaddr*) &addr, SUN_LEN (&addr)) < 0) + if (bind (listen_fd, (struct sockaddr*) &addr, slen) < 0) { fprintf (stderr, "Abstract socket namespace bind() failed: %s\n", strerror (errno)); @@ -1038,7 +1045,7 @@ AC_SUBST(DBUS_CLIENT_CFLAGS) AC_SUBST(DBUS_CLIENT_LIBS) DBUS_BUS_CFLAGS="$XML_CFLAGS" -DBUS_BUS_LIBS="$XML_LIBS $SELINUX_LIBS $INTLLIBS $THREAD_LIBS $ADT_LIBS $NETWORK_libs" +DBUS_BUS_LIBS="$XML_LIBS $SELINUX_LIBS $THREAD_LIBS $ADT_LIBS $NETWORK_libs" AC_SUBST(DBUS_BUS_CFLAGS) AC_SUBST(DBUS_BUS_LIBS) @@ -1085,17 +1092,13 @@ fi #### gcc warning flags cc_supports_flag() { - AC_MSG_CHECKING(whether $CC supports "$@") - Cfile=/tmp/foo${$} - touch ${Cfile}.c - $CC -c "$@" ${Cfile}.c -o ${Cfile}.o >/dev/null 2>&1 - rc=$? - rm -f ${Cfile}.c ${Cfile}.o - case $rc in - 0) AC_MSG_RESULT(yes);; - *) AC_MSG_RESULT(no);; - esac - return $rc + AC_MSG_CHECKING(whether $CC supports "$*") + save_CFLAGS="$CFLAGS" + CFLAGS="$*" + AC_TRY_COMPILE([], [], [rc=yes], [rc=no]) + CFLAGS="$save_CFLAGS" + AC_MSG_RESULT([$rc]) + test "x$rc" = xyes } ld_supports_flag() { @@ -1174,7 +1177,7 @@ if test "x$GCC" = "xyes"; then case " $CFLAGS " in *[\ \ ]-Wfloat-equal[\ \ ]*) ;; - *) if cc_supports_flag -Wfloat-equals; then + *) if cc_supports_flag -Wfloat-equal; then CFLAGS="$CFLAGS -Wfloat-equal" fi ;; @@ -1306,11 +1309,10 @@ AC_SUBST(SECTION_FLAGS) AC_SUBST(SECTION_LDFLAGS) AC_MSG_RESULT($ac_gcsections) -# Add -D_POSIX_PTHREAD_SEMANTICS if on Solaris -# case $host_os in solaris*) - CFLAGS="$CFLAGS -D_POSIX_PTHREAD_SEMANTICS" ;; + # Solaris' C library apparently needs these runes to be threadsafe... + CFLAGS="$CFLAGS -D_POSIX_PTHREAD_SEMANTICS -D_REENTRANT" esac changequote(,)dnl @@ -1697,7 +1699,6 @@ echo " Building XML docs: ${enable_xml_docs} Building cache support: ${enable_userdb_cache} Building launchd support: ${have_launchd} - Gettext libs (empty OK): ${INTLLIBS} Using XML parser: ${with_xml} Init scripts style: ${with_init_scripts} Abstract socket names: ${ac_cv_have_abstract_sockets}