Thomas Zeiser

Some comments by Thomas Zeiser about HPC@RRZE and other things

Content

32-bit Intel compiler on 64-bit Ubuntu system

The 32-bit Intel compilers fail to produce 32-bit executables on a 64-bit Ubuntu (or Debian) system as they append (hardcoded) /usr/lib/crt?.o to the linkage command. On 64-bit Ubuntu or Debian systems, however, /usr/lib contains 64-bit code and 32-bit code is in /usr/lib32. The workaround is to prevent the compiler from using the standard startup files when linking and supplying the correct ones manually, i.e. -L/usr/lib32 -nostartfiles /usr/lib32/crt1.o /usr/lib32/crti.o /usr/lib32/crtn.o. As specifying these command line arguments is cumbersome, they can be written to some file and referenced using the ICCCFG, ICPCCFG or IFORTCFG environment variable. This is now done automatically on RRZE’s system via the Modules system. But of course it would be preferential if Intel could determine the correct directories and files itself – but probably, Debian/Ubuntu is not supported officially or nobody tries to create 32-bit code on a 64-bit system …