Difference between revisions of "Legacy staging"

From Openembedded.org
Jump to: navigation, search
(New page: The term "legacy staging" refers to recipes or classes which have a do_stage function for populating the sysroot directories that we use for building rather than having a do_install that w...)
 
(Update for OE-Core and tidy up formatting)
Line 1: Line 1:
The term "legacy staging" refers to recipes or classes which have a do_stage function for populating the sysroot directories that we use for building rather than having a do_install that works, along with post install functions to mangle the contents as needed.
+
The term "legacy staging" refers to recipes or classes which have a <code>do_stage</code> function for populating the sysroot directories that we use for building, rather than having a <code>do_install</code> that works, along with post install functions to mangle the contents as needed.
  
 +
In OpenEmbedded-Classic, legacy staging was deprecated but still supported; but with OE-Core, BitBake will error out during parse if it finds a <code>do_stage</code> function defined in any recipe, so when migrating a recipe you will need to translate this if present.
  
Koen has provided a mini cheat sheet for converting the do_stage functions to do_install functions:
+
Steps for moving script code in the <code>do_stage</code> function to the <code>do_install</code> function:
  * STAGING_BINDIR -> ${D}${bindir}
+
  * STAGING_INCDIR -> ${D}${includedir}
+
  * STAGING_LIBDIR -> ${D}${libdir}
+
  * STAGING_DATADIR -> ${D}${datadir}
+
  * And if your recipe uses BBCLASSEXTEND = native *and* 'make install' doesn't do the job (e.g. using do_install_append), use NATIVE_INSTALL_WORKS = "1"
+
  * If you use packaged-staging it's easy to do dpkg-deb -c on the staging packages before and after the changes.
+
  
To see what recipes that *you* are currently building and make use of legacy staging, see the legacy-staging.log file in your TMPDIR.
+
* Replace <code>STAGING_BINDIR</code> with <code>${D}${bindir}</code>
 +
* Replace <code>STAGING_INCDIR</code> with <code>${D}${includedir}</code>
 +
* Replace <code>STAGING_LIBDIR</code> with <code>${D}${libdir}</code>
 +
* Replace <code>STAGING_DATADIR</code> with <code>${D}${datadir}</code>

Revision as of 14:36, 7 November 2012

The term "legacy staging" refers to recipes or classes which have a do_stage function for populating the sysroot directories that we use for building, rather than having a do_install that works, along with post install functions to mangle the contents as needed.

In OpenEmbedded-Classic, legacy staging was deprecated but still supported; but with OE-Core, BitBake will error out during parse if it finds a do_stage function defined in any recipe, so when migrating a recipe you will need to translate this if present.

Steps for moving script code in the do_stage function to the do_install function:

  • Replace STAGING_BINDIR with ${D}${bindir}
  • Replace STAGING_INCDIR with ${D}${includedir}
  • Replace STAGING_LIBDIR with ${D}${libdir}
  • Replace STAGING_DATADIR with ${D}${datadir}
Personal tools
Namespaces

Variants
Actions
Navigation
Categories
OE services
Toolbox