1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145
|
#!/bin/sh
# Copyright (C) Philipp 'ph3-der-loewe' Schafft - 2008-2012
#
# This file is part of roard a part of RoarAudio,
# a cross-platform sound system for both, home and professional use.
# See README for details.
#
# This file is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 3
# as published by the Free Software Foundation.
#
# RoarAudio is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this software; see the file COPYING. If not, write to
# the Free Software Foundation, 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
# This code sets up $ROAR_BUILDSYSTEM_DIR
if [ "$1" = '--buildsystem' ]
then
ROAR_BUILDSYSTEM_DIR="$2"
shift 2
fi
if [ "$ROAR_BUILDSYSTEM_DIR" = '' ]
then
for dir in `roar-config --path prefix-buildsystem 2> /dev/null` \
/usr/lib/roaraudio/build-system/ \
/usr/local/lib/roaraudio/build-system/
do
if [ -d "$dir" ]
then
ROAR_BUILDSYSTEM_DIR="$dir"
break
fi
done
fi
if [ "$ROAR_BUILDSYSTEM_DIR" = '' ]
then
echo 'Can not find build system. Try --buildsystem /path/to/build-system/' >&2
exit 1
fi
# now we include the build system.
. "$ROAR_BUILDSYSTEM_DIR/configure.all"
# the real configure starts here:
# Bad libxml-2.0 hack:
CFLAGS="$CFLAGS -I/usr/include/libxml2"
test_libroar '1.0.11' || exit 1
test_pkgversion
test_buildstamp
test_cc
test_ranlib
test_pkgconfig
test_sysname
while [ "$1" != '' ]
do
parse_option "$@"
shift $SHIFT_COUNT
$HANDLED && continue;
case "$1" in
'--help')
write_help
echo 'OPTIONS:'
exit 0;
;;
*)
echo "Error: unknown option: $1" >&2;
echo "Try: $0 --help" >&2;
exit 1;
;;
esac;
shift;
done
open_configure_files
update_target
test_crosscompile
update_prefixes
update_ccft
update_cc
test_wextra
write_header _CONFIG_H_
test_bin_format
test_linkdeps
test_cp_v
echo -n 'checking for user id of root/superuser... '
if [ "$ROOT_UID" = '(none)' ]
then
echo "none (disabled by user)"
elif [ "$ROOT_UID" = '' ]
then
ROOT_USER='root'
ROOT_UID=`id -u $ROOT_USER`
if [ "$ROOT_UID" = '' ]
then
echo "none (please report this)"
else
echo "$ROOT_UID($ROOT_USER)"
echo "ROOT_UID=$ROOT_UID" >&4
fi
else
echo "$ROOT_UID"
echo "ROOT_UID=$ROOT_UID" >&4
fi
test_func_defmake HAVE_FUNC_UALARM ualarm 'ualarm(0, 0)' -- unistd.h
test_func_defmake HAVE_FUNC_SIGINTERRUPT siginterrupt 'siginterrupt(0, 0)' -- signal.h
test_lib_defmake HAVE_H_STDINT % stdint.h c -- stdint.h
test_lib_defmake HAVE_LIB_WSOCK32 % WinSockP0 wsock32 -- winsock2.h
test_lib_defmake HAVE_LIB_WS2_32 % WinSockP1 ws2_32 -- winsock2.h
test_lib_defmake HAVE_LIB_SLP % OpenSLP slp -- slp.h
test_lib_defmake HAVE_LIB_XML2 % libxml-2 xml2 -- libxml/tree.h libxml/parser.h libxml/xmlreader.h libxml/xpath.h libxml/xpathInternals.h libxml/uri.h
test_lib_defmake HAVE_LIB_ROAR % RoarAudio roar -- roaraudio.h
if [ "$?" != '0' ]
then
echo "Error: can not find libroar" >&2
exit 1
fi
write_vars_configh_literal ROOT_UID
write_vars_configh_string VERSION BUILD_STAMP DISTRIBUTION_VERSION_STRING
cleanup_ccft
write_footer
#ll
|