1
dnl =======================================================
2
dnl FILE: ./admin/configure.in.min
3
dnl =======================================================
5
dnl This file is part of the KDE libraries/packages
6
dnl Copyright (C) 2001 Stephan Kulow (coolo@kde.org)
8
dnl This file is free software; you can redistribute it and/or
9
dnl modify it under the terms of the GNU Library General Public
10
dnl License as published by the Free Software Foundation; either
11
dnl version 2 of the License, or (at your option) any later version.
13
dnl This library is distributed in the hope that it will be useful,
14
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
15
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16
dnl Library General Public License for more details.
18
dnl You should have received a copy of the GNU Library General Public License
19
dnl along with this library; see the file COPYING.LIB. If not, write to
20
dnl the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21
dnl Boston, MA 02110-1301, USA.
23
# Original Author was Kalle@kde.org
24
# I lifted it in some mater. (Stephan Kulow)
25
# I used much code from Janos Farkas
27
dnl Process this file with autoconf to produce a configure script.
29
AC_INIT(acinclude.m4) dnl a source file from your sub dir
31
dnl This is so we can use kde-common
32
AC_CONFIG_AUX_DIR(admin)
34
dnl This ksh/zsh feature conflicts with `cd blah ; pwd`
37
dnl Checking host/target/build systems, for make, install etc.
39
dnl Perform program name transformation
42
dnl Automake doc recommends to do this only here. (Janos)
43
AM_INIT_AUTOMAKE(knetworkmanager-0.2, "3.5.7") dnl searches for some needed programs
47
dnl generate the config header
48
AM_CONFIG_HEADER(config.h) dnl at the distribution this done
50
dnl Checks for programs.
56
dnl for NLS support. Call them in this order!
57
dnl WITH_NLS is for the po files
62
dnl =======================================================
63
dnl FILE: configure.in.in
64
dnl =======================================================
67
CXXFLAGS="$CXXFLAGS $KDE_DEFAULT_CXXFLAGS"
69
if test "$build_arts" = "yes"; then
70
AC_DEFINE(USE_ARTS, 1, [If we use arts volume])
75
KDE_INIT_DOXYGEN([KEG Network API Reference], [Version $VERSION])
77
dnl =======================================================
78
dnl FILE: ./knetworkmanager/configure.in.in
79
dnl =======================================================
81
dnl dnl PACKAGE set before
84
AC_CHECK_KDEMAXPATHLEN
86
KNETWORKMANAGER_VERSION="0.2"
87
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_VERSION, $KNETWORKMANAGER_VERSION, [KNetworkManager Version])
88
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_VERSION_STRING, "$KNETWORKMANAGER_VERSION", [KNetworkManager Version String])
90
# test if variables are already set
91
test "x$prefix" = xNONE && prefix=$ac_default_prefix
93
# check for dbus, hal, libnm-util and libnl
94
PKG_CHECK_MODULES(DBUS, [dbus-1 >= 0.33], [], [
96
AC_MSG_WARN([You need D-Bus, knetworkmanager will not be compiled])
97
DO_NOT_COMPILE="$DO_NOT_COMPILE knetworkmanager"
98
MISSING_DEPS="$MISSING_DEPS dbus-1"
100
PKG_CHECK_MODULES(HAL, [hal], [], [
102
AC_MSG_WARN([You need Hal, knetworkmanager will not be compiled])
103
DO_NOT_COMPILE="$DO_NOT_COMPILE knetworkmanager"
104
MISSING_DEPS="$MISSING_DEPS hal"
106
PKG_CHECK_MODULES(LIBNMUTIL, [libnm-util], [], [
108
AC_MSG_WARN([You need libnm-util, knetworkmanager will not be compiled])
109
DO_NOT_COMPILE="$DO_NOT_COMPILE knetworkmanager"
110
MISSING_DEPS="$MISSING_DEPS libnm-util"
112
PKG_CHECK_MODULES(LIBNL, [libnl-1], [], [
114
AC_MSG_WARN([You need libnl, knetworkmanager will not be compiled])
115
DO_NOT_COMPILE="$DO_NOT_COMPILE knetworkmanager"
116
MISSING_DEPS="$MISSING_DEPS libnl-1"
119
PACKAGE_CFLAGS="$DBUS_CFLAGS $HAL_CFLAGS $LIBNMUITL_CFLAGS $LIBNL_CFLAGS"
120
PACKAGE_LIBS="$DBUS_LIBS $HAL_LIBS $LIBNMUTIL_LIBS $LIBNL_LIBS"
122
AC_ARG_WITH(dbus-sys, AC_HELP_STRING([--with-dbus-sys=DIR], [D-BUS system.d directory]))
123
if ! test -z "$with_dbus_sys" ; then
124
DBUS_SYS_DIR="$with_dbus_sys"
126
DBUS_SYS_DIR="${sysconfdir}/dbus-1/system.d"
128
AC_SUBST(DBUS_SYS_DIR)
129
AC_DEFINE_UNQUOTED(DBUS_SYSTEMD_DIR, "$DBUS_SYS_DIR", [D-BUS system.d directory])
131
AC_SUBST(PACKAGE_CFLAGS)
132
AC_SUBST(PACKAGE_LIBS)
135
# Check for D-Bus Qt3 bindings
137
safe_CPPFLAGS=$CPPFLAGS
138
CPPFLAGS="$CPPFLAGS $PACKAGE_CFLAGS $all_includes"
144
AC_CHECK_HEADER([dbus/connection.h],,[
145
AC_MSG_WARN([You need D-Bus/Qt3 bindings])
146
DO_NOT_COMPILE="$DO_NOT_COMPILE knetworkmanager"
149
AC_MSG_CHECKING([for phase2 authentication support in NetworkManager])
150
AC_TRY_COMPILE([#include <NetworkManager/NetworkManager.h>]
151
, [#ifdef NM_PHASE2_AUTH_NONE
156
, [AC_MSG_RESULT([yes])
157
AC_DEFINE([HAVE_PHASE2_AUTH], [], [Enable phase2 authentication])
159
, [AC_MSG_RESULT([no])])
162
AC_CHECK_FUNC([nmu_security_serialize_leap_with_cipher], [AC_DEFINE([HAVE_LEAP], [], [Enable Leap support])])
164
CPPFLAGS=$safe_CPPFLAGS
168
AC_ARG_WITH(distro, AC_HELP_STRING([--with-distro=DISTRO], [Specify the Linux distribution to target: suse]))
169
if test "x$with_distro" = "x"; then
170
AC_CHECK_FILE(/etc/SuSE-release,with_distro="suse")
171
if test "x$with_distro" = "x"; then
172
with_distro=`lsb_release -is`
176
with_distro=`echo ${with_distro} | tr '[[:upper:]]' '[[:lower:]]' `
178
if test "x$with_distro" = "x"; then
179
echo "Linux distribution autodetection failed, you must specify the distribution to target using --with-distro=DISTRO"
183
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_DIALUP_CONFIG, "kdesu --nonewdcop /sbin/yast2 modem", [Command to launch dial up configuration tool])
186
echo "Your distribution (${with_distro}) is not yet supported (e.g. you will not be able to launch a tool to configure dial-up connections.)"
193
AC_ARG_WITH(openvpn, AC_HELP_STRING([--with-openvpn], [Build KNetworkManager with openvpn plugin]))
194
if test "x$with_openvpn" = "x"; then
195
AC_CHECK_FILE(/etc/NetworkManager/VPN/nm-openvpn-service.name,with_openvpn="yes" )
197
AM_CONDITIONAL(WITH_OPENVPN, test x"$with_openvpn" != x)
201
AC_ARG_WITH(vpnc, AC_HELP_STRING([--with-vpnc], [Build KNetworkManager with vpnc plugin]))
202
if test "x$with_vpnc" = "x"; then
203
AC_CHECK_FILE(/etc/NetworkManager/VPN/nm-vpnc-service.name,with_vpnc="yes" )
205
AM_CONDITIONAL(WITH_VPNC, test x"$with_vpnc" != x)
209
AC_ARG_WITH(pptp, AC_HELP_STRING([--with-pptp], [Build KNetworkManager with pptp plugin]))
210
if test "x$with_pptp" = "x"; then
211
AC_CHECK_FILE(/etc/NetworkManager/VPN/nm-pptp-service.name,with_pptp="yes" )
213
AM_CONDITIONAL(WITH_PPTP, test x"$with_pptp" != x)
215
# set include path for knetworkmanager-plugin.h and knetworkmanager-vpnplugin.h when vpn plugins are built together with knetworkmanager
217
KNETWORKMANAGER_CFLAGS="-I\$(top_srcdir)/knetworkmanager/src"
218
AC_SUBST(KNETWORKMANAGER_CFLAGS)
219
dnl =======================================================
220
dnl FILE: ./knetworkmanager/vpn-plugins/openvpn/configure.in.in
221
dnl =======================================================
223
KNETWORKMANAGER_OPENVPN_VERSION=0.1
224
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_OPENVPN_VERSION, $KNETWORKMANAGER_OPENVPN_VERSION, [KNetworkManager OpenVPN Plugin Version])
225
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_OPENVPN_VERSION_STRING, "$KNETWORKMANAGER_OPENVPN_VERSION", [KNetworkManager OpenVPN Plugin Version String])
228
dnl =======================================================
229
dnl FILE: ./knetworkmanager/vpn-plugins/pptp/configure.in.in
230
dnl =======================================================
232
KNETWORKMANAGER_PPTP_VERSION=0.1
233
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_PPTP_VERSION, $KNETWORKMANAGER_PPTP_VERSION, [KNetworkManager PPTP Plugin Version])
234
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_PPTP_VERSION_STRING, "$KNETWORKMANAGER_PPTP_VERSION", [KNetworkManager PPTP Plugin Version String])
237
dnl =======================================================
238
dnl FILE: ./knetworkmanager/vpn-plugins/vpnc/configure.in.in
239
dnl =======================================================
241
KNETWORKMANAGER_VPNC_VERSION=0.1
242
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_VPNC_VERSION, $KNETWORKMANAGER_VPNC_VERSION, [KNetworkManager VPNC Plugin Version])
243
AC_DEFINE_UNQUOTED(KNETWORKMANAGER_VPNC_VERSION_STRING, "$KNETWORKMANAGER_VPNC_VERSION", [KNetworkManager VPNC Plugin Version String])
246
KDE_CREATE_SUBDIRSLIST
247
AM_CONDITIONAL(knetworkmanager_SUBDIR_included, test "x$knetworkmanager_SUBDIR_included" = xyes)
248
AM_CONDITIONAL(po_SUBDIR_included, test "x$po_SUBDIR_included" = xyes)
249
AC_CONFIG_FILES([ Makefile ])
250
AC_CONFIG_FILES([ knetworkmanager/Makefile ])
251
AC_CONFIG_FILES([ knetworkmanager/pics/Makefile ])
252
AC_CONFIG_FILES([ knetworkmanager/src/Makefile ])
253
AC_CONFIG_FILES([ knetworkmanager/vpn-plugins/Makefile ])
254
AC_CONFIG_FILES([ knetworkmanager/vpn-plugins/openvpn/Makefile ])
255
AC_CONFIG_FILES([ knetworkmanager/vpn-plugins/openvpn/src/Makefile ])
256
AC_CONFIG_FILES([ knetworkmanager/vpn-plugins/pptp/Makefile ])
257
AC_CONFIG_FILES([ knetworkmanager/vpn-plugins/pptp/src/Makefile ])
258
AC_CONFIG_FILES([ knetworkmanager/vpn-plugins/vpnc/Makefile ])
259
AC_CONFIG_FILES([ knetworkmanager/vpn-plugins/vpnc/src/Makefile ])
260
AC_CONFIG_FILES([ po/Makefile ])
261
AC_CONFIG_FILES([ po/ar/Makefile ])
262
AC_CONFIG_FILES([ po/bg/Makefile ])
263
AC_CONFIG_FILES([ po/br/Makefile ])
264
AC_CONFIG_FILES([ po/ca/Makefile ])
265
AC_CONFIG_FILES([ po/cs/Makefile ])
266
AC_CONFIG_FILES([ po/da/Makefile ])
267
AC_CONFIG_FILES([ po/de/Makefile ])
268
AC_CONFIG_FILES([ po/el/Makefile ])
269
AC_CONFIG_FILES([ po/es/Makefile ])
270
AC_CONFIG_FILES([ po/et/Makefile ])
271
AC_CONFIG_FILES([ po/fi/Makefile ])
272
AC_CONFIG_FILES([ po/fr/Makefile ])
273
AC_CONFIG_FILES([ po/ga/Makefile ])
274
AC_CONFIG_FILES([ po/gl/Makefile ])
275
AC_CONFIG_FILES([ po/hu/Makefile ])
276
AC_CONFIG_FILES([ po/it/Makefile ])
277
AC_CONFIG_FILES([ po/ja/Makefile ])
278
AC_CONFIG_FILES([ po/ka/Makefile ])
279
AC_CONFIG_FILES([ po/km/Makefile ])
280
AC_CONFIG_FILES([ po/nb/Makefile ])
281
AC_CONFIG_FILES([ po/nl/Makefile ])
282
AC_CONFIG_FILES([ po/pa/Makefile ])
283
AC_CONFIG_FILES([ po/pl/Makefile ])
284
AC_CONFIG_FILES([ po/pt/Makefile ])
285
AC_CONFIG_FILES([ po/ru/Makefile ])
286
AC_CONFIG_FILES([ po/sk/Makefile ])
287
AC_CONFIG_FILES([ po/sl/Makefile ])
288
AC_CONFIG_FILES([ po/sv/Makefile ])
289
AC_CONFIG_FILES([ po/tr/Makefile ])
290
AC_CONFIG_FILES([ po/uk/Makefile ])
291
AC_CONFIG_FILES([ po/zh_CN/Makefile ])
292
AC_CONFIG_FILES([ po/zh_TW/Makefile ])
294
if test -n "$MISSING_DEPS"; then
296
echo "**************************************************"
298
echo "* KNetworkManager will not be built due to missing dependencies!"
299
echo "* Missing: $MISSING_DEPS"
301
echo "**************************************************"
304
# Check if KDE_SET_PREFIX was called, and --prefix was passed to configure
305
if test -n "$kde_libs_prefix" -a -n "$given_prefix"; then
306
# And if so, warn when they don't match
307
if test "$kde_libs_prefix" != "$given_prefix"; then
308
# And if kde doesn't know about the prefix yet
309
echo ":"`kde-config --path exe`":" | grep ":$given_prefix/bin/:" 2>&1 >/dev/null
310
if test $? -ne 0; then
312
echo "Warning: you chose to install this package in $given_prefix,"
313
echo "but KDE was found in $kde_libs_prefix."
314
echo "For this to work, you will need to tell KDE about the new prefix, by ensuring"
315
echo "that KDEDIRS contains it, e.g. export KDEDIRS=$given_prefix:$kde_libs_prefix"
316
echo "Then restart KDE."
322
if test x$GXX = "xyes" -a x$kde_have_gcc_visibility = "xyes" -a x$kde_cv_val_qt_gcc_visibility_patched = "xno"; then
324
echo "Your GCC supports symbol visibility, but the patch for Qt supporting visibility"
325
echo "was not included. Therefore, GCC symbol visibility support remains disabled."
327
echo "For better performance, consider including the Qt visibility supporting patch"
330
echo "http://bugs.kde.org/show_bug.cgi?id=109386"
332
echo "and recompile all of Qt and KDE. Note, this is entirely optional and"
333
echo "everything will continue to work just fine without it."
337
if test "$all_tests" = "bad"; then
338
if test ! "$cache_file" = "/dev/null"; then
340
echo "Please remove the file $cache_file after changing your setup"
341
echo "so that configure will find the changes next time."
346
echo "Good - your configure finished. Start make now"