Darwin, configury : Allow for specification and detection of dsymutil.
In order to enable DWARF versions > 2 we need a sufficiently modern version of dsymutil (in addition to the assembler / linker). This allows the user to configure a different path from the installed one. In addition, there are several sources of dsymutil so we differentiate these in order to be get accurate version information. Backported from commits3b5e8ee4f1
andb019b28ebd
Signed-off-by: Iain Sandoe <iain@sandoe.co.uk> gcc/ChangeLog: * configure.ac: Handle --with-dsymutil in the same way as we do for the assembler and linker. (DEFAULT_DSYMUTIL): New. Extract the type and version for the dsymutil configured or found by the default searches. * config.in: Regenerated. * configure: Regenerated. * collect2.c (do_dsymutil): Handle locating dsymutil in the same way as for the assembler and linker. * config/darwin.h (DSYMUTIL): Delete. * gcc.c: Report a configured dsymutil correctly. * exec-tool.in: Allow for dsymutil. * doc/install.texi: Document --with-dsymutil. ChangeLog: * Makefile.def: Add dsymutil defs. * Makefile.in: Regenerated. * Makefile.tpl: Add dsymutil to flags. * configure: Regenerated. * configure.ac: Add dsymutil to target and build recipes.
This commit is contained in:
parent
558cdc29cd
commit
c7c9940788
|
@ -283,6 +283,7 @@ flags_to_pass = { flag= CFLAGS_FOR_TARGET ; };
|
|||
flags_to_pass = { flag= CPPFLAGS_FOR_TARGET ; };
|
||||
flags_to_pass = { flag= CXXFLAGS_FOR_TARGET ; };
|
||||
flags_to_pass = { flag= DLLTOOL_FOR_TARGET ; };
|
||||
flags_to_pass = { flag= DSYMUTIL_FOR_TARGET ; };
|
||||
flags_to_pass = { flag= FLAGS_FOR_TARGET ; };
|
||||
flags_to_pass = { flag= GFORTRAN_FOR_TARGET ; };
|
||||
flags_to_pass = { flag= GOC_FOR_TARGET ; };
|
||||
|
|
10
Makefile.in
10
Makefile.in
|
@ -162,6 +162,7 @@ BUILD_EXPORTS = \
|
|||
GDC="$(GDC_FOR_BUILD)"; export GDC; \
|
||||
GDCFLAGS="$(GDCFLAGS_FOR_BUILD)"; export GDCFLAGS; \
|
||||
DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
|
||||
DSYMUTIL="$(DSYMUTIL_FOR_BUILD)"; export DSYMUTIL; \
|
||||
LD="$(LD_FOR_BUILD)"; export LD; \
|
||||
LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
|
||||
NM="$(NM_FOR_BUILD)"; export NM; \
|
||||
|
@ -203,6 +204,7 @@ HOST_EXPORTS = \
|
|||
CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
|
||||
CXX_FOR_BUILD="$(CXX_FOR_BUILD)"; export CXX_FOR_BUILD; \
|
||||
DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
|
||||
DSYMUTIL="$(DSYMUTIL)"; export DSYMUTIL; \
|
||||
LD="$(LD)"; export LD; \
|
||||
LDFLAGS="$(STAGE1_LDFLAGS) $(LDFLAGS)"; export LDFLAGS; \
|
||||
NM="$(NM)"; export NM; \
|
||||
|
@ -215,6 +217,7 @@ HOST_EXPORTS = \
|
|||
READELF="$(READELF)"; export READELF; \
|
||||
AR_FOR_TARGET="$(AR_FOR_TARGET)"; export AR_FOR_TARGET; \
|
||||
AS_FOR_TARGET="$(AS_FOR_TARGET)"; export AS_FOR_TARGET; \
|
||||
DSYMUTIL_FOR_TARGET="$(DSYMUTIL_FOR_TARGET)"; export DSYMUTIL_FOR_TARGET; \
|
||||
GCC_FOR_TARGET="$(GCC_FOR_TARGET)"; export GCC_FOR_TARGET; \
|
||||
LD_FOR_TARGET="$(LD_FOR_TARGET)"; export LD_FOR_TARGET; \
|
||||
NM_FOR_TARGET="$(NM_FOR_TARGET)"; export NM_FOR_TARGET; \
|
||||
|
@ -297,6 +300,7 @@ BASE_TARGET_EXPORTS = \
|
|||
GOC="$(GOC_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export GOC; \
|
||||
GDC="$(GDC_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export GDC; \
|
||||
DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
|
||||
DSYMUTIL="$(DSYMUTIL_FOR_TARGET)"; export DSYMUTIL; \
|
||||
LD="$(COMPILER_LD_FOR_TARGET)"; export LD; \
|
||||
LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
|
||||
LIPO="$(LIPO_FOR_TARGET)"; export LIPO; \
|
||||
|
@ -359,6 +363,7 @@ CFLAGS_FOR_BUILD = @CFLAGS_FOR_BUILD@
|
|||
CXXFLAGS_FOR_BUILD = @CXXFLAGS_FOR_BUILD@
|
||||
CXX_FOR_BUILD = @CXX_FOR_BUILD@
|
||||
DLLTOOL_FOR_BUILD = @DLLTOOL_FOR_BUILD@
|
||||
DSYMUTIL_FOR_BUILD = @DSYMUTIL_FOR_BUILD@
|
||||
GFORTRAN_FOR_BUILD = @GFORTRAN_FOR_BUILD@
|
||||
GOC_FOR_BUILD = @GOC_FOR_BUILD@
|
||||
GDC_FOR_BUILD = @GDC_FOR_BUILD@
|
||||
|
@ -409,6 +414,7 @@ AR_FLAGS = rc
|
|||
CC = @CC@
|
||||
CXX = @CXX@
|
||||
DLLTOOL = @DLLTOOL@
|
||||
DSYMUTIL = @DSYMUTIL@
|
||||
LD = @LD@
|
||||
LIPO = @LIPO@
|
||||
NM = @NM@
|
||||
|
@ -599,6 +605,7 @@ GFORTRAN_FOR_TARGET=$(STAGE_CC_WRAPPER) @GFORTRAN_FOR_TARGET@
|
|||
GOC_FOR_TARGET=$(STAGE_CC_WRAPPER) @GOC_FOR_TARGET@
|
||||
GDC_FOR_TARGET=$(STAGE_CC_WRAPPER) @GDC_FOR_TARGET@
|
||||
DLLTOOL_FOR_TARGET=@DLLTOOL_FOR_TARGET@
|
||||
DSYMUTIL_FOR_TARGET=@DSYMUTIL_FOR_TARGET@
|
||||
LD_FOR_TARGET=@LD_FOR_TARGET@
|
||||
|
||||
LIPO_FOR_TARGET=@LIPO_FOR_TARGET@
|
||||
|
@ -817,6 +824,7 @@ BASE_FLAGS_TO_PASS = \
|
|||
"CPPFLAGS_FOR_TARGET=$(CPPFLAGS_FOR_TARGET)" \
|
||||
"CXXFLAGS_FOR_TARGET=$(CXXFLAGS_FOR_TARGET)" \
|
||||
"DLLTOOL_FOR_TARGET=$(DLLTOOL_FOR_TARGET)" \
|
||||
"DSYMUTIL_FOR_TARGET=$(DSYMUTIL_FOR_TARGET)" \
|
||||
"FLAGS_FOR_TARGET=$(FLAGS_FOR_TARGET)" \
|
||||
"GFORTRAN_FOR_TARGET=$(GFORTRAN_FOR_TARGET)" \
|
||||
"GOC_FOR_TARGET=$(GOC_FOR_TARGET)" \
|
||||
|
@ -892,6 +900,7 @@ EXTRA_HOST_FLAGS = \
|
|||
'CC=$(CC)' \
|
||||
'CXX=$(CXX)' \
|
||||
'DLLTOOL=$(DLLTOOL)' \
|
||||
'DSYMUTIL=$(DSYMUTIL)' \
|
||||
'GFORTRAN=$(GFORTRAN)' \
|
||||
'GOC=$(GOC)' \
|
||||
'GDC=$(GDC)' \
|
||||
|
@ -950,6 +959,7 @@ EXTRA_TARGET_FLAGS = \
|
|||
$$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
|
||||
'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
|
||||
'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
|
||||
'DSYMUTIL=$$(DSYMUTIL_FOR_TARGET)' \
|
||||
'GFORTRAN=$$(GFORTRAN_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
|
||||
'GOC=$$(GOC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
|
||||
'GOCFLAGS=$$(GOCFLAGS_FOR_TARGET)' \
|
||||
|
|
|
@ -165,6 +165,7 @@ BUILD_EXPORTS = \
|
|||
GDC="$(GDC_FOR_BUILD)"; export GDC; \
|
||||
GDCFLAGS="$(GDCFLAGS_FOR_BUILD)"; export GDCFLAGS; \
|
||||
DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
|
||||
DSYMUTIL="$(DSYMUTIL_FOR_BUILD)"; export DSYMUTIL; \
|
||||
LD="$(LD_FOR_BUILD)"; export LD; \
|
||||
LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
|
||||
NM="$(NM_FOR_BUILD)"; export NM; \
|
||||
|
@ -206,6 +207,7 @@ HOST_EXPORTS = \
|
|||
CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
|
||||
CXX_FOR_BUILD="$(CXX_FOR_BUILD)"; export CXX_FOR_BUILD; \
|
||||
DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
|
||||
DSYMUTIL="$(DSYMUTIL)"; export DSYMUTIL; \
|
||||
LD="$(LD)"; export LD; \
|
||||
LDFLAGS="$(STAGE1_LDFLAGS) $(LDFLAGS)"; export LDFLAGS; \
|
||||
NM="$(NM)"; export NM; \
|
||||
|
@ -218,6 +220,7 @@ HOST_EXPORTS = \
|
|||
READELF="$(READELF)"; export READELF; \
|
||||
AR_FOR_TARGET="$(AR_FOR_TARGET)"; export AR_FOR_TARGET; \
|
||||
AS_FOR_TARGET="$(AS_FOR_TARGET)"; export AS_FOR_TARGET; \
|
||||
DSYMUTIL_FOR_TARGET="$(DSYMUTIL_FOR_TARGET)"; export DSYMUTIL_FOR_TARGET; \
|
||||
GCC_FOR_TARGET="$(GCC_FOR_TARGET)"; export GCC_FOR_TARGET; \
|
||||
LD_FOR_TARGET="$(LD_FOR_TARGET)"; export LD_FOR_TARGET; \
|
||||
NM_FOR_TARGET="$(NM_FOR_TARGET)"; export NM_FOR_TARGET; \
|
||||
|
@ -300,6 +303,7 @@ BASE_TARGET_EXPORTS = \
|
|||
GOC="$(GOC_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export GOC; \
|
||||
GDC="$(GDC_FOR_TARGET) $(XGCC_FLAGS_FOR_TARGET) $$TFLAGS"; export GDC; \
|
||||
DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
|
||||
DSYMUTIL="$(DSYMUTIL_FOR_TARGET)"; export DSYMUTIL; \
|
||||
LD="$(COMPILER_LD_FOR_TARGET)"; export LD; \
|
||||
LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
|
||||
LIPO="$(LIPO_FOR_TARGET)"; export LIPO; \
|
||||
|
@ -362,6 +366,7 @@ CFLAGS_FOR_BUILD = @CFLAGS_FOR_BUILD@
|
|||
CXXFLAGS_FOR_BUILD = @CXXFLAGS_FOR_BUILD@
|
||||
CXX_FOR_BUILD = @CXX_FOR_BUILD@
|
||||
DLLTOOL_FOR_BUILD = @DLLTOOL_FOR_BUILD@
|
||||
DSYMUTIL_FOR_BUILD = @DSYMUTIL_FOR_BUILD@
|
||||
GFORTRAN_FOR_BUILD = @GFORTRAN_FOR_BUILD@
|
||||
GOC_FOR_BUILD = @GOC_FOR_BUILD@
|
||||
GDC_FOR_BUILD = @GDC_FOR_BUILD@
|
||||
|
@ -412,6 +417,7 @@ AR_FLAGS = rc
|
|||
CC = @CC@
|
||||
CXX = @CXX@
|
||||
DLLTOOL = @DLLTOOL@
|
||||
DSYMUTIL = @DSYMUTIL@
|
||||
LD = @LD@
|
||||
LIPO = @LIPO@
|
||||
NM = @NM@
|
||||
|
@ -522,6 +528,7 @@ GFORTRAN_FOR_TARGET=$(STAGE_CC_WRAPPER) @GFORTRAN_FOR_TARGET@
|
|||
GOC_FOR_TARGET=$(STAGE_CC_WRAPPER) @GOC_FOR_TARGET@
|
||||
GDC_FOR_TARGET=$(STAGE_CC_WRAPPER) @GDC_FOR_TARGET@
|
||||
DLLTOOL_FOR_TARGET=@DLLTOOL_FOR_TARGET@
|
||||
DSYMUTIL_FOR_TARGET=@DSYMUTIL_FOR_TARGET@
|
||||
LD_FOR_TARGET=@LD_FOR_TARGET@
|
||||
|
||||
LIPO_FOR_TARGET=@LIPO_FOR_TARGET@
|
||||
|
@ -647,6 +654,7 @@ EXTRA_HOST_FLAGS = \
|
|||
'CC=$(CC)' \
|
||||
'CXX=$(CXX)' \
|
||||
'DLLTOOL=$(DLLTOOL)' \
|
||||
'DSYMUTIL=$(DSYMUTIL)' \
|
||||
'GFORTRAN=$(GFORTRAN)' \
|
||||
'GOC=$(GOC)' \
|
||||
'GDC=$(GDC)' \
|
||||
|
@ -705,6 +713,7 @@ EXTRA_TARGET_FLAGS = \
|
|||
$$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
|
||||
'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
|
||||
'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
|
||||
'DSYMUTIL=$$(DSYMUTIL_FOR_TARGET)' \
|
||||
'GFORTRAN=$$(GFORTRAN_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
|
||||
'GOC=$$(GOC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
|
||||
'GOCFLAGS=$$(GOCFLAGS_FOR_TARGET)' \
|
||||
|
|
|
@ -609,6 +609,7 @@ OBJCOPY_FOR_TARGET
|
|||
NM_FOR_TARGET
|
||||
LIPO_FOR_TARGET
|
||||
LD_FOR_TARGET
|
||||
DSYMUTIL_FOR_TARGET
|
||||
DLLTOOL_FOR_TARGET
|
||||
AS_FOR_TARGET
|
||||
AR_FOR_TARGET
|
||||
|
@ -629,6 +630,7 @@ RANLIB
|
|||
NM
|
||||
LIPO
|
||||
LD
|
||||
DSYMUTIL
|
||||
DLLTOOL
|
||||
AS
|
||||
AR
|
||||
|
@ -649,6 +651,7 @@ LDFLAGS_FOR_BUILD
|
|||
GDC_FOR_BUILD
|
||||
GOC_FOR_BUILD
|
||||
GFORTRAN_FOR_BUILD
|
||||
DSYMUTIL_FOR_BUILD
|
||||
DLLTOOL_FOR_BUILD
|
||||
CXX_FOR_BUILD
|
||||
CXXFLAGS_FOR_BUILD
|
||||
|
@ -851,6 +854,7 @@ target_configargs
|
|||
AR
|
||||
AS
|
||||
DLLTOOL
|
||||
DSYMUTIL
|
||||
LD
|
||||
LIPO
|
||||
NM
|
||||
|
@ -871,6 +875,7 @@ GDC_FOR_TARGET
|
|||
AR_FOR_TARGET
|
||||
AS_FOR_TARGET
|
||||
DLLTOOL_FOR_TARGET
|
||||
DSYMUTIL_FOR_TARGET
|
||||
LD_FOR_TARGET
|
||||
LIPO_FOR_TARGET
|
||||
NM_FOR_TARGET
|
||||
|
@ -1634,6 +1639,7 @@ Some influential environment variables:
|
|||
AR AR for the host
|
||||
AS AS for the host
|
||||
DLLTOOL DLLTOOL for the host
|
||||
DSYMUTIL DSYMUTIL for the host
|
||||
LD LD for the host
|
||||
LIPO LIPO for the host
|
||||
NM NM for the host
|
||||
|
@ -1663,6 +1669,8 @@ Some influential environment variables:
|
|||
AS for the target
|
||||
DLLTOOL_FOR_TARGET
|
||||
DLLTOOL for the target
|
||||
DSYMUTIL_FOR_TARGET
|
||||
DSYMUTIL for the target
|
||||
LD_FOR_TARGET
|
||||
LD for the target
|
||||
LIPO_FOR_TARGET
|
||||
|
@ -4094,6 +4102,7 @@ if test "${build}" != "${host}" ; then
|
|||
AS_FOR_BUILD=${AS_FOR_BUILD-as}
|
||||
CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
|
||||
CXX_FOR_BUILD=${CXX_FOR_BUILD-g++}
|
||||
DSYMUTIL_FOR_BUILD=${DSYMUTIL_FOR_BUILD-dsymutil}
|
||||
GFORTRAN_FOR_BUILD=${GFORTRAN_FOR_BUILD-gfortran}
|
||||
GOC_FOR_BUILD=${GOC_FOR_BUILD-gccgo}
|
||||
GDC_FOR_BUILD=${GDC_FOR_BUILD-gdc}
|
||||
|
@ -4108,6 +4117,7 @@ else
|
|||
AS_FOR_BUILD="\$(AS)"
|
||||
CC_FOR_BUILD="\$(CC)"
|
||||
CXX_FOR_BUILD="\$(CXX)"
|
||||
DSYMUTIL_FOR_BUILD="\$(DSYMUTIL)"
|
||||
GFORTRAN_FOR_BUILD="\$(GFORTRAN)"
|
||||
GOC_FOR_BUILD="\$(GOC)"
|
||||
GDC_FOR_BUILD="\$(GDC)"
|
||||
|
@ -7883,6 +7893,7 @@ done
|
|||
|
||||
|
||||
|
||||
|
||||
# Generate default definitions for YACC, M4, LEX and other programs that run
|
||||
# on the build machine. These are used if the Makefile can't locate these
|
||||
# programs in objdir.
|
||||
|
@ -8715,6 +8726,147 @@ fi
|
|||
|
||||
|
||||
|
||||
if test -n "$DSYMUTIL"; then
|
||||
ac_cv_prog_DSYMUTIL=$DSYMUTIL
|
||||
elif test -n "$ac_cv_prog_DSYMUTIL"; then
|
||||
DSYMUTIL=$ac_cv_prog_DSYMUTIL
|
||||
fi
|
||||
|
||||
if test -n "$ac_cv_prog_DSYMUTIL"; then
|
||||
for ncn_progname in dsymutil; do
|
||||
# Extract the first word of "${ncn_progname}", so it can be a program name with args.
|
||||
set dummy ${ncn_progname}; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_prog_DSYMUTIL+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$DSYMUTIL"; then
|
||||
ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||
ac_cv_prog_DSYMUTIL="${ncn_progname}"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
DSYMUTIL=$ac_cv_prog_DSYMUTIL
|
||||
if test -n "$DSYMUTIL"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
|
||||
$as_echo "$DSYMUTIL" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
done
|
||||
fi
|
||||
|
||||
for ncn_progname in dsymutil; do
|
||||
if test -n "$ncn_tool_prefix"; then
|
||||
# Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
|
||||
set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_prog_DSYMUTIL+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$DSYMUTIL"; then
|
||||
ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||
ac_cv_prog_DSYMUTIL="${ncn_tool_prefix}${ncn_progname}"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
DSYMUTIL=$ac_cv_prog_DSYMUTIL
|
||||
if test -n "$DSYMUTIL"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
|
||||
$as_echo "$DSYMUTIL" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
if test -z "$ac_cv_prog_DSYMUTIL" && test $build = $host ; then
|
||||
# Extract the first word of "${ncn_progname}", so it can be a program name with args.
|
||||
set dummy ${ncn_progname}; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_prog_DSYMUTIL+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$DSYMUTIL"; then
|
||||
ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||
ac_cv_prog_DSYMUTIL="${ncn_progname}"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
DSYMUTIL=$ac_cv_prog_DSYMUTIL
|
||||
if test -n "$DSYMUTIL"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
|
||||
$as_echo "$DSYMUTIL" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
test -n "$ac_cv_prog_DSYMUTIL" && break
|
||||
done
|
||||
|
||||
if test -z "$ac_cv_prog_DSYMUTIL" ; then
|
||||
set dummy dsymutil
|
||||
if test $build = $host ; then
|
||||
DSYMUTIL="$2"
|
||||
else
|
||||
DSYMUTIL="${ncn_tool_prefix}$2"
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
|
||||
if test -n "$LD"; then
|
||||
ac_cv_prog_LD=$LD
|
||||
elif test -n "$ac_cv_prog_LD"; then
|
||||
|
@ -11945,6 +12097,236 @@ fi
|
|||
|
||||
|
||||
|
||||
if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" ; then
|
||||
if test -n "$with_build_time_tools"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for dsymutil in $with_build_time_tools" >&5
|
||||
$as_echo_n "checking for dsymutil in $with_build_time_tools... " >&6; }
|
||||
if test -x $with_build_time_tools/dsymutil; then
|
||||
DSYMUTIL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dsymutil
|
||||
ac_cv_path_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_DSYMUTIL_FOR_TARGET" >&5
|
||||
$as_echo "$ac_cv_path_DSYMUTIL_FOR_TARGET" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
elif test $build != $host && test $have_gcc_for_target = yes; then
|
||||
DSYMUTIL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dsymutil`
|
||||
test $DSYMUTIL_FOR_TARGET = dsymutil && DSYMUTIL_FOR_TARGET=
|
||||
test -n "$DSYMUTIL_FOR_TARGET" && ac_cv_path_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
|
||||
fi
|
||||
fi
|
||||
if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
|
||||
# Extract the first word of "dsymutil", so it can be a program name with args.
|
||||
set dummy dsymutil; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_path_DSYMUTIL_FOR_TARGET+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
case $DSYMUTIL_FOR_TARGET in
|
||||
[\\/]* | ?:[\\/]*)
|
||||
ac_cv_path_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test with a path.
|
||||
;;
|
||||
*)
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $gcc_cv_tool_dirs
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||
ac_cv_path_DSYMUTIL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
DSYMUTIL_FOR_TARGET=$ac_cv_path_DSYMUTIL_FOR_TARGET
|
||||
if test -n "$DSYMUTIL_FOR_TARGET"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
|
||||
$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" ; then
|
||||
|
||||
|
||||
if test -n "$DSYMUTIL_FOR_TARGET"; then
|
||||
ac_cv_prog_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
|
||||
elif test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
|
||||
DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
|
||||
fi
|
||||
|
||||
if test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
|
||||
for ncn_progname in dsymutil; do
|
||||
# Extract the first word of "${ncn_progname}", so it can be a program name with args.
|
||||
set dummy ${ncn_progname}; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$DSYMUTIL_FOR_TARGET"; then
|
||||
ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||
ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_progname}"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
|
||||
if test -n "$DSYMUTIL_FOR_TARGET"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
|
||||
$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
done
|
||||
fi
|
||||
|
||||
if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && test -n "$with_build_time_tools"; then
|
||||
for ncn_progname in dsymutil; do
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
|
||||
$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
|
||||
if test -x $with_build_time_tools/${ncn_progname}; then
|
||||
ac_cv_prog_DSYMUTIL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
|
||||
$as_echo "yes" >&6; }
|
||||
break
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
|
||||
for ncn_progname in dsymutil; do
|
||||
if test -n "$ncn_target_tool_prefix"; then
|
||||
# Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
|
||||
set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$DSYMUTIL_FOR_TARGET"; then
|
||||
ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||
ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
|
||||
if test -n "$DSYMUTIL_FOR_TARGET"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
|
||||
$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && test $build = $target ; then
|
||||
# Extract the first word of "${ncn_progname}", so it can be a program name with args.
|
||||
set dummy ${ncn_progname}; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
if test -n "$DSYMUTIL_FOR_TARGET"; then
|
||||
ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
|
||||
else
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||
ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_progname}"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
fi
|
||||
fi
|
||||
DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
|
||||
if test -n "$DSYMUTIL_FOR_TARGET"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
|
||||
$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && break
|
||||
done
|
||||
fi
|
||||
|
||||
if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" ; then
|
||||
set dummy dsymutil
|
||||
if test $build = $target ; then
|
||||
DSYMUTIL_FOR_TARGET="$2"
|
||||
else
|
||||
DSYMUTIL_FOR_TARGET="${ncn_target_tool_prefix}$2"
|
||||
fi
|
||||
else
|
||||
DSYMUTIL_FOR_TARGET="$ac_cv_prog_DSYMUTIL_FOR_TARGET"
|
||||
fi
|
||||
|
||||
else
|
||||
DSYMUTIL_FOR_TARGET=$ac_cv_path_DSYMUTIL_FOR_TARGET
|
||||
fi
|
||||
|
||||
|
||||
|
||||
|
||||
if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
|
||||
if test -n "$with_build_time_tools"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld in $with_build_time_tools" >&5
|
||||
|
@ -14733,6 +15115,37 @@ $as_echo "pre-installed" >&6; }
|
|||
fi
|
||||
fi
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target dsymutil" >&5
|
||||
$as_echo_n "checking where to find the target dsymutil... " >&6; }
|
||||
if test "x${build}" != "x${host}" ; then
|
||||
if expr "x$DSYMUTIL_FOR_TARGET" : "x/" > /dev/null; then
|
||||
# We already found the complete path
|
||||
ac_dir=`dirname $DSYMUTIL_FOR_TARGET`
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
|
||||
$as_echo "pre-installed in $ac_dir" >&6; }
|
||||
else
|
||||
# Canadian cross, just use what we found
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
|
||||
$as_echo "pre-installed" >&6; }
|
||||
fi
|
||||
else
|
||||
if expr "x$DSYMUTIL_FOR_TARGET" : "x/" > /dev/null; then
|
||||
# We already found the complete path
|
||||
ac_dir=`dirname $DSYMUTIL_FOR_TARGET`
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
|
||||
$as_echo "pre-installed in $ac_dir" >&6; }
|
||||
elif test "x$target" = "x$host"; then
|
||||
# We can use an host tool
|
||||
DSYMUTIL_FOR_TARGET='$(DSYMUTIL)'
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
|
||||
$as_echo "host tool" >&6; }
|
||||
else
|
||||
# We need a cross tool
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
|
||||
$as_echo "pre-installed" >&6; }
|
||||
fi
|
||||
fi
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gcc" >&5
|
||||
$as_echo_n "checking where to find the target gcc... " >&6; }
|
||||
if test "x${build}" != "x${host}" ; then
|
||||
|
|
|
@ -1350,6 +1350,7 @@ if test "${build}" != "${host}" ; then
|
|||
AS_FOR_BUILD=${AS_FOR_BUILD-as}
|
||||
CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
|
||||
CXX_FOR_BUILD=${CXX_FOR_BUILD-g++}
|
||||
DSYMUTIL_FOR_BUILD=${DSYMUTIL_FOR_BUILD-dsymutil}
|
||||
GFORTRAN_FOR_BUILD=${GFORTRAN_FOR_BUILD-gfortran}
|
||||
GOC_FOR_BUILD=${GOC_FOR_BUILD-gccgo}
|
||||
GDC_FOR_BUILD=${GDC_FOR_BUILD-gdc}
|
||||
|
@ -1364,6 +1365,7 @@ else
|
|||
AS_FOR_BUILD="\$(AS)"
|
||||
CC_FOR_BUILD="\$(CC)"
|
||||
CXX_FOR_BUILD="\$(CXX)"
|
||||
DSYMUTIL_FOR_BUILD="\$(DSYMUTIL)"
|
||||
GFORTRAN_FOR_BUILD="\$(GFORTRAN)"
|
||||
GOC_FOR_BUILD="\$(GOC)"
|
||||
GDC_FOR_BUILD="\$(GDC)"
|
||||
|
@ -3378,6 +3380,7 @@ AC_SUBST(CFLAGS_FOR_BUILD)
|
|||
AC_SUBST(CXXFLAGS_FOR_BUILD)
|
||||
AC_SUBST(CXX_FOR_BUILD)
|
||||
AC_SUBST(DLLTOOL_FOR_BUILD)
|
||||
AC_SUBST(DSYMUTIL_FOR_BUILD)
|
||||
AC_SUBST(GFORTRAN_FOR_BUILD)
|
||||
AC_SUBST(GOC_FOR_BUILD)
|
||||
AC_SUBST(GDC_FOR_BUILD)
|
||||
|
@ -3457,6 +3460,7 @@ esac
|
|||
NCN_STRICT_CHECK_TOOLS(AR, ar)
|
||||
NCN_STRICT_CHECK_TOOLS(AS, as)
|
||||
NCN_STRICT_CHECK_TOOLS(DLLTOOL, dlltool)
|
||||
NCN_STRICT_CHECK_TOOLS(DSYMUTIL, dsymutil)
|
||||
NCN_STRICT_CHECK_TOOLS(LD, ld)
|
||||
NCN_STRICT_CHECK_TOOLS(LIPO, lipo)
|
||||
NCN_STRICT_CHECK_TOOLS(NM, nm)
|
||||
|
@ -3496,6 +3500,7 @@ NCN_STRICT_CHECK_TARGET_TOOLS(GDC_FOR_TARGET, gdc)
|
|||
ACX_CHECK_INSTALLED_TARGET_TOOL(AR_FOR_TARGET, ar)
|
||||
ACX_CHECK_INSTALLED_TARGET_TOOL(AS_FOR_TARGET, as)
|
||||
ACX_CHECK_INSTALLED_TARGET_TOOL(DLLTOOL_FOR_TARGET, dlltool)
|
||||
ACX_CHECK_INSTALLED_TARGET_TOOL(DSYMUTIL_FOR_TARGET, dsymutil)
|
||||
ACX_CHECK_INSTALLED_TARGET_TOOL(LD_FOR_TARGET, ld)
|
||||
ACX_CHECK_INSTALLED_TARGET_TOOL(LIPO_FOR_TARGET, lipo)
|
||||
ACX_CHECK_INSTALLED_TARGET_TOOL(NM_FOR_TARGET, nm)
|
||||
|
@ -3521,6 +3526,7 @@ GCC_TARGET_TOOL(c++ for libstdc++, RAW_CXX_FOR_TARGET, CXX,
|
|||
[gcc/xgcc -shared-libgcc -B$$r/$(HOST_SUBDIR)/gcc -nostdinc++ -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
|
||||
c++)
|
||||
GCC_TARGET_TOOL(dlltool, DLLTOOL_FOR_TARGET, DLLTOOL, [binutils/dlltool])
|
||||
GCC_TARGET_TOOL(dsymutil, DSYMUTIL_FOR_TARGET, DSYMUTIL)
|
||||
GCC_TARGET_TOOL(gcc, GCC_FOR_TARGET, , [gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/])
|
||||
GCC_TARGET_TOOL(gfortran, GFORTRAN_FOR_TARGET, GFORTRAN,
|
||||
[gcc/gfortran -B$$r/$(HOST_SUBDIR)/gcc/], fortran)
|
||||
|
|
|
@ -3005,14 +3005,48 @@ process_args (int *argcp, char **argv) {
|
|||
|
||||
static void
|
||||
do_dsymutil (const char *output_file) {
|
||||
const char *dsymutil = DSYMUTIL + 1;
|
||||
const char *dsymutil = 0;
|
||||
struct pex_obj *pex;
|
||||
char **real_argv = XCNEWVEC (char *, 3);
|
||||
char **real_argv = XCNEWVEC (char *, verbose ? 4 : 3);
|
||||
const char ** argv = CONST_CAST2 (const char **, char **,
|
||||
real_argv);
|
||||
/* For cross-builds search the PATH using target-qualified name if we
|
||||
have not already found a suitable dsymutil. In practice, all modern
|
||||
versions of dsymutil handle all supported archs, however the approach
|
||||
here is consistent with the way other installations work (and one can
|
||||
always symlink a multitarget dsymutil with a target-specific name). */
|
||||
const char *dsname = "dsymutil";
|
||||
#ifdef CROSS_DIRECTORY_STRUCTURE
|
||||
const char *qname = concat (target_machine, "-", dsname, NULL);
|
||||
#else
|
||||
const char *qname = dsname;
|
||||
#endif
|
||||
#ifdef DEFAULT_DSYMUTIL
|
||||
/* Configured default takes priority. */
|
||||
if (dsymutil == 0 && access (DEFAULT_DSYMUTIL, X_OK) == 0)
|
||||
dsymutil = DEFAULT_DSYMUTIL;
|
||||
if (dsymutil == 0)
|
||||
#endif
|
||||
#ifdef DSYMUTIL
|
||||
/* Followed by one supplied in the target header, somewhat like the
|
||||
REAL_XX_NAME used elsewhere. */
|
||||
dsymutil = find_a_file (&cpath, DSYMUTIL, X_OK);
|
||||
if (dsymutil == 0)
|
||||
dsymutil = find_a_file (&path, DSYMUTIL, X_OK);
|
||||
if (dsymutil == 0)
|
||||
#endif
|
||||
dsymutil = find_a_file (&cpath, dsname, X_OK);
|
||||
if (dsymutil == 0)
|
||||
dsymutil = find_a_file (&path, qname, X_OK);
|
||||
|
||||
argv[0] = dsymutil;
|
||||
argv[1] = output_file;
|
||||
if (verbose)
|
||||
{
|
||||
argv[2] = "-v";
|
||||
argv[3] = (char *) 0;
|
||||
}
|
||||
else
|
||||
argv[2] = (char *) 0;
|
||||
|
||||
pex = collect_execute (dsymutil, real_argv, NULL, NULL,
|
||||
|
|
|
@ -55,6 +55,12 @@
|
|||
#endif
|
||||
|
||||
|
||||
/* Define to enable the use of a default debug linker. */
|
||||
#ifndef USED_FOR_TARGET
|
||||
#undef DEFAULT_DSYMUTIL
|
||||
#endif
|
||||
|
||||
|
||||
/* Define to enable the use of a default linker. */
|
||||
#ifndef USED_FOR_TARGET
|
||||
#undef DEFAULT_LINKER
|
||||
|
@ -94,6 +100,12 @@
|
|||
#endif
|
||||
|
||||
|
||||
/* Define to the dsymutil version. */
|
||||
#ifndef USED_FOR_TARGET
|
||||
#undef DSYMUTIL_VERSION
|
||||
#endif
|
||||
|
||||
|
||||
/* Define 0/1 if static analyzer feature is enabled. */
|
||||
#ifndef USED_FOR_TARGET
|
||||
#undef ENABLE_ANALYZER
|
||||
|
|
|
@ -240,8 +240,6 @@ extern GTY(()) int darwin_ms_struct;
|
|||
DARWIN_NOCOMPACT_UNWIND \
|
||||
"}}}}}}} %<pie %<no-pie %<rdynamic "
|
||||
|
||||
#define DSYMUTIL "\ndsymutil"
|
||||
|
||||
/* Spec that controls whether the debug linker is run automatically for
|
||||
a link step. This needs to be done if there is a source file on the
|
||||
command line which will result in a temporary object (and debug is
|
||||
|
|
|
@ -719,6 +719,8 @@ thin_archive_support
|
|||
ld_soname_option
|
||||
ld_version_script_option
|
||||
libgcc_visibility
|
||||
ORIGINAL_DSYMUTIL_FOR_TARGET
|
||||
gcc_cv_dsymutil
|
||||
gcc_cv_otool
|
||||
gcc_cv_readelf
|
||||
gcc_cv_objdump
|
||||
|
@ -938,6 +940,7 @@ enable_generated_files_in_srcdir
|
|||
with_gnu_ld
|
||||
with_ld
|
||||
with_demangler_in_ld
|
||||
with_dsymutil
|
||||
with_gnu_as
|
||||
with_as
|
||||
enable_largefile
|
||||
|
@ -1791,6 +1794,8 @@ Optional Packages:
|
|||
--with-gnu-ld arrange to work with GNU ld
|
||||
--with-ld arrange to use the specified ld (full pathname)
|
||||
--with-demangler-in-ld try to use demangler in GNU ld
|
||||
--with-dsymutil arrange to use the specified dsymutil (full
|
||||
pathname)
|
||||
--with-gnu-as arrange to work with GNU as
|
||||
--with-as arrange to use the specified as (full pathname)
|
||||
--with-stabs arrange to use stabs instead of host debug format
|
||||
|
@ -3765,8 +3770,14 @@ fi
|
|||
|
||||
|
||||
case $target in
|
||||
*darwin*) ld64_flag=yes;; # Darwin can only use a ld64-compatible linker.
|
||||
*) ld64_flag=no;;
|
||||
*darwin*)
|
||||
ld64_flag=yes # Darwin can only use a ld64-compatible linker.
|
||||
dsymutil_flag=yes # Darwin uses dsymutil to link debug.
|
||||
;;
|
||||
*)
|
||||
ld64_flag=no
|
||||
dsymutil_flag=no
|
||||
;;
|
||||
esac
|
||||
|
||||
# With pre-defined ld
|
||||
|
@ -3816,6 +3827,40 @@ else
|
|||
fi
|
||||
|
||||
|
||||
# Allow the user to specify a dsymutil executable (used on Darwin only, so far)
|
||||
|
||||
# Check whether --with-dsymutil was given.
|
||||
if test "${with_dsymutil+set}" = set; then :
|
||||
withval=$with_dsymutil; DEFAULT_DSYMUTIL="$with_dsymutil"
|
||||
fi
|
||||
|
||||
|
||||
dsymutil_vers=
|
||||
if test x"${DEFAULT_DSYMUTIL+set}" = x"set"; then
|
||||
if test ! -x "$DEFAULT_DSYMUTIL"; then
|
||||
as_fn_error $? "cannot execute: $DEFAULT_DSYMUTIL: check --with-dsymutil or env. var. DEFAULT_DSYMUTIL" "$LINENO" 5
|
||||
else
|
||||
if dsymutil_vers=`$DEFAULT_DSYMUTIL -v /dev/null 2>&1`; then
|
||||
dsymutil_flag=yes
|
||||
fi
|
||||
fi
|
||||
|
||||
cat >>confdefs.h <<_ACEOF
|
||||
#define DEFAULT_DSYMUTIL "$DEFAULT_DSYMUTIL"
|
||||
_ACEOF
|
||||
|
||||
fi
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a default dsymutil was specified" >&5
|
||||
$as_echo_n "checking whether a default dsymutil was specified... " >&6; }
|
||||
if test x"${DEFAULT_DSYMUTIL+set}" = x"set"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($DEFAULT_DSYMUTIL)" >&5
|
||||
$as_echo "yes ($DEFAULT_DSYMUTIL)" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
# ----------------------
|
||||
# Find default assembler
|
||||
# ----------------------
|
||||
|
@ -19022,7 +19067,7 @@ else
|
|||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 19025 "configure"
|
||||
#line 19070 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
|
@ -19128,7 +19173,7 @@ else
|
|||
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
|
||||
lt_status=$lt_dlunknown
|
||||
cat > conftest.$ac_ext <<_LT_EOF
|
||||
#line 19131 "configure"
|
||||
#line 19176 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
#if HAVE_DLFCN_H
|
||||
|
@ -23036,6 +23081,71 @@ else
|
|||
$as_echo "$gcc_cv_otool" >&6; }
|
||||
fi
|
||||
|
||||
# Figure out the dsymutil we will use.
|
||||
if ${gcc_cv_dsymutil+:} false; then :
|
||||
|
||||
else
|
||||
|
||||
if test -x "$DEFAULT_DSYMUTIL"; then
|
||||
gcc_cv_dsymutil="$DEFAULT_DSYMUTIL"
|
||||
elif test -x dsymutil$build_exeext; then
|
||||
gcc_cv_dsymutil=./dsymutil$build_exeext
|
||||
elif ( set dummy $DSYMUTIL_FOR_TARGET; test -x $2 ); then
|
||||
gcc_cv_dsymutil=$DSYMUTIL_FOR_TARGET
|
||||
elif ( set dummy $DSYMUTIL; test -x $2 ); then
|
||||
gcc_cv_dsymutil=$DSYMUTIL
|
||||
else
|
||||
# Extract the first word of "$DSYMUTIL_FOR_TARGET", so it can be a program name with args.
|
||||
set dummy $DSYMUTIL_FOR_TARGET; ac_word=$2
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
|
||||
$as_echo_n "checking for $ac_word... " >&6; }
|
||||
if ${ac_cv_path_gcc_cv_dsymutil+:} false; then :
|
||||
$as_echo_n "(cached) " >&6
|
||||
else
|
||||
case $gcc_cv_dsymutil in
|
||||
[\\/]* | ?:[\\/]*)
|
||||
ac_cv_path_gcc_cv_dsymutil="$gcc_cv_dsymutil" # Let the user override the test with a path.
|
||||
;;
|
||||
*)
|
||||
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
|
||||
for as_dir in $PATH
|
||||
do
|
||||
IFS=$as_save_IFS
|
||||
test -z "$as_dir" && as_dir=.
|
||||
for ac_exec_ext in '' $ac_executable_extensions; do
|
||||
if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
|
||||
ac_cv_path_gcc_cv_dsymutil="$as_dir/$ac_word$ac_exec_ext"
|
||||
$as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
|
||||
break 2
|
||||
fi
|
||||
done
|
||||
done
|
||||
IFS=$as_save_IFS
|
||||
|
||||
;;
|
||||
esac
|
||||
fi
|
||||
gcc_cv_dsymutil=$ac_cv_path_gcc_cv_dsymutil
|
||||
if test -n "$gcc_cv_dsymutil"; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_dsymutil" >&5
|
||||
$as_echo "$gcc_cv_dsymutil" >&6; }
|
||||
else
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
|
||||
$as_echo "no" >&6; }
|
||||
fi
|
||||
|
||||
|
||||
fi
|
||||
fi
|
||||
|
||||
ORIGINAL_DSYMUTIL_FOR_TARGET=$gcc_cv_dsymutil
|
||||
|
||||
case "$ORIGINAL_DSYMUTIL_FOR_TARGET" in
|
||||
./dsymutil | ./dsymutil$build_exeext) ;;
|
||||
*) ac_config_files="$ac_config_files dsymutil:exec-tool.in"
|
||||
;;
|
||||
esac
|
||||
|
||||
# Figure out what assembler alignment features are present.
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler flags" >&5
|
||||
$as_echo_n "checking assembler flags... " >&6; }
|
||||
|
@ -29276,6 +29386,100 @@ _ACEOF
|
|||
|
||||
fi
|
||||
|
||||
if test x"$dsymutil_flag" = x"yes"; then
|
||||
|
||||
# If the user specified a dsymutil path, then we will already have the
|
||||
# version string, otherwise, pick it up.
|
||||
if test x"$gcc_cv_dsymutil" = x; then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: dsymutil is a required tool for this system, but not found" >&5
|
||||
$as_echo "$as_me: WARNING: dsymutil is a required tool for this system, but not found" >&2;}
|
||||
dsymutil_vers="tool unspecified"
|
||||
elif test x"$dsymutil_vers" = x; then
|
||||
dsymutil_vers=`$gcc_cv_dsymutil -v /dev/null 2>&1`
|
||||
fi
|
||||
|
||||
dsymutil_temp=`echo $dsymutil_vers | sed 1q`
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dsymutil version \"$dsymutil_temp\"" >&5
|
||||
$as_echo_n "checking dsymutil version \"$dsymutil_temp\"... " >&6; }
|
||||
if echo $dsymutil_temp | grep dwarfutils- > /dev/null; then
|
||||
dsymutil_kind=DWARFUTILS
|
||||
dsymutil_vers=`echo $dsymutil_temp | sed 's/.*dwarfutils-\([0-9\.]*\).*/\1/'`
|
||||
elif echo $dsymutil_temp | grep clang- > /dev/null; then
|
||||
dsymutil_kind=CLANG
|
||||
dsymutil_vers=`echo $dsymutil_temp | sed 's/.*clang-\([0-9\.]*\).*/\1/'`
|
||||
elif echo $dsymutil_temp | grep 'LLVM version ' > /dev/null; then
|
||||
dsymutil_kind=LLVM
|
||||
dsymutil_vers=`echo $dsymutil_temp | sed 's/.*LLVM\ version\ \([0-9\.]*\).*/\1/'`
|
||||
else
|
||||
dsymutil_kind=UNKNOWN
|
||||
dsymutil_vers="0.0"
|
||||
fi
|
||||
dsymutil_major=`expr "$dsymutil_vers" : '\([0-9]*\)'`
|
||||
dsymutil_minor=`expr "$dsymutil_vers" : '[0-9]*\.\([0-9]*\)'`
|
||||
dsymutil_tiny=`expr "$dsymutil_vers" : '[0-9]*\.[0-9]*\.\([0-9]*\)'`
|
||||
if test x"${dsymutil_minor}" = x; then
|
||||
dsymutil_minor=0
|
||||
fi
|
||||
if test x"${dsymutil_tiny}" = x; then
|
||||
dsymutil_tiny=0
|
||||
fi
|
||||
|
||||
cat >>confdefs.h <<_ACEOF
|
||||
#define DSYMUTIL_VERSION $dsymutil_kind,${dsymutil_major},${dsymutil_minor},${dsymutil_tiny}
|
||||
_ACEOF
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dsymutil_vers : $dsymutil_kind ${dsymutil_major} ${dsymutil_minor} ${dsymutil_tiny} " >&5
|
||||
$as_echo "$dsymutil_vers : $dsymutil_kind ${dsymutil_major} ${dsymutil_minor} ${dsymutil_tiny} " >&6; }
|
||||
fi
|
||||
|
||||
case $target_os in
|
||||
win32 | pe | cygwin* | mingw32*)
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking broken PE linker dwarf5 support" >&5
|
||||
$as_echo_n "checking broken PE linker dwarf5 support... " >&6; }
|
||||
gcc_cv_ld_broken_pe_dwarf5=yes
|
||||
if test $in_tree_ld = yes ; then
|
||||
if grep -q '\.debug_loclists.*BLOCK.*__section_alignment__.*NOLOAD.*:' \
|
||||
$gcc_cv_ld_gld_srcdir/scripttempl/pe*.sc \
|
||||
&& grep -q '\.debug_rnglists.*BLOCK.*__section_alignment__.*NOLOAD.*:' \
|
||||
$gcc_cv_ld_gld_srcdir/scripttempl/pe*.sc; then
|
||||
gcc_cv_ld_broken_pe_dwarf5=no
|
||||
fi
|
||||
else
|
||||
if $gcc_cv_ld --verbose 2>&1 | grep -q '\.debug_loclists.*BLOCK.*__section_alignment__.*NOLOAD.*:' \
|
||||
&& $gcc_cv_ld --verbose 2>&1 | grep -q '\.debug_rnglists.*BLOCK.*__section_alignment__.*NOLOAD.*:'; then
|
||||
gcc_cv_ld_broken_pe_dwarf5=no
|
||||
fi
|
||||
fi
|
||||
if test x$gcc_cv_ld_broken_pe_dwarf5 = xyes; then
|
||||
|
||||
$as_echo "#define HAVE_LD_BROKEN_PE_DWARF5 1" >>confdefs.h
|
||||
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_broken_pe_dwarf5" >&5
|
||||
$as_echo "$gcc_cv_ld_broken_pe_dwarf5" >&6; }
|
||||
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking PE linker --disable-dynamicbase support" >&5
|
||||
$as_echo_n "checking PE linker --disable-dynamicbase support... " >&6; }
|
||||
gcc_cv_ld_disable_dynamicbase=no
|
||||
if test $in_tree_ld = yes; then
|
||||
if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 36 -o "$gcc_cv_gld_major_version" -gt 2; then \
|
||||
gcc_cv_ld_disable_dynamicbase=yes
|
||||
fi
|
||||
else
|
||||
if $gcc_cv_ld --help 2>&1 | grep -q 'disable\-]dynamicbase' > /dev/null; then
|
||||
gcc_cv_ld_disable_dynamicbase=yes
|
||||
fi
|
||||
fi
|
||||
if test x"$gcc_cv_ld_disable_dynamicbase" = xyes; then
|
||||
|
||||
$as_echo "#define HAVE_LD_PE_DISABLE_DYNAMICBASE 1" >>confdefs.h
|
||||
|
||||
fi
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_disable_dynamicbase" >&5
|
||||
$as_echo "$gcc_cv_ld_disable_dynamicbase" >&6; }
|
||||
;;
|
||||
esac
|
||||
|
||||
# --------
|
||||
# UNSORTED
|
||||
# --------
|
||||
|
@ -31576,6 +31780,7 @@ do
|
|||
"as") CONFIG_FILES="$CONFIG_FILES as:exec-tool.in" ;;
|
||||
"collect-ld") CONFIG_FILES="$CONFIG_FILES collect-ld:exec-tool.in" ;;
|
||||
"nm") CONFIG_FILES="$CONFIG_FILES nm:exec-tool.in" ;;
|
||||
"dsymutil") CONFIG_FILES="$CONFIG_FILES dsymutil:exec-tool.in" ;;
|
||||
"clearcap.map") CONFIG_LINKS="$CONFIG_LINKS clearcap.map:${srcdir}/config/$clearcap_map" ;;
|
||||
"$all_outputs") CONFIG_FILES="$CONFIG_FILES $all_outputs" ;;
|
||||
"default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
|
||||
|
@ -32210,6 +32415,7 @@ $as_echo "$as_me: executing $ac_file commands" >&6;}
|
|||
"as":F) chmod +x as ;;
|
||||
"collect-ld":F) chmod +x collect-ld ;;
|
||||
"nm":F) chmod +x nm ;;
|
||||
"dsymutil":F) chmod +x dsymutil ;;
|
||||
"default":C)
|
||||
case ${CONFIG_HEADERS} in
|
||||
*auto-host.h:config.in*)
|
||||
|
|
138
gcc/configure.ac
138
gcc/configure.ac
|
@ -274,8 +274,14 @@ gnu_ld_flag="$with_gnu_ld",
|
|||
gnu_ld_flag=no)
|
||||
|
||||
case $target in
|
||||
*darwin*) ld64_flag=yes;; # Darwin can only use a ld64-compatible linker.
|
||||
*) ld64_flag=no;;
|
||||
*darwin*)
|
||||
ld64_flag=yes # Darwin can only use a ld64-compatible linker.
|
||||
dsymutil_flag=yes # Darwin uses dsymutil to link debug.
|
||||
;;
|
||||
*)
|
||||
ld64_flag=no
|
||||
dsymutil_flag=no
|
||||
;;
|
||||
esac
|
||||
|
||||
# With pre-defined ld
|
||||
|
@ -311,6 +317,31 @@ AC_ARG_WITH(demangler-in-ld,
|
|||
demangler_in_ld="$with_demangler_in_ld",
|
||||
demangler_in_ld=yes)
|
||||
|
||||
# Allow the user to specify a dsymutil executable (used on Darwin only, so far)
|
||||
AC_ARG_WITH(dsymutil,
|
||||
[AS_HELP_STRING([--with-dsymutil], [arrange to use the specified dsymutil (full pathname)])],
|
||||
DEFAULT_DSYMUTIL="$with_dsymutil")
|
||||
|
||||
dsymutil_vers=
|
||||
if test x"${DEFAULT_DSYMUTIL+set}" = x"set"; then
|
||||
if test ! -x "$DEFAULT_DSYMUTIL"; then
|
||||
AC_MSG_ERROR([cannot execute: $DEFAULT_DSYMUTIL: check --with-dsymutil or env. var. DEFAULT_DSYMUTIL])
|
||||
else
|
||||
if dsymutil_vers=`$DEFAULT_DSYMUTIL -v /dev/null 2>&1`; then
|
||||
dsymutil_flag=yes
|
||||
fi
|
||||
fi
|
||||
AC_DEFINE_UNQUOTED(DEFAULT_DSYMUTIL,"$DEFAULT_DSYMUTIL",
|
||||
[Define to enable the use of a default debug linker.])
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING([whether a default dsymutil was specified])
|
||||
if test x"${DEFAULT_DSYMUTIL+set}" = x"set"; then
|
||||
AC_MSG_RESULT([yes ($DEFAULT_DSYMUTIL)])
|
||||
else
|
||||
AC_MSG_RESULT(no)
|
||||
fi
|
||||
|
||||
# ----------------------
|
||||
# Find default assembler
|
||||
# ----------------------
|
||||
|
@ -2714,6 +2745,27 @@ else
|
|||
AC_MSG_RESULT($gcc_cv_otool)
|
||||
fi
|
||||
|
||||
# Figure out the dsymutil we will use.
|
||||
AS_VAR_SET_IF(gcc_cv_dsymutil,, [
|
||||
if test -x "$DEFAULT_DSYMUTIL"; then
|
||||
gcc_cv_dsymutil="$DEFAULT_DSYMUTIL"
|
||||
elif test -x dsymutil$build_exeext; then
|
||||
gcc_cv_dsymutil=./dsymutil$build_exeext
|
||||
elif ( set dummy $DSYMUTIL_FOR_TARGET; test -x $[2] ); then
|
||||
gcc_cv_dsymutil=$DSYMUTIL_FOR_TARGET
|
||||
elif ( set dummy $DSYMUTIL; test -x $[2] ); then
|
||||
gcc_cv_dsymutil=$DSYMUTIL
|
||||
else
|
||||
AC_PATH_PROG(gcc_cv_dsymutil, $DSYMUTIL_FOR_TARGET)
|
||||
fi])
|
||||
|
||||
ORIGINAL_DSYMUTIL_FOR_TARGET=$gcc_cv_dsymutil
|
||||
AC_SUBST(ORIGINAL_DSYMUTIL_FOR_TARGET)
|
||||
case "$ORIGINAL_DSYMUTIL_FOR_TARGET" in
|
||||
./dsymutil | ./dsymutil$build_exeext) ;;
|
||||
*) AC_CONFIG_FILES(dsymutil:exec-tool.in, [chmod +x dsymutil]) ;;
|
||||
esac
|
||||
|
||||
# Figure out what assembler alignment features are present.
|
||||
gcc_GAS_CHECK_FEATURE([.balign and .p2align], gcc_cv_as_balign_and_p2align,
|
||||
[2,6,0],,
|
||||
|
@ -5749,6 +5801,88 @@ if test x"$ld64_flag" = x"yes"; then
|
|||
[Define to 1 if ld64 supports '-export_dynamic'.])
|
||||
fi
|
||||
|
||||
if test x"$dsymutil_flag" = x"yes"; then
|
||||
|
||||
# If the user specified a dsymutil path, then we will already have the
|
||||
# version string, otherwise, pick it up.
|
||||
if test x"$gcc_cv_dsymutil" = x; then
|
||||
AC_MSG_WARN([dsymutil is a required tool for this system, but not found])
|
||||
dsymutil_vers="tool unspecified"
|
||||
elif test x"$dsymutil_vers" = x; then
|
||||
dsymutil_vers=`$gcc_cv_dsymutil -v /dev/null 2>&1`
|
||||
fi
|
||||
|
||||
dsymutil_temp=`echo $dsymutil_vers | sed 1q`
|
||||
AC_MSG_CHECKING(dsymutil version "$dsymutil_temp")
|
||||
if echo $dsymutil_temp | grep dwarfutils- > /dev/null; then
|
||||
dsymutil_kind=DWARFUTILS
|
||||
dsymutil_vers=`echo $dsymutil_temp | sed 's/.*dwarfutils-\([[0-9\.]]*\).*/\1/'`
|
||||
elif echo $dsymutil_temp | grep clang- > /dev/null; then
|
||||
dsymutil_kind=CLANG
|
||||
dsymutil_vers=`echo $dsymutil_temp | sed 's/.*clang-\([[0-9\.]]*\).*/\1/'`
|
||||
elif echo $dsymutil_temp | grep 'LLVM version ' > /dev/null; then
|
||||
dsymutil_kind=LLVM
|
||||
dsymutil_vers=`echo $dsymutil_temp | sed 's/.*LLVM\ version\ \([[0-9\.]]*\).*/\1/'`
|
||||
else
|
||||
dsymutil_kind=UNKNOWN
|
||||
dsymutil_vers="0.0"
|
||||
fi
|
||||
dsymutil_major=`expr "$dsymutil_vers" : '\([[0-9]]*\)'`
|
||||
dsymutil_minor=`expr "$dsymutil_vers" : '[[0-9]]*\.\([[0-9]]*\)'`
|
||||
dsymutil_tiny=`expr "$dsymutil_vers" : '[[0-9]]*\.[[0-9]]*\.\([[0-9]]*\)'`
|
||||
if test x"${dsymutil_minor}" = x; then
|
||||
dsymutil_minor=0
|
||||
fi
|
||||
if test x"${dsymutil_tiny}" = x; then
|
||||
dsymutil_tiny=0
|
||||
fi
|
||||
AC_DEFINE_UNQUOTED(DSYMUTIL_VERSION, [$dsymutil_kind,${dsymutil_major},${dsymutil_minor},${dsymutil_tiny}],
|
||||
[Define to the dsymutil version.])
|
||||
AC_MSG_RESULT($dsymutil_vers : $dsymutil_kind ${dsymutil_major} ${dsymutil_minor} ${dsymutil_tiny} )
|
||||
fi
|
||||
|
||||
case $target_os in
|
||||
win32 | pe | cygwin* | mingw32*)
|
||||
AC_MSG_CHECKING(broken PE linker dwarf5 support)
|
||||
gcc_cv_ld_broken_pe_dwarf5=yes
|
||||
if test $in_tree_ld = yes ; then
|
||||
if grep -q '\.debug_loclists.*BLOCK.*__section_alignment__.*NOLOAD.*:' \
|
||||
$gcc_cv_ld_gld_srcdir/scripttempl/pe*.sc \
|
||||
&& grep -q '\.debug_rnglists.*BLOCK.*__section_alignment__.*NOLOAD.*:' \
|
||||
$gcc_cv_ld_gld_srcdir/scripttempl/pe*.sc; then
|
||||
gcc_cv_ld_broken_pe_dwarf5=no
|
||||
fi
|
||||
else
|
||||
if $gcc_cv_ld --verbose 2>&1 | grep -q '\.debug_loclists.*BLOCK.*__section_alignment__.*NOLOAD.*:' \
|
||||
&& $gcc_cv_ld --verbose 2>&1 | grep -q '\.debug_rnglists.*BLOCK.*__section_alignment__.*NOLOAD.*:'; then
|
||||
gcc_cv_ld_broken_pe_dwarf5=no
|
||||
fi
|
||||
fi
|
||||
if test x$gcc_cv_ld_broken_pe_dwarf5 = xyes; then
|
||||
AC_DEFINE(HAVE_LD_BROKEN_PE_DWARF5, 1,
|
||||
[Define if the PE linker has broken DWARF 5 support.])
|
||||
fi
|
||||
AC_MSG_RESULT($gcc_cv_ld_broken_pe_dwarf5)
|
||||
|
||||
AC_MSG_CHECKING(PE linker --disable-dynamicbase support)
|
||||
gcc_cv_ld_disable_dynamicbase=no
|
||||
if test $in_tree_ld = yes; then
|
||||
if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 36 -o "$gcc_cv_gld_major_version" -gt 2; then \
|
||||
gcc_cv_ld_disable_dynamicbase=yes
|
||||
fi
|
||||
else
|
||||
if $gcc_cv_ld --help 2>&1 | grep -q 'disable\-]dynamicbase' > /dev/null; then
|
||||
gcc_cv_ld_disable_dynamicbase=yes
|
||||
fi
|
||||
fi
|
||||
if test x"$gcc_cv_ld_disable_dynamicbase" = xyes; then
|
||||
AC_DEFINE(HAVE_LD_PE_DISABLE_DYNAMICBASE, 1,
|
||||
[Define if the PE linker supports --disable-dynamicbase option.])
|
||||
fi
|
||||
AC_MSG_RESULT($gcc_cv_ld_disable_dynamicbase)
|
||||
;;
|
||||
esac
|
||||
|
||||
# --------
|
||||
# UNSORTED
|
||||
# --------
|
||||
|
|
|
@ -1041,6 +1041,10 @@ but for the linker.
|
|||
Same as @uref{#with-as,,@option{--with-as}}
|
||||
but for the linker.
|
||||
|
||||
@item --with-dsymutil=@var{pathname}
|
||||
Same as @uref{#with-as,,@option{--with-as}}
|
||||
but for the debug linker (only used on Darwin platforms so far).
|
||||
|
||||
@item --with-stabs
|
||||
Specify that stabs debugging
|
||||
information should be used instead of whatever format the host normally
|
||||
|
|
|
@ -25,6 +25,7 @@ ORIGINAL_LD_BFD_FOR_TARGET="@ORIGINAL_LD_BFD_FOR_TARGET@"
|
|||
ORIGINAL_LD_GOLD_FOR_TARGET="@ORIGINAL_LD_GOLD_FOR_TARGET@"
|
||||
ORIGINAL_PLUGIN_LD_FOR_TARGET="@ORIGINAL_PLUGIN_LD_FOR_TARGET@"
|
||||
ORIGINAL_NM_FOR_TARGET="@ORIGINAL_NM_FOR_TARGET@"
|
||||
ORIGINAL_DSYMUTIL_FOR_TARGET="@ORIGINAL_DSYMUTIL_FOR_TARGET@"
|
||||
exeext=@host_exeext@
|
||||
fast_install=@enable_fast_install@
|
||||
objdir=@objdir@
|
||||
|
@ -71,6 +72,13 @@ case "$invoked" in
|
|||
prog=nm-new$exeext
|
||||
dir=binutils
|
||||
;;
|
||||
dsymutil)
|
||||
original=$ORIGINAL_DSYMUTIL_FOR_TARGET
|
||||
# We do not build this in tree - but still want to be able to execute
|
||||
# a configured version from the build dir.
|
||||
prog=
|
||||
dir=
|
||||
;;
|
||||
esac
|
||||
|
||||
case "$original" in
|
||||
|
|
|
@ -2864,6 +2864,11 @@ find_a_file (const struct path_prefix *pprefix, const char *name, int mode,
|
|||
return xstrdup (DEFAULT_LINKER);
|
||||
#endif
|
||||
|
||||
#ifdef DEFAULT_DSYMUTIL
|
||||
if (! strcmp (name, "dsymutil") && access (DEFAULT_DSYMUTIL, mode) == 0)
|
||||
return xstrdup (DEFAULT_DSYMUTIL);
|
||||
#endif
|
||||
|
||||
/* Determine the filename to execute (special case for absolute paths). */
|
||||
|
||||
if (IS_ABSOLUTE_PATH (name))
|
||||
|
|
Loading…
Reference in New Issue