- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I have installed oneAPI Base Toolkit and HPC Toolkit in my WSL2 system.
The system information is
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu 18.04.5 LTS"
The gcc version is: gcc version 7.5.0 (Ubuntu 7.5.0-3ubuntu1~18.04)
The compiler used is Interl Fortran compiler(classic) on the HPC Toolkit. So it is /opt/intel/oneapi/compiler/2021.2.0/linux/bin/intel64/ifort
As I had encoutered the ld problem with my own codes, I went back to the examples given in https://software.intel.com/content/www/us/en/develop/download/776979.html to check the fortran compiler. The same problems happened:
ifort -V src/driver.o src/matvec.o -o matvec
Intel(R) Fortran Intel(R) 64 Compiler Classic for applications running on Intel(R) 64, Version 2021.2.0 Build 20210228_000000
Copyright (C) 1985-2021 Intel Corporation. All rights reserved.
ifort: error #10106: Fatal error in ld, terminated by segmentation violation
Makefile:35: recipe for target 'matvec' failed
make: *** [matvec] Error 1
I found a solved post in the forum https://community.intel.com/t5/Intel-Fortran-Compiler/ld-fatal-error/td-p/1226358. But I now have oneAPI installed, which seems to be a more intergrated and last updated version. Do I really need to go backe to the parallel_studio_xe_2020 version to get rid of the ld problem?
The LD_PATH variable is echo $LD_LIBRARY_PATH
/opt/intel/oneapi/vpl/2021.2.2/lib:/opt/intel/oneapi/tbb/2021.2.0/env/../lib/intel64/gcc4.8:/opt/intel/oneapi/mpi/2021.2.0//libfabric/lib:/opt/intel/oneapi/mpi/2021.2.0//lib/release:/opt/intel/oneapi/mpi/2021.2.0//lib:/opt/intel/oneapi/mkl/latest/lib/intel64:/opt/intel/oneapi/itac/2021.2.0/slib:/opt/intel/oneapi/ippcp/2021.2.0/lib/intel64:/opt/intel/oneapi/ipp/2021.2.0/lib/intel64:/opt/intel/oneapi/dnnl/2021.2.0/cpu_dpcpp_gpu_dpcpp/lib:/opt/intel/oneapi/debugger/10.1.1/dep/lib:/opt/intel/oneapi/debugger/10.1.1/libipt/intel64/lib:/opt/intel/oneapi/debugger/10.1.1/gdb/intel64/lib:/opt/intel/oneapi/dal/2021.2.0/lib/intel64:/opt/intel/oneapi/compiler/2021.2.0/linux/lib:/opt/intel/oneapi/compiler/2021.2.0/linux/lib/x64:/opt/intel/oneapi/compiler/2021.2.0/linux/lib/emu:/opt/intel/oneapi/compiler/2021.2.0/linux/lib/oclfpga/host/linux64/lib:/opt/intel/oneapi/compiler/2021.2.0/linux/lib/oclfpga/linux64/lib:/opt/intel/oneapi/compiler/2021.2.0/linux/compiler/lib/intel64_lin:/opt/intel/oneapi/compiler/2021.2.0/linux/compiler/lib:/opt/intel/oneapi/ccl/2021.2.0/lib/cpu_gpu_dpcpp
Does anygone have any solution to this problem?
WY
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You need to run the commands manually and see what the ld message said. There is no useful information in what you posted. Be aware that other posts of the same general symptom may be unrelated. If you need more help, you'll need to attach a test case that demonstrates the problem.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You can find the test case in the attached file. The error messages are:
ifort -V src/driver.o src/matvec.o -o matvec
Intel(R) Fortran Intel(R) 64 Compiler Classic for applications running on Intel(R) 64, Version 2021.2.0 Build 20210228_000000
Copyright (C) 1985-2021 Intel Corporation. All rights reserved.
ifort: error #10106: Fatal error in ld, terminated by segmentation violation
Makefile:35: recipe for target 'matvec' failed
make: *** [matvec] Error 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Or even an easy helloworld program gives me this problem. You can find the serial_hello.f90 in attached file and compile with the command:
ifort serial_hello.f90 -o serial_hello
The error message is
ifort: error #10106: Fatal error in ld, terminated by segmentation violation
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
On your system, are you able to compile, link and run a C program using GCC? If not, that problem has to be solved before attempting to get Ifort to work.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
For the above serial_hello.f90 program, gfortran works and so does ifx. Only ifort produce the ld segmentation error.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
GETENV is not a Fortran command, it is a system extension. If you wish to use that in intel Fortran add USE IFPORT. Read the help topic on GETENV, you may have linked to a GENENV in the C library runtime but the calling will probably be invalid.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I can remove than line. I can just compile a program that aims to print a 'Hello world' (see the attached file). The same error takes place.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I do not know whether the following pertains to your installation of Ifort-Linux on WSL2, but I do remember that WSL1 did not support any 32-bit executables. Because of that, I could not use a Fortran compiler (LF 64 8.1) that generated 64-bit a.outs, but used a toolchain that included some 32-bit utility programs.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
OK I only have windows so cannot help in detail with your OS but the problem suggests to me that your installation/environment/runtime are not correct. Maybe others can help.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page