The libcrypto symbols are conflicting when Python-iOS framework is used along with AmazonFling frameworks.
nandishyb opened this issue · 6 comments
Example warning :
ld: warning: duplicate symbol '_CRYPTO_memcmp' in:
/Users/nandishbellad/Development/TestYoutubeApp/TestPythonApp/AmazonFling.framework/AmazonFling(cryptlib.o)
/Users/nandishbellad/Library/Developer/Xcode/DerivedData/TestPythonApp-akquhzlstsszvfdavaajjevmysua/Build/Products/Debug-iphoneos/libcrypto.a(arm64cpuid.o)
Amazon Fling framework is using libcrypto internally and so we can just delete the the duplicate symbol in AmazonFling framework using lipo and ar commands. However , I think Amazon framework is using old openssl version code , so when removed some to the apis are not there in latest version of openssl that Python-iOS uses.
Can I get the Python-iOS framework with old version of openssl, probably 1.0.2?
As you can see from https://github.com/beeware/Python-Apple-support/blob/3.7/Makefile, Beeware build of Python 3.7 uses openssl 1.0.2. You should download the build and try.
Thank you very much for quick response . I checked the makefile of 3.7 but it is using openssl version 1.1.1j, however, the makefile of 3.6 indicates it is using openssl version 1.0.2u.
We are using swift package manager to use the Python-iOS framework. Do I have to build the Python-iOS framework manually? Can you let me know how to change the Python-iOS framework to use Python 3.6 ?
Also I see that " If you want to build XCFrameworks yourself, see https://github.com/kewlbear/kivy-ios " I tried to setup but when I try to running toolchain recipes it shows latest version :
(venv) N-MBP kivy_ios % python toolchain.py recipes
toolchain.py:94: DeprecationWarning: ChromeDownloader style of invoking requests is deprecated. Use newer urlopen functions/methods
urlretrieve = ChromeDownloader().retrieve
audiostream master
click 7.1.2
curly master
cymunk master
ffmpeg n4.3.1
ffpyplayer 4.2.0
flask 1.1.2
freetype 2.5.5
host_setuptools3 40.9.0
hostlibffi 3.2.1
hostopenssl 1.1.1g
hostpython3 3.8.2
ios master
itsdangerous 1.1.0
jinja2 2.11.2
kivent_core master
kivy b5ec51ed2315a9a890f264b0df6d23c8e6341d42
libcurl 7.65.3
libffi 3.2.1
libjpeg v9a
libpng 1.6.26
libzbar 0.10
markupsafe 1.1.1
netifaces 0.10.9
numpy 1.16.4
openssl 1.1.1g
photolibrary master
pillow 6.1.0
plyer master
pycrypto 2.6.1
pykka 1.2.1
pyobjus master
python3 3.8.2
pyyaml 3.11
sdl2 7cc4fc886d9e
sdl2_image 2.0.4
sdl2_mixer 2.0.4
sdl2_ttf 2.0.14
werkzeug 1.0.1
zbarlight 1.2
Even if I try to change the version of openssl in it's respective recipe init.py it is not updated.
Is it possible for you to create a branch for Python-iOS that uses python 3.6 and openssl 1.0.2u? Or is it too much to ask you :-) Thank you again.
Sorry for the wrong link to Python 3.7. Are you using the kivy branch? If not, please take a look at kewlbear/Python-Apple-support@eabee39. You can see how I used lipo and xcodebuild to convert static libraries to xcframeworks. You should do the same for Python 3.6. And modify Package.swift to use those binary targets.
Not a problem. Yes I am using the kivy branch. Can you show me how you used lipo and xcodebuild to convert static libraries to xcframeworks. Can you help me to build Python-iOS framework to use Python 3.6? It would be great if you can create a release tag for Python-iOS package that uses Python 3.6. Can this be done? If you have some time can we discuss in other platform like skype?
For Kivy-ios branch, this commit upgraded openssl to 1.1: kivy/kivy-ios@b47cddd. So you should check out a commit before it and build. Creating xcframeworks is basically using lipo to extract individual architectures from fat libraries and then running xcodebuild -create-xcframework -output a.xcframework -library arch1.a -library arch2.a ...