--- ia32/bin/ifc.orig Sun Jan 18 17:29:47 2004 +++ ia32/bin/ifc Sun Jan 18 17:34:08 2004 @@ -1,6 +1,9 @@ #!/bin/sh -if [ -z INTEL_LICENSE_FILE ] +ICC_LOCALBASE=%%ICC_LOCALBASE%% +export ICC_LOCALBASE; + +if [ -z "$INTEL_LICENSE_FILE" ] then INTEL_LICENSE_FILE=/licenses; else @@ -8,7 +11,7 @@ fi export INTEL_LICENSE_FILE; -if [ -z LD_LIBRARY_PATH ] +if [ -z "$LD_LIBRARY_PATH" ] then LD_LIBRARY_PATH=/compiler70/ia32/lib; else @@ -16,7 +19,7 @@ fi export LD_LIBRARY_PATH; -if [ -z PATH ] +if [ -z "$PATH" ] then PATH=/compiler70/ia32/bin; else @@ -24,11 +27,31 @@ fi export PATH; -export -n IA32ROOT; unset IA32ROOT; - if [ $# != 0 ] then - exec -a "/compiler70/ia32/bin/ifc" /compiler70/ia32/bin/ifcbin "$@"; + i=0 + argc=$# + while [ $i -lt $argc ] ; do + val1=$1 + shift + val2=${val1#"-openmp"} + if [ ${#val1} -gt ${#val2} ] ; then + echo "Sorry, option '$val1' is not supported on FreeBSD." + exit 1 + fi + val2=${val1#"-par"} + if [ ${#val1} -gt ${#val2} ] ; then + echo "Sorry, option '$val1' is not supported on FreeBSD." + exit 1 + fi + if [ "${val1}" = "-Kpic" ] || [ "${val1}" = "-KPIC" ] || \ + [ "${val1}" = "-fpic" ] || [ "${val1}" = "-fPIC" ] ; then + set -- "$@" "-Qoption,ld,-PIC" + fi + set -- "$@" "$val1" + i=$(($i+1)) + done + exec /compiler70/ia32/bin/ifcbin "$@"; else - exec -a "/compiler70/ia32/bin/ifc" /compiler70/ia32/bin/ifcbin; + exec /compiler70/ia32/bin/ifcbin; fi