Openembedded Core Discussions
 help / color / mirror / Atom feed
From: "Peter Kjellerstedt" <peter.kjellerstedt@axis.com>
To: Alexander Kanavin <alex.kanavin@gmail.com>
Cc: "openembedded-core@lists.openembedded.org"
	<openembedded-core@lists.openembedded.org>
Subject: Re: [OE-core] [PATCH 1/2] apr-util: make gdbm optional
Date: Sat, 20 Jun 2020 14:03:19 +0000	[thread overview]
Message-ID: <2bc56eb8b72e4aeb8da13c2dc2cfc4b2@XBOX03.axis.com> (raw)
In-Reply-To: <CANNYZj_z2tOZivRx4bmC_FsVRTu9jnBeo021qKXJPVq9rrK_9g@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 4447 bytes --]

Hmm, ok. How about a common without_gpl3.inc file? It could serve as a place to gather/document these PACKAGECONFIGs and other setting that need to be enabled to build without GPL-3.0. That way you are not forced in the same way as a distro feature would be, but at the same time it is easy for anyone who wants to disable GPL-3.0 for their build to find all the setting they need to tweak.

//Peter

From: Alexander Kanavin <alex.kanavin@gmail.com>
Sent: den 20 juni 2020 14:52
To: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
Cc: openembedded-core@lists.openembedded.org
Subject: Re: [OE-core] [PATCH 1/2] apr-util: make gdbm optional

In our environment gpl3 is not banned across the distro but rather banned only in the product image, with a targeted set of recipe tweaks aimed to allow that image to build. Non-product images are still permitted to contain gpl3 items. Since everyone has a different set of what goes into their product image, and what doesn't, and there are inevitably various 3rd party layers in the mix, I do not think a distro setting would make much sense.

Alex

On Sat, 20 Jun 2020 at 13:30, Peter Kjellerstedt <peter.kjellerstedt@axis.com<mailto:peter.kjellerstedt@axis.com>> wrote:
> -----Original Message-----
> From: openembedded-core@lists.openembedded.org<mailto:openembedded-core@lists.openembedded.org> <openembedded-
> core@lists.openembedded.org<mailto:core@lists.openembedded.org>> On Behalf Of Alexander Kanavin
> Sent: den 17 juni 2020 12:16
> To: openembedded-core@lists.openembedded.org<mailto:openembedded-core@lists.openembedded.org>
> Cc: Alexander Kanavin <alex.kanavin@gmail.com<mailto:alex.kanavin@gmail.com>>
> Subject: [OE-core] [PATCH 1/2] apr-util: make gdbm optional
>
> This helps with gpl3-free builds.
>
> Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com<mailto:alex.kanavin@gmail.com>>
> ---
>  meta/recipes-support/apr/apr-util_1.6.1.bb<http://apr-util_1.6.1.bb> | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/meta/recipes-support/apr/apr-util_1.6.1.bb<http://apr-util_1.6.1.bb> b/meta/recipes-support/apr/apr-util_1.6.1.bb<http://apr-util_1.6.1.bb>
> index 3896c924f0..0dd8f025e8 100644
> --- a/meta/recipes-support/apr/apr-util_1.6.1.bb<http://apr-util_1.6.1.bb>
> +++ b/meta/recipes-support/apr/apr-util_1.6.1.bb<http://apr-util_1.6.1.bb>
> @@ -1,7 +1,7 @@
>  SUMMARY = "Apache Portable Runtime (APR) companion library"
>  HOMEPAGE = "http://apr.apache.org/"
>  SECTION = "libs"
> -DEPENDS = "apr expat gdbm"
> +DEPENDS = "apr expat"
>
>  BBCLASSEXTEND = "native nativesdk"
>
> @@ -23,7 +23,6 @@ EXTRA_OECONF = "--with-apr=${STAGING_BINDIR_CROSS}/apr-1-config \
>               --without-odbc \
>               --without-pgsql \
>               --with-dbm=gdbm \
> -             --with-gdbm=${STAGING_DIR_HOST}${prefix} \
>               --without-sqlite2 \
>               --with-expat=${STAGING_DIR_HOST}${prefix}"
>
> @@ -66,10 +65,11 @@ do_install_append_class-target() {
>              -e 's,APU_BUILD_DIR=.*,APR_BUILD_DIR=,g' ${D}${bindir}/apu-1-config
>  }
>
> -PACKAGECONFIG ??= "crypto"
> +PACKAGECONFIG ??= "crypto gdbm"

Since I assume this is not the only place where it is needed to disable a
feature to achieve a GPL-3.0 free build, maybe we should introduce a distro
feature to control them? E.g.:

PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'allow-gpl3', 'gdbm', '', d)} \
                   crypto<mailto:$%7b@bb.utils.contains('DISTRO_FEATURES',%20'allow-gpl3',%20'gdbm',%20'',%20d)%7d%20\%0b %20 %20 %20 %20 %20 %20 %20 %20 %20 crypto>"

This would make it a lot easier for anyone who wants to disable the use of
GPL-3.0 code as they would not have to go searching through the recipes for
these kind of features to disable.

>  PACKAGECONFIG[ldap] = "--with-ldap,--without-ldap,openldap"
>  PACKAGECONFIG[crypto] = "--with-openssl=${STAGING_DIR_HOST}${prefix} --with-crypto,--without-crypto,openssl"
>  PACKAGECONFIG[sqlite3] = "--with-sqlite3=${STAGING_DIR_HOST}${prefix},--without-sqlite3,sqlite3"
> +PACKAGECONFIG[gdbm] = "--with-gdbm=${STAGING_DIR_HOST}${prefix},--without-gdbm,gdbm"
>
>  #files ${libdir}/apr-util-1/*.so are not symlinks but loadable modules thus they are packaged in ${PN}
>  FILES_${PN}     += "${libdir}/apr-util-1/apr*${SOLIBS} ${libdir}/apr-util-1/apr*${SOLIBSDEV}"
> --
> 2.27.0

//Peter

[-- Attachment #2: Type: text/html, Size: 9151 bytes --]

  reply	other threads:[~2020-06-20 14:03 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-17 10:15 [PATCH 1/2] apr-util: make gdbm optional Alexander Kanavin
2020-06-17 10:15 ` [PATCH 2/2] gobject-introspection: add a patch to fix a build race Alexander Kanavin
2020-06-20 11:30 ` [OE-core] [PATCH 1/2] apr-util: make gdbm optional Peter Kjellerstedt
2020-06-20 12:51   ` Alexander Kanavin
2020-06-20 14:03     ` Peter Kjellerstedt [this message]
2020-06-20 16:11       ` Alexander Kanavin

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=2bc56eb8b72e4aeb8da13c2dc2cfc4b2@XBOX03.axis.com \
    --to=peter.kjellerstedt@axis.com \
    --cc=alex.kanavin@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox