chore(windows installer): adapt script from sqool_manager to external lib
This commit is contained in:
parent
d4675ed160
commit
e69ef58485
@ -4,12 +4,13 @@ import os
|
|||||||
import argparse
|
import argparse
|
||||||
import shutil
|
import shutil
|
||||||
import string
|
import string
|
||||||
|
import sys
|
||||||
|
|
||||||
|
|
||||||
# parse args
|
# parse args
|
||||||
parser = argparse.ArgumentParser()
|
parser = argparse.ArgumentParser()
|
||||||
parser.add_argument('src', help='google_breakpad root directory where build was done')
|
parser.add_argument('src', help='google_breakpad root directory where build was done')
|
||||||
parser.add_argument('dst', help='sqool_manager root directory where google_breakpad have to be installed')
|
parser.add_argument('dst', help='destination root directory where google_breakpad have to be installed')
|
||||||
|
|
||||||
args = parser.parse_args()
|
args = parser.parse_args()
|
||||||
|
|
||||||
@ -25,14 +26,14 @@ if not os.path.isdir(args.dst):
|
|||||||
|
|
||||||
|
|
||||||
# customize args
|
# customize args
|
||||||
google_breakpad_src_dir = os.path.join( args.src, 'src')
|
google_breakpad_src_dir = os.path.join( args.src, 'src' )
|
||||||
sqool_manager_3rdparties_dir = os.path.join( args.dst, '3rdParties', 'windows')
|
dst_dir = os.path.join( args.dst )
|
||||||
|
|
||||||
|
|
||||||
# function to define src and dst in copy function
|
# function to define src and dst in copy function
|
||||||
def convertSrcAndDst( srcFile, dstFile, subDir ):
|
def convertSrcAndDst( srcFile, dstFile, subDir ):
|
||||||
src = os.path.join(google_breakpad_src_dir, srcFile.replace('/', os.path.sep))
|
src = os.path.join(google_breakpad_src_dir, srcFile.replace('/', os.path.sep))
|
||||||
dst = os.path.join(sqool_manager_3rdparties_dir, subDir, dstFile.replace('/', os.path.sep))
|
dst = os.path.join(dst_dir, subDir, dstFile.replace('/', os.path.sep))
|
||||||
return src, dst
|
return src, dst
|
||||||
|
|
||||||
|
|
||||||
@ -105,9 +106,11 @@ build_type = [
|
|||||||
# copy libraries
|
# copy libraries
|
||||||
for bt in build_type:
|
for bt in build_type:
|
||||||
for f in google_breakpad_library_files:
|
for f in google_breakpad_library_files:
|
||||||
file = os.path.join(google_breakpad_library_dir_base, bt, 'lib', f)
|
bt_lib_dir = os.path.join(google_breakpad_library_dir_base, bt)
|
||||||
src, dst = convertSrcAndDst(file, os.path.basename(file), os.path.join('lib', bt))
|
if os.path.exists(bt_lib_dir):
|
||||||
copyFile(src, dst)
|
file = os.path.join(bt_lib_dir, 'lib', f)
|
||||||
|
src, dst = convertSrcAndDst(file, os.path.basename(file), os.path.join('lib', bt))
|
||||||
|
copyFile(src, dst)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -121,8 +124,3 @@ for f in google_breakpad_binary_files:
|
|||||||
copyFile(src, dst)
|
copyFile(src, dst)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# copy binaries
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user