2 # Process this file with autoconf to produce a configure script.
5 AC_INIT([homebank], [5.1.3])
6 #AC_INIT([homebank], [x.x-rc])
8 AM_CONFIG_HEADER(config.h)
10 AM_INIT_AUTOMAKE([1.9 foreign])
14 AC_CONFIG_MACRO_DIR([m4])
16 # If the source code has changed at all, increment REVISION
17 # If any interfaces have been added, removed, or changed, increment CURRENT, and set REVISION to 0.
18 # If any interfaces have been added since the last public release, then increment AGE.
19 # If any interfaces have been removed since the last public release, then set AGE to 0.
20 # Reference: http://www.gnu.org/software/libtool/manual.html#Versioning
22 # Checks for programs.
28 # Checks for libraries.
29 PKG_CHECK_MODULES(DEPS, gtk+-3.0 >= 3.12 glib-2.0 >= 2.39 gmodule-2.0 >= 2.39)
34 PKG_CHECK_MODULES(LIBSOUP, [libsoup-2.4 >= 2.26])
35 AC_SUBST(LIBSOUP_CFLAGS)
36 AC_SUBST(LIBSOUP_LIBS)
39 CFLAGS="${CFLAGS} -Wall -Wmissing-prototypes"
41 # disable deprecated warnings
42 CFLAGS="${CFLAGS} -Wno-deprecated-declarations"
45 #CFLAGS="${CFLAGS} -Wextra -Wno-unused-parameter"
47 # profiling valgrind/gprof flags
48 #CFLAGS="${CFLAGS} -g -O0 -pg"
50 # pre-relase # 2 - error as warning for
51 #CFLAGS="${CFLAGS} -Werror"
54 #CFLAGS="${CFLAGS} -DGTK_DISABLE_SINGLE_INCLUDES -DGSEAL_ENABLE"
56 # GLib/Gtk deprecated flags
57 #CFLAGS="${CFLAGS} -DG_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"
61 AC_CHECK_HEADER(libofx/libofx.h,,noofx=true)
63 [ --without-ofx build without ofx support [default=with]],
67 if test x$build_ofx != xno
69 if test x$noofx != xtrue
71 AC_CHECK_LIB(ofx, ofx_set_status_cb, OFX_0_7="-DOFX_ENABLE")
72 DEPS_LIBS="-lofx ${DEPS_LIBS}"
73 CPPFLAGS="${CPPFLAGS} $OFX_0_7"
76 AC_MSG_RESULT([Libofx header missing. Check your libofx installation])
77 CFLAGS="${CFLAGS} -DNOOFX"
81 CFLAGS="${CFLAGS} -DNOOFX"
83 AM_CONDITIONAL(NOOFX, test x$noofx = xtrue)
86 [ --with-perl build with perl plug-in support [default=without]],
87 [build_perl=$withval],
90 if test x$build_perl != xno
92 test x$build_perl != xyes -a -x "$build_perl" && PERL=$build_perl
93 AC_PATH_PROG(PERL, perl, perl)
94 AC_MSG_CHECKING(if perl can be embedded)
95 if $PERL -MExtUtils::Embed -e "use v5.8" >/dev/null 2>&1
98 CPPFLAGS="${CPPFLAGS} -DPERL_ENABLE"
99 PERL_CPPFLAGS="`$PERL -MExtUtils::Embed -e ccopts`"
100 PERL_OBJS="ext-perl.o perlxsi.o"
101 PERL_PRIVLIBEXP="`$PERL -MConfig -e 'print $Config{privlibexp}'`"
102 PERL_SITELIBEXP="`$PERL -MConfig -e 'print $Config{sitelibexp}'`"
103 DEPS_LIBS="`$PERL -MExtUtils::Embed -e ldopts` ${DEPS_LIBS}"
104 if test -e "$PERL_SITELIBEXP/ExtUtils/xsubpp"
106 XSUBPP="$PERL $PERL_SITELIBEXP/ExtUtils/xsubpp"
108 XSUBPP="$PERL $PERL_PRIVLIBEXP/ExtUtils/xsubpp"
111 AC_MSG_ERROR([no working perl found, or perl not version >= 5.8])
114 AC_SUBST(PERL_CPPFLAGS)
116 AC_SUBST(PERL_PRIVLIBEXP)
117 AC_SUBST(PERL_SITELIBEXP)
120 # Checks for header files.
122 AC_CHECK_HEADERS([libintl.h locale.h stdlib.h string.h])
124 # Checks for typedefs, structures, and compiler characteristics.
130 # Checks for library functions.
131 AC_CHECK_FUNCS([floor localeconv memset modf pow setlocale sqrt strcasecmp strtoul])
133 # International support
134 ALL_LINGUAS="af ar ast be bg br ca cs cy da de el en_AU en_CA en_GB es et eu fa fi fr gl he hr hu id is it ja ko lt lv mr ms nb nds nl oc pl pt_BR pt pt_PT ro ru si sk sl sr sv tr uk vi zh_CN zh_TW"
138 GETTEXT_PACKAGE=$PACKAGE
139 AC_SUBST(GETTEXT_PACKAGE)
140 AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE], ["${GETTEXT_PACKAGE}"], [gettext domain])
145 data/homebank.desktop.in
152 themes/hicolor/Makefile
161 # *************************************
162 # *************************************
165 echo $PACKAGE $VERSION
167 echo Compiler................ : $CC
168 echo Build with OFX support.. : $build_ofx
169 echo Build with perl support. : $build_perl
170 if test "x$noofx" = "xtrue" ; then
171 echo ........................ : **error** libofx header is missing, ofx feature will be disabled. Check your libofx installation
173 eval eval echo Path to images.......... : $datadir/homebank/images
174 eval eval echo Path to locale.......... : $datadir/locale
175 eval eval echo Path to help............ : $datadir/homebank/help
178 eval eval echo HomeBank will be installed in $bindir.
180 echo configure complete, now type \'make\'