diff options
author | Jose Quaresma <quaresma.jose@gmail.com> | 2022-03-07 22:12:48 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-03-08 09:44:28 +0000 |
commit | 3ec1f30ebba498566d4b266168e1faf182a38fb8 (patch) | |
tree | 8eb092d4d483b3abca225ce3d5f8c66040e75243 /meta | |
parent | bcd7e29a3b754a3e5cdc7f0db56b89d0c6369c8e (diff) | |
download | poky-3ec1f30ebba498566d4b266168e1faf182a38fb8.tar.gz |
gstreamer1.0-plugins-bad/ugly: use the GPL-2.0-or-later only when it is in use
Since all gstreamer modules uses LGPLv2.1 with exceptions
for some plugins in bad and ugly modules that has GPLv2+.
For the GPLv2+ this patch set this license only for each plugin
that is affected by by that, using the new GSTREAMER_GPL.
CC: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
(From OE-Core rev: 25ea8753e2d1dc4e1aa01b4800da532ca1aecec7)
Signed-off-by: Jose Quaresma <quaresma.jose@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
3 files changed, 29 insertions, 10 deletions
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.20.0.bb b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.20.0.bb index 44532222fa..1531b68de9 100644 --- a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.20.0.bb +++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_1.20.0.bb | |||
@@ -1,4 +1,5 @@ | |||
1 | require gstreamer1.0-plugins-common.inc | 1 | require gstreamer1.0-plugins-common.inc |
2 | require gstreamer1.0-plugins-license.inc | ||
2 | 3 | ||
3 | DESCRIPTION = "'Bad' GStreamer plugins and helper libraries " | 4 | DESCRIPTION = "'Bad' GStreamer plugins and helper libraries " |
4 | HOMEPAGE = "https://gstreamer.freedesktop.org/" | 5 | HOMEPAGE = "https://gstreamer.freedesktop.org/" |
@@ -44,6 +45,7 @@ PACKAGECONFIG[dc1394] = "-Ddc1394=enabled,-Ddc1394=disabled,libdc1394" | |||
44 | PACKAGECONFIG[directfb] = "-Ddirectfb=enabled,-Ddirectfb=disabled,directfb" | 45 | PACKAGECONFIG[directfb] = "-Ddirectfb=enabled,-Ddirectfb=disabled,directfb" |
45 | PACKAGECONFIG[dtls] = "-Ddtls=enabled,-Ddtls=disabled,openssl" | 46 | PACKAGECONFIG[dtls] = "-Ddtls=enabled,-Ddtls=disabled,openssl" |
46 | PACKAGECONFIG[faac] = "-Dfaac=enabled,-Dfaac=disabled,faac" | 47 | PACKAGECONFIG[faac] = "-Dfaac=enabled,-Dfaac=disabled,faac" |
48 | PACKAGECONFIG[faad] = "-Dfaad=enabled,-Dfaad=disabled,faad2" | ||
47 | PACKAGECONFIG[fluidsynth] = "-Dfluidsynth=enabled,-Dfluidsynth=disabled,fluidsynth" | 49 | PACKAGECONFIG[fluidsynth] = "-Dfluidsynth=enabled,-Dfluidsynth=disabled,fluidsynth" |
48 | PACKAGECONFIG[hls] = "-Dhls=enabled,-Dhls=disabled," | 50 | PACKAGECONFIG[hls] = "-Dhls=enabled,-Dhls=disabled," |
49 | # Pick atleast one crypto backend below when enabling hls | 51 | # Pick atleast one crypto backend below when enabling hls |
@@ -69,6 +71,7 @@ PACKAGECONFIG[openmpt] = "-Dopenmpt=enabled,-Dopenmpt=disabled,libopenmp | |||
69 | # the opus encoder/decoder elements are now in the -base package, | 71 | # the opus encoder/decoder elements are now in the -base package, |
70 | # but the opus parser remains in -bad | 72 | # but the opus parser remains in -bad |
71 | PACKAGECONFIG[opusparse] = "-Dopus=enabled,-Dopus=disabled,libopus" | 73 | PACKAGECONFIG[opusparse] = "-Dopus=enabled,-Dopus=disabled,libopus" |
74 | PACKAGECONFIG[resindvd] = "-Dresindvd=enabled,-Dresindvd=disabled,libdvdread libdvdnav" | ||
72 | PACKAGECONFIG[rsvg] = "-Drsvg=enabled,-Drsvg=disabled,librsvg" | 75 | PACKAGECONFIG[rsvg] = "-Drsvg=enabled,-Drsvg=disabled,librsvg" |
73 | PACKAGECONFIG[rtmp] = "-Drtmp=enabled,-Drtmp=disabled,rtmpdump" | 76 | PACKAGECONFIG[rtmp] = "-Drtmp=enabled,-Drtmp=disabled,rtmpdump" |
74 | PACKAGECONFIG[sbc] = "-Dsbc=enabled,-Dsbc=disabled,sbc" | 77 | PACKAGECONFIG[sbc] = "-Dsbc=enabled,-Dsbc=disabled,sbc" |
@@ -91,13 +94,10 @@ PACKAGECONFIG[webrtc] = "-Dwebrtc=enabled,-Dwebrtc=disabled,libnice" | |||
91 | PACKAGECONFIG[webrtcdsp] = "-Dwebrtcdsp=enabled,-Dwebrtcdsp=disabled,webrtc-audio-processing" | 94 | PACKAGECONFIG[webrtcdsp] = "-Dwebrtcdsp=enabled,-Dwebrtcdsp=disabled,webrtc-audio-processing" |
92 | PACKAGECONFIG[zbar] = "-Dzbar=enabled,-Dzbar=disabled,zbar" | 95 | PACKAGECONFIG[zbar] = "-Dzbar=enabled,-Dzbar=disabled,zbar" |
93 | PACKAGECONFIG[x11] = "-Dx11=enabled,-Dx11=disabled,libxcb libxkbcommon" | 96 | PACKAGECONFIG[x11] = "-Dx11=enabled,-Dx11=disabled,libxcb libxkbcommon" |
94 | |||
95 | # GPL - only built if gpl option is also enabled! | ||
96 | PACKAGECONFIG[gpl] = "-Dgpl=enabled,-Dgpl=disabled" | ||
97 | PACKAGECONFIG[faad] = "-Dfaad=enabled,-Dfaad=disabled,faad2" | ||
98 | PACKAGECONFIG[resindvd] = "-Dresindvd=enabled,-Dresindvd=disabled,libdvdread libdvdnav" | ||
99 | PACKAGECONFIG[x265] = "-Dx265=enabled,-Dx265=disabled,x265" | 97 | PACKAGECONFIG[x265] = "-Dx265=enabled,-Dx265=disabled,x265" |
100 | 98 | ||
99 | GSTREAMER_GPL = "${@bb.utils.filter('PACKAGECONFIG', 'faad resindvd x265', d)}" | ||
100 | |||
101 | EXTRA_OEMESON += " \ | 101 | EXTRA_OEMESON += " \ |
102 | -Ddoc=disabled \ | 102 | -Ddoc=disabled \ |
103 | -Daes=enabled \ | 103 | -Daes=enabled \ |
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-license.inc b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-license.inc new file mode 100644 index 0000000000..6638f13540 --- /dev/null +++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-license.inc | |||
@@ -0,0 +1,19 @@ | |||
1 | # This .inc file contains functionality for automatically setting | ||
2 | # the the license of all plugins according to the GSTREAMER_GPL. | ||
3 | |||
4 | PACKAGESPLITFUNCS:append = " set_gstreamer_license " | ||
5 | |||
6 | python set_gstreamer_license () { | ||
7 | import oe.utils | ||
8 | pn = d.getVar('PN') + '-' | ||
9 | gpl_plugins_names = [pn+plugin for plugin in d.getVar('GSTREAMER_GPL').split()] | ||
10 | for pkg in oe.utils.packages_filter_out_system(d): | ||
11 | if pkg in gpl_plugins_names: | ||
12 | d.setVar('LICENSE:' + pkg, 'GPL-2.0-or-later') | ||
13 | else: | ||
14 | d.setVar('LICENSE:' + pkg, 'LGPL-2.1-or-later') | ||
15 | } | ||
16 | |||
17 | EXTRA_OEMESON += " \ | ||
18 | ${@bb.utils.contains_any('PACKAGECONFIG', "${GSTREAMER_GPL}", '-Dgpl=enabled', '-Dgpl=disabled', d)} \ | ||
19 | " | ||
diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.20.0.bb b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.20.0.bb index 9b6f80aa89..3dae3d5a11 100644 --- a/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.20.0.bb +++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_1.20.0.bb | |||
@@ -1,4 +1,5 @@ | |||
1 | require gstreamer1.0-plugins-common.inc | 1 | require gstreamer1.0-plugins-common.inc |
2 | require gstreamer1.0-plugins-license.inc | ||
2 | 3 | ||
3 | DESCRIPTION = "'Ugly GStreamer plugins" | 4 | DESCRIPTION = "'Ugly GStreamer plugins" |
4 | HOMEPAGE = "https://gstreamer.freedesktop.org/" | 5 | HOMEPAGE = "https://gstreamer.freedesktop.org/" |
@@ -23,20 +24,19 @@ GST_PLUGIN_SET_HAS_EXAMPLES = "0" | |||
23 | 24 | ||
24 | PACKAGECONFIG ??= " \ | 25 | PACKAGECONFIG ??= " \ |
25 | ${GSTREAMER_ORC} \ | 26 | ${GSTREAMER_ORC} \ |
26 | gpl a52dec mpeg2dec \ | 27 | a52dec mpeg2dec \ |
27 | " | 28 | " |
28 | 29 | ||
29 | PACKAGECONFIG[amrnb] = "-Damrnb=enabled,-Damrnb=disabled,opencore-amr" | 30 | PACKAGECONFIG[amrnb] = "-Damrnb=enabled,-Damrnb=disabled,opencore-amr" |
30 | PACKAGECONFIG[amrwb] = "-Damrwbdec=enabled,-Damrwbdec=disabled,opencore-amr" | 31 | PACKAGECONFIG[amrwb] = "-Damrwbdec=enabled,-Damrwbdec=disabled,opencore-amr" |
31 | |||
32 | # GPL - only built if gpl option is also enabled! | ||
33 | PACKAGECONFIG[gpl] = "-Dgpl=enabled,-Dgpl=disabled" | ||
34 | PACKAGECONFIG[cdio] = "-Dcdio=enabled,-Dcdio=disabled,libcdio" | ||
35 | PACKAGECONFIG[a52dec] = "-Da52dec=enabled,-Da52dec=disabled,liba52" | 32 | PACKAGECONFIG[a52dec] = "-Da52dec=enabled,-Da52dec=disabled,liba52" |
33 | PACKAGECONFIG[cdio] = "-Dcdio=enabled,-Dcdio=disabled,libcdio" | ||
36 | PACKAGECONFIG[dvdread] = "-Ddvdread=enabled,-Ddvdread=disabled,libdvdread" | 34 | PACKAGECONFIG[dvdread] = "-Ddvdread=enabled,-Ddvdread=disabled,libdvdread" |
37 | PACKAGECONFIG[mpeg2dec] = "-Dmpeg2dec=enabled,-Dmpeg2dec=disabled,mpeg2dec" | 35 | PACKAGECONFIG[mpeg2dec] = "-Dmpeg2dec=enabled,-Dmpeg2dec=disabled,mpeg2dec" |
38 | PACKAGECONFIG[x264] = "-Dx264=enabled,-Dx264=disabled,x264" | 36 | PACKAGECONFIG[x264] = "-Dx264=enabled,-Dx264=disabled,x264" |
39 | 37 | ||
38 | GSTREAMER_GPL = "${@bb.utils.filter('PACKAGECONFIG', 'a52dec cdio dvdread mpeg2dec x264', d)}" | ||
39 | |||
40 | EXTRA_OEMESON += " \ | 40 | EXTRA_OEMESON += " \ |
41 | -Ddoc=disabled \ | 41 | -Ddoc=disabled \ |
42 | -Dsidplay=disabled \ | 42 | -Dsidplay=disabled \ |