mirror of
https://gitlab.freedesktop.org/libevdev/libevdev.git
synced 2025-12-24 17:00:07 +01:00
Check for GNU ld and use the flags depending on the outcome
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: David Herrmann <dh.herrmann@gmail.com>
This commit is contained in:
parent
95df174f06
commit
0b712e6f86
2 changed files with 6 additions and 4 deletions
|
|
@ -32,6 +32,11 @@ AC_PROG_CC
|
|||
# Initialize libtool
|
||||
LT_PREREQ([2.2])
|
||||
LT_INIT
|
||||
LT_PATH_LD
|
||||
if test "x$lt_cv_prog_gnu_ld" = "xyes"; then
|
||||
GNU_LD_FLAGS="-Wl,--as-needed -Wl,--gc-sections -Wl,-z,relro -Wl,-z,now"
|
||||
AC_SUBST(GNU_LD_FLAGS)
|
||||
fi
|
||||
|
||||
PKG_PROG_PKG_CONFIG()
|
||||
PKG_CHECK_MODULES(CHECK, [check], [HAVE_CHECK="yes"], [HAVE_CHECK="no"])
|
||||
|
|
|
|||
|
|
@ -15,10 +15,7 @@ libevdev_la_LDFLAGS = \
|
|||
-version-info $(LIBEVDEV_LT_VERSION) \
|
||||
-export-symbols-regex '^libevdev_' \
|
||||
$(GCOV_LDFLAGS) \
|
||||
-Wl,--as-needed \
|
||||
-Wl,--gc-sections \
|
||||
-Wl,-z,relro \
|
||||
-Wl,-z,now
|
||||
$(GNU_LD_FLAGS)
|
||||
|
||||
libevdevincludedir = $(includedir)/libevdev-1.0/libevdev
|
||||
libevdevinclude_HEADERS = libevdev.h libevdev-uinput.h
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue