Re: [OE-core] [PATCH] dnf: Enable nativesdk

2019-04-12 Thread Alexander Kanavin
On Fri, 12 Apr 2019 at 10:57, Zheng, Ruoqin  wrote:
> > > echo 'export OECORE_DISTRO_VERSION="${DISTRO_VERSION}"' >>
> > > $script
> > > +   echo 'export MACHINE_ARCH=${MACHINE_ARCH}' >> $script
> > > Please explain why this change in the commit.
>
> Dnf is based on rpm and rpm need to read the arch info, but $script did not 
> provide it. So I added it.

Please make a separate commit for this then.

> > > Do not copy-paste large chunks like this please. Assign the
> > > dependencies to a variable, and use it where needed.
>
> If so, how about this way?
>
> BBCLASSEXTEND = "native nativesdk"
>
> RDEPENDS_${PN} += " \
>python3-core \
>..
>"
>
> RDEPENDS_${PN}_class-native = ""

Yes, this should work. There is an issue with class-native RDEPENDS,
where you can put recipe names in it, but not package names (because
there are no packages created for -native). I wrote about it here:
http://lists.openembedded.org/pipermail/openembedded-core/2019-March/280618.html

Alex
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] dnf: Enable nativesdk

2019-04-12 Thread Zheng, Ruoqin
Hi Alex:

> > echo 'export OECORE_DISTRO_VERSION="${DISTRO_VERSION}"' >> 
> > $script
> > +   echo 'export MACHINE_ARCH=${MACHINE_ARCH}' >> $script
> > Please explain why this change in the commit.

Dnf is based on rpm and rpm need to read the arch info, but $script did not 
provide it. So I added it.

> > Do not copy-paste large chunks like this please. Assign the 
> > dependencies to a variable, and use it where needed.

If so, how about this way?

BBCLASSEXTEND = "native nativesdk"

RDEPENDS_${PN} += " \
   python3-core \
   ..
   "

RDEPENDS_${PN}_class-native = ""

--
Zheng Ruoqin
Nanjing Fujitsu Nanda Software Tech. Co., Ltd.(FNST)
ADDR.: No.6 Wenzhu Road, Software Avenue,
   Nanjing, 210012, China
MAIL : zhengrq.f...@cn.fujistu.com


> -Original Message-
> From: Alexander Kanavin [mailto:alex.kana...@gmail.com]
> Sent: Thursday, April 11, 2019 7:19 PM
> To: Zheng, Ruoqin/郑 若钦 
> Cc: OE-core 
> Subject: Re: [OE-core] [PATCH] dnf: Enable nativesdk
> 
> On Thu, 11 Apr 2019 at 08:13, Zheng Ruoqin 
> wrote:
> 
> > --- a/meta/classes/toolchain-scripts.bbclass
> > +++ b/meta/classes/toolchain-scripts.bbclass
> > @@ -101,6 +101,7 @@ toolchain_shared_env_script () {
> > echo 'export CPPFLAGS="${TARGET_CPPFLAGS}"' >> $script
> > echo 'export KCFLAGS="--sysroot=$SDKTARGETSYSROOT"' >> $script
> > echo 'export OECORE_DISTRO_VERSION="${DISTRO_VERSION}"' >>
> > $script
> > +   echo 'export MACHINE_ARCH=${MACHINE_ARCH}' >> $script
> 
> Please explain why this change in the commit.
> 
> > +RDEPENDS_${PN}_class-nativesdk += " \
> > +  python3-core \
> > +  python3-codecs \
> > +  python3-netclient \
> > +  python3-email \
> > +  python3-threading \
> > +  python3-distutils \
> > +  python3-logging \
> > +  python3-fcntl \
> > +  librepo \
> > +  python3-shell \
> > +  libcomps \
> > +  libdnf \
> > +  python3-sqlite3 \
> > +  python3-compression \
> > +  python3-rpm \
> > +  python3-iniparse \
> > +  python3-json \
> > +  python3-curses \
> > +  python3-misc \
> > +  python3-gpg \
> > +  "
> > +
> >  RRECOMMENDS_${PN}_class-target += "gnupg"
> 
> Do not copy-paste large chunks like this please. Assign the dependencies to a
> variable, and use it where needed.
> 
> Alex
> 



-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] dnf: Enable nativesdk

2019-04-11 Thread richard . purdie
On Thu, 2019-04-11 at 14:16 +0200, Alexander Kanavin wrote:
> Presumably to be able to put dnf into SDKs?

nativesdk-dnf would depend on nativesdk-python3-core, not python3-core
though?

nativesdk-dnf doesn't run target packages?

Cheers,

Richard

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] dnf: Enable nativesdk

2019-04-11 Thread Alexander Kanavin
Presumably to be able to put dnf into SDKs?

Alex

On Thu, 11 Apr 2019 at 14:05, Richard Purdie
 wrote:
>
> On Thu, 2019-04-11 at 13:19 +0200, Alexander Kanavin wrote:
> > On Thu, 11 Apr 2019 at 08:13, Zheng Ruoqin <
> > zhengrq.f...@cn.fujitsu.com> wrote:
> >
> > > +RDEPENDS_${PN}_class-nativesdk += " \
> > > +  python3-core \
> > > +  python3-codecs \
> > > +  python3-netclient \
> > > +  python3-email \
> > > +  python3-threading \
> > > +  python3-distutils \
> > > +  python3-logging \
> > > +  python3-fcntl \
> > > +  librepo \
> > > +  python3-shell \
> > > +  libcomps \
> > > +  libdnf \
> > > +  python3-sqlite3 \
> > > +  python3-compression \
> > > +  python3-rpm \
> > > +  python3-iniparse \
> > > +  python3-json \
> > > +  python3-curses \
> > > +  python3-misc \
> > > +  python3-gpg \
> > > +  "
> > > +
> > >  RRECOMMENDS_${PN}_class-target += "gnupg"
> >
> > Do not copy-paste large chunks like this please. Assign the
> > dependencies to a variable, and use it where needed.
>
> Its worse than that, those are target dependencies, why would nativesdk
> need them?
>
> Cheers,
>
> Richard
>
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] dnf: Enable nativesdk

2019-04-11 Thread Richard Purdie
On Thu, 2019-04-11 at 13:19 +0200, Alexander Kanavin wrote:
> On Thu, 11 Apr 2019 at 08:13, Zheng Ruoqin <
> zhengrq.f...@cn.fujitsu.com> wrote:
> 
> > +RDEPENDS_${PN}_class-nativesdk += " \
> > +  python3-core \
> > +  python3-codecs \
> > +  python3-netclient \
> > +  python3-email \
> > +  python3-threading \
> > +  python3-distutils \
> > +  python3-logging \
> > +  python3-fcntl \
> > +  librepo \
> > +  python3-shell \
> > +  libcomps \
> > +  libdnf \
> > +  python3-sqlite3 \
> > +  python3-compression \
> > +  python3-rpm \
> > +  python3-iniparse \
> > +  python3-json \
> > +  python3-curses \
> > +  python3-misc \
> > +  python3-gpg \
> > +  "
> > +
> >  RRECOMMENDS_${PN}_class-target += "gnupg"
> 
> Do not copy-paste large chunks like this please. Assign the
> dependencies to a variable, and use it where needed.

Its worse than that, those are target dependencies, why would nativesdk
need them?

Cheers,

Richard

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] dnf: Enable nativesdk

2019-04-11 Thread Alexander Kanavin
On Thu, 11 Apr 2019 at 08:13, Zheng Ruoqin  wrote:

> --- a/meta/classes/toolchain-scripts.bbclass
> +++ b/meta/classes/toolchain-scripts.bbclass
> @@ -101,6 +101,7 @@ toolchain_shared_env_script () {
> echo 'export CPPFLAGS="${TARGET_CPPFLAGS}"' >> $script
> echo 'export KCFLAGS="--sysroot=$SDKTARGETSYSROOT"' >> $script
> echo 'export OECORE_DISTRO_VERSION="${DISTRO_VERSION}"' >> $script
> +   echo 'export MACHINE_ARCH=${MACHINE_ARCH}' >> $script

Please explain why this change in the commit.

> +RDEPENDS_${PN}_class-nativesdk += " \
> +  python3-core \
> +  python3-codecs \
> +  python3-netclient \
> +  python3-email \
> +  python3-threading \
> +  python3-distutils \
> +  python3-logging \
> +  python3-fcntl \
> +  librepo \
> +  python3-shell \
> +  libcomps \
> +  libdnf \
> +  python3-sqlite3 \
> +  python3-compression \
> +  python3-rpm \
> +  python3-iniparse \
> +  python3-json \
> +  python3-curses \
> +  python3-misc \
> +  python3-gpg \
> +  "
> +
>  RRECOMMENDS_${PN}_class-target += "gnupg"

Do not copy-paste large chunks like this please. Assign the
dependencies to a variable, and use it where needed.

Alex
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core