summaryrefslogtreecommitdiffstats
path: root/package/qextserialport
diff options
context:
space:
mode:
authorArnout Vandecappelle <arnout@mind.be>2016-11-20 23:13:29 +0100
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2016-11-21 22:48:09 +0100
commitf09b33a0abe964a137041f52afb111d351c9e5ff (patch)
tree048235cccc35a0f4bf3011c2728bd46c6f8022fd /package/qextserialport
parent8ad8e9917fd1ea37a4866ef00ce42fd029a72bae (diff)
downloadbuildroot-f09b33a0abe964a137041f52afb111d351c9e5ff.tar.gz
buildroot-f09b33a0abe964a137041f52afb111d351c9e5ff.zip
qextserialport: fix static build
By default, qextserialport will attempt to build a shared library. qesp_static has to be set in CONFIG to build static. Note that static+shared is not supported, in that case we just build shared. The install target commands also have to be gated in that case, because the *.so files don't exist. For completeness we both set QEXTSERIALPORT_INSTALL_STAGING to NO and don't define QEXTSERIALPORT_INSTALL_TARGET_CMDS for static builds, although one of them would be sufficient. Fixes: http://autobuild.buildroot.net/results/c9233ad71fd60d0e6a85731a8bd4e598bd84947a Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be> Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/qextserialport')
-rw-r--r--package/qextserialport/qextserialport.mk10
1 files changed, 9 insertions, 1 deletions
diff --git a/package/qextserialport/qextserialport.mk b/package/qextserialport/qextserialport.mk
index 15cb74cbd4..3641353a3f 100644
--- a/package/qextserialport/qextserialport.mk
+++ b/package/qextserialport/qextserialport.mk
@@ -10,6 +10,10 @@ QEXTSERIALPORT_LICENSE = MIT
QEXTSERIALPORT_LICENSE_FILES = LICENSE.md
QEXTSERIALPORT_INSTALL_STAGING = YES
+ifeq ($(BR2_STATIC_LIBS),y)
+QEXTSERIALPORT_CONF_OPTS += CONFIG+=qesp_static
+endif
+
ifeq ($(BR2_PACKAGE_QT),y)
QEXTSERIALPORT_DEPENDENCIES += qt
QEXTSERIALPORT_QMAKE = $(QT_QMAKE)
@@ -19,7 +23,7 @@ QEXTSERIALPORT_QMAKE = $(QT5_QMAKE)
endif
define QEXTSERIALPORT_CONFIGURE_CMDS
- cd $(@D); $(TARGET_MAKE_ENV) $(QEXTSERIALPORT_QMAKE)
+ cd $(@D); $(TARGET_MAKE_ENV) $(QEXTSERIALPORT_QMAKE) $(QEXTSERIALPORT_CONF_OPTS)
endef
define QEXTSERIALPORT_BUILD_CMDS
@@ -32,8 +36,12 @@ define QEXTSERIALPORT_INSTALL_STAGING_CMDS
cp $(@D)/qextserialport.pc $(STAGING_DIR)/usr/lib/pkgconfig/
endef
+ifeq ($(BR2_STATIC_LIBS),y)
+QEXTSERIALPORT_INSTALL_STAGING = NO
+else
define QEXTSERIALPORT_INSTALL_TARGET_CMDS
cp -a $(@D)/*.so.* $(TARGET_DIR)/usr/lib
endef
+endif
$(eval $(generic-package))
OpenPOWER on IntegriCloud