Hi Martin and Ross,

My original intention was to only condition the dependency on 
gobject-introspection but the reviewers were convinced the -native packages 
should be handled the same, see 
https://lists.openembedded.org/g/openembedded-core/message/175475 . That 
triggered a set of patches like 
https://lists.openembedded.org/g/openembedded-core/message/179620 . The result 
is passing the builds but honestly I'm not surprised about side-effects, sorry 
for that.

The key question is whether the problematic packages have intrinsic dependency 
on g-i-native, which can (and should) be fixed by adding the package in DEPENDS 
directly, or g-i-native is always needed as Ross says, which would imply 
g-i-native should not be conditioned by GI_DATA_ENABLED in the class.

I'm not an expert on g-i so I didn't have strong arguments but feel free to 
convince Alex that g-i-native should be always in DEPENDS.

Petr

________________________________________
From: Ross Burton <ross.bur...@arm.com>
Sent: Monday, May 15, 2023 3:58 PM
To: martin.ja...@gmail.com
Cc: Petr Kubizňák - 2N; openembedded-core@lists.openembedded.org
Subject: Re: [OE-core][PATCH v5 1/6] gobject-introspection: reduce dependencies

On 15 May 2023, at 12:40, Martin Jansa via lists.openembedded.org 
<Martin.Jansa=gmail....@lists.openembedded.org> wrote:
>  do_configure:prepend:class-target () {
> -    # introspection.m4 pre-packaged with upstream tarballs does not yet
> -    # have our fixes
> -    mkdir -p ${S}/m4
> -    cp ${STAGING_DIR_TARGET}/${datadir}/aclocal/introspection.m4 ${S}/m4
> +    if [ "${@bb.utils.contains('GI_DATA_ENABLED', 'True', '1', '0', d)}" = 
> "1" ] ; then
> +        # introspection.m4 pre-packaged with upstream tarballs does not yet
> +        # have our fixes
> +        mkdir -p ${S}/m4
> +        cp ${STAGING_DIR_TARGET}/${datadir}/aclocal/introspection.m4 ${S}/m4
> +    fi
>
> Was this extra .m4 file causing issues in builds without 
> gobject-introspection-data in DISTRO_FEATURES?
>
> I've noticed some maybe unexpected side-effects from this change, see:
> libblockdev: 
> https://lists.openembedded.org/g/openembedded-devel/message/102599
> glade: https://lists.openembedded.org/g/openembedded-devel/message/102601

That would be from:

-DEPENDS:append:class-target = " gobject-introspection 
gobject-introspection-native qemu-native"
+DEPENDS:append:class-target = " ${@bb.utils.contains('GI_DATA_ENABLED', 
'True', 'gobject-introspection gobject-introspection-native qemu-native', '', 
d)}”

As the comment below explains:

# Even though introspection is disabled on -native, gobject-introspection 
package is still
# needed for m4 macros.

g-i-native will *always* be needed as a build dependency, because packages 
built from git may not have any m4 macros in.

Ross
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#181263): 
https://lists.openembedded.org/g/openembedded-core/message/181263
Mute This Topic: https://lists.openembedded.org/mt/98032505/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to