# set glib_binary_age _and_ glib_interface_age to 0.
#
m4_define([glib_major_version], [2])
-m4_define([glib_minor_version], [15])
-m4_define([glib_micro_version], [4])
+m4_define([glib_minor_version], [17])
+m4_define([glib_micro_version], [0])
m4_define([glib_interface_age], [0])
m4_define([glib_binary_age],
[m4_eval(100 * glib_minor_version + glib_micro_version)])
case "$host" in
*-*-mingw*)
glib_native_win32=yes
- GLIB_DEF=glib.def
- GMODULE_DEF=gmodule.def
- GOBJECT_DEF=gobject.def
- GTHREAD_DEF=gthread.def
- TESTGMODULE_EXP=testgmodule.exp
glib_pid_type='void *'
+ # Unfortunately the mingw implementations of C99-style snprintf and vsnprintf
+ # don't seem to be quite good enough, at least not in mingw-runtime-3.14.
+ # (Sorry, I don't know exactly what is the problem, but it is related to
+ # floating point formatting and decimal point vs. comma.)
+ # The simple tests in AC_FUNC_VSNPRINTF_C99 and AC_FUNC_SNPRINTF_C99 aren't
+ # rigorous enough to notice, though.
+ # So preset the autoconf cache variables.
+ ac_cv_func_vsnprintf_c99=no
+ ac_cv_func_snprintf_c99=no
;;
*)
glib_native_win32=no
- GLIB_DEF=
- GMODULE_DEF=
- GOBJECT_DEF=
- GTHREAD_DEF=
- TESTGMODULE_EXP=
glib_pid_type=int
;;
esac
AM_CONDITIONAL(OS_UNIX, [test "$glib_native_win32" != "yes"])
AM_CONDITIONAL(OS_LINUX, [test "$glib_os_linux" = "yes"])
AM_CONDITIONAL(OS_CARBON, [test "$glib_have_carbon" = "yes"])
-AC_SUBST(GLIB_DEF)
-AC_SUBST(GMODULE_DEF)
-AC_SUBST(GOBJECT_DEF)
-AC_SUBST(GTHREAD_DEF)
-AC_SUBST(TESTGMODULE_EXP)
if test "$glib_native_win32" = "yes"; then
AC_CHECK_TOOL(WINDRES, windres, no)
AC_MSG_RESULT([yes])
fi
-if test "$glib_native_win32" = "yes"; then
- if test x$enable_static = xyes -o x$enable_static = x; then
- AC_MSG_WARN([Disabling static library build, must build as DLL on Windows.])
- enable_static=no
- fi
- if test x$enable_shared = xno; then
- AC_MSG_WARN([Enabling shared library build, must build as DLL on Windows.])
- fi
- enable_shared=yes
-fi
-
dnl Checks for programs.
AC_PROG_CC
fi
fi
fi
+GLIB_EXTRA_CFLAGS="${msnative_struct}"
+AC_SUBST(GLIB_EXTRA_CFLAGS)
AC_EXEEXT
esac
fi
+if test "$glib_native_win32" = "yes"; then
+ if test x$enable_static = xyes -a x$enable_shared = xyes; then
+ AC_MSG_ERROR([Can not build both shared and static at the same time on Windows.])
+ fi
+ if test x$enable_static = xyes; then
+ glib_win32_static_compilation=yes
+ GLIB_WIN32_STATIC_COMPILATION_DEFINE="#define GLIB_STATIC_COMPILATION 1
+#define GOBJECT_STATIC_COMPILATION 1"
+ AC_SUBST(GLIB_WIN32_STATIC_COMPILATION_DEFINE)
+ fi
+fi
+AM_CONDITIONAL(OS_WIN32_AND_DLL_COMPILATION, [test x$glib_native_win32 = xyes -a x$glib_win32_static_compilation != xyes])
+
dnl
dnl DU4 native cc currently needs -std1 for ANSI mode (instead of K&R)
dnl
AC_CHECK_FUNCS(atexit on_exit)
-AC_CHECK_FUNCS(timegm)
+AC_CHECK_FUNCS(timegm gmtime_r)
AC_CHECK_SIZEOF(char)
AC_CHECK_SIZEOF(short)
# check for structure fields
AC_CHECK_MEMBERS([struct stat.st_mtimensec, struct stat.st_mtim.tv_nsec, struct stat.st_atimensec, struct stat.st_atim.tv_nsec, struct stat.st_ctimensec, struct stat.st_ctim.tv_nsec])
-AC_CHECK_MEMBERS([struct stat.st_blksize, struct stat.st_blocks])
+AC_CHECK_MEMBERS([struct stat.st_blksize, struct stat.st_blocks, struct statfs.f_fstypename],,, [#include <sys/types.h>
+#include <sys/stat.h>
+#include <unistd.h>
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+#ifdef HAVE_SYS_MOUNT_H
+#include <sys/mount.h>
+#endif])
# Checks for libcharset
jm_LANGINFO_CODESET
# Check for some functions
AC_CHECK_FUNCS(lstat strerror strsignal memmove vsnprintf stpcpy strcasecmp strncasecmp poll getcwd vasprintf setenv unsetenv getc_unlocked readlink symlink fdwalk)
AC_CHECK_FUNCS(chown lchown fchmod fchown link statvfs statfs utimes getgrgid getpwuid)
-AC_CHECK_FUNCS(setmntent endmntent hasmntopt getmntinfo)
+AC_CHECK_FUNCS(getmntent_r setmntent endmntent hasmntopt getmntinfo)
# Check for high-resolution sleep functions
AC_CHECK_FUNCS(nanosleep nsleep)
AM_CONDITIONAL(HAVE_INOTIFY, [test "$inotify_support" = "yes"])
+dnl *********************************
+dnl ** Check for Solaris FEN (GIO) **
+dnl *********************************
+fen_support=no
+AC_COMPILE_IFELSE([
+#include <port.h>
+#ifndef PORT_SOURCE_FILE
+#error "Please upgrade to Nevada 72 or above to suppoert FEN"
+#endif
+int main() { return 0; } ],
+[
+ fen_support=yes
+],)
+
+AM_CONDITIONAL(HAVE_FEN, [test "$fen_support" = "yes"])
+
dnl ****************************
dnl *** Checks for FAM (GIO) ***
dnl ****************************
# we are not doing the following for now, as this might require glib
# to always be linked with the thread libs on some platforms.
# LIBS="$LIBS $G_THREAD_LIBS"
- AC_CHECK_FUNCS(localtime_r)
+ AC_CHECK_FUNCS(localtime_r gmtime_r)
if test "$ac_cv_header_pwd_h" = "yes"; then
AC_CACHE_CHECK([for posix getpwuid_r],
ac_cv_func_posix_getpwuid_r,
libpcre >= $PCRE_REQUIRED_VERSION)
AC_CACHE_CHECK([for Unicode support in PCRE],glib_cv_pcre_has_unicode,[
glib_save_CFLAGS="$CFLAGS"
- glib_save_LDFLAGS="$LDFLAGS"
- CFLAGS="$CFLAGS $PCRE_CFLAGS" LDFLAGS="$LDFLAGS $PCRE_LIBS"
+ glib_save_LIBS="$LIBS"
+ CFLAGS="$CFLAGS $PCRE_CFLAGS" LIBS="$PCRE_LIBS"
AC_TRY_RUN([#include <pcre.h>
int main () {
int support;
glib_cv_pcre_has_unicode=no,
glib_cv_pcre_has_unicode=yes)
CFLAGS="$glib_save_CFLAGS"
- LDFLAGS="$glib_save_LDFLAGS"
+ LIBS="$glib_save_LIBS"
])
if test "$glib_cv_pcre_has_unicode" = "no"; then
AC_MSG_ERROR([*** The system-supplied PCRE does not support Unicode properties or UTF-8.])
$glib_memmove
$glib_defines
$glib_os
+$glib_static_compilation
$glib_vacopy
} static_mutex;
};
#define G_STATIC_MUTEX_INIT { NULL, { { $g_mutex_contents} } }
+#ifdef __cplusplus
#define g_static_mutex_get_mutex(mutex) \\
(g_thread_use_default_impl ? ((GMutex*) ((mutex)->static_mutex.pad)) : \\
g_static_mutex_get_mutex_impl_shortcut (&((mutex)->runtime_mutex)))
+#else
+#define g_static_mutex_get_mutex(mutex) \\
+ (g_thread_use_default_impl ? ((GMutex*) (void*) ((mutex)->static_mutex.pad)) : \\
+ g_static_mutex_get_mutex_impl_shortcut (&((mutex)->runtime_mutex)))
+#endif
_______EOF
else
cat >>$outfile <<_______EOF
glib_os="#define G_OS_UNIX"
;;
esac
+glib_static_compilation=""
+if test x$glib_win32_static_compilation = xyes; then
+ glib_static_compilation="#define GLIB_STATIC_COMPILATION 1
+#define GOBJECT_STATIC_COMPILATION 1"
+fi
])
AC_CONFIG_FILES([
gmodule/gmoduleconf.h
gobject/Makefile
gobject/glib-mkenums
+gobject/tests/Makefile
gthread/Makefile
gio/Makefile
gio/xdgmime/Makefile
gio/inotify/Makefile
+gio/fen/Makefile
gio/fam/Makefile
+gio/win32/Makefile
gio/tests/Makefile
po/Makefile.in
docs/Makefile