src/test/resources/golden-sample/configure2

Sun, 17 Sep 2023 12:39:42 +0200

author
Mike Becker <universe@uap-core.de>
date
Sun, 17 Sep 2023 12:39:42 +0200
branch
configure-evo
changeset 60
43d6680e6410
parent 52
afcb57893858
child 63
ac47c2fb2c4a
permissions
-rwxr-xr-x

update reference configure scripts

39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
1 #!/bin/sh
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
2
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
3 # create temporary directory
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
4 TEMP_DIR=".tmp-`uname -n`"
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
5 rm -Rf "$TEMP_DIR"
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
6 if mkdir -p "$TEMP_DIR"; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
7 :
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
8 else
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
9 echo "Cannot create tmp dir $TEMP_DIR"
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
10 echo "Abort"
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
11 exit 1
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
12 fi
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
13 touch "$TEMP_DIR/options"
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
14 touch "$TEMP_DIR/features"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
15
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
16 # define standard variables
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
17 PREFIX=/usr
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
18 EPREFIX=/usr
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
19 BINDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
20 SBINDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
21 LIBDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
22 LIBEXECDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
23 DATADIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
24 SYSCONFDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
25 SHAREDSTATEDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
26 LOCALSTATEDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
27 INCLUDEDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
28 INFODIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
29 MANDIR=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
30
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
31 # custom variables
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
32
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
33 # features
47
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
34 FEATURE_DB=auto
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
35
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
36 # clean abort
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
37 abort_configure()
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
38 {
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
39 rm -Rf "$TEMP_DIR"
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
40 exit 1
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
41 }
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
42
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
43 # help text
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
44 printhelp()
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
45 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
46 echo "Usage: $0 [OPTIONS]..."
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
47 cat << __EOF__
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
48 Installation directories:
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
49 --prefix=PREFIX path prefix for architecture-independent files
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
50 [/usr]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
51 --exec-prefix=EPREFIX path prefix for architecture-dependent files
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
52 [PREFIX]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
53
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
54 --bindir=DIR user executables [EPREFIX/bin]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
55 --sbindir=DIR system admin executables [EPREFIX/sbin]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
56 --libexecdir=DIR program executables [EPREFIX/libexec]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
57 --sysconfdir=DIR system configuration files [PREFIX/etc]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
58 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
59 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
60 --libdir=DIR object code libraries [EPREFIX/lib]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
61 --includedir=DIR C header files [PREFIX/include]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
62 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
63 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
64 --infodir=DIR info documentation [DATAROOTDIR/info]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
65 --mandir=DIR man documentation [DATAROOTDIR/man]
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
66
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
67 Options:
51
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
68 --debug add extra compile flags for debug builds
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
69 --release add extra compile flags for release builds
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
70 --toolkit=(gtk3|cli|gtk2|wpf)
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
71
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
72 Optional Features:
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
73 --disable-db
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
74 --enable-gui
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
75
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
76 __EOF__
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
77 }
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
78
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
79 #
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
80 # parse arguments
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
81 #
51
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
82 BUILD_TYPE="default"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
83 for ARG in "$@"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
84 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
85 case "$ARG" in
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
86 "--prefix="*) PREFIX=${ARG#--prefix=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
87 "--exec-prefix="*) EPREFIX=${ARG#--exec-prefix=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
88 "--bindir="*) BINDIR=${ARG#----bindir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
89 "--sbindir="*) SBINDIR=${ARG#--sbindir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
90 "--libdir="*) LIBDIR=${ARG#--libdir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
91 "--libexecdir="*) LIBEXECDIR=${ARG#--libexecdir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
92 "--datadir="*) DATADIR=${ARG#--datadir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
93 "--sysconfdir="*) SYSCONFDIR=${ARG#--sysconfdir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
94 "--sharedstatedir="*) SHAREDSTATEDIR=${ARG#--sharedstatedir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
95 "--localstatedir="*) LOCALSTATEDIR=${ARG#--localstatedir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
96 "--includedir="*) INCLUDEDIR=${ARG#--includedir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
97 "--infodir="*) INFODIR=${ARG#--infodir=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
98 "--mandir"*) MANDIR=${ARG#--mandir} ;;
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
99 "--help"*) printhelp; abort_configure ;;
51
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
100 "--debug") BUILD_TYPE="debug" ;;
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
101 "--release") BUILD_TYPE="release" ;;
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
102 "--toolkit="*) OPT_TOOLKIT=${ARG#--toolkit=} ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
103 "--enable-db") FEATURE_DB=on ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
104 "--disable-db") unset FEATURE_DB ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
105 "--enable-gui") FEATURE_GUI=on ;;
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
106 "--disable-gui") unset FEATURE_GUI ;;
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
107 "-"*) echo "unknown option: $ARG"; abort_configure ;;
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
108 esac
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
109 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
110
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
111
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
112 # set dir variables
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
113 : ${BINDIR:="$EPREFIX/bin"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
114 : ${SBINDIR:="$EPREFIX/sbin"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
115 : ${LIBDIR:="$EPREFIX/lib"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
116 : ${LIBEXECDIR:="$EPREFIX/libexec"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
117 : ${DATADIR:="$PREFIX/share"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
118 : ${SYSCONFDIR:="$PREFIX/etc"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
119 : ${SHAREDSTATEDIR:="$PREFIX/com"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
120 : ${LOCALSTATEDIR:="$PREFIX/var"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
121 : ${INCLUDEDIR:="$PREFIX/include"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
122 : ${INFODIR:="$PREFIX/info"}
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
123 : ${MANDIR:="$PREFIX/man"}
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
124
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
125 # Test for availability of pkg-config
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
126 PKG_CONFIG=`command -v pkg-config`
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
127 : ${PKG_CONFIG:="false"}
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
128
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
129 # Simple uname based platform detection
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
130 # $PLATFORM is used for platform dependent dependency selection
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
131 OS=`uname -s`
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
132 OS_VERSION=`uname -r`
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
133 printf "detect platform... "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
134 if [ "$OS" = "SunOS" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
135 PLATFORM="solaris sunos unix svr4"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
136 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
137 if [ "$OS" = "Linux" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
138 PLATFORM="linux unix"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
139 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
140 if [ "$OS" = "FreeBSD" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
141 PLATFORM="freebsd bsd unix"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
142 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
143 if [ "$OS" = "Darwin" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
144 PLATFORM="macos osx bsd unix"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
145 fi
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
146 if echo "$OS" | grep -i "MINGW" > /dev/null; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
147 PLATFORM="windows mingw"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
148 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
149 : ${PLATFORM:="unix"}
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
150
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
151 PLATFORM_NAME=`echo "$PLATFORM" | cut -f1 -d' ' -`
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
152 echo "$PLATFORM_NAME"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
153
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
154 isplatform()
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
155 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
156 for p in $PLATFORM
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
157 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
158 if [ "$p" = "$1" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
159 return 0
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
160 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
161 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
162 return 1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
163 }
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
164 notisplatform()
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
165 {
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
166 for p in $PLATFORM
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
167 do
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
168 if [ "$p" = "$1" ]; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
169 return 1
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
170 fi
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
171 done
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
172 return 0
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
173 }
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
174
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
175
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
176 # generate config.mk
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
177 cat > "$TEMP_DIR/vars.mk" << __EOF__
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
178 PREFIX=$PREFIX
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
179 EPREFIX=$EPREFIX
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
180 BINDIR=$BINDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
181 SBINDIR=$SBINDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
182 LIBDIR=$LIBDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
183 LIBEXECDIR=$LIBEXECDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
184 DATADIR=$DATADIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
185 SYSCONFDIR=$SYSCONFDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
186 SHAREDSTATEDIR=$SHAREDSTATEDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
187 LOCALSTATEDIR=$LOCALSTATEDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
188 INCLUDEDIR=$INCLUDEDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
189 INFODIR=$INFODIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
190 MANDIR=$MANDIR
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
191 __EOF__
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
192 cat > "$TEMP_DIR/config.mk" << __EOF__
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
193 #
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
194 # config.mk generated by configure
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
195 #
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
196 __EOF__
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
197 sort -u "$TEMP_DIR/vars.mk" >> "$TEMP_DIR/config.mk"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
198
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
199
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
200 # toolchain detection
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
201 # this will insert make vars to config.mk
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
202 . make/toolchain.sh
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
203 if [ -n "$TOOLCHAIN_ERROR" ]; then
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
204 echo "Toolchain error: $TOOLCHAIN_ERROR"
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
205 echo "Abort."
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
206 abort_configure
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
207 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
208
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
209 #
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
210 # DEPENDENCIES
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
211 #
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
212
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
213 # create buffer for make variables required by dependencies
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
214 echo > "$TEMP_DIR/make.mk"
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
215
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
216 dependency_error_qt4()
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
217 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
218 printf "checking for qt4... "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
219 # dependency qt4
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
220 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
221 do
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
222 if which qmake-qt4 > /dev/null ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
223 :
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
224 else
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
225 break
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
226 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
227 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
228 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
229 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
230
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
231 echo no
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
232 return 0
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
233 }
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
234 dependency_error_curl()
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
235 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
236 printf "checking for curl... "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
237 # dependency curl platform="windows"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
238 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
239 do
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
240 if notisplatform "windows"; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
241 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
242 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
243 TEMP_CFLAGS="$TEMP_CFLAGS -I/mingw/include"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
244 TEMP_LDFLAGS="$TEMP_LDFLAGS -lcurl"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
245 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
246 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
247 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
248
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
249 # dependency curl platform="macos"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
250 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
251 do
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
252 if notisplatform "macos"; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
253 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
254 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
255 if tmp_flags=`curl-config --cflags` ; then
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
256 TEMP_CFLAGS="$TEMP_CFLAGS $tmp_flags"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
257 else
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
258 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
259 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
260 if tmp_flags=`curl-config --ldflags` ; then
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
261 TEMP_LDFLAGS="$TEMP_LDFLAGS $tmp_flags"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
262 else
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
263 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
264 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
265 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
266 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
267 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
268
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
269 # dependency curl
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
270 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
271 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
272 if [ -z "$PKG_CONFIG" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
273 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
274 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
275 if $PKG_CONFIG libcurl ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
276 TEMP_CFLAGS="$TEMP_CFLAGS `"$PKG_CONFIG" --cflags libcurl`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
277 TEMP_LDFLAGS="$TEMP_LDFLAGS `"$PKG_CONFIG" --libs libcurl`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
278 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
279 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
280 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
281 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
282 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
283 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
284
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
285 echo no
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
286 return 0
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
287 }
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
288 dependency_error_gtk2()
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
289 {
40
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
290 printf "checking for gtk2... "
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
291 # dependency gtk2
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
292 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
293 do
40
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
294 if [ -z "$PKG_CONFIG" ]; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
295 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
296 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
297 if $PKG_CONFIG gtk+-2.0 ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
298 TEMP_CFLAGS="$TEMP_CFLAGS `"$PKG_CONFIG" --cflags gtk+-2.0`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
299 TEMP_LDFLAGS="$TEMP_LDFLAGS `"$PKG_CONFIG" --libs gtk+-2.0`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
300 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
301 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
302 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
303 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
304 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
305 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
306
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
307 echo no
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
308 return 0
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
309 }
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
310 dependency_error_sqlite()
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
311 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
312 printf "checking for sqlite... "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
313 # dependency sqlite
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
314 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
315 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
316 if [ -z "$PKG_CONFIG" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
317 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
318 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
319 if $PKG_CONFIG sqlite3 ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
320 TEMP_CFLAGS="$TEMP_CFLAGS `"$PKG_CONFIG" --cflags sqlite3`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
321 TEMP_LDFLAGS="$TEMP_LDFLAGS `"$PKG_CONFIG" --libs sqlite3`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
322 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
323 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
324 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
325 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
326 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
327 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
328
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
329 echo no
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
330 return 0
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
331 }
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
332 dependency_error_test()
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
333 {
40
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
334 printf "checking for test... "
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
335 # dependency test platform="bsd"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
336 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
337 do
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
338 if notisplatform "bsd"; then
40
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
339 break
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
340 fi
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
341 if isplatform "macos"; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
342 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
343 fi
40
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
344 TEMP_CFLAGS="$TEMP_CFLAGS -DBSD"
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
345 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
346 return 1
40
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
347 done
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
348
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
349 # dependency test
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
350 while true
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
351 do
b42bfc9e9983 first minor code improvements
Mike Becker <universe@uap-core.de>
parents: 39
diff changeset
352 TEMP_CFLAGS="$TEMP_CFLAGS -DTEST"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
353 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
354 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
355 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
356
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
357 echo no
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
358 return 0
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
359 }
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
360 dependency_error_gtk3()
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
361 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
362 printf "checking for gtk3... "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
363 # dependency gtk3
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
364 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
365 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
366 if [ -z "$PKG_CONFIG" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
367 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
368 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
369 if $PKG_CONFIG gtk+-5.0 ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
370 TEMP_CFLAGS="$TEMP_CFLAGS `"$PKG_CONFIG" --cflags gtk+-5.0`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
371 TEMP_LDFLAGS="$TEMP_LDFLAGS `"$PKG_CONFIG" --libs gtk+-5.0`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
372 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
373 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
374 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
375 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
376 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
377 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
378
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
379 echo no
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
380 return 0
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
381 }
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
382 dependency_error_deptest()
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
383 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
384 printf "checking for deptest... "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
385 # dependency deptest
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
386 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
387 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
388 TEMP_CFLAGS="$TEMP_CFLAGS -DDEPTEST"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
389 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
390 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
391 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
392
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
393 echo no
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
394 return 0
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
395 }
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
396 dependency_error_libxml2()
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
397 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
398 printf "checking for libxml2... "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
399 # dependency libxml2
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
400 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
401 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
402 if [ -z "$PKG_CONFIG" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
403 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
404 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
405 if $PKG_CONFIG --atleast-version=2.8 libxml-2.0 ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
406 TEMP_CFLAGS="$TEMP_CFLAGS `"$PKG_CONFIG" --cflags libxml-2.0`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
407 TEMP_LDFLAGS="$TEMP_LDFLAGS `"$PKG_CONFIG" --libs libxml-2.0`"
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
408 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
409 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
410 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
411 cat >> $TEMP_DIR/make.mk << __EOF__
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
412 # Dependency: libxml2
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
413 xml = libxml2
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
414
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
415 __EOF__
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
416 echo yes
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
417 return 1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
418 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
419
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
420 echo no
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
421 return 0
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
422 }
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
423
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
424 DEPENDENCIES_FAILED=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
425 ERROR=0
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
426 # unnamed dependencies
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
427 TEMP_CFLAGS=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
428 TEMP_LDFLAGS=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
429 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
430 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
431 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
432 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
433
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
434 cat >> "$TEMP_DIR/make.mk" << __EOF__
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
435 MVAR = 123
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
436 MVAR += 123
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
437
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
438 __EOF__
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
439 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
440 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
441 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
442 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
443
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
444 # add unnamed dependency flags to config.mk
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
445 echo >> "$TEMP_DIR/config.mk"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
446 if [ -n "${TEMP_CFLAGS}" ]; then
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
447 echo "CFLAGS += $TEMP_CFLAGS" >> "$TEMP_DIR/config.mk"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
448 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
449 if [ -n "${TEMP_LDFLAGS}" ]; then
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
450 echo "LDFLAGS += $TEMP_LDFLAGS" >> "$TEMP_DIR/config.mk"
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
451 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
452
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
453 #
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
454 # OPTION VALUES
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
455 #
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
456 checkopt_toolkit_gtk3()
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
457 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
458 VERR=0
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
459 if dependency_error_gtk3 ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
460 VERR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
461 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
462 if [ $VERR -ne 0 ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
463 return 1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
464 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
465 TEMP_CFLAGS="$TEMP_CFLAGS -Da=b"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
466 cat >> "$TEMP_DIR/make.mk" << __EOF__
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
467 UIOBJ += graphics_cairo.o
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
468
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
469 __EOF__
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
470 return 0
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
471 }
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
472 checkopt_toolkit_cli()
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
473 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
474 VERR=0
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
475 if dependency_error_curl ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
476 VERR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
477 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
478 if dependency_error_test ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
479 VERR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
480 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
481 if [ $VERR -ne 0 ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
482 return 1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
483 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
484 return 0
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
485 }
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
486 checkopt_toolkit_gtk2()
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
487 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
488 VERR=0
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
489 if dependency_error_gtk2 ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
490 VERR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
491 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
492 if [ $VERR -ne 0 ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
493 return 1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
494 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
495 return 0
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
496 }
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
497 checkopt_toolkit_wpf()
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
498 {
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
499 VERR=0
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
500 if dependency_error_test ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
501 VERR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
502 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
503 if [ $VERR -ne 0 ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
504 return 1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
505 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
506 return 0
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
507 }
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
508
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
509 #
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
510 # TARGETS
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
511 #
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
512
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
513 # Target: dav
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
514 TEMP_CFLAGS=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
515 TEMP_LDFLAGS=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
516
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
517 if dependency_error_curl; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
518 DEPENDENCIES_FAILED="$DEPENDENCIES_FAILED curl "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
519 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
520 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
521 if dependency_error_libxml2; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
522 DEPENDENCIES_FAILED="$DEPENDENCIES_FAILED libxml2 "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
523 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
524 fi
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
525 if dependency_error_test; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
526 DEPENDENCIES_FAILED="$DEPENDENCIES_FAILED test "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
527 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
528 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
529
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
530 # Features
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
531 if [ -n "$FEATURE_DB" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
532 # check dependency
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
533 if dependency_error_sqlite ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
534 # "auto" features can fail and are just disabled in this case
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
535 if [ "$FEATURE_DB" = "auto" ]; then
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
536 unset FEATURE_DB
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
537 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
538 DEPENDENCIES_FAILED="$DEPENDENCIES_FAILED sqlite "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
539 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
540 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
541 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
542 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
543 if [ -n "$FEATURE_GUI" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
544 # check dependency
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
545 if dependency_error_gtk3 ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
546 # "auto" features can fail and are just disabled in this case
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
547 if [ "$FEATURE_GUI" = "auto" ]; then
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
548 unset FEATURE_GUI
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
549 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
550 DEPENDENCIES_FAILED="$DEPENDENCIES_FAILED gtk3 "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
551 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
552 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
553 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
554 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
555
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
556 # Option: --toolkit
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
557 if [ -z $OPT_TOOLKIT ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
558 SAVED_ERROR="$ERROR"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
559 SAVED_DEPENDENCIES_FAILED="$DEPENDENCIES_FAILED"
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
560 ERROR=1
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
561 while true
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
562 do
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
563 if isplatform "windows"; then
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
564 if checkopt_toolkit_wpf ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
565 echo " toolkit: wpf" >> "$TEMP_DIR/options"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
566 ERROR=0
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
567 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
568 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
569 fi
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
570 if checkopt_toolkit_gtk3 ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
571 echo " toolkit: gtk3" >> "$TEMP_DIR/options"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
572 ERROR=0
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
573 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
574 fi
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
575 if checkopt_toolkit_gtk2 ; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
576 echo " toolkit: gtk2" >> "$TEMP_DIR/options"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
577 ERROR=0
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
578 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
579 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
580 break
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
581 done
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
582 if [ $ERROR -ne 0 ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
583 SAVED_ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
584 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
585 ERROR="$SAVED_ERROR"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
586 DEPENDENCIES_FAILED="$SAVED_DEPENDENCIES_FAILED"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
587 else
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
588 if false; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
589 false
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
590 elif [ "$OPT_TOOLKIT" = "gtk3" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
591 echo " toolkit: $OPT_TOOLKIT" >> $TEMP_DIR/options
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
592 if checkopt_toolkit_gtk3 ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
593 :
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
594 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
595 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
596 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
597 elif [ "$OPT_TOOLKIT" = "cli" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
598 echo " toolkit: $OPT_TOOLKIT" >> $TEMP_DIR/options
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
599 if checkopt_toolkit_cli ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
600 :
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
601 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
602 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
603 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
604 elif [ "$OPT_TOOLKIT" = "gtk2" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
605 echo " toolkit: $OPT_TOOLKIT" >> $TEMP_DIR/options
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
606 if checkopt_toolkit_gtk2 ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
607 :
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
608 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
609 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
610 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
611 elif [ "$OPT_TOOLKIT" = "wpf" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
612 echo " toolkit: $OPT_TOOLKIT" >> $TEMP_DIR/options
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
613 if checkopt_toolkit_wpf ; then
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
614 :
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
615 else
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
616 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
617 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
618 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
619 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
620
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
621 echo >> "$TEMP_DIR/config.mk"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
622 if [ -n "${TEMP_CFLAGS}" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
623 echo "DAV_CFLAGS += $TEMP_CFLAGS" >> "$TEMP_DIR/config.mk"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
624 fi
51
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
625 if [ "$BUILD_TYPE" = "debug" ]; then
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
626 echo 'DAV_CFLAGS += ${DEBUG_FLAGS}' >> "$TEMP_DIR/config.mk"
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
627 fi
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
628 if [ "$BUILD_TYPE" = "release" ]; then
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
629 echo 'DAV_CFLAGS += ${RELEASE_FLAGS}' >> "$TEMP_DIR/config.mk"
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
630 fi
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
631 if [ -n "${TEMP_LDFLAGS}" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
632 echo "DAV_LDFLAGS += $TEMP_LDFLAGS" >> "$TEMP_DIR/config.mk"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
633 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
634
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
635 # Target
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
636 TEMP_CFLAGS=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
637 TEMP_LDFLAGS=
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
638
60
43d6680e6410 update reference configure scripts
Mike Becker <universe@uap-core.de>
parents: 52
diff changeset
639 if dependency_error_deptest; then
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
640 DEPENDENCIES_FAILED="$DEPENDENCIES_FAILED deptest "
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
641 ERROR=1
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
642 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
643
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
644 # Features
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
645
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
646
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
647 echo >> "$TEMP_DIR/config.mk"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
648 if [ -n "${TEMP_CFLAGS}" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
649 echo "CFLAGS += $TEMP_CFLAGS" >> "$TEMP_DIR/config.mk"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
650 fi
51
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
651 if [ "$BUILD_TYPE" = "debug" ]; then
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
652 echo 'CFLAGS += ${DEBUG_FLAGS}' >> "$TEMP_DIR/config.mk"
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
653 fi
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
654 if [ "$BUILD_TYPE" = "release" ]; then
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
655 echo 'CFLAGS += ${RELEASE_FLAGS}' >> "$TEMP_DIR/config.mk"
5c12e9e29733 add debug/release options - fixes #285
Mike Becker <universe@uap-core.de>
parents: 47
diff changeset
656 fi
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
657 if [ -n "${TEMP_LDFLAGS}" ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
658 echo "LDFLAGS += $TEMP_LDFLAGS" >> "$TEMP_DIR/config.mk"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
659 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
660
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
661 if [ $ERROR -ne 0 ]; then
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
662 echo
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
663 echo "Error: Unresolved dependencies"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
664 echo "$DEPENDENCIES_FAILED"
52
afcb57893858 major evolution of configure template - fixes #283
Mike Becker <universe@uap-core.de>
parents: 51
diff changeset
665 abort_configure
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
666 fi
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
667
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
668 echo "configure finished"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
669 echo
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
670 echo "Build Config:"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
671 echo " PREFIX: $PREFIX"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
672 echo " TOOLCHAIN: $TOOLCHAIN_NAME"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
673 echo "Options:"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
674 cat "$TEMP_DIR/options"
47
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
675 echo "Features:"
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
676 if [ -n "$FEATURE_DB" ]; then
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
677 echo " db: on"
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
678 else
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
679 echo " db: off"
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
680 fi
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
681 if [ -n "$FEATURE_GUI" ]; then
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
682 echo " gui: on"
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
683 else
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
684 echo " gui: off"
78ee95836412 automatically disable default-features if dependencies fail
Olaf Wintermann <olaf.wintermann@gmail.com>
parents: 46
diff changeset
685 fi
39
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
686 echo
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
687 cat "$TEMP_DIR/config.mk" "$TEMP_DIR/make.mk" > config.mk
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
688 rm -Rf "$TEMP_DIR"
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
689
3ca85da78515 add RegressionTest - fixes #264
Mike Becker <universe@uap-core.de>
parents:
diff changeset
690

mercurial