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

Unified Diff: run_tests.sh

Issue 2795008: Update with note. (Closed) Base URL: ssh://git@chromiumos-git/crosutils.git
Patch Set: Created 10 years, 6 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: run_tests.sh
diff --git a/run_tests.sh b/run_tests.sh
index 83715bd63b8862ad5ecaf71c17cf39f244b15e72..3d2c8bd9b69f4b7f1bc24a6290f2ea0b4471426a 100755
--- a/run_tests.sh
+++ b/run_tests.sh
@@ -51,10 +51,24 @@ trap cleanup ERR 0
# NOTE: We currently skip cryptohome_tests (which happens to have a different
# suffix than the other tests), because it doesn't work.
+# NOTE: Removed explicit use of the target board's ld-linux.so.2 so that this
+# will work on hardened builds (with PIE on by default). Tests pass on
+# hardened and non-hardened builds without this explicit use, but we only
+# disable this on hardened, since that is where the PIE conflict happens.
for i in ${TESTS_DIR}/*_{test,unittests}; do
if [[ "`file -b $i`" = "POSIX shell script text executable" ]]; then
- LD_LIBRARY_PATH=$LD_LIBRARY_PATH /build/${FLAGS_board}/lib/ld-linux.so.2 /build/${FLAGS_board}/bin/bash $i
+ if [[ -f /etc/hardened ]]; then
+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH /build/${FLAGS_board}/bin/bash $i
+ else
+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH /build/${FLAGS_board}/lib/ld-linux.so.2 /build/${FLAGS_board}/bin/bash $i
+ fi
else
- LD_LIBRARY_PATH=$LD_LIBRARY_PATH /build/${FLAGS_board}/lib/ld-linux.so.2 $i
+ if [[ -f /etc/hardened ]]; then
+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH $i
+ else
+ LD_LIBRARY_PATH=$LD_LIBRARY_PATH /build/${FLAGS_board}/lib/ld-linux.so.2 $i
+ fi
fi
done
+
+
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698