summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKoen Kooi <koen@openembedded.org>2006-08-22 18:35:48 +0000
committerKoen Kooi <koen@openembedded.org>2006-08-22 18:35:48 +0000
commitdef7fdbd8aef8f57d4cfc3b30e4eeb6524a52853 (patch)
treed6c01fa6f5ac0405c7a1721942f9ec9e7026ffd2
parent862ce6c735bea264f51055de9654a4be1626d324 (diff)
downloadopenembedded-def7fdbd8aef8f57d4cfc3b30e4eeb6524a52853.tar.gz
docs/packaged-staging.xml: be more verbose and talk about chroot a bit
-rw-r--r--docs/packaged-staging.xml35
1 files changed, 27 insertions, 8 deletions
diff --git a/docs/packaged-staging.xml b/docs/packaged-staging.xml
index 9a748a63ea..b701689a65 100644
--- a/docs/packaged-staging.xml
+++ b/docs/packaged-staging.xml
@@ -26,9 +26,9 @@
<para>First we need to identify three classes of packages:
<itemizedlist>
- <listitem><para>'native' - These packages run on the buildsystem (e.g. quilt-native)</para></listitem>
- <listitem><para>'cross' - These packages run on the buildsystem, but creates things for the target system (e.g gcc-cross)</para></listitem>
- <listitem><para>'regular' - These packages run on the targetsystem (e.g. glibc)</para></listitem>
+ <listitem><para>'native' - These packages run on the buildsystem (e.g. quilt-native), OE doesn't package these</para></listitem>
+ <listitem><para>'cross' - These packages run on the buildsystem, but creates things for the target system (e.g gcc-cross), OE doesn't packages these completely. It will e.g. create a libgcc1 packages, but not a gcc-cross package</para></listitem>
+ <listitem><para>'regular' - These packages run on the targetsystem (e.g. glibc), OE does packages these</para></listitem>
</itemizedlist>
</para>
<para>
@@ -49,12 +49,12 @@ And some terminology:
</para>
<section>
- <title>Start over from scratch</title> <para> For each to be built package we will repopulate the staging directory from scratch. The benefits are a clean environment and avoids packages picking stuff up at random. Conflicts when installing packages can only happen when two different providers are trying to install the same file. This can only be a bug of the OpenEmbedded meta data. This approach will not require any conflict handling or resolution
+ <title>Start over from scratch</title> <para> For each to be built package we will repopulate the staging directory from scratch. The benefits are a clean environment and avoids packages picking stuff up at random. Conflicts when installing packages can only happen when two different providers are trying to install the same file. This can only be a bug of the OpenEmbedded meta data. This approach will not require any conflict handling or resolution. This will break a multithreaded bitbake, since only one tasks can access staging reliably.
</para>
</section>
<section>
- <title>Incrementally installing packages</title> <para>In contrast to repopluating the staging area from scratch we install additional dependencies and remove conflicting packages. The installing and removing of packages is assumed to be faster than repopulating from scratch. Once a package completed we could consider removing the non-native depends to avoid a growing staging directory. One issue is with the clean task. We could assume that cleaning a package will remove it from the staging area as well. There is one possible problem with it. Let us assume we want to clean quilt-native, virtually every package DEPENDS on it, we would have to clean the staging area completely. If this is the wished behaviour needs to be discussed.
+ <title>Incrementally installing packages</title> <para>In contrast to repopluating the staging area from scratch we install additional dependencies and remove conflicting packages. The installing and removing of packages is assumed to be faster than repopulating from scratch. Once a package completed we could consider removing the non-native depends to avoid a growing staging directory. One issue is with the clean task. We could assume that cleaning a package will remove it from the staging area as well. There is one possible problem with it. Let us assume we want to clean quilt-native, virtually every package DEPENDS on it, we would have to clean the staging area completely. If this is the wished behaviour needs to be discussed. This should be safe for a multithreaded bitbake, given that no two do_stages access staging at the same time.
</para>
</section>
</chapter>
@@ -118,7 +118,7 @@ python do_write_ipk_list () {
}
</screen>
-So now OE will spit out a spawnfile for each revision of a recipe, instead of one per recipe as the pkgmap code does.
+So now OE will spit out a spawnfile for each revision of a recipe, instead of one per recipe as the pkgmap code does. This is needed to get versioned dependencies to work in the future.
</para>
</section>
@@ -153,6 +153,8 @@ STAGING_BASEDIR = "${STAGING_LIBDIR}/.."
oenote "Spawn file not found!"
fi
</screen>
+
+The sed is needed to fix the .la files to avoid linking problems. Using a chroot for building would avoid this problem. I've not encountered troubles with pkgconfig files yet, so those remain untouched.
</para>
</section>
@@ -221,7 +223,8 @@ fi #if !glibc intermediate
}
</screen>
-The above gets prepended to the do_stage() method specified in the recipe. I works by rotating away the staging dir so the next step can easily find the added files:
+The above gets prepended to the do_stage() method specified in the recipe. A 'shared' ipkg.conf is used to make tracking of packages easier, but could result in target binaries ending up in staging.
+It works by rotating away the staging dir so the next step can easily find the added files:
<screen>
do_stage_append() {
@@ -265,6 +268,8 @@ cat installed-list | xargs ipkg install
ipkg install newly-packaged-stuff
</screen>
+This will avoid a lot of troubles and isn't hard to implement and would be a nice task for someone planning to work on this.
+
</para>
</section>
@@ -278,6 +283,14 @@ ipkg install newly-packaged-stuff
<para>
The metadata in the packaged-staging branch well, once it's done building the toolchains. The infamous 'bitbake nano' testcase works as well as other packages present in the packaged-staging branch.
</para>
+<para>
+The whole concept of ad-hoc creating seperate packages for native and cross packages is flawed, however. The correct solution would involve building the needed native stuff with MACHINE=native and ASSUME_PROVIDED_native = "bunch of stuff".
+Stuffing all archs in the ipkg.conf is wrong as well, since it could allow installing of x86 stuff in an ARM based staging. I have no real solution for that yet.
+</para>
+<para>
+The hardcoded use of ipkg sucks, but it's the only package format OE can generate reliably. Using checkinstall would solve that, but that would introduce even more bootstrap and self-hosting problems.
+</para>
+
</section>
<section>
@@ -303,8 +316,14 @@ We could save some CPU cycles and disk IO by doing checking "inherits('cross')"
</screen>
The code for both items is in packaged-staging.bbclass already, but in different methods. Estimated time: 30 minutes.
-
</para>
+<para>
+To completely solve chicken and egg problems OE should have -bootstrap packages that contains functional replacements, or require on things from RequiredSoftware to build. We should consider using the shell version of ipkg to install packages into staging/cross/work.
+</para>
+<para>
+A good follow-up for this SoC would be to investigate using chroot for compiling combined with something like mount --bind/unionfs/checkinstall to get rid of most relocation issues. Using a chroot would also be safe for a multithreaded bitbake, since each build can have its own sandbox.
+</para>
+
</section>