aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mk/libraries.mk3
-rw-r--r--src/libstore/globals.hh2
2 files changed, 3 insertions, 2 deletions
diff --git a/mk/libraries.mk b/mk/libraries.mk
index 307e29b9d..e6ef2e3ec 100644
--- a/mk/libraries.mk
+++ b/mk/libraries.mk
@@ -125,7 +125,8 @@ define build-library
$(1)_PATH := $$(_d)/$$($(1)_NAME).a
$$($(1)_PATH): $$($(1)_OBJS) | $$(_d)/
- $(trace-ar) $(AR) crs $$@ $$?
+ $(trace-ld) $(LD) -Ur -o $$(_d)/$$($(1)_NAME).o $$?
+ $(trace-ar) $(AR) crs $$@ $$(_d)/$$($(1)_NAME).o
$(1)_LDFLAGS_USE += $$($(1)_PATH) $$($(1)_LDFLAGS)
diff --git a/src/libstore/globals.hh b/src/libstore/globals.hh
index da95fd3ae..2fbcafff8 100644
--- a/src/libstore/globals.hh
+++ b/src/libstore/globals.hh
@@ -271,7 +271,7 @@ public:
"listed in 'trusted-public-keys'."};
Setting<StringSet> extraPlatforms{this,
- std::string{SYSTEM} == "x86_64-linux" ? StringSet{"i686-linux"} : StringSet{},
+ std::string{SYSTEM} == "x86_64-linux" && !isWSL1() ? StringSet{"i686-linux"} : StringSet{},
"extra-platforms",
"Additional platforms that can be built on the local system. "
"These may be supported natively (e.g. armv7 on some aarch64 CPUs "