unrealircd- supernets unrealircd source & configuration |
git clone git://git.acid.vegas/unrealircd.git |
Log | Files | Refs | Archive | README | LICENSE |
build (2201B)
1 #!/bin/bash 2 3 # Exit on any failure: 4 set -e 5 6 # Verbose: 7 set -x 8 9 if [ "$1" != "" ]; then 10 BUILDCONFIG="$*" 11 fi 12 13 if [[ "$OSTYPE" == "freebsd"* ]]; then 14 export MAKE="gmake -j4" 15 else 16 export MAKE="make -j4" 17 fi 18 19 export CPPFLAGS="-DFAKELAG_CONFIGURABLE -DNOREMOVETMP -DRAWCMDLOGGING" 20 21 # !! skipped for now: extras/build-tests/nix/select-config $BUILDCONFIG !! 22 # !! temporary use this: 23 cp extras/build-tests/nix/configs/default ./config.settings 24 25 # Debian 8 workaround: 26 if lsb_release -av 2>&1|egrep 'Debian.*jessie'; then 27 echo "Disabling ASan due to false positives on deb8" 28 echo 'EXTRAPARA="--enable-werror --disable-asan"' >>config.settings 29 fi 30 if uname -s|grep -i freebsd; then 31 echo "Disabling ASan on FreeBSD due to 100% CPU loop in OpenSSL initialization routine" 32 echo 'EXTRAPARA="--enable-werror --disable-asan"' >>config.settings 33 fi 34 35 # If SSLDIR is set the environment, this overrides config.settings 36 # Used for example in the openssl3 build tests. 37 if [ "$SSLDIR" != "" ]; then 38 echo 'SSLDIR="'"$SSLDIR"'"' >>config.settings 39 fi 40 41 # Read config.settings, this makes a couple of variables available to us. 42 . ./config.settings 43 if [ "$SSLDIR" != "" ]; then 44 # In case we build local openssl/libressl 45 export LD_LIBRARY_PATH="$SSLDIR/lib" 46 fi 47 ./Config -quick || (tail -n 5000 config.log; exit 1) 48 $MAKE 49 yes ''|$MAKE pem 50 $MAKE || exit 1 51 $MAKE install || exit 1 52 ./unrealircd module install third/dumpcmds || exit 1 53 54 set +x 55 echo "" 56 echo "***********************************************" 57 echo "UnrealIRCd build & install successful." 58 echo "***********************************************" 59 60 if [[ "$OSTYPE" == "darwin"* ]]; then 61 otool -L ~/unrealircd/bin/unrealircd 62 else 63 ldd ~/unrealircd/bin/unrealircd 64 fi 65 66 if [ "$BUILDCONFIG" = "local-curl" ]; then 67 # We broke the system significantly earlier that build tests 68 # won't work (eg: 'git' is uninstallable). Don't bother 69 # running the tests. I don't expect a 'local-curl' specific 70 # bug anyway. 71 exit 0 72 fi 73 74 if [[ "$OSTYPE" == "darwin"* ]]; then 75 # 'rake' doesn't work. have to figure that one out.. 76 echo "Not running test on OS X for now" 77 exit 0 78 fi 79 80 echo "" 81 echo "" 82 #echo "Now running UnrealIRCd test framework..." 83 #set -x 84 #extras/build-tests/nix/run-tests