blob: 71963e0c49ba7dd751260401fb71bb15208f9fcc [file] [log] [blame]
Patrick Williamsb48b7b42016-08-17 15:04:38 -05001multipath-tools: modify Makefile.inc for cross-compilation
2
3Do not look for systemd info on the host, and allow us to pass in CFLAGS
4using the OPTFLAGS variable.
5
6Upstream-Status: Inappropriate [embedded specific]
7
8Signed-off-by: Joe Slater <joe.slater@windriver.com>
9
10Update for version 0.5.0-144-g770e6d0
11
12Signed-off-by: Kai Kang <kai.kang@windriver.com>
13
14--- a/Makefile.inc
15+++ b/Makefile.inc
16@@ -21,12 +21,6 @@ ifndef LIB
17 endif
18 endif
19
20-ifndef SYSTEMD
21- ifeq ($(shell systemctl --version > /dev/null 2>&1 && echo 1), 1)
22- SYSTEMD = $(shell systemctl --version 2> /dev/null | sed -n 's/systemd \([0-9]*\)/\1/p')
23- endif
24-endif
25-
26 ifndef SYSTEMDPATH
27 SYSTEMDPATH=usr/lib
28 endif
29@@ -53,7 +47,10 @@ ifndef RPM_OPT_FLAGS
30 RPM_OPT_FLAGS = -O2 -g -pipe -Wformat-security -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4
31 endif
32
33+ifndef OPTFLAGS
34 OPTFLAGS = $(RPM_OPT_FLAGS) -Wunused -Wstrict-prototypes
35+endif
36+
37 CFLAGS = $(OPTFLAGS) -fPIC -DLIB_STRING=\"${LIB}\"
38 SHARED_FLAGS = -shared
39