gnustep-dev
[Top][All Lists]
Advanced

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

Libobjc2 on Linux - link issues


From: Riccardo Mottola
Subject: Libobjc2 on Linux - link issues
Date: Tue, 18 Feb 2020 23:40:25 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Firefox/52.0 SeaMonkey/2.49.9.1

Hi!

while I got a reliable clang+libobjc2 setup on OpenBSD with the bfd
linker (contrary to other experiences here) I am unable to get it to
work on something as simple as a current Linux/i386 with clang 8

I configure current make with:
./configure --prefix=/ --with-layout=gnustep
--with-library-combo=ng-gnu-gnu LDFLAGS=-fuse-ld=gold

I tried with and without LDFLAGS gold.
I build and install "our" libobjc2.

When I configure base, I get this failure:
/System/Library/Libraries/libobjc.so: error: undefined reference to
'__cxa_guard_acquire'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'std::terminate()'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'__cxa_guard_abort'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'std::ios_base::Init::Init()'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'__cxa_rethrow'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'__cxa_begin_catch'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'std::ios_base::Init::~Init()'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'__cxa_guard_release'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'std::basic_ostream<char, std::char_traits<char> >& std::operator<<
<std::char_traits<char> >(std::basic_ostream<char,
std::char_traits<char> >&, char const*)'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'operator new(unsigned int)'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'std::cerr'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'__cxa_end_catch'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'operator delete(void*)'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'std::ostream::operator<<(std::ostream& (*)(std::ostream&))'
/System/Library/Libraries/libobjc.so: error: undefined reference to
'std::basic_ostream<char, std::char_traits<char> >& std::endl<char,
std::char_traits<char> >(std::basic_ostream<char, std::char_traits<char>
>&)'
clang-8: error: linker command failed with exit code 1 (use -v to see
invocation)


If Instead I do NOT use gold option, I get this

1 warning generated.
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to
`std::ostream::operator<<(std::ostream& (*)(std::ostream&))'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `std::basic_ostream<char,
std::char_traits<char> >& std::endl<char,
std::char_traits<char> >(std::basic_ostream<char, std::char_traits<char>
>&)'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `operator delete(void*)'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `__cxa_end_catch'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `std::basic_ostream<char,
std::char_traits<char> >& std::operator<<
<std::char_traits<char> >(std::basic_ostream<char,
std::char_traits<char> >&, char const*)'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `__cxa_guard_release'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `std::ios_base::Init::~Init()'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `operator new(unsigned int)'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `std::cerr'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `__cxa_begin_catch'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `__cxa_rethrow'
/usr/lib/gcc/i686-pc-linux-gnu/7.3.0/../../../../i686-pc-linux-gnu/bin/ld:
/System/Library/Libraries/l
ibobjc.so: undefined reference to `std::ios_base::Init::Init()'

which is even more weird?

Riccardo



reply via email to

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