configure.ac.in 10.6 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], [5])
Nick Schermer's avatar
Nick Schermer committed
28
m4_define([thunar_version_micro], [3])
Stephan Arts's avatar
Stephan Arts committed
29
m4_define([thunar_version_nano], [])
30
m4_define([thunar_version_build], [@REVISION@])
Nick Schermer's avatar
Nick Schermer 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 ***************************
Jannis Pohlmann's avatar
Jannis Pohlmann committed
42
AC_COPYRIGHT([Copyright (c) 2004-2011 The Thunar development team. All rights reserved.])
43
AC_INIT([Thunar], [thunar_version], [http://bugzilla.xfce.org/], [Thunar])
44
AC_PREREQ([2.50])
45
AC_CANONICAL_TARGET()
46 47
AC_REVISION([$Id$])

48 49 50
dnl ***************************
dnl *** Initialize automake ***
dnl ***************************
51
AM_INIT_AUTOMAKE([1.8 dist-bzip2 tar-ustar no-dist-gzip])
52 53
AM_CONFIG_HEADER([config.h])
AM_MAINTAINER_MODE()
54
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
55

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

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

67 68 69
dnl ********************************
dnl *** Check for basic programs ***
dnl ********************************
70
AC_PROG_CC()
71
AC_PROG_LD()
72
AM_PROG_CC_C_O()
73
AC_PROG_INSTALL()
74
AC_PROG_INTLTOOL()
75
AC_CHECK_PROGS([PERL], [perl5 perl])
76
m4_ifdef([AC_PROG_SED], [AC_PROG_SED], [AC_CHECK_PROG(SED, sed, sed)])
77 78 79 80

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

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

98 99 100 101 102 103 104 105 106 107
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])

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

113 114 115
dnl **********************************
dnl *** Check for standard headers ***
dnl **********************************
116 117
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 \
118 119
                  sys/mman.h sys/param.h sys/stat.h sys/time.h sys/types.h \
                  sys/uio.h sys/wait.h time.h])
120

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

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

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

138 139 140
dnl ***********************************
dnl *** Check for required packages ***
dnl ***********************************
Nick Schermer's avatar
Nick Schermer committed
141
XDT_CHECK_PACKAGE([EXO], [exo-1], [0.9.0])
142 143 144 145
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])
146
XDT_CHECK_PACKAGE([GTK], [gtk+-2.0], [2.24.0])
147
XDT_CHECK_PACKAGE([GDK_PIXBUF], [gdk-pixbuf-2.0], [2.14.0])
Nick Schermer's avatar
Nick Schermer committed
148 149
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
150
XDT_CHECK_PACKAGE([XFCONF], [libxfconf-0], [4.10.0])
151

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

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

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

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])

177 178 179 180 181 182
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)])

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

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

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

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

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

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

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

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

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

dnl ***************************
dnl *** Print configuration ***
dnl ***************************
echo
echo "Build Configuration:"
echo
if test x"$DBUS_FOUND" = x"yes"; then
276
echo "* D-BUS support:                      yes"
277
else
278
echo "* D-BUS support:                      no"
279
fi
280
if test x"$GIO_UNIX_FOUND" = x"yes"; then
281
echo "* GIO UNIX features:                  yes"
282
else
283
echo "* GIO UNIX features:                  no"
284 285
fi
if test x"$LIBSTARTUP_NOTIFICATION_FOUND" = x"yes"; then
286 287 288 289 290 291
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"
292
else
293
echo "* GUDev (required for thunar-volman): no"
294
fi
295 296 297 298 299 300
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"
301 302 303
echo
echo "Additional Plugins:"
echo
304
echo "* Advanced Properties:                $ac_bm_thunar_plugin_apr"
305
echo "* Simple Builtin Renamers:            $ac_bm_thunar_plugin_sbr"
306 307 308
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"
309
echo