Could not build Objective-C module '_SwiftUIKitOverlayShims' - swift4

In the Xcode8.3.3 project will not be a problem, but after upgrading to xcode9, the compiler has a problem!
Showing Recent Issues
CompileSwift normal arm64
/Users/leekexi/Documents/macsrc/mtom/modules/ScrollerRefresh/RefreshConst.swift
cd /Users/leekexi/Documents/macsrc/mtom
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift -frontend -c -filelist /var/folders/cz/jq8bwvds0j52yy2j0p7_2kf40000gn/T/sources-86be14 -primary-file /Users/leekexi/Documents/macsrc/mtom/modules/ScrollerRefresh/RefreshConst.swift -target arm64-apple-ios8.0 -Xllvm -aarch64-use-tbi -enable-objc-interop -sdk /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS11.0.sdk -I /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Products/Debug-iphoneos -F /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Products/Debug-iphoneos -F /Users/leekexi/Documents/macsrc/mtom/Pods/RongCloudIM/RongCloudIM -F /Users/leekexi/Documents/macsrc/mtom/modules -F /Users/leekexi/Documents/macsrc/mtom/modules/Live/IJKMediaPlayer -F /Users/leekexi/Documents/macsrc/mtom -enable-testing -g -module-cache-path /Users/leekexi/Library/Developer/Xcode/DerivedData/ModuleCache -swift-version 4 -enforce-exclusivity=checked -D DEBUG -serialize-debugging-options -Xcc -I/Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/swift-overrides.hmap -Xcc -iquote -Xcc /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/mtom-generated-files.hmap -Xcc -I/Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/mtom-own-target-headers.hmap -Xcc -I/Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/mtom-all-target-headers.hmap -Xcc -iquote -Xcc /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/mtom-project-headers.hmap -Xcc -I/Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Products/Debug-iphoneos/include -Xcc -I/Users/leekexi/Documents/macsrc/mtom/Pods/Headers/Public -Xcc -I/Users/leekexi/Documents/macsrc/mtom/Pods/Headers/Public/RongCloudIM -Xcc -I/Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/DerivedSources/arm64 -Xcc -I/Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/DerivedSources -Xcc -DDEBUG=1 -Xcc -DCOCOAPODS=1 -Xcc -working-directory/Users/leekexi/Documents/macsrc/mtom -emit-module-doc-path /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/Objects-normal/arm64/RefreshConst~partial.swiftdoc -serialize-diagnostics-path /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/Objects-normal/arm64/RefreshConst.dia -import-objc-header /Users/leekexi/Documents/macsrc/mtom/mtom-bridging.h -pch-output-dir /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/PrecompiledHeaders -pch-disable-validation -Onone -module-name mtom -emit-module-path /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/Objects-normal/arm64/RefreshConst~partial.swiftmodule -emit-dependencies-path /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/Objects-normal/arm64/RefreshConst.d -emit-reference-dependencies-path /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/Objects-normal/arm64/RefreshConst.swiftdeps -o /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Build/Intermediates.noindex/mtom.build/Debug-iphoneos/mtom.build/Objects-normal/arm64/RefreshConst.o -index-store-path /Users/leekexi/Library/Developer/Xcode/DerivedData/mtom-aecafhlecijtaebzvztitxjcabvr/Index/DataStore -index-system-modules
<module-includes>:1:9: note: in file included from <module-includes>:1:
#import "UIKitOverlayShims.h"
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/shims/UIKitOverlayShims.h:24:11: error: use of undeclared identifier 'UIFocusSystem'
return [UIFocusSystem environment:environment containsEnvironment:otherEnvironment];
^
<unknown>:0: error: could not build Objective-C module '_SwiftUIKitOverlayShims'

This fix from the mentioned forum thread fixed it for me: Just delete the offending code!
Open the file the error points to (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/shims/UIKitOverlayShims.h for most people).
Delete the method _swift_UIKit_UIFocusEnvironmentContainsEnvironment, plus the surrounding compiler directives.
I rebuilt after that just to be sure, but that might not be necessary.
This is definitely a workaround; hopefully this will be fixed in a future version of Xcode.

For me on Xcode 9.0.1 the solution has been the typical engineer solution:
Clean the project
Erase DerivedData
Reboot computer

Related

Swift compiler error at the time of compiling

Trying to compile a .swift file using the swift compiler in Ubuntu 19.10 but facing this error at the time of compilation.
$ swiftc swift.swift
/usr/bin/ld.gold: fatal error: swift: open: Is a directory
clang-7: error: linker command failed with exit code 1 (use -v to see invocation)
<unknown>:0: error: link command failed with exit code 1 (use -v to see invocation)
I have also tried it with -v parameter and it shows this:
$ swiftc -v swift.swift
Swift version 5.1 (swift-5.1.2-RELEASE)
Target: x86_64-unknown-linux-gnu
/home/takshaksh/swift/usr/bin/swift -frontend -c -primary-file swift.swift -target x86_64-unknown-linux-gnu -disable-objc-interop -color-diagnostics -module-name swift -o /tmp/swift-2339bd.o
/home/takshaksh/swift/usr/bin/swift-autolink-extract /tmp/swift-2339bd.o -o /tmp/swift-0db3ba.autolink
/home/takshaksh/swift/usr/bin/clang++ -fuse-ld=gold -pie -target x86_64-unknown-linux-gnu -Xlinker -rpath -Xlinker /home/takshaksh/swift/usr/lib/swift/linux /home/takshaksh/swift/usr/lib/swift/linux/x86_64/swiftrt.o /tmp/swift-2339bd.o #/tmp/swift-0db3ba.autolink -L /home/takshaksh/swift/usr/lib/swift/linux -lswiftCore --target=x86_64-unknown-linux-gnu -v -o swift
clang version 7.0.0
Target: x86_64-unknown-linux-gnu
Thread model: posix
InstalledDir: /home/takshaksh/swift/usr/bin
Found candidate GCC installation: /usr/lib/gcc/i686-linux-gnu/9
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/7
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/7.4.0
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/8
Found candidate GCC installation: /usr/lib/gcc/x86_64-linux-gnu/9
Selected GCC installation: /usr/lib/gcc/x86_64-linux-gnu/9
Candidate multilib: .;#m64
Selected multilib: .;#m64
"/usr/bin/ld.gold" -pie --eh-frame-hdr -m elf_x86_64 -dynamic-linker /lib64/ld-linux-x86-64.so.2 -o swift /usr/lib/gcc/x86_64-linux-gnu/9/../../../x86_64-linux-gnu/Scrt1.o /usr/lib/gcc/x86_64-linux-gnu/9/../../../x86_64-linux-gnu/crti.o /usr/lib/gcc/x86_64-linux-gnu/9/crtbeginS.o -L/home/takshaksh/swift/usr/lib/swift/linux -L/usr/lib/gcc/x86_64-linux-gnu/9 -L/usr/lib/gcc/x86_64-linux-gnu/9/../../../x86_64-linux-gnu -L/lib/x86_64-linux-gnu -L/lib/../lib64 -L/usr/lib/x86_64-linux-gnu -L/usr/lib/gcc/x86_64-linux-gnu/9/../../.. -L/home/takshaksh/swift/usr/bin/../lib -L/lib -L/usr/lib -rpath /home/takshaksh/swift/usr/lib/swift/linux /home/takshaksh/swift/usr/lib/swift/linux/x86_64/swiftrt.o /tmp/swift-2339bd.o -lswiftSwiftOnoneSupport -lswiftCore -lswiftCore -lstdc++ -lm -lgcc_s -lgcc -lc -lgcc_s -lgcc /usr/lib/gcc/x86_64-linux-gnu/9/crtendS.o /usr/lib/gcc/x86_64-linux-gnu/9/../../../x86_64-linux-gnu/crtn.o
/usr/bin/ld.gold: fatal error: swift: open: Is a directory
clang-7: error: linker command failed with exit code 1 (use -v to see invocation)
:0: error: link command failed with exit code 1 (use -v to see invocation)

Realm for Swift 3.1 - Command failed due to signal: Illegal instruction: 4

After updating Swift to v3.1, I got Realm frameworks replaced by the new version downloaded from Realm Swift 2.5.1 but get the following issue:
Command failed due to signal: Illegal instruction: 4
Already checked this and this, but they didn't work.
Here is the error description, not sure if it's helpful though.
CompileSwift normal x86_64
/Users/linhcn/Documents/XcodeProjects/HerdManager/HerdManager/Models/ActionCategory.swift
-target x86_64-apple-ios9.3 -enable-objc-interop -sdk /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator10.3.sdk
-I /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Products/Debug-iphonesimulator
-F /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Products/Debug-iphonesimulator
-F /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Products/Debug-iphonesimulator/FileBrowser
-F /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Products/Debug-iphonesimulator/Realm
-F /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Products/Debug-iphonesimulator/RealmSwift
-F /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Products/Debug-iphonesimulator/Toast-Swift
-F /Users/linhcn/Documents/XcodeProjects/HerdManager/HerdManager/Frameworks
-enable-testing -g -module-cache-path /Users/linhcn/Library/Developer/Xcode/DerivedData/ModuleCache -D DEBUG
-D COCOAPODS -serialize-debugging-options -Xcc -I/Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/swift-overrides.hmap
-Xcc -iquote -Xcc /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/HerdManager-generated-files.hmap
-Xcc -I/Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/HerdManager-own-target-headers.hmap -Xcc -I/Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/HerdManager-all-non-framework-target-headers.hmap
-Xcc -ivfsoverlay -Xcc /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/all-product-headers.yaml
-Xcc -iquote -Xcc /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/HerdManager-project-headers.hmap
-Xcc -I/Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Products/Debug-iphonesimulator/include
-Xcc -I/Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/DerivedSources/x86_64
-Xcc -I/Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/DerivedSources
-Xcc -DDEBUG=1 -Xcc -DCOCOAPODS=1 -Xcc -working-directory/Users/linhcn/Documents/XcodeProjects/HerdManager -emit-module-doc-path /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/Objects-normal/x86_64/Invoice~partial.swiftdoc
-serialize-diagnostics-path /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/Objects-normal/x86_64/Invoice.dia
-Onone -module-name HerdManager -emit-module-path /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/Objects-normal/x86_64/Invoice~partial.swiftmodule
-emit-dependencies-path /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/Objects-normal/x86_64/Invoice.d
-emit-reference-dependencies-path /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/Objects-normal/x86_64/Invoice.swiftdeps
-o /Users/linhcn/Library/Developer/Xcode/DerivedData/HerdManager-exytfaymknfhzqabpximiccdzmaa/Build/Intermediates/HerdManager.build/Debug-iphonesimulator/HerdManager.build/Objects-normal/x86_64/Invoice.o
Problem solved.
I guess that it's a problem of the new Xcode's (8.3.2) error report system. Apple may add some new coding rules but not update the error reporter. I ended up commenting out all the code and uncommenting each part to figure out where the problem is. It reports errors in some classes but the actual problem is in another class.

Xcode Swift compile error import name too long

This is the error I'm getting from trying to build my project.
Opening import file for module 'Swift': File name too long
This is the swift compile command being run:
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift -frontend -c -filelist /var/folders/b7/c8z8dq8n6y5b1x29mx_p209w0000gn/T/sources-adfc78 -primary-file "/Users/james/Documents/workspace/fb-ios-recover/FitBugg/Model/Mock model/MockUser.swift" -target x86_64-apple-ios8.0 -enable-objc-interop -sdk /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator9.3.sdk -I /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator -F /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator -F " \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/AFNetworking\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/Bolts\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/Bolts-Swift\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/FBSDKCoreKit\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/FBSDKLoginKit\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/FBSDKShareKit\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/HexColors\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/JSQMessagesViewController\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/JSQSystemSoundPlayer\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/JTCalendar\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/MBProgressHUD\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/NMRangeSlider\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/Parse\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/ParseCrashReporting\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/ParseFacebookUtilsV4\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/ParseLiveQuery\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/ParseUI\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/SocketRocket\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/THContactPicker\" \"/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/TSMessages\" \"/Users/james/Documents/workspace/fb-ios-recover/Pods/GoogleMaps/Frameworks\"" -enable-testing -g -import-objc-header /Users/james/Documents/workspace/fb-ios-recover/FitBugg-Bridging-Header.h -module-cache-path /Users/james/Library/Developer/Xcode/DerivedData/ModuleCache -D DEBUG -serialize-debugging-options -Xcc -I/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/swift-overrides.hmap -Xcc -iquote -Xcc /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/FitBugg-generated-files.hmap -Xcc -I/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/FitBugg-own-target-headers.hmap -Xcc -I/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/FitBugg-all-non-framework-target-headers.hmap -Xcc -ivfsoverlay -Xcc /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/all-product-headers.yaml -Xcc -iquote -Xcc /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/FitBugg-project-headers.hmap -Xcc -I/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Products/Debug-iphonesimulator/include -Xcc "-I \"/Users/james/Documents/workspace/fb-ios-recover/Pods/Headers/Public\" \"/Users/james/Documents/workspace/fb-ios-recover/Pods/Headers/Public/GoogleMaps\"" -Xcc -I/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/DerivedSources/x86_64 -Xcc -I/Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/DerivedSources -Xcc -DDEBUG=1 -Xcc -DCOCOAPODS=1 -Xcc -DCOCOAPODS=1 -Xcc -working-directory/Users/james/Documents/workspace/fb-ios-recover -emit-module-doc-path /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/Objects-normal/x86_64/MockUser~partial.swiftdoc -Onone -module-name FitBugg -emit-module-path /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/Objects-normal/x86_64/MockUser~partial.swiftmodule -serialize-diagnostics-path /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/Objects-normal/x86_64/MockUser.dia -emit-dependencies-path /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/Objects-normal/x86_64/MockUser.d -emit-reference-dependencies-path /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/Objects-normal/x86_64/MockUser.swiftdeps -o /Users/james/Library/Developer/Xcode/DerivedData/FitBugg-gzpxgbmtwqvbozdkgabiahuiovrr/Build/Intermediates/FitBugg.build/Debug-iphonesimulator/FitBugg.build/Objects-normal/x86_64/MockUser.o
By looking at your logs I found strange all the \" after the -F option.
Could it be possible that in your build settings the Framework search Paths is set to "$(inherited)" instead of just $(inherited) (no surrounding "")?

Apple LLVM compiler 3.1 error - iOS 5; Xcode 4.3

I have been receiving this error for a long time and I don't know what to do.
In order to keep the question short, I have written the error into a .rtf file and put it into CloudApp. Here's the link: http://cl.ly/0T3n1Q123u352T372t0m
I think it has something to do with "CLAPIDeserializer.m".
I will appreciate any help. Thank you.
ERROR:
CompileC
/Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/Objects-normal/armv7/CLAPIDeserializer.o
"Cloud/API Parsing/CLAPIDeserializer.m" normal armv7 objective-c
com.apple.compilers.llvm.clang.1_0.compiler
cd "/Users/juniorpond/Documents/Dropbox/Triple J Studios/Applications/Applications/CloudSend/Test/Test"
setenv LANG en_US.US-ASCII
setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
-x objective-c -arch armv7 -fmessage-length=0 -std=gnu99 -Wno-trigraphs -fpascal-strings -O0 -Wno-missing-field-initializers -Wno-missing-prototypes -Wreturn-type -Wno-implicit-atomic-properties -Wformat -Wno-missing-braces -Wparentheses -Wswitch -Wno-unused-function -Wno-unused-label -Wno-unused-parameter -Wunused-variable -Wunused-value -Wuninitialized -Wno-unknown-pragmas -Wno-shadow -Wno-four-char-constants -Wno-sign-compare -Wno-shorten-64-to-32 -Wpointer-sign -Wno-newline-eof -Wno-selector -Wno-strict-selector-match -Wno-undeclared-selector -Wno-deprecated-implementations -DDEBUG=1 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk
-Wprotocol -Wdeprecated-declarations -g -Wno-conversion -Wno-sign-conversion -mthumb "-DIBOutlet=attribute((iboutlet))" "-DIBOutletCollection(ClassName)=attribute((iboutletcollection(ClassName)))"
"-DIBAction=void)attribute((ibaction)" -miphoneos-version-min=5.1
-iquote /Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/Test-generated-files.hmap
-I/Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/Test-own-target-headers.hmap
-I/Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/Test-all-target-headers.hmap
-iquote /Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/Test-project-headers.hmap
-I/Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Products/Debug-iphoneos/include
-I/Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/DerivedSources/armv7
-I/Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/DerivedSources
-F/Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Products/Debug-iphoneos
-include /Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/PrecompiledHeaders/Test-Prefix-clsydhfesjzmtrbgszvgmeofhzfq/Test-Prefix.pch
-MMD -MT dependencies -MF /Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/Objects-normal/armv7/CLAPIDeserializer.d
--serialize-diagnostics /Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/Objects-normal/armv7/CLAPIDeserializer.dia
-c "/Users/juniorpond/Documents/Dropbox/Triple J Studios/Applications/Applications/CloudSend/Test/Test/Cloud/API
Parsing/CLAPIDeserializer.m" -o
/Users/juniorpond/Library/Developer/Xcode/DerivedData/Test-fqacaiejputxwicubwhguzleizde/Build/Intermediates/Test.build/Debug-iphoneos/Test.build/Objects-normal/armv7/CLAPIDeserializer.o
clang: error: unable to execute command: posix_spawn failed: Resource
temporarily unavailable clang: error: clang frontend command failed
due to signal 1 (use -v to see invocation) clang: note: diagnostic
msg: Please submit a bug report to
http://developer.apple.com/bugreporter/ and include command line
arguments and all diagnostic information. clang: error: unable to
execute command: posix_spawn failed: Resource temporarily unavailable
clang: note: diagnostic msg: Error generating preprocessed source(s).
Command
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang
failed with exit code 255
When this happens, close xcode and issue the "purge" command in Terminal then restart xcode. That solved this error for me.
It means your OS X kernel cannot spawn any more processes for your user ID. There is a maximum number of processes per user:
To see your process limitation:
sysctl kern.maxprocperuid
To check how many processes you have running:
ps aux | grep username | wc -l
To see how many zombie process:
ps -v -u username | grep -v grep | awk '{print $2}' | grep Z | wc -l
To see what they are:
for pid in `ps -v -u username | grep -v grep | awk '{print $1, $2}' | grep Z | awk '{print $1}'`
do
ps -o command="" -p $pid >> zombies.txt
done
None of these processes can be killed, and purge won't work on my mac, 10.8.2.
You could temporarily increase the max user processes count:
sudo sysctl -w kern.maxprocperuid=1024
Then in your .bash_profile or .bashrc add:
ulimit -u 1024
And change Finder’s limits:
sudo launchctl limit maxproc 1024
But really, it's time for coffee and give your mac a reboot..
I had this same problem with a project that I have under GIT with some of my team, the problem was that some of my team forgot to commit some new added files.
So, the .xcodeproj project it self was taking into consideration that it has some ViewControllers, but they weren't physically exist.
As soon as I added the missing view controllers, the project got built properly.
Hope this can help your situation.
just do it!!
1.Turn off your mac computer.
2.Turn on mac computer.
3.Run XCode
I had to do a clean to fix this. product>clean from xcode. rebooting & purging didn't help, cleaning fixed it.
The message says
clang frontend command failed due to signal 1 (use -v to see
invocation)
Try adding a "-v" to your "Other C Flags" under Build Settings of your project and see what it spits out...

Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/clang failed with exit code 1 in iPhone

I am trying to integrate Facebook into my application. When copying the FBconnect file into my application and running it, my application shows the above error. If I remove FBconnet file, the application is fine without errors. What is the problem?
Error Displayed above that is:
ProcessPCH /Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/PrecompiledHeaders/fExample2-Prefix-dgpfiszavygwrjgnbbtfhrwetzpp/fExample2-Prefix.pch.pth fExample2/fExample2-Prefix.pch normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
cd /Users/patrontechnosoft/Desktop/fExample2
setenv LANG en_US.US-ASCII
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/clang -x objective-c-header -arch i386 -fmessage-length=0 -fdiagnostics-print-source-range-info -fdiagnostics-show-category=id -fdiagnostics-parseable-fixits -std=gnu99 -fobjc-arc -Wno-trigraphs -fpascal-strings -O0 -Wmissing-prototypes -Wreturn-type -Wparentheses -Wswitch -Wno-unused-parameter -Wunused-variable -Wunused-value -Wno-shorten-64-to-32 -DDEBUG=1 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.0.sdk -fexceptions -fasm-blocks -mmacosx-version-min=10.6 -gdwarf-2 -Wno-sign-conversion -fobjc-abi-version=2 -fobjc-legacy-dispatch "-DIBOutlet=__attribute__((iboutlet))" "-DIBOutletCollection(ClassName)=__attribute__((iboutletcollection(ClassName)))" "-DIBAction=void)__attribute__((ibaction)" -D__IPHONE_OS_VERSION_MIN_REQUIRED=30200 -iquote /Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/Intermediates/fExample2.build/Debug-iphonesimulator/fExample2.build/fExample2-generated-files.hmap -I/Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/Intermediates/fExample2.build/Debug-iphonesimulator/fExample2.build/fExample2-own-target-headers.hmap -I/Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/Intermediates/fExample2.build/Debug-iphonesimulator/fExample2.build/fExample2-all-target-headers.hmap -iquote /Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/Intermediates/fExample2.build/Debug-iphonesimulator/fExample2.build/fExample2-project-headers.hmap -I/Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/Products/Debug-iphonesimulator/include -I/Users/patrontechnosoft/Desktop/New -IGMAT -I- -IPractice/facebook-iphone-sdk/src -I/Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/Intermediates/fExample2.build/Debug-iphonesimulator/fExample2.build/DerivedSources/i386 -I/Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/Intermediates/fExample2.build/Debug-iphonesimulator/fExample2.build/DerivedSources -F/Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/Products/Debug-iphonesimulator -c /Users/patrontechnosoft/Desktop/fExample2/fExample2/fExample2-Prefix.pch -o /Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/PrecompiledHeaders/fExample2-Prefix-dgpfiszavygwrjgnbbtfhrwetzpp/fExample2-Prefix.pch.pth -MMD -MT dependencies -MF /Users/patrontechnosoft/Library/Developer/Xcode/DerivedData/fExample2-hazidfxqkfibktcxoeovnngtzsxo/Build/PrecompiledHeaders/fExample2-Prefix-dgpfiszavygwrjgnbbtfhrwetzpp/fExample2-Prefix.pch.d
clang: error: '-I-' not supported, please use -iquote instead
Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/clang failed with exit code 1