Summary: | dev-lang/icc-11.1 ebuild will not allow icpc to compile C++ code | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Adam Stylinski <stylinae> |
Component: | New packages | Assignee: | Andrey Kislyuk (RETIRED) <weaver> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | bicatali, craftyguy, dschridde+gentoobugs, mattst88, timmy |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | AMD64 | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Bug Depends on: | |||
Bug Blocks: | 246516 | ||
Attachments: | emerge --info |
Description
Adam Stylinski
2009-08-20 20:41:42 UTC
Sourcing /etc/profile.d/icc.sh is supposed to take care of the environment. That said, I have committed a revision (-r1) that uses an env.d file as before, instead of a profile.d file. Let me know whether that fixes it for you. (In reply to comment #1) > Sourcing /etc/profile.d/icc.sh is supposed to take care of the environment. > > That said, I have committed a revision (-r1) that uses an env.d file as before, > instead of a profile.d file. Let me know whether that fixes it for you. > Still not working, is there some sort of extra step to use the env.d file? I've considered sourcing it in, don't know how that will mess with my profile, though. (In reply to comment #2) > (In reply to comment #1) > > Sourcing /etc/profile.d/icc.sh is supposed to take care of the environment. > > > > That said, I have committed a revision (-r1) that uses an env.d file as before, > > instead of a profile.d file. Let me know whether that fixes it for you. > > > > Still not working, is there some sort of extra step to use the env.d file? > I've considered sourcing it in, don't know how that will mess with my profile, > though. > Actually I'm fairly certain that env file may have broken something in LD_PATH as I'm getting the notorious sandbox error since I tried -r1 (ERROR: ld.so: object 'libsandbox.so' from LD_PRELOAD cannot be preloaded) Keywords removed until we can resolve this. Appreciate any help. Just remove the LD_PRELOAD line from /etc/env.d/05icc. The root cause of the problem is that icc/icpc interrogates gcc about the location of its headers and libraries, but then prepends '/usr' to paths reported by gcc for no reason I can track down. That results in the following failed syscall: stat("/usr/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.1/include/g++-v4", 0x7fff60195280) = -1 ENOENT (No such file or directory) If I create a symlink /usr/usr -> /usr, the compiler works. However that's not an acceptable workaround to use in the tree. The following contents can be added to icpc.cfg to avoid the problem: -nostdinc++ -isystem/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.1/include/g++-v4 -isystem/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.1/include/g++-v4/x86_64-pc-linux-gnu -isystem/usr/lib/gcc/x86_64-pc-linux-gnu/4.4.1/include/g++-v4/backward However, this solution requires a maintenance overhead as it will change with every GCC version. I have committed a revision (-r2) that includes the options above in icpc.cfg. This fixes the problems on amd64 native compiling. However icpc still has problems with headers on x86. Any help tracking down the solution on x86 is appreciated. Re-added ~amd64 keyword but not ~x86 I have just upgraded from 11.0 to the r2 ebuild, and there is still a major path issue. I am getting errors about a missing 'libintlc.so.5'. Sourcing /etc/profile fixes the issue in the current shell, but any applications that were compiled with ICC (python, etc) bomb with the same missing lib error. You must have LD_LIBRARY_PATH=/opt/intel/Compiler/11.1/046/lib/intel64 set in the shell where you want to run dynamically linked Intel stuff. If you can't ensure that, copying its contents to /usr/lib might work but that's probably an unacceptably bad hack so it won't go into the ebuild. How did you manage to compile Python with this icc? It doesn't compile for me. How does it work with the 11.0.X, but break in 11.1.X? I had no problems compiling python with ICC. I even followed the ICC article on gentoo-wiki (http://www.gentoo-wiki.info/HOWTO_ICC_and_Portage) Python is even listed as one of the apps that works well with ICC. Only downside is now I've lost any apps that depend on python (emerge, etc) since invoking them launches python in a different shell that doesn't seem to source /etc/profile for some reason. (In reply to comment #11) Please post your emerge --info. (In reply to comment #11) > How does it work with the 11.0.X, but break in 11.1.X? The 11.0.x ebuild set LDPATH. Please try setting LDPATH to the same value as LD_LIBRARY_PATH in /etc/env.d/05icc and let me know if that makes a difference. Intel's script only sets LD_LIBRARY_PATH. (In reply to comment #13) Setting LDPATH in /etc/env.d/05icc doesn't seem to make any difference. I've attached my emerge --info above. Created attachment 202411 [details]
emerge --info
emerge --info
'emerge' breaks when it cannot find libintlc.so.5, despite sourcing /etc/profile
(In reply to comment #14) > Setting LDPATH in /etc/env.d/05icc doesn't seem to make any difference. > I've attached my emerge --info above. > Did you run env-update after adding LDPATH? Check if the lib path is in /etc/ld.so.conf. Yes I tried running env-update. I've since reverted back to the previous version of ICC, since I could not afford to have the system in limbo as I tried to work out the issues with this newer version. 11.1.056 compiles c++ fine. Could someone check? If it still fails, link your "gcc-config -X" to /usr/include/c++/<gcc-version>, test and report. Thanks (In reply to comment #18) > 11.1.056 compiles c++ fine. Could someone check? Is this bug still valid? Sorry, completely forgot about this bug. Yes, it's fixed. |