-
Notifications
You must be signed in to change notification settings - Fork 1
/
configure.ac
1571 lines (1289 loc) · 44.4 KB
/
configure.ac
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
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# Process this file with autoconf to produce a configure script.
###-------------------------------------------------------------------------
#
# The following line makes sure that this file is always touched when a new
# revision is checked out.
#
# $Rev: 2550 $
#
AC_PREREQ(2.56)
AC_INIT
AC_CANONICAL_BUILD
AC_CANONICAL_HOST
AC_CONFIG_SRCDIR([README])
AC_CONFIG_HEADERS([config.h])
###-------------------------------------------------------------------------
#
# AqBanking versions
#
AQBANKING_VERSION_MAJOR=5
AQBANKING_VERSION_MINOR=5
AQBANKING_VERSION_PATCHLEVEL=0
AQBANKING_VERSION_BUILD=2
dnl "stable", "rcX", "betaX", "svn"
AQBANKING_VERSION_TAG="git"
###-------------------------------------------------------------------------
#
# SO versions
#
#
# AqBanking
#
AQBANKING_SO_CURRENT=39
AQBANKING_SO_AGE=5
AQBANKING_SO_REVISION=2
AQBANKING_SO_EFFECTIVE="`echo \$(($AQBANKING_SO_CURRENT-$AQBANKING_SO_AGE))`"
#
# backends
#
AQHBCI_SO_CURRENT=22
AQHBCI_SO_AGE=0
AQHBCI_SO_REVISION=0
AQHBCI_SO_EFFECTIVE="`echo \$(($AQHBCI_SO_CURRENT-$AQHBCI_SO_AGE))`"
AQOFXCONNECT_SO_CURRENT=7
AQOFXCONNECT_SO_AGE=0
AQOFXCONNECT_SO_REVISION=2
AQOFXCONNECT_SO_EFFECTIVE="`echo \$(($AQOFXCONNECT_SO_CURRENT-$AQOFXCONNECT_SO_AGE))`"
AQEBICS_SO_CURRENT=2
AQEBICS_SO_AGE=1
AQEBICS_SO_REVISION=9
AQEBICS_SO_EFFECTIVE="`echo \$(($AQEBICS_SO_CURRENT-$AQEBICS_SO_AGE))`"
###-------------------------------------------------------------------------
#
# Generate version strings and BUILD
#
SVN="svn"
AQBANKING_VERSION_FULL_STRING="${AQBANKING_VERSION_MAJOR}.${AQBANKING_VERSION_MINOR}.${AQBANKING_VERSION_PATCHLEVEL}.${AQBANKING_VERSION_BUILD}${AQBANKING_VERSION_TAG}"
AQBANKING_VERSION_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL"
case "$AQBANKING_VERSION_TAG" in
svn|cvs)
rev=`LC_ALL="C" $SVN info|grep 'Last Changed Rev'|cut -d' ' -f4`
if test "x$rev" != "x" ; then
AQBANKING_VERSION_FULL_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.${AQBANKING_VERSION_PATCHLEVEL}${AQBANKING_VERSION_TAG}-r${rev}"
fi
;;
git)
AQBANKING_VERSION_FULL_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.${AQBANKING_VERSION_PATCHLEVEL}.${AQBANKING_VERSION_BUILD}"
;;
esac
###-------------------------------------------------------------------------
#
# Versions (all versions are now linked to AqBanking versions, so the lines
# here don't have to be changed)
#
AQHBCI_VERSION_MAJOR=$AQBANKING_VERSION_MAJOR
AQHBCI_VERSION_MINOR=$AQBANKING_VERSION_MINOR
AQHBCI_VERSION_PATCHLEVEL=$AQBANKING_VERSION_PATCHLEVEL
AQHBCI_VERSION_BUILD=$AQBANKING_VERSION_BUILD
AQHBCI_VERSION_TAG=$AQBANKING_VERSION_TAG
AQHBCI_VERSION_FULL_STRING="$AQBANKING_VERSION_FULL_STRING"
AQHBCI_VERSION_STRING="$AQBANKING_VERSION_STRING"
AQOFXCONNECT_VERSION_MAJOR=$AQBANKING_VERSION_MAJOR
AQOFXCONNECT_VERSION_MINOR=$AQBANKING_VERSION_MINOR
AQOFXCONNECT_VERSION_PATCHLEVEL=$AQBANKING_VERSION_PATCHLEVEL
AQOFXCONNECT_VERSION_BUILD=$AQBANKING_VERSION_BUILD
AQOFXCONNECT_VERSION_TAG=$AQBANKING_VERSION_TAG
AQOFXCONNECT_VERSION_FULL_STRING="$AQBANKING_VERSION_FULL_STRING"
AQOFXCONNECT_VERSION_STRING="$AQBANKING_VERSION_STRING"
AQEBICS_VERSION_MAJOR=$AQBANKING_VERSION_MAJOR
AQEBICS_VERSION_MINOR=$AQBANKING_VERSION_MINOR
AQEBICS_VERSION_PATCHLEVEL=$AQBANKING_VERSION_PATCHLEVEL
AQEBICS_VERSION_BUILD=$AQBANKING_VERSION_BUILD
AQEBICS_VERSION_TAG=$AQBANKING_VERSION_TAG
AQEBICS_VERSION_FULL_STRING="$AQBANKING_VERSION_FULL_STRING"
AQEBICS_VERSION_STRING="$AQBANKING_VERSION_STRING"
###-------------------------------------------------------------------------
#
# datetime
#
DATETIME="`date +\"%Y%m%d%H%M%S\"`"
AC_SUBST(DATETIME)
###-------------------------------------------------------------------------
#
# Create release strings
#
case "$AQBANKING_VERSION_TAG" in
cvs|svn)
AQBANKING_VERSION_RELEASE_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL.r${AQBANKING_VERSION_BUILD}"
;;
git)
AQBANKING_VERSION_RELEASE_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL.${AQBANKING_VERSION_BUILD}-${AQBANKING_VERSION_TAG}"
;;
stable)
AQBANKING_VERSION_RELEASE_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL"
;;
*)
AQBANKING_VERSION_RELEASE_STRING="$AQBANKING_VERSION_MAJOR.$AQBANKING_VERSION_MINOR.$AQBANKING_VERSION_PATCHLEVEL"
# add TAG
AQBANKING_VERSION_RELEASE_STRING="${AQBANKING_VERSION_RELEASE_STRING}${AQBANKING_VERSION_TAG}"
;;
esac
AQHBCI_VERSION_RELEASE_STRING="$AQBANKING_RELEASE_STRING"
AQOFXCONNECT_VERSION_RELEASE_STRING="$AQBANKING_RELEASE_STRING"
AQEBICS_VERSION_RELEASE_STRING="$AQBANKING_RELEASE_STRING"
###-------------------------------------------------------------------------
#
# SUBST and DEFINE versions
#
AC_SUBST(AQBANKING_VERSION_MAJOR)
AC_SUBST(AQBANKING_VERSION_MINOR)
AC_SUBST(AQBANKING_VERSION_PATCHLEVEL)
AC_SUBST(AQBANKING_VERSION_BUILD)
AC_SUBST(AQBANKING_VERSION_TAG)
AC_SUBST(AQBANKING_VERSION_FULL_STRING)
AC_SUBST(AQBANKING_VERSION_STRING)
AC_SUBST(AQBANKING_VERSION_RELEASE_STRING)
AC_SUBST(AQBANKING_SO_CURRENT)
AC_SUBST(AQBANKING_SO_REVISION)
AC_SUBST(AQBANKING_SO_AGE)
AC_SUBST(AQBANKING_SO_EFFECTIVE)
AC_DEFINE_UNQUOTED(AQBANKING_SO_EFFECTIVE_STR, "$AQBANKING_SO_EFFECTIVE",
[effective SO version])
AM_INIT_AUTOMAKE(aqbanking, $AQBANKING_VERSION_RELEASE_STRING)
#
# same for AqHBCI
#
AC_SUBST(AQHBCI_VERSION_MAJOR)
AC_SUBST(AQHBCI_VERSION_MINOR)
AC_SUBST(AQHBCI_VERSION_PATCHLEVEL)
AC_SUBST(AQHBCI_VERSION_BUILD)
AC_SUBST(AQHBCI_VERSION_TAG)
AC_SUBST(AQHBCI_VERSION_FULL_STRING)
AC_SUBST(AQHBCI_VERSION_STRING)
AC_SUBST(AQHBCI_VERSION_RELEASE_STRING)
AC_DEFINE_UNQUOTED(AQHBCI_VERSION_MAJOR,$AQHBCI_VERSION_MAJOR,
[major version])
AC_DEFINE_UNQUOTED(AQHBCI_VERSION_MINOR,$AQHBCI_VERSION_MINOR,
[minor version])
AC_DEFINE_UNQUOTED(AQHBCI_VERSION_PATCHLEVEL,$AQHBCI_VERSION_PATCHLEVEL,
[patchlevel])
AC_DEFINE_UNQUOTED(AQHBCI_VERSION_BUILD,$AQHBCI_VERSION_BUILD, [build])
AC_DEFINE_UNQUOTED(AQHBCI_VERSION_STRING,"$AQHBCI_VERSION_STRING",
[version string])
AC_DEFINE_UNQUOTED(AQHBCI_VERSION_FULL_STRING,"$AQHBCI_VERSION_FULL_STRING",
[full version string])
AC_DEFINE_UNQUOTED(AQHBCI_VERSION_TAG,$AQHBCI_VERSION_TAG, [tag])
AC_SUBST(AQHBCI_SO_CURRENT)
AC_SUBST(AQHBCI_SO_REVISION)
AC_SUBST(AQHBCI_SO_AGE)
AC_SUBST(AQHBCI_SO_EFFECTIVE)
AC_DEFINE_UNQUOTED(AQHBCI_SO_EFFECTIVE_STR, "$AQHBCI_SO_EFFECTIVE",
[effective SO version])
#
# same for AqOFXCONNECT
#
AC_SUBST(AQOFXCONNECT_VERSION_MAJOR)
AC_SUBST(AQOFXCONNECT_VERSION_MINOR)
AC_SUBST(AQOFXCONNECT_VERSION_PATCHLEVEL)
AC_SUBST(AQOFXCONNECT_VERSION_BUILD)
AC_SUBST(AQOFXCONNECT_VERSION_TAG)
AC_SUBST(AQOFXCONNECT_VERSION_FULL_STRING)
AC_SUBST(AQOFXCONNECT_VERSION_STRING)
AC_SUBST(AQOFXCONNECT_VERSION_RELEASE_STRING)
AC_DEFINE_UNQUOTED(AQOFXCONNECT_VERSION_MAJOR,$AQOFXCONNECT_VERSION_MAJOR,
[major version])
AC_DEFINE_UNQUOTED(AQOFXCONNECT_VERSION_MINOR,$AQOFXCONNECT_VERSION_MINOR,
[minor version])
AC_DEFINE_UNQUOTED(AQOFXCONNECT_VERSION_PATCHLEVEL,$AQOFXCONNECT_VERSION_PATCHLEVEL,
[patchlevel])
AC_DEFINE_UNQUOTED(AQOFXCONNECT_VERSION_BUILD,$AQOFXCONNECT_VERSION_BUILD, [build])
AC_DEFINE_UNQUOTED(AQOFXCONNECT_VERSION_STRING,"$AQOFXCONNECT_VERSION_STRING",
[version string])
AC_DEFINE_UNQUOTED(AQOFXCONNECT_VERSION_FULL_STRING,"$AQOFXCONNECT_VERSION_FULL_STRING",
[full version string])
AC_DEFINE_UNQUOTED(AQOFXCONNECT_VERSION_TAG,$AQOFXCONNECT_VERSION_TAG, [tag])
AC_SUBST(AQOFXCONNECT_SO_CURRENT)
AC_SUBST(AQOFXCONNECT_SO_REVISION)
AC_SUBST(AQOFXCONNECT_SO_AGE)
AC_SUBST(AQOFXCONNECT_SO_EFFECTIVE)
AC_DEFINE_UNQUOTED(AQOFXCONNECT_SO_EFFECTIVE_STR, "$AQOFXCONNECT_SO_EFFECTIVE",
[effective SO version])
#
# same for AqEBICS
#
AC_SUBST(AQEBICS_VERSION_MAJOR)
AC_SUBST(AQEBICS_VERSION_MINOR)
AC_SUBST(AQEBICS_VERSION_PATCHLEVEL)
AC_SUBST(AQEBICS_VERSION_BUILD)
AC_SUBST(AQEBICS_VERSION_TAG)
AC_SUBST(AQEBICS_VERSION_FULL_STRING)
AC_SUBST(AQEBICS_VERSION_STRING)
AC_SUBST(AQEBICS_VERSION_RELEASE_STRING)
AC_DEFINE_UNQUOTED(AQEBICS_VERSION_MAJOR,$AQEBICS_VERSION_MAJOR,
[major version])
AC_DEFINE_UNQUOTED(AQEBICS_VERSION_MINOR,$AQEBICS_VERSION_MINOR,
[minor version])
AC_DEFINE_UNQUOTED(AQEBICS_VERSION_PATCHLEVEL,$AQEBICS_VERSION_PATCHLEVEL,
[patchlevel])
AC_DEFINE_UNQUOTED(AQEBICS_VERSION_BUILD,$AQEBICS_VERSION_BUILD, [build])
AC_DEFINE_UNQUOTED(AQEBICS_VERSION_STRING,"$AQEBICS_VERSION_STRING",
[version string])
AC_DEFINE_UNQUOTED(AQEBICS_VERSION_FULL_STRING,"$AQEBICS_VERSION_FULL_STRING",
[full version string])
AC_DEFINE_UNQUOTED(AQEBICS_VERSION_TAG,$AQEBICS_VERSION_TAG, [tag])
AC_SUBST(AQEBICS_SO_CURRENT)
AC_SUBST(AQEBICS_SO_REVISION)
AC_SUBST(AQEBICS_SO_AGE)
AC_SUBST(AQEBICS_SO_EFFECTIVE)
AC_DEFINE_UNQUOTED(AQEBICS_SO_EFFECTIVE_STR, "$AQEBICS_SO_EFFECTIVE",
[effective SO version])
###-------------------------------------------------------------------------
#
# determine operating system
#
AQ_CHECK_OS
###-------------------------------------------------------------------------
#
# prefix handling
#
AC_PREFIX_DEFAULT(/usr)
if test "x$prefix" = "xNONE"; then
prefix=$ac_default_prefix
ac_configure_args="$ac_configure_args --prefix $prefix"
fi
AC_SUBST(prefix)
###-------------------------------------------------------------------------
#
# static/shared handling
#
AC_ENABLE_STATIC(no)
AC_ENABLE_SHARED(yes)
###-------------------------------------------------------------------------
#
# define some needed variables
#
abs_top_builddir="`pwd`"
AC_SUBST(abs_top_builddir)
###-------------------------------------------------------------------------
#
# Enable some GNU extensions if using the GNU C library
#
AC_GNU_SOURCE
###-------------------------------------------------------------------------
#
# Checks for programs.
#
AC_PROG_CC
AC_PROG_CXX
AC_PROG_INSTALL
AC_PROG_LIBTOOL
AC_LIBTOOL_WIN32_DLL
AC_LIBTOOL_RC
# Newer libtool doesn't have AC_LIBTOOL_RC anymore. Need to check for
# $(RC) by ourselves.
AC_CHECK_TOOL([RC], [windres], [no])
AC_CHECK_PROG(USE_DOT,dot,YES,NO)
AC_CHECK_PROG(SED,sed,sed)
# Checks for libraries.
###-------------------------------------------------------------------------
#
# Checks for header files.
#
AC_HEADER_STDC
AC_CHECK_HEADERS([fcntl.h stdlib.h string.h unistd.h locale.h])
AC_CHECK_HEADERS([termios.h signal.h iconv.h])
AC_CHECK_DECLS([sigprocmask], [], [], [
#ifdef HAVE_SIGNAL_H
# include <signal.h>
#endif
])
###-------------------------------------------------------------------------
#
# Checks for typedefs, structures, and compiler characteristics.
#
AC_C_CONST
AC_STRUCT_TM
###-------------------------------------------------------------------------
#
# Checks for library functions.
#
AC_FUNC_STRFTIME
AC_CHECK_FUNCS([memmove memset strcasecmp strdup strerror snprintf])
AC_CHECK_FUNCS([setlocale])
###-------------------------------------------------------------------------
#
# Backends. Those do not have a required ordering.
#
AC_ARG_WITH(backends,
[ --with-backends=list space separated list of backends (default:all)],
[aqbanking_backends="$withval"],
[aqbanking_backends="all"]
)
if test "$aqbanking_backends" = "all"; then
aqbanking_backends="aqhbci aqnone aqofxconnect aqebics"
fi
for f in ${aqbanking_backends}; do
case "$f" in
aqhbci)
aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqhbci"
AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQHBCI, 1, [plugin availability])
;;
aqebics)
aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqebics"
AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQEBICS, 1, [plugin availability])
;;
aqnone)
aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqnone"
AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQNONE, 1, [plugin availability])
;;
aqofxconnect)
aqbanking_plugins_backends_dirs="$aqbanking_plugins_backends_dirs aqofxconnect"
AC_DEFINE(AQBANKING_WITH_PLUGIN_BACKEND_AQOFXCONNECT, 1, [plugin availability])
;;
aqpaypal)
AC_MSG_WARN("WARNING: AqPaypal no longer supported, ignoring")
;;
*)
AC_MSG_ERROR("ERROR: Unknown plugin \"$f\"")
;;
esac
done
AC_SUBST(aqbanking_plugins_backends_dirs)
###-------------------------------------------------------------------------
#
# ImExporters. Those do not have a required ordering.
#
AC_ARG_WITH(imexporters,
[ --with-imexporters=list space separated list of im-/exporters (default:all)],
[aqbanking_imexporters="$withval"],
[aqbanking_imexporters="all"]
)
if test "$aqbanking_imexporters" = "all"; then
aqbanking_imexporters="csv dtaus eri2 ofx openhbci1 swift xmldb yellownet sepa ctxfile q43"
fi
for f in ${aqbanking_imexporters}; do
case "$f" in
csv)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs csv"
;;
dtaus)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs dtaus"
;;
eri2)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs eri2"
;;
ofx)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs ofx"
;;
openhbci1)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs openhbci1"
;;
swift)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs swift"
;;
xmldb)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs xmldb"
;;
yellownet)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs yellownet"
;;
sepa)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs sepa"
;;
ctxfile)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs ctxfile"
;;
q43)
aqbanking_plugins_imexporters_dirs="$aqbanking_plugins_imexporters_dirs q43"
;;
*)
AC_MSG_ERROR("ERROR: Unknown plugin \"$f\"")
;;
esac
done
AC_SUBST(aqbanking_plugins_imexporters_dirs)
###-------------------------------------------------------------------------
#
# Parsers. Those do not have a required ordering.
#
AC_ARG_WITH(parsers,
[ --with-parsers=list space separated list of parsers (default:all)],
[aqbanking_parsers="$withval"],
[aqbanking_parsers="all"]
)
if test "$aqbanking_parsers" = "all"; then
aqbanking_parsers="dtaus swift"
fi
for f in ${aqbanking_parsers}; do
case "$f" in
dtaus)
aqbanking_plugins_parsers_dirs="$aqbanking_plugins_parsers_dirs dtaus"
;;
swift)
aqbanking_plugins_parsers_dirs="$aqbanking_plugins_parsers_dirs swift"
;;
*)
AC_MSG_ERROR("ERROR: Unknown plugin \"$f\"")
;;
esac
done
AC_SUBST(aqbanking_plugins_parsers_dirs)
###-------------------------------------------------------------------------
#
# Bankinfo plugins. Those do not have a required ordering.
#
AC_ARG_WITH(bankinfos,
[ --with-bankinfos=list space separated list of bankinfo (default:all)],
[aqbanking_bankinfos="$withval"],
[aqbanking_bankinfos="all"]
)
if test "$aqbanking_bankinfos" = "all"; then
aqbanking_bankinfos="at ca ch de us"
fi
for f in ${aqbanking_bankinfos}; do
case "$f" in
at)
aqbanking_plugins_bankinfo_dirs="$aqbanking_plugins_bankinfo_dirs at"
;;
ca)
aqbanking_plugins_bankinfo_dirs="$aqbanking_plugins_bankinfo_dirs ca"
;;
ch)
aqbanking_plugins_bankinfo_dirs="$aqbanking_plugins_bankinfo_dirs ch"
;;
de)
aqbanking_plugins_bankinfo_dirs="$aqbanking_plugins_bankinfo_dirs de"
;;
us)
aqbanking_plugins_bankinfo_dirs="$aqbanking_plugins_bankinfo_dirs us"
;;
*)
AC_MSG_ERROR("ERROR: Unknown plugin \"$f\"")
;;
esac
done
AC_SUBST(aqbanking_plugins_bankinfo_dirs)
###-------------------------------------------------------------------------
#
# KtoBlzCheck
#
pkg_modules="ktoblzcheck >= 1.10"
PKG_CHECK_MODULES(ktoblzcheck, [$pkg_modules], [have_ktoblzcheck="yes"], [have_ktoblzcheck="no"])
if test "$have_ktoblzcheck" = "yes"; then
AC_DEFINE(HAVE_KTOBLZCHECK, 1, [if KTOBLZCHECK is available])
ktoblzcheck_includes="$ktoblzcheck_CFLAGS"
ktoblzcheck_libs="$ktoblzcheck_LIBS"
else
AC_MSG_WARN([
*** ktoblzcheck is missing.
*** Account number checking will not be available.
*** We strongly suggest installing ktoblzcheck and its devel
*** package.])
fi
AM_CONDITIONAL(WITH_KTOBLZCHECK, [test "$have_ktoblzcheck" = "yes"])
AC_SUBST(ktoblzcheck_libs)
AC_SUBST(ktoblzcheck_includes)
###-------------------------------------------------------------------------
#
# Check for Gwen
#
# Variable used in aqbanking-config.cmake
AC_SUBST(GWENHYWFAR_MINIMUM_VERSION, "4.10.0.0")
AC_GWENHYWFAR(4,10,0,0)
all_includes="$all_includes $gwenhywfar_includes"
AC_ARG_ENABLE(gui-tests,
[ --enable-gui-tests allow GUI tests (default=no)],
enable_gui_tests="$enableval",
enable_gui_tests="no")
AC_MSG_RESULT($enable_gui_tests)
if test "$enable_gui_tests" != "no"; then
# For libgwenhywfar > 3.99.20, look for its library gwengui-gtk2.
PKG_CHECK_MODULES([GWENGUI_GTK2], [gwengui-gtk2 gwenhywfar], [
HAVE_GWENGUI_GTK2=1
PKG_CHECK_MODULES([GTK2], [gtk+-2.0])
], [
HAVE_GWENGUI_GTK2=0
])
AC_SUBST(HAVE_GWENGUI_GTK2)
if test "$HAVE_GWENGUI_GTK2" = "1"; then
AC_DEFINE(USE_GWENGUI_GTK2, 1, [GTK2Gui availability])
fi
else
HAVE_GWENGUI_GTK2=0
fi
AM_CONDITIONAL(WITH_GWENGUI_GTK2, [test "$HAVE_GWENGUI_GTK2" = "1"])
###-------------------------------------------------------------------------
#
# check typemaker2
#
AC_MSG_CHECKING(typemaker2 binary)
AC_ARG_WITH(typemaker2-exe,
[ --with-typemaker2-exe=EXE path and name of the executable typemaker2],
[typemaker2_exe="$withval"],
[typemaker2_exe="\$(gwenhywfar_bindir)/typemaker2"]
)
AC_MSG_RESULT($typemaker2_exe)
AC_SUBST(typemaker2_exe)
###-------------------------------------------------------------------------
#
# check xmlmerge
#
AC_MSG_CHECKING(xmlmerge)
AC_ARG_WITH(xmlmerge, [ --with-xmlmerge=PATH path and name of tool xmlmerge],
[XMLMERGE="$withval"],
[XMLMERGE="$gwenhywfar_dir/bin/xmlmerge"])
AC_SUBST(XMLMERGE)
AC_MSG_RESULT($XMLMERGE)
###-------------------------------------------------------------------------
#
# Check for GMP
#
# Allow the user to override the gmp_libs detection here
if test "x$gmp_libs" = "x"; then
AC_CHECK_LIB(gmp, __gmpz_init, [have_gmp="yes"], [have_gmp="no"])
AC_CHECK_HEADERS(gmp.h, [], [have_gmp="no"])
if test "$have_gmp" != "yes"; then
AC_MSG_ERROR([GMP is required, see http://swox.com/gmp])
else
gmp_libs="-lgmp"
fi
fi
AC_SUBST(gmp_libs)
###-------------------------------------------------------------------------
#
# OS dependant settings
#
# Common settings; can be overridden per-OS below.
aqbanking_internal_libs="${abs_top_builddir}/src/libs/aqbanking/libaqbanking.la"
aqbanking_ldflags="-L\${libdir}"
aqbanking_libs="-laqbanking"
aqbanking_includes="-I\${includedir}/aqbanking5"
aqbanking_headerdir_am="\$(includedir)/aqbanking5"
aqbanking_headerdir="\${includedir}/aqbanking5"
aqbanking_plugindir="\${libdir}/aqbanking/plugins/${AQBANKING_SO_EFFECTIVE}"
aqbanking_pkgdatadir="\${datadir}/aqbanking"
aqbanking_symlinkdir="\$(top_builddir)/aqbanking5"
case "$OS_TYPE" in
posix)
aqbanking_sys_is_windows=0
;;
windows)
aqbanking_sys_is_windows=1
AC_DEFINE_UNQUOTED(BUILDING_AQBANKING_DLL,1, [Define if DLL is built])
;;
esac
AM_CONDITIONAL(IS_WINDOWS, [test "$OS_TYPE" = "windows"])
###-------------------------------------------------------------------------
#
# check whether local installation mode is enabled
#
AC_MSG_CHECKING(whether local installation mode is wanted)
AC_ARG_ENABLE(local-install,
[ --enable-local-install allow local installation mode (default=no)],
enable_local_install="$enableval",
enable_local_install="no")
AC_MSG_RESULT($enable_local_install)
if test "$enable_local_install" != "no"; then
AC_DEFINE(ENABLE_LOCAL_INSTALL, 1, [whether local install is wanted])
fi
###-------------------------------------------------------------------------
#
# check plugin search path
#
AC_MSG_CHECKING(plugin search dir)
AC_ARG_WITH(plugin-searchdir, [ --with-plugin-searchdir=DIR where to search for plugins],
[aqbanking_plugin_searchdir="$withval"],
[aqbanking_plugin_searchdir=""])
if test -z "${aqbanking_plugin_searchdir}"; then
if test "$OSYSTEM" = "windows"; then
aqbanking_plugin_searchdir="lib/aqbanking/plugins/${AQBANKING_SO_EFFECTIVE}"
else
if test "$enable_local_install" != "no"; then
aqbanking_plugin_searchdir="lib/aqbanking/plugins/${AQBANKING_SO_EFFECTIVE}"
else
aqbanking_plugin_searchdir="$aqbanking_plugindir"
fi
fi
fi
AC_SUBST(aqbanking_plugin_searchdir)
AC_MSG_RESULT($aqbanking_plugin_searchdir)
###-------------------------------------------------------------------------
#
# check cfg search dir
#
AC_MSG_CHECKING(cfg search dir)
AC_ARG_WITH(cfg-searchdir, [ --with-cfg-searchdir=DIR where to search for cfg files],
[aqbanking_cfg_searchdir="$withval"],
[aqbanking_cfg_searchdir=""])
if test -z "$aqbanking_cfg_searchdir"; then
if test "$OSYSTEM" = "windows"; then
aqbanking_cfg_searchdir="etc"
else
if test "$enable_local_install" != "no"; then
aqbanking_cfg_searchdir="etc"
else
aqbanking_cfg_searchdir="\$(sysconfdir)"
fi
fi
fi
AC_SUBST(aqbanking_cfg_searchdir)
AC_MSG_RESULT($aqbanking_cfg_searchdir)
###-------------------------------------------------------------------------
#
# check locale search dir
#
AC_MSG_CHECKING(locale search dir)
AC_ARG_WITH(locale-searchdir, [ --with-locale-searchdir=DIR where to search for locale files],
[aqbanking_locale_searchdir="$withval"],
[aqbanking_locale_searchdir=""])
if test -z "${aqbanking_locale_searchdir}"; then
if test "$OSYSTEM" = "windows"; then
aqbanking_locale_searchdir="share/locale"
else
if test "$enable_local_install" != "no"; then
aqbanking_locale_searchdir="share/locale"
else
aqbanking_locale_searchdir="\$(localedir)"
fi
fi
fi
AC_SUBST(aqbanking_locale_searchdir)
AC_MSG_RESULT($aqbanking_locale_searchdir)
###-------------------------------------------------------------------------
#
# check data search dir
#
AC_MSG_CHECKING(data search dir)
AC_ARG_WITH(data-searchdir, [ --with-data-searchdir=DIR where to search for data files],
[aqbanking_data_searchdir="$withval"],
[aqbanking_data_searchdir=""])
if test -z "${aqbanking_data_searchdir}"; then
if test "$OSYSTEM" = "windows"; then
aqbanking_data_searchdir="share"
else
if test "$enable_local_install" != "no"; then
aqbanking_data_searchdir="share"
else
aqbanking_data_searchdir="\$(datadir)"
fi
fi
fi
AC_SUBST(aqbanking_data_searchdir)
AC_MSG_RESULT($aqbanking_data_searchdir)
###-------------------------------------------------------------------------
# check for Distribution
AQ_DISTRIBUTION
###-------------------------------------------------------------------------
#
# check for I18N
#
# check whether i18n files are to be created
AC_CHECK_PROG(XGETTEXT,xgettext,xgettext, missing)
MAKE_I18N_FILES="yes"
if test "$XGETTEXT" = "missing"; then
MAKE_I18N_FILES="no"
AC_MSG_WARN([xgettext is missing. Locale suport is disabled.])
fi
AC_PATH_PROG([MSGFMT], [msgfmt], [missing])
if test "$MSGFMT" = "missing"; then
MAKE_I18N_FILES="no"
AC_MSG_WARN([msgfmt is missing. Locale suport is disabled.])
else
# check for --qt argument of msgfmt
AC_MSG_CHECKING(whether msgfmt understands --qt)
if test "x${MSGFMT}" != "x"; then
if ${MSGFMT} --qt --help >/dev/null 2>&1; then
MSGFMT_SUPPORTS_QT=yes
else
MSGFMT_SUPPORTS_QT=no
fi
else
MSGFMT_SUPPORTS_QT=no
fi
AC_MSG_RESULT($MSGFMT_SUPPORTS_QT)
fi
AC_SUBST(MAKE_I18N_FILES)
AC_SUBST(MSGFMT_SUPPORTS_QT)
AM_CONDITIONAL(IF_MAKE_I18N_FILES, [test "$MAKE_I18N_FILES" = "yes"])
# then check whether i18n support is to be compiled in
i18n_libs=""
HAVE_I18N="yes"
AC_CHECK_HEADERS([locale.h libintl.h], [], [HAVE_I18N="no"])
AC_CHECK_FUNCS([setlocale])
if test "$OS_TYPE" != "windows"; then
oldlibs="$LIBS"
LIBS=""
AC_SEARCH_LIBS(gettext, intl, [], [HAVE_I18N="no"])
i18n_libs="$LIBS"
LIBS="$oldlibs"
else
i18n_libs="-lintl"
fi
if test "$HAVE_I18N" != "NO"; then
AC_DEFINE_UNQUOTED(HAVE_I18N, 1, [whether I18N is available])
fi
AC_SUBST(HAVE_I18N)
AC_SUBST(i18n_libs)
###-------------------------------------------------------------------------
#
# check for release
#
AC_MSG_CHECKING(whether this is an official release)
AC_ARG_ENABLE(release,
[ --enable-release make this an official release (default=no)],
[ case "${enableval}" in
yes) enable_release="yes";;
no) enable_release="no";;
*) AC_MSG_ERROR(bad value ${enableval} for --enable-release);;
esac
],
enable_release="no")
if test "$enable_release" = "yes"; then
STRIPALL="-s"
else
STRIPALL=""
fi
AC_SUBST(STRIPALL)
AC_MSG_RESULT($enable_release)
###-------------------------------------------------------------------------
# Debug arguments for compilation
ACX_COMPILE_WARN()
###-------------------------------------------------------------------------
#
# GCC version (check for usability)
#
AC_MSG_CHECKING(if symbol visibility is supported)
visibility_cflags=""
case `basename $CC` in
*gcc*)
dnl Determine version number (watch out: the outside square
dnl parenteses are vitally important here!)
gccversion=["` ${CC} --version | head -1 | ${SED} 's/.*\([0-9]\.[0-9]\.[0-9]*\).*/\1/' `"]
case $gccversion in
4.*)
# Activate -fvisibility=hidden only for explicit 4.x gcc
# versions. We never now what future gcc's might do with
# that argument, and we also can't be sure that other
# gcc's happen to show very weird version
# numbers. Therefore leave the default at non-activated.
visibility_supported="yes, gcc-${gccversion}"
AC_DEFINE(GCC_WITH_VISIBILITY_ATTRIBUTE, 1, [visibility])
visibility_cflags="-fvisibility=hidden"
;;
*)
# Default: -fvisibility=hidden not activated.
visibility_supported="no (needs gcc >=4.0, you have gcc-${gccversion})"
;;
esac
;;
*)
visibility_supported="no (needs gcc >=4.0, you use $CC)"
;;
esac
# -fvisibility is at least not available on MinGW/gcc-3.4.4 (will
# give an "unrecognized cmdline option"). Also, unfortunately I
# don't know an easy way to ask the compiler here. Maybe
# http://autoconf-archive.cryp.to/ax_cflags_gcc_option.html
case "$OS_TYPE" in
windows)
visibility_supported="no (not yet on MinGW/Windows)"
visibility_cflags=""
;;
*)
;;
esac
AC_MSG_RESULT(${visibility_supported})
AC_SUBST(visibility_cflags)
###-------------------------------------------------------------------------
#
# Subst
#
AS_SCRUB_INCLUDE(aqbanking_includes)
AC_SUBST(aqbanking_sys_is_windows)
AC_SUBST(aqbanking_includes)
AC_SUBST(aqbanking_internal_libs)
AC_SUBST(aqbanking_ldflags)
AC_SUBST(aqbanking_libs)
AC_SUBST(aqbanking_plugindir)
AC_SUBST(aqbanking_pkgdatadir)
AC_SUBST(aqbanking_symlinkdir)
AC_SUBST(aqbanking_headerdir_am)
AC_SUBST(aqbanking_headerdir)
###-------------------------------------------------------------------------
#