help-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: MacOSX GNUstep build issues


From: Kree Cole-McLaughlin
Subject: Re: MacOSX GNUstep build issues
Date: Thu, 09 Dec 2004 12:06:18 -0800
User-agent: Mozilla Thunderbird 0.9 (Macintosh/20041103)

Adam Fedor wrote:


On Dec 9, 2004, at 2:19 AM, Kree Cole-McLaughlin wrote:

Ooops, you're right, I got it backwards. I guess libgnustep-base is linking agaisnt the shared libraries, which means every time I want to build an app I need to include the libraries in the linking command (what a pain!) Does anyone know how to force darwin to include the static versions of the libraries in libgnustep-base? Do I have to move the shared libraries out of the way while I compile GNUstep? There should be a better way.


Um... I'm not really sure what's going on here. You shouldn't need to include basic libraries like libxml, etc in every linking command. What errors are you getting? What are you compiling? Try running make like this:

Okay I recompiled things without my changes so I could list the error I get. When compiling in the gui directory it stops here:

Making all in Tools...
Making all for tool make_services...
/GNUstep/usr/bin/gcc        -o shared_obj/make_services \
       ./shared_obj/make_services.o \
-L/sw/lib -L../Source/./shared_obj -L../Model/./shared_obj -L/GNUstep/System/Library/Libraries/ -lgnustep-base -lobjc -lm
/usr/bin/ld: Undefined symbols:
_ffi_prep_cif
_ffi_type_double
_ffi_type_float
_ffi_type_pointer
_ffi_type_sint16
_ffi_type_sint32
_ffi_type_sint64
_ffi_type_sint8
_ffi_type_uint16
_ffi_type_uint32
_ffi_type_uint64
_ffi_type_uint8
_ffi_type_void
_gzclose
_gzdopen
_gzread
_gzseek

There are a lot more undefined symbols after this but you get the idea. My work around was to change these lines of Makefile.preamble:


# Additional library directories the linker should search
ADDITIONAL_LIB_DIRS += -L../Source/$(GNUSTEP_OBJ_DIR) -L../Model/$(GNUSTEP_OBJ_DIR)

# Additional libraries when linking tools
make_services_TOOL_LIBS +=
gpbs_TOOL_LIBS += -lgnustep-gui $(SYSTEM_LIBS)
set_show_service_TOOL_LIBS += -lgnustep-gui $(SYSTEM_LIBS) gopen_TOOL_LIBS += -lgnustep-gui $(SYSTEM_LIBS)

to


# Additional library directories the linker should search
ADDITIONAL_LIB_DIRS += -L../Source/$(GNUSTEP_OBJ_DIR) -L../Model/$(GNUSTEP_OBJ_DIR) $(ADDITIONAL_DEPENDS) -L/sw/lib -lgmp -lxslt -lxml2 -lz -lpthread -liconv -lm -lffi -ldl -lz

# Additional libraries when linking tools
make_services_TOOL_LIBS += -lgmp -lxslt -L/sw/lib -lxml2 -lz -lpthread -L/sw/lib -liconv -lm -lffi -ldl -lz
gpbs_TOOL_LIBS += -lgnustep-gui $(SYSTEM_LIBS)
set_show_service_TOOL_LIBS += -lgnustep-gui $(SYSTEM_LIBS) gopen_TOOL_LIBS += -lgnustep-gui $(SYSTEM_LIBS)

When I did this it compiled fine. But as you can see it is a pain to have to include all those additional libs every time I want to link a tool.

make messages=yes


Thanks for this suggestion. I was trying to find the command to print out the make info. Eventually I started using 'make -N' :)

Okay, gdomap -N say nothing is registered. I guess this means there is a problem with gdnc right?


Yes. I'm not sure what, because it works fine on my Mac OS X system as well as many other people's. You probably need to debug it. Make sure to use the '-f' switch to prevent it from forking.


I get a bus error when I use -f. I've recompiled with debugging symbols and I am going to try to figure out what causes this. BTW when it links gdnc I get a warning about multiple symbols definitions for NSDistributedNotificationCenterDummy. Is this normal?

Thanks for your help. I really want to get this running so I can start writing some portable apps on my mac.

-Kree





reply via email to

[Prev in Thread] Current Thread [Next in Thread]