1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141
|
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ(2.52)
AC_INIT([homebank], [5.3.2])
#AC_INIT([homebank], [x.x-rc])
AM_CONFIG_HEADER(config.h)
AM_INIT_AUTOMAKE([1.9 foreign])
# If the source code has changed at all, increment REVISION
# If any interfaces have been added, removed, or changed, increment CURRENT, and set REVISION to 0.
# If any interfaces have been added since the last public release, then increment AGE.
# If any interfaces have been removed since the last public release, then set AGE to 0.
# Reference: http://www.gnu.org/software/libtool/manual.html#Versioning
# Checks for programs.
AC_PROG_CC
AC_PROG_LN_S
AC_PROG_INSTALL
AC_PROG_INTLTOOL
# Checks for libraries.
PKG_CHECK_MODULES(DEPS, gtk+-3.0 >= 3.16 glib-2.0 >= 2.39)
AC_SUBST(DEPS_CFLAGS)
AC_SUBST(DEPS_LIBS)
AC_CHECK_LIB(m, pow)
PKG_CHECK_MODULES(LIBSOUP, [libsoup-2.4 >= 2.26])
AC_SUBST(LIBSOUP_CFLAGS)
AC_SUBST(LIBSOUP_LIBS)
# general usage flags
CFLAGS="${CFLAGS} -Wall -Wmissing-prototypes"
# disable deprecated warnings
CFLAGS="${CFLAGS} -Wno-deprecated-declarations"
# extended flags
#CFLAGS="${CFLAGS} -Wextra -Wno-unused-parameter -Wno-cast-function-type"
# profiling valgrind/gprof flags
#CFLAGS="${CFLAGS} -g -O0 -pg"
# pre-relase # 2 - error as warning for
#CFLAGS="${CFLAGS} -Werror"
# gtk3 migration
#CFLAGS="${CFLAGS} -DGTK_DISABLE_SINGLE_INCLUDES -DGSEAL_ENABLE"
# GLib/Gtk deprecated flags
#CFLAGS="${CFLAGS} -DG_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_DEPRECATED -DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED"
# Check for libofx
AC_CHECK_HEADER(libofx/libofx.h,,noofx=true)
AC_ARG_WITH(ofx,
[ --without-ofx build without ofx support [default=with]],
[build_ofx=$withval],
[build_ofx=yes]
)
if test x$build_ofx != xno
then
if test x$noofx != xtrue
then
AC_CHECK_LIB(ofx, ofx_set_status_cb, OFX_0_7="-DOFX_ENABLE")
DEPS_LIBS="-lofx ${DEPS_LIBS}"
CFLAGS="${CFLAGS} $OFX_0_7"
else
noofx=true
AC_MSG_RESULT([Libofx header missing. Check your libofx installation])
CFLAGS="${CFLAGS} -DNOOFX"
fi
else
noofx=true
CFLAGS="${CFLAGS} -DNOOFX"
fi
AM_CONDITIONAL(NOOFX, test x$noofx = xtrue)
# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([libintl.h locale.h stdlib.h string.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_HEADER_STDBOOL
AC_C_CONST
AC_STRUCT_TM
AC_C_VOLATILE
# Checks for library functions.
AC_CHECK_FUNCS([floor localeconv memset modf pow setlocale sqrt strcasecmp strtoul])
# International support
ALL_LINGUAS="af ar ast be bg br ca ckb 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 ka ko lt lv 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"
AM_GLIB_GNU_GETTEXT
GETTEXT_PACKAGE=$PACKAGE
AC_SUBST(GETTEXT_PACKAGE)
AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE], ["${GETTEXT_PACKAGE}"], [gettext domain])
AC_CONFIG_FILES([
Makefile
src/Makefile
data/homebank.desktop.in
data/Makefile
data/datas/Makefile
images/Makefile
mime/Makefile
pixmaps/Makefile
themes/Makefile
themes/hicolor/Makefile
po/Makefile.in
doc/Makefile
doc/images/Makefile
])
AC_OUTPUT
# *************************************
# *************************************
echo
echo $PACKAGE $VERSION
echo
echo Compiler................ : $CC
echo Build with OFX support.. : $build_ofx
if test "x$noofx" = "xtrue" ; then
echo ........................ : **error** libofx header is missing, ofx feature will be disabled. Check your libofx installation
fi
eval eval echo Path to images.......... : $datadir/homebank/images
eval eval echo Path to locale.......... : $datadir/locale
eval eval echo Path to help............ : $datadir/homebank/help
echo
eval eval echo HomeBank will be installed in $bindir.
echo
echo configure complete, now type \'make\'
echo
|