Hi Fredrik,
I would love to get sdljava working with Max OS X. I can't offer to
much aid at the moment however because I don't have access to an OS X
machine.
There might be some special stuff you have to do to have it work under
Eclipse. Check the list archives. I know people have gotten it to work
under Eclipse but I think they had to explicitly specify the path to the
shared libraries. I've added a VM switch to allow this.
Having all the classes in the jarfile should be fine. Unless you
actually reference image or gfx then the VM won't attempt to load those
shared libraries. The System.loadLibrary() call is only made if the
class is actually loaded by the runtime which won't happen unless its
referenced by come other class.
Would really appreciate it if someone can get this working on OS X.
Please post the appropriate Makefile, documentation, etc... that are
needed to make it work and I'll include it in the next release. If
someone is willing to build me binaries for OSX before a release I can
include those for the public.
-Ivan/
Fredrik Olsson wrote:
> Hi.
>
> I have tried to compile sdljava for Mac OS X, the Makefile does not
> work as -shared is not used on gcc for Darwin (-dynamic should be used
> to linker instead). To work around that I instead created a dummy
> XCode project and successfully compiled libsdljava.dylib (Default
> extension is .dylib not .so).
>
> Using ant I have compiled sdljava.jar as the INSTALL text file
> documents, and included it in my project in Eclipse. When starting the
> application it says that libsdljava can not be found in path. I have
> tried to rename .dylib to .so and put it in different paths (.,
> /usr/lib and /usr/lib/java/).
>
> I have linked against the lib from another C application to confirm
> that it works so far.
>
> The jar still includes classes for image and gfx that I have not
> compiled native libraries for, I guess that could be the problem. If
> that is the problem how do I compile the jar with only selected classes?
>
> I am quite new to Java and very new to JNI so any help is appreciated.
> Pre-compiled binaries would be best :). But a crash course is also
> very welcome (Always good to know what it is you are doing).
>
> regards
> Fredrik Olsson
>
>
>
> -------------------------------------------------------
> SF email is sponsored by - The IT Product Guide
> Read honest & candid reviews on hundreds of IT Products from real users.
> Discover which products truly live up to the hype. Start reading now.
> http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
> _______________________________________________
> sdljava-users mailing list
> sdl...@li...
> https://lists.sourceforge.net/lists/listinfo/sdljava-users
|