Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Compiling JNI Libs on 10.5 (for 10.4)



What is the trick to compile a JNI lib on 10.5 that should also work on 10.4?

Right now I'm using:

g++
  -c
  -g
  -pipe
  -O2
  -Wall
  -W
  -isysroot /Developer/SDKs/MacOSX10.4u.sdk -arch i386
  -I/System/Library/Frameworks/JavaVM.framework/Headers
  my_lib_MyClass.cpp

g++
  -o MyLib.so
  my_lib_MyClass.o
  -Wl,-syslibroot,/Developer/SDKs/MacOSX10.4u.sdk
  -arch i386
  -dynamiclib
  -framework JavaVM

But that results in a:

ld: library not found for -ldylib1.10.5.o
collect2: ld returned 1 exit status
ld: library not found for -ldylib1.10.5.o
collect2: ld returned 1 exit status
lipo: can't open input file:
/var/folders/5i/5inkXg8OGZWPGkqRVOdWdE+++TI/-Tmp-//ccmCrWXP.out (No
such file or directory)

This build works ok in 10.4.

 S.
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Java-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/java-dev/email@hidden

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.