Skip to content
Snippets Groups Projects
Commit f9142cad authored by Joe Garcia's avatar Joe Garcia
Browse files

Merge branch 'base_2021Q3' of gitlab.ssec.wisc.edu:rayg/ShellB3 into base_2021Q3

parents d01cf4cc 10f53bb6
Branches base_2021Q3
No related tags found
No related merge requests found
Showing
with 276 additions and 91 deletions
......@@ -13,6 +13,8 @@ ShellB3/qml
ShellB3/translations
ShellB3/phrasebooks
ShellB3/qtvirtualkeyboard
ShellB3/metatypes
ShellB3/cmake
ShellB3/plugins
ShellB3/bin
ShellB3/modules
......
......@@ -776,13 +776,15 @@ def matchSSL(path):
otool = sp.Popen(['otool','-L', path], stdout=sp.PIPE, stderr=None)
out, err = otool.communicate()
out=out.decode('utf8')
return '@rpath/OpenSSL.framework/Versions/3/lib/libssl.3.dylib' in out or \
'@rpath/OpenSSL.framework/Versions/3/lib/libcrypto.3.dylib' in out
return '/OpenSSL.framework/Versions/3/lib/libssl.3.dylib' in out or \
'/OpenSSL.framework/Versions/3/lib/libcrypto.3.dylib' in out
def fixSSL(path):
print(f"FOUND SSL-linked object {path}")
ssllinkfixes={'@rpath/OpenSSL.framework/Versions/3/lib/libssl.3.dylib':'@rpath/lib/libssl.3.dylib',
'@rpath/OpenSSL.framework/Versions/3/lib/libcrypto.3.dylib':'@rpath/lib/libcrypto.3.dylib'}
'@rpath/OpenSSL.framework/Versions/3/lib/libcrypto.3.dylib':'@rpath/lib/libcrypto.3.dylib',
'/Volumes/ShellB3-OpenSSL/Library/Frameworks/OpenSSL.framework/Versions/3/lib/libssl.3.dylib':'@rpath/lib/libssl.3.dylib',
'/Volumes/ShellB3-OpenSSL/Library/Frameworks/OpenSSL.framework/Versions/3/lib/libcrypto.3.dylib':'@rpath/lib/libcrypto.3.dylib'}
sslrpathfixes={"@loader_path/../../../../../..":"@loader_path/../../../../../../OpenSSL.framework/Versions/3",
"/Volumes/ShellB3-OpenSSL/Library/Frameworks":"/Volumes/ShellB3-OpenSSL/Library/Frameworks/OpenSSL.framework/Versions/3",
"/Library/Application Support/ShellB3/Frameworks":"/Library/Application Support/ShellB3/Frameworks/OpenSSL.framework/Versions/3"}
......@@ -793,6 +795,8 @@ def fixSSL(path):
for k,v in sslrpathfixes.items():
intool = sp.Popen(['install_name_tool', "-rpath",k,v,path], stdout=sp.PIPE, stderr=None)
out, err = intool.communicate()
intool = sp.Popen(['install_name_tool', "-add_rpath",v,path], stdout=sp.PIPE, stderr=None)
out, err = intool.communicate()
for k in sslrpathadditions:
intool = sp.Popen(['install_name_tool', "-add_rpath",k,path], stdout=sp.PIPE, stderr=None)
out, err = intool.communicate()
......@@ -1035,8 +1039,12 @@ python3 duolipo.py x86_64 /somewhere/ShellB3-x86path/ arm64 /somewhere/ShellB3-a
timeit.benchmark("Copied First Base")
tryMergePaths(platform2,base2,platform1,newbase,skip=skipLameFiles,branchedFiles=branchedFiles,secondPassQueue=secondPassQueue,isSecondPass=False,signidentity=options.signidentity,notarize=options.notarize)
timeit.benchmark("Merged Second Base")
if options.sslmacports and 'OpenSSL' not in newbase:
runOnEach(recurse(newbase,files=True,callablematch=ismacho),matchSSL,fixSSL)
if options.sslmacports:
if 'OpenSSL' in newbase:
print("Skipping SSL repath for macports with ssl distribution")
else:
print("SSL repath for macports")
runOnEach(recurse(newbase,files=True,callablematch=ismacho),matchSSL,fixSSL)
if not options.disablesign:
print("signing files")
signMacho(recurse(newbase,files=True,callablematch=ismacho),identity=options.signidentity,runtime=options.runtime,dryrun=options.dry_run)
......
This diff is collapsed.
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
No preview for this file type
File deleted
File added
File deleted
File added
File added
No preview for this file type
File deleted
File added
File deleted
File added
File added
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment