Re: Trouble compiling base

R Frith-Macdonald <[email protected]> Sun, 4 Jan 2026 19:39:48 +0000
Newsgroups gmane.comp.lib.gnustep.devel
Message-ID <[email protected]>
Since you are wanting to use the ng-gnu-gnu library combo=20
(clang/libobjc2) rather than the standard gnu-gnu-gnu library combo=20
(gcc/gnu-libobjc),=C2=A0 you first configure gnustep-make that way (you=20
didn't say whether you did that) and install it.

Next, you have to source GNUstep.sh to set up your environment, then=20
build/install libobjc2 (this is more complicated) so that it installs in=
=20
the correct place (if you configured gnustep-make with --layout=3Dgnustep=
=20
this is NOT /usr/local since the gnustep layout uses /usr/GNUstep/...).=20
However, the libobjc2 code should use the information provided by=20
GNUstep.sh to find the correwct place whichever filesystem layout you chos=
e.

Next you build/install gnustep-base (then gnustep-gui, then=20
gnustep-back). None of these normally need any special configure options=
=20
unless libraries that they depend on are not present in the standard=20
locations.

For each stage, the configure script generates a config.log file which=20
records what was done and (if it failed) why it failed.

Finally, your compile command appears to have a typo;=C2=A0 I expect you=
=20
meant to use -lobjc


On 04/01/2026 18:49, Mick wrote:
> Hello.
> Once again in my life, I am installing gnustep, but every time after a l=
ot of time, so I have to learn from scratch the procedure.
> This time on my own LinuxMint 22, and I am in trouble configuring base.
>
> I downloaded gnustep-make-2.9.3.tar.gz, unpacked and configured to use
> clang compiler (14) and --layout=3Dgnustep.
> Than I got libobjc2 from github repo, compiled and installed under
> /usr/local. Finally I added /usr/local/lib in a file under /etc/ld.so.co=
nf.d/, and launched ldconfig.
>
> At the base step the configure failed "checking whether objc really
> works... no". So I tried to write a very simple program in objc
> (containing a class definition, though), and it fails to link with
> error: "/usr/bin/ld: /tmp/testobjc-ba4d71.o:(.data.rel.ro+0x0):
> undefined reference to `__objc_class_name_Object'".
>
> Any idea of what can I miss?
> I compiled the program with "clang -o testobjc testobjc.m
> -L/usr/local/lib -mobjc", so I am quite sure I am pointing the right
> library.
>
> --
> Mick
>
>
>