- Timestamp:
- 2016-09-24T20:14:34Z (8 years ago)
- Children:
- ba52ac5
- Parents:
- 63cad66 (diff), 82cb190 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
configure
r63cad66 r3fbce97 24 24 pcdir='$prefix/lib/pkgconfig' 25 25 systemlibdirs="/lib64 /usr/lib64 /usr/local/lib64 /lib /usr/lib /usr/local/lib" 26 sysroot='' 27 28 configure_args="$@" 26 29 27 30 # Set these to default-on to let it be overriden by either the user or purple … … 53 56 pie=1 54 57 55 arch= `uname -s`56 cpu= `uname -m`58 arch=$(uname -s) 59 cpu=$(uname -m) 57 60 58 61 GLIB_MIN_VERSION=2.16 … … 105 108 106 109 while [ -n "$1" ]; do 107 e=" `expr "X$1" : 'X--\(.*=.*\)'`"110 e="$(expr "X$1" : 'X--\(.*=.*\)')" 108 111 if [ -z "$e" ]; then 109 112 cat<<EOF … … 153 156 154 157 --target=... Cross compilation target same as host 158 --sysroot=... Cross compilation sysroot $sysroot 155 159 EOF 156 160 exit; … … 161 165 162 166 # Expand $prefix and get rid of double slashes 163 bindir= `eval echo "$bindir/" | sed 's/\/\{1,\}/\//g'`164 sbindir= `eval echo "$sbindir/" | sed 's/\/\{1,\}/\//g'`165 etcdir= `eval echo "$etcdir/" | sed 's/\/\{1,\}/\//g'`166 mandir= `eval echo "$mandir/" | sed 's/\/\{1,\}/\//g'`167 datadir= `eval echo "$datadir/" | sed 's/\/\{1,\}/\//g'`168 config= `eval echo "$config/" | sed 's/\/\{1,\}/\//g'`169 plugindir= `eval echo "$plugindir/" | sed 's/\/\{1,\}/\//g'`167 bindir=$(eval echo "$bindir/" | sed 's/\/\{1,\}/\//g') 168 sbindir=$(eval echo "$sbindir/" | sed 's/\/\{1,\}/\//g') 169 etcdir=$(eval echo "$etcdir/" | sed 's/\/\{1,\}/\//g') 170 mandir=$(eval echo "$mandir/" | sed 's/\/\{1,\}/\//g') 171 datadir=$(eval echo "$datadir/" | sed 's/\/\{1,\}/\//g') 172 config=$(eval echo "$config/" | sed 's/\/\{1,\}/\//g') 173 plugindir=$(eval echo "$plugindir/" | sed 's/\/\{1,\}/\//g') 170 174 rpcplugindir=$(eval echo "$rpcplugindir/" | sed 's/\/\{1,\}/\//g') 171 includedir= `eval echo "$includedir"/ | sed 's/\/\{1,\}/\//g'`172 libevent= `eval echo "$libevent"/ | sed 's/\/\{1,\}/\//g'`173 174 pidfile= `eval echo "$pidfile" | sed 's/\/\{1,\}/\//g'`175 ipcsocket= `eval echo "$ipcsocket" | sed 's/\/\{1,\}/\//g'`176 pcdir= `eval echo "$pcdir" | sed 's/\/\{1,\}/\//g'`175 includedir=$(eval echo "$includedir"/ | sed 's/\/\{1,\}/\//g') 176 libevent=$(eval echo "$libevent"/ | sed 's/\/\{1,\}/\//g') 177 178 pidfile=$(eval echo "$pidfile" | sed 's/\/\{1,\}/\//g') 179 ipcsocket=$(eval echo "$ipcsocket" | sed 's/\/\{1,\}/\//g') 180 pcdir=$(eval echo "$pcdir" | sed 's/\/\{1,\}/\//g') 177 181 178 182 protocols_mods="" … … 180 184 cat <<EOF >Makefile.settings 181 185 ## BitlBee settings, generated by configure 186 187 # ./configure $configure_args 188 182 189 PREFIX=$prefix 183 190 BINDIR=$bindir … … 233 240 of them can/will be overridden at run-time */ 234 241 242 #define BITLBEE_CONFIGURE_ARGS "$configure_args" 243 235 244 #define CONFIG "$config" 236 245 #define ETCDIR "$etcdir" … … 247 256 248 257 if [ -n "$target" ]; then 249 PKG_CONFIG_LIBDIR=/usr/$target/lib/pkgconfig 250 export PKG_CONFIG_LIBDIR 251 PATH=/usr/$target/bin:$PATH 258 # prepend sysroot to system lib dirs 259 260 systemlibdirs_cross='' 261 for i in $systemlibdirs; do 262 systemlibdirs_cross="$systemlibdirs_cross $sysroot$i" 263 done 264 systemlibdirs=$systemlibdirs_cross 265 unset systemlibdirs_cross 266 267 # backward compatibility 268 269 if [ -z "$PKG_CONFIG_LIBDIR" ]; then 270 PKG_CONFIG_LIBDIR=/usr/$target/lib/pkgconfig 271 export PKG_CONFIG_LIBDIR 272 fi 273 274 if [ -d /usr/$target/bin ]; then 275 PATH=/usr/$target/bin:$PATH 276 fi 277 278 if [ -d /usr/$target/lib ]; then 279 systemlibdirs="$systemlibdirs /usr/$target/lib" 280 fi 281 252 282 CC=$target-cc 253 283 LD=$target-ld 254 systemlibdirs="/usr/$target/lib"284 STRIP=$target-strip 255 285 fi 256 286 … … 321 351 if $PKG_CONFIG glib-2.0 --atleast-version=$GLIB_MIN_VERSION; then 322 352 cat<<EOF >>Makefile.settings 323 EFLAGS+= `$PKG_CONFIG --libs glib-2.0 gmodule-2.0`324 CFLAGS+= `$PKG_CONFIG --cflags glib-2.0 gmodule-2.0`353 EFLAGS+=$($PKG_CONFIG --libs glib-2.0 gmodule-2.0) 354 CFLAGS+=$($PKG_CONFIG --cflags glib-2.0 gmodule-2.0) 325 355 EOF 326 356 else 327 357 echo 328 echo 'Found glib2 ' `$PKG_CONFIG glib-2.0 --modversion`', but version '$GLIB_MIN_VERSION' or newer is required.'358 echo 'Found glib2 '$($PKG_CONFIG glib-2.0 --modversion)', but version '$GLIB_MIN_VERSION' or newer is required.' 329 359 exit 1 330 360 fi … … 362 392 if $PKG_CONFIG --exists gnutls; then 363 393 cat <<EOF >>Makefile.settings 364 EFLAGS+= `$PKG_CONFIG --libs gnutls` `libgcrypt-config --libs`365 CFLAGS+= `$PKG_CONFIG --cflags gnutls` `libgcrypt-config --cflags`394 EFLAGS+=$($PKG_CONFIG --libs gnutls) $(libgcrypt-config --libs) 395 CFLAGS+=$($PKG_CONFIG --cflags gnutls) $(libgcrypt-config --cflags) 366 396 EOF 367 397 ssl=gnutls 368 if ! pkg-configgnutls --atleast-version=2.8; then398 if ! $PKG_CONFIG gnutls --atleast-version=2.8; then 369 399 echo 370 400 echo 'Warning: With GnuTLS versions <2.8, certificate expire dates are not verified.' … … 373 403 elif libgnutls-config --version > /dev/null 2> /dev/null; then 374 404 cat <<EOF >>Makefile.settings 375 EFLAGS+= `libgnutls-config --libs` `libgcrypt-config --libs`376 CFLAGS+= `libgnutls-config --cflags` `libgcrypt-config --cflags`405 EFLAGS+=$(libgnutls-config --libs) $(libgcrypt-config --libs) 406 CFLAGS+=$(libgnutls-config --cflags) $(libgcrypt-config --cflags) 377 407 EOF 378 408 … … 388 418 if $PKG_CONFIG --version > /dev/null 2>/dev/null && $PKG_CONFIG nss; then 389 419 cat<<EOF >>Makefile.settings 390 EFLAGS+= `$PKG_CONFIG --libs nss`391 CFLAGS+= `$PKG_CONFIG --cflags nss`420 EFLAGS+=$($PKG_CONFIG --libs nss) 421 CFLAGS+=$($PKG_CONFIG --cflags nss) 392 422 EOF 393 423 … … 634 664 if [ -z "$systemdsystemunitdir" ]; then 635 665 if $PKG_CONFIG --exists systemd; then 636 systemdsystemunitdir= `$PKG_CONFIG --variable=systemdsystemunitdir systemd`666 systemdsystemunitdir=$($PKG_CONFIG --variable=systemdsystemunitdir systemd) 637 667 fi 638 668 fi … … 662 692 663 693 otrprefix="" 664 for i in / /usr /usr/local; do665 if [ -f ${i}/lib/libotr.a ]; then666 otrprefix=${i}667 break668 fi669 done670 694 if [ "$otr" = "auto" ]; then 671 if [ -n "$otrprefix" ]; then 672 otr=1 673 else 674 otr=0 675 fi 676 fi 695 ! $PKG_CONFIG --exists libotr 696 otr=$? 697 fi 698 699 if [ "$otr" != 0 ] && ! $PKG_CONFIG --atleast-version=4.0 --print-errors libotr; then 700 exit 1 701 fi 702 677 703 if [ "$otr" = 1 ]; then 678 704 # BI == built-in 679 705 echo '#define OTR_BI' >> config.h 680 echo "EFLAGS+= -L${otrprefix}/lib -lotr -lgcrypt" >> Makefile.settings681 echo "CFLAGS+= -I${otrprefix}/include" >> Makefile.settings706 echo "EFLAGS+=$($PKG_CONFIG --libs libotr) $(libgcrypt-config --libs)" >> Makefile.settings 707 echo "CFLAGS+=$($PKG_CONFIG --cflags libotr) $(libgcrypt-config --cflags)" >> Makefile.settings 682 708 echo 'OTR_BI=otr.o' >> Makefile.settings 683 709 elif [ "$otr" = "plugin" ]; then 710 # for some mysterious reason beyond the comprehension of my mortal mind, 711 # the libgcrypt flags aren't needed when building as plugin. add them anyway. 684 712 echo '#define OTR_PI' >> config.h 685 echo "OTRFLAGS= -L${otrprefix}/lib -lotr" >> Makefile.settings686 echo "CFLAGS+= -I${otrprefix}/include" >> Makefile.settings713 echo "OTRFLAGS=$($PKG_CONFIG --libs libotr) $(libgcrypt-config --libs)" >> Makefile.settings 714 echo "CFLAGS+=$($PKG_CONFIG --cflags libotr) $(libgcrypt-config --cflags)" >> Makefile.settings 687 715 echo 'OTR_PI=otr.so' >> Makefile.settings 688 fi689 if [ "$otr" != 0 ] && ! pkg-config libotr --atleast-version=4.0; then690 echo691 echo 'WARNING: Your libotr seems to be old. BitlBee now needs at least libotr 4.0.'692 # Not hard-failing because the code above doesn't use pkg-config, so who knows693 # what's true at this point...694 716 fi 695 717
Note: See TracChangeset
for help on using the changeset viewer.