summaryrefslogtreecommitdiffstats
path: root/configure.in.in
diff options
context:
space:
mode:
authortoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
committertoma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2009-11-25 17:56:58 +0000
commit460c52653ab0dcca6f19a4f492ed2c5e4e963ab0 (patch)
tree67208f7c145782a7e90b123b982ca78d88cc2c87 /configure.in.in
downloadtdepim-460c52653ab0dcca6f19a4f492ed2c5e4e963ab0.tar.gz
tdepim-460c52653ab0dcca6f19a4f492ed2c5e4e963ab0.zip
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'configure.in.in')
-rw-r--r--configure.in.in138
1 files changed, 138 insertions, 0 deletions
diff --git a/configure.in.in b/configure.in.in
new file mode 100644
index 000000000..cd92d3cb2
--- /dev/null
+++ b/configure.in.in
@@ -0,0 +1,138 @@
+#MIN_CONFIG(3.3)
+AC_HEADER_DIRENT
+AC_HEADER_STDC
+AC_CHECK_HEADERS(fcntl.h sys/sysctl.h sys/param.h sys/time.h sys/types.h unistd.h values.h sys/limits.h err.h sys/cdefs.h)
+
+AC_CHECK_SETENV
+AC_CHECK_UNSETENV
+
+KDE_NEED_FLEX
+
+if test "$x_includes" != "NONE"; then
+ AC_DEFINE(HAVE_X11_HEADERS,1,Define if you have X11 header files)
+fi
+AC_CHECK_LIB(Xtst, XTestFakeKeyEvent, [LIBXTST=-lXtst],, -lX11)
+AC_SUBST(LIBXTST)
+if test "$LIBXTST" != ""; then
+ AC_CHECK_HEADER([X11/extensions/XTest.h],
+ [AC_DEFINE(HAVE_XTEST, 1, [Define if you have X11 Xtest header files])])
+fi
+
+KDE_INIT_DOXYGEN([KDE PIM API Reference], [Version $VERSION])
+
+KDE_CHECK_THREADING
+
+dnl For apps that NEED threads
+if test -z "$LIBPTHREAD" && test -z "$USE_THREADS"; then
+ DO_NOT_COMPILE="$DO_NOT_COMPILE knode"
+fi
+
+CXXFLAGS="$CXXFLAGS $KDE_DEFAULT_CXXFLAGS"
+
+# check for libbluetooth (Bluetooth library) because gnokii may require it
+AC_DEFUN([KDE_CHECK_BLUETOOTH],
+[
+ AC_CHECK_HEADERS(bluetooth/bluetooth.h)
+ LIB_BLUETOOTH=
+ AC_CHECK_LIB(bluetooth, hci_open_dev,
+ [ LIB_BLUETOOTH="-lbluetooth" ],
+ [],
+ [] )
+ AC_SUBST(LIB_BLUETOOTH)
+])
+
+
+# check for libgnokii (Nokia mobile phone library)
+AC_DEFUN([KDE_CHECK_GNOKII],
+[
+ KDE_CHECK_HEADERS(gnokii.h)
+ AC_REQUIRE([AC_HAVE_XPM])
+ AC_CHECK_LIB(gnokii, gn_cfg_read,
+ [ LIB_GNOKII="-lgnokii $LIB_BLUETOOTH" ],
+ [
+ AC_CHECK_LIB(gnokii, gn_cfg_get,
+ [ LIB_GNOKII="-lgnokii -lintl $LIB_BLUETOOTH" ],
+ [], $all_libraries -lintl -lXpm -lX11 $LIB_BLUETOOTH )
+ ],
+ $all_libraries -lXpm -lX11 $LIB_BLUETOOTH )
+ AC_SUBST(LIB_GNOKII)
+])
+
+AC_ARG_WITH(gnokii,
+ [AC_HELP_STRING(--with-gnokii,
+ [enable support for mobile phones through gnokii @<:@default=check@:>@])],
+ [], with_gnokii=check)
+
+LIB_GNOKII=
+if test "x$with_gnokii" != xno; then
+ # for kaddressbook/xxport/ and kmobile/devices/gnokii/
+ KDE_CHECK_BLUETOOTH
+ KDE_CHECK_GNOKII
+
+ if test "x$with_gnokii" != xcheck && test -z "$LIB_GNOKII"; then
+ AC_MSG_ERROR([--with-gnokii was given, but test for gnokii failed])
+ fi
+fi
+
+dnl Checks for header files.
+AC_CHECK_HEADERS(sys/cdefs.h) dnl for libkholidays/lunarphase.cpp
+AC_CHECK_HEADERS(sys/ioctl.h) dnl for kandy/src/modem.cpp
+AC_CHECK_HEADERS(sys/file.h sys/stat.h sys/time.h byteswap.h) dnl for at least kmail
+
+dnl the below is copied from kdenetwork's configure as too many apps moved
+dnl and noone can say which tests are needed and which are obsolete for kdepim ;(
+
+AC_CHECK_HEADERS(fcntl.h unistd.h sysent.h strings.h paths.h)
+
+dnl unused AC_CHECK_HEADER([resolv.h],,,[#include <netinet/in.h>])
+
+KDE_CHECK_LARGEFILE
+
+AC_CHECK_USLEEP
+
+dnl Checks for library functions.
+AC_CHECK_FUNCS(socket fabsl strdup vsnprintf tzset)
+AC_CHECK_GETDOMAINNAME
+AC_CHECK_GETHOSTNAME
+AC_C_BIGENDIAN
+
+AC_CHECK_RES_INIT
+
+dnl needed by libkmime
+AC_CACHE_CHECK(for timezone variable, ac_cv_var_timezone,
+ AC_TRY_COMPILE([
+ #include <time.h>
+ ], [
+ timezone = 1;
+ ], ac_cv_var_timezone=yes, ac_cv_var_timezone=no))
+if test $ac_cv_var_timezone = yes; then
+ AC_DEFINE(HAVE_TIMEZONE, 1, [define if you have a timezone variable])
+fi
+
+dnl needed by libkmime
+AC_CACHE_CHECK(for tm_gmtoff in struct tm, ac_cv_struct_tm_gmtoff,
+ AC_TRY_COMPILE([
+ #include <time.h>
+ ], [
+ struct tm tm;
+ tm.tm_gmtoff = 1;
+ ], ac_cv_struct_tm_gmtoff=yes, ac_cv_struct_tm_gmtoff=no))
+if test $ac_cv_struct_tm_gmtoff = yes; then
+ AC_DEFINE(HAVE_TM_GMTOFF, 1, [Define if you have a tm_gmtoff member in struct tm])
+fi
+
+AC_LANG_PUSH(C++)
+AC_CACHE_CHECK(for stl coping with namespace std, ac_cv_var_stlnamespace,
+ AC_TRY_COMPILE([
+ #include <iterator>
+ struct s : public std::iterator<std::forward_iterator_tag, int> {};
+ ], [
+ ], ac_cv_var_stlnamespace=yes, ac_cv_var_stlnamespace=no))
+if test $ac_cv_var_stlnamespace = yes; then
+ AC_DEFINE(HAVE_STLNAMESPACE, 1, [Define if your version of stl is defined in namespace std])
+ AC_DEFINE(STD_NAMESPACE_PREFIX, [std::], [Namespace prefix the stl is defined in])
+else
+ AC_DEFINE(STD_NAMESPACE_PREFIX, [], [Namespace prefix the stl is defined in])
+fi
+
+AC_LANG_POP