Boost logo

Boost-Build :

From: Martin Wille (mw8329_at_[hidden])
Date: 2005-10-09 15:59:16


Martin Wille wrote:
> Rene Rivera wrote:
>
>
>>>Summary: can't compile with intel-linux (icc 8)
>>>Bug #: 1105342
>>> <http://sourceforge.net/tracker/index.php?func=detail&aid=1105342&group_id=7586&atid=107586>
>>
>>
>>Dave, Volodya, me, or anyone who has intel-8 on Linux installed (I don't
>>but I could install it).
>
>
> I'm working on this one.

The attached patch adds support for intel 8.0 and intel 9.0 in build.sh.
This implies support for intel 8.1 (which gets installed in the same
directory as intel 8.0). Additionally, the patch makes build.sh set
LD_RUN_PATH to icc's lib directory. Without that, the runtime linker
bjam will be unable to find icc's shared libraries if ld.so.conf doesn't
have an entry for that directory (iccvars.sh does not set LD_RUN_PATH,
the icc installer does not touch ld.so.conf, and bjam does get linked
against shared libraries in icc's lib directory).

The attached patch adds #including of unistd.h on Linux for two files.
(icc reported unistd.h symbols as being declared implicitly. Other
symbols are still implicitly declared.)

I was unable to reproduce the problem described by the original poster.
It might be related to an older version of icc8 or to a problem with the
OP's installation.

I've tested the patch against icc 8.0, icc 8.1 and icc 9.0.

Regards,
m
 --------------060709020105040504040001 Content-Type: text/plain;
name="jam_src.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="jam_src.diff"

Index: build.sh
===================================================================
RCS file: /cvsroot/boost/boost/tools/build/jam_src/build.sh,v
retrieving revision 1.34.2.2
diff -u -r1.34.2.2 build.sh
--- build.sh 8 Sep 2005 22:04:43 -0000 1.34.2.2
+++ build.sh 9 Oct 2005 20:46:00 -0000
@@ -68,6 +68,12 @@
elif test_path qcc ; then BOOST_JAM_TOOLSET=qcc
elif test_path gcc ; then BOOST_JAM_TOOLSET=gcc
elif test_path icc ; then BOOST_JAM_TOOLSET=intel-linux
+ elif test -r /opt/intel/cc/9.0/bin/iccvars.sh ; then
+ BOOST_JAM_TOOLSET=intel-linux
+ BOOST_JAM_TOOLSET_ROOT=/opt/intel/cc/9.0
+ elif test -r /opt/intel_cc_80/bin/iccvars.sh ; then
+ BOOST_JAM_TOOLSET=intel-linux
+ BOOST_JAM_TOOLSET_ROOT=/opt/intel_cc_80
elif test -r /opt/intel/compiler70/ia32/bin/iccvars.sh ; then
BOOST_JAM_TOOLSET=intel-linux
BOOST_JAM_TOOLSET_ROOT=/opt/intel/compiler70/ia32/
@@ -118,7 +124,11 @@
;;

intel-linux)
- if test -r /opt/intel/compiler70/ia32/bin/iccvars.sh ; then
+ if test -r /opt/intel/cc/9.0/bin/iccvars.sh ; then
+ BOOST_JAM_TOOLSET_ROOT=/opt/intel/cc/9.0/
+ elif test -r /opt/intel_cc_80/bin/iccvars.sh ; then
+ BOOST_JAM_TOOLSET_ROOT=/opt/intel_cc_80/
+ elif test -r /opt/intel/compiler70/ia32/bin/iccvars.sh ; then
BOOST_JAM_TOOLSET_ROOT=/opt/intel/compiler70/ia32/
elif test -r /opt/intel/compiler60/ia32/bin/iccvars.sh ; then
BOOST_JAM_TOOLSET_ROOT=/opt/intel/compiler60/ia32/
@@ -126,6 +136,17 @@
BOOST_JAM_TOOLSET_ROOT=/opt/intel/compiler50/ia32/
fi
if test -r ${BOOST_JAM_TOOLSET_ROOT}bin/iccvars.sh ; then
+ # iccvars doesn't change LD_RUN_PATH. We adjust LD_RUN_PATH
+ # here in order not to have to rely on ld.so.conf knowing the
+ # icc library directory. We do this before running iccvars.sh
+ # in order to allow a user to add modifications to LD_RUN_PATH
+ # in iccvars.sh.
+ if test -z "${LD_RUN_PATH}"; then
+ LD_RUN_PATH="${BOOST_JAM_TOOLSET_ROOT}lib"
+ else
+ LD_RUN_PATH="${BOOST_JAM_TOOLSET_ROOT}lib:${LD_RUN_PATH}"
+ fi
+ export LD_RUN_PATH
. ${BOOST_JAM_TOOLSET_ROOT}bin/iccvars.sh
fi
BOOST_JAM_CC=icc
Index: execunix.c
===================================================================
RCS file: /cvsroot/boost/boost/tools/build/jam_src/execunix.c,v
retrieving revision 1.6
diff -u -r1.6 execunix.c
--- execunix.c 12 Feb 2005 02:30:17 -0000 1.6
+++ execunix.c 9 Oct 2005 20:46:00 -0000
@@ -10,7 +10,7 @@
# include <errno.h>
# include <time.h>

-#if defined(sun) || defined(__sun)
+#if defined(sun) || defined(__sun) || defined(linux)
#include <unistd.h> /* need to include unistd.h on sun for the vfork prototype*/
#include <wait.h>
#endif
Index: fileunix.c
===================================================================
RCS file: /cvsroot/boost/boost/tools/build/jam_src/fileunix.c,v
retrieving revision 1.13
diff -u -r1.13 fileunix.c
--- fileunix.c 22 Dec 2004 07:33:12 -0000 1.13
+++ fileunix.c 9 Oct 2005 20:46:00 -0000
@@ -16,7 +16,7 @@
# include "pathsys.h"
# include <stdio.h>

-#if defined(sun) || defined(__sun)
+#if defined(sun) || defined(__sun) || defined(linux)
# include <unistd.h> /* needed for read and close prototype */
#endif

 --------------060709020105040504040001--


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk