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

Unified Diff: ports/devenv/build.sh

Issue 1555913002: Build gtest from source rather than using SDK-provided version (Closed) Base URL: https://chromium.googlesource.com/webports.git@master
Patch Set: Created 4 years, 12 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 side-by-side diff with in-line comments
Download patch
Index: ports/devenv/build.sh
diff --git a/ports/devenv/build.sh b/ports/devenv/build.sh
index 3596d3044f170cdfe474d7bbbf764f14a7598a1c..f3394a4e50f937d7e4e43b83efcf6928cf15eb4b 100644
--- a/ports/devenv/build.sh
+++ b/ports/devenv/build.sh
@@ -4,6 +4,7 @@
EnableCliMain
NACLPORTS_CPPFLAGS+=" -Wall -Werror -Dpipe=nacl_spawn_pipe"
+NACLPORTS_CPPFLAGS+=" -isystem ${GTEST_SRC}/include"
EXECUTABLES="tests/devenv_small_test_${NACL_ARCH}${NACL_EXEEXT} \
jseval/jseval_${NACL_ARCH}${NACL_EXEEXT}"
@@ -25,11 +26,17 @@ BuildStep() {
${LIBS}
# Build test module.
- MakeDir ${BUILD_DIR}/tests
- LogExecute ${CXX} ${CPPFLAGS} ${CXXFLAGS} ${LDFLAGS} \
- ${START_DIR}/tests/devenv_small_test.cc \
- -o ${BUILD_DIR}/tests/devenv_small_test_${NACL_ARCH}${NACL_EXEEXT} \
- -lgtest ${LIBS}
+ LogExecute ${CXX} ${CPPFLAGS} ${CXXFLAGS} -o devenv_small_test.o \
binji 2016/01/04 19:12:54 what directory does this write to? It used to pref
Sam Clegg 2016/01/05 12:41:14 The CWD in the BuildStep is BUILD_DIR so it was re
+ -c ${START_DIR}/tests/devenv_small_test.cc
+ LogExecute ${CXX} ${CPPFLAGS} ${CXXFLAGS} -o gtest-all.o \
+ -c ${GTEST_SRC}/src/gtest-all.cc -I${GTEST_SRC}
+
+ LogExecute ${CXX} ${LDFLAGS} devenv_small_test.o gtest-all.o ${LIBS} \
+ -o devenv_small_test_${NACL_ARCH}${NACL_EXEEXT}
+
+ if [[ ${NACL_ARCH} == pnacl ]]; then
+ LogExecute ${PNACLFINALIZE} devenv_small_test_${NACL_ARCH}${NACL_EXEEXT}
+ fi
}
InstallStep() {
@@ -162,11 +169,8 @@ PublishStep() {
# Install tests.
MakeDir ${PUBLISH_DIR}/tests
- LogExecute cp -r ${BUILD_DIR}/tests/* ${PUBLISH_DIR}/tests
+ LogExecute cp -r ${BUILD_DIR}/tests/*${NACL_EXEEXT} ${PUBLISH_DIR}/tests
cd ${PUBLISH_DIR}/tests
- if [[ ${NACL_ARCH} == pnacl ]]; then
- LogExecute ${PNACLFINALIZE} devenv_small_test_${NACL_ARCH}${NACL_EXEEXT}
- fi
LogExecute python ${NACL_SDK_ROOT}/tools/create_nmf.py \
devenv_small_test_${NACL_ARCH}${NACL_EXEEXT} \
-s . \
« no previous file with comments | « ports/corelibs/build.sh ('k') | ports/devenv/pkg_info » ('j') | ports/gtest/build.sh » ('J')

Powered by Google App Engine
This is Rietveld 408576698