First of all, let me apologize if this posting belongs elsewhere, I
am not a regular user. If this belongs on another list, let me know.
Also, my problem involves Java, although I believe the Java element
is not the main issue. (This is an update to a previous posting from
several months ago. I have been busy with other aspects of the
project, and this part has been lying fallow. Now it is getting in
the way, and needs to be addressed.)
Here's the situation: I have a makefile that was used to build a
shared library (a Java Native Interface library, to be specific).
This makefile worked when I had Panther installed, but it broke when
I upgraded to Tiger.
>>> begin makefile >>>
TARGET=../libJEngine.jnilib
OBJECTS=\
JEngine_Model.o\
JEngine_Parser.o\
# >> more *.o files here <<
engine/model.o\
engine/imc.o
$(TARGET): $(OBJECTS)
# this is the original libtool line
libtool -dynamic -M -single_module -o $@ $^ -lstdc++ -lc -lgcc > map
strip -x $@
%.o: %.cpp
# this is the original cc line
cc -c -O2 -o $@ $^ -I /System/Library/Frameworks/JavaVM.framework/
Headers
# I have tried this, too, with the same results
# g++ -c -O2 -o $@ $^ -I /System/Library/Frameworks/JavaVM.framework/
Headers
So, what is going on here? What are these symbols? Are they STL/
template symbols? (Do I care a lot? Not really, I just want this to
work.)
My experiments with the makefile, including changing cc to gcc or g+
+, or trying to use glibtool instead of libtool, have been
unsuccessful. I have tried setting my GCC version to use 3.3 instead
of 4.0 (sudo gcc_select 3.3). No luck.
Is the GCC distribution broken? Is libtool the culprit, or is it gcc
or ld? Are there any known fixes?
Where are these undefined symbols defined? Am I missing a library or
a header, and if so, which one and how would I find out? (Even if the
problem IS the GCC distribution, I am still curious how I would
determine where to find the definitions of undefined symbols.
Metrowerks supplies a "Find Library" facility which can be used to
find symbols. Does GCC have something like that?)
(One thing that helped a lot was to use the Disk Utility.app to
repair the file permissions on my drive. Before I did that (thanks to
whoever suggested that, I forget where I saw it), libtool choked on
the -llstdc++ -lc -lgcc section of the makefile, asserting that lstdc+
+ and gcc were not found and could not be included. After fixing file
permissions, that error went away. I think everyone should run fix
permissions.)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/darwin-dev/email@hidden