mirror of
https://github.com/motioneye-project/motioneyeos.git
synced 2025-07-30 14:46:31 +00:00
package/dvb-app: handle static/shared only build
Also remove tests since they require static libraries. Signed-off-by: Romain Naour <romain.naour@openwide.fr> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
This commit is contained in:
parent
2b266815cb
commit
129496891d
44
package/dvb-apps/0003-handle-static-shared-only-build.patch
Normal file
44
package/dvb-apps/0003-handle-static-shared-only-build.patch
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
From a826c7c722db40bfedf00e51ce38411550ae8216 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Romain Naour <romain.naour@openwide.fr>
|
||||||
|
Date: Thu, 25 Dec 2014 19:22:16 +0100
|
||||||
|
Subject: [PATCH] Make.rules: Handle static/shared only build
|
||||||
|
|
||||||
|
Do not build .a library when enable_static is set to "no"
|
||||||
|
Do not build .so library when enable_shared is set to "no"
|
||||||
|
|
||||||
|
Signed-off-by: Romain Naour <romain.naour@openwide.fr>
|
||||||
|
---
|
||||||
|
Make.rules | 10 ++++++++--
|
||||||
|
1 file changed, 8 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/Make.rules b/Make.rules
|
||||||
|
index 3410d7b..d274e16 100644
|
||||||
|
--- a/Make.rules
|
||||||
|
+++ b/Make.rules
|
||||||
|
@@ -9,7 +9,13 @@ ifneq ($(lib_name),)
|
||||||
|
CFLAGS_LIB ?= -fPIC
|
||||||
|
CFLAGS += $(CFLAGS_LIB)
|
||||||
|
|
||||||
|
-libraries = $(lib_name).so $(lib_name).a
|
||||||
|
+ifneq ($(enable_static),no)
|
||||||
|
+libraries += $(lib_name).a
|
||||||
|
+endif
|
||||||
|
+
|
||||||
|
+ifneq ($(enable_shared),no)
|
||||||
|
+libraries += $(lib_name).so
|
||||||
|
+endif
|
||||||
|
|
||||||
|
.PHONY: library
|
||||||
|
|
||||||
|
@@ -23,7 +29,7 @@ prerequisites = $(subst .o,.d,$(objects)) $(addsuffix .d,$(binaries))
|
||||||
|
|
||||||
|
.PHONY: clean install
|
||||||
|
|
||||||
|
-ifeq ($(static),1)
|
||||||
|
+ifneq ($(enable_static),no)
|
||||||
|
LDFLAGS += -static
|
||||||
|
endif
|
||||||
|
|
||||||
|
--
|
||||||
|
1.9.3
|
||||||
|
|
@ -1,20 +0,0 @@
|
|||||||
Make.rules: don't build .so libraries when static=1
|
|
||||||
|
|
||||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
|
||||||
|
|
||||||
Index: b/Make.rules
|
|
||||||
===================================================================
|
|
||||||
--- a/Make.rules
|
|
||||||
+++ b/Make.rules
|
|
||||||
@@ -9,7 +9,11 @@
|
|
||||||
CFLAGS_LIB ?= -fPIC
|
|
||||||
CFLAGS += $(CFLAGS_LIB)
|
|
||||||
|
|
||||||
+ifeq ($(static),1)
|
|
||||||
+libraries = $(lib_name).a
|
|
||||||
+else
|
|
||||||
libraries = $(lib_name).so $(lib_name).a
|
|
||||||
+endif
|
|
||||||
|
|
||||||
.PHONY: library
|
|
||||||
|
|
27
package/dvb-apps/0004-Makefile-remove-test.patch
Normal file
27
package/dvb-apps/0004-Makefile-remove-test.patch
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
From c578772d6abc5fdf3ec83f632c371373e5baf9f1 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Romain Naour <romain.naour@openwide.fr>
|
||||||
|
Date: Fri, 26 Dec 2014 01:04:58 +0100
|
||||||
|
Subject: [PATCH] Makefile: remove test
|
||||||
|
|
||||||
|
Tests needs static libraries, remove them for shared only build.
|
||||||
|
|
||||||
|
Signed-off-by: Romain Naour <romain.naour@openwide.fr>
|
||||||
|
---
|
||||||
|
Makefile | 1 -
|
||||||
|
1 file changed, 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index 65a2273..105c460 100644
|
||||||
|
--- a/Makefile
|
||||||
|
+++ b/Makefile
|
||||||
|
@@ -10,7 +10,6 @@ DVB_API_MINOR := $(word 3, $(shell grep -m1 "DVB_API_VERSION_MINOR" $(VERSION_FI
|
||||||
|
|
||||||
|
all clean install:
|
||||||
|
$(MAKE) -C lib $@
|
||||||
|
- $(MAKE) -C test $@
|
||||||
|
$(MAKE) -C util $@
|
||||||
|
|
||||||
|
update:
|
||||||
|
--
|
||||||
|
1.9.3
|
||||||
|
|
@ -16,7 +16,9 @@ DVB_APPS_LDLIBS += -liconv
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(BR2_STATIC_LIBS),y)
|
ifeq ($(BR2_STATIC_LIBS),y)
|
||||||
DVB_APPS_MAKE_OPTS += static=1
|
DVB_APPS_MAKE_OPTS += enable_shared=no
|
||||||
|
else ifeq ($(BR2_SHARED_LIBS),y)
|
||||||
|
DVB_APPS_MAKE_OPTS += enable_static=no
|
||||||
endif
|
endif
|
||||||
|
|
||||||
DVB_APPS_INSTALL_STAGING = YES
|
DVB_APPS_INSTALL_STAGING = YES
|
||||||
|
Loading…
x
Reference in New Issue
Block a user