summaryrefslogtreecommitdiffstats
path: root/meta-oe
diff options
context:
space:
mode:
authorAndré Draszik <andre.draszik@jci.com>2018-01-12 13:16:58 +0000
committerArmin Kuster <akuster808@gmail.com>2018-01-22 19:36:04 -0800
commit000b80ef91ea37e57988eeb43b674c7f1b6f4fe7 (patch)
tree5abdbdd513d913d2c3ce4171f89912976ce1b70e /meta-oe
parentfa6d5d1087d299f40e19e5299a14f97c421beaf0 (diff)
downloadmeta-openembedded-000b80ef91ea37e57988eeb43b674c7f1b6f4fe7.tar.gz
mosquitto: simplify build patch
By simply allowing to set certain make variables from the environment, and by specifying the strip program to use (/bin/true), we can greatly simplify the build patch. Signed-off-by: André Draszik <andre.draszik@jci.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
Diffstat (limited to 'meta-oe')
-rw-r--r--meta-oe/recipes-connectivity/mosquitto/files/0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch35
-rw-r--r--meta-oe/recipes-connectivity/mosquitto/files/build.patch94
-rw-r--r--meta-oe/recipes-connectivity/mosquitto/mosquitto_1.4.14.bb3
3 files changed, 37 insertions, 95 deletions
diff --git a/meta-oe/recipes-connectivity/mosquitto/files/0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch b/meta-oe/recipes-connectivity/mosquitto/files/0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch
new file mode 100644
index 000000000..a5aa277a0
--- /dev/null
+++ b/meta-oe/recipes-connectivity/mosquitto/files/0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch
@@ -0,0 +1,35 @@
1From 0be38301249d797ec1f59071cc868ceda6d4720a Mon Sep 17 00:00:00 2001
2From: =?UTF-8?q?Andr=C3=A9=20Draszik?= <andre.draszik@jci.com>
3Date: Tue, 12 Apr 2016 12:50:32 +0100
4Subject: [PATCH 1/2] config.mk: allow prefix / mandir / localedir from
5 environment
6MIME-Version: 1.0
7Content-Type: text/plain; charset=UTF-8
8Content-Transfer-Encoding: 8bit
9
10We want to control them using OE environment variables.
11
12Upstream-Status: Inappropriate [embedded-specific]
13Signed-off-by: André Draszik <andre.draszik@jci.com>
14---
15 config.mk | 6 +++---
16 1 file changed, 3 insertions(+), 3 deletions(-)
17
18diff --git a/config.mk b/config.mk
19index 71f17e5..81d9702 100644
20--- a/config.mk
21+++ b/config.mk
22@@ -249,7 +249,7 @@ ifeq ($(WITH_DOCS),yes)
23 endif
24
25 INSTALL?=install
26-prefix=/usr/local
27-mandir=${prefix}/share/man
28-localedir=${prefix}/share/locale
29+prefix?=/usr/local
30+mandir?=${prefix}/share/man
31+localedir?=${prefix}/share/locale
32 STRIP?=strip
33--
342.15.1
35
diff --git a/meta-oe/recipes-connectivity/mosquitto/files/build.patch b/meta-oe/recipes-connectivity/mosquitto/files/build.patch
deleted file mode 100644
index 0d0912b7a..000000000
--- a/meta-oe/recipes-connectivity/mosquitto/files/build.patch
+++ /dev/null
@@ -1,94 +0,0 @@
1From ebd7c8e548e9b8e096ee4c390173db9a701f2604 Mon Sep 17 00:00:00 2001
2From: Bruno Bottazzini <bruno.bottazzini@intel.com>
3Date: Wed, 23 Mar 2016 11:18:26 -0300
4Subject: [PATCH] build
5
6Disable stripping and allow easily overriding prefix
7
8Upstream-Status: Pending
9
10Signed-off-by: Bruno Bottazzini <bruno.bottazzini@intel.com>
11---
12 client/Makefile | 4 ++--
13 config.mk | 2 +-
14 lib/Makefile | 2 +-
15 lib/cpp/Makefile | 2 +-
16 src/Makefile | 4 ++--
17 5 files changed, 7 insertions(+), 7 deletions(-)
18
19diff --git a/client/Makefile b/client/Makefile
20index bd65355..4e5a640 100644
21--- a/client/Makefile
22+++ b/client/Makefile
23@@ -24,8 +24,8 @@ client_shared.o : client_shared.c client
24
25 install : all
26 $(INSTALL) -d ${DESTDIR}$(prefix)/bin
27- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} mosquitto_pub ${DESTDIR}${prefix}/bin/mosquitto_pub
28- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} mosquitto_sub ${DESTDIR}${prefix}/bin/mosquitto_sub
29+ $(INSTALL) mosquitto_pub ${DESTDIR}${prefix}/bin/mosquitto_pub
30+ $(INSTALL) mosquitto_sub ${DESTDIR}${prefix}/bin/mosquitto_sub
31
32 uninstall :
33 -rm -f ${DESTDIR}${prefix}/bin/mosquitto_pub
34diff --git a/config.mk b/config.mk
35index c0f175f..3427b83 100644
36--- a/config.mk
37+++ b/config.mk
38@@ -241,7 +241,7 @@ ifeq ($(WITH_DOCS),yes)
39 endif
40
41 INSTALL?=install
42-prefix=/usr/local
43+prefix?=/usr
44 mandir=${prefix}/share/man
45 localedir=${prefix}/share/locale
46 STRIP?=strip
47diff --git a/lib/Makefile b/lib/Makefile
48index 825fcea..9b7c05c 100644
49--- a/lib/Makefile
50+++ b/lib/Makefile
51@@ -25,7 +25,7 @@ all : libmosquitto.so.${SOVERSION} libmo
52
53 install : all
54 $(INSTALL) -d ${DESTDIR}$(prefix)/lib${LIB_SUFFIX}/
55- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} libmosquitto.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquitto.so.${SOVERSION}
56+ $(INSTALL) libmosquitto.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquitto.so.${SOVERSION}
57 ln -sf libmosquitto.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquitto.so
58 $(INSTALL) -d ${DESTDIR}${prefix}/include/
59 $(INSTALL) mosquitto.h ${DESTDIR}${prefix}/include/mosquitto.h
60diff --git a/lib/cpp/Makefile b/lib/cpp/Makefile
61index 8b627d3..cdb2923 100644
62--- a/lib/cpp/Makefile
63+++ b/lib/cpp/Makefile
64@@ -10,7 +10,7 @@ all : libmosquittopp.so.${SOVERSION}
65
66 install : all
67 $(INSTALL) -d ${DESTDIR}$(prefix)/lib${LIB_SUFFIX}/
68- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} libmosquittopp.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquittopp.so.${SOVERSION}
69+ $(INSTALL) libmosquittopp.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquittopp.so.${SOVERSION}
70 ln -sf libmosquittopp.so.${SOVERSION} ${DESTDIR}${prefix}/lib${LIB_SUFFIX}/libmosquittopp.so
71 $(INSTALL) -d ${DESTDIR}${prefix}/include/
72 $(INSTALL) mosquittopp.h ${DESTDIR}${prefix}/include/mosquittopp.h
73diff --git a/src/Makefile b/src/Makefile
74index 2cfb7d4..9a97644 100644
75--- a/src/Makefile
76+++ b/src/Makefile
77@@ -103,12 +103,12 @@ mosquitto_passwd.o : mosquitto_passwd.c
78
79 install : all
80 $(INSTALL) -d ${DESTDIR}$(prefix)/sbin
81- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} mosquitto ${DESTDIR}${prefix}/sbin/mosquitto
82+ $(INSTALL) mosquitto ${DESTDIR}${prefix}/sbin/mosquitto
83 $(INSTALL) -d ${DESTDIR}$(prefix)/include
84 $(INSTALL) mosquitto_plugin.h ${DESTDIR}${prefix}/include/mosquitto_plugin.h
85 ifeq ($(WITH_TLS),yes)
86 $(INSTALL) -d ${DESTDIR}$(prefix)/bin
87- $(INSTALL) -s --strip-program=${CROSS_COMPILE}${STRIP} mosquitto_passwd ${DESTDIR}${prefix}/bin/mosquitto_passwd
88+ $(INSTALL) mosquitto_passwd ${DESTDIR}${prefix}/bin/mosquitto_passwd
89 endif
90
91 uninstall :
92--
932.7.1
94
diff --git a/meta-oe/recipes-connectivity/mosquitto/mosquitto_1.4.14.bb b/meta-oe/recipes-connectivity/mosquitto/mosquitto_1.4.14.bb
index 07440a241..13ce3811d 100644
--- a/meta-oe/recipes-connectivity/mosquitto/mosquitto_1.4.14.bb
+++ b/meta-oe/recipes-connectivity/mosquitto/mosquitto_1.4.14.bb
@@ -11,7 +11,7 @@ LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=62ddc846179e908dc0c8efec4a42ef20 \
11DEPENDS = "uthash" 11DEPENDS = "uthash"
12 12
13SRC_URI = "http://mosquitto.org/files/source/mosquitto-${PV}.tar.gz \ 13SRC_URI = "http://mosquitto.org/files/source/mosquitto-${PV}.tar.gz \
14 file://build.patch \ 14 file://0001-config.mk-allow-prefix-mandir-localedir-from-environ.patch \
15 file://0002-uthash-remove-in-tree-version.patch \ 15 file://0002-uthash-remove-in-tree-version.patch \
16 file://mosquitto.service \ 16 file://mosquitto.service \
17 file://mosquitto.init \ 17 file://mosquitto.init \
@@ -28,6 +28,7 @@ PACKAGECONFIG[dns-srv] = ",,c-ares"
28PACKAGECONFIG[ssl] = ",,openssl" 28PACKAGECONFIG[ssl] = ",,openssl"
29PACKAGECONFIG[uuid] = ",,util-linux" 29PACKAGECONFIG[uuid] = ",,util-linux"
30EXTRA_OEMAKE = "${@bb.utils.contains('PACKAGECONFIG', 'dns-srv', 'WITH_SRV=yes', 'WITH_SRV=no', d)} \ 30EXTRA_OEMAKE = "${@bb.utils.contains('PACKAGECONFIG', 'dns-srv', 'WITH_SRV=yes', 'WITH_SRV=no', d)} \
31 STRIP=/bin/true \
31 WITH_DOCS=no \ 32 WITH_DOCS=no \
32 ${@bb.utils.contains('PACKAGECONFIG', 'ssl', 'WITH_TLS=yes WITH_TLS_PSK=yes', 'WITH_TLS=no WITH_TLS_PSK=no', d)} \ 33 ${@bb.utils.contains('PACKAGECONFIG', 'ssl', 'WITH_TLS=yes WITH_TLS_PSK=yes', 'WITH_TLS=no WITH_TLS_PSK=no', d)} \
33 ${@bb.utils.contains('PACKAGECONFIG', 'uuid', 'WITH_UUID=yes', 'WITH_UUID=no', d)}" 34 ${@bb.utils.contains('PACKAGECONFIG', 'uuid', 'WITH_UUID=yes', 'WITH_UUID=no', d)}"