I have updated my iOS scripts to build for all archs now using the latest fips-2.0.14 and openssl-1.1.0e.
Before I was using 1.0.2h I believe and fips-2.0.12 and didn't have armv7s support added. I needed to add it so I upgrade and adjusted my script accordingly https://gist.github.com/jostster/ebbc6925c668b632d8b185293080256c
This works great, however I now get an error when building my application in xcode.
Undefined symbols for architecture armv7:
"_FIPS_text_start", referenced from:
_FINGERPRINT_premain in fips_premain.o
"_FIPS_signature", referenced from:
_FINGERPRINT_premain in fips_premain.o
+[VTFipsInfo getEmbeddedFingerprint] in VTFipsInfo.o
"_FIPS_incore_fingerprint", referenced from:
_FINGERPRINT_premain in fips_premain.o
+[VTFipsInfo getExpectedFingerprint] in VTFipsInfo.o
ld: symbol(s) not found for architecture armv7
VTFipsInfo.o is my objective-c files that get if FIPS is enabled and gets the hashes to display to the end user. If I try this on our buildkite server it replaces armv7 with x86_64. However running lipo --info
on my libssl and libcrypt.a returns
Architectures in the fat file: libssl.a are: armv7 i386 armv7s x86_64 arm64
Architectures in the fat file: libcrypto.a are: armv7 i386 armv7s x86_64 arm64
My valid architectures in xcode are armv7, armv7s and armv64. Before I upgraded my openssl and added armv7s support, this wasn't an issue.
Any ideas how to fix this?
UPDATE 1
Using the script above to compile the libcrypto.a
and libssl.a
you can then use the fips-pi.tar.gz
sample application located at http://openssl.com/fips/2.0/platforms/ios/ to test. This encounters the same error.