fi
AC_LANG_PUSH(C)
-dnl solaris has some odd defines it needs in order to propperly compile ctime_r
+dnl solaris has some odd defines it needs in order to properly compile ctime_r
AC_MSG_CHECKING([if ctime_r need special care to act posixly correct])
AC_LINK_IFELSE(
[AC_LANG_PROGRAM(
fi
+# Check for MinGW-w64 build and pass to automake
+build_mingw_w64=no
+AC_MSG_CHECKING([for MinGW-w64 build])
+case "$host" in
+ *w64-mingw32*)
+ AC_MSG_RESULT([yes])
+ build_mingw_w64=yes
+ ;;
+ *)
+ AC_MSG_RESULT([no])
+ ;;
+esac
+# Pass the conditional to automake
+AM_CONDITIONAL([MINGW_W64], [test "$build_mingw_w64" = "yes"])
+
# systemd check
PKG_PROG_PKG_CONFIG
AC_ARG_WITH([systemdsystemunitdir],
## Process this file with automake to produce Makefile.in
-#AUTOMAKE_OPTIONS = foreign
+AUTOMAKE_OPTIONS = subdir-objects
#
#ACLOCAL_M4 = $(top_srcdir)/config/aclocal.m4
#AUTOHEADER = @AUTOHEADER@ --localdir=$(top_srcdir)/config
noinst_HEADERS = \
unused.h \
- gettext.h \
+ gettext.h \
mutex.h \
- rrd_strtod.h \
+ rrd_strtod.h \
rrd_snprintf.h \
rrd_parsetime.h \
rrd_config_bottom.h rrd_i18n.h \
noinst_HEADERS += rrd_rados.h
endif
+if MINGW_W64
+RRD_C_FILES += ../win32/win32-glob.c
+noinst_HEADERS += ../win32/win32-glob.h
+endif
+
noinst_LTLIBRARIES = librrdupd.la
-lib_LTLIBRARIES = librrd.la
+lib_LTLIBRARIES = librrd.la
librrdupd_la_SOURCES = $(UPD_C_FILES)
librrdupd_la_LIBADD = $(CORE_LIBS)
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = librrd.pc
-# strftime is here because we do not usually need it. unices have propper
+# strftime is here because we do not usually need it. unices have proper
# iso date support
EXTRA_DIST= librrd.pc.in strftime.c strftime.h \
win32comp.c rrd_thread_safe_nt.c get_ver.awk librrd.sym plbasename.c plbasename.h