6
if test "$*" = "--help" -o "$*" = "-h"; then
7
echo "$F [--simulator] [OPTIONS]"
10
echo " --simulator Optional parameter to specify that the compilation"
11
echo " target is a simulator."
12
echo " OPTIONS Other options that will be passed directly to"
13
echo " ./configure script. Run ./configure --help"
14
echo " for more info."
18
# Find simulator argument
22
if test "$arg" = "--simulator"; then
29
if test "$simulator" = "yes"; then
31
TARGET_ARCHEND=${TARGET_ARCH}
33
TARGET_HOST="i486-pc-nto-qnx8.0.0"
36
TARGET_ARCHEND="${TARGET_ARCH}le"
38
TARGET_HOST="arm-unknown-nto-qnx8.0.0eabi"
41
RANLIB="${QNX_HOST}/usr/bin/nto${TARGET_ARCH}-ranlib "
42
CPP="${QNX_HOST}/usr/bin/qcc -V4.6.3,gcc_nto${TARGET_ARCHEND}_cpp -E "
43
CC="${QNX_HOST}/usr/bin/qcc -V4.6.3,gcc_nto${TARGET_ARCHEND}_cpp "
44
LD="${QNX_HOST}/usr/bin/nto${TARGET_ARCH}-ld "
45
export LDFLAGS="$LDFLAGS -L${QNX_TARGET}/${LIBDIR}/usr/lib -L${QNX_TARGET}/${LIBDIR}/lib -L${QNX_HOST}/usr/lib/gcc/${TARGET_HOST}/4.6.3 -lgcc -lasound -laudio_manager"
47
if test "$CFLAGS" = ""; then
48
# Default if no CFLAGS is set in env
49
export CFLAGS=" -g -O2"
51
export CFLAGS="$CFLAGS -fPIC -DPJ_CONFIG_BB10=1 -DPJMEDIA_AUDIO_DEV_HAS_BB10=1"
54
./configure --host=${TARGET_HOST} --disable-oss $args
57
# Write to pjsip.pri only if configure was successful
58
if test $RETVAL -eq 0; then
59
echo "# Config file to be included in app's .pro file" > pjsip.pri
60
echo "# Auto-generated by 'configure-bb10 $*'" >> pjsip.pri
61
make -f bb10-config.mak >> pjsip.pri
63
echo PJSIP config file for BB10 has been written to \'pjsip.pri\'. You can include this file from your application\'s .pro file.