ld cannot find crt1.o crti.o

Hi,

I’m facing some problems in getting the pgi compiler suite (19.10) to work on an x86_64 system with ubuntu 16.04.12 and gcc 5.4.0.

The installation script runs until completion without problem however whenever I try to use the compilers I have the following linker problem:

/usr/bin/ld: cannot find /usr/lib64/crt1.o: No such file or directory
/usr/bin/ld: cannot find /usr/lib64/crti.o: No such file or directory

The compiler is instructing the linker with the absolute path to those object files which instead are located under /usr/lib/x86_64-linux-gnu/.

I can solve the problem creating two symlinks in /usr/lib64, however this seems an ugly solution to me, I would rather been able to have the compilers working out of the box. I cannot understand whether I somehow broke my ubuntu installation and /usr/lib64 should be a symlink to /usr/lib/x86_64-linux-gnu/ or whether it is a PGI issue. What do you guys think?

Thanks,

Marco

Duplicate post. Please see ld cannot find /usr/lib64/crt1.o /usr/lib64/crti.o

-Mat