From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id 6501EE00D7F; Thu, 5 Oct 2017 10:51:44 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,HTML_MESSAGE, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, * medium trust * [64.235.150.234 listed in list.dnswl.org] * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * 0.0 HTML_MESSAGE BODY: HTML included in message Received: from 14pmail.ess.barracuda.com (14pmail.ess.barracuda.com [64.235.150.234]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id BA45BE00C78 for ; Thu, 5 Oct 2017 10:51:40 -0700 (PDT) Received: from SFAMAIL.SAKURAUS.LOCAL (mail.sakuraus.com [12.26.104.5]) by mx2.ess.sfj.cudaops.com (version=TLSv1.2 cipher=AES256-SHA256 bits=256 verify=NO); Thu, 05 Oct 2017 17:51:34 +0000 Received: from SFAMAIL.SAKURAUS.LOCAL (10.16.3.8) by SFAMAIL.SAKURAUS.LOCAL (10.16.3.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.669.32; Thu, 5 Oct 2017 10:51:32 -0700 Received: from SFAMAIL.SAKURAUS.LOCAL ([::1]) by SFAMAIL.SAKURAUS.LOCAL ([::1]) with mapi id 15.01.0669.032; Thu, 5 Oct 2017 10:51:32 -0700 From: Greg Wilson-Lindberg To: Paul Eggleton Thread-Topic: [yocto] Having trouble getting recipe to run in proper directory Thread-Index: AQHTPWxb0oRn/yAKOUO4B9H0W4aZLaLU9iAAgACRpBI= Date: Thu, 5 Oct 2017 17:51:32 +0000 Message-ID: <8c87603b0e564a00b7ef230b0e24b41d@sakuraus.com> References: <2376f96acc0f4c3db9c3b40a3cfc98f3@sakuraus.com>, <3688235.HQgvHeQ0bO@peggleto-mobl.ger.corp.intel.com> In-Reply-To: <3688235.HQgvHeQ0bO@peggleto-mobl.ger.corp.intel.com> Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.16.5.239] MIME-Version: 1.0 X-BESS-ID: 1507225893-298553-21844-13189-1 X-BESS-VER: 2017.12-r1709122024 X-BESS-Apparent-Source-IP: 12.26.104.5 X-BESS-Outbound-Spam-Score: 0.00 X-BESS-Outbound-Spam-Report: Code version 3.2, rules version 3.2.2.185720 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------- 0.00 HTML_MESSAGE BODY: HTML included in message 0.00 BSF_BESS_OUTBOUND META: BESS Outbound X-BESS-Outbound-Spam-Status: SCORE=0.00 using account:ESS29408 scores of KILL_LEVEL=7.0 tests=HTML_MESSAGE, BSF_BESS_OUTBOUND X-BESS-BRTS-Status: 1 Cc: "yocto@yoctoproject.org" Subject: Re: Having trouble getting recipe to run in proper directory X-BeenThere: yocto@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Discussion of all things Yocto Project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Oct 2017 17:51:44 -0000 Content-Language: en-US Content-Type: multipart/alternative; boundary="_000_8c87603b0e564a00b7ef230b0e24b41dsakurauscom_" --_000_8c87603b0e564a00b7ef230b0e24b41dsakurauscom_ Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: quoted-printable Hi Paul, I changed the name of the recipe to 'canfestival_3-asc.bb' and removed the = PN, PV, & PR defines and that seems to have gotten bitbake to extract and e= xecute into the same directory. I'm now getting an error from the 'configure' scripe: NOTE: Running ../canfestival-3-asc/configure --build=3Dx86_64-linux --ho= st=3Darm-poky-linux-gnueabi --target=3Darm-poky-linux-gnueabi --prefix= =3D/usr --exec_prefix=3D/usr --bindir=3D/usr/bin --sbindir=3D/usr/sbi= n --libexecdir=3D/usr/libexec --datadir=3D/usr/share --sysconfdir=3D/= etc --sharedstatedir=3D/com --localstatedir=3D/var --libdir=3D/usr/li= b --includedir=3D/usr/include --oldincludedir=3D/usr/include --infodi= r=3D/usr/share/info --mandir=3D/usr/share/man --disable-silent-rules = --disable-dependency-tracking --with-libtool-sysroot=3D/home/gwilson/Qt-5= .9/Yocto-build-RPi3/build-raspberrypi3/tmp/sysroots/raspberrypi3 =96can=3Ds= ocket =96timers=3Dunix =96SDO_MAX_SIMULTANEOUS_TRANSFERS=3D25 = =96SDO_MAX_LENGTH_TRANSFER=3D4096 =96MAX_NB_TIMER=3D128 =96SDO_TIMEOUT_M= S=3D1000 --disable-static ERROR: configure failed Unknown argument --build=3Dx86_64-linux so bitbake is including an option that the configure script doesn't underst= and. Is there a way to delete that option? Thanks so much for you help, Greg ________________________________ From: Paul Eggleton Sent: Wednesday, October 4, 2017 7:01:10 PM To: Greg Wilson-Lindberg Cc: yocto@yoctoproject.org Subject: Re: [yocto] Having trouble getting recipe to run in proper directo= ry Hi Greg, On Thursday, 5 October 2017 1:16:15 PM NZDT Greg Wilson-Lindberg wrote: > I'm trying to create a new recipe for a package that has a version and no= n-numeric rev > in its name (canfestival-3-asc). I've gotten bitbake to unpack the packag= e into a tree > that looks ok, but it keeps trying to run the compile at least in the wro= ng directory. > Here is the recipe: > > > SUMMARY =3D "Independent CANOpen=AE stack" > DESCRIPTION =3D "CanFestival focuses on providing an ANSI-C platform inde= pendent \ > CANOpen=AE stack that can be built as master or slave node= s on PCs, \ > Real-time IPCs, and Microcontrollers." > > HOMEPAGE =3D "http://www.canfestival.org/" > > SRCREV =3D "895:8973dd8be7e8" > > SRC_URI =3D "hg://bitbucket.org/Mongo;protocol=3Dhttps;module=3Dcanfestiv= al-3-asc" > SRC_URI[md5sum] =3D "" > SRC_URI[sha256sum] =3D "" > > PN =3D "canfestival" > PV =3D '3' > PR =3D 'asc' > > LICENSE =3D "LGPL-2" > LIC_FILES_CHKSUM =3D "file://COPYING;md5=3D \ > file://LICENCE;md5=3D" > > inherit autotools > > # Specify any options you want to pass to the configure script using EXTR= A_OECONF: > EXTRA_OECONF =3D "-can=3Dsocket -timers=3Dunix -SDO_MAX_SIMULTANEOUS_TRAN= SFERS=3D25 \ > -SDO_MAX_LENGTH_TRANSFER=3D4096 -MAX_NB_TIMER=3D128 -SDO_= TIMEOUT_MS=3D1000" > > PROVIDES =3D "canfestival" > > The directory structure that bitbake builds is: > > > canfestival > > 3-asc > > build > > canfestival-3 # directory that bitbake is tr= ying to compile in > > canfestival-3-asc # directory that code was extr= acted to > > temp > > > I'm not getting any errors from the configure task, but the log file look= s like > it is trying to run from the canfestival-3 directory, not the canfestival= -3-asc. What > can I do to the recipe to get the build to run in the canfestival-3-asc d= irectory? > Or, i guess, get bitbake to unpack the source into the canfestival-3, or = a > different directory that it will actually run the tasks in. So firstly the directory where the build system should expect to find the source after do_unpack is specified by the S variable, whose default is "${WORKDIR}/${BP}" where BP defaults to "${BPN}-${PV}" and BPN will be t= he same as PN in this case. However, you're setting the "asc" part in PR - typically PR is left under the control of the build system and thus your PV would typically be set to "3-asc" in which case S would default to the righ= t value i.e. "canfestival-3-asc" (but if it didn't, you would just set S to fix it). To summarise, set PV =3D "3-asc" (or alternatively have it picked up from t= he file name, i.e. name it canfestival_3-asc.bb) and it should work as you expect. A couple of other notes: * For LICENSE, LGPL-2 isn't a standard value - LGPLv2, LGPLv2.0, LGPLv2.1, LGPL-2.0, or LGPL-2.1 (with or without + at the end) would be understood by the build system * You don't need SRC_URI md5sum/sha256sum for an hg:// URL. Cheers, Paul -- Paul Eggleton Intel Open Source Technology Centre --_000_8c87603b0e564a00b7ef230b0e24b41dsakurauscom_ Content-Type: text/html; charset="Windows-1252" Content-Transfer-Encoding: quoted-printable

Hi Paul,

I changed the name of the recipe to 'canfestival_3-asc.bb' and removed t= he PN, PV, & PR defines and that seems to have gotten bitbake to extrac= t and execute into the same directory.


I'm now getting an error from the 'configure' scripe:


NOTE: Ru= nning ../canfestival-3-asc/configure  --build=3Dx86_64-linux   --host=3Darm-poky-linux-gnueabi   --target=3Darm-poky-linux-gnueabi   --prefix=3D/usr   --exec_prefix=3D/usr   --bindir=3D/usr/bin   --sbindir=3D/usr/sbin   --libexecdir=3D/usr/libexec   --datadir=3D/usr/share   --sysconfdir=3D/etc   --sharedstatedir=3D/com   --localstatedir=3D/var   --libdir=3D/usr/lib   --includedir=3D/usr/include   --oldincludedir=3D/usr/include   --infodir=3D/usr/share/info   --mandir=3D/usr/share/man   --disable-silent-rules   --disable-dependency-tracking   --with-libtool-sysroot=3D/home/gwilson/Qt-5.9/Yocto-build-RPi3/= build-raspberrypi3/tmp/sysroots/raspberrypi3 =96can=3Dsocket =96timers=3Dun= ix =96SDO_MAX_SIMULTANEOUS_TRANSFERS=3D25          &= nbsp;      =96SDO_MAX_LENGTH_TRANSFER=3D4096 =96MAX_NB_TIMER= =3D128 =96SDO_TIMEOUT_MS=3D1000 --disable-static  
ERROR: configure failed
Unknown = argument --build=3Dx86_64-linux

so bitbake is including an option that the configure script doesn't underst= and. Is there a way to delete that option?


Thanks so much for you help,

Greg


From: Paul Eggleton <p= aul.eggleton@linux.intel.com>
Sent: Wednesday, October 4, 2017 7:01:10 PM
To: Greg Wilson-Lindberg
Cc: yocto@yoctoproject.org
Subject: Re: [yocto] Having trouble getting recipe to run in proper = directory
 
Hi Greg,

On Thursday, 5 October 2017 1:16:15 PM NZDT Greg Wilson-Lindberg wrote:
> I'm trying to create a new recipe for a package that has a version and= non-numeric rev
> in its name (canfestival-3-asc). I've gotten bitbake to unpack the pac= kage into a tree
> that looks ok, but it keeps trying to run the compile at least in the = wrong directory.
> Here is the recipe:
>
>
> SUMMARY =3D "Independent CANOpen=AE stack"
> DESCRIPTION =3D "CanFestival focuses on providing an ANSI-C platf= orm independent \
>            = ;    CANOpen=AE stack that can be built as master or slave n= odes on PCs, \
>            = ;    Real-time IPCs, and Microcontrollers."
>
> HOMEPAGE =3D "http://www.= canfestival.org/"
>
> SRCREV =3D "895:8973dd8be7e8"
>
> SRC_URI =3D "hg://bitbucket.org/Mongo;protocol=3Dhttps;module=3Dc= anfestival-3-asc"
> SRC_URI[md5sum] =3D ""
> SRC_URI[sha256sum] =3D ""
>
> PN =3D "canfestival"
> PV =3D '3'
> PR =3D 'asc'
>
> LICENSE =3D "LGPL-2"
> LIC_FILES_CHKSUM =3D "file://COPYING;md5=3D \ >            = ;         file://LICENCE;md5=3D"
>
> inherit autotools
>
> # Specify any options you want to pass to the configure script using E= XTRA_OECONF:
> EXTRA_OECONF =3D "-can=3Dsocket -timers=3Dunix -SDO_MAX_SIMULTANE= OUS_TRANSFERS=3D25 \
>            = ;     -SDO_MAX_LENGTH_TRANSFER=3D4096 -MAX_NB_TIMER=3D1= 28 -SDO_TIMEOUT_MS=3D1000"
>
> PROVIDES =3D "canfestival"
>
> The directory structure that bitbake builds is:
>
>
> canfestival
>
>            3-as= c
>
>            = ;        build
>
>            = ;        canfestival-3   =         # directory that bitbake is tryi= ng to compile in
>
>            = ;        canfestival-3-asc  &n= bsp;    # directory that code was extracted to
>
>            = ;        temp
>
>
> I'm not getting any errors from the configure task, but the log file l= ooks like
> it is trying to run from the canfestival-3 directory, not the canfesti= val-3-asc. What
> can I do to the recipe to get the build to run in the canfestival-3-as= c directory?
> Or, i guess, get bitbake to unpack the source into the canfestival-3, = or a
> different directory that it will actually run the tasks in.

So firstly the directory where the build system should expect to find the source after do_unpack is specified by the S variable, whose default
is "${WORKDIR}/${BP}" where BP defaults to "${BPN}-${PV}&quo= t; and BPN will be the
same as PN in this case. However, you're setting the "asc" part i= n PR -
typically PR is left under the control of the build system and thus your PV=
would typically be set to "3-asc" in which case S would default t= o the right value i.e.
"canfestival-3-asc" (but if it didn't, you would just set S to fi= x it).

To summarise, set PV =3D "3-asc" (or alternatively have it picked= up from the
file name, i.e. name it canfestival_3-asc.bb) and it should work as you
expect.

A couple of other notes:
* For LICENSE, LGPL-2 isn't a standard value - LGPLv2, LGPLv2.0, LGPLv2.1, =
  LGPL-2.0, or LGPL-2.1 (with or without + at the end) would be un= derstood
  by the build system
* You don't need SRC_URI md5sum/sha256sum for an hg:// URL.

Cheers,
Paul

--

Paul Eggleton
Intel Open Source Technology Centre
--_000_8c87603b0e564a00b7ef230b0e24b41dsakurauscom_--