From: SeokYeon Hwang Date: Fri, 6 Nov 2015 02:33:32 +0000 (+0900) Subject: DIBS: build on DIBS in the same way on local X-Git-Tag: Tizen_Studio_1.3_Release_p2.3.2~185 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ddc4595e68572be506ef2edec5cbb26f1dec5b1b;p=sdk%2Femulator%2Fqemu.git DIBS: build on DIBS in the same way on local Using TIZEN_SDK_DEV_PATH instead of overriding PKG_CONFIG_PATH. Change-Id: Ib99c9e6149cbca93c278e84873b8a93de6f436e0 Signed-off-by: SeokYeon Hwang --- diff --git a/package/build.common b/package/build.common index 2b5100a5b5..917b91178c 100644 --- a/package/build.common +++ b/package/build.common @@ -15,12 +15,12 @@ build_common() prepare_common prepare - cd ${SRCDIR}/tizen + TIZEN_SDK_DEV_PATH=${ROOTDIR} + PATH=${TIZEN_SDK_DEV_PATH}/bin:${PATH} - PKG_CONFIG_PATH=${ROOTDIR}/lib/pkgconfig - PATH=${PATH}:${ROOTDIR}/bin + cd ${SRCDIR}/tizen - PKG_CONFIG_PATH=${PKG_CONFIG_PATH} ./emulator_configure.sh x86_64 + TIZEN_SDK_DEV_PATH=${TIZEN_SDK_DEV_PATH} ./emulator_configure.sh x86_64 make clean # needed for building java UI diff --git a/package/build.macos b/package/build.macos new file mode 100755 index 0000000000..a3c38286a9 --- /dev/null +++ b/package/build.macos @@ -0,0 +1,59 @@ +#!/bin/sh -xe +# check build environment +prepare() +{ + if [ "${TARGET_OS}" != "macos-64" ] + then + exit 1 + fi +} + +# clean +clean() +{ + echo "nothing to do" +} + +# build +build() +{ + . $SRCDIR/package/build.common + build_common +} + +# install +install() +{ + . $SRCDIR/package/build.common + install_common + + EMULATOR_BIN_DIR=$EMULATOR_X86_DIR/emulator/bin + + # change loading path of dynamic shared libraries on MAC OS X + if [ "${TARGET_OS}" = "macos-64" ]; then + LIB_LIST="libgthread-2.0.0.dylib libglib-2.0.0.dylib libintl.8.dylib libgcc_s.1.dylib libz.1.dylib libcurl.4.dylib libgcc_s.1.dylib libcurl.4.dylib libx264.142.dylib libncurses.5.dylib libpixman-1.0.dylib libpng16.16.dylib QtOpenGL QtWidgets QtGui QtCore" + BIN_ARR=( emulator-x86_64 qt5_msgbox ) + for bin in ${BIN_ARR[@]}; do + LIB_ARR=( $(otool -L ${EMULATOR_BIN_DIR}/$bin | awk '/\opt\/local\/lib/ { split($1, lib, "/"); print lib[5]}') ) + for lib in ${LIB_ARR[@]}; do + [[ $LIB_LIST =~ $lib ]] && IS_LIB=true || IS_LIB=false + if [ "$IS_LIB" == "true" ] ; then + install_name_tool -change /opt/local/lib/$lib @loader_path/$lib ${EMULATOR_BIN_DIR}/$bin + echo "$bin: the loading path of $lib is changed." + else + echo "$bin: $lib does not exist in the loading path." + fi + done + LIB_ARR=( $(otool -L ${EMULATOR_BIN_DIR}/$bin | awk '/\opt\/local\/Library/ { split($1, lib, "/"); print lib[9]}') ) + for lib in ${LIB_ARR[@]}; do + [[ $LIB_LIST =~ $lib ]] && IS_LIB=true || IS_LIB=false + if [ "$IS_LIB" == "true" ] ; then + install_name_tool -change /opt/local/Library/Frameworks/$lib.framework/Versions/5/$lib @loader_path/$lib ${EMULATOR_BIN_DIR}/$bin + echo "$bin: the loading path of $lib is changed." + else + echo "$bin: $lib does not exist in the loading path." + fi + done + done + fi +} diff --git a/package/build.macos-64 b/package/build.macos-64 deleted file mode 100755 index a3c38286a9..0000000000 --- a/package/build.macos-64 +++ /dev/null @@ -1,59 +0,0 @@ -#!/bin/sh -xe -# check build environment -prepare() -{ - if [ "${TARGET_OS}" != "macos-64" ] - then - exit 1 - fi -} - -# clean -clean() -{ - echo "nothing to do" -} - -# build -build() -{ - . $SRCDIR/package/build.common - build_common -} - -# install -install() -{ - . $SRCDIR/package/build.common - install_common - - EMULATOR_BIN_DIR=$EMULATOR_X86_DIR/emulator/bin - - # change loading path of dynamic shared libraries on MAC OS X - if [ "${TARGET_OS}" = "macos-64" ]; then - LIB_LIST="libgthread-2.0.0.dylib libglib-2.0.0.dylib libintl.8.dylib libgcc_s.1.dylib libz.1.dylib libcurl.4.dylib libgcc_s.1.dylib libcurl.4.dylib libx264.142.dylib libncurses.5.dylib libpixman-1.0.dylib libpng16.16.dylib QtOpenGL QtWidgets QtGui QtCore" - BIN_ARR=( emulator-x86_64 qt5_msgbox ) - for bin in ${BIN_ARR[@]}; do - LIB_ARR=( $(otool -L ${EMULATOR_BIN_DIR}/$bin | awk '/\opt\/local\/lib/ { split($1, lib, "/"); print lib[5]}') ) - for lib in ${LIB_ARR[@]}; do - [[ $LIB_LIST =~ $lib ]] && IS_LIB=true || IS_LIB=false - if [ "$IS_LIB" == "true" ] ; then - install_name_tool -change /opt/local/lib/$lib @loader_path/$lib ${EMULATOR_BIN_DIR}/$bin - echo "$bin: the loading path of $lib is changed." - else - echo "$bin: $lib does not exist in the loading path." - fi - done - LIB_ARR=( $(otool -L ${EMULATOR_BIN_DIR}/$bin | awk '/\opt\/local\/Library/ { split($1, lib, "/"); print lib[9]}') ) - for lib in ${LIB_ARR[@]}; do - [[ $LIB_LIST =~ $lib ]] && IS_LIB=true || IS_LIB=false - if [ "$IS_LIB" == "true" ] ; then - install_name_tool -change /opt/local/Library/Frameworks/$lib.framework/Versions/5/$lib @loader_path/$lib ${EMULATOR_BIN_DIR}/$bin - echo "$bin: the loading path of $lib is changed." - else - echo "$bin: $lib does not exist in the loading path." - fi - done - done - fi -}