Step 1: create the Java class:
public class Hello {
public static void main(String[] args) {
System.out.println("hello, world");
}
}
Step 2: compile the Java class into a .m file:
j2objc Hello.java
Step 3: create the binary file:
j2objcc -c Hello.m
Result:
/Users/miaroba/j2objc-0.5.2/include/JreEmulation.h:25:13: fatal error:
'Foundation/Foundation.h' file not found
#import <Foundation/Foundation.h>
The file JreEmulation.h does reference the missing header file:
24 #ifdef __OBJC__
25 #import <Foundation/Foundation.h>
I checked in this directory:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.8.sdk
and I found these files:
/System/Library/Frameworks/AVFoundation.framework/Versions/A/Headers/AVFoundation.h
./System/Library/Frameworks/CoreFoundation.framework/Versions/A/Headers/CoreFoundation.h
./System/Library/Frameworks/Foundation.framework/Versions/C/Headers/Foundation.h
./System/Library/Frameworks/JavaVM.framework/Versions/A/Frameworks/JavaNativeFoundation.framework/Versions/A/Headers/JavaNativeFoundation.h
I modified j2objcc like this:
clang $* -I /Applications/...../Headers -I ${INCLUDE_PATH} ${CC_FLAGS} ${OBJC} ${LINK_FLAGS}
but I got a cascading set of missing header files;(
--
You received this message because you are subscribed to the Google Groups "j2objc-discuss" group.
To unsubscribe from this group, send email to j2objc-discus...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.