Project

General

Profile

Statistics
| Branch: | Tag: | Revision:

aqbanking / configure.ac @ e7796bf3

History | View | Annotate | Download (40.1 KB)

1
# Process this file with autoconf to produce a configure script.
2

    
3
AC_PREREQ(2.56)
4
AC_INIT
5
AC_CANONICAL_BUILD
6
AC_CANONICAL_HOST
7

    
8
AC_CONFIG_SRCDIR([README])
9
AC_CONFIG_HEADERS([config.h])
10

    
11

    
12
###-------------------------------------------------------------------------
13
#
14
# AqBanking versions
15
#
16

    
17
AQBANKING_VERSION_MAJOR=5
18
AQBANKING_VERSION_MINOR=99
19
AQBANKING_VERSION_PATCHLEVEL=32
20
AQBANKING_VERSION_BUILD=1
21
dnl "stable", "rcX", "betaX", "svn"
22
AQBANKING_VERSION_TAG="git"
23

    
24

    
25

    
26
###-------------------------------------------------------------------------
27
#
28
# SO versions
29
#
30

    
31
#
32
# AqBanking
33
#
34

    
35
AQBANKING_SO_CURRENT=43
36
AQBANKING_SO_AGE=0
37
AQBANKING_SO_REVISION=32
38
AQBANKING_SO_EFFECTIVE="`echo \$(($AQBANKING_SO_CURRENT-$AQBANKING_SO_AGE))`"
39

    
40

    
41
###-------------------------------------------------------------------------
42
#
43
# Generate version strings and BUILD
44
#
45

    
46
SVN="svn"
47
AQBANKING_VERSION_FULL_STRING="${AQBANKING_VERSION_MAJOR}.${AQBANKING_VERSION_MINOR}.${AQBANKING_VERSION_PATCHLEVEL}.${AQBANKING_VERSION_BUILD}${AQBANKING_VERSION_TAG}"
48
AQBANKING_VERSION_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL"
49
AQBANKING_FINTS_VERSION_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR"
50

    
51
case "$AQBANKING_VERSION_TAG" in 
52
  svn|cvs)
53
     rev=`LC_ALL="C" $SVN info|grep 'Last Changed Rev'|cut -d' ' -f4`
54
     if test "x$rev" != "x" ; then
55
       AQBANKING_VERSION_FULL_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.${AQBANKING_VERSION_PATCHLEVEL}${AQBANKING_VERSION_TAG}-r${rev}"
56
     fi
57
     ;;
58
     
59
  git)
60
     AQBANKING_VERSION_FULL_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.${AQBANKING_VERSION_PATCHLEVEL}.${AQBANKING_VERSION_BUILD}"
61
     ;;
62
esac
63

    
64

    
65
###-------------------------------------------------------------------------
66
#
67
# datetime
68
#
69
AC_ARG_WITH([build-datetime],
70
  [AS_HELP_STRING([--with-build-datetime=DATETIME],
71
                  [use fixed datetime for build (default: current date and time)])],
72
  [AS_IF([test "x$withval" = "xyes"],
73
    [DATETIME="`date +\"%Y%m%d%H%M%S\"`"],
74
    [DATETIME="`date +\"%Y%m%d%H%M%S\" --date=\"$withval\"`"])],
75
  [DATETIME="`date +\"%Y%m%d%H%M%S\"`"])
76
AC_SUBST(DATETIME)
77

    
78

    
79
###-------------------------------------------------------------------------
80
#
81
# Create release strings
82
#
83
case "$AQBANKING_VERSION_TAG" in
84
  cvs|svn)
85
     AQBANKING_VERSION_RELEASE_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL.r${AQBANKING_VERSION_BUILD}"
86
     ;;
87
  git)
88
     AQBANKING_VERSION_RELEASE_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL.${AQBANKING_VERSION_BUILD}-${AQBANKING_VERSION_TAG}"
89
     ;;
90
  stable)
91
     AQBANKING_VERSION_RELEASE_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL"
92
     ;;
93
  *)
94
     AQBANKING_VERSION_RELEASE_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL"
95
     
96
     # add TAG
97
     AQBANKING_VERSION_RELEASE_STRING="${AQBANKING_VERSION_RELEASE_STRING}${AQBANKING_VERSION_TAG}"
98
     ;;
99
esac
100

    
101

    
102
###-------------------------------------------------------------------------
103
#
104
# SUBST and DEFINE versions
105
#
106
AC_SUBST(AQBANKING_VERSION_MAJOR)
107
AC_SUBST(AQBANKING_VERSION_MINOR)
108
AC_SUBST(AQBANKING_VERSION_PATCHLEVEL)
109
AC_SUBST(AQBANKING_VERSION_BUILD)
110
AC_SUBST(AQBANKING_VERSION_TAG)
111
AC_SUBST(AQBANKING_VERSION_FULL_STRING)
112
AC_SUBST(AQBANKING_VERSION_STRING)
113
AC_SUBST(AQBANKING_VERSION_RELEASE_STRING)
114

    
115
AC_SUBST(AQBANKING_FINTS_VERSION_STRING)
116
AC_DEFINE_UNQUOTED(AQBANKING_FINTS_VERSION_STRING, "$AQBANKING_FINTS_VERSION_STRING", [Version string for FINTS])
117

    
118
AC_SUBST(AQBANKING_SO_CURRENT)
119
AC_SUBST(AQBANKING_SO_REVISION)
120
AC_SUBST(AQBANKING_SO_AGE)
121
AC_SUBST(AQBANKING_SO_EFFECTIVE)
122
AC_DEFINE_UNQUOTED(AQBANKING_SO_EFFECTIVE_STR, "$AQBANKING_SO_EFFECTIVE",
123
                   [effective SO version])
124

    
125
AM_INIT_AUTOMAKE(aqbanking, $AQBANKING_VERSION_RELEASE_STRING)
126

    
127

    
128
###-------------------------------------------------------------------------
129
#
130
# determine operating system
131
#
132
AQ_CHECK_OS
133

    
134

    
135
###-------------------------------------------------------------------------
136
#
137
# prefix handling
138
#
139
AC_PREFIX_DEFAULT(/usr)
140
if test "x$prefix" = "xNONE"; then
141
  prefix=$ac_default_prefix
142
  ac_configure_args="$ac_configure_args --prefix $prefix"
143
fi
144
AC_SUBST(prefix)
145

    
146

    
147
###-------------------------------------------------------------------------
148
#
149
# static/shared handling
150
#
151
AC_ENABLE_STATIC(no)
152
AC_ENABLE_SHARED(yes)
153

    
154

    
155

    
156
###-------------------------------------------------------------------------
157
#
158
# define some needed variables
159
#
160
abs_top_builddir="`pwd`"
161
AC_SUBST(abs_top_builddir)
162

    
163

    
164
###-------------------------------------------------------------------------
165
#
166
# Enable some GNU extensions if using the GNU C library
167
#
168

    
169
AC_GNU_SOURCE
170

    
171

    
172

    
173
###-------------------------------------------------------------------------
174
#
175
# Checks for programs.
176
#
177
AC_PROG_CC
178
AC_PROG_CXX
179
AC_PROG_CPP
180
AC_PROG_INSTALL
181

    
182
AC_PROG_LIBTOOL
183
AC_LIBTOOL_WIN32_DLL
184
AC_LIBTOOL_RC
185
# Newer libtool doesn't have AC_LIBTOOL_RC anymore.  Need to check for
186
# $(RC) by ourselves.
187
AC_CHECK_TOOL([RC], [windres], [no])
188
AC_CHECK_PROG(USE_DOT,dot,YES,NO)
189
AC_CHECK_PROG(SED,sed,sed)
190

    
191
PKG_PROG_PKG_CONFIG
192

    
193
# Checks for libraries.
194

    
195
###-------------------------------------------------------------------------
196
#
197
# Checks for header files.
198
#
199
AC_HEADER_STDC
200
AC_CHECK_HEADERS([fcntl.h stdlib.h string.h unistd.h locale.h])
201
AC_CHECK_HEADERS([iconv.h libintl.h locale.h])
202
AC_CHECK_HEADERS([assert.h ctype.h errno.h fcntl.h stdio.h stdlib.h string.h strings.h locale.h])
203

    
204

    
205

    
206
###-------------------------------------------------------------------------
207
#
208
# Checks for typedefs, structures, and compiler characteristics.
209
#
210
AC_C_CONST
211
AC_STRUCT_TM
212

    
213

    
214

    
215
###-------------------------------------------------------------------------
216
#
217
# Checks for library functions.
218
#
219
AC_FUNC_STRFTIME
220
AC_CHECK_FUNCS([memmove memset strcasecmp strdup strerror snprintf])
221
AC_CHECK_FUNCS([setlocale])
222

    
223

    
224

    
225
###-------------------------------------------------------------------------
226
#
227
# Backends. Those do not have a required ordering.
228
#
229

    
230
AC_ARG_WITH(backends, 
231
  [  --with-backends=list      space separated list of backends (default:all)],
232
  [aqbanking_backends="$withval"],
233
  [aqbanking_backends="all"]
234
)
235

    
236
if test "$aqbanking_backends" = "all"; then
237
  aqbanking_backends="aqhbci aqofxconnect aqebics"
238
fi
239

    
240
for f in ${aqbanking_backends}; do
241
  case "$f" in
242
    aqhbci)
243
      aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqhbci"
244
      aqbanking_plugins_backends_libs="$aqbanking_plugins_backends_libs aqhbci/libaqhbci.la"
245
      AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQHBCI, 1, [plugin availability])
246
      ;;
247
    aqfints)
248
      aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqfints"
249
      aqbanking_plugins_backends_libs="$aqbanking_plugins_backends_libs aqfints/libaqfints.la"
250
      AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQFINTS, 1, [plugin availability])
251
      ;;
252
    aqebics)
253
      aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqebics"
254
      aqbanking_plugins_backends_libs="$aqbanking_plugins_backends_libs aqebics/libaqebics.la"
255
      AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQEBICS, 1, [plugin availability])
256
      ;;
257
    aqofxconnect)
258
      aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqofxconnect"
259
      aqbanking_plugins_backends_libs="$aqbanking_plugins_backends_libs aqofxconnect/libaqofxconnect.la"
260
      AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQOFXCONNECT, 1, [plugin availability])
261
      ;;
262
    aqpaypal)
263
      aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqpaypal"
264
      aqbanking_plugins_backends_libs="$aqbanking_plugins_backends_libs aqpaypal/libaqpaypal.la"
265
      AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQPAYPAL, 1, [plugin availability])
266
      ;;
267
    aqnone)
268
      ;;
269
    *)
270
      AC_MSG_ERROR("ERROR: Unknown plugin $f")
271
      ;;
272
  esac
273
done
274

    
275
# always define this
276
AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQNONE, 1, [plugin availability])
277

    
278
AC_SUBST(aqbanking_plugins_backends_dirs)
279
AC_SUBST(aqbanking_plugins_backends_libs)
280

    
281

    
282

    
283
###-------------------------------------------------------------------------
284
#
285
# ImExporters. Those do not have a required ordering.
286
#
287

    
288
AC_ARG_WITH(imexporters, 
289
  [  --with-imexporters=list      space separated list of im-/exporters (default:all)],
290
  [aqbanking_imexporters="$withval"],
291
  [aqbanking_imexporters="all"]
292
)
293

    
294
if test "$aqbanking_imexporters" = "all"; then
295
  aqbanking_imexporters="csv eri2 ofx openhbci1 swift xmldb yellownet sepa ctxfile q43 camt xml"
296
fi
297

    
298
for f in ${aqbanking_imexporters}; do
299
  case "$f" in
300
    csv)
301
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs csv"
302
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs csv/libabimexporters_csv.la"
303
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_CSV, 1, [plugin availability])
304
      ;;
305
    eri2)
306
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs eri2"
307
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs eri2/libabimexporters_eri2.la"
308
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_ERI2, 1, [plugin availability])
309
      ;;
310
    ofx)
311
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs ofx"
312
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs ofx/libabimexporters_ofx.la"
313
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_OFX, 1, [plugin availability])
314
      ;;
315
    openhbci1)
316
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs openhbci1"
317
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs openhbci1/libabimexporters_openhbci1.la"
318
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_OPENHBCI1, 1, [plugin availability])
319
      ;;
320
    swift)
321
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs swift"
322
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs swift/libabimexporters_swift.la"
323
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_SWIFT, 1, [plugin availability])
324
      ;;
325
    xmldb)
326
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs xmldb"
327
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs xmldb/libabimexporters_xmldb.la"
328
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_XMLDB, 1, [plugin availability])
329
      ;;
330
    yellownet)
331
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs yellownet"
332
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs yellownet/libabimexporters_yellownet.la"
333
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_YELLOWNET, 1, [plugin availability])
334
      ;;
335
    sepa)
336
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs sepa"
337
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs sepa/libabimexporters_sepa.la"
338
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_SEPA, 1, [plugin availability])
339
      ;;
340
    ctxfile)
341
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs ctxfile"
342
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs ctxfile/libabimexporters_ctxfile.la"
343
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_CTXFILE, 1, [plugin availability])
344
      ;;
345
    q43)
346
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs q43"
347
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs q43/libabimexporters_q43.la"
348
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_Q43, 1, [plugin availability])
349
      ;;
350
    camt)
351
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs camt"
352
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs camt/libabimexporters_camt.la"
353
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_CAMT, 1, [plugin availability])
354
      ;;
355
    xml)
356
      aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs xml"
357
      aqbanking_plugins_imexporters_libs="$aqbanking_plugins_imexporters_libs xml/libabimexporters_xml.la"
358
      AC_DEFINE(AQBANKING_WITH_PLUGIN_IMEXPORTER_XML, 1, [plugin availability])
359
      ;;
360
    *)
361
      AC_MSG_ERROR("ERROR: Unknown plugin \"$f\"")
362
      ;;
363
  esac
364
done
365

    
366
AC_SUBST(aqbanking_plugins_imexporters_dirs)
367
AC_SUBST(aqbanking_plugins_imexporters_libs)
368

    
369

    
370

    
371
###-------------------------------------------------------------------------
372
#
373
# Parsers. Those do not have a required ordering.
374
#
375

    
376
AC_ARG_WITH(parsers, 
377
  [  --with-parsers=list      space separated list of parsers (default:all)],
378
  [aqbanking_parsers="$withval"],
379
  [aqbanking_parsers="all"]
380
)
381

    
382
if test "$aqbanking_parsers" = "all"; then
383
  aqbanking_parsers="swift"
384
fi
385

    
386
for f in ${aqbanking_parsers}; do
387
  case "$f" in
388
    swift)
389
      aqbanking_plugins_parsers_dirs="$aqbanking_plugins_parsers_dirs swift"
390
      ;;
391
    *)
392
      AC_MSG_ERROR("ERROR: Unknown plugin \"$f\"")
393
      ;;
394
  esac
395
done
396

    
397
AC_SUBST(aqbanking_plugins_parsers_dirs)
398

    
399

    
400

    
401
###-------------------------------------------------------------------------
402
#
403
# Bankinfo plugins. Those do not have a required ordering.
404
#
405

    
406
AC_ARG_WITH(bankinfos, 
407
  [  --with-bankinfos=list      space separated list of bankinfo (default:all)],
408
  [aqbanking_bankinfos="$withval"],
409
  [aqbanking_bankinfos="all"]
410
)
411

    
412
if test "$aqbanking_bankinfos" = "all"; then
413
  aqbanking_bankinfos="de"
414
fi
415

    
416
for f in ${aqbanking_bankinfos}; do
417
  case "$f" in
418
    de)
419
      aqbanking_plugins_bankinfo_dirs="$aqbanking_plugins_bankinfo_dirs de"
420
      aqbanking_plugins_bankinfo_libs="$aqbanking_plugins_bankinfo_libs de/libbankinfo_de.la"
421
      AC_DEFINE(AQBANKING_WITH_PLUGIN_BANKINFO_DE, 1, [plugin availability])
422
      ;;
423
    *)
424
      AC_MSG_ERROR("ERROR: Unknown plugin \"$f\"")
425
      ;;
426
  esac
427
done
428

    
429
AC_SUBST(aqbanking_plugins_bankinfo_dirs)
430
AC_SUBST(aqbanking_plugins_bankinfo_libs)
431

    
432

    
433

    
434
###-------------------------------------------------------------------------
435
#
436
# Check for Gwen
437
#
438

    
439
# Variable used in aqbanking-config.cmake
440
AC_SUBST(GWENHYWFAR_MINIMUM_VERSION, "4.99.10.0")
441
AC_GWENHYWFAR(4,99,10,0)
442

    
443
all_includes="$all_includes $gwenhywfar_includes"
444

    
445
AC_ARG_ENABLE(gui-tests,
446
  [  --enable-gui-tests         allow GUI tests (default=no)],
447
  enable_gui_tests="$enableval",
448
  enable_gui_tests="no")
449
AC_MSG_RESULT($enable_gui_tests)
450

    
451
if test "$enable_gui_tests" != "no"; then
452
  # For libgwenhywfar > 3.99.20, look for its library gwengui-gtk2.
453
  PKG_CHECK_MODULES([GWENGUI_GTK2], [gwengui-gtk2 gwenhywfar], [
454
      HAVE_GWENGUI_GTK2=1
455
      PKG_CHECK_MODULES([GTK2], [gtk+-2.0])
456
    ], [
457
      HAVE_GWENGUI_GTK2=0
458
    ])
459
  AC_SUBST(HAVE_GWENGUI_GTK2)
460
  if test "$HAVE_GWENGUI_GTK2" = "1"; then
461
    AC_DEFINE(USE_GWENGUI_GTK2, 1, [GTK2Gui availability])
462
  fi
463
else
464
  HAVE_GWENGUI_GTK2=0
465
fi
466
AM_CONDITIONAL(WITH_GWENGUI_GTK2, [test "$HAVE_GWENGUI_GTK2" = "1"])
467

    
468

    
469
###-------------------------------------------------------------------------
470
#
471
# check typemaker2
472
#
473

    
474
AC_MSG_CHECKING(typemaker2 binary)
475
AC_ARG_WITH(typemaker2-exe, 
476
  [  --with-typemaker2-exe=EXE      path and name of the executable typemaker2],
477
  [typemaker2_exe="$withval"],
478
  [typemaker2_exe="\$(gwenhywfar_bindir)/typemaker2"]
479
)
480
AC_MSG_RESULT($typemaker2_exe)
481
AC_SUBST(typemaker2_exe)
482

    
483

    
484

    
485
###-------------------------------------------------------------------------
486
#
487
# check xmlmerge
488
#
489
AC_MSG_CHECKING(xmlmerge)
490
AC_ARG_WITH(xmlmerge, [  --with-xmlmerge=PATH path and name of tool xmlmerge],
491
  [XMLMERGE="$withval"],
492
  [XMLMERGE="$gwenhywfar_dir/bin/xmlmerge"])
493
AC_SUBST(XMLMERGE)
494
AC_MSG_RESULT($XMLMERGE)
495

    
496

    
497

    
498
###-------------------------------------------------------------------------
499
#
500
# Check for GMP
501
#
502

    
503
# Allow the user to override the gmp_libs detection here
504
if test "x$gmp_libs" = "x"; then
505
  AC_CHECK_LIB(gmp, __gmpz_init, [have_gmp="yes"], [have_gmp="no"])
506
  AC_CHECK_HEADERS(gmp.h, [], [have_gmp="no"])
507
  if test "$have_gmp" != "yes"; then
508
    AC_MSG_ERROR([GMP is required, see http://swox.com/gmp])
509
  else
510
    gmp_libs="-lgmp"
511
  fi
512
fi
513
AC_SUBST(gmp_libs)
514

    
515

    
516

    
517
###-------------------------------------------------------------------------
518
#
519
# OS dependant settings
520
#
521

    
522
# Common settings; can be overridden per-OS below.
523
aqbanking_internal_libs="${abs_top_builddir}/src/libs/libaqbanking.la"
524
aqbanking_ldflags="-L\${libdir}"
525
aqbanking_libs="-laqbanking"
526
aqbanking_includes="-I\${includedir}/aqbanking6"
527
aqbanking_headerdir_am="\$(includedir)/aqbanking6"
528
aqbanking_headerdir="\${includedir}/aqbanking6"
529
aqbanking_plugindir="\${libdir}/aqbanking/plugins/${AQBANKING_SO_EFFECTIVE}"
530
aqbanking_pkgdatadir="\${datadir}/aqbanking"
531
aqbanking_symlinkdir="\$(top_builddir)/aqbanking6"
532

    
533
case "$OS_TYPE" in
534
    posix)
535
        aqbanking_sys_is_windows=0
536
    	;;
537
    windows)
538
        aqbanking_sys_is_windows=1
539
        AC_DEFINE_UNQUOTED(BUILDING_AQBANKING_DLL,1, [Define if DLL is built])
540
    	;;
541
esac
542
AM_CONDITIONAL(IS_WINDOWS, [test "$OS_TYPE" = "windows"])
543

    
544

    
545

    
546
###-------------------------------------------------------------------------
547
#
548
# check whether local installation mode is enabled
549
#
550

    
551
AC_MSG_CHECKING(whether local installation mode is wanted)
552
AC_ARG_ENABLE(local-install,
553
  [  --enable-local-install         allow local installation mode (default=no)],
554
  enable_local_install="$enableval",
555
  enable_local_install="no")
556
AC_MSG_RESULT($enable_local_install)
557

    
558
if test "$enable_local_install" != "no"; then
559
  AC_DEFINE(ENABLE_LOCAL_INSTALL, 1, [whether local install is wanted])
560
fi
561

    
562

    
563

    
564
###-------------------------------------------------------------------------
565
#
566
# check plugin search path
567
#
568
AC_MSG_CHECKING(plugin search dir)
569
AC_ARG_WITH(plugin-searchdir, [  --with-plugin-searchdir=DIR where to search for plugins],
570
  [aqbanking_plugin_searchdir="$withval"],
571
  [aqbanking_plugin_searchdir=""])
572

    
573
if test -z "${aqbanking_plugin_searchdir}"; then
574
  if test "$OSYSTEM" = "windows"; then
575
    aqbanking_plugin_searchdir="lib/aqbanking/plugins/${AQBANKING_SO_EFFECTIVE}"
576
  else
577
    if test "$enable_local_install" != "no"; then
578
      aqbanking_plugin_searchdir="lib/aqbanking/plugins/${AQBANKING_SO_EFFECTIVE}"
579
    else
580
      aqbanking_plugin_searchdir="$aqbanking_plugindir"
581
    fi
582
  fi
583
fi
584

    
585
AC_SUBST(aqbanking_plugin_searchdir)
586
AC_MSG_RESULT($aqbanking_plugin_searchdir)
587

    
588

    
589

    
590
###-------------------------------------------------------------------------
591
#
592
# check cfg search dir
593
#
594
AC_MSG_CHECKING(cfg search dir)
595
AC_ARG_WITH(cfg-searchdir, [  --with-cfg-searchdir=DIR where to search for cfg files],
596
  [aqbanking_cfg_searchdir="$withval"],
597
  [aqbanking_cfg_searchdir=""])
598

    
599
if test -z "$aqbanking_cfg_searchdir"; then
600
  if test "$OSYSTEM" = "windows"; then
601
    aqbanking_cfg_searchdir="etc"
602
  else
603
    if test "$enable_local_install" != "no"; then
604
      aqbanking_cfg_searchdir="etc"
605
    else
606
      aqbanking_cfg_searchdir="\$(sysconfdir)"
607
    fi
608
  fi
609
fi
610

    
611

    
612
AC_SUBST(aqbanking_cfg_searchdir)
613
AC_MSG_RESULT($aqbanking_cfg_searchdir)
614

    
615

    
616

    
617
###-------------------------------------------------------------------------
618
#
619
# check locale search dir
620
#
621
AC_MSG_CHECKING(locale search dir)
622
AC_ARG_WITH(locale-searchdir, [  --with-locale-searchdir=DIR where to search for locale files],
623
  [aqbanking_locale_searchdir="$withval"],
624
  [aqbanking_locale_searchdir=""])
625

    
626
if test -z "${aqbanking_locale_searchdir}"; then
627
  if test "$OSYSTEM" = "windows"; then
628
    aqbanking_locale_searchdir="share/locale"
629
  else
630
    if test "$enable_local_install" != "no"; then
631
      aqbanking_locale_searchdir="share/locale"
632
    else
633
      aqbanking_locale_searchdir="\$(localedir)"
634
    fi
635
  fi
636
fi
637

    
638
AC_SUBST(aqbanking_locale_searchdir)
639
AC_MSG_RESULT($aqbanking_locale_searchdir)
640

    
641

    
642

    
643
###-------------------------------------------------------------------------
644
#
645
# check data search dir
646
#
647
AC_MSG_CHECKING(data search dir)
648
AC_ARG_WITH(data-searchdir, [  --with-data-searchdir=DIR where to search for data files],
649
  [aqbanking_data_searchdir="$withval"],
650
  [aqbanking_data_searchdir=""])
651

    
652
if test -z "${aqbanking_data_searchdir}"; then
653
  if test "$OSYSTEM" = "windows"; then
654
    aqbanking_data_searchdir="share"
655
  else
656
    if test "$enable_local_install" != "no"; then
657
      aqbanking_data_searchdir="share"
658
    else
659
      aqbanking_data_searchdir="\$(datadir)"
660
    fi
661
  fi
662
fi
663

    
664
AC_SUBST(aqbanking_data_searchdir)
665
AC_MSG_RESULT($aqbanking_data_searchdir)
666

    
667

    
668

    
669
###-------------------------------------------------------------------------
670
# check for Distribution
671

    
672
AQ_DISTRIBUTION
673

    
674

    
675

    
676
###-------------------------------------------------------------------------
677
#
678
# check for I18N
679
#
680

    
681

    
682
# check whether i18n files are to be created
683
AC_CHECK_PROG(XGETTEXT,xgettext,xgettext, missing)
684

    
685
MAKE_I18N_FILES="yes"
686
if test "$XGETTEXT" = "missing"; then
687
  MAKE_I18N_FILES="no"
688
  AC_MSG_WARN([xgettext is missing. Locale suport is disabled.])
689
fi
690

    
691
AC_PATH_PROG([MSGFMT], [msgfmt], [missing])
692
if test "$MSGFMT" = "missing"; then
693
  MAKE_I18N_FILES="no"
694
  AC_MSG_WARN([msgfmt is missing. Locale suport is disabled.])
695
else
696
  # check for --qt argument of msgfmt
697
  AC_MSG_CHECKING(whether msgfmt understands --qt)
698
  if test "x${MSGFMT}" != "x"; then
699
    if ${MSGFMT} --qt --help >/dev/null 2>&1; then
700
      MSGFMT_SUPPORTS_QT=yes
701
    else
702
      MSGFMT_SUPPORTS_QT=no
703
    fi
704
  else
705
    MSGFMT_SUPPORTS_QT=no
706
  fi
707
  AC_MSG_RESULT($MSGFMT_SUPPORTS_QT)
708
fi
709

    
710
AC_SUBST(MAKE_I18N_FILES)
711
AC_SUBST(MSGFMT_SUPPORTS_QT)
712
AM_CONDITIONAL(IF_MAKE_I18N_FILES, [test "$MAKE_I18N_FILES" = "yes"])
713

    
714

    
715
# then check whether i18n support is to be compiled in
716
i18n_libs=""
717
HAVE_I18N="yes"
718
AC_CHECK_HEADERS([locale.h libintl.h], [], [HAVE_I18N="no"])
719
AC_CHECK_FUNCS([setlocale])
720

    
721
if test "$OS_TYPE" != "windows"; then
722
  oldlibs="$LIBS"
723
  LIBS=""
724
  AC_SEARCH_LIBS(gettext, intl, [], [HAVE_I18N="no"])
725
  i18n_libs="$LIBS"
726
  LIBS="$oldlibs"
727
else
728
  i18n_libs="-lintl"
729
fi
730

    
731
if test "$HAVE_I18N" != "NO"; then
732
  AC_DEFINE_UNQUOTED(HAVE_I18N, 1, [whether I18N is available])
733
fi
734

    
735
AC_SUBST(HAVE_I18N)
736
AC_SUBST(i18n_libs)
737

    
738

    
739

    
740
###-------------------------------------------------------------------------
741
#
742
# check for release
743
#
744
AC_MSG_CHECKING(whether this is an official release)
745
AC_ARG_ENABLE(release,
746
  [  --enable-release         make this an official release (default=no)],
747
  [ case "${enableval}" in
748
    yes) enable_release="yes";;
749
    no)  enable_release="no";;
750
    *) AC_MSG_ERROR(bad value ${enableval} for --enable-release);;
751
    esac
752
  ],
753
  enable_release="no")
754

    
755
if test "$enable_release" = "yes"; then
756
  STRIPALL="-s"
757
else
758
  STRIPALL=""
759
fi
760
AC_SUBST(STRIPALL)
761
AC_MSG_RESULT($enable_release)
762

    
763

    
764

    
765
###-------------------------------------------------------------------------
766
# Debug arguments for compilation
767

    
768
ACX_COMPILE_WARN()
769

    
770

    
771

    
772
###-------------------------------------------------------------------------
773
#
774
# Compiler check for symbol visibility
775
#
776
AC_CACHE_CHECK([whether compiler supports symbol visibility],
777
  ac_cv_hidden_visibility_attribute, [
778
    echo 'int __attribute__ ((visibility ("hidden"))) foo (void) { return 1; }' > conftest.c
779
    ac_cv_hidden_visibility_attribute=no
780
    if AC_TRY_COMMAND(${CC-cc} -Werror -S conftest.c -o conftest.s 1>&AS_MESSAGE_LOG_FD);
781
    then
782
      if grep '\.hidden.*foo' conftest.s >/dev/null;
783
      then
784
        ac_cv_hidden_visibility_attribute=yes
785
      fi
786
    fi
787
    rm -f conftest.*
788
  ])
789
if test $ac_cv_hidden_visibility_attribute = yes;
790
then
791
  AC_DEFINE(GCC_WITH_VISIBILITY_ATTRIBUTE, 1, [visibility])
792
  visibility_cflags="-fvisibility=hidden"
793
fi
794
AC_SUBST(visibility_cflags)
795

    
796

    
797

    
798
###-------------------------------------------------------------------------
799
#
800
# Subst
801
#
802
AS_SCRUB_INCLUDE(aqbanking_includes)
803
AC_SUBST(aqbanking_sys_is_windows)
804
AC_SUBST(aqbanking_includes)
805
AC_SUBST(aqbanking_internal_libs)
806
AC_SUBST(aqbanking_ldflags)
807
AC_SUBST(aqbanking_libs)
808
AC_SUBST(aqbanking_plugindir)
809
AC_SUBST(aqbanking_pkgdatadir)
810
AC_SUBST(aqbanking_symlinkdir)
811
AC_SUBST(aqbanking_headerdir_am)
812
AC_SUBST(aqbanking_headerdir)
813

    
814

    
815
###-------------------------------------------------------------------------
816
#
817
# Check for additional aclocal flags
818
#
819
ADD_ACLOCAL_FLAGS=""
820
for A in "${GWEN_PREFIX}/share/aclocal" \
821
	 "${prefix}/share/aclocal"; do 
822
  if test -d "${A}"; then 
823
    ADD_ACLOCAL_FLAGS="${ADD_ACLOCAL_FLAGS} -I ${A}"
824
  fi
825
done
826
AC_SUBST(ADD_ACLOCAL_FLAGS)
827

    
828

    
829

    
830
###-------------------------------------------------------------------------
831
#
832
# AqBanking modules
833
#
834

    
835
aqbanking_modules=". types"
836
aqbankingpp_modules="."
837

    
838
AC_SUBST(aqbanking_modules)
839
AC_SUBST(aqbankingpp_modules)
840

    
841

    
842

    
843
###-------------------------------------------------------------------------
844
#
845
# docpath
846
#
847
AC_MSG_CHECKING(docpath)
848
AC_ARG_WITH(docpath, [  --with-docpath=DIR where to store the apidoc],
849
  [docpath="$withval"],
850
  [docpath="${HOME}/apidoc"])
851
AC_SUBST(docpath)
852
AC_MSG_RESULT($docpath)
853

    
854

    
855
###-------------------------------------------------------------------------
856
#
857
# check for doc type
858
#
859
AC_MSG_CHECKING(if full docu should be created)
860
AC_ARG_ENABLE(full-doc,
861
  [  --enable-full-doc         enable creating full apidoc (default=no)],
862
  [ case "${enableval}" in
863
    yes) enable_fulldoc="yes";;
864
    no)  enable_fulldoc="no";;
865
    *) AC_MSG_ERROR(bad value ${enableval} for --enable-full-doc);;
866
    esac
867
  ],
868
  enable_fulldoc="no")
869

    
870
if test "$enable_fulldoc" = "yes"; then
871
	DOXYGEN_INPUT="listdoc.h src"
872
        DOXYGEN_DEFINE=""
873
        DOXYGEN_FILE_PATTERNS="*.h *.hpp *.c *.cpp"
874
        DOXYGEN_EXCLUDE_PATTERNS=""
875
else
876
	DOXYGEN_DEFINE="DOXYGEN_HIDE"
877
	DOXYGEN_INPUT="listdoc.h \
878
                       aqbanking6/banking.h \
879
                       aqbanking6/banking_bankinfo.h \
880
                       aqbanking6/banking_dialogs.h \
881
                       aqbanking6/banking_online.h \
882
                       aqbanking6/banking_transaction.h \
883
                       aqbanking6/error.h \
884
                       aqbanking6/account_type.h \
885
                       aqbanking6/value.h \
886
                       aqbanking6/account_spec.h \
887
                       aqbanking6/balance.h \
888
                       aqbanking6/bankinfo.h \
889
                       aqbanking6/bankinfoservice.h \
890
                       aqbanking6/document.h \
891
                       aqbanking6/imexporter_accountinfo.h \
892
                       aqbanking6/imexporter_context.h \
893
                       aqbanking6/message.h \
894
                       aqbanking6/security.h \
895
                       aqbanking6/transaction.h \
896
                       aqbanking6/transactionlimits.h\
897
                      "
898
        DOXYGEN_FILE_PATTERNS="*.h *.hpp"
899
        DOXYGEN_EXCLUDE_PATTERNS="*_p.h"
900
fi
901
AC_SUBST(DOXYGEN_INPUT)
902
AC_SUBST(DOXYGEN_DEFINE)
903
AC_SUBST(DOXYGEN_FILE_PATTERNS)
904
AC_SUBST(DOXYGEN_EXCLUDE_PATTERNS)
905
AC_MSG_RESULT($enable_fulldoc)
906

    
907

    
908

    
909
###-------------------------------------------------------------------------
910
#
911
# search for tag files
912
#
913
AC_MSG_CHECKING(doxygen tag files)
914
DOXYGEN_TAGFILES=""
915
DOXYGEN_TAGFILEPATHS=""
916
if test -d "${docpath}"; then
917
  tagfiles="`cd ${docpath} && ls *.tag`"
918
  if test -n "${tagfiles}"; then
919
    # remove own package from list
920
    tagfiles="`echo ${tagfiles} | ${SED} -e s/${PACKAGE}.tag//`"
921

    
922
    # add every remaining tag file
923
    for ff in ${tagfiles}; do
924
      DOXYGEN_TAGFILES="${DOXYGEN_TAGFILES} ${docpath}/${ff}=${docpath}/`basename -s .tag ${ff}`"
925
    done
926
  fi
927
fi
928
if test -z "${DOXYGEN_TAGFILES}"; then
929
  AC_MSG_RESULT(none)
930
else
931
  AC_MSG_RESULT(found)
932
fi
933
AC_SUBST(DOXYGEN_TAGFILES)
934

    
935

    
936

    
937
###-------------------------------------------------------------------------
938
#
939
# check for dependencies of backends
940
#  (nothing to check for right now)
941

    
942
dependencies_ok="yes"
943

    
944

    
945

    
946
###-------------------------------------------------------------------------
947
#
948
# Configure stuff for backend AqHBCI
949
#
950

    
951
# Common settings; can be overridden per-OS below.
952
aqhbci_internal_libs="${abs_top_builddir}/src/libs/plugins/backends/aqhbci/libaqhbci.la"
953
aqhbci_ldflags="-L\${libdir}"
954
aqhbci_includes="${aqbanking_includes}"
955
aqhbci_libs="-laqhbci"
956
with_aqhbci="no"
957

    
958
case "$aqbanking_backends" in *aqhbci*)
959
  with_aqhbci="yes"
960
  case "$OS_TYPE" in
961
      posix)
962
          ;;
963
      windows)
964
          AC_DEFINE_UNQUOTED(BUILDING_AQHBCI_DLL,1, [Define if DLL is built])
965
          ;;
966
  esac
967
  ;;
968
esac
969

    
970
AS_SCRUB_INCLUDE(aqhbci_includes)
971
AC_SUBST(aqhbci_includes)
972
AC_SUBST(aqhbci_internal_libs)
973
AC_SUBST(aqhbci_libs)
974
AC_SUBST(aqhbci_ldflags)
975
AC_SUBST(with_aqhbci)
976

    
977

    
978

    
979
###-------------------------------------------------------------------------
980
#
981
# check AqHBCI data dir
982
#
983
AC_MSG_CHECKING(aqhbci data dir)
984
AC_ARG_WITH(aqhbci-datadir, [  --with-aqhbci-datadir=DIR where to search for data files],
985
  [aqhbci_datadir="$withval"],
986
  [aqhbci_datadir="$aqhbci_data"])
987
AC_SUBST(aqhbci_datadir)
988
AC_MSG_RESULT($aqhbci_datadir)
989

    
990

    
991

    
992
###-------------------------------------------------------------------------
993
#
994
# Configure stuff for backend AqOfxConnect
995
#
996

    
997
# Common settings
998
aqofxconnect_internal_libs="${abs_top_builddir}/src/libs/plugins/backends/aqofxconnect/libaqofxconnect.la"
999
aqofxconnect_includes="${aqbanking_includes}"
1000
aqofxconnect_libs="-L\${libdir} -laqofxconnect"
1001

    
1002
case "$aqbanking_backends" in *aqofxconnect*)
1003
  case "$OS_TYPE" in
1004
      posix)
1005
          ;;
1006
      windows)
1007
          AC_DEFINE_UNQUOTED(BUILDING_AQOFXCONNECT_DLL,1, [Define if DLL is built])
1008
          ;;
1009
  esac
1010
  ;;
1011
esac
1012

    
1013
AS_SCRUB_INCLUDE(aqofxconnect_includes)
1014
AC_SUBST(aqofxconnect_includes)
1015
AC_SUBST(aqofxconnect_internal_libs)
1016
AC_SUBST(aqofxconnect_libs)
1017
#AC_DEFINE_UNQUOTED(AQOFXCONNECT_DATA, "${aqofxconnect_data}", [data dir])
1018

    
1019

    
1020
###-------------------------------------------------------------------------
1021
#
1022
# Configure stuff for backend AqPaypal
1023
#
1024

    
1025
# Common settings
1026
aqpaypal_internal_libs="${abs_top_builddir}/src/libs/plugins/backends/aqpaypal/libaqpaypal.la"
1027
aqpaypal_includes="${aqbanking_includes}"
1028
aqpaypal_libs="-L\${libdir} -laqpaypal"
1029

    
1030
case "$aqbanking_backends" in *aqpaypal*)
1031
  case "$OS_TYPE" in
1032
      posix)
1033
          ;;
1034
      windows)
1035
          AC_DEFINE_UNQUOTED(BUILDING_AQPAYPAL_DLL,1, [Define if DLL is built])
1036
          ;;
1037
  esac
1038
  ;;
1039
esac
1040

    
1041
AS_SCRUB_INCLUDE(aqpaypal_includes)
1042
AC_SUBST(aqpaypal_includes)
1043
AC_SUBST(aqpaypal_internal_libs)
1044
AC_SUBST(aqpaypal_libs)
1045
#AC_DEFINE_UNQUOTED(AQPAYPAL_DATA, "${aqpaypal_data}", [data dir])
1046

    
1047

    
1048
###-------------------------------------------------------------------------
1049
#
1050
# Configure stuff for backend AqEBICS
1051
#
1052

    
1053
# Common settings; can be overridden per-OS below.
1054
aqebics_internal_libs="${abs_top_builddir}/src/libs/plugins/backends/aqebics/plugin/libaqebics.la"
1055
aqebics_ldflags="-L\${libdir}"
1056
aqebics_includes="${aqbanking_includes}"
1057
aqebics_libs="-laqebics"
1058
with_aqebics="no"
1059

    
1060
case "$aqbanking_backends" in *aqebics*)
1061
  with_aqebics="yes"
1062
  case "$OS_TYPE" in
1063
      posix)
1064
          ;;
1065
      windows)
1066
          AC_DEFINE_UNQUOTED(BUILDING_AQEBICS_DLL,1, [Define if DLL is built])
1067
          ;;
1068
  esac
1069
  ;;
1070
esac
1071

    
1072
AS_SCRUB_INCLUDE(aqebics_includes)
1073
AC_SUBST(aqebics_includes)
1074
AC_SUBST(aqebics_internal_libs)
1075
AC_SUBST(aqebics_libs)
1076
AC_SUBST(aqebics_ldflags)
1077
AC_SUBST(with_aqebics)
1078

    
1079

    
1080

    
1081
###-------------------------------------------------------------------------
1082
#
1083
# check AqEBICS data dir
1084
#
1085
AC_MSG_CHECKING(aqebics data dir)
1086
AC_ARG_WITH(aqebics-datadir, [  --with-aqebics-datadir=DIR where to search for data files],
1087
  [aqebics_datadir="$withval"],
1088
  [aqebics_datadir="$aqebics_data"])
1089
AC_SUBST(aqebics_datadir)
1090
AC_MSG_RESULT($aqebics_datadir)
1091

    
1092

    
1093

    
1094

    
1095
###-------------------------------------------------------------------------
1096
#
1097
# Check for xmlsec
1098
#
1099
if test "$with_aqebics" = "yes"; then
1100
  AC_MSG_CHECKING(for build requirements needed by EBICS backend)
1101
  AC_MSG_RESULT()
1102
  PKG_CHECK_MODULES(XMLSEC,  [xmlsec1-gnutls >= 1.0.0])
1103
  PKG_CHECK_MODULES(LIBXML,  [libxml-2.0])
1104
  PKG_CHECK_MODULES(LIBXSLT, [libxslt])
1105
  AQEBICS_CFLAGS="$XMLSEC_CFLAGS $LIBXML_CFLAGS $LIBXSLT_CFLAGS"
1106
  AQEBICS_LIBS="$XMLSEC_LIBS $LIBXML_LIBS $LIBXSLT_LIBS"
1107
  AC_SUBST(AQEBICS_CFLAGS)
1108
  AC_SUBST(AQEBICS_LIBS)
1109
fi
1110

    
1111

    
1112

    
1113

    
1114
###-------------------------------------------------------------------------
1115
#
1116
# check for plugin init
1117
#
1118
AC_MSG_CHECKING(if plugin init is wanted)
1119
AC_ARG_ENABLE(init-plugins,
1120
  [  --enable-init-plugins             enable plugin init (default=yes)],
1121
  enable_init_plugins="$enableval",
1122
  enable_init_plugins="yes")
1123
AC_MSG_RESULT($enable_init_plugins)
1124

    
1125
if test "$enable_init_plugins" != "no"; then
1126
  AC_DEFINE(AQBANKING_ENABLE_INIT_PLUGINS, 1, [if plugin init is wanted])
1127
fi
1128

    
1129

    
1130

    
1131
###-------------------------------------------------------------------------
1132
#
1133
# check whether aqbanking is a subproject to another one
1134
#
1135

    
1136
AC_MSG_CHECKING(if AqBanking is a subproject)
1137
AC_ARG_ENABLE(aqb-subproject,
1138
  [  --enable-aqb-subproject         make gwen only a subproject (default=no)],
1139
  enable_aqb_subproject="$enableval",
1140
  enable_aqb_subproject="no")
1141
AC_MSG_RESULT($enable_aqb_subproject)
1142

    
1143
if test "$enable_aqb_subproject" != "no"; then
1144
  AC_DEFINE(AQBANKING_IS_SUBPROJECT, 1, [whether aqb is a subproject])
1145
fi
1146

    
1147

    
1148

    
1149
###-------------------------------------------------------------------------
1150
#
1151
# check whether aqbanking-cli is enabled
1152
#
1153

    
1154
AC_MSG_CHECKING(whether aqbanking-cli is wanted)
1155
AC_ARG_ENABLE(cli,
1156
  [  --enable-cli         build aqbanking-cli (default=yes)],
1157
  enable_cli="$enableval",
1158
  enable_cli="yes")
1159
AC_MSG_RESULT($enable_cli)
1160

    
1161
AM_CONDITIONAL(ENABLE_CLI, [test "$enable_cli" = "yes"])
1162

    
1163
AC_ARG_WITH(cli-version-string, 
1164
  [  --with-cli-version-string      list of additional libraries],
1165
  [AQBANKING_CLI_VERSION_STRING="$withval"],
1166
  [AQBANKING_CLI_VERSION_STRING="$AQBANKING_VERSION_STRING"]
1167
)
1168

    
1169
AC_SUBST(AQBANKING_CLI_VERSION_STRING)
1170

    
1171

    
1172
###-------------------------------------------------------------------------
1173
#
1174
# check whether tutorials are to be built
1175
#
1176

    
1177
AC_MSG_CHECKING(whether tutorials are to be built)
1178
AC_ARG_ENABLE(tutorials,
1179
  [  --enable-tutorials         build tutorials (default=yes)],
1180
  [ case "${enableval}" in
1181
    yes) TUTORIALS="tutorials";;
1182
    no)  TUTORIALS="";;
1183
    *) AC_MSG_ERROR(bad value ${enableval} for --enable-tutorials);;
1184
    esac
1185
  ],
1186
  [
1187
   TUTORIALS="tutorials"
1188
   enableval="yes"
1189
  ])
1190
AC_MSG_RESULT($enableval)
1191
AC_SUBST(TUTORIALS)
1192

    
1193

    
1194
###-------------------------------------------------------------------------
1195
#
1196
# Cleanup includes, define all_XXX
1197
#
1198

    
1199
AS_SCRUB_INCLUDE(all_includes)
1200
AC_SUBST(all_includes)
1201
AC_SUBST(all_libraries)
1202

    
1203
AC_SUBST(aqbanking_backends)
1204

    
1205

    
1206
# Adjust CFLAGS and LDFLAGS on Windows
1207
case "$OS_TYPE" in
1208
    windows)
1209
	# GnuCash compiles with this; maybe we need this, too?
1210
	#CFLAGS="${CFLAGS} -mms-bitfields"
1211
	LDFLAGS="${LDFLAGS} -no-undefined -mwindows"
1212
    ;;
1213
esac
1214

    
1215

    
1216

    
1217
###-------------------------------------------------------------------------
1218
#
1219
# Output files
1220
#
1221

    
1222
AC_CONFIG_FILES([
1223
  mksymlinks.sh
1224
  admin/Makefile
1225
  doc/Makefile
1226
  m4/Makefile
1227
  src/Makefile
1228
  src/libs/Makefile
1229
  src/libs/aqbanking/Makefile
1230
  src/libs/aqbanking/version.h
1231
  src/libs/aqbanking/system.h
1232
  src/libs/aqbanking/dialogs/Makefile
1233
  src/libs/aqbanking/types/Makefile
1234
  src/libs/aqbanking/gui/Makefile
1235
  src/libs/aqbanking/typemaker2/Makefile
1236
  src/libs/aqbanking/typemaker2/c/Makefile
1237
  src/libs/aqbanking/backendsupport/Makefile
1238
  src/libs/aqbankingpp/Makefile
1239
  src/libs/plugins/Makefile
1240
  src/libs/plugins/bankinfo/Makefile
1241
  src/libs/plugins/bankinfo/de/Makefile
1242
  src/libs/plugins/bankinfo/de/de.xml
1243
  src/libs/plugins/bankinfo/generic/Makefile
1244
  src/libs/plugins/imexporters/Makefile
1245
  src/libs/plugins/imexporters/eri2/Makefile
1246
  src/libs/plugins/imexporters/eri2/eri2.xml
1247
  src/libs/plugins/imexporters/eri2/profiles/Makefile
1248
  src/libs/plugins/imexporters/ofx/Makefile
1249
  src/libs/plugins/imexporters/ofx/ofx.xml
1250
  src/libs/plugins/imexporters/ofx/parser/Makefile
1251
  src/libs/plugins/imexporters/ofx/profiles/Makefile
1252
  src/libs/plugins/imexporters/swift/Makefile
1253
  src/libs/plugins/imexporters/swift/swift.xml
1254
  src/libs/plugins/imexporters/swift/profiles/Makefile
1255
  src/libs/plugins/imexporters/csv/Makefile
1256
  src/libs/plugins/imexporters/csv/csv.xml
1257
  src/libs/plugins/imexporters/csv/profiles/Makefile
1258
  src/libs/plugins/imexporters/openhbci1/Makefile
1259
  src/libs/plugins/imexporters/openhbci1/openhbci1.xml
1260
  src/libs/plugins/imexporters/openhbci1/profiles/Makefile
1261
  src/libs/plugins/imexporters/qif/Makefile
1262
  src/libs/plugins/imexporters/qif/qif.xml
1263
  src/libs/plugins/imexporters/qif/profiles/Makefile
1264
  src/libs/plugins/imexporters/yellownet/Makefile
1265
  src/libs/plugins/imexporters/yellownet/yellownet.xml
1266
  src/libs/plugins/imexporters/yellownet/profiles/Makefile
1267
  src/libs/plugins/imexporters/xmldb/Makefile
1268
  src/libs/plugins/imexporters/xmldb/xmldb.xml
1269
  src/libs/plugins/imexporters/xmldb/profiles/Makefile
1270
  src/libs/plugins/imexporters/sepa/Makefile
1271
  src/libs/plugins/imexporters/sepa/sepa.xml
1272
  src/libs/plugins/imexporters/sepa/profiles/Makefile
1273
  src/libs/plugins/imexporters/ctxfile/Makefile
1274
  src/libs/plugins/imexporters/ctxfile/ctxfile.xml
1275
  src/libs/plugins/imexporters/ctxfile/profiles/Makefile
1276
  src/libs/plugins/imexporters/q43/Makefile
1277
  src/libs/plugins/imexporters/q43/q43.xml
1278
  src/libs/plugins/imexporters/q43/profiles/Makefile
1279
  src/libs/plugins/imexporters/camt/Makefile
1280
  src/libs/plugins/imexporters/camt/camt.xml
1281
  src/libs/plugins/imexporters/camt/profiles/Makefile
1282
  src/libs/plugins/imexporters/xml/Makefile
1283
  src/libs/plugins/imexporters/xml/xml.xml
1284
  src/libs/plugins/imexporters/xml/data/Makefile
1285
  src/libs/plugins/imexporters/xml/profiles/Makefile
1286
  src/libs/plugins/parsers/Makefile
1287
  src/libs/plugins/parsers/swift/Makefile
1288
  src/libs/plugins/parsers/swift/swift.xml
1289
  src/libs/plugins/backends/Makefile
1290
  src/libs/plugins/backends/aqhbci/Makefile
1291
  src/libs/plugins/backends/aqhbci/aqhbci.xml
1292
  src/libs/plugins/backends/aqhbci/dialogs/Makefile
1293
  src/libs/plugins/backends/aqhbci/header.xml
1294
  src/libs/plugins/backends/aqhbci/banking/Makefile
1295
  src/libs/plugins/backends/aqhbci/msglayer/Makefile
1296
  src/libs/plugins/backends/aqhbci/joblayer/Makefile
1297
  src/libs/plugins/backends/aqhbci/applayer/Makefile
1298
  src/libs/plugins/backends/aqhbci/ajobs/Makefile
1299
  src/libs/plugins/backends/aqhbci/admjobs/Makefile
1300
  src/libs/plugins/backends/aqhbci/applayer/xml/Makefile
1301
  src/libs/plugins/backends/aqhbci/control/Makefile
1302
  src/libs/plugins/backends/aqhbci/tan/Makefile
1303
  src/libs/plugins/backends/aqhbci/version.h
1304
  src/libs/plugins/backends/aqofxconnect/Makefile
1305
  src/libs/plugins/backends/aqofxconnect/aqofxconnect.xml
1306
  src/libs/plugins/backends/aqofxconnect/libofxhome/Makefile
1307
  src/libs/plugins/backends/aqpaypal/Makefile
1308
  src/libs/plugins/backends/aqpaypal/aqpaypal.xml
1309
  src/libs/plugins/backends/aqpaypal/control/Makefile
1310
  src/libs/plugins/backends/aqnone/Makefile
1311
  src/libs/plugins/backends/aqnone/aqnone.xml
1312
  src/libs/plugins/backends/aqebics/Makefile
1313
  src/libs/plugins/backends/aqebics/aqebics.xml
1314
  src/libs/plugins/backends/aqebics/client/Makefile
1315
  src/libs/plugins/backends/aqebics/dialogs/Makefile
1316
  src/libs/plugins/backends/aqebics/msg/Makefile
1317
  src/libs/plugins/backends/aqebics/control/Makefile
1318
  src/libs/plugins/backends/aqebics/requests/Makefile
1319
  src/libs/plugins/backends/aqfints/Makefile
1320
  src/libs/plugins/backends/aqfints/aqfints.xml
1321
  src/libs/plugins/backends/aqfints/msglayer/Makefile
1322
  src/libs/plugins/backends/aqfints/msglayer/parser/Makefile
1323
  src/libs/plugins/backends/aqfints/servicelayer/Makefile
1324
  src/libs/plugins/backends/aqfints/servicelayer/xml/Makefile
1325
  src/libs/plugins/backends/aqfints/servicelayer/bpd/Makefile
1326
  src/libs/plugins/backends/aqfints/servicelayer/upd/Makefile
1327
  src/libs/plugins/backends/aqfints/transportlayer/Makefile
1328
  src/libs/plugins/backends/aqfints/sessionlayer/Makefile
1329
  src/libs/plugins/backends/aqfints/sessionlayer/pintan/Makefile
1330
  src/test/Makefile
1331
  src/tools/Makefile
1332
  src/tools/aqbanking-cli/Makefile
1333
  src/tools/mkdeinfo/Makefile
1334
  tutorials/Makefile
1335
  po/Makefile
1336
  Doxyfile
1337
  Makefile
1338
  aqbanking-config.in
1339
  aqbanking.pc
1340
  aqbanking.spec
1341
  aqbanking.iss
1342
  aqbanking-config.cmake
1343
  aqbanking-config-version.cmake
1344
])
1345
AC_OUTPUT
1346

    
1347

    
1348

    
1349
###-------------------------------------------------------------------------
1350
#
1351
# Summary
1352
#
1353

    
1354
echo
1355
echo
1356
echo "Summary"
1357
echo "----------------------------------------------------"
1358
echo "AqBanking version       : $AQBANKING_VERSION_FULL_STRING"
1359
echo "Local Installation Mode : $enable_local_install"
1360
echo "Prefix                  : $prefix"
1361
echo "Exec-Prefix             : $exec_prefix"
1362
echo "Libdir                  : $libdir"
1363
echo "Cfg Search Folder       : $aqbanking_cfg_searchdir"
1364
echo "Data Search Folder      : $aqbanking_data_searchdir"
1365
echo "Locale Search Folder    : $aqbanking_locale_searchdir"
1366
echo "Plugin Search Folder    : $aqbanking_plugin_searchdir"
1367
echo "Symbol Visibility       : $visibility_supported"
1368
echo "Build AqBanking-CLI     : $enable_cli"
1369
echo "CLI Version String      : $AQBANKING_CLI_VERSION_STRING"
1370
echo
1371

    
1372
echo
1373
echo "Plugins"
1374
echo "----------------------------------------------------"
1375
echo "  Backends              : $aqbanking_backends"
1376
echo "  Im-/Exporters         : $aqbanking_imexporters"
1377
echo "  Parsers               : $aqbanking_parsers"
1378
echo "  Bank Infos            : $aqbanking_bankinfos"
1379
echo
1380

    
1381
echo "----------------------------------------------------"
1382
echo "You can now run \"make\" (or gmake on FreeBSD) to compile."
1383

    
1384