[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Problem building gnustep-base
From: |
Nicola Pero |
Subject: |
Re: Problem building gnustep-base |
Date: |
Fri, 22 Feb 2002 16:19:18 +0000 (GMT) |
> I recompiled gcc with --enable-threads=pthreads which doesn't help eighter...
> config.log shows:
>
> configure:2051: checking whether objc has thread support
> configure:2096: gcc -o conftest -O2 -x objective-c -I. conftest.c -lobjc
> -lp
>
> thread 1>&5
> In file included from configure:2093:
> config_thread.m:7: warning: incomplete implementation of class
> `NXConstantString
>
> '
> config_thread.m:7: warning: method definition for `-length' not found
> config_thread.m:7: warning: method definition for `-cString' not found
> configure: failed program was:
> #line 2092 "configure"
> #include "confdefs.h"
> #include "config_thread.m"
> > Sorry for replying to my own mail again, but I found a part of the problem
> > in
> > the gnustep-make configure script I uncommented the following lines:
> >
> > gcc_shared_libobjc=`gcc -print-file-name=libobjc.so`
> > if test -f "$gcc_shared_libobjc"; then
> > gs_cv_objc_libdir=`dirname $gcc_shared_libobjc`
> > fi
I don't understand how/why this is supposed to work. It might work, I
don't know how you are configuring things. But I would *at least* modify
it to read
gcc_shared_libobjc=`$CC -print-file-name=libobjc.so`
otherwise you're using the default gcc shared libobjc, but compiling with
the newer compiler. Of course then you get problems with
NXConstantString!
I think there is some sort of confusion here.
If you use a stock compiler, but use a custom libobjc, then gnustep-make
is going to detect the custom libobjc and hack all compilation and
configuration stuff so that the custom libobjc is used instead of the
compiler's one.
If you use a stock compiler, and use the compiler's standard libobjc, then
gnustep-make has nothing to do - yours is a standard compiler
installation, and the compiler - when properly installed - automatically
uses the correct libobjc ! If that doesn't work, then it's your problem
:-) (or your distribution problem) to fix the compiler installation so
that the compiler works !
And, it's very simple to do.
On my system, after having installed GCC 3.0.1 from CVS, I need to source
the following script to use it -
#! /bin/sh
# Experimental Compiler
#
# Uncomment to use GCC 3.0 as default compiler
#
PATH=/opt/gcc-3.0/bin:$PATH
LD_LIBRARY_PATH=/opt/gcc-3.0/lib/:/opt/gcc-3.0/lib/gcc-lib/i686-pc-linux-gnu/3.0.1:$LD_LIBRARY_PATH
export LD_LIBRARY_PATH
But that might be because I like to switch compiler on the fly. I
remember someone suggested a better simpler solution - if you look on the
old mailing list archives, you'll find it.
Anyway - you need to make sure your compiler's libobjc.so and libgcc_s.so
are in the linker paths - either by adding them to /etc/ld.so.conf, or by
adding them to the LD_LIBRARY_PATH, or by whatever other configuration the
installation of a new compiler requires.
If you install multiple compilers or do strange things with the compilers
or whatever - you're free to do what you want but ... you must make sure
your compilers works before even trying to configure gnustep-make.
Once you have a working Objective-C compiler installation, then you can
start the gnustep configuration/compilation procedure.
Please feel free to contribute updates/fixes to the gnustep HOWTO or
installation documents if they were not helpful enough.
> > > > Something goes wrong while building gnustep-base with gcc 3.0.4
> > > > I just installed the new gcc in /usr/GNUstep
> > > > But the configure of gnustep-base returns:
> > > >
> > > > checking for objc/objc.h... yes
> > > > checking for gdomap network details... checking for variable length
> > > > socket addresses... not found
> > > > checking for objc threading flags...
> > > > checking whether byte ordering is bigendian... no
> > > > checking size of void*... 4
> > > > checking size of short... 2
> > > > checking size of int... 4
> > > > checking size of long... 4
> > > > checking size of long long... 8
> > > > checking size of float... 4
> > > > checking size of double... 8
> > > > checking loading of constructor functions... yes
> > > > checking for dlfcn.h... yes
> > > > checking whether objc really works... no
> > > > I don't seem to be able to use your Objective-C compiler to produce
> > > > working binaries! Please check your Objective-C compiler installation.
> > > > If you are using gcc-3.x make sure that your compiler's libgcc_s and
> > > > libobjc
> > > > can be found by the dynamic linker - usually that requires you to play
> > > > with LD_LIBRARY_PATH or /etc/ld.so.conf.
> > > > Please refer to your compiler installation instructions for more help.
> > > > configure: error: The Objective-C compiler doesn't work or is not
> > > > installed properly.
Btw, I'm still puzzled - why did you ignore this message in the first
place ? It's telling you where the problem is, and explaining you what to
do to fix it.
Re: Problem building gnustep-base, David Relson, 2002/02/22