Hi all,
I’m just trying to compile the latest HEAD 2021-09-12 on Ubuntu LTS. The last time I did this was around Xmas last year, and the compile was succesful. However, I am now getting the following error message:
gcc -I../common -I../rt -L../lib -O2 -Dlinux -D_FILE_OFFSET_BITS=64 -L/usr/X11R6/lib -I/usr/include/X11 -DNOSTEREO -c -o genbox.o genbox.c
gcc -I../common -I../rt -L../lib -O2 -Dlinux -D_FILE_OFFSET_BITS=64 -L/usr/X11R6/lib -I/usr/include/X11 -DNOSTEREO -o genbox genbox.o -lwfobj -lrtrad
/usr/bin/ld: genbox.o: in function `cylinder':
genbox.c:(.text+0x728): undefined reference to `sincos'
/usr/bin/ld: ../lib/librtrad.a(xf.o): in function `xf':
xf.c:(.text+0x3ed): undefined reference to `sincos'
/usr/bin/ld: xf.c:(.text+0x611): undefined reference to `sincos'
/usr/bin/ld: xf.c:(.text+0x759): undefined reference to `sincos'
/usr/bin/ld: ../lib/librtrad.a(xf.o): in function `invxf':
xf.c:(.text+0xbe6): undefined reference to `cos'
/usr/bin/ld: xf.c:(.text+0xc13): undefined reference to `sin'
/usr/bin/ld: xf.c:(.text+0xe2a): undefined reference to `cos'
/usr/bin/ld: xf.c:(.text+0xe57): undefined reference to `sin'
/usr/bin/ld: xf.c:(.text+0xf9a): undefined reference to `cos'
/usr/bin/ld: xf.c:(.text+0xfc3): undefined reference to `sin'
/usr/bin/ld: ../lib/librtrad.a(fvect.o): in function `normalize':
fvect.c:(.text+0x4b6): undefined reference to `sqrt'
/usr/bin/ld: ../lib/librtrad.a(fvect.o): in function `spinvector':
fvect.c:(.text+0x82c): undefined reference to `sincos'
/usr/bin/ld: ../lib/librtrad.a(fvect.o): in function `geodesic':
fvect.c:(.text+0xac4): undefined reference to `sincos'
/usr/bin/ld: fvect.c:(.text+0xb91): undefined reference to `sqrt'
/usr/bin/ld: fvect.c:(.text+0xc00): undefined reference to `acos'
/usr/bin/ld: fvect.c:(.text+0xc43): undefined reference to `sqrt'
/usr/bin/ld: ../lib/librtrad.a(fvect.o): in function `Acos':
fvect.c:(.text+0x29): undefined reference to `acos'
/usr/bin/ld: ../lib/librtrad.a(fvect.o): in function `Asin':
fvect.c:(.text+0x71): undefined reference to `asin'
collect2: error: ld returned 1 exit status
make: *** [Rmakefile:38: genbox] Error 1
make: Target 'install' not remade because of errors.
I’m not much of a C programmer, but tried
#include <math.h>
in both genbox.c and xf.c, but to no avail. Whilst I don’t tend to use genbox a lot, the compile error also causes other generators to not get installed (which I did manually).
Any ideas on how to fix this?
Thank you
Axel