2 # Process this file with autoconf to produce a configure script.
5 AC_INIT([homebank], [4.6.3])
7 AM_CONFIG_HEADER(config.h)
9 AM_INIT_AUTOMAKE([1.9 foreign])
13 AC_CONFIG_MACRO_DIR([m4])
15 # If the source code has changed at all, increment REVISION
16 # If any interfaces have been added, removed, or changed, increment CURRENT, and set REVISION to 0.
17 # If any interfaces have been added since the last public release, then increment AGE.
18 # If any interfaces have been removed since the last public release, then set AGE to 0.
19 # Reference: http://www.gnu.org/software/libtool/manual.html#Versioning
21 # Checks for programs.
27 # Checks for libraries.
28 PKG_CHECK_MODULES(DEPS, gtk+-2.0 >= 2.24 glib-2.0 >= 2.28 gmodule-2.0 >= 2.28)
34 CFLAGS="${CFLAGS} -Wall -Wmissing-prototypes"
37 #CFLAGS="${CFLAGS} -Wextra -Wno-unused-parameter"
40 #CFLAGS="${CFLAGS} -g -O0"
42 # pre-relase # 2 - error as warning for
43 #CFLAGS="${CFLAGS} -Werror"
46 #CFLAGS="${CFLAGS} -DGTK_DISABLE_SINGLE_INCLUDES -DGSEAL_ENABLE"
48 # GLib/Gtk deprecated flags
49 #CFLAGS="${CFLAGS} -DG_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"
53 AC_CHECK_HEADER(libofx/libofx.h,,noofx=true)
55 [ --without-ofx build without ofx support [default=with]],
59 if test x$build_ofx != xno
61 if test x$noofx != xtrue
63 AC_CHECK_LIB(ofx, ofx_set_status_cb, OFX_0_7="-DOFX_ENABLE")
64 DEPS_LIBS="-lofx ${DEPS_LIBS}"
65 CPPFLAGS="${CPPFLAGS} $OFX_0_7"
68 AC_MSG_RESULT([Libofx header missing. Check your libofx installation])
69 CFLAGS="${CFLAGS} -DNOOFX"
73 CFLAGS="${CFLAGS} -DNOOFX"
75 AM_CONDITIONAL(NOOFX, test x$noofx = xtrue)
78 [ --with-perl build with perl plug-in support [default=without]],
79 [build_perl=$withval],
82 if test x$build_perl != xno
84 test x$build_perl != xyes -a -x "$build_perl" && PERL=$build_perl
85 AC_PATH_PROG(PERL, perl, perl)
86 AC_MSG_CHECKING(if perl can be embedded)
87 if $PERL -MExtUtils::Embed -e "use v5.8" >/dev/null 2>&1
90 CPPFLAGS="${CPPFLAGS} -DPERL_ENABLE"
91 PERL_CPPFLAGS="`$PERL -MExtUtils::Embed -e ccopts`"
92 PERL_OBJS="ext-perl.o perlxsi.o"
93 PERL_PRIVLIBEXP="`$PERL -MConfig -e 'print $Config{privlibexp}'`"
94 PERL_SITELIBEXP="`$PERL -MConfig -e 'print $Config{sitelibexp}'`"
95 DEPS_LIBS="`$PERL -MExtUtils::Embed -e ldopts` ${DEPS_LIBS}"
96 if test -e "$PERL_SITELIBEXP/ExtUtils/xsubpp"
98 XSUBPP="$PERL $PERL_SITELIBEXP/ExtUtils/xsubpp"
100 XSUBPP="$PERL $PERL_PRIVLIBEXP/ExtUtils/xsubpp"
103 AC_MSG_ERROR([no working perl found, or perl not version >= 5.8])
106 AC_SUBST(PERL_CPPFLAGS)
108 AC_SUBST(PERL_PRIVLIBEXP)
109 AC_SUBST(PERL_SITELIBEXP)
112 # Checks for header files.
114 AC_CHECK_HEADERS([libintl.h locale.h stdlib.h string.h])
116 # Checks for typedefs, structures, and compiler characteristics.
122 # Checks for library functions.
123 AC_CHECK_FUNCS([floor localeconv memset modf pow setlocale sqrt strcasecmp strtoul])
125 # International support
126 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 ga gl he hr hu id is it ja ka 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"
130 GETTEXT_PACKAGE=$PACKAGE
131 AC_SUBST(GETTEXT_PACKAGE)
132 AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE], ["${GETTEXT_PACKAGE}"], [gettext domain])
137 data/homebank.desktop.in
151 # *************************************
152 # *************************************
155 echo $PACKAGE $VERSION
157 echo Compiler................ : $CC
158 echo Build with OFX support.. : $build_ofx
159 echo Build with perl support. : $build_perl
160 if test "x$noofx" = "xtrue" ; then
161 echo ........................ : **error** libofx header is missing, ofx feature will be disabled. Check your libofx installation
163 eval eval echo Path to images.......... : $datadir/homebank/images
164 eval eval echo Path to locale.......... : $datadir/locale
165 eval eval echo Path to help............ : $datadir/homebank/help
168 eval eval echo HomeBank will be installed in $bindir.
170 echo configure complete, now type \'make\'