Hello,
I have the problem when building an own package because do_fetch() is
called twice.
Here is what i have done:
- built Angstrom as described (in fact i have a beagle board here):
git clone git://git.angstrom-distribution.org/setup-scripts
MACHINE=beagleboard ./oebb.sh update
MACHINE=beagleboard ./oebb.sh bitbake virtual/kernel
bitbake console-image
(Everything was doing fine, the board was booting with the created image)
- added my package:
$ cat sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb
DESCRIPTION = "Double fetch"
PR = "r0"
#
# interesting part is in do_fetch():
#
do_fetch () {
echo fetching... >>/tmp/doublefetch
}
do_compile () {
echo compiling
}
do_install () {
echo installing
}
do_stage () {
echo staging
}
- build it:
$ bitbake -b sources/openembedded/recipes/doublefetc/doublefetch_0.0.bb
Build Configuration:
BB_VERSION = "1.12.0"
METADATA_BRANCH = "2011.03-maintenance"
METADATA_REVISION = "bdb967b"
TARGET_ARCH = "arm"
TARGET_OS = "linux-gnueabi"
MACHINE = "beagleboard"
DISTRO = "angstrom"
DISTRO_VERSION = "2010.7-test-20110317"
TARGET_FPU = "hard"
NOTE: Preparing runqueue
NOTE: Executing RunQueue Tasks
NOTE: Running task 1 of 19 (ID: 10,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_setscene)
NOTE: package doublefetch-0.0-r0: task do_setscene: Started
NOTE: package doublefetch-0.0-r0: task do_setscene: Succeeded
NOTE: Running task 2 of 19 (ID: 8,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_fetch)
NOTE: package doublefetch-0.0-r0: task do_fetch: Started
NOTE: package doublefetch-0.0-r0: task do_fetch: Succeeded
NOTE: Running task 3 of 19 (ID: 0,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_unpack)
NOTE: Running task 4 of 19 (ID: 15,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_distribute_sources)
NOTE: package doublefetch-0.0-r0: task do_unpack: Started
NOTE: package doublefetch-0.0-r0: task do_unpack: Succeeded
NOTE: Running task 5 of 19 (ID: 1,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_patch)
NOTE: package doublefetch-0.0-r0: task do_distribute_sources: Started
NOTE: package doublefetch-0.0-r0: task do_distribute_sources: Succeeded
NOTE: package doublefetch-0.0-r0: task do_patch: Started
NOTE: package doublefetch-0.0-r0: task do_patch: Succeeded
NOTE: Running task 6 of 19 (ID: 11,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_configure)
NOTE: package doublefetch-0.0-r0: task do_configure: Started
NOTE: package doublefetch-0.0-r0: task do_configure: Succeeded
NOTE: Running task 7 of 19 (ID: 12,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_qa_configure)
NOTE: package doublefetch-0.0-r0: task do_qa_configure: Started
NOTE: package doublefetch-0.0-r0: task do_qa_configure: Succeeded
NOTE: Running task 8 of 19 (ID: 13,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_compile)
NOTE: package doublefetch-0.0-r0: task do_compile: Started
NOTE: package doublefetch-0.0-r0: task do_compile: Succeeded
NOTE: Running task 9 of 19 (ID: 2,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_install)
NOTE: package doublefetch-0.0-r0: task do_install: Started
NOTE: package doublefetch-0.0-r0: task do_install: Succeeded
NOTE: Running task 10 of 19 (ID: 14,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_package)
NOTE: Running task 11 of 19 (ID: 3,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_populate_sysroot)
NOTE: package doublefetch-0.0-r0: task do_package: Started
NOTE: package doublefetch-0.0-r0: task do_populate_sysroot: Started
NOTE: package doublefetch-0.0-r0: task do_package: Succeeded
NOTE: Running task 12 of 19 (ID: 18,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_package_write_ipk)
NOTE: package doublefetch-0.0-r0: task do_package_write_ipk: Started
Packaged contents of doublefetch-dbg into
/home/plus/beagleboard/setup-scripts/build/tmp-angstrom_2008_1/deploy/glibc/ipk/armv7a/doublefetch-dbg_0.0-r0.6_armv7a.ipk
Packaged contents of doublefetch-dev into
/home/plus/beagleboard/setup-scripts/build/tmp-angstrom_2008_1/deploy/glibc/ipk/armv7a/doublefetch-dev_0.0-r0.6_armv7a.ipk
NOTE: package doublefetch-0.0-r0: task do_package_write_ipk: Succeeded
NOTE: Running task 13 of 19 (ID: 5,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_package_write)
NOTE: package doublefetch-0.0-r0: task do_package_write: Started
NOTE: package doublefetch-0.0-r0: task do_package_write: Succeeded
NOTE: package doublefetch-0.0-r0: task do_populate_sysroot: Succeeded
NOTE: Running task 14 of 19 (ID: 4,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_qa_staging)
NOTE: package doublefetch-0.0-r0: task do_qa_staging: Started
NOTE: package doublefetch-0.0-r0: task do_qa_staging: Succeeded
NOTE: Running task 15 of 19 (ID: 6,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_package_stage)
NOTE: package doublefetch-0.0-r0: task do_package_stage: Started
NOTE: package doublefetch-0.0-r0: task do_package_stage: Succeeded
NOTE: Running task 16 of 19 (ID: 7,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_package_stage_all)
NOTE: package doublefetch-0.0-r0: task do_package_stage_all: Started
NOTE: package doublefetch-0.0-r0: task do_package_stage_all: Succeeded
NOTE: Running task 17 of 19 (ID: 9,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_build)
NOTE: package doublefetch-0.0-r0: task do_build: Started
NOTE: package doublefetch-0.0-r0: task do_build: Succeeded
NOTE: Running task 18 of 19 (ID: 16,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_rm_work)
NOTE: package doublefetch-0.0-r0: task do_rm_work: Started
NOTE: package doublefetch-0.0-r0: task do_rm_work: Succeeded
NOTE: Running task 19 of 19 (ID: 17,
/home/plus/beagleboard/setup-scripts/sources/openembedded/recipes/doublefetch/doublefetch_0.0.bb,
do_rm_work_all)
NOTE: package doublefetch-0.0-r0: task do_rm_work_all: Started
NOTE: package doublefetch-0.0-r0: task do_rm_work_all: Succeeded
NOTE: Tasks Summary: Attempted 19 tasks of which 0 didn't need to be
rerun and 0 failed.
- and the result:
$ cat /tmp/doublefetch
fetching...
fetching...
I can't use the standard fetchers as the source is controlled with the
mercurial system. While the first fetch is ok, the second fails because
the files are already there.
How can i get rid of the second fetch?
Some more information:
- In the real package (with files, not this stripped version above),
bitbake fails with "ERROR: Function 'do_fetch' failed (see /dev/null for
further information)" - log is going to /dev/null?
- All the packages (mine and the Angstrom packages) have run.do_fetch twice:
$ ls -1
build/tmp-angstrom_2008_1/work/armv7a-angstrom-linux-gnueabi/doublefetch-0.0-r0/temp/run.do_fetch.*
build/tmp-angstrom_2008_1/work/armv7a-angstrom-linux-gnueabi/doublefetch-0.0-r0/temp/run.do_fetch.13710
build/tmp-angstrom_2008_1/work/armv7a-angstrom-linux-gnueabi/doublefetch-0.0-r0/temp/run.do_fetch.13713
All other run scripts are there only once, as expected.
Well i could of course do a workaround in the do_fetch function, but
that wouldn't be very beautiful... Can someone help me any further
bye
Norbert
_______________________________________________
Angstrom-distro-users mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/angstrom-distro-users