ZXingObjC iOS archive issue: 'ZXingObjC/ZXingObjC.h' file not found Edit - ios

I followed the instructions in the readme file and it worked fine when I ran it as debug config on simulator or device, but when I archived I got this error:
'ZXingObjC/ZXingObjC.h' file not found
I tried to set header search path in build settings as something like ./libs/ZXingObjC-8f83c0b and then got the error
libs/ZXingObjC-8f83c0b/ZXingObjC/ZXingObjC.h:20:9: 'ZXingObjC/ZXAztecDecoder.h' file not found
any idea how to fix it? thanks

add in Header Search Paths
$(SRCROOT)/../..
recursive

I figured it out.
- add "$(BUILD_ROOT)/../IntermediateBuildFilesPath/UninstalledProducts" to header search path
- go to ZXingObjC project's build settings, change public header folder path from $(PROJECT_NAME)Headers to $(PROJECT_NAME)

Related

How to resolve "PCH file not found" error coming in the code?

I just cloned a github code.
When i tried to run it , it gave me no bridging header available isse, which i resolved by changing the folder name in "Build settings" .
After that when i tried to build i am getting this issue as
"<unknown>:0: error: PCH file '/Users/iosdeveloper/Library/Developer/Xcode/DerivedData/Project-ebqolwjodqhfifemlvpiqcmkwmtt/Build/Intermediates.noindex/PrecompiledHeaders/Project_1CZ4Z98EHTKKG-clang_1PO86BEGEY3JE.pch' not found: module file not found
<unknown>:0: error: clang importer creation failed
"
Please help me on this.
In my case I've not included .h extension at the end of App-Bridging-Header in Build Settings. After given App-Bridging-Header.h the error gone. Hope it will help to some one.
Use $(SRCROOT)/$(PROJECT_NAME) to setup a dynamic link as dragging the file to settings make a static path and that causes a problem when running the project in another path
go to
1- Build Settings > Search: "Prefix Header".
2- Under "Apple LLVM 7.0" you will get the Prefix Header key.
3- Type file directory. e.g: "$(SRCROOT)/$(PROJECT_NAME)/ProjectName-Prefix.pch".
I too had this issue today - I found that if I gave the path to my App-Bridging-Header.h in the form of "${SRCROOT}/App/Some/Directory/App-Bridging-Header.h" the error in question would occur, however by changing the bridging header path to simply App/Some/Directory/App-Bridging-Header.h the PCH "module file not found" disappeared and I was able to compile my project.
I did not need to create a Prefix.pch file at all
Hope this helps someone!

iOS clang error no file or directory

I''m very unfamiliar with the iOS build process. I was giving a legacy application that hasn't been touched in a few years, it was targeting iOS 5 before I opened it.
I'm running into an error Command
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang failed with exit code 1
I could be wrong but I've browsed a few post and it seems like older xCode cersions didn't have a pch file. Any suggestion on how to get this project running again?
Thank you
If this file you are used to bridge OC and Swift,now you should creat a new .header file and Move All Header file Name inside file
and Add Your File Location inside Build setting -> objectiveC Bridging Header
Hope It Works.
It seems the .pch file is missing from the project but reference still exists in the Xcode Settings. So, Xcode is searching for the .pch file but couldn't find the same.
I recommend you to update the GPU-Image Framework as this might be the old framework. Otherwise, Try the below steps:
Go the Build Settings.
Scroll down to the section 'Apple LLVM 8.1- Language'.
You'll see the option for 'Prefix Header' with the path to the .pch file.
Remove the path from the 'Prefix Header'.
Hope this'll solve your issue.

Xcode not searching correct subdirectory for headers

I am using Cocoapods for dependency resolution in an iOS project.
The problem I am having is that the compiler is unable to find the correct subdirectory where the headers are located.
See in the image below the directory in which the compiler is searching for the header file:
However, the file is in the subdirectory /Users/Scott/Documents/GitHub/ios-demo/Pods/iOS-KML-Framework/KML. How do I specifically enable that subdirectory to be searched? I have tried suggestions here and here but those did not seem to work.
Any help would be greatly appreciated!
try set Header Search Path or Library Search Path in Building Setting:

<ShinobiGrids/ShinobiGrids.h> file not found

I just updated my shinobigrids and I am looking at some sample codes the new has got and I tried to #import but I got a file not found error. but I can see this files in the framework...why am I getting this error:
Looks like you need to check your framework search paths in the Xcode project file settings - they'll not be pointing at your framework I imagine

<libxml2/tree.h> not found in my Xcode project

Hi in my Xcode project I included libxml2.dylib framework. I am still getting a error:
libxml2/tree.h not found.
How to resolve this issue?
I didn't give any search header paths. I am using Xcode 4.2
In my own projects that use libxml2, I modified the Header Search paths to explicitly tell the compiler where to find the header files:
As you can tell from the "$(SDKROOT)" bit, it's actually built into the SDK that gets installed with Xcode.
change the Header Search Paths to this:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk/usr/include/libxml2
you are welcome :)
Read this documents.........i think this url is helpful for you....
see this topic in this url Setting up your project file
if you did not know header search path in Xcode , then follow step
go to target->click on BUild Setting-> search heder in search bar -> then you see search Path -> and check header search path
you go in Build Phase "Link with binary Libarys" and add libxml2 frame work
You follow all step after use step then click all tab (not combined tab)
I have similar issue and fix issue by following steps as per this article :
http://www.optimusmobility.com/2013/06/11/how-to-resolve-libxmltree-h-file-not-found-error/

Resources