summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Rules.mak2
1 files changed, 1 insertions, 1 deletions
diff --git a/Rules.mak b/Rules.mak
index 7478c2a01..8a3636cc7 100644
--- a/Rules.mak
+++ b/Rules.mak
@@ -296,7 +296,7 @@ ifndef LDPIEFLAG
ifneq ($(UCLIBC_BUILD_PIE),y)
export LDPIEFLAG:=
else
-export LDPIEFLAG:=$(shell $(LD) --help | grep -q pie && echo "-Wl,-pie")
+export LDPIEFLAG:=$(shell $(LD) --help 2>/dev/null | grep -q -- -pie && echo "-Wl,-pie")
endif
endif