* Linking two recipes
@ 2012-03-19 20:59 simran singh
2012-03-19 21:22 ` Richard Purdie
0 siblings, 1 reply; 10+ messages in thread
From: simran singh @ 2012-03-19 20:59 UTC (permalink / raw)
To: openembedded-core
[-- Attachment #1.1: Type: text/plain, Size: 348 bytes --]
Hello,I have recipes for two applications Recipe A and Recipe B. Recipe B requires a lib.so file and init.h file which are installed by Recipe A.How do I acknowledge this dependency in Recipe B. I tried doing do_stage() function in recipe A with no success. Please advice.I am attaching the two recipes.Thank you for any help.
Simran
[-- Attachment #1.2: Type: text/html, Size: 632 bytes --]
[-- Attachment #2: recipeA.bb --]
[-- Type: application/octet-stream, Size: 1075 bytes --]
DESCRIPTION = "Botan library"
PR = "r0"
SRC_URI = "file://${PN}-${PV}.tar.gz"
export LDFLAGS = "-L${STAGING_LIBDIR}"
S = "${WORKDIR}"
#EXTRA_OEMAKE = 'LINUX=${STAGING_KERNEL_DIR} EXLDFLAGS="${LDFLAGS}" \
# MACHINE=${TARGET_ARCH} CC="${CC}" AR="${AR}" PREFIX="${prefix}"'
do_configure() {
mkdir -p ${D}/usr/botan
cd Botan-1.10.1
# export PATH=${WORKDIR}:${PATH}
# export CC=gcc
# export CXX=g++
python configure.py --prefix=${D}/usr/botan
# make
# make install
}
#TARGET_CC_ARCH += "${LDFLAGS}"
do_compile() {
# export PATH=${WORKDIR}:${PATH}
# export CC=gcc
# export CXX=g++
cd Botan-1.10.1
make
}
fakeroot do_install() {
cd Botan-1.10.1
make install
cp -r ${WORKDIR}/Botan-1.10.1/* ${D}/usr/botan
}
do_stage() {
# install -m 0755 ${D}/usr/botan/libbotan-1.10.so.0.1 ${STAGING_LIBDIR}/botan
install -d ${STAGING_INCDIR}/
install -d ${STAGING_LIBDIR}
# cd ${D}/usr/botan
oe_libinstall -so libbotan-1.10.so.0.1 ${STAGING_LIBDIR}
}
#FILES_${PN} += "${datadir}/botan"
FILES_${PN} += "/usr/bin/botan"
#FILES_${PN} = "${base_libdir}/libgcc*.so.*"
[-- Attachment #3: recipeB.bb --]
[-- Type: application/octet-stream, Size: 624 bytes --]
DESCRIPTION = "SoftHSM"
PR = "r0"
SRC_URI = "file://${PN}-${PV}.tar.gz"
S = "${WORKDIR}"
DEPENDS = "botan sqlite3"
#RDEPENDS = "botan"
export LDFLAGS = "-L${STAGING_LIBDIR}"
export STAGING_LIBDIR
do_configure() {
mkdir -p ${D}/usr/softhsm
./softhsm-1.3.1/configure --host --prefix=${D}/usr/softhsm --with-loglevel=4 #--with-botan=${STAGING_LIBDIR}/botan
}
do_compile() {
make
}
fakeroot do_install() {
make install
}
FILES_${PN} += "/usr/bin/softhsm"
#FILES_${PN} += "/home/Simran/Freescale/QorIQ-DPAA-SDK-20111026-systembuilder/build_p4080ds_release/work/ppce500mc-linux/botan-1.0-r0/image/usr/botan"
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: Linking two recipes 2012-03-19 20:59 Linking two recipes simran singh @ 2012-03-19 21:22 ` Richard Purdie 2012-03-19 21:33 ` simran singh 0 siblings, 1 reply; 10+ messages in thread From: Richard Purdie @ 2012-03-19 21:22 UTC (permalink / raw) To: Patches and discussions about the oe-core layer On Mon, 2012-03-19 at 13:59 -0700, simran singh wrote: > Hello, > I have recipes for two applications Recipe A and Recipe B. Recipe B > requires a lib.so file and init.h file which are installed by Recipe > A. > How do I acknowledge this dependency in Recipe B. I tried doing > do_stage() function in recipe A with no success. Please advice. > I am attaching the two recipes. > Thank you for any help. recipe B needs to do: DEPENDS += "recipeA" Cheers, Richard ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Linking two recipes 2012-03-19 21:22 ` Richard Purdie @ 2012-03-19 21:33 ` simran singh 2012-03-19 21:39 ` Christopher Larson 0 siblings, 1 reply; 10+ messages in thread From: simran singh @ 2012-03-19 21:33 UTC (permalink / raw) To: openembedded-core [-- Attachment #1: Type: text/plain, Size: 1267 bytes --] Hello Richard, I did try the DEPENDS variable before but still doesnt solve the problem.A configure script in recipe B has to run a program that is built under ${D}/usr/botan by recipe A. Even if i pass the path to the configure script, it is unable to find the script. ./configure --with-botan=............./usr/botanThanks. Simran > From: richard.purdie@linuxfoundation.org > To: openembedded-core@lists.openembedded.org > Date: Mon, 19 Mar 2012 21:22:30 +0000 > Subject: Re: [OE-core] Linking two recipes > > On Mon, 2012-03-19 at 13:59 -0700, simran singh wrote: > > Hello, > > I have recipes for two applications Recipe A and Recipe B. Recipe B > > requires a lib.so file and init.h file which are installed by Recipe > > A. > > How do I acknowledge this dependency in Recipe B. I tried doing > > do_stage() function in recipe A with no success. Please advice. > > I am attaching the two recipes. > > Thank you for any help. > > recipe B needs to do: > > DEPENDS += "recipeA" > > Cheers, > > Richard > > > > _______________________________________________ > Openembedded-core mailing list > Openembedded-core@lists.openembedded.org > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core [-- Attachment #2: Type: text/html, Size: 1803 bytes --] ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Linking two recipes 2012-03-19 21:33 ` simran singh @ 2012-03-19 21:39 ` Christopher Larson 2012-03-19 21:57 ` simran singh 0 siblings, 1 reply; 10+ messages in thread From: Christopher Larson @ 2012-03-19 21:39 UTC (permalink / raw) To: Patches and discussions about the oe-core layer [-- Attachment #1: Type: text/plain, Size: 2084 bytes --] /usr/botan isn't a path that'll be placed into the sysroot, which is the standard mechanism by which files from dependencies are accessed (e.g. headers, shared libraries, native scripts). You should install to more standard system locations. -- Christopher Larson On Monday, March 19, 2012 at 2:33 PM, simran singh wrote: > Hello Richard, > > I did try the DEPENDS variable before but still doesnt solve the problem. > A configure script in recipe B has to run a program that is built under ${D}/usr/botan by recipe A. > Even if i pass the path to the configure script, it is unable to find the script. ./configure --with-botan=............./usr/botan > Thanks. > > Simran > > > > From: richard.purdie@linuxfoundation.org (mailto:richard.purdie@linuxfoundation.org) > > To: openembedded-core@lists.openembedded.org (mailto:openembedded-core@lists.openembedded.org) > > Date: Mon, 19 Mar 2012 21:22:30 +0000 > > Subject: Re: [OE-core] Linking two recipes > > > > On Mon, 2012-03-19 at 13:59 -0700, simran singh wrote: > > > Hello, > > > I have recipes for two applications Recipe A and Recipe B. Recipe B > > > requires a lib.so file and init.h file which are installed by Recipe > > > A. > > > How do I acknowledge this dependency in Recipe B. I tried doing > > > do_stage() function in recipe A with no success. Please advice. > > > I am attaching the two recipes. > > > Thank you for any help. > > > > recipe B needs to do: > > > > DEPENDS += "recipeA" > > > > Cheers, > > > > Richard > > > > > > > > _______________________________________________ > > Openembedded-core mailing list > > Openembedded-core@lists.openembedded.org (mailto:Openembedded-core@lists.openembedded.org) > > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core > _______________________________________________ > Openembedded-core mailing list > Openembedded-core@lists.openembedded.org (mailto:Openembedded-core@lists.openembedded.org) > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core > > [-- Attachment #2: Type: text/html, Size: 3170 bytes --] ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Linking two recipes 2012-03-19 21:39 ` Christopher Larson @ 2012-03-19 21:57 ` simran singh 2012-03-19 21:59 ` Christopher Larson 0 siblings, 1 reply; 10+ messages in thread From: simran singh @ 2012-03-19 21:57 UTC (permalink / raw) To: openembedded-core [-- Attachment #1: Type: text/plain, Size: 2736 bytes --] So install something along the lines: do_install(){ python configure.py --prefix=${libdir}/botan} When I do that, I get a permission denied error:mkdir: cannot create directory /usr/lib/botan Sorry I am still significantly new to open embedded and bitbake. Thanks,Simran Date: Mon, 19 Mar 2012 14:39:13 -0700 From: kergoth@gmail.com To: openembedded-core@lists.openembedded.org Subject: Re: [OE-core] Linking two recipes /usr/botan isn't a path that'll be placed into the sysroot, which is the standard mechanism by which files from dependencies are accessed (e.g. headers, shared libraries, native scripts). You should install to more standard system locations. -- Christopher Larson On Monday, March 19, 2012 at 2:33 PM, simran singh wrote: Hello Richard, I did try the DEPENDS variable before but still doesnt solve the problem.A configure script in recipe B has to run a program that is built under ${D}/usr/botan by recipe A. Even if i pass the path to the configure script, it is unable to find the script. ./configure --with-botan=............./usr/botanThanks. Simran > From: richard.purdie@linuxfoundation.org > To: openembedded-core@lists.openembedded.org > Date: Mon, 19 Mar 2012 21:22:30 +0000 > Subject: Re: [OE-core] Linking two recipes > > On Mon, 2012-03-19 at 13:59 -0700, simran singh wrote: > > Hello, > > I have recipes for two applications Recipe A and Recipe B. Recipe B > > requires a lib.so file and init.h file which are installed by Recipe > > A. > > How do I acknowledge this dependency in Recipe B. I tried doing > > do_stage() function in recipe A with no success. Please advice. > > I am attaching the two recipes. > > Thank you for any help. > > recipe B needs to do: > > DEPENDS += "recipeA" > > Cheers, > > Richard > > > > _______________________________________________ > Openembedded-core mailing list > Openembedded-core@lists.openembedded.org > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core _______________________________________________Openembedded-core mailing listOpenembedded-core@lists.openembedded.orghttp://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core [-- Attachment #2: Type: text/html, Size: 4283 bytes --] ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Linking two recipes 2012-03-19 21:57 ` simran singh @ 2012-03-19 21:59 ` Christopher Larson 2012-03-19 22:10 ` simran singh 0 siblings, 1 reply; 10+ messages in thread From: Christopher Larson @ 2012-03-19 21:59 UTC (permalink / raw) To: Patches and discussions about the oe-core layer [-- Attachment #1: Type: text/plain, Size: 3447 bytes --] All installs should be placed relative to ${D}. See one of the many other recipes that define do_install for examples :) -- Christopher Larson On Monday, March 19, 2012 at 2:57 PM, simran singh wrote: > So install something along the lines: > > do_install(){ > python configure.py --prefix=${libdir}/botan > } > > When I do that, I get a permission denied error: > mkdir: cannot create directory /usr/lib/botan > > Sorry I am still significantly new to open embedded and bitbake. > > Thanks, > Simran > > Date: Mon, 19 Mar 2012 14:39:13 -0700 > From: kergoth@gmail.com (mailto:kergoth@gmail.com) > To: openembedded-core@lists.openembedded.org (mailto:openembedded-core@lists.openembedded.org) > Subject: Re: [OE-core] Linking two recipes > > /usr/botan isn't a path that'll be placed into the sysroot, which is the standard mechanism by which files from dependencies are accessed (e.g. headers, shared libraries, native scripts). You should install to more standard system locations. > > -- > Christopher Larson > > > On Monday, March 19, 2012 at 2:33 PM, simran singh wrote: > > > Hello Richard, > > > > I did try the DEPENDS variable before but still doesnt solve the problem. > > A configure script in recipe B has to run a program that is built under ${D}/usr/botan by recipe A. > > Even if i pass the path to the configure script, it is unable to find the script. ./configure --with-botan=............./usr/botan > > Thanks. > > > > Simran > > > > > > > From: richard.purdie@linuxfoundation.org (mailto:richard.purdie@linuxfoundation.org) > > > To: openembedded-core@lists.openembedded.org (mailto:openembedded-core@lists.openembedded.org) > > > Date: Mon, 19 Mar 2012 21:22:30 +0000 > > > Subject: Re: [OE-core] Linking two recipes > > > > > > On Mon, 2012-03-19 at 13:59 -0700, simran singh wrote: > > > > Hello, > > > > I have recipes for two applications Recipe A and Recipe B. Recipe B > > > > requires a lib.so file and init.h file which are installed by Recipe > > > > A. > > > > How do I acknowledge this dependency in Recipe B. I tried doing > > > > do_stage() function in recipe A with no success. Please advice. > > > > I am attaching the two recipes. > > > > Thank you for any help. > > > > > > recipe B needs to do: > > > > > > DEPENDS += "recipeA" > > > > > > Cheers, > > > > > > Richard > > > > > > > > > > > > _______________________________________________ > > > Openembedded-core mailing list > > > Openembedded-core@lists.openembedded.org (mailto:Openembedded-core@lists.openembedded.org) > > > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core > > _______________________________________________ > > Openembedded-core mailing list > > Openembedded-core@lists.openembedded.org (mailto:Openembedded-core@lists.openembedded.org) > > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core > > > > > > > > > > _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core > _______________________________________________ > Openembedded-core mailing list > Openembedded-core@lists.openembedded.org (mailto:Openembedded-core@lists.openembedded.org) > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core > > [-- Attachment #2: Type: text/html, Size: 5325 bytes --] ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Linking two recipes 2012-03-19 21:59 ` Christopher Larson @ 2012-03-19 22:10 ` simran singh 2012-03-19 22:54 ` Richard Purdie 0 siblings, 1 reply; 10+ messages in thread From: simran singh @ 2012-03-19 22:10 UTC (permalink / raw) To: openembedded-core [-- Attachment #1: Type: text/plain, Size: 3920 bytes --] This is how I was able to install it: do_install(){ python configure.py --prefix=${D}/${libdir}/botan} But still the other recipe is unable to locate the files. Date: Mon, 19 Mar 2012 14:59:33 -0700 From: kergoth@gmail.com To: openembedded-core@lists.openembedded.org Subject: Re: [OE-core] Linking two recipes All installs should be placed relative to ${D}. See one of the many other recipes that define do_install for examples :) -- Christopher Larson On Monday, March 19, 2012 at 2:57 PM, simran singh wrote: So install something along the lines: do_install(){ python configure.py --prefix=${libdir}/botan} When I do that, I get a permission denied error:mkdir: cannot create directory /usr/lib/botan Sorry I am still significantly new to open embedded and bitbake. Thanks,Simran Date: Mon, 19 Mar 2012 14:39:13 -0700 From: kergoth@gmail.com To: openembedded-core@lists.openembedded.org Subject: Re: [OE-core] Linking two recipes /usr/botan isn't a path that'll be placed into the sysroot, which is the standard mechanism by which files from dependencies are accessed (e.g. headers, shared libraries, native scripts). You should install to more standard system locations. -- Christopher Larson On Monday, March 19, 2012 at 2:33 PM, simran singh wrote: Hello Richard, I did try the DEPENDS variable before but still doesnt solve the problem.A configure script in recipe B has to run a program that is built under ${D}/usr/botan by recipe A. Even if i pass the path to the configure script, it is unable to find the script. ./configure --with-botan=............./usr/botanThanks. Simran > From: richard.purdie@linuxfoundation.org > To: openembedded-core@lists.openembedded.org > Date: Mon, 19 Mar 2012 21:22:30 +0000 > Subject: Re: [OE-core] Linking two recipes > > On Mon, 2012-03-19 at 13:59 -0700, simran singh wrote: > > Hello, > > I have recipes for two applications Recipe A and Recipe B. Recipe B > > requires a lib.so file and init.h file which are installed by Recipe > > A. > > How do I acknowledge this dependency in Recipe B. I tried doing > > do_stage() function in recipe A with no success. Please advice. > > I am attaching the two recipes. > > Thank you for any help. > > recipe B needs to do: > > DEPENDS += "recipeA" > > Cheers, > > Richard > > > > _______________________________________________ > Openembedded-core mailing list > Openembedded-core@lists.openembedded.org > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core _______________________________________________Openembedded-core mailing listOpenembedded-core@lists.openembedded.orghttp://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core _______________________________________________Openembedded-core mailing listOpenembedded-core@lists.openembedded.orghttp://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core [-- Attachment #2: Type: text/html, Size: 6311 bytes --] ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Linking two recipes 2012-03-19 22:10 ` simran singh @ 2012-03-19 22:54 ` Richard Purdie 2012-03-20 19:25 ` simran singh 0 siblings, 1 reply; 10+ messages in thread From: Richard Purdie @ 2012-03-19 22:54 UTC (permalink / raw) To: Patches and discussions about the oe-core layer On Mon, 2012-03-19 at 15:10 -0700, simran singh wrote: > This is how I was able to install it: > > > do_install(){ > python configure.py --prefix=${D}/${libdir}/botan > } > > > But still the other recipe is unable to locate the files. > In the other recipe, look in ${STAGING_LIBDIR}... Cheers, Richard ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Linking two recipes 2012-03-19 22:54 ` Richard Purdie @ 2012-03-20 19:25 ` simran singh 2012-04-07 3:44 ` Khem Raj 0 siblings, 1 reply; 10+ messages in thread From: simran singh @ 2012-03-20 19:25 UTC (permalink / raw) To: openembedded-core [-- Attachment #1: Type: text/plain, Size: 949 bytes --] Hello, I was able to have the recipes find each other but I think the problem lies somewhere else as to why the build is failing.But thanks for all the help. Simran > From: richard.purdie@linuxfoundation.org > To: openembedded-core@lists.openembedded.org > Date: Mon, 19 Mar 2012 22:54:14 +0000 > Subject: Re: [OE-core] Linking two recipes > > On Mon, 2012-03-19 at 15:10 -0700, simran singh wrote: > > This is how I was able to install it: > > > > > > do_install(){ > > python configure.py --prefix=${D}/${libdir}/botan > > } > > > > > > But still the other recipe is unable to locate the files. > > > > In the other recipe, look in ${STAGING_LIBDIR}... > > Cheers, > > Richard > > > > _______________________________________________ > Openembedded-core mailing list > Openembedded-core@lists.openembedded.org > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-core [-- Attachment #2: Type: text/html, Size: 1450 bytes --] ^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Linking two recipes 2012-03-20 19:25 ` simran singh @ 2012-04-07 3:44 ` Khem Raj 0 siblings, 0 replies; 10+ messages in thread From: Khem Raj @ 2012-04-07 3:44 UTC (permalink / raw) To: openembedded-core -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 03/20/2012 12:25 PM, simran singh wrote: > > Hello, I was able to have the recipes find each other but I think > the problem lies somewhere else as to why the build is failing.But > thanks for all the help. Simran It seems recipeB needs to run some binary from recipeA during its configure step which tells me that you need a native version of recipeA so add BBCLASSEXTEND = "native" to recipeA and then in recipeB add recipeA-native to DEPENDS - -Khem -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk9/uCYACgkQuwUzVZGdMxR+sgCdEx+b67XQhyH0V9cE6PtRKVk0 JRsAn0x5DBv9wILS1RGl8vw347lUz1uN =8c5R -----END PGP SIGNATURE----- ^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2012-04-07 3:53 UTC | newest] Thread overview: 10+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2012-03-19 20:59 Linking two recipes simran singh 2012-03-19 21:22 ` Richard Purdie 2012-03-19 21:33 ` simran singh 2012-03-19 21:39 ` Christopher Larson 2012-03-19 21:57 ` simran singh 2012-03-19 21:59 ` Christopher Larson 2012-03-19 22:10 ` simran singh 2012-03-19 22:54 ` Richard Purdie 2012-03-20 19:25 ` simran singh 2012-04-07 3:44 ` Khem Raj
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox