configure.ac.in 10.7 KB
Newer Older
1 2 3
# vi:set et ai sw=2 sts=2 ts=2: */
#-
# Copyright (c) 2004-2007 Benedikt Meurer <benny@xfce.org>
Jannis Pohlmann's avatar
Jannis Pohlmann committed
4
# Copyright (c) 2009-2011 Jannis Pohlmann <jannis@xfce.org>
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
#
# This program is free software; you can redistribute it and/or 
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 2 of 
# the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public 
# License along with this program; if not, write to the Free 
# Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
20

21 22 23
dnl ***************************
dnl *** Version information ***
dnl ***************************
24 25
m4_define([thunarx_verinfo], [0:0:0])
m4_define([thunarx_version_api], [2])
Stephan Arts's avatar
Stephan Arts committed
26
m4_define([thunar_version_major], [1])
Nick Schermer's avatar
Nick Schermer committed
27
m4_define([thunar_version_minor], [6])
Andrzej's avatar
Andrzej committed
28
m4_define([thunar_version_micro], [4])
Stephan Arts's avatar
Stephan Arts committed
29
m4_define([thunar_version_nano], [])
30
m4_define([thunar_version_build], [@REVISION@])
Andrzej's avatar
Andrzej committed
31
m4_define([thunar_version_tag], [git])
32
m4_define([thunar_version], [thunar_version_major().thunar_version_minor().thunar_version_micro()ifelse(thunar_version_nano(), [], [], [.thunar_version_nano()])ifelse(thunar_version_tag(), [git], [thunar_version_tag()-thunar_version_build()], [thunar_version_tag()])])
33

34
dnl *******************************************
Nick Schermer's avatar
Nick Schermer committed
35
dnl *** Debugging support for GIT snapshots ***
36
dnl *******************************************
37
m4_define([thunar_debug_default], [ifelse(thunar_version_tag(), [git], [yes], [minimum])])
38

39 40 41
dnl ***************************
dnl *** Initialize autoconf ***
dnl ***************************
Nick Schermer's avatar
Nick Schermer committed
42
AC_COPYRIGHT([Copyright (c) 2004-2012 The Thunar development team. All rights reserved.])
43
AC_INIT([Thunar], [thunar_version], [http://bugzilla.xfce.org/], [Thunar])
Harald Judt's avatar
Harald Judt committed
44 45
AC_PREREQ([2.60])
AC_CONFIG_MACRO_DIR([m4])
46
AC_CANONICAL_TARGET()
47 48
AC_REVISION([$Id$])

49 50 51
dnl ***************************
dnl *** Initialize automake ***
dnl ***************************
52
AM_INIT_AUTOMAKE([1.8 dist-bzip2 tar-ustar no-dist-gzip])
Nick Schermer's avatar
Nick Schermer committed
53
AC_CONFIG_HEADERS([config.h])
54
AM_MAINTAINER_MODE()
55
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
56

57 58 59
dnl *******************************
dnl *** Check for UNIX variants ***
dnl *******************************
60 61 62 63
AC_AIX()
AC_ISC_POSIX()
AC_MINIX()

64 65 66 67
if test "x$target_os" = "xlinux-gnu"; then
  AC_DEFINE([HAVE_LINUX], [], [Whether we are building on Linux or not])
fi

68 69 70
dnl ********************************
dnl *** Check for basic programs ***
dnl ********************************
71
AC_PROG_CC()
72
AC_PROG_LD()
73
AM_PROG_CC_C_O()
74
AC_PROG_INSTALL()
Eric Koegel's avatar
Eric Koegel committed
75
IT_PROG_INTLTOOL()
76
AC_CHECK_PROGS([PERL], [perl5 perl])
77
m4_ifdef([AC_PROG_SED], [AC_PROG_SED], [AC_CHECK_PROG(SED, sed, sed)])
78 79 80 81

dnl **************************
dnl *** Initialize libtool ***
dnl **************************
82 83
LT_PREREQ([2.2.6])
LT_INIT([disable-static])
84

85 86 87
dnl **************************************
dnl *** Substitute version information ***
dnl **************************************
88 89
THUNARX_VERINFO=thunarx_verinfo()
THUNARX_VERSION_API=thunarx_version_api()
90 91 92
THUNAR_VERSION_MAJOR=thunar_version_major()
THUNAR_VERSION_MINOR=thunar_version_minor()
THUNAR_VERSION_MICRO=thunar_version_micro()
93 94
AC_SUBST([THUNARX_VERINFO])
AC_SUBST([THUNARX_VERSION_API])
95 96 97
AC_SUBST([THUNAR_VERSION_MAJOR])
AC_SUBST([THUNAR_VERSION_MINOR])
AC_SUBST([THUNAR_VERSION_MICRO])
98

99 100 101 102 103 104 105 106 107 108
dnl ******************************
dnl *** Set helper path prefix ***
dnl ******************************
AC_ARG_WITH([helper-path-prefix],
            [AC_HELP_STRING([--with-helper-path-prefix=PATH],
                            [Path prefix under which helper executables will be installed (default: $libdir)])],
            [HELPER_PATH_PREFIX="$withval"],
            [HELPER_PATH_PREFIX="$libdir"])
AC_SUBST([HELPER_PATH_PREFIX])

109 110 111 112 113
dnl ***********************************************
dnl *** Work-around system-specific limitations ***
dnl ***********************************************
AC_SYS_LARGEFILE()

114 115 116
dnl **********************************
dnl *** Check for standard headers ***
dnl **********************************
117 118
AC_CHECK_HEADERS([ctype.h errno.h fcntl.h grp.h limits.h locale.h memory.h \
                  paths.h pwd.h sched.h signal.h stdarg.h stdlib.h string.h \
119 120
                  sys/mman.h sys/param.h sys/stat.h sys/time.h sys/types.h \
                  sys/uio.h sys/wait.h time.h])
121

122 123 124
dnl ************************************
dnl *** Check for standard functions ***
dnl ************************************
125
AC_FUNC_MMAP()
126
AC_CHECK_FUNCS([localeconv mkdtemp pread pwrite sched_yield setgroupent \
Nick Schermer's avatar
Nick Schermer committed
127
                setpassent strcoll strlcpy strptime symlink atexit])
128

Benedikt Meurer's avatar
 
Benedikt Meurer committed
129 130 131
dnl ******************************
dnl *** Check for i18n support ***
dnl ******************************
132
XDT_I18N([@LINGUAS@])
Benedikt Meurer's avatar
 
Benedikt Meurer committed
133

134 135 136 137 138
dnl *********************
dnl *** Check for X11 ***
dnl *********************
XDT_CHECK_LIBX11_REQUIRE()

139 140 141
dnl ***********************************
dnl *** Check for required packages ***
dnl ***********************************
Nick Schermer's avatar
Nick Schermer committed
142
XDT_CHECK_PACKAGE([EXO], [exo-1], [0.10.0])
143 144 145 146
XDT_CHECK_PACKAGE([GLIB], [glib-2.0], [2.30.0])
XDT_CHECK_PACKAGE([GIO], [gio-2.0], [2.30.0])
XDT_CHECK_PACKAGE([GTHREAD], [gthread-2.0], [2.30.0])
XDT_CHECK_PACKAGE([GMODULE], [gmodule-2.0], [2.30.0])
147
XDT_CHECK_PACKAGE([GTK], [gtk+-2.0], [2.24.0])
148
XDT_CHECK_PACKAGE([GDK_PIXBUF], [gdk-pixbuf-2.0], [2.14.0])
Nick Schermer's avatar
Nick Schermer committed
149 150
XDT_CHECK_PACKAGE([LIBXFCE4UTIL], [libxfce4util-1.0], [4.10.0])
XDT_CHECK_PACKAGE([LIBXFCE4UI], [libxfce4ui-1], [4.10.0])
Nick Schermer's avatar
Nick Schermer committed
151
XDT_CHECK_PACKAGE([XFCONF], [libxfconf-0], [4.10.0])
152

153 154 155 156 157
dnl ********************************************
dnl *** Check for session management support ***
dnl ********************************************
XDT_CHECK_LIBSM()

158
dnl **********************************
159
dnl *** Optional GIO UNIX features ***
160
dnl **********************************
161
XDT_CHECK_OPTIONAL_PACKAGE([GIO_UNIX], [gio-unix-2.0],
Nick Schermer's avatar
Nick Schermer committed
162
                           [2.30.0], [gio-unix], [GIO UNIX features])
163

164 165 166 167 168
dnl **********************************
dnl *** Optional support for D-BUS ***
dnl **********************************
XDT_CHECK_OPTIONAL_PACKAGE([DBUS], [dbus-glib-1],
                           [0.34], [dbus], [D-BUS support])
169 170 171 172 173 174 175 176 177

dnl *************************************************
dnl *** Optional support for startup notification ***
dnl *************************************************
XDT_CHECK_OPTIONAL_PACKAGE([LIBSTARTUP_NOTIFICATION],
                           [libstartup-notification-1.0],
                           [0.4], [startup-notification],
                           [startup notification library])

178 179 180 181 182 183
dnl ***************************************************************
dnl *** Optional support for GUDev (required for thunar-volman) ***
dnl ***************************************************************
XDT_CHECK_OPTIONAL_PACKAGE([GUDEV], [gudev-1.0], [145], [gudev], 
                           [GUDev (required for thunar-volman)])

184 185 186 187 188 189
dnl **************************************
dnl *** Optional support for libnotify ***
dnl **************************************
XDT_CHECK_OPTIONAL_PACKAGE([LIBNOTIFY], [libnotify], [0.4.0], [notifications],
                           [Mount notification support], [yes])

190 191 192 193 194
dnl *************************
dnl *** Check for gtk-doc ***
dnl *************************
GTK_DOC_CHECK([1.0])

195 196 197
dnl ***********************************
dnl *** Check for debugging support ***
dnl ***********************************
198
XDT_FEATURE_DEBUG([thunar_debug_default])
199

200 201 202 203 204 205
dnl *************************************
dnl *** Compensate for broken gtk-doc ***
dnl *************************************
XDT_SUPPORTED_FLAGS([GTK_DOC_EXTRA_CFLAGS], [-Wno-sign-compare])
AC_SUBST([GTK_DOC_EXTRA_CFLAGS])

206 207 208
dnl **************************************
dnl *** Check for linker optimizations ***
dnl **************************************
209
XDT_FEATURE_LINKER_OPTS()
210

211 212 213 214
dnl dnl ****************************************
dnl dnl *** Check for ELF visibility support ***
dnl dnl ****************************************
dnl XDT_FEATURE_VISIBILITY()
215

216 217 218
dnl *********************************
dnl *** Substitute platform flags ***
dnl *********************************
219 220
AC_MSG_CHECKING([PLATFORM_CPPFLAGS])
AC_MSG_RESULT([$PLATFORM_CPPFLAGS])
221
AC_SUBST([PLATFORM_CPPFLAGS])
222 223 224 225 226
AC_MSG_CHECKING([PLATFORM_CFLAGS])
AC_MSG_RESULT([$PLATFORM_CFLAGS])
AC_SUBST([PLATFORM_CFLAGS])
AC_MSG_CHECKING([PLATFORM_LDFLAGS])
AC_MSG_RESULT([$PLATFORM_LDFLAGS])
227 228
AC_SUBST([PLATFORM_LDFLAGS])

229 230 231
dnl ************************************
dnl *** Check for additional plugins ***
dnl ************************************
232
BM_THUNAR_PLUGIN_APR()
233
BM_THUNAR_PLUGIN_SBR()
234
BM_THUNAR_PLUGIN_TPA()
235
BM_THUNAR_PLUGIN_UCA()
236
BM_THUNAR_PLUGIN_WALLPAPER()
237

238 239
AC_OUTPUT([
Makefile
240 241
docs/Makefile
docs/design/Makefile
242
docs/papers/Makefile
243 244 245 246
docs/reference/Makefile
docs/reference/thunarx/Makefile
docs/reference/thunarx/version.xml
examples/Makefile
247
examples/tex-open-terminal/Makefile
248
icons/Makefile
249
icons/16x16/Makefile
250 251
icons/24x24/Makefile
icons/48x48/Makefile
252 253
icons/64x64/Makefile
icons/128x128/Makefile
254
icons/scalable/Makefile
255 256
pixmaps/Makefile
plugins/Makefile
257
plugins/thunar-apr/Makefile
258
plugins/thunar-sbr/Makefile
259
plugins/thunar-sendto-email/Makefile
260
plugins/thunar-tpa/Makefile
261
plugins/thunar-uca/Makefile
262
plugins/thunar-wallpaper/Makefile
Benedikt Meurer's avatar
 
Benedikt Meurer committed
263
po/Makefile.in
264
thunar/Makefile
265
thunarx/Makefile
266
thunarx/thunarx-2.pc
267
thunarx/thunarx-config.h
268
])
269 270 271 272 273 274 275 276

dnl ***************************
dnl *** Print configuration ***
dnl ***************************
echo
echo "Build Configuration:"
echo
if test x"$DBUS_FOUND" = x"yes"; then
277
echo "* D-BUS support:                      yes"
278
else
279
echo "* D-BUS support:                      no"
280
fi
281
if test x"$GIO_UNIX_FOUND" = x"yes"; then
282
echo "* GIO UNIX features:                  yes"
283
else
284
echo "* GIO UNIX features:                  no"
285 286
fi
if test x"$LIBSTARTUP_NOTIFICATION_FOUND" = x"yes"; then
287 288 289 290 291 292
echo "* Startup Notification:               yes"
else
echo "* Startup Notification:               no"
fi
if test x"$GUDEV_FOUND" = x"yes"; then
echo "* GUDev (required for thunar-volman): yes"
293
else
294
echo "* GUDev (required for thunar-volman): no"
295
fi
296 297 298 299 300 301
if test x"$LIBNOTIFY_FOUND" = x"yes"; then
echo "* Mount notification support:         yes"
else
echo "* Mount notification support:         no"
fi
echo "* Debug Support:                      $enable_debug"
302 303 304
echo
echo "Additional Plugins:"
echo
305
echo "* Advanced Properties:                $ac_bm_thunar_plugin_apr"
306
echo "* Simple Builtin Renamers:            $ac_bm_thunar_plugin_sbr"
307 308 309
echo "* Trash Panel Applet:                 $ac_bm_thunar_plugin_tpa"
echo "* User Customizable Actions:          $ac_bm_thunar_plugin_uca"
echo "* Wallpaper support:                  $ac_bm_thunar_plugin_wallpaper"
310
echo