Skip to content

Commit

Permalink
config-ml.in: Pass FFLAGS and ADAFLAGS for multilibs, handle F77 like…
Browse files Browse the repository at this point in the history
… CC.

	* config-ml.in: Pass FFLAGS and ADAFLAGS for multilibs, handle F77
	like CC.

Co-Authored-By: James E Wilson <wilson@specifixinc.com>

From-SVN: r82465
  • Loading branch information
ajaeger authored and Andreas Jaeger committed May 30, 2004
1 parent b3dd9f3 commit 78dd5e3
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 2 deletions.
6 changes: 6 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2004-05-30 Andreas Jaeger <aj@suse.de>
Jim Wilson <wilson@specifixinc.com>

* config-ml.in: Pass FFLAGS and ADAFLAGS for multilibs, handle F77
like CC.

2004-05-27 Daniel Jacobowitz <dan@debian.org>

* configure.in: Fix sed invocation for GFORTRAN_FOR_TARGET.
Expand Down
19 changes: 17 additions & 2 deletions config-ml.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Configure fragment invoked in the post-target section for subdirs
# wanting multilib support.
#
# Copyright (C) 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003
# Copyright (C) 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
# Free Software Foundation, Inc.
#
# This file is free software; you can redistribute it and/or modify
Expand Down Expand Up @@ -546,6 +546,8 @@ multi-do:
flags=`echo $$i | sed -e 's/^[^;]*;//' -e 's/@/ -/g'`; \
if (cd ../$${dir}/$${lib}; $(MAKE) $(FLAGS_TO_PASS) \
CFLAGS="$(CFLAGS) $${flags}" \
FFLAGS="$(FFLAGS) $${flags}" \
ADAFLAGS="$(ADAFLAGS) $${flags}" \
prefix="$(prefix)" \
exec_prefix="$(exec_prefix)" \
GCJFLAGS="$(GCJFLAGS) $${flags}" \
Expand Down Expand Up @@ -777,11 +779,12 @@ if [ -n "${multidirs}" ] && [ -z "${ml_norecursion}" ]; then
break
fi
done
ml_config_env='CC="${CC_}$flags" CXX="${CXX_}$flags" GCJ="${GCJ_}$flags"'
ml_config_env='CC="${CC_}$flags" CXX="${CXX_}$flags" F77="${F77_}$flags" GCJ="${GCJ_}$flags"'

if [ "${with_target_subdir}" = "." ]; then
CC_=$CC' '
CXX_=$CXX' '
F77_=$F77' '
GCJ_=$GCJ' '
else
# Create a regular expression that matches any string as long
Expand Down Expand Up @@ -811,6 +814,18 @@ if [ -n "${multidirs}" ] && [ -z "${ml_norecursion}" ]; then
esac
done

F77_=
for arg in ${F77}; do
case $arg in
-[BIL]"${ML_POPDIR}"/*)
F77_="${F77_}"`echo "X${arg}" | sed -n "s/X\\(-[BIL]${popdir_rx}\\).*/\\1/p"`/${ml_dir}`echo "X${arg}" | sed -n "s/X-[BIL]${popdir_rx}\\(.*\\)/\\1/p"`' ' ;;
"${ML_POPDIR}"/*)
F77_="${F77_}"`echo "X${arg}" | sed -n "s/X\\(${popdir_rx}\\).*/\\1/p"`/${ml_dir}`echo "X${arg}" | sed -n "s/X${popdir_rx}\\(.*\\)/\\1/p"`' ' ;;
*)
F77_="${F77_}${arg} " ;;
esac
done

GCJ_=
for arg in ${GCJ}; do
case $arg in
Expand Down

0 comments on commit 78dd5e3

Please sign in to comment.