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-gc6.8.sh | 7 # nacl-gc6.8.sh |
8 # | 8 # |
9 # usage: nacl-gc6.8.sh | 9 # usage: nacl-gc6.8.sh |
10 # | 10 # |
11 # this script downloads, patches, and builds libgc for Native Client | 11 # this script downloads, patches, and builds libgc 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 | 16 |
17 CustomConfigureStep() { | 17 CustomConfigureStep() { |
18 Banner "Configuring ${PACKAGE_NAME}" | 18 Banner "Configuring ${PACKAGE_NAME}" |
19 # export the nacl tools | 19 # export the nacl tools |
20 export CC=${NACLCC} | 20 export CC=${NACLCC} |
21 export CXX=${NACLCXX} | 21 export CXX=${NACLCXX} |
22 export AR=${NACLAR} | 22 export AR=${NACLAR} |
23 export RANLIB=${NACLRANLIB} | 23 export RANLIB=${NACLRANLIB} |
24 export PKG_CONFIG_PATH=${NACL_SDK_USR_LIB}/pkgconfig | 24 export PKG_CONFIG_PATH=${NACLPORTS_LIBDIR}/pkgconfig |
25 export PKG_CONFIG_LIBDIR=${NACL_SDK_USR_LIB} | 25 export PKG_CONFIG_LIBDIR=${NACLPORTS_LIBDIR} |
26 export PATH=${NACL_BIN_PATH}:${PATH}; | 26 export PATH=${NACL_BIN_PATH}:${PATH}; |
27 ChangeDir ${NACL_PACKAGES_REPOSITORY}/${PACKAGE_NAME} | 27 ChangeDir ${NACL_PACKAGES_REPOSITORY}/${PACKAGE_NAME} |
28 Remove ${PACKAGE_NAME}-build | 28 Remove ${PACKAGE_NAME}-build |
29 MakeDir ${PACKAGE_NAME}-build | 29 MakeDir ${PACKAGE_NAME}-build |
30 cd ${PACKAGE_NAME}-build | 30 cd ${PACKAGE_NAME}-build |
31 ../configure \ | 31 ../configure \ |
32 --host=nacl \ | 32 --host=nacl \ |
33 --disable-shared \ | 33 --disable-shared \ |
34 --prefix=${NACL_SDK_USR} \ | 34 --prefix=${NACLPORTS_PREFIX} \ |
35 --exec-prefix=${NACL_SDK_USR} \ | 35 --exec-prefix=${NACLPORTS_PREFIX} \ |
36 --libdir=${NACL_SDK_USR_LIB} \ | 36 --libdir=${NACLPORTS_LIBDIR} \ |
37 --oldincludedir=${NACL_SDK_USR_INCLUDE} \ | 37 --oldincludedir=${NACLPORTS_INCLUDE} \ |
38 --with-http=off \ | 38 --with-http=off \ |
39 --with-html=off \ | 39 --with-html=off \ |
40 --with-ftp=off \ | 40 --with-ftp=off \ |
41 --enable-threads=pthreads \ | 41 --enable-threads=pthreads \ |
42 --${NACL_OPTION}-mmx \ | 42 --${NACL_OPTION}-mmx \ |
43 --${NACL_OPTION}-sse \ | 43 --${NACL_OPTION}-sse \ |
44 --${NACL_OPTION}-sse2 \ | 44 --${NACL_OPTION}-sse2 \ |
45 --${NACL_OPTION}-asm \ | 45 --${NACL_OPTION}-asm \ |
46 --with-x=no | 46 --with-x=no |
47 } | 47 } |
48 | 48 |
49 CustomPackageInstall() { | 49 CustomPackageInstall() { |
50 DefaultPreInstallStep | 50 DefaultPreInstallStep |
51 DefaultDownloadStep | 51 DefaultDownloadStep |
52 DefaultExtractStep | 52 DefaultExtractStep |
53 DefaultPatchStep | 53 DefaultPatchStep |
54 CustomConfigureStep | 54 CustomConfigureStep |
55 DefaultBuildStep | 55 DefaultBuildStep |
56 DefaultInstallStep | 56 DefaultInstallStep |
57 DefaultCleanUpStep | 57 DefaultCleanUpStep |
58 } | 58 } |
59 | 59 |
60 CustomPackageInstall | 60 CustomPackageInstall |
61 | 61 |
62 exit 0 | 62 exit 0 |
63 | 63 |
OLD | NEW |