Skip to contentSkip to conversation

libomxil: Fix up commercial license flag

PATCH In review Joshua Watt 2 participants 3 messages Feb 12, 2021 – Feb 16, 2021

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 libomxil: Fix up commercial license flag

The commercial license flag on libomxil is set because it may include the Adaptive Multi-Rate audio codec (AMR) using FFmepg, which is patent encumbered.

It turns out this component is disabled by default in the recipe; add a PACKAGECONFIG to enable it and trigger the "commercial" LICENSE_FLAGS on it. This make the default build configuration clean unless a user specifically asks for AMR support, and prevents them from marking the recipe with the "commerical" flag unnecessarily which could hide potential problems later on.

---
 meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb +5 -1
index 2061c280e4..82cdaf54c7 100644
@@ -4,7 +4,7 @@ DESCRIPTION = "Bellagio is an opensource implementation of the Khronos OpenMAX \
 HOMEPAGE = "http://omxil.sourceforge.net/"
 
 LICENSE = "LGPLv2.1+"
-LICENSE_FLAGS = "commercial"
+LICENSE_FLAGS = "${@bb.utils.contains('PACKAGECONFIG', 'amr', 'commercial', '', d)}"
 LIC_FILES_CHKSUM = "file://COPYING;md5=ae6f0f4dbc7ac193b50f323a6ae191cb \
                     file://src/omxcore.h;beginline=1;endline=27;md5=806b1e5566c06486fe8e42b461e03a90"
 
@@ -28,6 +28,10 @@ PROVIDES += "virtual/libomxil"
 
 CFLAGS += "-fcommon"
 
+PACKAGECONFIG ??= ""
+
+PACKAGECONFIG[amr] = "--enable-amr,,"
+
 #
 # The .so files under ${libdir}/bellagio are not intended to be versioned and symlinked.
 # Make sure they get packaged in the main package.
Signature · 1 line
2.30.0
#1 lore raw

Can this please be backported to gatesgarth?

Quoted 40 lines · Joshua Watt

The commercial license flag on libomxil is set because it may include the Adaptive Multi-Rate audio codec (AMR) using FFmepg, which is patent encumbered.

It turns out this component is disabled by default in the recipe; add a PACKAGECONFIG to enable it and trigger the "commercial" LICENSE_FLAGS on it. This make the default build configuration clean unless a user specifically asks for AMR support, and prevents them from marking the recipe with the "commerical" flag unnecessarily which could hide potential problems later on.

---
  meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb | 6 +++++-
  1 file changed, 5 insertions(+), 1 deletion(-)
meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb +5 -1
index 2061c280e4..82cdaf54c7 100644
@@ -4,7 +4,7 @@ DESCRIPTION = "Bellagio is an opensource implementation of the Khronos OpenMAX \
  HOMEPAGE = "http://omxil.sourceforge.net/"
 
  LICENSE = "LGPLv2.1+"
-LICENSE_FLAGS = "commercial"
+LICENSE_FLAGS = "${@bb.utils.contains('PACKAGECONFIG', 'amr', 'commercial', '', d)}"
  LIC_FILES_CHKSUM = "file://COPYING;md5=ae6f0f4dbc7ac193b50f323a6ae191cb \
                      file://src/omxcore.h;beginline=1;endline=27;md5=806b1e5566c06486fe8e42b461e03a90"
 
@@ -28,6 +28,10 @@ PROVIDES += "virtual/libomxil"
 
  CFLAGS += "-fcommon"
 
+PACKAGECONFIG ??= ""
+
+PACKAGECONFIG[amr] = "--enable-amr,,"
+
  #
  # The .so files under ${libdir}/bellagio are not intended to be versioned and symlinked.
  # Make sure they get packaged in the main package.
#2 lore raw

Yes, I have picked this and the weston change.

Thanks,

Anuj

Quoted 55 lines · Joshua Watt

Can this please be backported to gatesgarth?

Quoted 52 lines · Joshua Watt

The commercial license flag on libomxil is set because it may include
the Adaptive Multi-Rate audio codec (AMR) using FFmepg, which is patent
encumbered.

It turns out this component is disabled by default in the recipe; add a
PACKAGECONFIG to enable it and trigger the "commercial" LICENSE_FLAGS on
it. This make the default build configuration clean unless a user specifically asks for AMR support, and prevents them from marking the
recipe with the "commerical" flag unnecessarily which could hide potential problems later on.

---
  meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb | 6 +++++-

  1 file changed, 5 insertions(+), 1 deletion(-)
meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb +0 -0
index 2061c280e4..82cdaf54c7 100644
@@ -4,7 +4,7 @@ DESCRIPTION = "Bellagio is an opensource
 implementation of the Khronos OpenMAX \

  HOMEPAGE = "http://omxil.sourceforge.net/"

  LICENSE = "LGPLv2.1+"

meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb +1 -1
-LICENSE_FLAGS = "commercial"
+LICENSE_FLAGS = "${@bb.utils.contains('PACKAGECONFIG', 'amr',

'commercial', '', d)}"
  LIC_FILES_CHKSUM = "file://COPYING;md5=ae6f0f4dbc7ac193b50f323a6ae191cb \
file://src/omxcore.h;beginline=1;endline=27;md5=806b1e5566c06486fe8e42b461e03a90 "

meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb +0 -0
@@ -28,6 +28,10 @@ PROVIDES += "virtual/libomxil"


  CFLAGS += "-fcommon"

meta/recipes-multimedia/libomxil/libomxil_0.9.3.bb +4 -0
+PACKAGECONFIG ??= ""
+
+PACKAGECONFIG[amr] = "--enable-amr,,"
+

  #
  # The .so files under ${libdir}/bellagio are not intended to be versioned and symlinked.
  # Make sure they get packaged in the main package.