menu: added new Keywords tag to .desktop files
[barry.git] / gui / configure.ac
blobf67bc0350652214eb317f9526174c7a4a5ce1d7c
1 #                                               -*- Autoconf -*-
2 # Process this file with autoconf to produce a configure script.
4 AC_PREREQ(2.61)
5 AC_INIT([barry-backup], [0.19.0], [barry-devel@lists.sourceforge.net])
6 #AM_CONFIG_HEADER(config.h)
7 AC_CONFIG_SRCDIR([src/main.cc])
8 AC_CONFIG_HEADERS([config.h:config.h.in])
9 AC_CONFIG_AUX_DIR([.])
10 AC_CONFIG_MACRO_DIR([m4])
11 AM_INIT_AUTOMAKE
13 AM_GNU_GETTEXT([external])
14 # this is the gettext version, not barry's version
15 AM_GNU_GETTEXT_VERSION([0.18.1])
18 # Checks for programs.
20 AC_PROG_CC
21 AC_PROG_CXX
22 AC_PROG_MAKE_SET
23 AC_PROG_LIBTOOL
25 AC_LANG([C++])
27 PKG_CHECK_MODULES([BARRY], [libbarry-19])
28 PKG_CHECK_MODULES([BARRYBACKUP], [libbarrybackup-19])
29 PKG_CHECK_MODULES([GTKMM], [gtkmm-2.4 libglademm-2.4 gthread-2.0])
31 # Carry the special tree build environment variables from parent configure,
32 # just in case user is doing a complete tree build with --enable-gui
33 AC_SUBST(TREE_BUILD_CXXFLAGS)
34 AC_SUBST(TREE_BUILD_LDFLAGS)
36 # Setup gladedir, so src/Makefile.am can use it for the compile
37 # and for the glade file installations. (glade_DATA)
38 gladedir="$datadir/barry/glade/"
39 AC_SUBST(gladedir)
41 # Checks for libraries.
42 #AC_CHECK_LIB([IOKit], [main])
43 AC_CHECK_LIB([pthread], [main])
44 #AC_CHECK_LIB([libusb], [libusb_init])
46 # Checks for header files.
47 AC_HEADER_DIRENT
48 AC_HEADER_STDC
49 AC_CHECK_HEADERS([assert.h stdint.h time.h])
51 # Checks for typedefs, structures, and compiler characteristics.
52 #AC_TYPE_SIZE_T
53 AC_HEADER_TIME
54 AC_STRUCT_TM
56 # Checks for library functions.
57 AC_FUNC_CLOSEDIR_VOID
58 AC_PROG_GCC_TRADITIONAL
59 AC_FUNC_MALLOC
60 AC_FUNC_MKTIME
61 AC_FUNC_REALLOC
62 AC_FUNC_SELECT_ARGTYPES
63 AC_FUNC_STAT
64 AC_CHECK_FUNCS([bzero gettimeofday memset select strcasecmp strchr strerror strtol strtoul])
66 AC_CONFIG_FILES([Makefile 
67                  po/Makefile.in
68                  src/Makefile
69                  man/Makefile])
70 AC_OUTPUT
74 # Add a special hack at the end, to let the user disable RPATH if he wants.
76 # http://wiki.debian.org/RpathIssue
77 # http://lists.debian.org/debian-devel/2003/debian-devel-200306/msg00569.html
78 # http://fedoraproject.org/wiki/Packaging:Guidelines#Removing_Rpath
80 AC_ARG_ENABLE([rpathhack],
81         [AC_HELP_STRING([--enable-rpathhack], [patch libtool to remove RPATH])],
82         [
83 AC_MSG_RESULT([patching libtool to fix HIDEOUS BREAKAGE])
84 sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
85 sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
86         ],
87         [])