Closed 666tos closed 4 months ago
@666tos Nice work. Is there any way to get the arm64 slice for macOS as well? I don't see any way in the Configure for OpenSSL 1.0.2.x but perhaps I'm missing something?
@levigroker there is no ready-made configuration for it, since arm64 Macs did not exist at that time. But I believe it's doable. You can take a look at configure()
function in scripts/build.sh
where CFLAG and CFLAGS are set up.
I believe, it should look like this.
if [ "$OS" == "MacOSX" ]; then
if [ "$ARCH" == "x86_64" ]; then
${SRC_DIR}/Configure darwin64-x86_64-cc no-asm no-shared --prefix="${PREFIX}" &> "${PREFIX}.config.log"
else if [ "$ARCH" == "arm64" ]; then
${SRC_DIR}/Configure iphoneos-cross no-asm no-shared --prefix="${PREFIX}" &> "${PREFIX}.config.log"
fi
sed -ie "s!^CFLAG=!CFLAG=-mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET} -isysroot ${CROSS_TOP}/SDKs/${CROSS_SDK} -fembed-bitcode -arch $ARCH !" "${SRC_DIR}/Makefile"
sed -ie "s!^CFLAGS=!CFLAGS=-mmacosx-version-min=${MACOSX_DEPLOYMENT_TARGET} -isysroot ${CROSS_TOP}/SDKs/${CROSS_SDK} -fembed-bitcode -arch $ARCH !" "${SRC_DIR}/Makefile"
fi
And then in build_macos()
function
build "x86_64" "MacOSX" ${TMP_BUILD_DIR} "macosx"
build "arm64" "MacOSX" ${TMP_BUILD_DIR} "macosx"
I have no time to perform a check right now and my current laptop is ridiculously slow, so you have to try it yourself.
@666tos Many thanks! I was able to get it to work based on your suggestions and some other tweaks. Let me know if you are interested in a PR to your fork. Cheers!
when can we get this merged in seems its a fix that will resolve this issue
Closing as "wont fix". I don't plan to support 1.0.x anymore. Feel free to maintain forks for your purpose. See https://github.com/krzyzanowskim/OpenSSL/issues/110
Hi @krzyzanowskim, i did ask you regarding building 1.0.2.x with XCode 12 and this is a PR. It makes sense to keep it as separate branch since it's legacy version of OpenSSL. Included platforms: