diff options
Diffstat (limited to 'rules')
-rw-r--r-- | rules/build-package-way.mk | 2 | ||||
-rw-r--r-- | rules/distdir-way-opts.mk | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/rules/build-package-way.mk b/rules/build-package-way.mk index 905b7f09df..8f61a355eb 100644 --- a/rules/build-package-way.mk +++ b/rules/build-package-way.mk @@ -155,7 +155,7 @@ BINDIST_LIBS += $$($1_$2_GHCI_LIB) endif endif $$($1_$2_GHCI_LIB) : $$($1_$2_$3_HS_OBJS) $$($1_$2_$3_CMM_OBJS) $$($1_$2_$3_C_OBJS) $$($1_$2_$3_S_OBJS) $$($1_$2_EXTRA_OBJS) $$($1_$2_LD_SCRIPT) - $$(call cmd,LD) $$(CONF_LD_LINKER_OPTS_STAGE$4) -r $$(if $$($1_$2_LD_SCRIPT),-T $$($1_$2_LD_SCRIPT)) -o $$@ $$(EXTRA_LD_OPTS) $$($1_$2_$3_HS_OBJS) $$($1_$2_$3_CMM_OBJS) $$($1_$2_$3_C_OBJS) $$($1_$2_$3_S_OBJS) $$($1_$2_EXTRA_OBJS) + $$(call cmd,LD) $$(CONF_LD_LINKER_OPTS_STAGE$4) -r $$(if $$($1_$2_LD_SCRIPT),-T $$($1_$2_LD_SCRIPT)) -o $$@ $$(EXTRA_LD_LINKER_OPTS) $$($1_$2_$3_HS_OBJS) $$($1_$2_$3_CMM_OBJS) $$($1_$2_$3_C_OBJS) $$($1_$2_$3_S_OBJS) $$($1_$2_EXTRA_OBJS) ifeq "$$($1_$2_BUILD_GHCI_LIB)" "YES" # Don't bother making ghci libs for bootstrapping packages diff --git a/rules/distdir-way-opts.mk b/rules/distdir-way-opts.mk index 6ae9807944..62a145162e 100644 --- a/rules/distdir-way-opts.mk +++ b/rules/distdir-way-opts.mk @@ -196,14 +196,15 @@ $1_$2_$3_GHC_CC_OPTS = \ $$(addprefix -optc, $$($1_$2_$3_ALL_CC_OPTS)) \ $$($1_$2_$3_MOST_HC_OPTS) -# Options for passing to plain ld +# Options for passing to gcc for linking $1_$2_$3_ALL_LD_OPTS = \ $$(WAY_$3_LD_OPTS) \ $$($1_$2_DIST_LD_OPTS) \ $$($1_$2_$3_LD_OPTS) \ $$($1_$2_EXTRA_LD_OPTS) \ $$(EXTRA_LD_OPTS) \ - $$(CONF_LD_LINKER_OPTS_STAGE$4) + $$(foreach o,$$(EXTRA_LD_LINKER_OPTS),-optl-Wl$$(comma)$$o) \ + $$(foreach o,$$(CONF_LD_LINKER_OPTS_STAGE$4),-optl-Wl$$(comma)$$o) # Options for passing to GHC when we use it for linking $1_$2_$3_GHC_LD_OPTS = \ |