We use WSDLParser tool to parse our xml content, till Xcode 9.2 everything was ok. As we shifted to Xcode 9.3, we are getting this error in one of parser file "Implicit declaration of function 'xmlFree' is invalid in C99".
The declaration was moved to globals.h, it should compile with this import:
#import <libxml/globals.h>
Related
I have a target with mixed Swift and Objective-C code. I do the following:
I put a breakpoint on a line in a Swift file part of this target.
I run this target.
I type po $someVariableName in the debugger once it hits the breakpoint.
The debugger now shows a host of errors, ending with:
error: failed to import bridging header '/path/to/Bridging-Header.h'
Couldn't initialize Swift expression evaluator due to previous errors.
The output starts with:
Error while loading Swift module:
TARGET_NAME: /path/to/Bridging-Header.h:18:9: note: in file included from /path/to/Bridging-Header.h:18:
In between are a host of nullability annotation warnings and errors about unknown type names. Some errors come from bridging headers in the Carthage builds directory:
error: /path/to/project/Carthage/Build/iOS/Some.framework/Headers/Some-Swift.h
It seems as if whatever is executing after my po statement, lacks a few header imports or executes things in the wrong order. Any clue as to what could be wrong here?
I am using Xcode 11.4 (11E146)
I have a Problem when I try to compiling my iOS project with iOS 8.
The errors messages are:
Implicit declaration of function 'glReadPixels' is invalid in C99 compiling
Conflicting types for 'glReadPixels'
Declaration of 'glReadPixels' must be imported from module 'OpenGLES.ES3.gl' before it is required
Recently I have faced the same issue.
The easiest way to resolve this problem is by adding #import OpenGLES; line in each file where you have got this message.
For iOS 8 is necessary Import
#import <OpenGLES/ES3/glext.h>
This link is the solution Click Here...
In my iOS 8 testing, everything seems to be working fine but now I'm getting issues with my OpenGLES framework where the gl header file exists, but for some reason it says that the GL_TEXTURE0 definition (along with various other definitions) cannot be found.
glActiveTexture(GL_TEXTURE0);
Exact error:
Implicit declaration of function glActiveTexture is invalid in C99.
Use of undeclared identifier 'GL_TEXTURE0'
This could be because I may be importing the framework incorrectly, but this is how I've been using it and it works fine in iOS 7 and below.
#import <OpenGLES/EAGL.h>
I'm not sure what the reasoning is, but I changed my import statements as follows:
#import <OpenGLES/ES2/gl.h>
#import <OpenGLES/ES2/glext.h>
This seems to resolve the issue.
I need to download and unzip a file in my Xcode project,
I am using Ziparchive (https://code.google.com/p/ziparchive/downloads/detail?name=ZipArchive.zip) to do so,instead of following every step I am getting compilation error as below:
/Developer/AR/vuforia-sdk-ios-2-6-8/samples/ARDemo/minizip/ioapi.c:68:18: Redefinition of 'fopen_file_func' as different kind of symbol
/Developer/AR/vuforia-sdk-ios-2-6-8/samples/ARDemo/minizip/ioapi.c:68:35: Use of undeclared identifier 'opaque'
/Developer/AR/vuforia-sdk-ios-2-6-8/samples/ARDemo/minizip/ioapi.c:68:58: Expected ';' after top level declarator
/Developer/AR/vuforia-sdk-ios-2-6-8/samples/ARDemo/minizip/ioapi.c:72:1: Expected unqualified-id
/Developer/AR/vuforia-sdk-ios-2-6-8/samples/ARDemo/minizip/ioapi.c:90:17: Redefinition of 'fread_file_func' as different kind of symbol
Developer/AR/vuforia-sdk-ios-2-6-8/samples/ARDemo/minizip/ioapi.c:90:42: Use of undeclared identifier 'stream'; did you mean 'strcat'?
Developer/AR/vuforia-sdk-ios-2-6-8/samples/ARDemo/minizip/ioapi.c:90:50: Use of undeclared identifier 'buf'
/Developer/AR/vuforia-sdk-ios-2-6-8/samples/ARDemo/minizip/ioapi.c:95:1: Expected unqualified-id
I dont have a clue how to compile it successfully, any help is appreciated.
In my case, it happens because I have an incorrect Prefix file.
It was including objective c imports outside the "#ifdef OBJC" block
So that there was no problem when all classes were objetctive-C classes but it didn't compile when I add the C classes of minizip.
Just moving all the imports in the prefix file inside the obj block and voilĂ !
#ifdef __OBJC__
#import <Availability.h>
#import <UIKit/UIKit.h>
#import <Foundation/Foundation.h>
#endif
I hope this helps
Please Add the FrameWork libz.dylib in your project and solve your problem
Project setting -> Target-> Build Phases -> Linked Frameworks and Libraries -> select ibz.dylib
I got the solution,I am using Metaio SDK for Augmented Reality which has a compile dependancy, it can only be compiled as "Compile sources as - > Objective C++" and this was the reason creating the problem, Ziparchive compiled fine otherwise, now to merge both in the same project I made Ziparchive as a STATIC LIBRARY and linked it in Xcode, it solved the problem.
I have a .m and .h file that generated with Thrift for objective-c based on this link :
http://wiki.apache.org/thrift/ThriftUsageObjectiveC
but there are a lot of error in .m files like :
1. error: duplicate interface definition for class
2. reimplementation of class 'bitlit_thrift_detect_cover_args'
3. use of undeclared identifier '__claim_id'; did you mean 'claim_id'?
4. use of undeclared identifier '__claim_id_isset'
5. reference to local variable 'claim_id' declared in enclosing context
6. error: use of undeclared identifier '__claim_id_isset'
__claim_id_isset = YES;
.....
7. fatal error: too many errors emitted, stopping now [-ferror-limit=]
would you please give me some hints, what is the problem?, is the error related to the xcode setting? my xCode Version is Version 4.6.1
Thanks in advance!
Here is the errors Picture: