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

Unified Diff: tools/create_sdk.py

Issue 2646853005: Fuchsia: Copy libraries to SDK bin directory (Closed)
Patch Set: . Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « BUILD.gn ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/create_sdk.py
diff --git a/tools/create_sdk.py b/tools/create_sdk.py
index 160844c25884f1fcbad91ab41c963850801116a1..f461d3b9b5f5340a796f655448ece8a8ac8683f8 100755
--- a/tools/create_sdk.py
+++ b/tools/create_sdk.py
@@ -93,6 +93,9 @@ def GetOptions():
help='Where to output the sdk')
options.add_option("--snapshot_location",
help='Location of the snapshots.')
+ options.add_option("--copy_libs",
+ action="store_true", default=False,
+ help='Copy dynamically linked libraries to the SDK bin directory.')
return options.parse_args()
@@ -131,6 +134,20 @@ def CopyShellScript(src_file, dest_dir):
Copy(src, dest)
+def CopyLibs(out_dir, bin_dir):
+ for library in ['libcrypto', 'libssl']:
+ ext = '.so'
+ if HOST_OS == 'macos':
+ ext = '.dylib'
+ elif HOST_OS == 'win32':
+ ext = '.dll'
+ src = os.path.join(out_dir, library + ext)
+ dst = os.path.join(bin_dir, library + ext)
+ if os.path.isfile(src):
+ copyfile(src, dst)
+ copymode(src, dst)
+
+
def CopyDartScripts(home, sdk_root):
for executable in ['dart2js_sdk', 'dartanalyzer_sdk', 'dartfmt_sdk',
'pub_sdk', 'dartdoc', 'dartdevc_sdk']:
@@ -313,6 +330,9 @@ def Main():
CopyAnalysisSummaries(SNAPSHOT, LIB)
CopyDevCompilerSdk(HOME, LIB)
+ if options.copy_libs:
+ CopyLibs(build_dir, BIN)
+
# Write the 'version' file
version = utils.GetVersion()
versionFile = open(os.path.join(SDK_tmp, 'version'), 'w')
« no previous file with comments | « BUILD.gn ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698