Brad Bishop | d7bf8c1 | 2018-02-25 22:55:05 -0500 | [diff] [blame] | 1 | From 6864ba28dec61609662ce5dc8bc7ed1925abb546 Mon Sep 17 00:00:00 2001 |
| 2 | From: Hongxu Jia <hongxu.jia@windriver.com> |
| 3 | Date: Wed, 5 Jul 2017 02:56:13 -0400 |
| 4 | Subject: [PATCH 12/14] multipath-tools: modify Makefile.inc for |
| 5 | cross-compilation |
| 6 | |
| 7 | Do not look for systemd info on the host, and allow us to pass in CFLAGS |
| 8 | using the OPTFLAGS variable. |
| 9 | |
| 10 | Upstream-Status: Inappropriate [embedded specific] |
| 11 | |
| 12 | Signed-off-by: Joe Slater <joe.slater@windriver.com> |
| 13 | |
| 14 | Update for version 0.5.0-144-g770e6d0 |
| 15 | |
| 16 | Signed-off-by: Kai Kang <kai.kang@windriver.com> |
| 17 | |
| 18 | Update for version 0.7.1 |
| 19 | |
| 20 | Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> |
| 21 | --- |
| 22 | Makefile.inc | 8 ++------ |
| 23 | 1 file changed, 2 insertions(+), 6 deletions(-) |
| 24 | |
| 25 | diff --git a/Makefile.inc b/Makefile.inc |
| 26 | index e084fd1..c7f45fa 100644 |
| 27 | --- a/Makefile.inc |
| 28 | +++ b/Makefile.inc |
| 29 | @@ -35,12 +35,6 @@ ifndef RUN |
| 30 | endif |
| 31 | endif |
| 32 | |
| 33 | -ifndef SYSTEMD |
| 34 | - ifeq ($(shell systemctl --version > /dev/null 2>&1 && echo 1), 1) |
| 35 | - SYSTEMD = $(shell systemctl --version 2> /dev/null | sed -n 's/systemd \([0-9]*\)/\1/p') |
| 36 | - endif |
| 37 | -endif |
| 38 | - |
| 39 | ifndef SYSTEMDPATH |
| 40 | SYSTEMDPATH=usr/lib |
| 41 | endif |
| 42 | @@ -82,11 +76,13 @@ TEST_CC_OPTION = $(shell \ |
| 43 | |
| 44 | STACKPROT := $(call TEST_CC_OPTION,-fstack-protector-strong,-fstack-protector) |
| 45 | |
| 46 | +ifndef OPTFLAGS |
| 47 | OPTFLAGS = -O2 -g -pipe -Wall -Wextra -Wformat=2 -Werror=implicit-int \ |
| 48 | -Werror=implicit-function-declaration -Werror=format-security \ |
| 49 | -Wno-sign-compare -Wno-unused-parameter -Wno-clobbered \ |
| 50 | -Wp,-D_FORTIFY_SOURCE=2 $(STACKPROT) \ |
| 51 | --param=ssp-buffer-size=4 |
| 52 | +endif |
| 53 | |
| 54 | CFLAGS = $(OPTFLAGS) -DLIB_STRING=\"${LIB}\" -DRUN_DIR=\"${RUN}\" |
| 55 | BIN_CFLAGS = -fPIE -DPIE |
| 56 | -- |
| 57 | 2.8.1 |
| 58 | |