Make sure libcrypto from brew is linked. In the resulting .app
This commit is contained in:
parent
3475000902
commit
5e66e81ab7
1
osx.sh
1
osx.sh
|
@ -3,6 +3,7 @@
|
||||||
# OS X Build script wrapper around the py2app script.
|
# OS X Build script wrapper around the py2app script.
|
||||||
# These build can only be generated on OS X.
|
# These build can only be generated on OS X.
|
||||||
# Requires all build dependencies for Bitmessage
|
# Requires all build dependencies for Bitmessage
|
||||||
|
# Especially important is openssl installed through brew
|
||||||
|
|
||||||
export ARCHFLAGS="-arch i386 -arch x86_64"
|
export ARCHFLAGS="-arch i386 -arch x86_64"
|
||||||
|
|
||||||
|
|
|
@ -21,8 +21,9 @@ if sys.platform == 'darwin':
|
||||||
setup_requires=['py2app'],
|
setup_requires=['py2app'],
|
||||||
app=[mainscript],
|
app=[mainscript],
|
||||||
options=dict(py2app=dict(argv_emulation=True,
|
options=dict(py2app=dict(argv_emulation=True,
|
||||||
includes = ['PyQt4.QtCore','PyQt4.QtGui', 'sip', 'sqlite'],
|
includes = ['PyQt4.QtCore','PyQt4.QtGui', 'sip'],
|
||||||
packages = ['bitmessageqt'],
|
packages = ['bitmessageqt'],
|
||||||
|
frameworks = ['/usr/local/opt/openssl/lib/libcrypto.dylib'],
|
||||||
iconfile='images/bitmessage.icns',
|
iconfile='images/bitmessage.icns',
|
||||||
resources=["images"])),
|
resources=["images"])),
|
||||||
)
|
)
|
||||||
|
@ -44,9 +45,17 @@ setup(
|
||||||
**extra_options
|
**extra_options
|
||||||
)
|
)
|
||||||
from distutils import dir_util
|
from distutils import dir_util
|
||||||
|
import glob
|
||||||
|
|
||||||
if sys.platform == 'darwin':
|
if sys.platform == 'darwin':
|
||||||
resource = "dist/" + name + ".app/Contents/Resources/"
|
resource = "dist/" + name + ".app/Contents/Resources/"
|
||||||
|
framework = "dist/" + name + ".app/Contents/Frameworks/"
|
||||||
|
|
||||||
|
# The pyElliptive module only works with hardcoded libcrypto paths so rename it so it can actually find it.
|
||||||
|
libs = glob.glob(framework + "libcrypto*.dylib")
|
||||||
|
for lib in libs:
|
||||||
|
os.rename(lib, framework + "libcrypto.dylib")
|
||||||
|
break
|
||||||
|
|
||||||
# Try to locate qt_menu
|
# Try to locate qt_menu
|
||||||
# Let's try the port version first!
|
# Let's try the port version first!
|
||||||
|
|
|
@ -417,6 +417,10 @@ except:
|
||||||
try:
|
try:
|
||||||
# try homebrew installation
|
# try homebrew installation
|
||||||
OpenSSL = _OpenSSL('/usr/local/opt/openssl/lib/libcrypto.dylib')
|
OpenSSL = _OpenSSL('/usr/local/opt/openssl/lib/libcrypto.dylib')
|
||||||
|
except:
|
||||||
|
try:
|
||||||
|
# Load it from an Bitmessage.app on OSX
|
||||||
|
OpenSSL = _OpenSSL('./../Frameworks/libcrypto.dylib')
|
||||||
except:
|
except:
|
||||||
try:
|
try:
|
||||||
from os import path
|
from os import path
|
||||||
|
|
Reference in New Issue
Block a user