graphics/sane-backends 1.2.1: ld: error: undefined symbol: basename@FBSD_1.0
# uname -a
FreeBSD host-name 15.0-CURRENT-HBSD FreeBSD 15.0--HBSD amd64 1500000 #0 : Thu Sep 14 13:34:53 UTC 2023 root@hbsd-build-01:/usr/obj/usr/src/amd64.amd64/sys/HARDENEDBSD amd64
# sysctl hardening | grep rtld
hardening.harden_rtld: 0
make
, also make MAKE_JOBS_UNSAFE=yes
,
also tried default config,
opted out all hardening options;
console output final:
...
libtool: link: cc -Wall -O2 -pipe -DHARDENEDBSD -fPIE -fPIC -mretpoline -fstack-protector-all -Qunused-arguments -isystem /usr/local/include -fno-strict-aliasing -pie -Wl,-z -Wl,relro -Wl,-z -Wl,now -fstack-protector-all -o .libs/scanimage scanimage.o jpegtopdf.o siccc.o stiff.o -L/usr/local/lib ../backend/.libs/libsane.so ../sanei/.libs/libsanei.a ../lib/.libs/liblib.a -lpng -ljpeg -Wl,-rpath -Wl,/usr/local/lib
ld: error: undefined symbol: basename@FBSD_1.0
>>> referenced by scanimage.c
>>> scanimage.o:(write_png_header)
>>> did you mean: basename
>>> defined in: /lib/libc.so.7
cc: error: linker command failed with exit code 1 (use -v to see invocation)
gmake[4]: *** [Makefile:571: scanimage] Error 1
gmake[4]: Leaving directory '/usr/ports/graphics/sane-backends/work/sane-backends-1.2.1/frontend'
gmake[3]: *** [Makefile:608: all-recursive] Error 1
gmake[3]: Leaving directory '/usr/ports/graphics/sane-backends/work/sane-backends-1.2.1'
gmake[2]: *** [Makefile:498: all] Error 2
gmake[2]: Leaving directory '/usr/ports/graphics/sane-backends/work/sane-backends-1.2.1'
*** Error code 1
...