Commit 4a0b6d6c authored by Ian Lynagh's avatar Ian Lynagh

Pass the location of gcc in the ghc wrapper script; partially fixes #3863

This means we don't rely on baking a path to gcc into the executable
parent 1de47f21
......@@ -62,8 +62,13 @@ dnl ** Find the path to sed **
AC_PATH_PROG(SedCmd,sed)
#
dnl ** How to invoke cpp directly **
dnl ** How to invoke gcc/cpp **
#
FP_ARG_WITH_PATH_GNU_PROG([CC], [gcc])
export CC
WhatGccIsCalled="$CC"
AC_SUBST(WhatGccIsCalled)
FP_HAVE_GCC
AC_PROG_CPP
......
exec "$executablename" -B"$topdir" ${1+"$@"}
exec "$executablename" -B"$topdir" -pgmc "$pgmgcc" ${1+"$@"}
......@@ -40,6 +40,7 @@ $$(INPLACE_BIN)/$$($1_$2_PROG): $$($1_$2_INPLACE)
echo 'datadir="$$(TOP)/$$(INPLACE_LIB)"' >> $$@
echo 'bindir="$$(TOP)/$$(INPLACE_BIN)"' >> $$@
echo 'topdir="$$(TOP)/$$(INPLACE_TOPDIR)"' >> $$@
echo 'pgmgcc="$$(WhatGccIsCalled)"' >> $$@
$$($1_$2_SHELL_WRAPPER_EXTRA)
$$($1_$2_INPLACE_SHELL_WRAPPER_EXTRA)
cat $$($1_$2_SHELL_WRAPPER_NAME) >> $$@
......@@ -71,6 +72,7 @@ install_$1_$2_wrapper:
echo 'datadir="$$(datadir)"' >> "$$(WRAPPER)"
echo 'bindir="$$(bindir)"' >> "$$(WRAPPER)"
echo 'topdir="$$(topdir)"' >> "$$(WRAPPER)"
echo 'pgmgcc="$$(WhatGccIsCalled)"' >> "$$(WRAPPER)"
$$($1_$2_SHELL_WRAPPER_EXTRA)
$$($1_$2_INSTALL_SHELL_WRAPPER_EXTRA)
cat $$($1_$2_SHELL_WRAPPER_NAME) >> "$$(WRAPPER)"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment