mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
makefiles: comman escape needs this trick
This commit is contained in:
parent
a8009f72bf
commit
b14f29ab5b
@ -233,19 +233,20 @@ endif
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ("@HAVE_FULL_RELRO@", "yes")
|
ifeq ("@HAVE_FULL_RELRO@", "yes")
|
||||||
|
comma := ,
|
||||||
ifneq ("@STATIC_LINK@", "yes")
|
ifneq ("@STATIC_LINK@", "yes")
|
||||||
ifeq (,$(findstring -z\,relro,$(LDFLAGS)))
|
ifeq (,$(findstring -z$(comma)relro,$(LDFLAGS)))
|
||||||
LDFLAGS += -Wl,-z,relro
|
LDFLAGS += -Wl,-z,relro
|
||||||
endif
|
endif
|
||||||
ifeq (,$(findstring -z\,now,$(LDFLAGS)))
|
ifeq (,$(findstring -z$(comma)now,$(LDFLAGS)))
|
||||||
LDFLAGS += -Wl,-z,now
|
LDFLAGS += -Wl,-z,now
|
||||||
endif
|
endif
|
||||||
ifeq (,$(findstring -z\,pack-relative-relocs,$(LDFLAGS)))
|
ifeq (,$(findstring -z$(comma)pack-relative-relocs,$(LDFLAGS)))
|
||||||
LDFLAGS += -Wl,-z,pack-relative-relocs
|
LDFLAGS += -Wl,-z,pack-relative-relocs
|
||||||
endif
|
endif
|
||||||
# For systems with old readline library that requires extra libs to link with
|
# For systems with old readline library that requires extra libs to link with
|
||||||
# we stick to default --no-as-needed and we avoid adding --as-needed flag
|
# we stick to default --no-as-needed and we avoid adding --as-needed flag
|
||||||
ifneq (2,$(words $(findstring -l,$(READLINE_LIBS))))
|
ifneq (2,$(words $(findstring -l%,$(READLINE_LIBS))))
|
||||||
ifeq (,$(findstring --as-needed,$(LDFLAGS)))
|
ifeq (,$(findstring --as-needed,$(LDFLAGS)))
|
||||||
LDFLAGS += -Wl,--as-needed
|
LDFLAGS += -Wl,--as-needed
|
||||||
endif
|
endif
|
||||||
|
@ -270,19 +270,20 @@ endif
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ("@HAVE_FULL_RELRO@", "yes")
|
ifeq ("@HAVE_FULL_RELRO@", "yes")
|
||||||
|
comma := ,
|
||||||
ifneq ("@STATIC_LINK@", "yes")
|
ifneq ("@STATIC_LINK@", "yes")
|
||||||
ifeq (,$(findstring -z\,relro,$(LDFLAGS)))
|
ifeq (,$(findstring -z$(comma)relro,$(LDFLAGS)))
|
||||||
LDFLAGS += -Wl,-z,relro
|
LDFLAGS += -Wl,-z,relro
|
||||||
endif
|
endif
|
||||||
ifeq (,$(findstring -z\,now,$(LDFLAGS)))
|
ifeq (,$(findstring -z$(comma)now,$(LDFLAGS)))
|
||||||
LDFLAGS += -Wl,-z,now
|
LDFLAGS += -Wl,-z,now
|
||||||
endif
|
endif
|
||||||
ifeq (,$(findstring -z\,pack-relative-relocs,$(LDFLAGS)))
|
ifeq (,$(findstring -z$(comma)pack-relative-relocs,$(LDFLAGS)))
|
||||||
LDFLAGS += -Wl,-z,pack-relative-relocs
|
LDFLAGS += -Wl,-z,pack-relative-relocs
|
||||||
endif
|
endif
|
||||||
# For systems with old readline library that requires extra libs to link with
|
# For systems with old readline library that requires extra libs to link with
|
||||||
# we stick to default --no-as-needed and we avoid adding --as-needed flag
|
# we stick to default --no-as-needed and we avoid adding --as-needed flag
|
||||||
ifneq (2,$(words $(findstring -l,$(READLINE_LIBS))))
|
ifneq (2,$(words $(findstring -l%,$(READLINE_LIBS))))
|
||||||
ifeq (,$(findstring --as-needed,$(LDFLAGS)))
|
ifeq (,$(findstring --as-needed,$(LDFLAGS)))
|
||||||
LDFLAGS += -Wl,--as-needed
|
LDFLAGS += -Wl,--as-needed
|
||||||
endif
|
endif
|
||||||
|
Loading…
Reference in New Issue
Block a user