public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
@ 2014-12-05 22:34 Dominique Dhumieres
  2014-12-05 22:41 ` Jeff Law
  2014-12-05 22:48 ` Jakub Jelinek
  0 siblings, 2 replies; 36+ messages in thread
From: Dominique Dhumieres @ 2014-12-05 22:34 UTC (permalink / raw)
  To: gcc-patches; +Cc: gcc, fxcoudert, pmuldoon, iain, jakub

> As I've tried to explain, that is IMHO wrong though.
> If what you are after is the -B stuff too, then perhaps:
> ...

Sorry but it does not work:

true  DO=all multi-do # make
make[4]: Leaving directory '/opt/gcc/build_w/libbacktrace'
make[3]: Leaving directory '/opt/gcc/build_w/libbacktrace'
make[3]: Entering directory '/opt/gcc/build_w/libcpp'
make[3]: Nothing to be done for 'all'.
make[3]: Leaving directory '/opt/gcc/build_w/libcpp'
make[3]: Entering directory '/opt/gcc/build_w/libdecnumber'
make[3]: Nothing to be done for 'all'.
make[3]: Leaving directory '/opt/gcc/build_w/libdecnumber'
make[3]: Entering directory '/opt/gcc/build_w/gcc'
make[3]: Leaving directory '/opt/gcc/build_w/gcc'
Checking multilib configuration for libgcc...
make[3]: Entering directory '/opt/gcc/build_w/x86_64-apple-darwin14.0.0/libgcc'
make[3]: *** No rule to make target ' -B$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'.  Stop.
make[3]: Leaving directory '/opt/gcc/build_w/x86_64-apple-darwin14.0.0/libgcc'
Makefile:14905: recipe for target 'all-stage1-target-libgcc' failed
make[2]: *** [all-stage1-target-libgcc] Error 2
make[2]: Leaving directory '/opt/gcc/build_w'
Makefile:21193: recipe for target 'stage1-bubble' failed
make[1]: *** [stage1-bubble] Error 2
make[1]: Leaving directory '/opt/gcc/build_w'
Makefile:910: recipe for target 'all' failed
make: *** [all] Error 2

Dominique

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-05 22:34 [patch, build] Restore bootstrap in building libcc1 on darwin Dominique Dhumieres
@ 2014-12-05 22:41 ` Jeff Law
  2014-12-05 22:46   ` Phil Muldoon
  2014-12-06 11:16   ` Iain Sandoe
  2014-12-05 22:48 ` Jakub Jelinek
  1 sibling, 2 replies; 36+ messages in thread
From: Jeff Law @ 2014-12-05 22:41 UTC (permalink / raw)
  To: Dominique Dhumieres, gcc-patches; +Cc: gcc, fxcoudert, pmuldoon, iain, jakub

On 12/05/14 15:34, Dominique Dhumieres wrote:
>> As I've tried to explain, that is IMHO wrong though.
>> If what you are after is the -B stuff too, then perhaps:
>> ...
>
> Sorry but it does not work:
BTW, thanks for working with Jakub on this.  We're going to be getting a 
Darwin box for Jakub and other folks in the Red Hat team to use when the 
need arises to dig into these kind of issues.

However, until that box arrives and is setup, this kind of iteration is 
the only way he can test Darwin stuff.

Jeff

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-05 22:41 ` Jeff Law
@ 2014-12-05 22:46   ` Phil Muldoon
  2014-12-06 11:16   ` Iain Sandoe
  1 sibling, 0 replies; 36+ messages in thread
From: Phil Muldoon @ 2014-12-05 22:46 UTC (permalink / raw)
  To: Jeff Law, Dominique Dhumieres, gcc-patches; +Cc: gcc, fxcoudert, iain, jakub

On 05/12/14 22:40, Jeff Law wrote:
> On 12/05/14 15:34, Dominique Dhumieres wrote:
>>> As I've tried to explain, that is IMHO wrong though.
>>> If what you are after is the -B stuff too, then perhaps:
>>> ...
>>
>> Sorry but it does not work:
> BTW, thanks for working with Jakub on this.  We're going to be getting a Darwin box for Jakub and other folks in the Red Hat team to use when the need arises to dig into these kind of issues.
>
> However, until that box arrives and is setup, this kind of iteration is the only way he can test Darwin stuff.
>
> Jeff
>

Indeed I feel especially bad in these scenarios where patches are
suggested for a patch I submitted and are causing you folks problems.
I really do not want to do that.  So many architectures for GCC, so
very few resources.  Hopefully as Jeff indicates, this will be sorted
soon.  Again from a libcc1 point of view, as long as we have the .so
built on all configurations, that is what matters.  I have not chipped
into these threads as I have nothing to say/recommend about darwin
architectures :( I do read them all, though.

Cheers,

Phil

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-05 22:34 [patch, build] Restore bootstrap in building libcc1 on darwin Dominique Dhumieres
  2014-12-05 22:41 ` Jeff Law
@ 2014-12-05 22:48 ` Jakub Jelinek
  2014-12-06  0:50   ` Dominique d'Humières
  2014-12-13 10:52   ` Paolo Bonzini
  1 sibling, 2 replies; 36+ messages in thread
From: Jakub Jelinek @ 2014-12-05 22:48 UTC (permalink / raw)
  To: Dominique Dhumieres; +Cc: gcc-patches, gcc, fxcoudert, pmuldoon, iain

On Fri, Dec 05, 2014 at 11:34:28PM +0100, Dominique Dhumieres wrote:
> > As I've tried to explain, that is IMHO wrong though.
> > If what you are after is the -B stuff too, then perhaps:
> > ...
> 
> Sorry but it does not work:

Sorry, make that (just removed 4x ' in each file):

2014-12-05  Jakub Jelinek  <jakub@redhat.com>

	PR bootstrap/64023
	* Makefile.tpl (EXTRA_TARGET_FLAGS): Set STAGE1_LDFLAGS
	to POSTSTAGE1_LDFLAGS and STAGE1_LIBS to POSTSTAGE1_LIBS.
	Add -B to libstdc++-v3/src/.libs and libstdc++-v3/libsupc++/.libs
	to CXX.
	* Makefile.in: Regenerated.

--- Makefile.tpl.jj	2014-11-12 09:31:59.000000000 +0100
+++ Makefile.tpl	2014-12-05 21:12:21.486031062 +0100
@@ -641,7 +641,9 @@ EXTRA_TARGET_FLAGS = \
 	'AS=$(COMPILER_AS_FOR_TARGET)' \
 	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
 	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
-	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
+	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \
+	 -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs \
+	 $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
 	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
 	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
 	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
@@ -659,6 +661,8 @@ EXTRA_TARGET_FLAGS = \
 	'WINDRES=$$(WINDRES_FOR_TARGET)' \
 	'WINDMC=$$(WINDMC_FOR_TARGET)' \
 	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
+	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
+	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
 	"TFLAGS=$$TFLAGS"
 
 TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
--- Makefile.in.jj	2014-11-28 14:40:52.000000000 +0100
+++ Makefile.in	2014-12-05 21:11:48.276616008 +0100
@@ -835,7 +835,9 @@ EXTRA_TARGET_FLAGS = \
 	'AS=$(COMPILER_AS_FOR_TARGET)' \
 	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
 	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
-	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
+	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \
+	 -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs \
+	 $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
 	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
 	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
 	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
@@ -853,6 +855,8 @@ EXTRA_TARGET_FLAGS = \
 	'WINDRES=$$(WINDRES_FOR_TARGET)' \
 	'WINDMC=$$(WINDMC_FOR_TARGET)' \
 	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
+	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
+	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
 	"TFLAGS=$$TFLAGS"
 
 TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)

	Jakub

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-05 22:48 ` Jakub Jelinek
@ 2014-12-06  0:50   ` Dominique d'Humières
  2014-12-09 17:08     ` Dominique d'Humières
  2014-12-13 10:52   ` Paolo Bonzini
  1 sibling, 1 reply; 36+ messages in thread
From: Dominique d'Humières @ 2014-12-06  0:50 UTC (permalink / raw)
  To: Jakub Jelinek; +Cc: gcc-patches, gcc, fxcoudert, pmuldoon, iain

Bootstrap just finished with the patch.

Thanks,

Dominique

> Le 5 déc. 2014 à 23:47, Jakub Jelinek <jakub@redhat.com> a écrit :
> 
> On Fri, Dec 05, 2014 at 11:34:28PM +0100, Dominique Dhumieres wrote:
>>> As I've tried to explain, that is IMHO wrong though.
>>> If what you are after is the -B stuff too, then perhaps:
>>> ...
>> 
>> Sorry but it does not work:
> 
> Sorry, make that (just removed 4x ' in each file):
> 
> 2014-12-05  Jakub Jelinek  <jakub@redhat.com>
> 
> 	PR bootstrap/64023
> 	* Makefile.tpl (EXTRA_TARGET_FLAGS): Set STAGE1_LDFLAGS
> 	to POSTSTAGE1_LDFLAGS and STAGE1_LIBS to POSTSTAGE1_LIBS.
> 	Add -B to libstdc++-v3/src/.libs and libstdc++-v3/libsupc++/.libs
> 	to CXX.
> 	* Makefile.in: Regenerated.
> 
> --- Makefile.tpl.jj	2014-11-12 09:31:59.000000000 +0100
> +++ Makefile.tpl	2014-12-05 21:12:21.486031062 +0100
> @@ -641,7 +641,9 @@ EXTRA_TARGET_FLAGS = \
> 	'AS=$(COMPILER_AS_FOR_TARGET)' \
> 	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> 	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
> -	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> +	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \
> +	 -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs \
> +	 $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> 	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
> 	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
> 	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> @@ -659,6 +661,8 @@ EXTRA_TARGET_FLAGS = \
> 	'WINDRES=$$(WINDRES_FOR_TARGET)' \
> 	'WINDMC=$$(WINDMC_FOR_TARGET)' \
> 	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
> +	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
> +	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
> 	"TFLAGS=$$TFLAGS"
> 
> TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
> --- Makefile.in.jj	2014-11-28 14:40:52.000000000 +0100
> +++ Makefile.in	2014-12-05 21:11:48.276616008 +0100
> @@ -835,7 +835,9 @@ EXTRA_TARGET_FLAGS = \
> 	'AS=$(COMPILER_AS_FOR_TARGET)' \
> 	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> 	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
> -	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> +	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \
> +	 -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs \
> +	 $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> 	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
> 	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
> 	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> @@ -853,6 +855,8 @@ EXTRA_TARGET_FLAGS = \
> 	'WINDRES=$$(WINDRES_FOR_TARGET)' \
> 	'WINDMC=$$(WINDMC_FOR_TARGET)' \
> 	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
> +	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
> +	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
> 	"TFLAGS=$$TFLAGS"
> 
> TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
> 
> 	Jakub

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-05 22:41 ` Jeff Law
  2014-12-05 22:46   ` Phil Muldoon
@ 2014-12-06 11:16   ` Iain Sandoe
  1 sibling, 0 replies; 36+ messages in thread
From: Iain Sandoe @ 2014-12-06 11:16 UTC (permalink / raw)
  To: Jeff Law
  Cc: Dominique Dhumieres, gcc-patches, gcc, fxcoudert, pmuldoon, jakub

Hi Jeff,

On 5 Dec 2014, at 22:40, Jeff Law wrote:

> On 12/05/14 15:34, Dominique Dhumieres wrote:
>>> As I've tried to explain, that is IMHO wrong though.
>>> If what you are after is the -B stuff too, then perhaps:
>>> ...
>> 
>> Sorry but it does not work:
> BTW, thanks for working with Jakub on this.  We're going to be getting a Darwin box for Jakub and other folks in the Red Hat team to use when the need arises to dig into these kind of issues.

That will be most welcome, we Darwin folks have only volunteer cycles to work on stuff, and those tend to get used up really quickly.

Iain

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-06  0:50   ` Dominique d'Humières
@ 2014-12-09 17:08     ` Dominique d'Humières
  0 siblings, 0 replies; 36+ messages in thread
From: Dominique d'Humières @ 2014-12-09 17:08 UTC (permalink / raw)
  To: Jakub Jelinek; +Cc: gcc-patches, gcc, FX, pmuldoon, Iain Sandoe, law

This was for x86_64-apple-darwin14. The patch also works for x86_64-apple-darwin10.

Dominique

> Le 6 déc. 2014 à 01:49, Dominique d'Humières <dominiq@lps.ens.fr> a écrit :
> 
> Bootstrap just finished with the patch.
> 
> Thanks,
> 
> Dominique

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-05 22:48 ` Jakub Jelinek
  2014-12-06  0:50   ` Dominique d'Humières
@ 2014-12-13 10:52   ` Paolo Bonzini
  2014-12-13 11:26     ` Paolo Bonzini
  1 sibling, 1 reply; 36+ messages in thread
From: Paolo Bonzini @ 2014-12-13 10:52 UTC (permalink / raw)
  To: Jakub Jelinek, Dominique Dhumieres
  Cc: gcc-patches, gcc, fxcoudert, pmuldoon, iain



On 05/12/2014 23:47, Jakub Jelinek wrote:
> On Fri, Dec 05, 2014 at 11:34:28PM +0100, Dominique Dhumieres wrote:
>>> As I've tried to explain, that is IMHO wrong though.
>>> If what you are after is the -B stuff too, then perhaps:
>>> ...
>>
>> Sorry but it does not work:
> 
> Sorry, make that (just removed 4x ' in each file):
> 
> 2014-12-05  Jakub Jelinek  <jakub@redhat.com>
> 
> 	PR bootstrap/64023
> 	* Makefile.tpl (EXTRA_TARGET_FLAGS): Set STAGE1_LDFLAGS
> 	to POSTSTAGE1_LDFLAGS and STAGE1_LIBS to POSTSTAGE1_LIBS.
> 	Add -B to libstdc++-v3/src/.libs and libstdc++-v3/libsupc++/.libs
> 	to CXX.
> 	* Makefile.in: Regenerated.
> 
> --- Makefile.tpl.jj	2014-11-12 09:31:59.000000000 +0100
> +++ Makefile.tpl	2014-12-05 21:12:21.486031062 +0100
> @@ -641,7 +641,9 @@ EXTRA_TARGET_FLAGS = \
>  	'AS=$(COMPILER_AS_FOR_TARGET)' \
>  	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
>  	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
> -	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> +	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \
> +	 -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs \
> +	 $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
>  	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
>  	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
>  	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> @@ -659,6 +661,8 @@ EXTRA_TARGET_FLAGS = \
>  	'WINDRES=$$(WINDRES_FOR_TARGET)' \
>  	'WINDMC=$$(WINDMC_FOR_TARGET)' \
>  	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
> +	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
> +	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
>  	"TFLAGS=$$TFLAGS"
>  
>  TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
> --- Makefile.in.jj	2014-11-28 14:40:52.000000000 +0100
> +++ Makefile.in	2014-12-05 21:11:48.276616008 +0100
> @@ -835,7 +835,9 @@ EXTRA_TARGET_FLAGS = \
>  	'AS=$(COMPILER_AS_FOR_TARGET)' \
>  	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
>  	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
> -	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> +	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \
> +	 -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs \
> +	 $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
>  	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
>  	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
>  	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> @@ -853,6 +855,8 @@ EXTRA_TARGET_FLAGS = \
>  	'WINDRES=$$(WINDRES_FOR_TARGET)' \
>  	'WINDMC=$$(WINDMC_FOR_TARGET)' \
>  	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
> +	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
> +	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
>  	"TFLAGS=$$TFLAGS"
>  
>  TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
> 
> 	Jakub
> 

If it also works for --disable-bootstrap, this is okay.

Paolo

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-13 10:52   ` Paolo Bonzini
@ 2014-12-13 11:26     ` Paolo Bonzini
  0 siblings, 0 replies; 36+ messages in thread
From: Paolo Bonzini @ 2014-12-13 11:26 UTC (permalink / raw)
  To: gcc-patches; +Cc: gcc



On 05/12/2014 23:47, Jakub Jelinek wrote:
> On Fri, Dec 05, 2014 at 11:34:28PM +0100, Dominique Dhumieres wrote:
>>> As I've tried to explain, that is IMHO wrong though.
>>> If what you are after is the -B stuff too, then perhaps:
>>> ...
>>
>> Sorry but it does not work:
> 
> Sorry, make that (just removed 4x ' in each file):
> 
> 2014-12-05  Jakub Jelinek  <jakub@redhat.com>
> 
> 	PR bootstrap/64023
> 	* Makefile.tpl (EXTRA_TARGET_FLAGS): Set STAGE1_LDFLAGS
> 	to POSTSTAGE1_LDFLAGS and STAGE1_LIBS to POSTSTAGE1_LIBS.
> 	Add -B to libstdc++-v3/src/.libs and libstdc++-v3/libsupc++/.libs
> 	to CXX.
> 	* Makefile.in: Regenerated.
> 
> --- Makefile.tpl.jj	2014-11-12 09:31:59.000000000 +0100
> +++ Makefile.tpl	2014-12-05 21:12:21.486031062 +0100
> @@ -641,7 +641,9 @@ EXTRA_TARGET_FLAGS = \
>  	'AS=$(COMPILER_AS_FOR_TARGET)' \
>  	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
>  	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
> -	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> +	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \
> +	 -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs \
> +	 $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
>  	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
>  	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
>  	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> @@ -659,6 +661,8 @@ EXTRA_TARGET_FLAGS = \
>  	'WINDRES=$$(WINDRES_FOR_TARGET)' \
>  	'WINDMC=$$(WINDMC_FOR_TARGET)' \
>  	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
> +	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
> +	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
>  	"TFLAGS=$$TFLAGS"
>  
>  TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
> --- Makefile.in.jj	2014-11-28 14:40:52.000000000 +0100
> +++ Makefile.in	2014-12-05 21:11:48.276616008 +0100
> @@ -835,7 +835,9 @@ EXTRA_TARGET_FLAGS = \
>  	'AS=$(COMPILER_AS_FOR_TARGET)' \
>  	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
>  	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
> -	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> +	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs \
> +	 -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs \
> +	 $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
>  	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
>  	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
>  	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
> @@ -853,6 +855,8 @@ EXTRA_TARGET_FLAGS = \
>  	'WINDRES=$$(WINDRES_FOR_TARGET)' \
>  	'WINDMC=$$(WINDMC_FOR_TARGET)' \
>  	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
> +	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
> +	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
>  	"TFLAGS=$$TFLAGS"
>  
>  TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
> 
> 	Jakub
> 

If it also works for --disable-bootstrap, this is okay.

Paolo

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2015-03-08 17:38                   ` Iain Sandoe
  2015-03-08 17:48                     ` Ian Lance Taylor
@ 2015-03-09 18:43                     ` Mike Stump
  1 sibling, 0 replies; 36+ messages in thread
From: Mike Stump @ 2015-03-09 18:43 UTC (permalink / raw)
  To: Iain Sandoe
  Cc: Jeff Law, gcc-patches Patches, DJ Delorie, FX, Rainer Orth,
	Dominique Dhumieres, Ian Lance Taylor

On Mar 8, 2015, at 10:38 AM, Iain Sandoe <iain@codesourcery.com> wrote:
> +Ian
> + ping

So, all the darwinness of the patch looks fine to me.  One maintainer down, just need libiberty approval.

If the work becomes too bothersome, the comment out the line and say, # does’t work with libcc1 approach for the config fragment I’ll pre-approve if you want to punt at any point.

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2015-03-08 17:38                   ` Iain Sandoe
@ 2015-03-08 17:48                     ` Ian Lance Taylor
  2015-03-09 18:43                     ` Mike Stump
  1 sibling, 0 replies; 36+ messages in thread
From: Ian Lance Taylor @ 2015-03-08 17:48 UTC (permalink / raw)
  To: Iain Sandoe
  Cc: Jeff Law, gcc-patches Patches, DJ Delorie, FX, Rainer Orth,
	Dominique Dhumieres

Iain Sandoe <iain@codesourcery.com> writes:

> +Ian
> + ping

The patch is missing the change to maint-tool to generate the
rules at the bottom of libiberty/Makefile.in.

Right now the libiberty Makefile does not require GNU make, and it's not
clear to me that we want to push that dependency onto all projects that
use libiberty.  It looks feasible to change this patch to not require
GNU make, by using a shell expansion rather than a make expansion, and I
think that would be the conservative thing to do.

> +# If the passed CFLAGS or CPPFLAGS include options which are incompatible
> +# with PIC code (and cannot be overridden) save them for non-pic code...

Is this a likely scenario?  Where would these options be coming from?

> +NONPIC = $(filter $(NOPICFLAG), $(CFLAGS))
> +NONPIC += $(filter $(NOPICFLAG), $(CPPFLAGS))

CPPFLAGS should precede CFLAGS.

Ian


> On 11 Feb 2015, at 14:37, Iain Sandoe wrote:
>
>> Hi Jeff,
>> 
>> On 9 Feb 2015, at 14:47, Jeff Law <law@redhat.com> wrote:
>> 
>>> On 02/01/15 09:42, Iain Sandoe wrote:
>>>> 
>>>> This is a GCC5 bootstrap regression on 32bit Darwin hosts ( I can
>>>> raise a PR if that is considered necessary).
>>> Has this been addressed or is it still pending?
>> 
>> I believe it's still awaiting review
>
> Dominque has raised PR65351 to track this.
> (i can rebase the patch if needed, it's being regularly tested on trunk)
>
> thanks, 
> Iain
>
>> 
>>> 
>>> 
>>>> 
>>>> In fact it is not libcc1, but libiberty that is the cause -
>>>> 
>>>> On 26 Jan 2015, at 14:13, Rainer Orth wrote:
>>>> 
>>>>> FX <fxcoudert@gmail.com> writes:
>>>>> 
>>>>>>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>>>>>>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB
>>>>>>> -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>>>>>>> This means that the PIC library is being built with non-pic relocs.
>>>>>> 
>>>>>> config/mh-darwin says that -mdynamic-no-pic is there because it “speeds
>>>>>> compiles by 3-5%”. I don’t think we care about speed when the bootstrap
>>>>>> fails, so can we remove it altogether?
>>>>> 
>>>>> Darwin/i686 still doesn't bootstrap without this patch, I believe.
>>>>> Shouldn't it be applied to trunk before GCC 5 ships, rather than leaving
>>>>> that target broken?
>>>> 
>>>> The PIC variant of libiberty, has never (since it was added,
>>>> AFAICT) catered for the possibility that non-PIC and PIC options
>>>> might conflict (and/or that it might not be possible to override
>>>> non-PIC options simply by appending PIC ones).
>>>> 
>>>> This has gone un-noticed until the libcc1 plugin started linking
>>>> with the pic version of libiberty.
>>>> 
>>>> Darwin uses -mdynamic-no-pic as a default flag during bootstrap
>>>> for 32bit targets, since that gives a stated ~ 3-5% improvement in
>>>> performance.
>>>> 
>>>> It is not possible to override this non-pic option by appending
>>>> -fPIC (that simply results in a warning that mdynamic-no-pic takes
>>>> precedence).
>>>> 
>>>> I'd rather not pretend that there's no problem and simply penalise
>>>> performance on m32 darwin by removing the option from the
>>>> bootflags.
>>>> 
>>>> So here's a patch that allows a target to declare incompatible
>>>> non-pic options (in the same way that we have PIC options already
>>>> declared as distinct).
>>>> 
>>>> The patch is largely mechanical (each of the targets adjusted to
>>>> use the NONPIC flag for the relevant case).
>>>> 
>>>> As an aside, is there a portability reason that we don't make this
>>>> repeated operation into a make function?
>>>> 
>>>> bootstapped on x86_64-linux, x86_64-darwin12, i686-darwin10,
>>>> powerpc-darwin9,
>>>> cross-compiled x86-64-darwin12 X i686-darwin10 , native X
>>>> i686-darwin10 (x86_64-darwin12 build).
>>>> 
>>>> all languages including Ada (note that there's a local patch
>>>> needed to work-around an Ada bootstrap issue - pr64349)
>>>> 
>>>> OK for trunk?
>>>> Iain
>>>> 
>>>> libiberty:
>>>> 	* Makefile.in (NONPICFLAG, NEWCFLAGS, NEWCPPFLAGS): New.
>>>> 	(COMPILE.c): Adjust to use new flags. (all non-pic targets):
>>>> 	Adjust to use NONPIC flag.
>>>> 	* configure.ac (NOPICFLAG): New.
>>>> 	* configure: Regenerate.
>>>> 
>>> 
>> 
>
> diff --git a/libiberty/Makefile.in b/libiberty/Makefile.in
> index f06cc69..8674b4a 100644
> --- a/libiberty/Makefile.in
> +++ b/libiberty/Makefile.in
> @@ -62,6 +62,7 @@ MAKEINFO = @MAKEINFO@
>  PERL = @PERL@
>  
>  PICFLAG = @PICFLAG@
> +NOPICFLAG = @NOPICFLAG@
>  NOASANFLAG = @NOASANFLAG@
>  
>  MAKEOVERRIDES =
> @@ -113,7 +114,16 @@ installcheck: installcheck-subdir
>  
>  INCDIR=$(srcdir)/$(MULTISRCTOP)../include
>  
> -COMPILE.c = $(CC) -c @DEFS@ $(CFLAGS) $(CPPFLAGS) -I. -I$(INCDIR) $(HDEFINES) @ac_libiberty_warn_cflags@
> +# If the passed CFLAGS or CPPFLAGS include options which are incompatible
> +# with PIC code (and cannot be overridden) save them for non-pic code...
> +NONPIC = $(filter $(NOPICFLAG), $(CFLAGS))
> +NONPIC += $(filter $(NOPICFLAG), $(CPPFLAGS))
> +# ... and then remove them from the default.
> +NEWCFLAGS = $(filter-out $(NOPICFLAG), $(CFLAGS))
> +NEWCPPFLAGS = $(filter-out $(NOPICFLAG), $(CPPFLAGS))
> +
> +COMPILE.c = $(CC) -c @DEFS@ $(NEWCFLAGS) $(NEWCPPFLAGS) -I. -I$(INCDIR) \
> +            $(HDEFINES) @ac_libiberty_warn_cflags@
>  
>  # Just to make sure we don't use a built-in rule with VPATH
>  .c.$(objext):
> @@ -519,7 +529,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/_doprnt.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/_doprnt.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/_doprnt.c $(OUTPUT_OPTION)
>  
>  ./alloca.$(objext): $(srcdir)/alloca.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -529,7 +539,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/alloca.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/alloca.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/alloca.c $(OUTPUT_OPTION)
>  
>  ./argv.$(objext): $(srcdir)/argv.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
> @@ -539,7 +549,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/argv.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/argv.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/argv.c $(OUTPUT_OPTION)
>  
>  ./asprintf.$(objext): $(srcdir)/asprintf.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -549,7 +559,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/asprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/asprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/asprintf.c $(OUTPUT_OPTION)
>  
>  ./atexit.$(objext): $(srcdir)/atexit.c config.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -558,7 +568,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/atexit.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/atexit.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/atexit.c $(OUTPUT_OPTION)
>  
>  ./basename.$(objext): $(srcdir)/basename.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
> @@ -568,7 +578,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/basename.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/basename.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/basename.c $(OUTPUT_OPTION)
>  
>  ./bcmp.$(objext): $(srcdir)/bcmp.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -577,7 +587,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bcmp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/bcmp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/bcmp.c $(OUTPUT_OPTION)
>  
>  ./bcopy.$(objext): $(srcdir)/bcopy.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -586,7 +596,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bcopy.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/bcopy.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/bcopy.c $(OUTPUT_OPTION)
>  
>  ./bsearch.$(objext): $(srcdir)/bsearch.c config.h $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -595,7 +605,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bsearch.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/bsearch.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/bsearch.c $(OUTPUT_OPTION)
>  
>  ./bzero.$(objext): $(srcdir)/bzero.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -604,7 +614,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bzero.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/bzero.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/bzero.c $(OUTPUT_OPTION)
>  
>  ./calloc.$(objext): $(srcdir)/calloc.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -613,7 +623,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/calloc.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/calloc.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/calloc.c $(OUTPUT_OPTION)
>  
>  ./choose-temp.$(objext): $(srcdir)/choose-temp.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -623,7 +633,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/choose-temp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/choose-temp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/choose-temp.c $(OUTPUT_OPTION)
>  
>  ./clock.$(objext): $(srcdir)/clock.c config.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -632,7 +642,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/clock.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/clock.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/clock.c $(OUTPUT_OPTION)
>  
>  ./concat.$(objext): $(srcdir)/concat.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -642,7 +652,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/concat.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/concat.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/concat.c $(OUTPUT_OPTION)
>  
>  ./copysign.$(objext): $(srcdir)/copysign.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -651,7 +661,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/copysign.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/copysign.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/copysign.c $(OUTPUT_OPTION)
>  
>  ./cp-demangle.$(objext): $(srcdir)/cp-demangle.c config.h $(INCDIR)/ansidecl.h \
>  	$(srcdir)/cp-demangle.h $(INCDIR)/demangle.h \
> @@ -662,7 +672,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cp-demangle.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/cp-demangle.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/cp-demangle.c $(OUTPUT_OPTION)
>  
>  ./cp-demint.$(objext): $(srcdir)/cp-demint.c config.h $(INCDIR)/ansidecl.h \
>  	$(srcdir)/cp-demangle.h $(INCDIR)/demangle.h \
> @@ -673,7 +683,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cp-demint.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/cp-demint.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/cp-demint.c $(OUTPUT_OPTION)
>  
>  ./cplus-dem.$(objext): $(srcdir)/cplus-dem.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/demangle.h $(INCDIR)/libiberty.h \
> @@ -684,7 +694,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cplus-dem.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/cplus-dem.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/cplus-dem.c $(OUTPUT_OPTION)
>  
>  ./crc32.$(objext): $(srcdir)/crc32.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -694,7 +704,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/crc32.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/crc32.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/crc32.c $(OUTPUT_OPTION)
>  
>  ./d-demangle.$(objext): $(srcdir)/d-demangle.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/demangle.h $(INCDIR)/libiberty.h \
> @@ -705,7 +715,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/d-demangle.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/d-demangle.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/d-demangle.c $(OUTPUT_OPTION)
>  
>  ./dwarfnames.$(objext): $(srcdir)/dwarfnames.c $(INCDIR)/dwarf2.def \
>  	$(INCDIR)/dwarf2.h
> @@ -715,7 +725,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/dwarfnames.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/dwarfnames.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/dwarfnames.c $(OUTPUT_OPTION)
>  
>  ./dyn-string.$(objext): $(srcdir)/dyn-string.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/dyn-string.h $(INCDIR)/libiberty.h
> @@ -725,7 +735,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/dyn-string.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/dyn-string.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/dyn-string.c $(OUTPUT_OPTION)
>  
>  ./fdmatch.$(objext): $(srcdir)/fdmatch.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -735,7 +745,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fdmatch.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/fdmatch.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/fdmatch.c $(OUTPUT_OPTION)
>  
>  ./ffs.$(objext): $(srcdir)/ffs.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -744,7 +754,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/ffs.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/ffs.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/ffs.c $(OUTPUT_OPTION)
>  
>  ./fibheap.$(objext): $(srcdir)/fibheap.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/fibheap.h $(INCDIR)/libiberty.h
> @@ -754,7 +764,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fibheap.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/fibheap.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/fibheap.c $(OUTPUT_OPTION)
>  
>  ./filename_cmp.$(objext): $(srcdir)/filename_cmp.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/filenames.h $(INCDIR)/hashtab.h \
> @@ -765,7 +775,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/filename_cmp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/filename_cmp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/filename_cmp.c $(OUTPUT_OPTION)
>  
>  ./floatformat.$(objext): $(srcdir)/floatformat.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/floatformat.h $(INCDIR)/libiberty.h
> @@ -775,7 +785,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/floatformat.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/floatformat.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/floatformat.c $(OUTPUT_OPTION)
>  
>  ./fnmatch.$(objext): $(srcdir)/fnmatch.c config.h $(INCDIR)/fnmatch.h \
>  	$(INCDIR)/safe-ctype.h
> @@ -785,7 +795,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fnmatch.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/fnmatch.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/fnmatch.c $(OUTPUT_OPTION)
>  
>  ./fopen_unlocked.$(objext): $(srcdir)/fopen_unlocked.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
> @@ -795,7 +805,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fopen_unlocked.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/fopen_unlocked.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/fopen_unlocked.c $(OUTPUT_OPTION)
>  
>  ./getcwd.$(objext): $(srcdir)/getcwd.c config.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -804,7 +814,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getcwd.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/getcwd.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/getcwd.c $(OUTPUT_OPTION)
>  
>  ./getopt.$(objext): $(srcdir)/getopt.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/getopt.h
> @@ -814,7 +824,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getopt.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/getopt.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/getopt.c $(OUTPUT_OPTION)
>  
>  ./getopt1.$(objext): $(srcdir)/getopt1.c config.h $(INCDIR)/getopt.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -823,7 +833,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getopt1.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/getopt1.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/getopt1.c $(OUTPUT_OPTION)
>  
>  ./getpagesize.$(objext): $(srcdir)/getpagesize.c config.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -832,7 +842,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getpagesize.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/getpagesize.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/getpagesize.c $(OUTPUT_OPTION)
>  
>  ./getpwd.$(objext): $(srcdir)/getpwd.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -842,7 +852,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getpwd.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/getpwd.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/getpwd.c $(OUTPUT_OPTION)
>  
>  ./getruntime.$(objext): $(srcdir)/getruntime.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -852,7 +862,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getruntime.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/getruntime.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/getruntime.c $(OUTPUT_OPTION)
>  
>  ./gettimeofday.$(objext): $(srcdir)/gettimeofday.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -862,7 +872,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/gettimeofday.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/gettimeofday.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/gettimeofday.c $(OUTPUT_OPTION)
>  
>  ./hashtab.$(objext): $(srcdir)/hashtab.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/hashtab.h $(INCDIR)/libiberty.h
> @@ -872,7 +882,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/hashtab.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/hashtab.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/hashtab.c $(OUTPUT_OPTION)
>  
>  ./hex.$(objext): $(srcdir)/hex.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
> @@ -882,7 +892,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/hex.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/hex.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/hex.c $(OUTPUT_OPTION)
>  
>  ./index.$(objext): $(srcdir)/index.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -891,7 +901,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/index.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/index.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/index.c $(OUTPUT_OPTION)
>  
>  ./insque.$(objext): $(srcdir)/insque.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -900,7 +910,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/insque.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/insque.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/insque.c $(OUTPUT_OPTION)
>  
>  ./lbasename.$(objext): $(srcdir)/lbasename.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/filenames.h $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h \
> @@ -911,7 +921,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/lbasename.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/lbasename.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/lbasename.c $(OUTPUT_OPTION)
>  
>  ./lrealpath.$(objext): $(srcdir)/lrealpath.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -921,7 +931,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/lrealpath.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/lrealpath.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/lrealpath.c $(OUTPUT_OPTION)
>  
>  ./make-relative-prefix.$(objext): $(srcdir)/make-relative-prefix.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
> @@ -931,7 +941,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/make-relative-prefix.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/make-relative-prefix.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/make-relative-prefix.c $(OUTPUT_OPTION)
>  
>  ./make-temp-file.$(objext): $(srcdir)/make-temp-file.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
> @@ -941,7 +951,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/make-temp-file.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/make-temp-file.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/make-temp-file.c $(OUTPUT_OPTION)
>  
>  ./md5.$(objext): $(srcdir)/md5.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/md5.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -950,7 +960,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/md5.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/md5.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/md5.c $(OUTPUT_OPTION)
>  
>  ./memchr.$(objext): $(srcdir)/memchr.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -959,7 +969,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memchr.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/memchr.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/memchr.c $(OUTPUT_OPTION)
>  
>  ./memcmp.$(objext): $(srcdir)/memcmp.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -968,7 +978,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memcmp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/memcmp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/memcmp.c $(OUTPUT_OPTION)
>  
>  ./memcpy.$(objext): $(srcdir)/memcpy.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -977,7 +987,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memcpy.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/memcpy.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/memcpy.c $(OUTPUT_OPTION)
>  
>  ./memmem.$(objext): $(srcdir)/memmem.c config.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -986,7 +996,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memmem.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/memmem.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/memmem.c $(OUTPUT_OPTION)
>  
>  ./memmove.$(objext): $(srcdir)/memmove.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -995,7 +1005,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memmove.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/memmove.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/memmove.c $(OUTPUT_OPTION)
>  
>  ./mempcpy.$(objext): $(srcdir)/mempcpy.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1004,7 +1014,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/mempcpy.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/mempcpy.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/mempcpy.c $(OUTPUT_OPTION)
>  
>  ./memset.$(objext): $(srcdir)/memset.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1013,7 +1023,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memset.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/memset.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/memset.c $(OUTPUT_OPTION)
>  
>  ./mkstemps.$(objext): $(srcdir)/mkstemps.c config.h $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1022,7 +1032,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/mkstemps.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/mkstemps.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/mkstemps.c $(OUTPUT_OPTION)
>  
>  ./msdos.$(objext): $(srcdir)/msdos.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1031,7 +1041,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/msdos.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/msdos.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/msdos.c $(OUTPUT_OPTION)
>  
>  ./objalloc.$(objext): $(srcdir)/objalloc.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/objalloc.h
> @@ -1041,7 +1051,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/objalloc.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/objalloc.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/objalloc.c $(OUTPUT_OPTION)
>  
>  ./obstack.$(objext): $(srcdir)/obstack.c config.h $(INCDIR)/obstack.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1050,7 +1060,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/obstack.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/obstack.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/obstack.c $(OUTPUT_OPTION)
>  
>  ./partition.$(objext): $(srcdir)/partition.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(INCDIR)/partition.h
> @@ -1060,7 +1070,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/partition.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/partition.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/partition.c $(OUTPUT_OPTION)
>  
>  ./pex-common.$(objext): $(srcdir)/pex-common.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
> @@ -1070,7 +1080,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-common.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/pex-common.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-common.c $(OUTPUT_OPTION)
>  
>  ./pex-djgpp.$(objext): $(srcdir)/pex-djgpp.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
> @@ -1080,7 +1090,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-djgpp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/pex-djgpp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-djgpp.c $(OUTPUT_OPTION)
>  
>  ./pex-msdos.$(objext): $(srcdir)/pex-msdos.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h \
> @@ -1091,7 +1101,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-msdos.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/pex-msdos.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-msdos.c $(OUTPUT_OPTION)
>  
>  ./pex-one.$(objext): $(srcdir)/pex-one.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1101,7 +1111,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-one.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/pex-one.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-one.c $(OUTPUT_OPTION)
>  
>  ./pex-unix.$(objext): $(srcdir)/pex-unix.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
> @@ -1111,7 +1121,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-unix.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/pex-unix.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-unix.c $(OUTPUT_OPTION)
>  
>  ./pex-win32.$(objext): $(srcdir)/pex-win32.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
> @@ -1121,7 +1131,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-win32.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/pex-win32.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-win32.c $(OUTPUT_OPTION)
>  
>  ./pexecute.$(objext): $(srcdir)/pexecute.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1131,7 +1141,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pexecute.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/pexecute.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/pexecute.c $(OUTPUT_OPTION)
>  
>  ./physmem.$(objext): $(srcdir)/physmem.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1141,7 +1151,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/physmem.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/physmem.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/physmem.c $(OUTPUT_OPTION)
>  
>  ./putenv.$(objext): $(srcdir)/putenv.c config.h $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1150,7 +1160,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/putenv.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/putenv.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/putenv.c $(OUTPUT_OPTION)
>  
>  ./random.$(objext): $(srcdir)/random.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1159,7 +1169,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/random.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/random.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/random.c $(OUTPUT_OPTION)
>  
>  ./regex.$(objext): $(srcdir)/regex.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/xregex.h $(INCDIR)/xregex2.h
> @@ -1169,7 +1179,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/regex.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/regex.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/regex.c $(OUTPUT_OPTION)
>  
>  ./rename.$(objext): $(srcdir)/rename.c config.h $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1178,7 +1188,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/rename.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/rename.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/rename.c $(OUTPUT_OPTION)
>  
>  ./rindex.$(objext): $(srcdir)/rindex.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1187,7 +1197,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/rindex.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/rindex.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/rindex.c $(OUTPUT_OPTION)
>  
>  ./safe-ctype.$(objext): $(srcdir)/safe-ctype.c $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/safe-ctype.h
> @@ -1197,7 +1207,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/safe-ctype.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/safe-ctype.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/safe-ctype.c $(OUTPUT_OPTION)
>  
>  ./setenv.$(objext): $(srcdir)/setenv.c config.h $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1206,7 +1216,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/setenv.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/setenv.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/setenv.c $(OUTPUT_OPTION)
>  
>  ./setproctitle.$(objext): $(srcdir)/setproctitle.c config.h $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1215,7 +1225,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/setproctitle.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/setproctitle.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/setproctitle.c $(OUTPUT_OPTION)
>  
>  ./sha1.$(objext): $(srcdir)/sha1.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/sha1.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1224,7 +1234,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sha1.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/sha1.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/sha1.c $(OUTPUT_OPTION)
>  
>  ./sigsetmask.$(objext): $(srcdir)/sigsetmask.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1233,7 +1243,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sigsetmask.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/sigsetmask.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/sigsetmask.c $(OUTPUT_OPTION)
>  
>  ./simple-object-coff.$(objext): $(srcdir)/simple-object-coff.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
> @@ -1244,7 +1254,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-coff.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/simple-object-coff.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-coff.c $(OUTPUT_OPTION)
>  
>  ./simple-object-elf.$(objext): $(srcdir)/simple-object-elf.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
> @@ -1255,7 +1265,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-elf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/simple-object-elf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-elf.c $(OUTPUT_OPTION)
>  
>  ./simple-object-mach-o.$(objext): $(srcdir)/simple-object-mach-o.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
> @@ -1266,7 +1276,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-mach-o.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/simple-object-mach-o.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-mach-o.c $(OUTPUT_OPTION)
>  
>  ./simple-object-xcoff.$(objext): $(srcdir)/simple-object-xcoff.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
> @@ -1277,7 +1287,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-xcoff.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/simple-object-xcoff.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-xcoff.c $(OUTPUT_OPTION)
>  
>  ./simple-object.$(objext): $(srcdir)/simple-object.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
> @@ -1288,7 +1298,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/simple-object.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object.c $(OUTPUT_OPTION)
>  
>  ./snprintf.$(objext): $(srcdir)/snprintf.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1297,7 +1307,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/snprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/snprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/snprintf.c $(OUTPUT_OPTION)
>  
>  ./sort.$(objext): $(srcdir)/sort.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(INCDIR)/sort.h
> @@ -1307,7 +1317,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sort.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/sort.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/sort.c $(OUTPUT_OPTION)
>  
>  ./spaces.$(objext): $(srcdir)/spaces.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1317,7 +1327,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/spaces.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/spaces.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/spaces.c $(OUTPUT_OPTION)
>  
>  ./splay-tree.$(objext): $(srcdir)/splay-tree.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(INCDIR)/splay-tree.h
> @@ -1327,7 +1337,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/splay-tree.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/splay-tree.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/splay-tree.c $(OUTPUT_OPTION)
>  
>  ./stack-limit.$(objext): $(srcdir)/stack-limit.c config.h $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1336,7 +1346,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stack-limit.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/stack-limit.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/stack-limit.c $(OUTPUT_OPTION)
>  
>  ./stpcpy.$(objext): $(srcdir)/stpcpy.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1345,7 +1355,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stpcpy.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/stpcpy.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/stpcpy.c $(OUTPUT_OPTION)
>  
>  ./stpncpy.$(objext): $(srcdir)/stpncpy.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1354,7 +1364,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stpncpy.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/stpncpy.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/stpncpy.c $(OUTPUT_OPTION)
>  
>  ./strcasecmp.$(objext): $(srcdir)/strcasecmp.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1363,7 +1373,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strcasecmp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strcasecmp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strcasecmp.c $(OUTPUT_OPTION)
>  
>  ./strchr.$(objext): $(srcdir)/strchr.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1372,7 +1382,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strchr.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strchr.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strchr.c $(OUTPUT_OPTION)
>  
>  ./strdup.$(objext): $(srcdir)/strdup.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1381,7 +1391,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strdup.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strdup.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strdup.c $(OUTPUT_OPTION)
>  
>  ./strerror.$(objext): $(srcdir)/strerror.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1391,7 +1401,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strerror.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strerror.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strerror.c $(OUTPUT_OPTION)
>  
>  ./strncasecmp.$(objext): $(srcdir)/strncasecmp.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1400,7 +1410,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strncasecmp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strncasecmp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strncasecmp.c $(OUTPUT_OPTION)
>  
>  ./strncmp.$(objext): $(srcdir)/strncmp.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1409,7 +1419,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strncmp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strncmp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strncmp.c $(OUTPUT_OPTION)
>  
>  ./strndup.$(objext): $(srcdir)/strndup.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1418,7 +1428,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strndup.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strndup.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strndup.c $(OUTPUT_OPTION)
>  
>  ./strnlen.$(objext): $(srcdir)/strnlen.c config.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1427,7 +1437,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strnlen.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strnlen.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strnlen.c $(OUTPUT_OPTION)
>  
>  ./strrchr.$(objext): $(srcdir)/strrchr.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1436,7 +1446,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strrchr.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strrchr.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strrchr.c $(OUTPUT_OPTION)
>  
>  ./strsignal.$(objext): $(srcdir)/strsignal.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1446,7 +1456,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strsignal.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strsignal.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strsignal.c $(OUTPUT_OPTION)
>  
>  ./strstr.$(objext): $(srcdir)/strstr.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1455,7 +1465,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strstr.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strstr.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strstr.c $(OUTPUT_OPTION)
>  
>  ./strtod.$(objext): $(srcdir)/strtod.c $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/safe-ctype.h
> @@ -1465,7 +1475,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtod.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strtod.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strtod.c $(OUTPUT_OPTION)
>  
>  ./strtol.$(objext): $(srcdir)/strtol.c config.h $(INCDIR)/safe-ctype.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1474,7 +1484,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtol.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strtol.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strtol.c $(OUTPUT_OPTION)
>  
>  ./strtoll.$(objext): $(srcdir)/strtoll.c config.h $(INCDIR)/safe-ctype.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1483,7 +1493,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoll.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strtoll.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoll.c $(OUTPUT_OPTION)
>  
>  ./strtoul.$(objext): $(srcdir)/strtoul.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/safe-ctype.h
> @@ -1493,7 +1503,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoul.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strtoul.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoul.c $(OUTPUT_OPTION)
>  
>  ./strtoull.$(objext): $(srcdir)/strtoull.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/safe-ctype.h
> @@ -1503,7 +1513,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoull.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strtoull.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoull.c $(OUTPUT_OPTION)
>  
>  ./strverscmp.$(objext): $(srcdir)/strverscmp.c $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
> @@ -1513,7 +1523,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strverscmp.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/strverscmp.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/strverscmp.c $(OUTPUT_OPTION)
>  
>  ./timeval-utils.$(objext): $(srcdir)/timeval-utils.c config.h \
>  	$(INCDIR)/timeval-utils.h
> @@ -1523,7 +1533,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/timeval-utils.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/timeval-utils.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/timeval-utils.c $(OUTPUT_OPTION)
>  
>  ./tmpnam.$(objext): $(srcdir)/tmpnam.c
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1542,7 +1552,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/unlink-if-ordinary.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/unlink-if-ordinary.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/unlink-if-ordinary.c $(OUTPUT_OPTION)
>  
>  ./vasprintf.$(objext): $(srcdir)/vasprintf.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(srcdir)/vprintf-support.h
> @@ -1552,7 +1562,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vasprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/vasprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/vasprintf.c $(OUTPUT_OPTION)
>  
>  ./vfork.$(objext): $(srcdir)/vfork.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1561,7 +1571,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vfork.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/vfork.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/vfork.c $(OUTPUT_OPTION)
>  
>  ./vfprintf.$(objext): $(srcdir)/vfprintf.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1570,7 +1580,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vfprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/vfprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/vfprintf.c $(OUTPUT_OPTION)
>  
>  ./vprintf-support.$(objext): $(srcdir)/vprintf-support.c config.h \
>  	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
> @@ -1580,7 +1590,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vprintf-support.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/vprintf-support.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/vprintf-support.c $(OUTPUT_OPTION)
>  
>  ./vprintf.$(objext): $(srcdir)/vprintf.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1589,7 +1599,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/vprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/vprintf.c $(OUTPUT_OPTION)
>  
>  ./vsnprintf.$(objext): $(srcdir)/vsnprintf.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1599,7 +1609,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vsnprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/vsnprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/vsnprintf.c $(OUTPUT_OPTION)
>  
>  ./vsprintf.$(objext): $(srcdir)/vsprintf.c $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1608,7 +1618,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vsprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/vsprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/vsprintf.c $(OUTPUT_OPTION)
>  
>  ./waitpid.$(objext): $(srcdir)/waitpid.c config.h $(INCDIR)/ansidecl.h
>  	if [ x"$(PICFLAG)" != x ]; then \
> @@ -1617,7 +1627,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/waitpid.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/waitpid.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/waitpid.c $(OUTPUT_OPTION)
>  
>  ./xasprintf.$(objext): $(srcdir)/xasprintf.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1627,7 +1637,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xasprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xasprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xasprintf.c $(OUTPUT_OPTION)
>  
>  ./xatexit.$(objext): $(srcdir)/xatexit.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1637,7 +1647,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xatexit.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xatexit.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xatexit.c $(OUTPUT_OPTION)
>  
>  ./xexit.$(objext): $(srcdir)/xexit.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1647,7 +1657,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xexit.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xexit.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xexit.c $(OUTPUT_OPTION)
>  
>  ./xmalloc.$(objext): $(srcdir)/xmalloc.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1657,7 +1667,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xmalloc.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xmalloc.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xmalloc.c $(OUTPUT_OPTION)
>  
>  ./xmemdup.$(objext): $(srcdir)/xmemdup.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1667,7 +1677,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xmemdup.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xmemdup.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xmemdup.c $(OUTPUT_OPTION)
>  
>  ./xstrdup.$(objext): $(srcdir)/xstrdup.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1677,7 +1687,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrdup.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xstrdup.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrdup.c $(OUTPUT_OPTION)
>  
>  ./xstrerror.$(objext): $(srcdir)/xstrerror.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1687,7 +1697,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrerror.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xstrerror.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrerror.c $(OUTPUT_OPTION)
>  
>  ./xstrndup.$(objext): $(srcdir)/xstrndup.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h
> @@ -1697,7 +1707,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrndup.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xstrndup.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrndup.c $(OUTPUT_OPTION)
>  
>  ./xvasprintf.$(objext): $(srcdir)/xvasprintf.c config.h $(INCDIR)/ansidecl.h \
>  	$(INCDIR)/libiberty.h $(srcdir)/vprintf-support.h
> @@ -1707,4 +1717,4 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
>  	if [ x"$(NOASANFLAG)" != x ]; then \
>  	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xvasprintf.c -o noasan/$@; \
>  	else true; fi
> -	$(COMPILE.c) $(srcdir)/xvasprintf.c $(OUTPUT_OPTION)
> +	$(COMPILE.c) $(NONPIC) $(srcdir)/xvasprintf.c $(OUTPUT_OPTION)
> diff --git a/libiberty/configure.ac b/libiberty/configure.ac
> index 922aa86..6ca85f6 100644
> --- a/libiberty/configure.ac
> +++ b/libiberty/configure.ac
> @@ -231,10 +231,19 @@ if [[ "${enable_host_shared}" = "yes" ]]; then
>    shared=yes
>  fi
>  
> +NOPICFLAG=
> +case "${host}" in
> +  i[[34567]]86-*-darwin* | powerpc-*-darwin*)
> +    NOPICFLAG=-mdynamic-no-pic ;;
> +  *) ;;
> +esac
> +
>  if [[ "${shared}" != "yes" ]]; then
>    PICFLAG=
> +  NOPICFLAG=
>  fi
>  AC_SUBST(PICFLAG)
> +AC_SUBST(NOPICFLAG)
>  
>  NOASANFLAG=
>  case " ${CFLAGS} " in

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2015-02-11 14:38                 ` Iain Sandoe
@ 2015-03-08 17:38                   ` Iain Sandoe
  2015-03-08 17:48                     ` Ian Lance Taylor
  2015-03-09 18:43                     ` Mike Stump
  0 siblings, 2 replies; 36+ messages in thread
From: Iain Sandoe @ 2015-03-08 17:38 UTC (permalink / raw)
  To: Jeff Law
  Cc: gcc-patches Patches, DJ Delorie, FX, Rainer Orth,
	Dominique Dhumieres, Ian Lance Taylor

[-- Attachment #1: Type: text/plain, Size: 3274 bytes --]

+Ian
+ ping

On 11 Feb 2015, at 14:37, Iain Sandoe wrote:

> Hi Jeff,
> 
> On 9 Feb 2015, at 14:47, Jeff Law <law@redhat.com> wrote:
> 
>> On 02/01/15 09:42, Iain Sandoe wrote:
>>> 
>>> This is a GCC5 bootstrap regression on 32bit Darwin hosts ( I can raise a PR if that is considered necessary).
>> Has this been addressed or is it still pending?
> 
> I believe it's still awaiting review

Dominque has raised PR65351 to track this.
(i can rebase the patch if needed, it's being regularly tested on trunk)

thanks, 
Iain

> 
>> 
>> 
>>> 
>>> In fact it is not libcc1, but libiberty that is the cause -
>>> 
>>> On 26 Jan 2015, at 14:13, Rainer Orth wrote:
>>> 
>>>> FX <fxcoudert@gmail.com> writes:
>>>> 
>>>>>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>>>>>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB
>>>>>> -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>>>>>> This means that the PIC library is being built with non-pic relocs.
>>>>> 
>>>>> config/mh-darwin says that -mdynamic-no-pic is there because it “speeds
>>>>> compiles by 3-5%”. I don’t think we care about speed when the bootstrap
>>>>> fails, so can we remove it altogether?
>>>> 
>>>> Darwin/i686 still doesn't bootstrap without this patch, I believe.
>>>> Shouldn't it be applied to trunk before GCC 5 ships, rather than leaving
>>>> that target broken?
>>> 
>>> The PIC variant of libiberty, has never (since it was added, AFAICT) catered for the possibility that non-PIC and PIC options might conflict (and/or that it might not be possible to override non-PIC options simply by appending PIC ones).
>>> 
>>> This has gone un-noticed until the libcc1 plugin started linking with the pic version of libiberty.
>>> 
>>> Darwin uses -mdynamic-no-pic as a default flag during bootstrap for 32bit targets, since that gives a stated ~ 3-5% improvement in performance.
>>> 
>>> It is not possible to override this non-pic option by appending -fPIC (that simply results in a warning that mdynamic-no-pic takes precedence).
>>> 
>>> I'd rather not pretend that there's no problem and simply penalise performance on m32 darwin by removing the option from the bootflags.
>>> 
>>> So here's a patch that allows a target to declare incompatible non-pic options (in the same way that we have PIC options already declared as distinct).
>>> 
>>> The patch is largely mechanical (each of the targets adjusted to use the NONPIC flag for the relevant case).
>>> 
>>> As an aside, is there a portability reason that we don't make this repeated operation into a make function?
>>> 
>>> bootstapped on x86_64-linux, x86_64-darwin12, i686-darwin10, powerpc-darwin9,
>>> cross-compiled x86-64-darwin12 X i686-darwin10 , native X i686-darwin10 (x86_64-darwin12 build).
>>> 
>>> all languages including Ada (note that there's a local patch needed to work-around an Ada bootstrap issue - pr64349)
>>> 
>>> OK for trunk?
>>> Iain
>>> 
>>> libiberty:
>>> 	* Makefile.in (NONPICFLAG, NEWCFLAGS, NEWCPPFLAGS): New.
>>> 	(COMPILE.c): Adjust to use new flags. (all non-pic targets):
>>> 	Adjust to use NONPIC flag.
>>> 	* configure.ac (NOPICFLAG): New.
>>> 	* configure: Regenerate.
>>> 
>> 
> 

[-- Attachment #2: darwin-libiberty-m32.txt --]
[-- Type: text/plain, Size: 55428 bytes --]

diff --git a/libiberty/Makefile.in b/libiberty/Makefile.in
index f06cc69..8674b4a 100644
--- a/libiberty/Makefile.in
+++ b/libiberty/Makefile.in
@@ -62,6 +62,7 @@ MAKEINFO = @MAKEINFO@
 PERL = @PERL@
 
 PICFLAG = @PICFLAG@
+NOPICFLAG = @NOPICFLAG@
 NOASANFLAG = @NOASANFLAG@
 
 MAKEOVERRIDES =
@@ -113,7 +114,16 @@ installcheck: installcheck-subdir
 
 INCDIR=$(srcdir)/$(MULTISRCTOP)../include
 
-COMPILE.c = $(CC) -c @DEFS@ $(CFLAGS) $(CPPFLAGS) -I. -I$(INCDIR) $(HDEFINES) @ac_libiberty_warn_cflags@
+# If the passed CFLAGS or CPPFLAGS include options which are incompatible
+# with PIC code (and cannot be overridden) save them for non-pic code...
+NONPIC = $(filter $(NOPICFLAG), $(CFLAGS))
+NONPIC += $(filter $(NOPICFLAG), $(CPPFLAGS))
+# ... and then remove them from the default.
+NEWCFLAGS = $(filter-out $(NOPICFLAG), $(CFLAGS))
+NEWCPPFLAGS = $(filter-out $(NOPICFLAG), $(CPPFLAGS))
+
+COMPILE.c = $(CC) -c @DEFS@ $(NEWCFLAGS) $(NEWCPPFLAGS) -I. -I$(INCDIR) \
+            $(HDEFINES) @ac_libiberty_warn_cflags@
 
 # Just to make sure we don't use a built-in rule with VPATH
 .c.$(objext):
@@ -519,7 +529,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/_doprnt.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/_doprnt.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/_doprnt.c $(OUTPUT_OPTION)
 
 ./alloca.$(objext): $(srcdir)/alloca.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -529,7 +539,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/alloca.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/alloca.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/alloca.c $(OUTPUT_OPTION)
 
 ./argv.$(objext): $(srcdir)/argv.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
@@ -539,7 +549,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/argv.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/argv.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/argv.c $(OUTPUT_OPTION)
 
 ./asprintf.$(objext): $(srcdir)/asprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -549,7 +559,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/asprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/asprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/asprintf.c $(OUTPUT_OPTION)
 
 ./atexit.$(objext): $(srcdir)/atexit.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -558,7 +568,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/atexit.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/atexit.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/atexit.c $(OUTPUT_OPTION)
 
 ./basename.$(objext): $(srcdir)/basename.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
@@ -568,7 +578,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/basename.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/basename.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/basename.c $(OUTPUT_OPTION)
 
 ./bcmp.$(objext): $(srcdir)/bcmp.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -577,7 +587,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bcmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/bcmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/bcmp.c $(OUTPUT_OPTION)
 
 ./bcopy.$(objext): $(srcdir)/bcopy.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -586,7 +596,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bcopy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/bcopy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/bcopy.c $(OUTPUT_OPTION)
 
 ./bsearch.$(objext): $(srcdir)/bsearch.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -595,7 +605,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bsearch.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/bsearch.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/bsearch.c $(OUTPUT_OPTION)
 
 ./bzero.$(objext): $(srcdir)/bzero.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -604,7 +614,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bzero.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/bzero.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/bzero.c $(OUTPUT_OPTION)
 
 ./calloc.$(objext): $(srcdir)/calloc.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -613,7 +623,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/calloc.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/calloc.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/calloc.c $(OUTPUT_OPTION)
 
 ./choose-temp.$(objext): $(srcdir)/choose-temp.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -623,7 +633,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/choose-temp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/choose-temp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/choose-temp.c $(OUTPUT_OPTION)
 
 ./clock.$(objext): $(srcdir)/clock.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -632,7 +642,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/clock.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/clock.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/clock.c $(OUTPUT_OPTION)
 
 ./concat.$(objext): $(srcdir)/concat.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -642,7 +652,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/concat.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/concat.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/concat.c $(OUTPUT_OPTION)
 
 ./copysign.$(objext): $(srcdir)/copysign.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -651,7 +661,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/copysign.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/copysign.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/copysign.c $(OUTPUT_OPTION)
 
 ./cp-demangle.$(objext): $(srcdir)/cp-demangle.c config.h $(INCDIR)/ansidecl.h \
 	$(srcdir)/cp-demangle.h $(INCDIR)/demangle.h \
@@ -662,7 +672,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cp-demangle.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/cp-demangle.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/cp-demangle.c $(OUTPUT_OPTION)
 
 ./cp-demint.$(objext): $(srcdir)/cp-demint.c config.h $(INCDIR)/ansidecl.h \
 	$(srcdir)/cp-demangle.h $(INCDIR)/demangle.h \
@@ -673,7 +683,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cp-demint.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/cp-demint.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/cp-demint.c $(OUTPUT_OPTION)
 
 ./cplus-dem.$(objext): $(srcdir)/cplus-dem.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/demangle.h $(INCDIR)/libiberty.h \
@@ -684,7 +694,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cplus-dem.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/cplus-dem.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/cplus-dem.c $(OUTPUT_OPTION)
 
 ./crc32.$(objext): $(srcdir)/crc32.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -694,7 +704,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/crc32.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/crc32.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/crc32.c $(OUTPUT_OPTION)
 
 ./d-demangle.$(objext): $(srcdir)/d-demangle.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/demangle.h $(INCDIR)/libiberty.h \
@@ -705,7 +715,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/d-demangle.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/d-demangle.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/d-demangle.c $(OUTPUT_OPTION)
 
 ./dwarfnames.$(objext): $(srcdir)/dwarfnames.c $(INCDIR)/dwarf2.def \
 	$(INCDIR)/dwarf2.h
@@ -715,7 +725,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/dwarfnames.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/dwarfnames.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/dwarfnames.c $(OUTPUT_OPTION)
 
 ./dyn-string.$(objext): $(srcdir)/dyn-string.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/dyn-string.h $(INCDIR)/libiberty.h
@@ -725,7 +735,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/dyn-string.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/dyn-string.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/dyn-string.c $(OUTPUT_OPTION)
 
 ./fdmatch.$(objext): $(srcdir)/fdmatch.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -735,7 +745,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fdmatch.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/fdmatch.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/fdmatch.c $(OUTPUT_OPTION)
 
 ./ffs.$(objext): $(srcdir)/ffs.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -744,7 +754,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/ffs.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/ffs.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/ffs.c $(OUTPUT_OPTION)
 
 ./fibheap.$(objext): $(srcdir)/fibheap.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/fibheap.h $(INCDIR)/libiberty.h
@@ -754,7 +764,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fibheap.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/fibheap.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/fibheap.c $(OUTPUT_OPTION)
 
 ./filename_cmp.$(objext): $(srcdir)/filename_cmp.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/filenames.h $(INCDIR)/hashtab.h \
@@ -765,7 +775,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/filename_cmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/filename_cmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/filename_cmp.c $(OUTPUT_OPTION)
 
 ./floatformat.$(objext): $(srcdir)/floatformat.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/floatformat.h $(INCDIR)/libiberty.h
@@ -775,7 +785,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/floatformat.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/floatformat.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/floatformat.c $(OUTPUT_OPTION)
 
 ./fnmatch.$(objext): $(srcdir)/fnmatch.c config.h $(INCDIR)/fnmatch.h \
 	$(INCDIR)/safe-ctype.h
@@ -785,7 +795,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fnmatch.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/fnmatch.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/fnmatch.c $(OUTPUT_OPTION)
 
 ./fopen_unlocked.$(objext): $(srcdir)/fopen_unlocked.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
@@ -795,7 +805,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fopen_unlocked.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/fopen_unlocked.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/fopen_unlocked.c $(OUTPUT_OPTION)
 
 ./getcwd.$(objext): $(srcdir)/getcwd.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -804,7 +814,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getcwd.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getcwd.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getcwd.c $(OUTPUT_OPTION)
 
 ./getopt.$(objext): $(srcdir)/getopt.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/getopt.h
@@ -814,7 +824,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getopt.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getopt.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getopt.c $(OUTPUT_OPTION)
 
 ./getopt1.$(objext): $(srcdir)/getopt1.c config.h $(INCDIR)/getopt.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -823,7 +833,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getopt1.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getopt1.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getopt1.c $(OUTPUT_OPTION)
 
 ./getpagesize.$(objext): $(srcdir)/getpagesize.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -832,7 +842,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getpagesize.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getpagesize.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getpagesize.c $(OUTPUT_OPTION)
 
 ./getpwd.$(objext): $(srcdir)/getpwd.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -842,7 +852,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getpwd.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getpwd.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getpwd.c $(OUTPUT_OPTION)
 
 ./getruntime.$(objext): $(srcdir)/getruntime.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -852,7 +862,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getruntime.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getruntime.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getruntime.c $(OUTPUT_OPTION)
 
 ./gettimeofday.$(objext): $(srcdir)/gettimeofday.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -862,7 +872,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/gettimeofday.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/gettimeofday.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/gettimeofday.c $(OUTPUT_OPTION)
 
 ./hashtab.$(objext): $(srcdir)/hashtab.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/hashtab.h $(INCDIR)/libiberty.h
@@ -872,7 +882,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/hashtab.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/hashtab.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/hashtab.c $(OUTPUT_OPTION)
 
 ./hex.$(objext): $(srcdir)/hex.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
@@ -882,7 +892,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/hex.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/hex.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/hex.c $(OUTPUT_OPTION)
 
 ./index.$(objext): $(srcdir)/index.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -891,7 +901,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/index.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/index.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/index.c $(OUTPUT_OPTION)
 
 ./insque.$(objext): $(srcdir)/insque.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -900,7 +910,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/insque.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/insque.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/insque.c $(OUTPUT_OPTION)
 
 ./lbasename.$(objext): $(srcdir)/lbasename.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/filenames.h $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h \
@@ -911,7 +921,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/lbasename.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/lbasename.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/lbasename.c $(OUTPUT_OPTION)
 
 ./lrealpath.$(objext): $(srcdir)/lrealpath.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -921,7 +931,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/lrealpath.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/lrealpath.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/lrealpath.c $(OUTPUT_OPTION)
 
 ./make-relative-prefix.$(objext): $(srcdir)/make-relative-prefix.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
@@ -931,7 +941,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/make-relative-prefix.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/make-relative-prefix.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/make-relative-prefix.c $(OUTPUT_OPTION)
 
 ./make-temp-file.$(objext): $(srcdir)/make-temp-file.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
@@ -941,7 +951,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/make-temp-file.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/make-temp-file.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/make-temp-file.c $(OUTPUT_OPTION)
 
 ./md5.$(objext): $(srcdir)/md5.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/md5.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -950,7 +960,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/md5.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/md5.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/md5.c $(OUTPUT_OPTION)
 
 ./memchr.$(objext): $(srcdir)/memchr.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -959,7 +969,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memchr.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memchr.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memchr.c $(OUTPUT_OPTION)
 
 ./memcmp.$(objext): $(srcdir)/memcmp.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -968,7 +978,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memcmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memcmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memcmp.c $(OUTPUT_OPTION)
 
 ./memcpy.$(objext): $(srcdir)/memcpy.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -977,7 +987,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memcpy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memcpy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memcpy.c $(OUTPUT_OPTION)
 
 ./memmem.$(objext): $(srcdir)/memmem.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -986,7 +996,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memmem.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memmem.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memmem.c $(OUTPUT_OPTION)
 
 ./memmove.$(objext): $(srcdir)/memmove.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -995,7 +1005,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memmove.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memmove.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memmove.c $(OUTPUT_OPTION)
 
 ./mempcpy.$(objext): $(srcdir)/mempcpy.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1004,7 +1014,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/mempcpy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/mempcpy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/mempcpy.c $(OUTPUT_OPTION)
 
 ./memset.$(objext): $(srcdir)/memset.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1013,7 +1023,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memset.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memset.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memset.c $(OUTPUT_OPTION)
 
 ./mkstemps.$(objext): $(srcdir)/mkstemps.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1022,7 +1032,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/mkstemps.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/mkstemps.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/mkstemps.c $(OUTPUT_OPTION)
 
 ./msdos.$(objext): $(srcdir)/msdos.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1031,7 +1041,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/msdos.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/msdos.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/msdos.c $(OUTPUT_OPTION)
 
 ./objalloc.$(objext): $(srcdir)/objalloc.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/objalloc.h
@@ -1041,7 +1051,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/objalloc.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/objalloc.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/objalloc.c $(OUTPUT_OPTION)
 
 ./obstack.$(objext): $(srcdir)/obstack.c config.h $(INCDIR)/obstack.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1050,7 +1060,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/obstack.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/obstack.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/obstack.c $(OUTPUT_OPTION)
 
 ./partition.$(objext): $(srcdir)/partition.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/partition.h
@@ -1060,7 +1070,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/partition.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/partition.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/partition.c $(OUTPUT_OPTION)
 
 ./pex-common.$(objext): $(srcdir)/pex-common.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
@@ -1070,7 +1080,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-common.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-common.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-common.c $(OUTPUT_OPTION)
 
 ./pex-djgpp.$(objext): $(srcdir)/pex-djgpp.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
@@ -1080,7 +1090,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-djgpp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-djgpp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-djgpp.c $(OUTPUT_OPTION)
 
 ./pex-msdos.$(objext): $(srcdir)/pex-msdos.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h \
@@ -1091,7 +1101,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-msdos.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-msdos.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-msdos.c $(OUTPUT_OPTION)
 
 ./pex-one.$(objext): $(srcdir)/pex-one.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1101,7 +1111,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-one.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-one.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-one.c $(OUTPUT_OPTION)
 
 ./pex-unix.$(objext): $(srcdir)/pex-unix.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
@@ -1111,7 +1121,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-unix.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-unix.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-unix.c $(OUTPUT_OPTION)
 
 ./pex-win32.$(objext): $(srcdir)/pex-win32.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
@@ -1121,7 +1131,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-win32.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-win32.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-win32.c $(OUTPUT_OPTION)
 
 ./pexecute.$(objext): $(srcdir)/pexecute.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1131,7 +1141,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pexecute.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pexecute.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pexecute.c $(OUTPUT_OPTION)
 
 ./physmem.$(objext): $(srcdir)/physmem.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1141,7 +1151,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/physmem.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/physmem.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/physmem.c $(OUTPUT_OPTION)
 
 ./putenv.$(objext): $(srcdir)/putenv.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1150,7 +1160,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/putenv.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/putenv.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/putenv.c $(OUTPUT_OPTION)
 
 ./random.$(objext): $(srcdir)/random.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1159,7 +1169,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/random.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/random.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/random.c $(OUTPUT_OPTION)
 
 ./regex.$(objext): $(srcdir)/regex.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/xregex.h $(INCDIR)/xregex2.h
@@ -1169,7 +1179,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/regex.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/regex.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/regex.c $(OUTPUT_OPTION)
 
 ./rename.$(objext): $(srcdir)/rename.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1178,7 +1188,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/rename.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/rename.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/rename.c $(OUTPUT_OPTION)
 
 ./rindex.$(objext): $(srcdir)/rindex.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1187,7 +1197,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/rindex.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/rindex.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/rindex.c $(OUTPUT_OPTION)
 
 ./safe-ctype.$(objext): $(srcdir)/safe-ctype.c $(INCDIR)/ansidecl.h \
 	$(INCDIR)/safe-ctype.h
@@ -1197,7 +1207,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/safe-ctype.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/safe-ctype.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/safe-ctype.c $(OUTPUT_OPTION)
 
 ./setenv.$(objext): $(srcdir)/setenv.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1206,7 +1216,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/setenv.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/setenv.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/setenv.c $(OUTPUT_OPTION)
 
 ./setproctitle.$(objext): $(srcdir)/setproctitle.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1215,7 +1225,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/setproctitle.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/setproctitle.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/setproctitle.c $(OUTPUT_OPTION)
 
 ./sha1.$(objext): $(srcdir)/sha1.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/sha1.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1224,7 +1234,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sha1.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/sha1.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/sha1.c $(OUTPUT_OPTION)
 
 ./sigsetmask.$(objext): $(srcdir)/sigsetmask.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1233,7 +1243,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sigsetmask.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/sigsetmask.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/sigsetmask.c $(OUTPUT_OPTION)
 
 ./simple-object-coff.$(objext): $(srcdir)/simple-object-coff.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1244,7 +1254,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-coff.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object-coff.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-coff.c $(OUTPUT_OPTION)
 
 ./simple-object-elf.$(objext): $(srcdir)/simple-object-elf.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1255,7 +1265,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-elf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object-elf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-elf.c $(OUTPUT_OPTION)
 
 ./simple-object-mach-o.$(objext): $(srcdir)/simple-object-mach-o.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1266,7 +1276,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-mach-o.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object-mach-o.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-mach-o.c $(OUTPUT_OPTION)
 
 ./simple-object-xcoff.$(objext): $(srcdir)/simple-object-xcoff.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1277,7 +1287,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-xcoff.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object-xcoff.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-xcoff.c $(OUTPUT_OPTION)
 
 ./simple-object.$(objext): $(srcdir)/simple-object.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1288,7 +1298,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object.c $(OUTPUT_OPTION)
 
 ./snprintf.$(objext): $(srcdir)/snprintf.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1297,7 +1307,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/snprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/snprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/snprintf.c $(OUTPUT_OPTION)
 
 ./sort.$(objext): $(srcdir)/sort.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/sort.h
@@ -1307,7 +1317,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sort.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/sort.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/sort.c $(OUTPUT_OPTION)
 
 ./spaces.$(objext): $(srcdir)/spaces.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1317,7 +1327,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/spaces.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/spaces.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/spaces.c $(OUTPUT_OPTION)
 
 ./splay-tree.$(objext): $(srcdir)/splay-tree.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/splay-tree.h
@@ -1327,7 +1337,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/splay-tree.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/splay-tree.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/splay-tree.c $(OUTPUT_OPTION)
 
 ./stack-limit.$(objext): $(srcdir)/stack-limit.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1336,7 +1346,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stack-limit.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/stack-limit.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/stack-limit.c $(OUTPUT_OPTION)
 
 ./stpcpy.$(objext): $(srcdir)/stpcpy.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1345,7 +1355,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stpcpy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/stpcpy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/stpcpy.c $(OUTPUT_OPTION)
 
 ./stpncpy.$(objext): $(srcdir)/stpncpy.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1354,7 +1364,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stpncpy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/stpncpy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/stpncpy.c $(OUTPUT_OPTION)
 
 ./strcasecmp.$(objext): $(srcdir)/strcasecmp.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1363,7 +1373,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strcasecmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strcasecmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strcasecmp.c $(OUTPUT_OPTION)
 
 ./strchr.$(objext): $(srcdir)/strchr.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1372,7 +1382,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strchr.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strchr.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strchr.c $(OUTPUT_OPTION)
 
 ./strdup.$(objext): $(srcdir)/strdup.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1381,7 +1391,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strdup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strdup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strdup.c $(OUTPUT_OPTION)
 
 ./strerror.$(objext): $(srcdir)/strerror.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1391,7 +1401,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strerror.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strerror.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strerror.c $(OUTPUT_OPTION)
 
 ./strncasecmp.$(objext): $(srcdir)/strncasecmp.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1400,7 +1410,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strncasecmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strncasecmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strncasecmp.c $(OUTPUT_OPTION)
 
 ./strncmp.$(objext): $(srcdir)/strncmp.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1409,7 +1419,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strncmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strncmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strncmp.c $(OUTPUT_OPTION)
 
 ./strndup.$(objext): $(srcdir)/strndup.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1418,7 +1428,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strndup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strndup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strndup.c $(OUTPUT_OPTION)
 
 ./strnlen.$(objext): $(srcdir)/strnlen.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1427,7 +1437,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strnlen.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strnlen.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strnlen.c $(OUTPUT_OPTION)
 
 ./strrchr.$(objext): $(srcdir)/strrchr.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1436,7 +1446,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strrchr.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strrchr.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strrchr.c $(OUTPUT_OPTION)
 
 ./strsignal.$(objext): $(srcdir)/strsignal.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1446,7 +1456,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strsignal.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strsignal.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strsignal.c $(OUTPUT_OPTION)
 
 ./strstr.$(objext): $(srcdir)/strstr.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1455,7 +1465,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strstr.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strstr.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strstr.c $(OUTPUT_OPTION)
 
 ./strtod.$(objext): $(srcdir)/strtod.c $(INCDIR)/ansidecl.h \
 	$(INCDIR)/safe-ctype.h
@@ -1465,7 +1475,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtod.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtod.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtod.c $(OUTPUT_OPTION)
 
 ./strtol.$(objext): $(srcdir)/strtol.c config.h $(INCDIR)/safe-ctype.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1474,7 +1484,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtol.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtol.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtol.c $(OUTPUT_OPTION)
 
 ./strtoll.$(objext): $(srcdir)/strtoll.c config.h $(INCDIR)/safe-ctype.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1483,7 +1493,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoll.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtoll.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoll.c $(OUTPUT_OPTION)
 
 ./strtoul.$(objext): $(srcdir)/strtoul.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/safe-ctype.h
@@ -1493,7 +1503,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoul.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtoul.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoul.c $(OUTPUT_OPTION)
 
 ./strtoull.$(objext): $(srcdir)/strtoull.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/safe-ctype.h
@@ -1503,7 +1513,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoull.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtoull.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoull.c $(OUTPUT_OPTION)
 
 ./strverscmp.$(objext): $(srcdir)/strverscmp.c $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
@@ -1513,7 +1523,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strverscmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strverscmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strverscmp.c $(OUTPUT_OPTION)
 
 ./timeval-utils.$(objext): $(srcdir)/timeval-utils.c config.h \
 	$(INCDIR)/timeval-utils.h
@@ -1523,7 +1533,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/timeval-utils.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/timeval-utils.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/timeval-utils.c $(OUTPUT_OPTION)
 
 ./tmpnam.$(objext): $(srcdir)/tmpnam.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1542,7 +1552,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/unlink-if-ordinary.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/unlink-if-ordinary.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/unlink-if-ordinary.c $(OUTPUT_OPTION)
 
 ./vasprintf.$(objext): $(srcdir)/vasprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/vprintf-support.h
@@ -1552,7 +1562,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vasprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vasprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vasprintf.c $(OUTPUT_OPTION)
 
 ./vfork.$(objext): $(srcdir)/vfork.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1561,7 +1571,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vfork.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vfork.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vfork.c $(OUTPUT_OPTION)
 
 ./vfprintf.$(objext): $(srcdir)/vfprintf.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1570,7 +1580,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vfprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vfprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vfprintf.c $(OUTPUT_OPTION)
 
 ./vprintf-support.$(objext): $(srcdir)/vprintf-support.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
@@ -1580,7 +1590,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vprintf-support.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vprintf-support.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vprintf-support.c $(OUTPUT_OPTION)
 
 ./vprintf.$(objext): $(srcdir)/vprintf.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1589,7 +1599,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vprintf.c $(OUTPUT_OPTION)
 
 ./vsnprintf.$(objext): $(srcdir)/vsnprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1599,7 +1609,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vsnprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vsnprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vsnprintf.c $(OUTPUT_OPTION)
 
 ./vsprintf.$(objext): $(srcdir)/vsprintf.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1608,7 +1618,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vsprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vsprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vsprintf.c $(OUTPUT_OPTION)
 
 ./waitpid.$(objext): $(srcdir)/waitpid.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1617,7 +1627,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/waitpid.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/waitpid.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/waitpid.c $(OUTPUT_OPTION)
 
 ./xasprintf.$(objext): $(srcdir)/xasprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1627,7 +1637,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xasprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xasprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xasprintf.c $(OUTPUT_OPTION)
 
 ./xatexit.$(objext): $(srcdir)/xatexit.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1637,7 +1647,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xatexit.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xatexit.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xatexit.c $(OUTPUT_OPTION)
 
 ./xexit.$(objext): $(srcdir)/xexit.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1647,7 +1657,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xexit.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xexit.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xexit.c $(OUTPUT_OPTION)
 
 ./xmalloc.$(objext): $(srcdir)/xmalloc.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1657,7 +1667,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xmalloc.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xmalloc.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xmalloc.c $(OUTPUT_OPTION)
 
 ./xmemdup.$(objext): $(srcdir)/xmemdup.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1667,7 +1677,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xmemdup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xmemdup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xmemdup.c $(OUTPUT_OPTION)
 
 ./xstrdup.$(objext): $(srcdir)/xstrdup.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1677,7 +1687,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrdup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xstrdup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrdup.c $(OUTPUT_OPTION)
 
 ./xstrerror.$(objext): $(srcdir)/xstrerror.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1687,7 +1697,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrerror.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xstrerror.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrerror.c $(OUTPUT_OPTION)
 
 ./xstrndup.$(objext): $(srcdir)/xstrndup.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1697,7 +1707,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrndup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xstrndup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrndup.c $(OUTPUT_OPTION)
 
 ./xvasprintf.$(objext): $(srcdir)/xvasprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/vprintf-support.h
@@ -1707,4 +1717,4 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xvasprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xvasprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xvasprintf.c $(OUTPUT_OPTION)
diff --git a/libiberty/configure.ac b/libiberty/configure.ac
index 922aa86..6ca85f6 100644
--- a/libiberty/configure.ac
+++ b/libiberty/configure.ac
@@ -231,10 +231,19 @@ if [[ "${enable_host_shared}" = "yes" ]]; then
   shared=yes
 fi
 
+NOPICFLAG=
+case "${host}" in
+  i[[34567]]86-*-darwin* | powerpc-*-darwin*)
+    NOPICFLAG=-mdynamic-no-pic ;;
+  *) ;;
+esac
+
 if [[ "${shared}" != "yes" ]]; then
   PICFLAG=
+  NOPICFLAG=
 fi
 AC_SUBST(PICFLAG)
+AC_SUBST(NOPICFLAG)
 
 NOASANFLAG=
 case " ${CFLAGS} " in

[-- Attachment #3: Type: text/plain, Size: 1 bytes --]



^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2015-02-09 22:47               ` Jeff Law
@ 2015-02-11 14:38                 ` Iain Sandoe
  2015-03-08 17:38                   ` Iain Sandoe
  0 siblings, 1 reply; 36+ messages in thread
From: Iain Sandoe @ 2015-02-11 14:38 UTC (permalink / raw)
  To: Jeff Law; +Cc: gcc-patches, DJ Delorie, FX, Rainer Orth, Dominique Dhumieres

Hi Jeff,

On 9 Feb 2015, at 14:47, Jeff Law <law@redhat.com> wrote:

> On 02/01/15 09:42, Iain Sandoe wrote:
>> 
>> This is a GCC5 bootstrap regression on 32bit Darwin hosts ( I can raise a PR if that is considered necessary).
> Has this been addressed or is it still pending?

I believe it's still awaiting review - I'm travelling this week, so limited access to resources - but will be able to tackle any comments at the weekend.
thanks
Iain

> 
> 
>> 
>> In fact it is not libcc1, but libiberty that is the cause -
>> 
>> On 26 Jan 2015, at 14:13, Rainer Orth wrote:
>> 
>>> FX <fxcoudert@gmail.com> writes:
>>> 
>>>>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>>>>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB
>>>>> -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>>>>> This means that the PIC library is being built with non-pic relocs.
>>>> 
>>>> config/mh-darwin says that -mdynamic-no-pic is there because it “speeds
>>>> compiles by 3-5%”. I don’t think we care about speed when the bootstrap
>>>> fails, so can we remove it altogether?
>>> 
>>> Darwin/i686 still doesn't bootstrap without this patch, I believe.
>>> Shouldn't it be applied to trunk before GCC 5 ships, rather than leaving
>>> that target broken?
>> 
>> The PIC variant of libiberty, has never (since it was added, AFAICT) catered for the possibility that non-PIC and PIC options might conflict (and/or that it might not be possible to override non-PIC options simply by appending PIC ones).
>> 
>> This has gone un-noticed until the libcc1 plugin started linking with the pic version of libiberty.
>> 
>> Darwin uses -mdynamic-no-pic as a default flag during bootstrap for 32bit targets, since that gives a stated ~ 3-5% improvement in performance.
>> 
>> It is not possible to override this non-pic option by appending -fPIC (that simply results in a warning that mdynamic-no-pic takes precedence).
>> 
>> I'd rather not pretend that there's no problem and simply penalise performance on m32 darwin by removing the option from the bootflags.
>> 
>> So here's a patch that allows a target to declare incompatible non-pic options (in the same way that we have PIC options already declared as distinct).
>> 
>> The patch is largely mechanical (each of the targets adjusted to use the NONPIC flag for the relevant case).
>> 
>> As an aside, is there a portability reason that we don't make this repeated operation into a make function?
>> 
>> bootstapped on x86_64-linux, x86_64-darwin12, i686-darwin10, powerpc-darwin9,
>> cross-compiled x86-64-darwin12 X i686-darwin10 , native X i686-darwin10 (x86_64-darwin12 build).
>> 
>> all languages including Ada (note that there's a local patch needed to work-around an Ada bootstrap issue - pr64349)
>> 
>> OK for trunk?
>> Iain
>> 
>> libiberty:
>> 	* Makefile.in (NONPICFLAG, NEWCFLAGS, NEWCPPFLAGS): New.
>> 	(COMPILE.c): Adjust to use new flags. (all non-pic targets):
>> 	Adjust to use NONPIC flag.
>> 	* configure.ac (NOPICFLAG): New.
>> 	* configure: Regenerate.
>> 
> 

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2015-02-01 16:42             ` Iain Sandoe
@ 2015-02-09 22:47               ` Jeff Law
  2015-02-11 14:38                 ` Iain Sandoe
  0 siblings, 1 reply; 36+ messages in thread
From: Jeff Law @ 2015-02-09 22:47 UTC (permalink / raw)
  To: Iain Sandoe, gcc-patches; +Cc: DJ Delorie, FX, Rainer Orth, Dominique Dhumieres

On 02/01/15 09:42, Iain Sandoe wrote:
>
> This is a GCC5 bootstrap regression on 32bit Darwin hosts ( I can raise a PR if that is considered necessary).
Has this been addressed or is it still pending?


>
> In fact it is not libcc1, but libiberty that is the cause -
>
> On 26 Jan 2015, at 14:13, Rainer Orth wrote:
>
>> FX <fxcoudert@gmail.com> writes:
>>
>>>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>>>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB
>>>> -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>>>> This means that the PIC library is being built with non-pic relocs.
>>>
>>> config/mh-darwin says that -mdynamic-no-pic is there because it 隆掳speeds
>>> compiles by 3-5%隆卤. I don隆炉t think we care about speed when the bootstrap
>>> fails, so can we remove it altogether?
>>
>> Darwin/i686 still doesn't bootstrap without this patch, I believe.
>> Shouldn't it be applied to trunk before GCC 5 ships, rather than leaving
>> that target broken?
>
> The PIC variant of libiberty, has never (since it was added, AFAICT) catered for the possibility that non-PIC and PIC options might conflict (and/or that it might not be possible to override non-PIC options simply by appending PIC ones).
>
> This has gone un-noticed until the libcc1 plugin started linking with the pic version of libiberty.
>
> Darwin uses -mdynamic-no-pic as a default flag during bootstrap for 32bit targets, since that gives a stated ~ 3-5% improvement in performance.
>
> It is not possible to override this non-pic option by appending -fPIC (that simply results in a warning that mdynamic-no-pic takes precedence).
>
> I'd rather not pretend that there's no problem and simply penalise performance on m32 darwin by removing the option from the bootflags.
>
> So here's a patch that allows a target to declare incompatible non-pic options (in the same way that we have PIC options already declared as distinct).
>
> The patch is largely mechanical (each of the targets adjusted to use the NONPIC flag for the relevant case).
>
> As an aside, is there a portability reason that we don't make this repeated operation into a make function?
>
> bootstapped on x86_64-linux, x86_64-darwin12, i686-darwin10, powerpc-darwin9,
> cross-compiled x86-64-darwin12 X i686-darwin10 , native X i686-darwin10 (x86_64-darwin12 build).
>
> all languages including Ada (note that there's a local patch needed to work-around an Ada bootstrap issue - pr64349)
>
> OK for trunk?
> Iain
>
> libiberty:
> 	* Makefile.in (NONPICFLAG, NEWCFLAGS, NEWCPPFLAGS): New.
> 	(COMPILE.c): Adjust to use new flags. (all non-pic targets):
> 	Adjust to use NONPIC flag.
> 	* configure.ac (NOPICFLAG): New.
> 	* configure: Regenerate.
>

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2015-01-26 15:02           ` Rainer Orth
  2015-01-26 15:06             ` Iain Sandoe
@ 2015-02-01 16:42             ` Iain Sandoe
  2015-02-09 22:47               ` Jeff Law
  1 sibling, 1 reply; 36+ messages in thread
From: Iain Sandoe @ 2015-02-01 16:42 UTC (permalink / raw)
  To: gcc-patches; +Cc: DJ Delorie, FX, Rainer Orth, Dominique Dhumieres

[-- Attachment #1: Type: text/plain, Size: 2634 bytes --]


This is a GCC5 bootstrap regression on 32bit Darwin hosts ( I can raise a PR if that is considered necessary).

In fact it is not libcc1, but libiberty that is the cause - 

On 26 Jan 2015, at 14:13, Rainer Orth wrote:

> FX <fxcoudert@gmail.com> writes:
> 
>>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB
>>> -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>>> This means that the PIC library is being built with non-pic relocs.
>> 
>> config/mh-darwin says that -mdynamic-no-pic is there because it “speeds
>> compiles by 3-5%”. I don’t think we care about speed when the bootstrap
>> fails, so can we remove it altogether?
> 
> Darwin/i686 still doesn't bootstrap without this patch, I believe.
> Shouldn't it be applied to trunk before GCC 5 ships, rather than leaving
> that target broken?

The PIC variant of libiberty, has never (since it was added, AFAICT) catered for the possibility that non-PIC and PIC options might conflict (and/or that it might not be possible to override non-PIC options simply by appending PIC ones).

This has gone un-noticed until the libcc1 plugin started linking with the pic version of libiberty.

Darwin uses -mdynamic-no-pic as a default flag during bootstrap for 32bit targets, since that gives a stated ~ 3-5% improvement in performance.

It is not possible to override this non-pic option by appending -fPIC (that simply results in a warning that mdynamic-no-pic takes precedence).

I'd rather not pretend that there's no problem and simply penalise performance on m32 darwin by removing the option from the bootflags.

So here's a patch that allows a target to declare incompatible non-pic options (in the same way that we have PIC options already declared as distinct).

The patch is largely mechanical (each of the targets adjusted to use the NONPIC flag for the relevant case).

As an aside, is there a portability reason that we don't make this repeated operation into a make function?

bootstapped on x86_64-linux, x86_64-darwin12, i686-darwin10, powerpc-darwin9,
cross-compiled x86-64-darwin12 X i686-darwin10 , native X i686-darwin10 (x86_64-darwin12 build).

all languages including Ada (note that there's a local patch needed to work-around an Ada bootstrap issue - pr64349)

OK for trunk?
Iain

libiberty:
	* Makefile.in (NONPICFLAG, NEWCFLAGS, NEWCPPFLAGS): New.
	(COMPILE.c): Adjust to use new flags. (all non-pic targets):
	Adjust to use NONPIC flag.
	* configure.ac (NOPICFLAG): New.
	* configure: Regenerate.


[-- Attachment #2: darwin-libiberty-m32.txt --]
[-- Type: text/plain, Size: 55428 bytes --]

diff --git a/libiberty/Makefile.in b/libiberty/Makefile.in
index f06cc69..8674b4a 100644
--- a/libiberty/Makefile.in
+++ b/libiberty/Makefile.in
@@ -62,6 +62,7 @@ MAKEINFO = @MAKEINFO@
 PERL = @PERL@
 
 PICFLAG = @PICFLAG@
+NOPICFLAG = @NOPICFLAG@
 NOASANFLAG = @NOASANFLAG@
 
 MAKEOVERRIDES =
@@ -113,7 +114,16 @@ installcheck: installcheck-subdir
 
 INCDIR=$(srcdir)/$(MULTISRCTOP)../include
 
-COMPILE.c = $(CC) -c @DEFS@ $(CFLAGS) $(CPPFLAGS) -I. -I$(INCDIR) $(HDEFINES) @ac_libiberty_warn_cflags@
+# If the passed CFLAGS or CPPFLAGS include options which are incompatible
+# with PIC code (and cannot be overridden) save them for non-pic code...
+NONPIC = $(filter $(NOPICFLAG), $(CFLAGS))
+NONPIC += $(filter $(NOPICFLAG), $(CPPFLAGS))
+# ... and then remove them from the default.
+NEWCFLAGS = $(filter-out $(NOPICFLAG), $(CFLAGS))
+NEWCPPFLAGS = $(filter-out $(NOPICFLAG), $(CPPFLAGS))
+
+COMPILE.c = $(CC) -c @DEFS@ $(NEWCFLAGS) $(NEWCPPFLAGS) -I. -I$(INCDIR) \
+            $(HDEFINES) @ac_libiberty_warn_cflags@
 
 # Just to make sure we don't use a built-in rule with VPATH
 .c.$(objext):
@@ -519,7 +529,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/_doprnt.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/_doprnt.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/_doprnt.c $(OUTPUT_OPTION)
 
 ./alloca.$(objext): $(srcdir)/alloca.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -529,7 +539,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/alloca.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/alloca.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/alloca.c $(OUTPUT_OPTION)
 
 ./argv.$(objext): $(srcdir)/argv.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
@@ -539,7 +549,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/argv.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/argv.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/argv.c $(OUTPUT_OPTION)
 
 ./asprintf.$(objext): $(srcdir)/asprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -549,7 +559,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/asprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/asprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/asprintf.c $(OUTPUT_OPTION)
 
 ./atexit.$(objext): $(srcdir)/atexit.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -558,7 +568,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/atexit.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/atexit.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/atexit.c $(OUTPUT_OPTION)
 
 ./basename.$(objext): $(srcdir)/basename.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
@@ -568,7 +578,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/basename.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/basename.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/basename.c $(OUTPUT_OPTION)
 
 ./bcmp.$(objext): $(srcdir)/bcmp.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -577,7 +587,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bcmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/bcmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/bcmp.c $(OUTPUT_OPTION)
 
 ./bcopy.$(objext): $(srcdir)/bcopy.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -586,7 +596,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bcopy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/bcopy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/bcopy.c $(OUTPUT_OPTION)
 
 ./bsearch.$(objext): $(srcdir)/bsearch.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -595,7 +605,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bsearch.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/bsearch.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/bsearch.c $(OUTPUT_OPTION)
 
 ./bzero.$(objext): $(srcdir)/bzero.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -604,7 +614,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/bzero.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/bzero.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/bzero.c $(OUTPUT_OPTION)
 
 ./calloc.$(objext): $(srcdir)/calloc.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -613,7 +623,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/calloc.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/calloc.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/calloc.c $(OUTPUT_OPTION)
 
 ./choose-temp.$(objext): $(srcdir)/choose-temp.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -623,7 +633,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/choose-temp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/choose-temp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/choose-temp.c $(OUTPUT_OPTION)
 
 ./clock.$(objext): $(srcdir)/clock.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -632,7 +642,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/clock.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/clock.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/clock.c $(OUTPUT_OPTION)
 
 ./concat.$(objext): $(srcdir)/concat.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -642,7 +652,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/concat.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/concat.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/concat.c $(OUTPUT_OPTION)
 
 ./copysign.$(objext): $(srcdir)/copysign.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -651,7 +661,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/copysign.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/copysign.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/copysign.c $(OUTPUT_OPTION)
 
 ./cp-demangle.$(objext): $(srcdir)/cp-demangle.c config.h $(INCDIR)/ansidecl.h \
 	$(srcdir)/cp-demangle.h $(INCDIR)/demangle.h \
@@ -662,7 +672,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cp-demangle.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/cp-demangle.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/cp-demangle.c $(OUTPUT_OPTION)
 
 ./cp-demint.$(objext): $(srcdir)/cp-demint.c config.h $(INCDIR)/ansidecl.h \
 	$(srcdir)/cp-demangle.h $(INCDIR)/demangle.h \
@@ -673,7 +683,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cp-demint.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/cp-demint.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/cp-demint.c $(OUTPUT_OPTION)
 
 ./cplus-dem.$(objext): $(srcdir)/cplus-dem.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/demangle.h $(INCDIR)/libiberty.h \
@@ -684,7 +694,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/cplus-dem.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/cplus-dem.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/cplus-dem.c $(OUTPUT_OPTION)
 
 ./crc32.$(objext): $(srcdir)/crc32.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -694,7 +704,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/crc32.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/crc32.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/crc32.c $(OUTPUT_OPTION)
 
 ./d-demangle.$(objext): $(srcdir)/d-demangle.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/demangle.h $(INCDIR)/libiberty.h \
@@ -705,7 +715,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/d-demangle.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/d-demangle.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/d-demangle.c $(OUTPUT_OPTION)
 
 ./dwarfnames.$(objext): $(srcdir)/dwarfnames.c $(INCDIR)/dwarf2.def \
 	$(INCDIR)/dwarf2.h
@@ -715,7 +725,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/dwarfnames.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/dwarfnames.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/dwarfnames.c $(OUTPUT_OPTION)
 
 ./dyn-string.$(objext): $(srcdir)/dyn-string.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/dyn-string.h $(INCDIR)/libiberty.h
@@ -725,7 +735,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/dyn-string.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/dyn-string.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/dyn-string.c $(OUTPUT_OPTION)
 
 ./fdmatch.$(objext): $(srcdir)/fdmatch.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -735,7 +745,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fdmatch.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/fdmatch.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/fdmatch.c $(OUTPUT_OPTION)
 
 ./ffs.$(objext): $(srcdir)/ffs.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -744,7 +754,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/ffs.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/ffs.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/ffs.c $(OUTPUT_OPTION)
 
 ./fibheap.$(objext): $(srcdir)/fibheap.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/fibheap.h $(INCDIR)/libiberty.h
@@ -754,7 +764,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fibheap.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/fibheap.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/fibheap.c $(OUTPUT_OPTION)
 
 ./filename_cmp.$(objext): $(srcdir)/filename_cmp.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/filenames.h $(INCDIR)/hashtab.h \
@@ -765,7 +775,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/filename_cmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/filename_cmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/filename_cmp.c $(OUTPUT_OPTION)
 
 ./floatformat.$(objext): $(srcdir)/floatformat.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/floatformat.h $(INCDIR)/libiberty.h
@@ -775,7 +785,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/floatformat.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/floatformat.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/floatformat.c $(OUTPUT_OPTION)
 
 ./fnmatch.$(objext): $(srcdir)/fnmatch.c config.h $(INCDIR)/fnmatch.h \
 	$(INCDIR)/safe-ctype.h
@@ -785,7 +795,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fnmatch.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/fnmatch.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/fnmatch.c $(OUTPUT_OPTION)
 
 ./fopen_unlocked.$(objext): $(srcdir)/fopen_unlocked.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
@@ -795,7 +805,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/fopen_unlocked.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/fopen_unlocked.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/fopen_unlocked.c $(OUTPUT_OPTION)
 
 ./getcwd.$(objext): $(srcdir)/getcwd.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -804,7 +814,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getcwd.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getcwd.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getcwd.c $(OUTPUT_OPTION)
 
 ./getopt.$(objext): $(srcdir)/getopt.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/getopt.h
@@ -814,7 +824,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getopt.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getopt.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getopt.c $(OUTPUT_OPTION)
 
 ./getopt1.$(objext): $(srcdir)/getopt1.c config.h $(INCDIR)/getopt.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -823,7 +833,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getopt1.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getopt1.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getopt1.c $(OUTPUT_OPTION)
 
 ./getpagesize.$(objext): $(srcdir)/getpagesize.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -832,7 +842,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getpagesize.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getpagesize.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getpagesize.c $(OUTPUT_OPTION)
 
 ./getpwd.$(objext): $(srcdir)/getpwd.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -842,7 +852,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getpwd.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getpwd.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getpwd.c $(OUTPUT_OPTION)
 
 ./getruntime.$(objext): $(srcdir)/getruntime.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -852,7 +862,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/getruntime.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/getruntime.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/getruntime.c $(OUTPUT_OPTION)
 
 ./gettimeofday.$(objext): $(srcdir)/gettimeofday.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -862,7 +872,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/gettimeofday.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/gettimeofday.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/gettimeofday.c $(OUTPUT_OPTION)
 
 ./hashtab.$(objext): $(srcdir)/hashtab.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/hashtab.h $(INCDIR)/libiberty.h
@@ -872,7 +882,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/hashtab.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/hashtab.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/hashtab.c $(OUTPUT_OPTION)
 
 ./hex.$(objext): $(srcdir)/hex.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
@@ -882,7 +892,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/hex.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/hex.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/hex.c $(OUTPUT_OPTION)
 
 ./index.$(objext): $(srcdir)/index.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -891,7 +901,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/index.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/index.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/index.c $(OUTPUT_OPTION)
 
 ./insque.$(objext): $(srcdir)/insque.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -900,7 +910,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/insque.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/insque.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/insque.c $(OUTPUT_OPTION)
 
 ./lbasename.$(objext): $(srcdir)/lbasename.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/filenames.h $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h \
@@ -911,7 +921,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/lbasename.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/lbasename.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/lbasename.c $(OUTPUT_OPTION)
 
 ./lrealpath.$(objext): $(srcdir)/lrealpath.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -921,7 +931,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/lrealpath.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/lrealpath.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/lrealpath.c $(OUTPUT_OPTION)
 
 ./make-relative-prefix.$(objext): $(srcdir)/make-relative-prefix.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
@@ -931,7 +941,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/make-relative-prefix.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/make-relative-prefix.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/make-relative-prefix.c $(OUTPUT_OPTION)
 
 ./make-temp-file.$(objext): $(srcdir)/make-temp-file.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
@@ -941,7 +951,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/make-temp-file.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/make-temp-file.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/make-temp-file.c $(OUTPUT_OPTION)
 
 ./md5.$(objext): $(srcdir)/md5.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/md5.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -950,7 +960,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/md5.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/md5.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/md5.c $(OUTPUT_OPTION)
 
 ./memchr.$(objext): $(srcdir)/memchr.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -959,7 +969,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memchr.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memchr.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memchr.c $(OUTPUT_OPTION)
 
 ./memcmp.$(objext): $(srcdir)/memcmp.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -968,7 +978,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memcmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memcmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memcmp.c $(OUTPUT_OPTION)
 
 ./memcpy.$(objext): $(srcdir)/memcpy.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -977,7 +987,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memcpy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memcpy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memcpy.c $(OUTPUT_OPTION)
 
 ./memmem.$(objext): $(srcdir)/memmem.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -986,7 +996,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memmem.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memmem.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memmem.c $(OUTPUT_OPTION)
 
 ./memmove.$(objext): $(srcdir)/memmove.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -995,7 +1005,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memmove.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memmove.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memmove.c $(OUTPUT_OPTION)
 
 ./mempcpy.$(objext): $(srcdir)/mempcpy.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1004,7 +1014,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/mempcpy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/mempcpy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/mempcpy.c $(OUTPUT_OPTION)
 
 ./memset.$(objext): $(srcdir)/memset.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1013,7 +1023,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/memset.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/memset.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/memset.c $(OUTPUT_OPTION)
 
 ./mkstemps.$(objext): $(srcdir)/mkstemps.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1022,7 +1032,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/mkstemps.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/mkstemps.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/mkstemps.c $(OUTPUT_OPTION)
 
 ./msdos.$(objext): $(srcdir)/msdos.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1031,7 +1041,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/msdos.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/msdos.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/msdos.c $(OUTPUT_OPTION)
 
 ./objalloc.$(objext): $(srcdir)/objalloc.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/objalloc.h
@@ -1041,7 +1051,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/objalloc.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/objalloc.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/objalloc.c $(OUTPUT_OPTION)
 
 ./obstack.$(objext): $(srcdir)/obstack.c config.h $(INCDIR)/obstack.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1050,7 +1060,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/obstack.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/obstack.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/obstack.c $(OUTPUT_OPTION)
 
 ./partition.$(objext): $(srcdir)/partition.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/partition.h
@@ -1060,7 +1070,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/partition.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/partition.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/partition.c $(OUTPUT_OPTION)
 
 ./pex-common.$(objext): $(srcdir)/pex-common.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
@@ -1070,7 +1080,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-common.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-common.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-common.c $(OUTPUT_OPTION)
 
 ./pex-djgpp.$(objext): $(srcdir)/pex-djgpp.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
@@ -1080,7 +1090,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-djgpp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-djgpp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-djgpp.c $(OUTPUT_OPTION)
 
 ./pex-msdos.$(objext): $(srcdir)/pex-msdos.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h \
@@ -1091,7 +1101,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-msdos.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-msdos.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-msdos.c $(OUTPUT_OPTION)
 
 ./pex-one.$(objext): $(srcdir)/pex-one.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1101,7 +1111,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-one.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-one.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-one.c $(OUTPUT_OPTION)
 
 ./pex-unix.$(objext): $(srcdir)/pex-unix.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
@@ -1111,7 +1121,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-unix.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-unix.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-unix.c $(OUTPUT_OPTION)
 
 ./pex-win32.$(objext): $(srcdir)/pex-win32.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/pex-common.h
@@ -1121,7 +1131,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pex-win32.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pex-win32.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pex-win32.c $(OUTPUT_OPTION)
 
 ./pexecute.$(objext): $(srcdir)/pexecute.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1131,7 +1141,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/pexecute.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/pexecute.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/pexecute.c $(OUTPUT_OPTION)
 
 ./physmem.$(objext): $(srcdir)/physmem.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1141,7 +1151,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/physmem.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/physmem.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/physmem.c $(OUTPUT_OPTION)
 
 ./putenv.$(objext): $(srcdir)/putenv.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1150,7 +1160,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/putenv.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/putenv.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/putenv.c $(OUTPUT_OPTION)
 
 ./random.$(objext): $(srcdir)/random.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1159,7 +1169,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/random.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/random.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/random.c $(OUTPUT_OPTION)
 
 ./regex.$(objext): $(srcdir)/regex.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/xregex.h $(INCDIR)/xregex2.h
@@ -1169,7 +1179,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/regex.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/regex.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/regex.c $(OUTPUT_OPTION)
 
 ./rename.$(objext): $(srcdir)/rename.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1178,7 +1188,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/rename.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/rename.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/rename.c $(OUTPUT_OPTION)
 
 ./rindex.$(objext): $(srcdir)/rindex.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1187,7 +1197,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/rindex.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/rindex.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/rindex.c $(OUTPUT_OPTION)
 
 ./safe-ctype.$(objext): $(srcdir)/safe-ctype.c $(INCDIR)/ansidecl.h \
 	$(INCDIR)/safe-ctype.h
@@ -1197,7 +1207,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/safe-ctype.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/safe-ctype.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/safe-ctype.c $(OUTPUT_OPTION)
 
 ./setenv.$(objext): $(srcdir)/setenv.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1206,7 +1216,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/setenv.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/setenv.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/setenv.c $(OUTPUT_OPTION)
 
 ./setproctitle.$(objext): $(srcdir)/setproctitle.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1215,7 +1225,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/setproctitle.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/setproctitle.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/setproctitle.c $(OUTPUT_OPTION)
 
 ./sha1.$(objext): $(srcdir)/sha1.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/sha1.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1224,7 +1234,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sha1.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/sha1.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/sha1.c $(OUTPUT_OPTION)
 
 ./sigsetmask.$(objext): $(srcdir)/sigsetmask.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1233,7 +1243,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sigsetmask.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/sigsetmask.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/sigsetmask.c $(OUTPUT_OPTION)
 
 ./simple-object-coff.$(objext): $(srcdir)/simple-object-coff.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1244,7 +1254,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-coff.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object-coff.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-coff.c $(OUTPUT_OPTION)
 
 ./simple-object-elf.$(objext): $(srcdir)/simple-object-elf.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1255,7 +1265,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-elf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object-elf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-elf.c $(OUTPUT_OPTION)
 
 ./simple-object-mach-o.$(objext): $(srcdir)/simple-object-mach-o.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1266,7 +1276,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-mach-o.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object-mach-o.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-mach-o.c $(OUTPUT_OPTION)
 
 ./simple-object-xcoff.$(objext): $(srcdir)/simple-object-xcoff.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1277,7 +1287,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object-xcoff.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object-xcoff.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object-xcoff.c $(OUTPUT_OPTION)
 
 ./simple-object.$(objext): $(srcdir)/simple-object.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
@@ -1288,7 +1298,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/simple-object.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/simple-object.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/simple-object.c $(OUTPUT_OPTION)
 
 ./snprintf.$(objext): $(srcdir)/snprintf.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1297,7 +1307,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/snprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/snprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/snprintf.c $(OUTPUT_OPTION)
 
 ./sort.$(objext): $(srcdir)/sort.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/sort.h
@@ -1307,7 +1317,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/sort.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/sort.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/sort.c $(OUTPUT_OPTION)
 
 ./spaces.$(objext): $(srcdir)/spaces.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1317,7 +1327,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/spaces.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/spaces.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/spaces.c $(OUTPUT_OPTION)
 
 ./splay-tree.$(objext): $(srcdir)/splay-tree.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/splay-tree.h
@@ -1327,7 +1337,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/splay-tree.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/splay-tree.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/splay-tree.c $(OUTPUT_OPTION)
 
 ./stack-limit.$(objext): $(srcdir)/stack-limit.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1336,7 +1346,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stack-limit.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/stack-limit.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/stack-limit.c $(OUTPUT_OPTION)
 
 ./stpcpy.$(objext): $(srcdir)/stpcpy.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1345,7 +1355,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stpcpy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/stpcpy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/stpcpy.c $(OUTPUT_OPTION)
 
 ./stpncpy.$(objext): $(srcdir)/stpncpy.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1354,7 +1364,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/stpncpy.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/stpncpy.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/stpncpy.c $(OUTPUT_OPTION)
 
 ./strcasecmp.$(objext): $(srcdir)/strcasecmp.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1363,7 +1373,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strcasecmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strcasecmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strcasecmp.c $(OUTPUT_OPTION)
 
 ./strchr.$(objext): $(srcdir)/strchr.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1372,7 +1382,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strchr.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strchr.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strchr.c $(OUTPUT_OPTION)
 
 ./strdup.$(objext): $(srcdir)/strdup.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1381,7 +1391,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strdup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strdup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strdup.c $(OUTPUT_OPTION)
 
 ./strerror.$(objext): $(srcdir)/strerror.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1391,7 +1401,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strerror.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strerror.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strerror.c $(OUTPUT_OPTION)
 
 ./strncasecmp.$(objext): $(srcdir)/strncasecmp.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1400,7 +1410,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strncasecmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strncasecmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strncasecmp.c $(OUTPUT_OPTION)
 
 ./strncmp.$(objext): $(srcdir)/strncmp.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1409,7 +1419,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strncmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strncmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strncmp.c $(OUTPUT_OPTION)
 
 ./strndup.$(objext): $(srcdir)/strndup.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1418,7 +1428,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strndup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strndup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strndup.c $(OUTPUT_OPTION)
 
 ./strnlen.$(objext): $(srcdir)/strnlen.c config.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1427,7 +1437,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strnlen.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strnlen.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strnlen.c $(OUTPUT_OPTION)
 
 ./strrchr.$(objext): $(srcdir)/strrchr.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1436,7 +1446,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strrchr.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strrchr.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strrchr.c $(OUTPUT_OPTION)
 
 ./strsignal.$(objext): $(srcdir)/strsignal.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1446,7 +1456,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strsignal.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strsignal.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strsignal.c $(OUTPUT_OPTION)
 
 ./strstr.$(objext): $(srcdir)/strstr.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1455,7 +1465,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strstr.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strstr.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strstr.c $(OUTPUT_OPTION)
 
 ./strtod.$(objext): $(srcdir)/strtod.c $(INCDIR)/ansidecl.h \
 	$(INCDIR)/safe-ctype.h
@@ -1465,7 +1475,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtod.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtod.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtod.c $(OUTPUT_OPTION)
 
 ./strtol.$(objext): $(srcdir)/strtol.c config.h $(INCDIR)/safe-ctype.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1474,7 +1484,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtol.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtol.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtol.c $(OUTPUT_OPTION)
 
 ./strtoll.$(objext): $(srcdir)/strtoll.c config.h $(INCDIR)/safe-ctype.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1483,7 +1493,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoll.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtoll.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoll.c $(OUTPUT_OPTION)
 
 ./strtoul.$(objext): $(srcdir)/strtoul.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/safe-ctype.h
@@ -1493,7 +1503,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoul.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtoul.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoul.c $(OUTPUT_OPTION)
 
 ./strtoull.$(objext): $(srcdir)/strtoull.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/safe-ctype.h
@@ -1503,7 +1513,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strtoull.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strtoull.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strtoull.c $(OUTPUT_OPTION)
 
 ./strverscmp.$(objext): $(srcdir)/strverscmp.c $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
@@ -1513,7 +1523,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/strverscmp.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/strverscmp.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/strverscmp.c $(OUTPUT_OPTION)
 
 ./timeval-utils.$(objext): $(srcdir)/timeval-utils.c config.h \
 	$(INCDIR)/timeval-utils.h
@@ -1523,7 +1533,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/timeval-utils.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/timeval-utils.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/timeval-utils.c $(OUTPUT_OPTION)
 
 ./tmpnam.$(objext): $(srcdir)/tmpnam.c
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1542,7 +1552,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/unlink-if-ordinary.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/unlink-if-ordinary.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/unlink-if-ordinary.c $(OUTPUT_OPTION)
 
 ./vasprintf.$(objext): $(srcdir)/vasprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/vprintf-support.h
@@ -1552,7 +1562,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vasprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vasprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vasprintf.c $(OUTPUT_OPTION)
 
 ./vfork.$(objext): $(srcdir)/vfork.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1561,7 +1571,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vfork.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vfork.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vfork.c $(OUTPUT_OPTION)
 
 ./vfprintf.$(objext): $(srcdir)/vfprintf.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1570,7 +1580,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vfprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vfprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vfprintf.c $(OUTPUT_OPTION)
 
 ./vprintf-support.$(objext): $(srcdir)/vprintf-support.c config.h \
 	$(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
@@ -1580,7 +1590,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vprintf-support.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vprintf-support.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vprintf-support.c $(OUTPUT_OPTION)
 
 ./vprintf.$(objext): $(srcdir)/vprintf.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1589,7 +1599,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vprintf.c $(OUTPUT_OPTION)
 
 ./vsnprintf.$(objext): $(srcdir)/vsnprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1599,7 +1609,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vsnprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vsnprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vsnprintf.c $(OUTPUT_OPTION)
 
 ./vsprintf.$(objext): $(srcdir)/vsprintf.c $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1608,7 +1618,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/vsprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/vsprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/vsprintf.c $(OUTPUT_OPTION)
 
 ./waitpid.$(objext): $(srcdir)/waitpid.c config.h $(INCDIR)/ansidecl.h
 	if [ x"$(PICFLAG)" != x ]; then \
@@ -1617,7 +1627,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/waitpid.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/waitpid.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/waitpid.c $(OUTPUT_OPTION)
 
 ./xasprintf.$(objext): $(srcdir)/xasprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1627,7 +1637,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xasprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xasprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xasprintf.c $(OUTPUT_OPTION)
 
 ./xatexit.$(objext): $(srcdir)/xatexit.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1637,7 +1647,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xatexit.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xatexit.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xatexit.c $(OUTPUT_OPTION)
 
 ./xexit.$(objext): $(srcdir)/xexit.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1647,7 +1657,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xexit.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xexit.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xexit.c $(OUTPUT_OPTION)
 
 ./xmalloc.$(objext): $(srcdir)/xmalloc.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1657,7 +1667,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xmalloc.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xmalloc.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xmalloc.c $(OUTPUT_OPTION)
 
 ./xmemdup.$(objext): $(srcdir)/xmemdup.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1667,7 +1677,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xmemdup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xmemdup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xmemdup.c $(OUTPUT_OPTION)
 
 ./xstrdup.$(objext): $(srcdir)/xstrdup.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1677,7 +1687,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrdup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xstrdup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrdup.c $(OUTPUT_OPTION)
 
 ./xstrerror.$(objext): $(srcdir)/xstrerror.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1687,7 +1697,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrerror.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xstrerror.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrerror.c $(OUTPUT_OPTION)
 
 ./xstrndup.$(objext): $(srcdir)/xstrndup.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h
@@ -1697,7 +1707,7 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xstrndup.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xstrndup.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xstrndup.c $(OUTPUT_OPTION)
 
 ./xvasprintf.$(objext): $(srcdir)/xvasprintf.c config.h $(INCDIR)/ansidecl.h \
 	$(INCDIR)/libiberty.h $(srcdir)/vprintf-support.h
@@ -1707,4 +1717,4 @@ $(CONFIGURED_OFILES): stamp-picdir stamp-noasandir
 	if [ x"$(NOASANFLAG)" != x ]; then \
 	  $(COMPILE.c) $(PICFLAG) $(NOASANFLAG) $(srcdir)/xvasprintf.c -o noasan/$@; \
 	else true; fi
-	$(COMPILE.c) $(srcdir)/xvasprintf.c $(OUTPUT_OPTION)
+	$(COMPILE.c) $(NONPIC) $(srcdir)/xvasprintf.c $(OUTPUT_OPTION)
diff --git a/libiberty/configure.ac b/libiberty/configure.ac
index 922aa86..6ca85f6 100644
--- a/libiberty/configure.ac
+++ b/libiberty/configure.ac
@@ -231,10 +231,19 @@ if [[ "${enable_host_shared}" = "yes" ]]; then
   shared=yes
 fi
 
+NOPICFLAG=
+case "${host}" in
+  i[[34567]]86-*-darwin* | powerpc-*-darwin*)
+    NOPICFLAG=-mdynamic-no-pic ;;
+  *) ;;
+esac
+
 if [[ "${shared}" != "yes" ]]; then
   PICFLAG=
+  NOPICFLAG=
 fi
 AC_SUBST(PICFLAG)
+AC_SUBST(NOPICFLAG)
 
 NOASANFLAG=
 case " ${CFLAGS} " in

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2015-01-26 15:02           ` Rainer Orth
@ 2015-01-26 15:06             ` Iain Sandoe
  2015-02-01 16:42             ` Iain Sandoe
  1 sibling, 0 replies; 36+ messages in thread
From: Iain Sandoe @ 2015-01-26 15:06 UTC (permalink / raw)
  To: Rainer Orth; +Cc: FX, gcc-patches, GCC Development


On 26 Jan 2015, at 14:13, Rainer Orth wrote:

> FX <fxcoudert@gmail.com> writes:
> 
>>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB
>>> -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>>> This means that the PIC library is being built with non-pic relocs.
>> 
>> config/mh-darwin says that -mdynamic-no-pic is there because it “speeds
>> compiles by 3-5%”. I don’t think we care about speed when the bootstrap
>> fails, so can we remove it altogether?
> 
> Darwin/i686 still doesn't bootstrap without this patch, I believe.
> Shouldn't it be applied to trunk before GCC 5 ships, rather than leaving
> that target broken?

I'll try and post a patch to fix it properly this week..
Iain

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:52         ` FX
  2014-12-04 13:54           ` Richard Biener
@ 2015-01-26 15:02           ` Rainer Orth
  2015-01-26 15:06             ` Iain Sandoe
  2015-02-01 16:42             ` Iain Sandoe
  1 sibling, 2 replies; 36+ messages in thread
From: Rainer Orth @ 2015-01-26 15:02 UTC (permalink / raw)
  To: FX; +Cc: Iain Sandoe, gcc-patches, GCC Development

FX <fxcoudert@gmail.com> writes:

>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB
>> -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>> This means that the PIC library is being built with non-pic relocs.
>
> config/mh-darwin says that -mdynamic-no-pic is there because it “speeds
> compiles by 3-5%”. I don’t think we care about speed when the bootstrap
> fails, so can we remove it altogether?

Darwin/i686 still doesn't bootstrap without this patch, I believe.
Shouldn't it be applied to trunk before GCC 5 ships, rather than leaving
that target broken?

	Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-05 19:12 Dominique Dhumieres
@ 2014-12-05 20:16 ` Jakub Jelinek
  0 siblings, 0 replies; 36+ messages in thread
From: Jakub Jelinek @ 2014-12-05 20:16 UTC (permalink / raw)
  To: Dominique Dhumieres; +Cc: gcc-patches, gcc, fxcoudert, pmuldoon, iain

On Fri, Dec 05, 2014 at 08:11:53PM +0100, Dominique Dhumieres wrote:
> > ...
> > Can you please test it on Darwin (or whatever other target has similar
> > issues with bootstrapping libcc1)?
> >
> > 2014-12-05  Jakub Jelinek  <jakub@redhat.com>
> > ...
> 
> The patch does not work for x86_64-apple-darwin14.0.0. However the following patch does:

As I've tried to explain, that is IMHO wrong though.
If what you are after is the -B stuff too, then perhaps:

2014-12-05  Jakub Jelinek  <jakub@redhat.com>

	PR bootstrap/64023
	* Makefile.tpl (EXTRA_TARGET_FLAGS): Set STAGE1_LDFLAGS
	to POSTSTAGE1_LDFLAGS and STAGE1_LIBS to POSTSTAGE1_LIBS.
	Add -B to libstdc++-v3/src/.libs and libstdc++-v3/libsupc++/.libs
	to CXX.
	* Makefile.in: Regenerated.

--- Makefile.tpl.jj	2014-11-12 09:31:59.000000000 +0100
+++ Makefile.tpl	2014-12-05 21:12:21.486031062 +0100
@@ -641,7 +641,9 @@ EXTRA_TARGET_FLAGS = \
 	'AS=$(COMPILER_AS_FOR_TARGET)' \
 	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
 	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
-	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
+	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs' \
+	' -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs' \
+	' $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
 	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
 	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
 	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
@@ -659,6 +661,8 @@ EXTRA_TARGET_FLAGS = \
 	'WINDRES=$$(WINDRES_FOR_TARGET)' \
 	'WINDMC=$$(WINDMC_FOR_TARGET)' \
 	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
+	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
+	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
 	"TFLAGS=$$TFLAGS"
 
 TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
--- Makefile.in.jj	2014-11-28 14:40:52.000000000 +0100
+++ Makefile.in	2014-12-05 21:11:48.276616008 +0100
@@ -835,7 +835,9 @@ EXTRA_TARGET_FLAGS = \
 	'AS=$(COMPILER_AS_FOR_TARGET)' \
 	'CC=$$(CC_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
 	'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
-	'CXX=$$(CXX_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
+	'CXX=$$(CXX_FOR_TARGET) -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/src/.libs' \
+	' -B$$r/$$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs' \
+	' $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
 	'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
 	'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
 	'GCJ=$$(GCJ_FOR_TARGET) $$(XGCC_FLAGS_FOR_TARGET) $$(TFLAGS)' \
@@ -853,6 +855,8 @@ EXTRA_TARGET_FLAGS = \
 	'WINDRES=$$(WINDRES_FOR_TARGET)' \
 	'WINDMC=$$(WINDMC_FOR_TARGET)' \
 	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
+	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
+	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
 	"TFLAGS=$$TFLAGS"
 
 TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)


	Jakub

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
@ 2014-12-05 19:12 Dominique Dhumieres
  2014-12-05 20:16 ` Jakub Jelinek
  0 siblings, 1 reply; 36+ messages in thread
From: Dominique Dhumieres @ 2014-12-05 19:12 UTC (permalink / raw)
  To: gcc-patches; +Cc: gcc, fxcoudert, pmuldoon, iain, jakub

> ...
> Can you please test it on Darwin (or whatever other target has similar
> issues with bootstrapping libcc1)?
>
> 2014-12-05  Jakub Jelinek  <jakub@redhat.com>
> ...

The patch does not work for x86_64-apple-darwin14.0.0. However the following patch does:

--- ../_clean/Makefile.in	2014-11-26 23:09:14.000000000 +0100
+++ Makefile.in	2014-12-05 17:22:54.000000000 +0100
@@ -31389,7 +31389,7 @@ configure-libcc1: 
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
 	test ! -f $(HOST_SUBDIR)/libcc1/Makefile || exit 0; \
 	$(SHELL) $(srcdir)/mkinstalldirs $(HOST_SUBDIR)/libcc1 ; \
-	$(HOST_EXPORTS)  \
+	$(POSTSTAGE1_HOST_EXPORTS)  \
 	echo Configuring in $(HOST_SUBDIR)/libcc1; \
 	cd "$(HOST_SUBDIR)/libcc1" || exit 1; \
 	case $(srcdir) in \
@@ -31422,7 +31422,7 @@ all-libcc1: configure-libcc1
 	@: $(MAKE); $(unstage)
 	@r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS)  \
+	$(POSTSTAGE1_HOST_EXPORTS)  \
 	(cd $(HOST_SUBDIR)/libcc1 && \
 	  $(MAKE) $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS) $(STAGE1_FLAGS_TO_PASS)  \
 		$(TARGET-libcc1))
@@ -31440,7 +31440,7 @@ check-libcc1:
 	@: $(MAKE); $(unstage)
 	@r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	(cd $(HOST_SUBDIR)/libcc1 && \
 	  $(MAKE) $(FLAGS_TO_PASS)  check)
 
@@ -31455,7 +31455,7 @@ install-libcc1: installdirs
 	@: $(MAKE); $(unstage)
 	@r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	(cd $(HOST_SUBDIR)/libcc1 && \
 	  $(MAKE) $(FLAGS_TO_PASS)  install)
 
@@ -31470,7 +31470,7 @@ install-strip-libcc1: installdirs
 	@: $(MAKE); $(unstage)
 	@r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	(cd $(HOST_SUBDIR)/libcc1 && \
 	  $(MAKE) $(FLAGS_TO_PASS)  install-strip)
 
@@ -31489,7 +31489,7 @@ info-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31515,7 +31515,7 @@ dvi-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31541,7 +31541,7 @@ pdf-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31567,7 +31567,7 @@ html-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31593,7 +31593,7 @@ TAGS-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31620,7 +31620,7 @@ install-info-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31647,7 +31647,7 @@ install-pdf-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31674,7 +31674,7 @@ install-html-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31700,7 +31700,7 @@ installcheck-libcc1: \
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31725,7 +31725,7 @@ mostlyclean-libcc1: 
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31750,7 +31750,7 @@ clean-libcc1: 
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31775,7 +31775,7 @@ distclean-libcc1: 
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \
@@ -31800,7 +31800,7 @@ maintainer-clean-libcc1: 
 	@[ -f ./libcc1/Makefile ] || exit 0; \
 	r=`${PWD_COMMAND}`; export r; \
 	s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
-	$(HOST_EXPORTS) \
+	$(POSTSTAGE1_HOST_EXPORTS) \
 	for flag in $(EXTRA_HOST_FLAGS) ; do \
 	  eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
 	done; \

although I am not sure that all the substitution are required.

Dominique

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-11-24  2:28 ` FX
  2014-11-25 20:59   ` Mike Stump
  2014-12-04  9:12   ` FX
@ 2014-12-05 16:35   ` Jakub Jelinek
  2 siblings, 0 replies; 36+ messages in thread
From: Jakub Jelinek @ 2014-12-05 16:35 UTC (permalink / raw)
  To: FX
  Cc: Paolo Bonzini, Rainer Orth, pmuldoon, Tom Tromey,
	GCC Development, gcc-patches, Iain Sandoe

On Mon, Nov 24, 2014 at 01:06:45AM +0100, FX wrote:
> tl;dr: One question to build maintainers, and one patch submitted to toplevel configure.ac
> 
> ---------------
> 
> I’m looked into the issue some more, and am comparing two builds of trunk (exact same source), one configured with system compiler (clang) in PATH, the other with GCC 4.9.2 in PATH.
> At the toplevel configure, the only meaningful difference is that the gcc-based build sets stage1_ldflags='-static-libstdc++ -static-libgcc' while the clang-based has stage1_ldflags='' (clang doesn’t recognized -static-libstdc++).
> 
> This is included into the toplevel Makefile as STAGE1_LDFLAGS (the comment appropriately says "Linker flags to use on the host, for stage1 or when not bootstrapping”).
> Those are exported by HOST_EXPORTS, which is are then used by configure-libcc1, all-libcc1, etc. Thus, we end up using STAGE1_LDFLAGS, which correspond to the system compiler, instead of the stage3 compiler (as we should).
> 
> So, this is “false negative” part of the problem (namely, why we don’t see the failure when bootstrapping with clang): we use STAGE1_LDFLAGS in building libcc1, and with clang as system compiler we don’t use static linking of the C++ library. This part, I don’t know how to fix: it is for the build experts to address. It is a real problem: it leads to libcc1.so being linked dynamically to libstdc++ and libgcc, instead of statically (as it should).
> 
> ---------------
> 
> Second part of the question: when the freshly built g++ is used, we need to pass the appropriate -B options. As I understand it, the appropriate place for that is in the toplevel configure.ac, where we already pass down the respective -L options. Indeed, the attached patch restores bootstrap on x86_64-apple-darwin14 with gcc as system compiler (and doesn’t break the bootstrap with clang as system compiler).
> 
> OK to commit?

Reading the toplevel Makefile and trying to understand how things work
for non-bootstrap vs. bootstrap host dirs that aren't bootstrapped,
I'd say the right fix should be something like following
(bootstrapping/regtesting it right now on x86_64-linux and i686-linux,
though it won't make much difference there, on x86_64-linux
STAGE1_LDFLAGS is equal to POSTSTAGE1_LDFLAGS and STAGE1_LIBS is equal
to POSTSTAGE1_LIBS.  On i686-linux there is at least a difference
for some reason (possibly related with my setarch and gcc -m32 wrappers
hacks to make i686-linux bootstrap work on x86_64-linux box) in
*STAGE1_LDFLAGS, only the POSTSTAGE1_LDFLAGS is -static-libstdc++ -static-libgcc.

From my reading, POSTSTAGE1_HOST_EXPORTS is clearly inappropriate for the
modules like libcc1, because it uses prev-gcc/, while we want to use gcc/,
but otherwise looking at the HOST_EXPORTS vs. POSTSTAGE1_HOST_EXPORTS
differences, LDFLAGS and HOST_LIBS is what needs changing.
For some reason POSTSTAGE1_HOST_EXPORTS sets LDFLAGS to 
$(POSTSTAGE1_LDFLAGS) $(BOOT_LDFLAGS)
(the first part is ok and clear, the latter differs from the HOST_EXPORTS
$(STAGE1_LDFLAGS) $(LDFLAGS).
With my patch below, one actually ends up with
$(POSTSTAGE1_LDFLAGS) $(LDFLAGS_FOR_TARGET)
for libcc1 when bootstrapping in LDFLAGS, while previously
$(STAGE1_LDFLAGS) $(LDFLAGS_FOR_TARGET)
was used.  STAGE1_L{DFLAGS,IBS} is only used in $(HOST_EXPORTS),
so at least in theory I think my patch should DTRT.

Can you please test it on Darwin (or whatever other target has similar
issues with bootstrapping libcc1)?

2014-12-05  Jakub Jelinek  <jakub@redhat.com>

	PR bootstrap/64023
	* Makefile.tpl (EXTRA_TARGET_FLAGS): Set STAGE1_LDFLAGS
	to POSTSTAGE1_LDFLAGS and STAGE1_LIBS to POSTSTAGE1_LIBS.
	* Makefile.in: Regenerated.

--- Makefile.tpl.jj	2014-11-12 09:31:59.000000000 +0100
+++ Makefile.tpl	2014-12-05 17:14:16.115295667 +0100
@@ -659,6 +659,8 @@ EXTRA_TARGET_FLAGS = \
 	'WINDRES=$$(WINDRES_FOR_TARGET)' \
 	'WINDMC=$$(WINDMC_FOR_TARGET)' \
 	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
+	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
+	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
 	"TFLAGS=$$TFLAGS"
 
 TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
--- Makefile.in.jj	2014-11-28 14:40:52.000000000 +0100
+++ Makefile.in	2014-12-05 17:15:04.322439003 +0100
@@ -853,6 +853,8 @@ EXTRA_TARGET_FLAGS = \
 	'WINDRES=$$(WINDRES_FOR_TARGET)' \
 	'WINDMC=$$(WINDMC_FOR_TARGET)' \
 	'XGCC_FLAGS_FOR_TARGET=$(XGCC_FLAGS_FOR_TARGET)' \
+	'STAGE1_LDFLAGS=$$(POSTSTAGE1_LDFLAGS)' \
+	'STAGE1_LIBS=$$(POSTSTAGE1_LIBS)' \
 	"TFLAGS=$$TFLAGS"
 
 TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)


	Jakub

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 15:24             ` FX
@ 2014-12-04 15:36               ` Iain Sandoe
  0 siblings, 0 replies; 36+ messages in thread
From: Iain Sandoe @ 2014-12-04 15:36 UTC (permalink / raw)
  To: FX; +Cc: Richard Biener, gcc-patches, GCC Development


On 4 Dec 2014, at 15:24, FX wrote:

>> Can you try adding it as
>> 
>> T_CFLAGS += -mdynamic-no-pic
>> 
>> in gcc/config/t-tarwin instead?
> 

-mdynamic-no-pic should be used to build *host* executable stuff for m32 darwin.

It is not suitable for building shared libraries (hence the problem with building the PIC version of libiberty) and won't work for the target libaries for similar reasons.

----

If you want a "quick fix", sure remove it from the boot cflags - but it's hiding a real issue which is that the pic build of libiberty does not cater for the possibility that the non-pic flags cannot simply be overridden by the pic ones.

Of course, it's possible what darwin is the only affected target - but I'd not want to swear to that.

Iain

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:54           ` Richard Biener
@ 2014-12-04 15:24             ` FX
  2014-12-04 15:36               ` Iain Sandoe
  0 siblings, 1 reply; 36+ messages in thread
From: FX @ 2014-12-04 15:24 UTC (permalink / raw)
  To: Richard Biener; +Cc: Iain Sandoe, gcc-patches, GCC Development

> Can you try adding it as
> 
> T_CFLAGS += -mdynamic-no-pic
> 
> in gcc/config/t-tarwin instead?

Nope, doing so fails to link libgcc_s.dylib:

/Users/fx/devel/gcc/i/./gcc/xgcc -B/Users/fx/devel/gcc/i/./gcc/ -B/Users/fx/devel/gcc/i2/i386-apple-darwin14.0.0/bin/ -B/Users/fx/devel/gcc/i2/i386-apple-darwin14.0.0/lib/ -isystem /Users/fx/devel/gcc/i2/i386-apple-darwin14.0.0/include -isystem /Users/fx/devel/gcc/i2/i386-apple-darwin14.0.0/sys-include    -O2  -g -O2 -DIN_GCC    -mdynamic-no-pic -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wno-format -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include   -pipe -fno-common -g -DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector  -dynamiclib -nodefaultlibs -install_name /Users/fx/devel/gcc/i2/lib/libgcc_s.1.dylib -single_module -o ./libgcc_s.dylib -Wl,-exported_symbols_list,libgcc.map -compatibility_version 1 -current_version 1.0 -g -O2 -B./ _muldi3_s.o _negdi2_s.o _lshrdi3_s.o _ashldi3_s.o _ashrdi3_s.o _cmpdi2_s.o _ucmpdi2_s.o _clear_cache_s.o _trampoline_s.o __main_s.o _absvsi2_s.o _absvdi2_s.o _addvsi3_s.o _addvdi3_s.o _subvsi3_s.o _subvdi3_s.o _mulvsi3_s.o _mulvdi3_s.o _negvsi2_s.o _negvdi2_s.o _ctors_s.o _ffssi2_s.o _ffsdi2_s.o _clz_s.o _clzsi2_s.o _clzdi2_s.o _ctzsi2_s.o _ctzdi2_s.o _popcount_tab_s.o _popcountsi2_s.o _popcountdi2_s.o _paritysi2_s.o _paritydi2_s.o _powisf2_s.o _powidf2_s.o _powixf2_s.o _powitf2_s.o _mulsc3_s.o _muldc3_s.o _mulxc3_s.o _multc3_s.o _divsc3_s.o _divdc3_s.o _divxc3_s.o _divtc3_s.o _bswapsi2_s.o _bswapdi2_s.o _clrsbsi2_s.o _clrsbdi2_s.o _fixunssfsi_s.o _fixunsdfsi_s.o _fixunsxfsi_s.o _fixsfdi_s.o _fixdfdi_s.o _fixxfdi_s.o _fixunssfdi_s.o _fixunsdfdi_s.o _fixunsxfdi_s.o _floatdisf_s.o _floatdidf_s.o _floatdixf_s.o _floatundisf_s.o _floatundidf_s.o _floatundixf_s.o _fixsfti_s.o _fixdfti_s.o _fixxfti_s.o _fixtfti_s.o _fixunssfti_s.o _fixunsdfti_s.o _fixunsxfti_s.o _fixunstfti_s.o _floattisf_s.o _floattidf_s.o _floattixf_s.o _floattitf_s.o _floatuntisf_s.o _floatuntidf_s.o _floatuntixf_s.o _floatuntitf_s.o _divdi3_s.o _moddi3_s.o _udivdi3_s.o _umoddi3_s.o _udiv_w_sdiv_s.o _udivmoddi4_s.o darwin-64_s.o cpuinfo_s.o tf-signs_s.o sfp-exceptions_s.o addtf3_s.o divtf3_s.o eqtf2_s.o getf2_s.o letf2_s.o multf3_s.o negtf2_s.o subtf3_s.o unordtf2_s.o fixtfsi_s.o fixunstfsi_s.o floatsitf_s.o floatunsitf_s.o fixtfdi_s.o fixunstfdi_s.o floatditf_s.o floatunditf_s.o extendsftf2_s.o extenddftf2_s.o extendxftf2_s.o trunctfsf2_s.o trunctfdf2_s.o trunctfxf2_s.o enable-execute-stack_s.o unwind-dw2_s.o unwind-dw2-fde-darwin_s.o unwind-sjlj_s.o unwind-c_s.o emutls_s.o libgcc.a -lc
ld: warning: could not create compact unwind for __Unwind_RaiseException: does not use EBP or ESP based frame
ld: warning: could not create compact unwind for __Unwind_ForcedUnwind: does not use EBP or ESP based frame
ld: warning: could not create compact unwind for __Unwind_Resume: does not use EBP or ESP based frame
ld: warning: could not create compact unwind for __Unwind_Resume_or_Rethrow: does not use EBP or ESP based frame
ld: illegal text-relocation to '4-byte-literal' in _powisf2_s.o from '___powisf2' in _powisf2_s.o for architecture i386
collect2: error: ld returned 1 exit status
make[3]: *** [libgcc_s.dylib] Error 1
make[2]: *** [all-stage1-target-libgcc] Error 2
make[1]: *** [stage1-bubble] Error 2
make: *** [all] Error 2


^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:52         ` FX
@ 2014-12-04 13:54           ` Richard Biener
  2014-12-04 15:24             ` FX
  2015-01-26 15:02           ` Rainer Orth
  1 sibling, 1 reply; 36+ messages in thread
From: Richard Biener @ 2014-12-04 13:54 UTC (permalink / raw)
  To: FX; +Cc: Iain Sandoe, gcc-patches, GCC Development

On Thu, Dec 4, 2014 at 2:52 PM, FX <fxcoudert@gmail.com> wrote:
>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>> This means that the PIC library is being built with non-pic relocs.
>
> config/mh-darwin says that -mdynamic-no-pic is there because it “speeds compiles by 3-5%”. I don’t think we care about speed when the bootstrap fails, so can we remove it altogether?

Can you try adding it as

T_CFLAGS += -mdynamic-no-pic

in gcc/config/t-tarwin instead?

> FX
>
>

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:48           ` Richard Biener
@ 2014-12-04 13:53             ` Richard Biener
  0 siblings, 0 replies; 36+ messages in thread
From: Richard Biener @ 2014-12-04 13:53 UTC (permalink / raw)
  To: Iain Sandoe
  Cc: Rainer Orth, FX, gcc-patches, Paolo Bonzini, pmuldoon,
	Jakub Jelinek, Tom Tromey, GCC Development

On Thu, Dec 4, 2014 at 2:48 PM, Richard Biener
<richard.guenther@gmail.com> wrote:
> On Thu, Dec 4, 2014 at 2:47 PM, Richard Biener
> <richard.guenther@gmail.com> wrote:
>> On Thu, Dec 4, 2014 at 2:43 PM, Iain Sandoe <iain@codesourcery.com> wrote:
>>> Hi Rainer,
>>>
>>> On 4 Dec 2014, at 13:32, Rainer Orth wrote:
>>>
>>>> FX <fxcoudert@gmail.com> writes:
>>>>
>>>>> 10-days ping
>>>>> This restores bootstrap on a secondary target, target maintainer is OK with
>>>>> it. I think I need build maintainers approval, so please review.
>>>>
>>>> While in my testing, 64-bit Mac OS X 10.10.1 (x86_64-apple-darwin14.0.0)
>>>> now bootstraps, but 32-bit (i386-apple-darwin14.0.0) does not:
>>>>
>>>> ld: illegal text-relocation to 'anon' in ../libiberty/pic/libiberty.a(regex.o) from '_byte_common_op_match_null_string_p' in ../libiberty/pic/libiberty.a(regex.o) for architecture i386
>>>> collect2: error: ld returned 1 exit status
>>>> make[3]: *** [libcc1.la] Error 1
>>>> make[2]: *** [all] Error 2
>>>> make[1]: *** [all-libcc1] Error 2
>>>
>>> For {i?86,ppc}-darwin* (i.e. m32 hosts) the PIC libiberty library is being incorrectly built.
>>>
>>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>>>
>>> This means that the PIC library is being built with non-pic relocs.
>>>
>>> I have a local hack to allow build to proceed on m32-host-darwin (which I can send to you if you would like it) - however, it's not really a suitable patch for trunk... and I've not had time recently to try and fix this.
>>>
>>> If you would like to raise a PR for this, I can append the analysis there.
>>
>> The libiberty PIC build shouldn't use BOOT_CFLAGS.  How does
>> lto-plugin get around being built for the host but as a shared library?
>
> That is, the mistake is probably adding -mdynamic-no-pic to BOOT_CFLAGS
> rather than in more contained places when building files for the host
> _binaries_.

Where T_CFLAGS should have been used?

Richard.

> Richard.
>
>> Richard.
>>
>>> cheers
>>> Iain
>>>

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:43       ` Iain Sandoe
  2014-12-04 13:47         ` Richard Biener
@ 2014-12-04 13:52         ` FX
  2014-12-04 13:54           ` Richard Biener
  2015-01-26 15:02           ` Rainer Orth
  1 sibling, 2 replies; 36+ messages in thread
From: FX @ 2014-12-04 13:52 UTC (permalink / raw)
  To: Iain Sandoe; +Cc: gcc-patches, GCC Development

[-- Attachment #1: Type: text/plain, Size: 475 bytes --]

> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
> This means that the PIC library is being built with non-pic relocs.

config/mh-darwin says that -mdynamic-no-pic is there because it “speeds compiles by 3-5%”. I don’t think we care about speed when the bootstrap fails, so can we remove it altogether?

FX



[-- Attachment #2: darwin.diff --]
[-- Type: application/octet-stream, Size: 974 bytes --]

Index: config/mh-darwin
===================================================================
--- config/mh-darwin	(revision 218343)
+++ config/mh-darwin	(working copy)
@@ -1,18 +1,8 @@
-# The -mdynamic-no-pic ensures that the compiler executable is built without
-# position-independent-code -- the usual default on Darwin. This fix speeds
-# compiles by 3-5%.
-BOOT_CFLAGS += \
-`case ${host} in i?86-*-darwin* | powerpc-*-darwin*) \
-                 echo -mdynamic-no-pic ;; esac;`
-
 # ld on Darwin versions >= 10.7 defaults to PIE executables. Disable this for
 # gcc components, since it is incompatible with our pch implementation.
 BOOT_LDFLAGS += \
 `case ${host} in *-*-darwin[1][1-9]*) echo -Wl,-no_pie ;; esac;`
 
 # Similarly, for cross-compilation.
-STAGE1_CFLAGS += \
-`case ${host} in i?86-*-darwin* | powerpc-*-darwin*)\
-                 echo -mdynamic-no-pic ;; esac;`
 STAGE1_LDFLAGS += \
 `case ${host} in *-*-darwin[1][1-9]*) echo -Wl,-no_pie ;; esac;`

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:47         ` Richard Biener
@ 2014-12-04 13:48           ` Richard Biener
  2014-12-04 13:53             ` Richard Biener
  0 siblings, 1 reply; 36+ messages in thread
From: Richard Biener @ 2014-12-04 13:48 UTC (permalink / raw)
  To: Iain Sandoe
  Cc: Rainer Orth, FX, gcc-patches, Paolo Bonzini, pmuldoon,
	Jakub Jelinek, Tom Tromey, GCC Development

On Thu, Dec 4, 2014 at 2:47 PM, Richard Biener
<richard.guenther@gmail.com> wrote:
> On Thu, Dec 4, 2014 at 2:43 PM, Iain Sandoe <iain@codesourcery.com> wrote:
>> Hi Rainer,
>>
>> On 4 Dec 2014, at 13:32, Rainer Orth wrote:
>>
>>> FX <fxcoudert@gmail.com> writes:
>>>
>>>> 10-days ping
>>>> This restores bootstrap on a secondary target, target maintainer is OK with
>>>> it. I think I need build maintainers approval, so please review.
>>>
>>> While in my testing, 64-bit Mac OS X 10.10.1 (x86_64-apple-darwin14.0.0)
>>> now bootstraps, but 32-bit (i386-apple-darwin14.0.0) does not:
>>>
>>> ld: illegal text-relocation to 'anon' in ../libiberty/pic/libiberty.a(regex.o) from '_byte_common_op_match_null_string_p' in ../libiberty/pic/libiberty.a(regex.o) for architecture i386
>>> collect2: error: ld returned 1 exit status
>>> make[3]: *** [libcc1.la] Error 1
>>> make[2]: *** [all] Error 2
>>> make[1]: *** [all-libcc1] Error 2
>>
>> For {i?86,ppc}-darwin* (i.e. m32 hosts) the PIC libiberty library is being incorrectly built.
>>
>> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
>> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>>
>> This means that the PIC library is being built with non-pic relocs.
>>
>> I have a local hack to allow build to proceed on m32-host-darwin (which I can send to you if you would like it) - however, it's not really a suitable patch for trunk... and I've not had time recently to try and fix this.
>>
>> If you would like to raise a PR for this, I can append the analysis there.
>
> The libiberty PIC build shouldn't use BOOT_CFLAGS.  How does
> lto-plugin get around being built for the host but as a shared library?

That is, the mistake is probably adding -mdynamic-no-pic to BOOT_CFLAGS
rather than in more contained places when building files for the host
_binaries_.

Richard.

> Richard.
>
>> cheers
>> Iain
>>

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:43       ` Iain Sandoe
@ 2014-12-04 13:47         ` Richard Biener
  2014-12-04 13:48           ` Richard Biener
  2014-12-04 13:52         ` FX
  1 sibling, 1 reply; 36+ messages in thread
From: Richard Biener @ 2014-12-04 13:47 UTC (permalink / raw)
  To: Iain Sandoe
  Cc: Rainer Orth, FX, gcc-patches, Paolo Bonzini, pmuldoon,
	Jakub Jelinek, Tom Tromey, GCC Development

On Thu, Dec 4, 2014 at 2:43 PM, Iain Sandoe <iain@codesourcery.com> wrote:
> Hi Rainer,
>
> On 4 Dec 2014, at 13:32, Rainer Orth wrote:
>
>> FX <fxcoudert@gmail.com> writes:
>>
>>> 10-days ping
>>> This restores bootstrap on a secondary target, target maintainer is OK with
>>> it. I think I need build maintainers approval, so please review.
>>
>> While in my testing, 64-bit Mac OS X 10.10.1 (x86_64-apple-darwin14.0.0)
>> now bootstraps, but 32-bit (i386-apple-darwin14.0.0) does not:
>>
>> ld: illegal text-relocation to 'anon' in ../libiberty/pic/libiberty.a(regex.o) from '_byte_common_op_match_null_string_p' in ../libiberty/pic/libiberty.a(regex.o) for architecture i386
>> collect2: error: ld returned 1 exit status
>> make[3]: *** [libcc1.la] Error 1
>> make[2]: *** [all] Error 2
>> make[1]: *** [all-libcc1] Error 2
>
> For {i?86,ppc}-darwin* (i.e. m32 hosts) the PIC libiberty library is being incorrectly built.
>
> The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
> the libiberty pic build appends: -fno-common (and not even -fPIC) [NB -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]
>
> This means that the PIC library is being built with non-pic relocs.
>
> I have a local hack to allow build to proceed on m32-host-darwin (which I can send to you if you would like it) - however, it's not really a suitable patch for trunk... and I've not had time recently to try and fix this.
>
> If you would like to raise a PR for this, I can append the analysis there.

The libiberty PIC build shouldn't use BOOT_CFLAGS.  How does
lto-plugin get around being built for the host but as a shared library?

Richard.

> cheers
> Iain
>

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:37       ` FX
@ 2014-12-04 13:47         ` Rainer Orth
  0 siblings, 0 replies; 36+ messages in thread
From: Rainer Orth @ 2014-12-04 13:47 UTC (permalink / raw)
  To: FX
  Cc: gcc-patches, Paolo Bonzini, pmuldoon, Jakub Jelinek, Tom Tromey,
	GCC Development, Iain Sandoe

FX <fxcoudert@gmail.com> writes:

>> While in my testing, 64-bit Mac OS X 10.10.1 (x86_64-apple-darwin14.0.0)
>> now bootstraps, but 32-bit (i386-apple-darwin14.0.0) does not:
>
> Is it due to my patch, or pre-existing bootstrap failure?

I can't tell: before your patch, 32-bit bootstrap was broken due to PR
bootstrap/63966 for quite some time.

> How do you configure this 32-bit compiler? target/build/host/CFLAGS/CXXFLAGS/etc

	--target=i386-apple-darwin14.0.0
	--build=i386-apple-darwin14.0.0
	--host=i386-apple-darwin14.0.0
	--enable-languages=all,ada,obj-c++ 

Bootstrap compiler is gcc 4.9.1 (patched for 10.10 support)

	CC='gcc -m32' 
        CXX='g++ -m32'

	Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:32     ` Rainer Orth
  2014-12-04 13:37       ` FX
@ 2014-12-04 13:43       ` Iain Sandoe
  2014-12-04 13:47         ` Richard Biener
  2014-12-04 13:52         ` FX
  1 sibling, 2 replies; 36+ messages in thread
From: Iain Sandoe @ 2014-12-04 13:43 UTC (permalink / raw)
  To: Rainer Orth
  Cc: FX, gcc-patches, Paolo Bonzini, pmuldoon, Jakub Jelinek,
	Tom Tromey, GCC Development

Hi Rainer,

On 4 Dec 2014, at 13:32, Rainer Orth wrote:

> FX <fxcoudert@gmail.com> writes:
> 
>> 10-days ping
>> This restores bootstrap on a secondary target, target maintainer is OK with
>> it. I think I need build maintainers approval, so please review.
> 
> While in my testing, 64-bit Mac OS X 10.10.1 (x86_64-apple-darwin14.0.0)
> now bootstraps, but 32-bit (i386-apple-darwin14.0.0) does not:
> 
> ld: illegal text-relocation to 'anon' in ../libiberty/pic/libiberty.a(regex.o) from '_byte_common_op_match_null_string_p' in ../libiberty/pic/libiberty.a(regex.o) for architecture i386
> collect2: error: ld returned 1 exit status
> make[3]: *** [libcc1.la] Error 1
> make[2]: *** [all] Error 2
> make[1]: *** [all-libcc1] Error 2

For {i?86,ppc}-darwin* (i.e. m32 hosts) the PIC libiberty library is being incorrectly built.

The default BOOT_CFLAGS are: -O2 -g -mdynamic-no-pic
the libiberty pic build appends: -fno-common (and not even -fPIC) [NB -fPIC _won't_ override -mdynamic-no-pic, so that's not a simple way out]

This means that the PIC library is being built with non-pic relocs.

I have a local hack to allow build to proceed on m32-host-darwin (which I can send to you if you would like it) - however, it's not really a suitable patch for trunk... and I've not had time recently to try and fix this.

If you would like to raise a PR for this, I can append the analysis there.

cheers
Iain

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04 13:32     ` Rainer Orth
@ 2014-12-04 13:37       ` FX
  2014-12-04 13:47         ` Rainer Orth
  2014-12-04 13:43       ` Iain Sandoe
  1 sibling, 1 reply; 36+ messages in thread
From: FX @ 2014-12-04 13:37 UTC (permalink / raw)
  To: Rainer Orth
  Cc: gcc-patches, Paolo Bonzini, pmuldoon, Jakub Jelinek, Tom Tromey,
	GCC Development, Iain Sandoe

> While in my testing, 64-bit Mac OS X 10.10.1 (x86_64-apple-darwin14.0.0)
> now bootstraps, but 32-bit (i386-apple-darwin14.0.0) does not:

Is it due to my patch, or pre-existing bootstrap failure?
How do you configure this 32-bit compiler? target/build/host/CFLAGS/CXXFLAGS/etc

FX

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-12-04  9:12   ` FX
@ 2014-12-04 13:32     ` Rainer Orth
  2014-12-04 13:37       ` FX
  2014-12-04 13:43       ` Iain Sandoe
  0 siblings, 2 replies; 36+ messages in thread
From: Rainer Orth @ 2014-12-04 13:32 UTC (permalink / raw)
  To: FX
  Cc: gcc-patches, Paolo Bonzini, pmuldoon, Jakub Jelinek, Tom Tromey,
	GCC Development, Iain Sandoe

FX <fxcoudert@gmail.com> writes:

> 10-days ping
> This restores bootstrap on a secondary target, target maintainer is OK with
> it. I think I need build maintainers approval, so please review.

While in my testing, 64-bit Mac OS X 10.10.1 (x86_64-apple-darwin14.0.0)
now bootstraps, but 32-bit (i386-apple-darwin14.0.0) does not:

ld: illegal text-relocation to 'anon' in ../libiberty/pic/libiberty.a(regex.o) from '_byte_common_op_match_null_string_p' in ../libiberty/pic/libiberty.a(regex.o) for architecture i386
collect2: error: ld returned 1 exit status
make[3]: *** [libcc1.la] Error 1
make[2]: *** [all] Error 2
make[1]: *** [all-libcc1] Error 2

I couldn't find a corresponding reloc in otool -rv output, though.

	Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-11-24  2:28 ` FX
  2014-11-25 20:59   ` Mike Stump
@ 2014-12-04  9:12   ` FX
  2014-12-04 13:32     ` Rainer Orth
  2014-12-05 16:35   ` Jakub Jelinek
  2 siblings, 1 reply; 36+ messages in thread
From: FX @ 2014-12-04  9:12 UTC (permalink / raw)
  To: gcc-patches
  Cc: Paolo Bonzini, Rainer Orth, pmuldoon, Jakub Jelinek, Tom Tromey,
	GCC Development, Iain Sandoe

[-- Attachment #1: Type: text/plain, Size: 738 bytes --]

10-days ping
This restores bootstrap on a secondary target, target maintainer is OK with it. I think I need build maintainers approval, so please review.


> when the freshly built g++ is used, we need to pass the appropriate -B options. As I understand it, the appropriate place for that is in the toplevel configure.ac, where we already pass down the respective -L options. Indeed, the attached patch restores bootstrap on x86_64-apple-darwin14 with gcc as system compiler (and doesn’t break the bootstrap with clang as system compiler).
> 
> OK to commit?
> 
> FX
> 
> 
> 
> PS: HJ, the reason only don’t see this on Linux is that only Darwin (AFAIK) plays spec tricks with static-libstdc++ (in gcc/config/darwin.h)


[-- Attachment #2: libcc1.ChangeLog --]
[-- Type: application/octet-stream, Size: 227 bytes --]

2014-11-24  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>

	PR bootstrap/64023
	* configure.ac (CXX_FOR_TARGET, RAW_CXX_FOR_TARGET): Pass -B
	options in addition to -L for libstdc++ and libsupc++.
	* configure: Regenerate.


[-- Attachment #3: libcc1.diff --]
[-- Type: application/octet-stream, Size: 4277 bytes --]

Index: configure.ac
===================================================================
--- configure.ac	(revision 217986)
+++ configure.ac	(working copy)
@@ -3330,10 +3330,10 @@ GCC_TARGET_TOOL(as, AS_FOR_TARGET, AS, [
 GCC_TARGET_TOOL(cc, CC_FOR_TARGET, CC, [gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/])
 dnl see comments for CXX_FOR_TARGET_FLAG_TO_PASS
 GCC_TARGET_TOOL(c++, CXX_FOR_TARGET, CXX,
-		[gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
+		[gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
 		c++)
 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],
+		[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 -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
 		c++)
 GCC_TARGET_TOOL(dlltool, DLLTOOL_FOR_TARGET, DLLTOOL, [binutils/dlltool])
 GCC_TARGET_TOOL(gcc, GCC_FOR_TARGET, , [gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/])
Index: configure
===================================================================
--- configure	(revision 217986)
+++ configure	(working copy)
@@ -13701,7 +13701,7 @@ else
   esac
   if test $ok = yes; then
     # An in-tree tool is available and we can use it
-    CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
+    CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
 $as_echo "just compiled" >&6; }
   elif expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
@@ -13746,7 +13746,7 @@ else
   esac
   if test $ok = yes; then
     # An in-tree tool is available and we can use it
-    RAW_CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/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'
+    RAW_CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/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 -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
 $as_echo "just compiled" >&6; }
   elif expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-11-25 21:37     ` Phil Muldoon
@ 2014-11-25 23:27       ` Jeff Law
  0 siblings, 0 replies; 36+ messages in thread
From: Jeff Law @ 2014-11-25 23:27 UTC (permalink / raw)
  To: Phil Muldoon, Mike Stump, FX
  Cc: Paolo Bonzini, Rainer Orth, Jakub Jelinek, Tom Tromey,
	GCC Development, gcc-patches, Iain Sandoe

On 11/25/14 13:57, Phil Muldoon wrote:
> On 25/11/14 20:37, Mike Stump wrote:
>> On Nov 23, 2014, at 4:06 PM, FX <fxcoudert@gmail.com> wrote:
>>> One question to build maintainers, and one patch submitted to top-level configure.ac
>>
>> So, not sure who wants to review this.  From the darwin perspective, Ok.
>
> I mean from my limited viewpoint it looks fine. As long as the .so is
> built, that's really our only goal from a GDB point of view.  But I am
> not a maintainer, so I have refrained from commenting on this change,
> as it seems fairly straightforward.  Though I am no expert on GCC
> build systems.
I'm not sure there *is* an expert on the GCC buildsystem :(

jeff

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-11-25 20:59   ` Mike Stump
@ 2014-11-25 21:37     ` Phil Muldoon
  2014-11-25 23:27       ` Jeff Law
  0 siblings, 1 reply; 36+ messages in thread
From: Phil Muldoon @ 2014-11-25 21:37 UTC (permalink / raw)
  To: Mike Stump, FX
  Cc: Paolo Bonzini, Rainer Orth, Jakub Jelinek, Tom Tromey,
	GCC Development, gcc-patches, Iain Sandoe

On 25/11/14 20:37, Mike Stump wrote:
> On Nov 23, 2014, at 4:06 PM, FX <fxcoudert@gmail.com> wrote:
>> One question to build maintainers, and one patch submitted to top-level configure.ac
>
> So, not sure who wants to review this.  From the darwin perspective, Ok.

I mean from my limited viewpoint it looks fine. As long as the .so is
built, that's really our only goal from a GDB point of view.  But I am
not a maintainer, so I have refrained from commenting on this change,
as it seems fairly straightforward.  Though I am no expert on GCC
build systems.

Cheers

Phil

^ permalink raw reply	[flat|nested] 36+ messages in thread

* Re: [patch, build] Restore bootstrap in building libcc1 on darwin
  2014-11-24  2:28 ` FX
@ 2014-11-25 20:59   ` Mike Stump
  2014-11-25 21:37     ` Phil Muldoon
  2014-12-04  9:12   ` FX
  2014-12-05 16:35   ` Jakub Jelinek
  2 siblings, 1 reply; 36+ messages in thread
From: Mike Stump @ 2014-11-25 20:59 UTC (permalink / raw)
  To: FX
  Cc: Paolo Bonzini, Rainer Orth, pmuldoon, Jakub Jelinek, Tom Tromey,
	GCC Development, gcc-patches, Iain Sandoe

On Nov 23, 2014, at 4:06 PM, FX <fxcoudert@gmail.com> wrote:
> One question to build maintainers, and one patch submitted to top-level configure.ac

So, not sure who wants to review this.  From the darwin perspective, Ok.

^ permalink raw reply	[flat|nested] 36+ messages in thread

* [patch, build] Restore bootstrap in building libcc1 on darwin
       [not found] <94381BB6-563C-44EE-910E-9569410F2AB5@gmail.com>
@ 2014-11-24  2:28 ` FX
  2014-11-25 20:59   ` Mike Stump
                     ` (2 more replies)
  0 siblings, 3 replies; 36+ messages in thread
From: FX @ 2014-11-24  2:28 UTC (permalink / raw)
  To: Paolo Bonzini, Rainer Orth, pmuldoon, Jakub Jelinek, Tom Tromey
  Cc: GCC Development, gcc-patches, Iain Sandoe

[-- Attachment #1: Type: text/plain, Size: 2005 bytes --]

tl;dr: One question to build maintainers, and one patch submitted to toplevel configure.ac

---------------

I’m looked into the issue some more, and am comparing two builds of trunk (exact same source), one configured with system compiler (clang) in PATH, the other with GCC 4.9.2 in PATH.
At the toplevel configure, the only meaningful difference is that the gcc-based build sets stage1_ldflags='-static-libstdc++ -static-libgcc' while the clang-based has stage1_ldflags='' (clang doesn’t recognized -static-libstdc++).

This is included into the toplevel Makefile as STAGE1_LDFLAGS (the comment appropriately says "Linker flags to use on the host, for stage1 or when not bootstrapping”).
Those are exported by HOST_EXPORTS, which is are then used by configure-libcc1, all-libcc1, etc. Thus, we end up using STAGE1_LDFLAGS, which correspond to the system compiler, instead of the stage3 compiler (as we should).

So, this is “false negative” part of the problem (namely, why we don’t see the failure when bootstrapping with clang): we use STAGE1_LDFLAGS in building libcc1, and with clang as system compiler we don’t use static linking of the C++ library. This part, I don’t know how to fix: it is for the build experts to address. It is a real problem: it leads to libcc1.so being linked dynamically to libstdc++ and libgcc, instead of statically (as it should).

---------------

Second part of the question: when the freshly built g++ is used, we need to pass the appropriate -B options. As I understand it, the appropriate place for that is in the toplevel configure.ac, where we already pass down the respective -L options. Indeed, the attached patch restores bootstrap on x86_64-apple-darwin14 with gcc as system compiler (and doesn’t break the bootstrap with clang as system compiler).

OK to commit?

FX



PS: HJ, the reason only don’t see this on Linux is that only Darwin (AFAIK) plays spec tricks with static-libstdc++ (in gcc/config/darwin.h)



[-- Attachment #2: libcc1.ChangeLog --]
[-- Type: application/octet-stream, Size: 227 bytes --]

2014-11-24  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>

	PR bootstrap/64023
	* configure.ac (CXX_FOR_TARGET, RAW_CXX_FOR_TARGET): Pass -B
	options in addition to -L for libstdc++ and libsupc++.
	* configure: Regenerate.


[-- Attachment #3: libcc1.diff --]
[-- Type: application/octet-stream, Size: 4277 bytes --]

Index: configure.ac
===================================================================
--- configure.ac	(revision 217986)
+++ configure.ac	(working copy)
@@ -3330,10 +3330,10 @@ GCC_TARGET_TOOL(as, AS_FOR_TARGET, AS, [
 GCC_TARGET_TOOL(cc, CC_FOR_TARGET, CC, [gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/])
 dnl see comments for CXX_FOR_TARGET_FLAG_TO_PASS
 GCC_TARGET_TOOL(c++, CXX_FOR_TARGET, CXX,
-		[gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
+		[gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
 		c++)
 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],
+		[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 -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
 		c++)
 GCC_TARGET_TOOL(dlltool, DLLTOOL_FOR_TARGET, DLLTOOL, [binutils/dlltool])
 GCC_TARGET_TOOL(gcc, GCC_FOR_TARGET, , [gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/])
Index: configure
===================================================================
--- configure	(revision 217986)
+++ configure	(working copy)
@@ -13701,7 +13701,7 @@ else
   esac
   if test $ok = yes; then
     # An in-tree tool is available and we can use it
-    CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
+    CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
 $as_echo "just compiled" >&6; }
   elif expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
@@ -13746,7 +13746,7 @@ else
   esac
   if test $ok = yes; then
     # An in-tree tool is available and we can use it
-    RAW_CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/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'
+    RAW_CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/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 -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs -B$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
     { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
 $as_echo "just compiled" >&6; }
   elif expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then

^ permalink raw reply	[flat|nested] 36+ messages in thread

end of thread, other threads:[~2015-03-09 18:43 UTC | newest]

Thread overview: 36+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-12-05 22:34 [patch, build] Restore bootstrap in building libcc1 on darwin Dominique Dhumieres
2014-12-05 22:41 ` Jeff Law
2014-12-05 22:46   ` Phil Muldoon
2014-12-06 11:16   ` Iain Sandoe
2014-12-05 22:48 ` Jakub Jelinek
2014-12-06  0:50   ` Dominique d'Humières
2014-12-09 17:08     ` Dominique d'Humières
2014-12-13 10:52   ` Paolo Bonzini
2014-12-13 11:26     ` Paolo Bonzini
  -- strict thread matches above, loose matches on Subject: below --
2014-12-05 19:12 Dominique Dhumieres
2014-12-05 20:16 ` Jakub Jelinek
     [not found] <94381BB6-563C-44EE-910E-9569410F2AB5@gmail.com>
2014-11-24  2:28 ` FX
2014-11-25 20:59   ` Mike Stump
2014-11-25 21:37     ` Phil Muldoon
2014-11-25 23:27       ` Jeff Law
2014-12-04  9:12   ` FX
2014-12-04 13:32     ` Rainer Orth
2014-12-04 13:37       ` FX
2014-12-04 13:47         ` Rainer Orth
2014-12-04 13:43       ` Iain Sandoe
2014-12-04 13:47         ` Richard Biener
2014-12-04 13:48           ` Richard Biener
2014-12-04 13:53             ` Richard Biener
2014-12-04 13:52         ` FX
2014-12-04 13:54           ` Richard Biener
2014-12-04 15:24             ` FX
2014-12-04 15:36               ` Iain Sandoe
2015-01-26 15:02           ` Rainer Orth
2015-01-26 15:06             ` Iain Sandoe
2015-02-01 16:42             ` Iain Sandoe
2015-02-09 22:47               ` Jeff Law
2015-02-11 14:38                 ` Iain Sandoe
2015-03-08 17:38                   ` Iain Sandoe
2015-03-08 17:48                     ` Ian Lance Taylor
2015-03-09 18:43                     ` Mike Stump
2014-12-05 16:35   ` Jakub Jelinek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).