Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(150)

Side by Side Diff: libraries/agg-2.5/nacl-agg-2.5.sh

Issue 11885025: Allow re-targeting of naclports install (Closed) Base URL: http://naclports.googlecode.com/svn/trunk/src
Patch Set: Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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-agg-2.5.sh 7 # nacl-agg-2.5.sh
8 # 8 #
9 # usage: nacl-agg-2.5.sh 9 # usage: nacl-agg-2.5.sh
10 # 10 #
11 # this script downloads, patches, and builds agg for Native Client 11 # this script downloads, patches, and builds agg for Native Client
12 # 12 #
13 13
14 readonly URL=http://commondatastorage.googleapis.com/nativeclient-mirror/nacl/ag g-2.5.tar.gz 14 readonly URL=http://commondatastorage.googleapis.com/nativeclient-mirror/nacl/ag g-2.5.tar.gz
15 #readonly URL=http://www.antigrain.com/agg-2.5.tar.gz 15 #readonly URL=http://www.antigrain.com/agg-2.5.tar.gz
16 readonly PATCH_FILE=nacl-agg-2.5.patch 16 readonly PATCH_FILE=nacl-agg-2.5.patch
17 readonly PACKAGE_NAME=agg-2.5 17 readonly PACKAGE_NAME=agg-2.5
18 18
19 source ../../build_tools/common.sh 19 source ../../build_tools/common.sh
20 20
21 21
22 CustomBuildStep() { 22 CustomBuildStep() {
23 cd ${NACL_PACKAGES_REPOSITORY}/${PACKAGE_NAME} 23 cd ${NACL_PACKAGES_REPOSITORY}/${PACKAGE_NAME}
24 if [ ${NACL_ARCH} = "pnacl" ] ; then 24 local cflags="${NACLPORTS_CFLAGS}"
25 extra="" 25 if [ ${NACL_ARCH} != "pnacl" ] ; then
26 else 26 cflags="${cflags} -O3 -mfpmath=sse -msse -fomit-frame-pointer"
27 extra="-O3 -mfpmath=sse -msse -fomit-frame-pointer"
28 fi 27 fi
29 AGGCXXFLAGS="${extra}" make NACLCXX=${NACLCXX} NACLCC=${NACLCC} NACLAR=${NACLA R} 28 AGGCXXFLAGS="${cflags}" make NACLCXX=${NACLCXX} NACLCC=${NACLCC} NACLAR=${NACL AR}
30 } 29 }
31 30
32 31
33 CustomInstallStep() { 32 CustomInstallStep() {
34 # copy libs and headers manually 33 # copy libs and headers manually
35 ChangeDir ${NACL_SDK_USR_INCLUDE} 34 ChangeDir ${NACLPORTS_INCLUDE}
36 Remove ${PACKAGE_NAME} 35 Remove ${PACKAGE_NAME}
37 MakeDir ${PACKAGE_NAME} 36 MakeDir ${PACKAGE_NAME}
38 readonly THIS_PACKAGE_PATH=${NACL_PACKAGES_REPOSITORY}/${PACKAGE_NAME} 37 readonly THIS_PACKAGE_PATH=${NACL_PACKAGES_REPOSITORY}/${PACKAGE_NAME}
39 cp -R ${THIS_PACKAGE_PATH}/include/*.h ${PACKAGE_NAME}/ 38 cp -R ${THIS_PACKAGE_PATH}/include/*.h ${PACKAGE_NAME}/
40 cp ${THIS_PACKAGE_PATH}/font_freetype/*.h ${PACKAGE_NAME}/ 39 cp ${THIS_PACKAGE_PATH}/font_freetype/*.h ${PACKAGE_NAME}/
41 ChangeDir ${NACL_SDK_USR_LIB} 40 ChangeDir ${NACLPORTS_LIBDIR}
42 cp ${THIS_PACKAGE_PATH}/src/libagg.a . 41 cp ${THIS_PACKAGE_PATH}/src/libagg.a .
43 cp ${THIS_PACKAGE_PATH}/font_freetype/libaggfontfreetype.a . 42 cp ${THIS_PACKAGE_PATH}/font_freetype/libaggfontfreetype.a .
44 DefaultTouchStep 43 DefaultTouchStep
45 } 44 }
46 45
47 46
48 CustomPackageInstall() { 47 CustomPackageInstall() {
49 DefaultPreInstallStep 48 DefaultPreInstallStep
50 DefaultDownloadStep 49 DefaultDownloadStep
51 DefaultExtractStep 50 DefaultExtractStep
52 DefaultPatchStep 51 DefaultPatchStep
53 CustomBuildStep 52 CustomBuildStep
54 CustomInstallStep 53 CustomInstallStep
55 DefaultCleanUpStep 54 DefaultCleanUpStep
56 } 55 }
57 56
58 57
59 CustomPackageInstall 58 CustomPackageInstall
60 exit 0 59 exit 0
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698