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

Unified Diff: chrome/tools/build/mac/verify_order

Issue 1413863003: mac: In static library builds, link against a static libc++.a (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: haaaaack Created 5 years, 2 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 | « chrome/chrome_dll.gypi ('k') | third_party/libc++-static/build.sh » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/tools/build/mac/verify_order
diff --git a/chrome/tools/build/mac/verify_order b/chrome/tools/build/mac/verify_order
index 3d5d644a4c484afbcc1dd5941daf5332e81a87c8..cfa4c5a28e30168d99c10c05001442bd02126daf 100755
--- a/chrome/tools/build/mac/verify_order
+++ b/chrome/tools/build/mac/verify_order
@@ -12,6 +12,8 @@
#
# This script can be used to verify that all of the global text symbols in
# a Mach-O file are accounted for in an order file.
+#
+# Also check that the file does not depend on either of libstdc++ or libc++.
if [ ${#} -ne 2 ] ; then
echo "usage: ${0} LAST_SYMBOL MACH_O_FILE" >& 2
@@ -40,4 +42,18 @@ if [ ${?} -eq 0 ] || [ -n "${UNORDERED_SYMBOLS}" ] ; then
exit 1
fi
+LIBS=$(otool -L "${MACH_O_FILE}")
+if [ ${?} -ne 0 ] ; then
+ echo "${0}: failed to get libraries in ${MACH_O_FILE}" >& 2
+ exit 1
+fi
+if grep -Fq libstdc++ <<< ${LIBS} ; then
+ echo "${0}: ${MACH_O_FILE} depends on libstdc++" >& 2
+ exit 1
+fi
+if grep -Fq libc++ <<< ${LIBS} ; then
+ echo "${0}: ${MACH_O_FILE} depends on libc++" >& 2
+ exit 1
+fi
+
exit 0
« no previous file with comments | « chrome/chrome_dll.gypi ('k') | third_party/libc++-static/build.sh » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698