| OLD | NEW |
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. | 2 # Copyright (c) 2011 The Native Client Authors. All rights reserved. |
| 3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
| 4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
| 5 # | 5 # |
| 6 | 6 |
| 7 # nacl-SDL_mixer-1.2.11.sh | 7 # nacl-SDL_mixer-1.2.11.sh |
| 8 # | 8 # |
| 9 # usage: nacl-SDL_mixer-1.2.11.sh | 9 # usage: nacl-SDL_mixer-1.2.11.sh |
| 10 # | 10 # |
| 11 # this script downloads, patches, and builds SDL_mixer for Native Client | 11 # this script downloads, patches, and builds SDL_mixer for Native Client |
| 12 # | 12 # |
| 13 | 13 |
| 14 source pkg_info | 14 source pkg_info |
| 15 source ../../build_tools/common.sh | 15 source ../../build_tools/common.sh |
| 16 set -x |
| 16 | 17 |
| 17 CustomConfigureStep() { | 18 CustomConfigureStep() { |
| 18 Banner "Configuring ${PACKAGE_NAME}" | 19 Banner "Configuring ${PACKAGE_NAME}" |
| 19 # export the nacl tools | 20 # export the nacl tools |
| 20 export CC=${NACLCC} | 21 export CC=${NACLCC} |
| 21 export CXX=${NACLCXX} | 22 export CXX=${NACLCXX} |
| 22 export AR=${NACLAR} | 23 export AR=${NACLAR} |
| 23 export RANLIB=${NACLRANLIB} | 24 export RANLIB=${NACLRANLIB} |
| 24 export PKG_CONFIG_PATH=${NACL_SDK_USR_LIB}/pkgconfig | 25 export PKG_CONFIG_PATH=${NACLPORTS_LIBDIR}/pkgconfig |
| 25 export PKG_CONFIG_LIBDIR=${NACL_SDK_USR_LIB} | 26 export PKG_CONFIG_LIBDIR=${NACLPORTS_LIBDIR} |
| 26 # Adding target usr/bin for libmikmod-config | 27 # Adding target usr/bin for libmikmod-config |
| 27 export PATH=${NACL_BIN_PATH}:${NACL_SDK_USR}/bin:${PATH}; | 28 export PATH=${NACL_BIN_PATH}:${NACLPORTS_PREFIX}/bin:${PATH}; |
| 28 export LIBS="-lvorbisfile -lvorbis -logg -lm" | 29 export LIBS="-lvorbisfile -lvorbis -logg -lm" |
| 29 ChangeDir ${NACL_PACKAGES_REPOSITORY}/${PACKAGE_NAME} | 30 ChangeDir ${NACL_PACKAGES_REPOSITORY}/${PACKAGE_NAME} |
| 30 Remove ${PACKAGE_NAME}-build | 31 Remove ${PACKAGE_NAME}-build |
| 31 MakeDir ${PACKAGE_NAME}-build | 32 MakeDir ${PACKAGE_NAME}-build |
| 32 cd ${PACKAGE_NAME}-build | 33 cd ${PACKAGE_NAME}-build |
| 33 ../configure \ | 34 ../configure \ |
| 34 --host=nacl \ | 35 --host=nacl \ |
| 35 --disable-shared \ | 36 --disable-shared \ |
| 36 --prefix=${NACL_SDK_USR} \ | 37 --prefix=${NACLPORTS_PREFIX} \ |
| 37 --exec-prefix=${NACL_SDK_USR} \ | 38 --exec-prefix=${NACLPORTS_PREFIX} \ |
| 38 --libdir=${NACL_SDK_USR_LIB} \ | 39 --libdir=${NACLPORTS_LIBDIR} \ |
| 39 --oldincludedir=${NACL_SDK_USR_INCLUDE} \ | 40 --oldincludedir=${NACLPORTS_INCLUDE} \ |
| 40 --${NACL_OPTION}-mmx \ | 41 --${NACL_OPTION}-mmx \ |
| 41 --${NACL_OPTION}-sse \ | 42 --${NACL_OPTION}-sse \ |
| 42 --${NACL_OPTION}-sse2 \ | 43 --${NACL_OPTION}-sse2 \ |
| 43 --${NACL_OPTION}-asm \ | 44 --${NACL_OPTION}-asm \ |
| 44 --with-x=no \ | 45 --with-x=no \ |
| 45 --disable-music-flac \ | 46 --disable-music-flac \ |
| 46 --disable-music-mp3 | 47 --disable-music-mp3 |
| 47 } | 48 } |
| 48 | 49 |
| 49 | 50 |
| 50 CustomPackageInstall() { | 51 CustomPackageInstall() { |
| 51 DefaultPreInstallStep | 52 DefaultPreInstallStep |
| 52 DefaultDownloadStep | 53 DefaultDownloadStep |
| 53 DefaultExtractStep | 54 DefaultExtractStep |
| 54 DefaultPatchStep | 55 DefaultPatchStep |
| 55 CustomConfigureStep | 56 CustomConfigureStep |
| 56 DefaultBuildStep | 57 DefaultBuildStep |
| 57 DefaultInstallStep | 58 DefaultInstallStep |
| 58 DefaultCleanUpStep | 59 DefaultCleanUpStep |
| 59 } | 60 } |
| 60 | 61 |
| 61 | 62 |
| 62 CustomPackageInstall | 63 CustomPackageInstall |
| 63 exit 0 | 64 exit 0 |
| OLD | NEW |