All of lore.kernel.org
 help / color / mirror / Atom feed
From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/1] package/domoticz: fix build with RELRO
Date: Thu, 31 Oct 2019 11:23:06 +0100	[thread overview]
Message-ID: <20191031102306.15433-1-fontaine.fabrice@gmail.com> (raw)

Fixes:
 - http://autobuild.buildroot.org/results/5c1ca3083ad672401d1e050c6c3a07b8c33b851d

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 ...xt-Add-USE_PRECOMPILED_HEADER-option.patch | 35 +++++++++++++++++++
 package/domoticz/domoticz.mk                  |  3 ++
 2 files changed, 38 insertions(+)
 create mode 100644 package/domoticz/0003-CMakeLists.txt-Add-USE_PRECOMPILED_HEADER-option.patch

diff --git a/package/domoticz/0003-CMakeLists.txt-Add-USE_PRECOMPILED_HEADER-option.patch b/package/domoticz/0003-CMakeLists.txt-Add-USE_PRECOMPILED_HEADER-option.patch
new file mode 100644
index 0000000000..831e4816e1
--- /dev/null
+++ b/package/domoticz/0003-CMakeLists.txt-Add-USE_PRECOMPILED_HEADER-option.patch
@@ -0,0 +1,35 @@
+From e2dfb2ece19748ba99ec8199fc902c0c9daff325 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Wed, 30 Oct 2019 18:55:48 +0100
+Subject: [PATCH] CMakeLists.txt: Add USE_PRECOMPILED_HEADER option
+
+Add USE_PRECOMPILED_HEADER to allow the user to disable precompiled
+header feature. Thanks to this, domoticz will be able to be built with
+RELRO on buildroot
+
+Fixes:
+ - http://autobuild.buildroot.org/results/5c1ca3083ad672401d1e050c6c3a07b8c33b851d
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+[Retrieved from:
+https://github.com/domoticz/domoticz/commit/e2dfb2ece19748ba99ec8199fc902c0c9daff325]
+---
+ CMakeLists.txt | 5 ++++-
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index cb6150ce4c..bd48872214 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -744,7 +744,10 @@ else()
+   target_link_libraries(domoticz -lrt -lresolv ${EXECINFO_LIBRARIES})
+ ENDIF()
+ 
+-ADD_PRECOMPILED_HEADER(domoticz "main/stdafx.h")
++option(USE_PRECOMPILED_HEADER "Use precompiled header feature to speed up build time " YES)
++if(USE_PRECOMPILED_HEADER)
++  ADD_PRECOMPILED_HEADER(domoticz "main/stdafx.h")
++ENDIF(USE_PRECOMPILED_HEADER)
+ 
+ IF(CMAKE_COMPILER_IS_GNUCXX)
+   option(USE_STATIC_LIBSTDCXX "Build with static libgcc/libstdc++ libraries" YES)
diff --git a/package/domoticz/domoticz.mk b/package/domoticz/domoticz.mk
index c0568c61c6..d8ccfeee5a 100644
--- a/package/domoticz/domoticz.mk
+++ b/package/domoticz/domoticz.mk
@@ -31,6 +31,9 @@ DOMOTICZ_CONF_OPTS += \
 	-DUSE_BUILTIN_SQLITE=OFF \
 	-DUSE_BUILTIN_MQTT=OFF
 
+# Disable precompiled header feature to fix build with RELRO
+DOMOTICZ_CONF_OPTS += -DUSE_PRECOMPILED_HEADER=OFF
+
 ifeq ($(BR2_PACKAGE_LIBUSB),y)
 DOMOTICZ_DEPENDENCIES += libusb
 endif
-- 
2.23.0

             reply	other threads:[~2019-10-31 10:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-31 10:23 Fabrice Fontaine [this message]
2019-10-31 12:43 ` [Buildroot] [PATCH 1/1] package/domoticz: fix build with RELRO Thomas Petazzoni
2019-10-31 13:01   ` Fabrice Fontaine
2019-11-04 22:12     ` Thomas Petazzoni
2019-11-05 20:19       ` Matthew Weber
2019-11-06 13:07         ` Arnout Vandecappelle
2019-11-06 13:46           ` [Buildroot] [External] " Matthew Weber

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191031102306.15433-1-fontaine.fabrice@gmail.com \
    --to=fontaine.fabrice@gmail.com \
    --cc=buildroot@busybox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.