SDWebImage Error when creating Product Archive for Generic iOS Device - xcode9

I've installed SDWebImage into my Xcode project. The Pod works great, except now I'm ready to create a build of my project and start testing with others using testflight. When I choose Generic iOS Device and Product -> Archive from xcode, I get the following error:
...Frameworks/SDWebImage.framework: unknown error -1=ffffffffffffffff
Detailed output below. Any help would be much appreciated.
Xcode version: Version 9.3 (9E145)
SDWebImage bundle version: 4.2.3
PhaseScriptExecution [CP]\ Embed\ Pods\ Frameworks
/Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/IntermediateBuildFilesPath/folie.build/Release-iphoneos/folie.build/Script-D7995652A1B6FAEC372573DE.sh
cd /Users/tgwagner/Documents/folie/source/App/folie/folie
/bin/sh -c /Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/IntermediateBuildFilesPath/folie.build/Release-iphoneos/folie.build/Script-D7995652A1B6FAEC372573DE.sh
mkdir -p
/Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/BuildProductsPath/Release-iphoneos/folie.app/Frameworks
Symlinked... rsync --delete -av --filter P .*.?????? --filter "- CVS/"
--filter "- .svn/" --filter "- .git/" --filter "- .hg/" --filter "- Headers" --filter "- PrivateHeaders" --filter "- Modules"
"/Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/SDWebImage.framework"
"/Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/InstallationBuildProductsLocation/Applications//folie.app/Frameworks"
building file list ... done SDWebImage.framework/
SDWebImage.framework/Info.plist SDWebImage.framework/SDWebImage
sent 2547349 bytes received 70 bytes 5094838.00 bytes/sec total size
is 2546802 speedup is 1.00 Stripped
/Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/InstallationBuildProductsLocation/Applications//folie.app/Frameworks/SDWebImage.framework/SDWebImage
of architectures: armv7 Code Signing
/Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/InstallationBuildProductsLocation/Applications//folie.app/Frameworks/SDWebImage.framework
with Identity iPhone Developer: Todd Wagner (64J9F8EP32)
/usr/bin/codesign --force --sign
FA2493469780E25F17F630FF538B8DA75BD6486A
--preserve-metadata=identifier,entitlements '/Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/InstallationBuildProductsLocation/Applications//folie.app/Frameworks/SDWebImage.framework'
/Users/tgwagner/Library/Developer/Xcode/DerivedData/folie-damzcypivcyrbvfnlcuepubrafru/Build/Intermediates.noindex/ArchiveIntermediates/folie/InstallationBuildProductsLocation/Applications//folie.app/Frameworks/SDWebImage.framework:
unknown error -1=ffffffffffffffff Command /bin/sh failed with exit
code 1

In case anyone else runs into this. I had an old version of SDWebImage. I updated the pod as follows:
pod update SDWebImage
then restarted xcode -- still getting the same error. Eventually I had to restart computer and everything worked again.
Hope this helps someone else.

Related

python-ldap 3.4 installation fails on alpine images

When trying to install the latest python-ldap version 3.4 on an apline docker image (I use python:3.9-alpine as my base image) the build of python-ldap fails with:
...
/usr/lib/gcc/x86_64-alpine-linux-musl/10.3.1/../../../../x86_64-alpine-linux-musl/bin/ld: cannot find -lldap_r
collect2: error: ld returned 1 exit status
error: command '/usr/bin/gcc' failed with exit code
...
Installed dependencies:
apk add --no-cache --virtual .build-deps musl-dev gcc postgresql-dev openldap-dev libffi-dev
Also tried with build-base etc. without success.
Would highly appreciate any ideas :)
There are issues with the python-ldap package when linking against OpenLDAP 2.5+. The issues are acknowledged by the devs in https://github.com/python-ldap/python-ldap/issues/432 and https://github.com/python-ldap/python-ldap/issues/445.
Tested workaround is the one described in the first issue:
As a workaround create the file /usr/lib64/libldap_r.so with content
INPUT ( libldap.so ). The approach works on all systems that use a GNU
ld-compatible linker.
# cat > /usr/lib64/libldap_r.so << EOF
INPUT ( libldap.so )
EOF
You can also use it in a simpler way (in Dockerfiles, for example):
echo -n "INPUT ( libldap.so )" > /usr/lib/libldap_r.so

Nativescript ios build fails with Error 65

I've run into an issue where suddenly my ios build will no longer build. It seems to have happened out of no-where.
I get this error and can't seem to get rid of it regardless of what I try.
[19-01-15 10:57:43.888] Build failed. Command xcodebuild failed with exit code 65 Error output:
** ARCHIVE FAILED **
I've tried tns platform remove ios
I've updated my plugins.
I also get these cli warnings before it fails:
(CLI) 1) Target 'class2tns' has copy command from ...
and
(CLI) warning: duplicate output file
for a number of files.
My Android version builds ok.
I had the same exit code from Xcode (65) and the warning of duplicate output file.
After along time of research the following steps are required because an update of a nativescript npm package.
rm -Rf platform/ios
rm -Rf node_modules
rm package-lock.json
pod repo update # important to execute this command in the project dir
tns build ios

Continuous Integration Code Signing issue

I've been working on setting up a TeamCity continuous integration build agent for my iOS builds and I've run into a bit of a road block.
We're going to be making builds for different clients with different certificates and mobile provisioning profiles, so I figured I would write a build script that would create an unsigned archive, then sign it with the appropriate identity and mobileprovision. It seems like the xcrun command doesn't like that the .app file is not signed, and therefore won't sign it.
Am I doing something wrong, or is there some other, more elegant way of accomplishing what I'm trying to do?
Infodump follows...
I'm creating the unsigned build with the following command:
xcodebuild -workspace "[workspace].xcworkspace" -scheme "[scheme]" clean archive CODE_SIGN_ENTITY="" CODE_SIGNING_REQUIRED=NO
Then, I'm attempting to code sign and create the IPA with this command:
APP=[path to .app file in archive]
OUT_IPA=[desired location of .ipa]
IDENTITY=[CodeSigning Identity]
MOBILE_PROVISION=[path to .mobileprovision]
xcrun -sdk iphoneos PackageApplication -v "${APP}" -o "${OUT_IPA}" --sign "${IDENTITY}" --embed "${MOBILE_PROVISION}"
The xcrun command prints a bunch of debug info, then copies files around to temporary directories. Then it checks the original app
### Checking original app
+ /usr/bin/codesign --verify -vvvv /Users/jibanez/Library/Developer/Xcode/Archives/2012-09-14/[scheme] 9-14-12 12.02 PM.xcarchive/Products/Applications/[product].app
Program /usr/bin/codesign returned 1 : [/Users/jibanez/Library/Developer/Xcode/Archives/2012-09-14/[scheme] 9-14-12 12.02 PM.xcarchive/Products/Applications/[product].app: code object is not signed at all
In architecture: armv7
]
Codesign check fails : /Users/jibanez/Library/Developer/Xcode/Archives/2012-09-14/[scheme] 9-14-12 12.02 PM.xcarchive/Products/Applications/[product].app: code object is not signed at all
In architecture: armv7
Done checking the original app
This seems about right. After all, I didn't code sign the archive, that's what xcrun is supposed to do. Here's where things get weird:
### Embedding '/Users/jibanez/Documents/[projectdir]/codesign/[scheme]/842F2922-D0CB-46CE-81E5-B7362DD1D960.mobileprovision'
+ /bin/rm -rf /var/folders/hh/qhf8930s5hg8lwbp2j_zsdm822y1s1/T/NycIiYdEYe/Payload/[product].app/embedded.mobileprovision
Program /bin/rm returned 0 : []
+ /bin/cp -rp /Users/jibanez/Documents/[projectdir]/codesign/[scheme]/mobileProvision.mobileprovision /var/folders/hh/qhf8930s5hg8lwbp2j_zsdm822y1s1/T/NycIiYdEYe/Payload/[product].app/embedded.mobileprovision
Program /bin/cp returned 0 : []
+ /usr/bin/codesign -d --entitlements /var/folders/hh/qhf8930s5hg8lwbp2j_zsdm822y1s1/T/NycIiYdEYe/entitlements_rawwAdCadPV /var/folders/hh/qhf8930s5hg8lwbp2j_zsdm822y1s1/T/NycIiYdEYe/Payload/[product].app
Program /usr/bin/codesign returned 1 : [/var/folders/hh/qhf8930s5hg8lwbp2j_zsdm822y1s1/T/NycIiYdEYe/Payload/[product].app: code object is not signed at all
]
error: Failed to read entitlements from '/var/folders/hh/qhf8930s5hg8lwbp2j_zsdm822y1s1/T/NycIiYdEYe/Payload/[product].app'
Failed: PackageApplication

Building iOS app for iPhone works from xCode but not from command line (xcodebuild)

I am currently trying to streamline our build and release process with an automated build which runs on an OSX server machine , a MacMini running OSX 10.6.7 with xCode 4.0.1 and iOS SDK 4.3 installed (latest release from Apple).
I have followed Mike Nachbaur's excellent guide and it feels like I'm almost there but I still have one final obstacle to overcome.
So. We have our app which build fine on:
a) My laptop from within xCode
b) My laptop from command line with xcodebuild
c) the build machine from within xCode
BUT it does not work on
d) the build machine from the command line with xcodebuild.
Here is the end of the console output:
CreateUniversalBinary build/Distribution-iphoneos/CallControl.app/CallControl normal "armv6 armv7"
cd /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/Users/ainutveckling/Jenkins/tools/jdk6/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/usr/bin/lipo -create /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol/build/Callcontrol.build/Distribution-iphoneos/CallControl.build/Objects-normal/armv6/CallControl /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol/build/Callcontrol.build/Distribution-iphoneos/CallControl.build/Objects-normal/armv7/CallControl -output /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol/build/Distribution-iphoneos/CallControl.app/CallControl
GenerateDSYMFile build/Distribution-iphoneos/CallControl.app.dSYM build/Distribution-iphoneos/CallControl.app/CallControl
cd /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/Users/ainutveckling/Jenkins/tools/jdk6/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/usr/bin/dsymutil /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol/build/Distribution-iphoneos/CallControl.app/CallControl -o /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol/build/Distribution-iphoneos/CallControl.app.dSYM
ProcessProductPackaging "/Users/ainutveckling/Library/MobileDevice/Provisioning Profiles/F792F2E5-45DB-43C7-969C-6012C59BF778.mobileprovision" build/Distribution-iphoneos/CallControl.app/embedded.mobileprovision
cd /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/Users/ainutveckling/Jenkins/tools/jdk6/bin:/usr/bin:/bin:/usr/sbin:/sbin"
<com.apple.tools.product-pkg-utility> "/Users/ainutveckling/Library/MobileDevice/Provisioning Profiles/F792F2E5-45DB-43C7-969C-6012C59BF778.mobileprovision" -o /Users/ainutveckling/Jenkins/workspace/CallControl_iPhoneContiousBuild/Callcontrol/build/Distribution-iphoneos/CallControl.app/embedded.mobileprovision
** BUILD FAILED **
+ failed build
+ echo 'Failed: build'
Failed: build
+ exit 1
Notifying upstream projects of job completion
Finished: FAILURE
On my machine, it looks almost the same:
GenerateDSYMFile build/Distribution-iphoneos/CallControl.app.dSYM build/Distribution-iphoneos/CallControl.app/CallControl
cd /Users/anders/Utveckling/CallControl/iphone/totala_samtalslistan/Callcontrol
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin:/Users/anders/Utveckling/android-sdk-mac_x86/tools:/Users/anders/Utveckling/android-sdk-mac_x86/platform-tools:"
/Developer/usr/bin/dsymutil /Users/anders/Utveckling/CallControl/iphone/totala_samtalslistan/Callcontrol/build/Distribution-iphoneos/CallControl.app/CallControl -o /Users/anders/Utveckling/CallControl/iphone/totala_samtalslistan/Callcontrol/build/Distribution-iphoneos/CallControl.app.dSYM
ProcessProductPackaging "/Users/anders/Library/MobileDevice/Provisioning Profiles/F792F2E5-45DB-43C7-969C-6012C59BF778.mobileprovision" build/Distribution-iphoneos/CallControl.app/embedded.mobileprovision
cd /Users/anders/Utveckling/CallControl/iphone/totala_samtalslistan/Callcontrol
setenv PATH "/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/X11/bin:/Users/anders/Utveckling/android-sdk-mac_x86/tools:/Users/anders/Utveckling/android-sdk-mac_x86/platform-tools:"
<com.apple.tools.product-pkg-utility> "/Users/anders/Library/MobileDevice/Provisioning Profiles/F792F2E5-45DB-43C7-969C-6012C59BF778.mobileprovision" -o /Users/anders/Utveckling/CallControl/iphone/totala_samtalslistan/Callcontrol/build/Distribution-iphoneos/CallControl.app/embedded.mobileprovision
** BUILD SUCCEEDED **
But success...
It does not matter if I start the build directly from the command line on the build machine or if it is started by Hudson, same result.
The certificate pointed out above seems to be in place.
I'm almost ready to give up on this, so I would very much appreciate any help to shed some light upon the matter!
Best regards,
Anders
I encountered the exact error that you showed above on my build machine after updating to a new distribution certificate and provisioning profile. After the ProcessProductPackaging step, it would just display the ** BUILD FAILED ** message.
However, when running the build manually on the build machine, I encountered the KeyChain permission dialog. Hitting "Allow Always" fixed the problem.
That in addition to unlocking in the build script:
security unlock -p $PASSWORD
Add this line of code to your script:
security list-keychains -s $KEYCHAINFILE
This has fixed the issue for me.

XCode cannot create IPA

My application compiles OK, and verifies.
But each of the Organizer options Validate..., Share..., Submit... just fail silently.
I'm using XCode version 3.2.5
I found the Console application had some information:
30/12/10 13:51:27 Xcode[8458] Running /usr/bin/xcrun with (
"-sdk",
iphoneos,
PackageApplication,
"-v",
"/Users/xxxxxx/Library/Application Support/Developer/Shared/Archived Applications/C201D5C0-2AB4-494B-A560-806AE36EF9A7.apparchive/Xxxxxx.app",
"-o",
"/var/folders/52/528Jj01wGtKYzlqffjXrck+++TI/-Tmp-/0610AAC0-E549-4F07-9496-08EFD6DFCAC3-8458-0000F00C5DE14F9F/Xxxxxx.ipa",
"--sign",
"iPhone Distribution: Xxxxxx",
"--embed",
"/Users/xxxxxx/Library/MobileDevice/Provisioning Profiles/66403280-7962-4A73-92D1-8FF34F65866C.mobileprovision"
)
30/12/10 13:51:27 [0x0-0x439439].com.apple.Xcode[8458] sh: /Developer/usr/bin/xcodebuild: No such file or directory
30/12/10 13:51:27 [0x0-0x439439].com.apple.Xcode[8458] /Developer/usr/bin/xcodebuild fails with 32512 - Unknown error: 32512
After searching around for a while, it appears that my install was missing the directory /Developer/usr/bin/.
In a Terminal shell, I linked the latest XCode version directory:
ln -s /Developer/XCode_3.2.5/usr/ /Developer/usr
and it fixed the problem.
You should try to package your IPA file through command line, so you can have full log in it. Here is a post I wrote, check it out.
http://www.nanaimostudio.com/blog/2011/4/17/xcode-build-and-archive-sharing-problem-and-solution.html

Resources