I’m seeing a haiku specific link error in one of my libraries.
TextView4.cpp:5499:(.text+0x15279): undefined reference to `LExecute'
Right, so that should be in liblgid.so… And it is! …kinda..?
~/code/lgi/trunk/Debug> readelf -sWC liblgid.so | grep -iw LExecute
3667: 0000000000000000 0 NOTYPE GLOBAL DEFAULT UND LExecute
10200: 0000000000596cf6 3161 FUNC GLOBAL DEFAULT 11 LExecute(char const*, char const*, char const*, LString*)
18436: 0000000000000000 0 NOTYPE GLOBAL DEFAULT UND LExecute
24969: 0000000000596cf6 3161 FUNC GLOBAL DEFAULT 11 LExecute(char const*, char const*, char const*, LString*)
It’s definitely being compiled into that .so, if I put a #error just before it’s defn it will error out.
The compile command looks like:
g++
-I../deps/build-x64-debug/include
-I./private/common
-I./include
-I./private/haiku
-I./include/lgi/haiku
-I../../../../system/develop/headers
-MMD
-MP
-fPIC
-fno-inline
-g
-fpermissive
-std=c++14
-g
-D_DEBUG
-DHAIKU
-D_REENTRANT
-DLGI_LIBRARY
-DLGI_UNIT_TESTS
-DPOSIX
-D_GNU_SOURCE
-c /boot/home/code/lgi/trunk/src/haiku/General.cpp
-o Debug/General.o
Link:
g++
-shared
-o Debug/liblgid.so
...
Debug/General.o
...
-L../deps/build-x64-debug/lib
-llunasvg
-lplutovg
-liconv
-static-libgcc
-lgnu
-lnetwork
-lbe
(Where ‘…’ are other objects…)
And this is perfectly fine on Linux:
matthew@matthew-linux:~/code/lgi/trunk/Debug$ readelf -sWC liblgi-gtk3d.so | grep -iw LExecute
4840: 000000000036173b 3683 FUNC GLOBAL DEFAULT 14 LExecute
12907: 000000000036173b 3683 FUNC GLOBAL DEFAULT 14 LExecute
No weird little NOTYPE entries. Does anyone know what generates those?