2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Standard target filesystem paths.
|
|
|
|
##################################################################
|
2011-07-22 12:08:58 +00:00
|
|
|
#
|
2015-08-23 02:38:55 +00:00
|
|
|
# If changing these values, beware that native/cross/nativesdk bbclass
|
2011-07-22 12:08:58 +00:00
|
|
|
# files may also need changes to keep in sync.
|
|
|
|
#
|
|
|
|
|
|
|
|
# Used by multilib code to change the library paths
|
2011-08-04 18:51:26 +00:00
|
|
|
baselib = "${BASELIB}"
|
2011-11-24 17:46:46 +00:00
|
|
|
baselib[vardepvalue] = "${baselib}"
|
2011-08-04 18:51:26 +00:00
|
|
|
BASELIB = "lib"
|
|
|
|
BASELIB_powerpc64 = "lib64"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
# Path prefixes
|
|
|
|
export base_prefix = ""
|
2009-09-16 22:09:44 +00:00
|
|
|
export prefix = "/usr"
|
2016-07-13 12:45:02 +00:00
|
|
|
export exec_prefix = "${prefix}"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
# Base paths
|
2009-09-16 22:09:44 +00:00
|
|
|
export base_bindir = "${base_prefix}/bin"
|
|
|
|
export base_sbindir = "${base_prefix}/sbin"
|
2011-07-22 12:08:58 +00:00
|
|
|
export base_libdir = "${base_prefix}/${baselib}"
|
2012-12-14 13:55:09 +00:00
|
|
|
export nonarch_base_libdir = "${base_prefix}/lib"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
# Architecture independent paths
|
2009-09-16 22:09:44 +00:00
|
|
|
export sysconfdir = "${base_prefix}/etc"
|
|
|
|
export servicedir = "${base_prefix}/srv"
|
|
|
|
export sharedstatedir = "${base_prefix}/com"
|
|
|
|
export localstatedir = "${base_prefix}/var"
|
native.bbclass: Properly define directories
For most users this commit will have no effect. But if you come across the idea of giving
different names for paths, you'll get some troubles.
When a recipe inherit native, properly define bindir, sbindir, includedir, sysconfdir, datadir
(using xxxdir_native definitions from meta/conf/bitbake.conf).
For example, edit "${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}/quilt-native/temp/log.do_configure"
and see what are the arguments given by oe_runconf.
Notice that ${docdir}, ${mandir}, ${infodir}, ${localstatedir} have no associated _native definition.
(From OE-Core rev: 15345ddd4be6a0b041b3d6caaad48d46b22142e9)
Signed-off-by: Matthieu Crapet <Matthieu.Crapet@ingenico.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-12 15:49:32 +00:00
|
|
|
export datadir = "${prefix}/share"
|
2009-09-16 22:09:44 +00:00
|
|
|
export infodir = "${datadir}/info"
|
|
|
|
export mandir = "${datadir}/man"
|
|
|
|
export docdir = "${datadir}/doc"
|
2015-07-30 11:33:11 +00:00
|
|
|
export systemd_unitdir = "${nonarch_base_libdir}/systemd"
|
|
|
|
export systemd_system_unitdir = "${nonarch_base_libdir}/systemd/system"
|
|
|
|
export nonarch_libdir = "${exec_prefix}/lib"
|
|
|
|
export systemd_user_unitdir = "${nonarch_libdir}/systemd/user"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
# Architecture dependent paths
|
2009-09-16 22:09:44 +00:00
|
|
|
export bindir = "${exec_prefix}/bin"
|
|
|
|
export sbindir = "${exec_prefix}/sbin"
|
2011-07-22 12:08:58 +00:00
|
|
|
export libdir = "${exec_prefix}/${baselib}"
|
2013-04-30 19:35:54 +00:00
|
|
|
export libexecdir = "${exec_prefix}/libexec"
|
2009-09-16 22:09:44 +00:00
|
|
|
export includedir = "${exec_prefix}/include"
|
|
|
|
export oldincludedir = "${exec_prefix}/include"
|
2012-09-24 19:00:41 +00:00
|
|
|
localedir = "${libdir}/locale"
|
2009-09-16 22:09:44 +00:00
|
|
|
|
2011-07-22 12:08:58 +00:00
|
|
|
# Linkage between native/cross/nativesdk layouts
|
2009-09-16 22:09:44 +00:00
|
|
|
base_bindir_native = "/bin"
|
|
|
|
base_sbindir_native = "/sbin"
|
|
|
|
sysconfdir_native = "/etc"
|
|
|
|
prefix_native = "/usr"
|
|
|
|
bindir_native = "${prefix_native}/bin"
|
|
|
|
sbindir_native = "${prefix_native}/sbin"
|
|
|
|
includedir_native = "${prefix_native}/include"
|
|
|
|
libdir_native = "${prefix_native}/lib"
|
2013-04-30 19:35:54 +00:00
|
|
|
libexecdir_native = "${prefix_native}/libexec"
|
2012-01-12 16:30:24 +00:00
|
|
|
base_libdir_native = "/lib"
|
2009-09-16 22:09:44 +00:00
|
|
|
datadir_native = "${prefix_native}/share"
|
|
|
|
bindir_cross = "/bin"
|
2011-01-18 08:17:58 +00:00
|
|
|
bindir_crossscripts = "${bindir}/crossscripts"
|
2010-07-02 13:35:08 +00:00
|
|
|
prefix_nativesdk = "/usr"
|
|
|
|
bindir_nativesdk = "${prefix_nativesdk}/bin"
|
2016-02-19 08:00:43 +00:00
|
|
|
sbindir_nativesdk = "${prefix_nativesdk}/sbin"
|
|
|
|
base_bindir_nativesdk = "/bin"
|
|
|
|
base_sbindir_nativesdk = "/sbin"
|
2011-08-25 02:25:55 +00:00
|
|
|
includedir_nativesdk = "${prefix_nativesdk}/include"
|
2010-07-02 13:35:08 +00:00
|
|
|
libdir_nativesdk = "${prefix_nativesdk}/lib"
|
2010-07-15 09:14:49 +00:00
|
|
|
base_libdir_nativesdk = "/lib"
|
2010-08-26 07:59:20 +00:00
|
|
|
localstatedir_nativesdk = "/var"
|
2009-09-16 22:09:44 +00:00
|
|
|
|
|
|
|
#
|
|
|
|
# Cross recipes need to know about the target layout
|
|
|
|
# := is used carefully here
|
|
|
|
#
|
|
|
|
target_datadir := "${datadir}"
|
2012-07-18 17:38:05 +00:00
|
|
|
# Used to find env/perl/python
|
|
|
|
USRBINPATH = "${bindir}"
|
|
|
|
USRBINPATH_class-native = "/usr/bin"
|
|
|
|
USRBINPATH_class-nativesdk = "/usr/bin"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2012-12-18 08:22:23 +00:00
|
|
|
# Root home directory
|
2013-05-10 06:47:39 +00:00
|
|
|
ROOT_HOME ??= "/home/root"
|
2012-12-18 08:22:23 +00:00
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Architecture-dependent build variables.
|
|
|
|
##################################################################
|
|
|
|
|
2015-05-26 10:42:26 +00:00
|
|
|
# Immediate expansion since there is no point in reapeatedly calling
|
|
|
|
# os.uname() throughout parsing
|
|
|
|
BUILD_ARCH := "${@os.uname()[4]}"
|
|
|
|
BUILD_OS := "${@os.uname()[0].lower()}"
|
2005-08-31 10:45:47 +00:00
|
|
|
BUILD_VENDOR = ""
|
|
|
|
BUILD_SYS = "${BUILD_ARCH}${BUILD_VENDOR}-${BUILD_OS}"
|
|
|
|
BUILD_PREFIX = ""
|
|
|
|
BUILD_CC_ARCH = ""
|
2011-07-27 22:31:28 +00:00
|
|
|
BUILD_LD_ARCH = ""
|
|
|
|
BUILD_AS_ARCH = ""
|
2009-07-02 13:30:04 +00:00
|
|
|
BUILD_EXEEXT = ""
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
HOST_ARCH = "${TARGET_ARCH}"
|
|
|
|
HOST_OS = "${TARGET_OS}"
|
|
|
|
HOST_VENDOR = "${TARGET_VENDOR}"
|
|
|
|
HOST_SYS = "${HOST_ARCH}${HOST_VENDOR}-${HOST_OS}"
|
|
|
|
HOST_PREFIX = "${TARGET_PREFIX}"
|
|
|
|
HOST_CC_ARCH = "${TARGET_CC_ARCH}"
|
2011-07-27 22:31:28 +00:00
|
|
|
HOST_LD_ARCH = "${TARGET_LD_ARCH}"
|
|
|
|
HOST_AS_ARCH = "${TARGET_AS_ARCH}"
|
2009-07-02 13:30:04 +00:00
|
|
|
HOST_EXEEXT = ""
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2011-07-22 13:15:20 +00:00
|
|
|
TUNE_ARCH ??= "INVALID"
|
2011-07-22 14:13:03 +00:00
|
|
|
TUNE_CCARGS ??= ""
|
2012-09-22 12:08:13 +00:00
|
|
|
TUNE_CCARGS[vardepvalue] = "${TUNE_CCARGS}"
|
2011-07-27 22:31:28 +00:00
|
|
|
TUNE_LDARGS ??= ""
|
|
|
|
TUNE_ASARGS ??= ""
|
2011-07-22 16:32:21 +00:00
|
|
|
TUNE_FEATURES ??= "${TUNE_FEATURES_tune-${DEFAULTTUNE}}"
|
2011-07-22 16:54:32 +00:00
|
|
|
LIBCEXTENSION ??= ""
|
|
|
|
ABIEXTENSION ??= ""
|
2015-08-24 22:18:38 +00:00
|
|
|
USE_NLS ??= "${@bb.utils.contains('DISTRO_FEATURES', 'libc-locale-code', 'yes', 'no', d)}"
|
2013-08-20 17:13:14 +00:00
|
|
|
SDKUSE_NLS ??= "yes"
|
2011-07-22 14:13:03 +00:00
|
|
|
|
2011-07-22 13:15:20 +00:00
|
|
|
TARGET_ARCH = "${TUNE_ARCH}"
|
2011-07-22 16:54:32 +00:00
|
|
|
TARGET_OS = "linux${LIBCEXTENSION}${ABIEXTENSION}"
|
2011-05-13 12:45:38 +00:00
|
|
|
TARGET_VENDOR = "-oe"
|
2016-12-14 21:13:04 +00:00
|
|
|
TARGET_SYS = "${TARGET_ARCH}${TARGET_VENDOR}${@['-' + d.getVar('TARGET_OS'), ''][d.getVar('TARGET_OS') == ('' or 'custom')]}"
|
2005-08-31 10:45:47 +00:00
|
|
|
TARGET_PREFIX = "${TARGET_SYS}-"
|
2011-07-22 14:13:03 +00:00
|
|
|
TARGET_CC_ARCH = "${TUNE_CCARGS}"
|
2011-07-27 22:31:28 +00:00
|
|
|
TARGET_LD_ARCH = "${TUNE_LDARGS}"
|
|
|
|
TARGET_AS_ARCH = "${TUNE_ASARGS}"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2016-09-22 12:24:30 +00:00
|
|
|
SDKMACHINE ??= "x86_64"
|
2009-09-17 00:00:45 +00:00
|
|
|
SDK_OS = "${BUILD_OS}"
|
2011-04-21 10:37:23 +00:00
|
|
|
SDK_VENDOR = "-oesdk"
|
2016-12-14 21:13:04 +00:00
|
|
|
SDK_SYS = "${SDK_ARCH}${SDK_VENDOR}${@['-' + d.getVar('SDK_OS'), ''][d.getVar('SDK_OS') == ('' or 'custom')]}"
|
2009-09-17 00:00:45 +00:00
|
|
|
SDK_PREFIX = "${SDK_SYS}-"
|
|
|
|
SDK_CC_ARCH = "${BUILD_CC_ARCH}"
|
2013-08-22 09:12:04 +00:00
|
|
|
SDKPKGSUFFIX = "nativesdk"
|
|
|
|
SDK_PACKAGE_ARCHS = "all any noarch ${SDK_ARCH}-${SDKPKGSUFFIX}"
|
2011-07-27 22:31:28 +00:00
|
|
|
SDK_LD_ARCH = "${BUILD_LD_ARCH}"
|
|
|
|
SDK_AS_ARCH = "${BUILD_AS_ARCH}"
|
2009-09-17 00:00:45 +00:00
|
|
|
|
2014-05-30 14:55:02 +00:00
|
|
|
TUNE_PKGARCH ??= ""
|
2014-08-19 12:31:22 +00:00
|
|
|
PACKAGE_ARCH ??= "${TUNE_PKGARCH}"
|
2016-12-14 21:13:04 +00:00
|
|
|
MACHINE_ARCH = "${@[d.getVar('TUNE_PKGARCH'), d.getVar('MACHINE')][bool(d.getVar('MACHINE'))].replace('-', '_')}"
|
2011-07-22 16:32:21 +00:00
|
|
|
PACKAGE_EXTRA_ARCHS ??= "${PACKAGE_EXTRA_ARCHS_tune-${DEFAULTTUNE}}"
|
2011-03-15 20:11:17 +00:00
|
|
|
PACKAGE_ARCHS = "all any noarch ${PACKAGE_EXTRA_ARCHS} ${MACHINE_ARCH}"
|
2011-04-08 16:10:31 +00:00
|
|
|
# MACHINE_ARCH shouldn't be included here as a variable dependency
|
|
|
|
# since machine specific packages are handled using multimachine
|
|
|
|
PACKAGE_ARCHS[vardepsexclude] = "MACHINE_ARCH"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2011-06-22 15:10:16 +00:00
|
|
|
MULTIMACH_TARGET_SYS = "${PACKAGE_ARCH}${TARGET_VENDOR}-${TARGET_OS}"
|
2008-07-17 20:49:48 +00:00
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Date/time variables.
|
|
|
|
##################################################################
|
|
|
|
|
|
|
|
DATE := "${@time.strftime('%Y%m%d',time.gmtime())}"
|
|
|
|
TIME := "${@time.strftime('%H%M%S',time.gmtime())}"
|
|
|
|
DATETIME = "${DATE}${TIME}"
|
|
|
|
|
2006-02-10 11:45:39 +00:00
|
|
|
##################################################################
|
|
|
|
# Openembedded Software Prerequisites.
|
|
|
|
##################################################################
|
|
|
|
|
2015-08-23 02:38:55 +00:00
|
|
|
# python-native should be here but python relies on building
|
2006-02-10 11:45:39 +00:00
|
|
|
# its own in staging
|
2007-12-18 15:04:06 +00:00
|
|
|
ASSUME_PROVIDED = "\
|
|
|
|
bzip2-native \
|
2012-10-02 13:12:21 +00:00
|
|
|
chrpath-native \
|
2015-10-16 21:49:26 +00:00
|
|
|
file-native \
|
2016-02-22 16:23:49 +00:00
|
|
|
findutils-native \
|
2012-07-10 13:26:18 +00:00
|
|
|
git-native \
|
2007-12-18 15:04:06 +00:00
|
|
|
grep-native \
|
|
|
|
diffstat-native \
|
|
|
|
patch-native \
|
2016-03-05 08:29:17 +00:00
|
|
|
libgcc-native \
|
2016-01-07 11:39:39 +00:00
|
|
|
hostperl-runtime-native \
|
2016-01-13 08:03:04 +00:00
|
|
|
hostpython-runtime-native \
|
2008-04-11 13:19:21 +00:00
|
|
|
tar-native \
|
2009-11-05 20:04:54 +00:00
|
|
|
virtual/libintl-native \
|
2016-01-08 16:25:04 +00:00
|
|
|
virtual/libiconv-native \
|
2014-08-18 06:24:02 +00:00
|
|
|
texinfo-native \
|
|
|
|
bash-native \
|
2015-04-09 19:58:53 +00:00
|
|
|
sed-native \
|
2016-01-25 13:38:00 +00:00
|
|
|
wget-native \
|
2007-12-18 15:04:06 +00:00
|
|
|
"
|
2012-10-02 13:12:21 +00:00
|
|
|
# gzip-native should be listed above?
|
2006-02-10 11:45:39 +00:00
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Package default variables.
|
|
|
|
##################################################################
|
|
|
|
|
2015-06-18 14:14:16 +00:00
|
|
|
PN = "${@bb.parse.BBHandler.vars_from_file(d.getVar('FILE', False),d)[0] or 'defaultpkgname'}"
|
|
|
|
PV = "${@bb.parse.BBHandler.vars_from_file(d.getVar('FILE', False),d)[1] or '1.0'}"
|
|
|
|
PR = "${@bb.parse.BBHandler.vars_from_file(d.getVar('FILE', False),d)[2] or 'r0'}"
|
2016-01-22 12:03:17 +00:00
|
|
|
PE = ""
|
2007-05-31 22:51:19 +00:00
|
|
|
PF = "${PN}-${EXTENDPE}${PV}-${PR}"
|
2016-12-14 21:13:04 +00:00
|
|
|
EXTENDPE = "${@['','${PE}_'][int(d.getVar('PE') or 0) > 0]}"
|
2005-08-31 10:45:47 +00:00
|
|
|
P = "${PN}-${PV}"
|
|
|
|
|
2016-01-22 12:03:17 +00:00
|
|
|
PRAUTO = ""
|
2016-12-14 21:13:04 +00:00
|
|
|
EXTENDPRAUTO = "${@['.${PRAUTO}', ''][not d.getVar('PRAUTO')]}"
|
2011-05-27 06:31:46 +00:00
|
|
|
PRAUTOINX = "${PF}"
|
|
|
|
|
|
|
|
PKGV ?= "${PV}"
|
|
|
|
PKGR ?= "${PR}${EXTENDPRAUTO}"
|
2016-12-14 21:13:04 +00:00
|
|
|
PKGE ?= "${@['','${PE}'][int(d.getVar('PE') or 0) > 0]}"
|
|
|
|
EXTENDPKGEVER = "${@['','${PKGE}:'][d.getVar('PKGE').strip() != '']}"
|
2011-05-27 06:31:46 +00:00
|
|
|
EXTENDPKGV ?= "${EXTENDPKGEVER}${PKGV}-${PKGR}"
|
|
|
|
|
2009-01-02 10:15:45 +00:00
|
|
|
# Base package name
|
|
|
|
# Automatically derives "foo" from "foo-native", "foo-cross" or "foo-initial"
|
|
|
|
# otherwise it is the same as PN and P
|
2011-12-22 17:43:33 +00:00
|
|
|
SPECIAL_PKGSUFFIX = "-native -cross -initial -intermediate -crosssdk -cross-canadian"
|
2016-12-14 21:13:04 +00:00
|
|
|
BPN = "${@base_prune_suffix(d.getVar('PN'), d.getVar('SPECIAL_PKGSUFFIX').split(), d)}"
|
2009-01-02 10:15:45 +00:00
|
|
|
BP = "${BPN}-${PV}"
|
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
# Package info.
|
|
|
|
|
|
|
|
SECTION = "base"
|
|
|
|
PRIORITY = "optional"
|
2011-02-02 15:16:47 +00:00
|
|
|
SUMMARY ?= "${PN} version ${PV}-${PR}"
|
2013-12-28 19:46:08 +00:00
|
|
|
DESCRIPTION ?= "${SUMMARY}."
|
2011-02-02 15:16:47 +00:00
|
|
|
|
|
|
|
# The following two are commented out because they result in a recursive
|
|
|
|
# definition of the variable in some corner cases. These are left in
|
|
|
|
# to illustrate the intended behavior.
|
|
|
|
#SUMMARY_${PN} ?= "${SUMMARY}"
|
|
|
|
#DESCRIPTION_${PN} ?= "${DESCRIPTION}"
|
|
|
|
|
|
|
|
SUMMARY_${PN}-dbg ?= "${SUMMARY} - Debugging files"
|
|
|
|
DESCRIPTION_${PN}-dbg ?= "${DESCRIPTION} \
|
|
|
|
This package contains ELF symbols and related sources for debugging purposes."
|
|
|
|
|
|
|
|
SUMMARY_${PN}-dev ?= "${SUMMARY} - Development files"
|
|
|
|
DESCRIPTION_${PN}-dev ?= "${DESCRIPTION} \
|
2011-05-26 16:13:50 +00:00
|
|
|
This package contains symbolic links, header files, and \
|
2011-02-02 15:16:47 +00:00
|
|
|
related items necessary for software development."
|
|
|
|
|
2011-05-26 16:13:50 +00:00
|
|
|
SUMMARY_${PN}-staticdev ?= "${SUMMARY} - Development files (Static Libraries)"
|
|
|
|
DESCRIPTION_${PN}-staticdev?= "${DESCRIPTION} \
|
|
|
|
This package contains static libraries for software development."
|
|
|
|
|
2011-02-02 15:16:47 +00:00
|
|
|
SUMMARY_${PN}-doc ?= "${SUMMARY} - Documentation files"
|
|
|
|
DESCRIPTION_${PN}-doc ?= "${DESCRIPTION} \
|
|
|
|
This package contains documentation."
|
|
|
|
|
2016-04-27 02:20:27 +00:00
|
|
|
LICENSE ??= "INVALID"
|
2011-04-21 10:38:41 +00:00
|
|
|
MAINTAINER = "OE-Core Developers <openembedded-core@lists.openembedded.org>"
|
2014-02-06 13:33:45 +00:00
|
|
|
HOMEPAGE = ""
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
# Package dependencies and provides.
|
|
|
|
|
2006-09-21 16:29:02 +00:00
|
|
|
# Ensure that -dev packages recommend the corresponding -dev packages of their
|
|
|
|
# deps, and the same for -dbg.
|
|
|
|
DEPCHAIN_PRE = ""
|
|
|
|
DEPCHAIN_POST = "-dev -dbg"
|
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
DEPENDS = ""
|
|
|
|
RDEPENDS = ""
|
|
|
|
PROVIDES = ""
|
2013-09-09 14:14:39 +00:00
|
|
|
PROVIDES_prepend = "${PN} "
|
2005-08-31 10:45:47 +00:00
|
|
|
RPROVIDES = ""
|
|
|
|
|
2011-12-22 17:43:33 +00:00
|
|
|
MULTI_PROVIDER_WHITELIST = "virtual/libintl virtual/libintl-native virtual/nativesdk-libintl virtual/xserver virtual/update-alternatives-native virtual/update-alternatives"
|
2007-09-01 14:38:51 +00:00
|
|
|
|
2008-02-11 23:01:28 +00:00
|
|
|
SOLIBS = ".so.*"
|
2013-08-22 10:24:57 +00:00
|
|
|
SOLIBS_darwin = ".dylib"
|
2008-05-05 22:19:28 +00:00
|
|
|
|
2008-02-11 23:01:28 +00:00
|
|
|
SOLIBSDEV = ".so"
|
2013-08-22 10:24:57 +00:00
|
|
|
# Due to the ordering of PACKAGES and the naming of the dev symlinks on darwin,
|
|
|
|
# we can't make the symlinks end up in the -dev packages easily at this point. This hack
|
|
|
|
# at least means builds aren't completely broken and symlinks don't take up much space.
|
|
|
|
SOLIBSDEV_darwin = ".dylibbroken"
|
2008-02-11 23:01:28 +00:00
|
|
|
|
2012-06-28 20:33:42 +00:00
|
|
|
PACKAGE_BEFORE_PN ?= ""
|
|
|
|
PACKAGES = "${PN}-dbg ${PN}-staticdev ${PN}-dev ${PN}-doc ${PN}-locale ${PACKAGE_BEFORE_PN} ${PN}"
|
2012-10-12 10:46:38 +00:00
|
|
|
PACKAGES_DYNAMIC = "^${PN}-locale-.*"
|
2005-08-31 10:45:47 +00:00
|
|
|
FILES = ""
|
2006-12-19 21:18:11 +00:00
|
|
|
|
2008-02-11 23:01:28 +00:00
|
|
|
FILES_${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*${SOLIBS} \
|
2005-08-31 10:45:47 +00:00
|
|
|
${sysconfdir} ${sharedstatedir} ${localstatedir} \
|
2009-07-02 13:30:04 +00:00
|
|
|
${base_bindir}/* ${base_sbindir}/* \
|
|
|
|
${base_libdir}/*${SOLIBS} \
|
2016-07-21 09:03:30 +00:00
|
|
|
${base_prefix}/lib/udev ${prefix}/lib/udev \
|
|
|
|
${base_libdir}/udev ${libdir}/udev \
|
2011-08-25 08:29:09 +00:00
|
|
|
${datadir}/${BPN} ${libdir}/${BPN}/* \
|
2005-08-31 10:45:47 +00:00
|
|
|
${datadir}/pixmaps ${datadir}/applications \
|
|
|
|
${datadir}/idl ${datadir}/omf ${datadir}/sounds \
|
|
|
|
${libdir}/bonobo/servers"
|
2006-12-19 21:18:11 +00:00
|
|
|
|
2012-06-06 08:16:39 +00:00
|
|
|
FILES_${PN}-bin = "${bindir}/* ${sbindir}/*"
|
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
FILES_${PN}-doc = "${docdir} ${mandir} ${infodir} ${datadir}/gtk-doc \
|
|
|
|
${datadir}/gnome/help"
|
2006-12-19 21:18:11 +00:00
|
|
|
SECTION_${PN}-doc = "doc"
|
|
|
|
|
2012-06-05 11:52:21 +00:00
|
|
|
FILES_SOLIBSDEV ?= "${base_libdir}/lib*${SOLIBSDEV} ${libdir}/lib*${SOLIBSDEV}"
|
|
|
|
FILES_${PN}-dev = "${includedir} ${FILES_SOLIBSDEV} ${libdir}/*.la \
|
2011-05-26 16:13:50 +00:00
|
|
|
${libdir}/*.o ${libdir}/pkgconfig ${datadir}/pkgconfig \
|
2012-06-05 11:52:21 +00:00
|
|
|
${datadir}/aclocal ${base_libdir}/*.o \
|
|
|
|
${libdir}/${BPN}/*.la ${base_libdir}/*.la"
|
2006-12-19 21:18:11 +00:00
|
|
|
SECTION_${PN}-dev = "devel"
|
|
|
|
ALLOW_EMPTY_${PN}-dev = "1"
|
2011-05-27 06:31:46 +00:00
|
|
|
RDEPENDS_${PN}-dev = "${PN} (= ${EXTENDPKGV})"
|
2006-12-19 21:18:11 +00:00
|
|
|
|
2012-03-14 07:57:57 +00:00
|
|
|
FILES_${PN}-staticdev = "${libdir}/*.a ${base_libdir}/*.a ${libdir}/${BPN}/*.a"
|
2011-05-26 16:13:50 +00:00
|
|
|
SECTION_${PN}-staticdev = "devel"
|
|
|
|
RDEPENDS_${PN}-staticdev = "${PN}-dev (= ${EXTENDPKGV})"
|
|
|
|
|
2015-12-15 15:40:23 +00:00
|
|
|
FILES_${PN}-dbg = "/usr/lib/debug /usr/src/debug"
|
2011-02-09 03:46:47 +00:00
|
|
|
|
2006-12-19 21:18:11 +00:00
|
|
|
SECTION_${PN}-dbg = "devel"
|
|
|
|
ALLOW_EMPTY_${PN}-dbg = "1"
|
|
|
|
|
2006-11-20 17:13:43 +00:00
|
|
|
FILES_${PN}-locale = "${datadir}/locale"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
# File manifest
|
|
|
|
|
2015-06-18 14:14:16 +00:00
|
|
|
FILE_DIRNAME = "${@os.path.dirname(d.getVar('FILE', False))}"
|
2009-01-02 10:15:45 +00:00
|
|
|
# FILESPATH is set in base.bbclass
|
|
|
|
#FILESPATH = "${FILE_DIRNAME}/${PF}:${FILE_DIRNAME}/${P}:${FILE_DIRNAME}/${PN}:${FILE_DIRNAME}/${BP}:${FILE_DIRNAME}/${BPN}:${FILE_DIRNAME}/files:${FILE_DIRNAME}"
|
2014-07-23 03:33:01 +00:00
|
|
|
# This default was only used for checking
|
|
|
|
FILESEXTRAPATHS ?= "__default:"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# General work and output directories for the build system.
|
|
|
|
##################################################################
|
|
|
|
|
2008-11-14 10:45:49 +00:00
|
|
|
TMPDIR ?= "${TOPDIR}/tmp"
|
2016-12-14 21:13:04 +00:00
|
|
|
CACHE = "${TMPDIR}/cache${@['', '/' + str(d.getVar('MACHINE'))][bool(d.getVar('MACHINE'))]}${@['', '/' + str(d.getVar('SDKMACHINE'))][bool(d.getVar('SDKMACHINE'))]}"
|
2009-05-31 21:23:30 +00:00
|
|
|
# The persistent cache should be shared by all builds
|
2013-03-02 17:18:15 +00:00
|
|
|
PERSISTENT_DIR = "${TOPDIR}/cache"
|
2010-05-28 17:48:34 +00:00
|
|
|
LOG_DIR = "${TMPDIR}/log"
|
2008-07-19 14:19:47 +00:00
|
|
|
CO_DIR = "${DL_DIR}"
|
|
|
|
CVSDIR = "${CO_DIR}/cvs"
|
|
|
|
SVNDIR = "${CO_DIR}/svn"
|
2011-02-07 00:58:44 +00:00
|
|
|
GITDIR = "${CO_DIR}/git2"
|
2008-07-19 14:19:47 +00:00
|
|
|
BZRDIR = "${CO_DIR}/bzr"
|
2009-07-02 13:30:04 +00:00
|
|
|
HGDIR = "${CO_DIR}/hg"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2013-01-29 13:16:28 +00:00
|
|
|
STAMPS_DIR ?= "${TMPDIR}/stamps"
|
|
|
|
STAMP = "${STAMPS_DIR}/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"
|
|
|
|
STAMPCLEAN = "${STAMPS_DIR}/${MULTIMACH_TARGET_SYS}/${PN}/*-*"
|
2013-09-19 10:03:42 +00:00
|
|
|
BASE_WORKDIR ?= "${TMPDIR}/work"
|
|
|
|
WORKDIR = "${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}/${PN}/${EXTENDPE}${PV}-${PR}"
|
2005-08-31 10:45:47 +00:00
|
|
|
T = "${WORKDIR}/temp"
|
|
|
|
D = "${WORKDIR}/image"
|
2009-01-02 10:15:45 +00:00
|
|
|
S = "${WORKDIR}/${BP}"
|
2005-08-31 10:45:47 +00:00
|
|
|
B = "${S}"
|
|
|
|
|
2009-11-10 14:55:23 +00:00
|
|
|
STAGING_DIR = "${TMPDIR}/sysroots"
|
2017-05-03 21:13:38 +00:00
|
|
|
COMPONENTS_DIR = "${STAGING_DIR}-components"
|
Switch to Recipe Specific Sysroots
This patch is comparatively large and invasive. It does only do one thing, switching the
system to build using recipe specific sysroots and where changes could be isolated from it,
that has been done.
With the current single sysroot approach, its possible for software to find things which
aren't in their dependencies. This leads to a determinism problem and is a growing issue in
several of the market segments where OE makes sense. The way to solve this problem for OE is
to have seperate sysroots for each recipe and these will only contain the dependencies for
that recipe.
Its worth noting that this is not task specific sysroots and that OE's dependencies do vary
enormously by task. This did result in some implementation challenges. There is nothing stopping
the implementation of task specific sysroots at some later point based on this work but
that as deemed a bridge too far right now.
Implementation details:
* Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in
TMPDIR/sysroot-components/PACKAGE_ARCH/PN.
* WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files
from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and
RECIPE_SYSROOT_NATIVE.
* This construction is primarily done by a new do_prepare_recipe_sysroot task which runs
before do_configure and consists of a call to the extend_recipe_sysroot function.
* Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native
and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies
for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot
dependencies.
* We have to do a search/replace 'fixme' operation on the files installed into the sysroot to
change hardcoded paths into the correct ones. We create a fixmepath file in the component
directory which lists the files which need this operation.
* Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each
time a new loader is added. These are handled by adding files in bindir with the name
prefixed by "postinst-" and are run in each sysroot as its created if they're present.
This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them.
* Since a recipe can have multiple tasks and these tasks can run against each other at the same
time we have to have a lock when we perform write operations against the sysroot. We also have
to maintain manifests of what we install against a task checksum of the dependency. If the
checksum changes, we remove its files and then add the new ones.
* The autotools logic for filtering the view of m4 files is no longer needed (and was the model
for the way extend_recipe_sysroot works).
* For autotools, we used to build a combined m4 macros directory which had both the native and
target m4 files. We can no longer do this so we use the target sysroot as the default and add
the native sysroot as an extra backup include path. If we don't do this, we'd have to build
target pkg-config before we could built anything using pkg-config for example (ditto gettext).
Such dependencies would be painful so we haven't required that.
* PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy
for each machine. The paths therefore changed, the behaviour did not.
* The ccache class had to be reworked to function with rss.
* The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data
does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal
recipe name therefore remains a bad idea.
* The logic in insane needed tweaks to deal with the new path layout, as did the debug source
file extraction code in package.bbclass.
* The logic in sstate.bbclass had to be rewritten since it previously only performed search and
replace on extracted sstate and we now need this to happen even if the compiled path was
"correct". This in theory could cause a mild performance issue but since the sysroot data
was the main data that needed this and we'd have to do it there regardless with rss, I've opted
just to change the way the class for everything. The built output used to build the sstate output
is now retained and installed rather than deleted.
* The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold
up against testing. This has been rewritten too. There are some assumptions made about paths, we
save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is
here works but is a little hardcoded and an area for future improvement.
* In order to work with eSDK we need a way to build something that looks like the old style sysroot.
"bitbake build-sysroots" will construct such a sysroot based on everything in the components
directory that matches the current MACHINE. It will allow transition of external tools and can
built target or native variants or both. It also supports a clean task. I'd suggest not relying on
this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have
to have built that in a previous bitbake invocation.
* pseudo is run out of its components directory. This is fine as its statically linked.
* The hacks for wayland to see allarch dependencies in the multilib case are no longer needed
and can be dropped.
* wic needed more extensive changes to work with rss and the fixes are in a separate commit series
* Various oe-selftest tweaks were needed since tests did assume the location to binaries and the
combined sysroot in several cases.
* Most missing dependencies this work found have been sent out as separate patches as they were found
but a few tweaks are still included here.
* A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib
sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my
hand. That implementation can probably be neater but this is on the list of things to cleanup later
at this point.
In summary, the impact people will likely see after this change:
* Recipes may fail with missing dependencies, particularly native tools like gettext-native,
glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors
* Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst
* There was a separate patch series dealing with roots postinst native dependency issues. Any postinst
which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS.
There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest
and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean
we've found all the issues.
Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the
task logfiles, not the console so I've intentionally left this like that for now. We can turn it down
easily enough in due course.
(From OE-Core rev: 809746f56df4b91af014bf6a3f28997d6698ac78)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-07 13:54:35 +00:00
|
|
|
RECIPE_SYSROOT = "${WORKDIR}/recipe-sysroot"
|
|
|
|
RECIPE_SYSROOT_NATIVE = "${WORKDIR}/recipe-sysroot-native"
|
2007-10-29 14:55:48 +00:00
|
|
|
|
Switch to Recipe Specific Sysroots
This patch is comparatively large and invasive. It does only do one thing, switching the
system to build using recipe specific sysroots and where changes could be isolated from it,
that has been done.
With the current single sysroot approach, its possible for software to find things which
aren't in their dependencies. This leads to a determinism problem and is a growing issue in
several of the market segments where OE makes sense. The way to solve this problem for OE is
to have seperate sysroots for each recipe and these will only contain the dependencies for
that recipe.
Its worth noting that this is not task specific sysroots and that OE's dependencies do vary
enormously by task. This did result in some implementation challenges. There is nothing stopping
the implementation of task specific sysroots at some later point based on this work but
that as deemed a bridge too far right now.
Implementation details:
* Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in
TMPDIR/sysroot-components/PACKAGE_ARCH/PN.
* WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files
from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and
RECIPE_SYSROOT_NATIVE.
* This construction is primarily done by a new do_prepare_recipe_sysroot task which runs
before do_configure and consists of a call to the extend_recipe_sysroot function.
* Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native
and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies
for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot
dependencies.
* We have to do a search/replace 'fixme' operation on the files installed into the sysroot to
change hardcoded paths into the correct ones. We create a fixmepath file in the component
directory which lists the files which need this operation.
* Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each
time a new loader is added. These are handled by adding files in bindir with the name
prefixed by "postinst-" and are run in each sysroot as its created if they're present.
This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them.
* Since a recipe can have multiple tasks and these tasks can run against each other at the same
time we have to have a lock when we perform write operations against the sysroot. We also have
to maintain manifests of what we install against a task checksum of the dependency. If the
checksum changes, we remove its files and then add the new ones.
* The autotools logic for filtering the view of m4 files is no longer needed (and was the model
for the way extend_recipe_sysroot works).
* For autotools, we used to build a combined m4 macros directory which had both the native and
target m4 files. We can no longer do this so we use the target sysroot as the default and add
the native sysroot as an extra backup include path. If we don't do this, we'd have to build
target pkg-config before we could built anything using pkg-config for example (ditto gettext).
Such dependencies would be painful so we haven't required that.
* PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy
for each machine. The paths therefore changed, the behaviour did not.
* The ccache class had to be reworked to function with rss.
* The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data
does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal
recipe name therefore remains a bad idea.
* The logic in insane needed tweaks to deal with the new path layout, as did the debug source
file extraction code in package.bbclass.
* The logic in sstate.bbclass had to be rewritten since it previously only performed search and
replace on extracted sstate and we now need this to happen even if the compiled path was
"correct". This in theory could cause a mild performance issue but since the sysroot data
was the main data that needed this and we'd have to do it there regardless with rss, I've opted
just to change the way the class for everything. The built output used to build the sstate output
is now retained and installed rather than deleted.
* The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold
up against testing. This has been rewritten too. There are some assumptions made about paths, we
save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is
here works but is a little hardcoded and an area for future improvement.
* In order to work with eSDK we need a way to build something that looks like the old style sysroot.
"bitbake build-sysroots" will construct such a sysroot based on everything in the components
directory that matches the current MACHINE. It will allow transition of external tools and can
built target or native variants or both. It also supports a clean task. I'd suggest not relying on
this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have
to have built that in a previous bitbake invocation.
* pseudo is run out of its components directory. This is fine as its statically linked.
* The hacks for wayland to see allarch dependencies in the multilib case are no longer needed
and can be dropped.
* wic needed more extensive changes to work with rss and the fixes are in a separate commit series
* Various oe-selftest tweaks were needed since tests did assume the location to binaries and the
combined sysroot in several cases.
* Most missing dependencies this work found have been sent out as separate patches as they were found
but a few tweaks are still included here.
* A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib
sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my
hand. That implementation can probably be neater but this is on the list of things to cleanup later
at this point.
In summary, the impact people will likely see after this change:
* Recipes may fail with missing dependencies, particularly native tools like gettext-native,
glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors
* Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst
* There was a separate patch series dealing with roots postinst native dependency issues. Any postinst
which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS.
There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest
and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean
we've found all the issues.
Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the
task logfiles, not the console so I've intentionally left this like that for now. We can turn it down
easily enough in due course.
(From OE-Core rev: 809746f56df4b91af014bf6a3f28997d6698ac78)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-07 13:54:35 +00:00
|
|
|
STAGING_DIR_NATIVE = "${RECIPE_SYSROOT_NATIVE}"
|
2009-09-16 22:09:44 +00:00
|
|
|
STAGING_BINDIR_NATIVE = "${STAGING_DIR_NATIVE}${bindir_native}"
|
2010-04-16 10:32:14 +00:00
|
|
|
STAGING_BINDIR_CROSS = "${STAGING_BINDIR}/crossscripts"
|
2014-04-27 00:23:07 +00:00
|
|
|
STAGING_BINDIR_TOOLCHAIN = "${STAGING_DIR_NATIVE}${bindir_native}/${TARGET_ARCH}${TARGET_VENDOR}-${TARGET_OS}"
|
2009-09-16 22:09:44 +00:00
|
|
|
STAGING_LIBDIR_NATIVE = "${STAGING_DIR_NATIVE}${libdir_native}"
|
2012-10-15 22:19:10 +00:00
|
|
|
STAGING_LIBEXECDIR_NATIVE = "${STAGING_DIR_NATIVE}${libexecdir_native}"
|
2012-01-12 16:30:24 +00:00
|
|
|
STAGING_BASE_LIBDIR_NATIVE = "${STAGING_DIR_NATIVE}${base_libdir_native}"
|
native.bbclass: Properly define directories
For most users this commit will have no effect. But if you come across the idea of giving
different names for paths, you'll get some troubles.
When a recipe inherit native, properly define bindir, sbindir, includedir, sysconfdir, datadir
(using xxxdir_native definitions from meta/conf/bitbake.conf).
For example, edit "${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}/quilt-native/temp/log.do_configure"
and see what are the arguments given by oe_runconf.
Notice that ${docdir}, ${mandir}, ${infodir}, ${localstatedir} have no associated _native definition.
(From OE-Core rev: 15345ddd4be6a0b041b3d6caaad48d46b22142e9)
Signed-off-by: Matthieu Crapet <Matthieu.Crapet@ingenico.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-12 15:49:32 +00:00
|
|
|
STAGING_SBINDIR_NATIVE = "${STAGING_DIR_NATIVE}${sbindir_native}"
|
2009-09-16 22:09:44 +00:00
|
|
|
STAGING_INCDIR_NATIVE = "${STAGING_DIR_NATIVE}${includedir_native}"
|
|
|
|
STAGING_ETCDIR_NATIVE = "${STAGING_DIR_NATIVE}${sysconfdir_native}"
|
|
|
|
STAGING_DATADIR_NATIVE = "${STAGING_DIR_NATIVE}${datadir_native}"
|
2007-10-29 14:55:48 +00:00
|
|
|
|
Switch to Recipe Specific Sysroots
This patch is comparatively large and invasive. It does only do one thing, switching the
system to build using recipe specific sysroots and where changes could be isolated from it,
that has been done.
With the current single sysroot approach, its possible for software to find things which
aren't in their dependencies. This leads to a determinism problem and is a growing issue in
several of the market segments where OE makes sense. The way to solve this problem for OE is
to have seperate sysroots for each recipe and these will only contain the dependencies for
that recipe.
Its worth noting that this is not task specific sysroots and that OE's dependencies do vary
enormously by task. This did result in some implementation challenges. There is nothing stopping
the implementation of task specific sysroots at some later point based on this work but
that as deemed a bridge too far right now.
Implementation details:
* Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in
TMPDIR/sysroot-components/PACKAGE_ARCH/PN.
* WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files
from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and
RECIPE_SYSROOT_NATIVE.
* This construction is primarily done by a new do_prepare_recipe_sysroot task which runs
before do_configure and consists of a call to the extend_recipe_sysroot function.
* Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native
and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies
for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot
dependencies.
* We have to do a search/replace 'fixme' operation on the files installed into the sysroot to
change hardcoded paths into the correct ones. We create a fixmepath file in the component
directory which lists the files which need this operation.
* Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each
time a new loader is added. These are handled by adding files in bindir with the name
prefixed by "postinst-" and are run in each sysroot as its created if they're present.
This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them.
* Since a recipe can have multiple tasks and these tasks can run against each other at the same
time we have to have a lock when we perform write operations against the sysroot. We also have
to maintain manifests of what we install against a task checksum of the dependency. If the
checksum changes, we remove its files and then add the new ones.
* The autotools logic for filtering the view of m4 files is no longer needed (and was the model
for the way extend_recipe_sysroot works).
* For autotools, we used to build a combined m4 macros directory which had both the native and
target m4 files. We can no longer do this so we use the target sysroot as the default and add
the native sysroot as an extra backup include path. If we don't do this, we'd have to build
target pkg-config before we could built anything using pkg-config for example (ditto gettext).
Such dependencies would be painful so we haven't required that.
* PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy
for each machine. The paths therefore changed, the behaviour did not.
* The ccache class had to be reworked to function with rss.
* The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data
does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal
recipe name therefore remains a bad idea.
* The logic in insane needed tweaks to deal with the new path layout, as did the debug source
file extraction code in package.bbclass.
* The logic in sstate.bbclass had to be rewritten since it previously only performed search and
replace on extracted sstate and we now need this to happen even if the compiled path was
"correct". This in theory could cause a mild performance issue but since the sysroot data
was the main data that needed this and we'd have to do it there regardless with rss, I've opted
just to change the way the class for everything. The built output used to build the sstate output
is now retained and installed rather than deleted.
* The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold
up against testing. This has been rewritten too. There are some assumptions made about paths, we
save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is
here works but is a little hardcoded and an area for future improvement.
* In order to work with eSDK we need a way to build something that looks like the old style sysroot.
"bitbake build-sysroots" will construct such a sysroot based on everything in the components
directory that matches the current MACHINE. It will allow transition of external tools and can
built target or native variants or both. It also supports a clean task. I'd suggest not relying on
this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have
to have built that in a previous bitbake invocation.
* pseudo is run out of its components directory. This is fine as its statically linked.
* The hacks for wayland to see allarch dependencies in the multilib case are no longer needed
and can be dropped.
* wic needed more extensive changes to work with rss and the fixes are in a separate commit series
* Various oe-selftest tweaks were needed since tests did assume the location to binaries and the
combined sysroot in several cases.
* Most missing dependencies this work found have been sent out as separate patches as they were found
but a few tweaks are still included here.
* A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib
sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my
hand. That implementation can probably be neater but this is on the list of things to cleanup later
at this point.
In summary, the impact people will likely see after this change:
* Recipes may fail with missing dependencies, particularly native tools like gettext-native,
glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors
* Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst
* There was a separate patch series dealing with roots postinst native dependency issues. Any postinst
which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS.
There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest
and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean
we've found all the issues.
Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the
task logfiles, not the console so I've intentionally left this like that for now. We can turn it down
easily enough in due course.
(From OE-Core rev: 809746f56df4b91af014bf6a3f28997d6698ac78)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-07 13:54:35 +00:00
|
|
|
STAGING_DIR_HOST = "${RECIPE_SYSROOT}"
|
2009-09-16 22:09:44 +00:00
|
|
|
STAGING_BINDIR = "${STAGING_DIR_HOST}${bindir}"
|
|
|
|
STAGING_LIBDIR = "${STAGING_DIR_HOST}${libdir}"
|
2012-10-15 22:19:10 +00:00
|
|
|
STAGING_LIBEXECDIR = "${STAGING_DIR_HOST}${libexecdir}"
|
2012-04-23 21:45:36 +00:00
|
|
|
STAGING_BASELIBDIR = "${STAGING_DIR_HOST}${base_libdir}"
|
2009-09-16 22:09:44 +00:00
|
|
|
STAGING_INCDIR = "${STAGING_DIR_HOST}${includedir}"
|
|
|
|
STAGING_DATADIR = "${STAGING_DIR_HOST}${datadir}"
|
|
|
|
STAGING_EXECPREFIXDIR = "${STAGING_DIR_HOST}${exec_prefix}"
|
2007-10-29 14:55:48 +00:00
|
|
|
STAGING_LOADER_DIR = "${STAGING_DIR_HOST}/loader"
|
|
|
|
STAGING_FIRMWARE_DIR = "${STAGING_DIR_HOST}/firmware"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
Switch to Recipe Specific Sysroots
This patch is comparatively large and invasive. It does only do one thing, switching the
system to build using recipe specific sysroots and where changes could be isolated from it,
that has been done.
With the current single sysroot approach, its possible for software to find things which
aren't in their dependencies. This leads to a determinism problem and is a growing issue in
several of the market segments where OE makes sense. The way to solve this problem for OE is
to have seperate sysroots for each recipe and these will only contain the dependencies for
that recipe.
Its worth noting that this is not task specific sysroots and that OE's dependencies do vary
enormously by task. This did result in some implementation challenges. There is nothing stopping
the implementation of task specific sysroots at some later point based on this work but
that as deemed a bridge too far right now.
Implementation details:
* Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in
TMPDIR/sysroot-components/PACKAGE_ARCH/PN.
* WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files
from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and
RECIPE_SYSROOT_NATIVE.
* This construction is primarily done by a new do_prepare_recipe_sysroot task which runs
before do_configure and consists of a call to the extend_recipe_sysroot function.
* Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native
and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies
for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot
dependencies.
* We have to do a search/replace 'fixme' operation on the files installed into the sysroot to
change hardcoded paths into the correct ones. We create a fixmepath file in the component
directory which lists the files which need this operation.
* Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each
time a new loader is added. These are handled by adding files in bindir with the name
prefixed by "postinst-" and are run in each sysroot as its created if they're present.
This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them.
* Since a recipe can have multiple tasks and these tasks can run against each other at the same
time we have to have a lock when we perform write operations against the sysroot. We also have
to maintain manifests of what we install against a task checksum of the dependency. If the
checksum changes, we remove its files and then add the new ones.
* The autotools logic for filtering the view of m4 files is no longer needed (and was the model
for the way extend_recipe_sysroot works).
* For autotools, we used to build a combined m4 macros directory which had both the native and
target m4 files. We can no longer do this so we use the target sysroot as the default and add
the native sysroot as an extra backup include path. If we don't do this, we'd have to build
target pkg-config before we could built anything using pkg-config for example (ditto gettext).
Such dependencies would be painful so we haven't required that.
* PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy
for each machine. The paths therefore changed, the behaviour did not.
* The ccache class had to be reworked to function with rss.
* The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data
does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal
recipe name therefore remains a bad idea.
* The logic in insane needed tweaks to deal with the new path layout, as did the debug source
file extraction code in package.bbclass.
* The logic in sstate.bbclass had to be rewritten since it previously only performed search and
replace on extracted sstate and we now need this to happen even if the compiled path was
"correct". This in theory could cause a mild performance issue but since the sysroot data
was the main data that needed this and we'd have to do it there regardless with rss, I've opted
just to change the way the class for everything. The built output used to build the sstate output
is now retained and installed rather than deleted.
* The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold
up against testing. This has been rewritten too. There are some assumptions made about paths, we
save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is
here works but is a little hardcoded and an area for future improvement.
* In order to work with eSDK we need a way to build something that looks like the old style sysroot.
"bitbake build-sysroots" will construct such a sysroot based on everything in the components
directory that matches the current MACHINE. It will allow transition of external tools and can
built target or native variants or both. It also supports a clean task. I'd suggest not relying on
this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have
to have built that in a previous bitbake invocation.
* pseudo is run out of its components directory. This is fine as its statically linked.
* The hacks for wayland to see allarch dependencies in the multilib case are no longer needed
and can be dropped.
* wic needed more extensive changes to work with rss and the fixes are in a separate commit series
* Various oe-selftest tweaks were needed since tests did assume the location to binaries and the
combined sysroot in several cases.
* Most missing dependencies this work found have been sent out as separate patches as they were found
but a few tweaks are still included here.
* A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib
sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my
hand. That implementation can probably be neater but this is on the list of things to cleanup later
at this point.
In summary, the impact people will likely see after this change:
* Recipes may fail with missing dependencies, particularly native tools like gettext-native,
glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors
* Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst
* There was a separate patch series dealing with roots postinst native dependency issues. Any postinst
which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS.
There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest
and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean
we've found all the issues.
Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the
task logfiles, not the console so I've intentionally left this like that for now. We can turn it down
easily enough in due course.
(From OE-Core rev: 809746f56df4b91af014bf6a3f28997d6698ac78)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-07 13:54:35 +00:00
|
|
|
STAGING_DIR_TARGET = "${RECIPE_SYSROOT}"
|
2007-10-29 14:55:48 +00:00
|
|
|
|
2009-07-02 13:30:04 +00:00
|
|
|
# Setting DEPLOY_DIR outside of TMPDIR is helpful, when you are using
|
|
|
|
# packaged staging and/or multimachine.
|
|
|
|
DEPLOY_DIR ?= "${TMPDIR}/deploy"
|
2005-08-31 10:45:47 +00:00
|
|
|
DEPLOY_DIR_TAR = "${DEPLOY_DIR}/tar"
|
|
|
|
DEPLOY_DIR_IPK = "${DEPLOY_DIR}/ipk"
|
|
|
|
DEPLOY_DIR_RPM = "${DEPLOY_DIR}/rpm"
|
2006-09-19 09:04:09 +00:00
|
|
|
DEPLOY_DIR_DEB = "${DEPLOY_DIR}/deb"
|
2013-09-12 11:04:52 +00:00
|
|
|
DEPLOY_DIR_IMAGE ?= "${DEPLOY_DIR}/images/${MACHINE}"
|
2007-08-08 21:02:39 +00:00
|
|
|
DEPLOY_DIR_TOOLS = "${DEPLOY_DIR}/tools"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
Switch to Recipe Specific Sysroots
This patch is comparatively large and invasive. It does only do one thing, switching the
system to build using recipe specific sysroots and where changes could be isolated from it,
that has been done.
With the current single sysroot approach, its possible for software to find things which
aren't in their dependencies. This leads to a determinism problem and is a growing issue in
several of the market segments where OE makes sense. The way to solve this problem for OE is
to have seperate sysroots for each recipe and these will only contain the dependencies for
that recipe.
Its worth noting that this is not task specific sysroots and that OE's dependencies do vary
enormously by task. This did result in some implementation challenges. There is nothing stopping
the implementation of task specific sysroots at some later point based on this work but
that as deemed a bridge too far right now.
Implementation details:
* Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in
TMPDIR/sysroot-components/PACKAGE_ARCH/PN.
* WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files
from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and
RECIPE_SYSROOT_NATIVE.
* This construction is primarily done by a new do_prepare_recipe_sysroot task which runs
before do_configure and consists of a call to the extend_recipe_sysroot function.
* Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native
and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies
for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot
dependencies.
* We have to do a search/replace 'fixme' operation on the files installed into the sysroot to
change hardcoded paths into the correct ones. We create a fixmepath file in the component
directory which lists the files which need this operation.
* Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each
time a new loader is added. These are handled by adding files in bindir with the name
prefixed by "postinst-" and are run in each sysroot as its created if they're present.
This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them.
* Since a recipe can have multiple tasks and these tasks can run against each other at the same
time we have to have a lock when we perform write operations against the sysroot. We also have
to maintain manifests of what we install against a task checksum of the dependency. If the
checksum changes, we remove its files and then add the new ones.
* The autotools logic for filtering the view of m4 files is no longer needed (and was the model
for the way extend_recipe_sysroot works).
* For autotools, we used to build a combined m4 macros directory which had both the native and
target m4 files. We can no longer do this so we use the target sysroot as the default and add
the native sysroot as an extra backup include path. If we don't do this, we'd have to build
target pkg-config before we could built anything using pkg-config for example (ditto gettext).
Such dependencies would be painful so we haven't required that.
* PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy
for each machine. The paths therefore changed, the behaviour did not.
* The ccache class had to be reworked to function with rss.
* The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data
does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal
recipe name therefore remains a bad idea.
* The logic in insane needed tweaks to deal with the new path layout, as did the debug source
file extraction code in package.bbclass.
* The logic in sstate.bbclass had to be rewritten since it previously only performed search and
replace on extracted sstate and we now need this to happen even if the compiled path was
"correct". This in theory could cause a mild performance issue but since the sysroot data
was the main data that needed this and we'd have to do it there regardless with rss, I've opted
just to change the way the class for everything. The built output used to build the sstate output
is now retained and installed rather than deleted.
* The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold
up against testing. This has been rewritten too. There are some assumptions made about paths, we
save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is
here works but is a little hardcoded and an area for future improvement.
* In order to work with eSDK we need a way to build something that looks like the old style sysroot.
"bitbake build-sysroots" will construct such a sysroot based on everything in the components
directory that matches the current MACHINE. It will allow transition of external tools and can
built target or native variants or both. It also supports a clean task. I'd suggest not relying on
this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have
to have built that in a previous bitbake invocation.
* pseudo is run out of its components directory. This is fine as its statically linked.
* The hacks for wayland to see allarch dependencies in the multilib case are no longer needed
and can be dropped.
* wic needed more extensive changes to work with rss and the fixes are in a separate commit series
* Various oe-selftest tweaks were needed since tests did assume the location to binaries and the
combined sysroot in several cases.
* Most missing dependencies this work found have been sent out as separate patches as they were found
but a few tweaks are still included here.
* A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib
sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my
hand. That implementation can probably be neater but this is on the list of things to cleanup later
at this point.
In summary, the impact people will likely see after this change:
* Recipes may fail with missing dependencies, particularly native tools like gettext-native,
glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors
* Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst
* There was a separate patch series dealing with roots postinst native dependency issues. Any postinst
which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS.
There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest
and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean
we've found all the issues.
Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the
task logfiles, not the console so I've intentionally left this like that for now. We can turn it down
easily enough in due course.
(From OE-Core rev: 809746f56df4b91af014bf6a3f28997d6698ac78)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-07 13:54:35 +00:00
|
|
|
PKGDATA_DIR = "${TMPDIR}/pkgdata/${MACHINE}"
|
2007-08-21 10:40:55 +00:00
|
|
|
|
2012-02-26 07:49:41 +00:00
|
|
|
##################################################################
|
2012-07-01 09:32:40 +00:00
|
|
|
# SDK variables.
|
2012-02-26 07:49:41 +00:00
|
|
|
##################################################################
|
|
|
|
|
2012-03-23 22:30:40 +00:00
|
|
|
SDK_NAME_PREFIX ?= "oecore"
|
|
|
|
SDK_NAME = "${SDK_NAME_PREFIX}-${SDK_ARCH}-${TUNE_PKGARCH}"
|
2012-02-26 07:49:41 +00:00
|
|
|
SDKPATH = "/usr/local/${SDK_NAME_PREFIX}-${SDK_ARCH}"
|
2010-07-02 13:35:08 +00:00
|
|
|
SDKPATHNATIVE = "${SDKPATH}/sysroots/${SDK_SYS}"
|
2007-06-27 14:13:23 +00:00
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Kernel info.
|
|
|
|
##################################################################
|
|
|
|
|
2016-05-11 17:35:21 +00:00
|
|
|
OLDEST_KERNEL = "3.2.0"
|
2015-07-15 07:58:02 +00:00
|
|
|
OLDEST_KERNEL_aarch64 = "3.14"
|
2016-05-11 17:35:39 +00:00
|
|
|
OLDEST_KERNEL_nios2 = "3.19"
|
|
|
|
|
2016-11-01 03:24:23 +00:00
|
|
|
# SDK_OLDEST_KERNEL can't be set using overrides since there are
|
|
|
|
# none for the SDK architecture. Best to set it from a machine-sdk
|
|
|
|
# include file if you need an SDK arch-specific value
|
|
|
|
SDK_OLDEST_KERNEL = "3.2.0"
|
|
|
|
|
2016-05-19 11:05:50 +00:00
|
|
|
# Define where the kernel headers are installed on the target as well as where
|
|
|
|
# they are staged.
|
|
|
|
KERNEL_SRC_PATH = "/usr/src/kernel"
|
|
|
|
|
kernel: move source and build output to work-shared
commit 3b3f7e785e279 [kernel: Rearrange for 1.8] began the process of
moving the kernel source and build artefacts out of sstate control and
into a shared location.
This changed triggered some workflow issues, as well as bugs related
to the kernel source containing build output, and hence being dirty and
breaking kernel rebuilds.
To solve these issues, and to make it clear that the kernel is not under
sstate control, we move the source and build outputs to:
work-shared/MACHINE/kernel-source
work-shared/MACHINE/kernel-build-artifacts
Where kernel-build-artifacts is the kernel build output and
kernel-source is kept "pristine". The build-artifacts contain everything
that is required to build external modules against the kernel source,
and includes the defconfig, the kernel-abiversion, System.map files and
output from "make scripts".
External module builds should either pass O= on the command line, or
set KBUILD_OUTPUT to point to the build-artifacts. module-base.bbclass
takes care of setting KBUILD_OUTPUT, so most existing external module
recipes are transparently adapted to the new source/build layout.
recipes that depend on the kernel source must have a depedency on the
do_shared_workdir task:
do_configure[depends] += "virtual/kernel:do_shared_workdir"
With this dependency added, the STAGING_KERNEL_DIR will be populated and
available to the rest of the build.
(From OE-Core rev: 6a1ff0e7eacef595738f2fed086986fd622ec32a)
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-01-15 11:54:15 +00:00
|
|
|
STAGING_KERNEL_DIR = "${TMPDIR}/work-shared/${MACHINE}/kernel-source"
|
|
|
|
STAGING_KERNEL_BUILDDIR = "${TMPDIR}/work-shared/${MACHINE}/kernel-build-artifacts"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Specific image creation and rootfs population info.
|
|
|
|
##################################################################
|
|
|
|
|
2009-08-12 09:01:25 +00:00
|
|
|
IMAGE_ROOTFS = "${WORKDIR}/rootfs"
|
2007-09-05 07:51:00 +00:00
|
|
|
IMAGE_BASENAME = "${PN}"
|
2005-08-31 10:45:47 +00:00
|
|
|
IMAGE_NAME = "${IMAGE_BASENAME}-${MACHINE}-${DATETIME}"
|
2012-09-26 13:56:05 +00:00
|
|
|
IMAGE_NAME[vardepsexclude] += "DATETIME"
|
2006-08-29 22:12:42 +00:00
|
|
|
IMAGE_LINK_NAME = "${IMAGE_BASENAME}-${MACHINE}"
|
2010-09-08 23:25:25 +00:00
|
|
|
|
2011-05-26 18:32:06 +00:00
|
|
|
# This option allows for a percentage overage of the actual image size rather than a
|
|
|
|
# fixed extra space, this is space needed for initial startup and basic operations.
|
2012-02-26 12:45:47 +00:00
|
|
|
IMAGE_OVERHEAD_FACTOR ?= "1.3"
|
2015-08-23 02:38:55 +00:00
|
|
|
# This option allows for adding additional space in K above and beyond what the
|
2011-05-26 18:32:06 +00:00
|
|
|
# IMAGE_OVERHEAD_FACTOR might add. This space is for additional packages, user data, ...
|
2012-07-01 09:32:40 +00:00
|
|
|
# To set a fixed size then overriding IMAGE_ROOTFS_SIZE with the max size one wants
|
2011-05-26 18:32:06 +00:00
|
|
|
# should do the trick
|
|
|
|
IMAGE_ROOTFS_EXTRA_SPACE ?= "0"
|
2010-09-08 23:25:25 +00:00
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
EXTRA_IMAGEDEPENDS = ""
|
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Toolchain info.
|
|
|
|
##################################################################
|
|
|
|
|
2013-10-06 13:01:33 +00:00
|
|
|
PATH_prepend = "${COREBASE}/scripts:${STAGING_BINDIR_TOOLCHAIN}:${STAGING_BINDIR_CROSS}:${STAGING_DIR_NATIVE}${sbindir_native}:${STAGING_BINDIR_NATIVE}:${STAGING_DIR_NATIVE}${base_sbindir_native}:${STAGING_DIR_NATIVE}${base_bindir_native}:"
|
2008-05-21 18:51:07 +00:00
|
|
|
export PATH
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Build utility info.
|
|
|
|
##################################################################
|
|
|
|
|
2017-04-28 15:01:01 +00:00
|
|
|
# Directory where host tools are copied
|
|
|
|
HOSTTOOLS_DIR = "${TMPDIR}/hosttools"
|
|
|
|
|
2017-03-09 00:14:38 +00:00
|
|
|
# Tools needed to run builds with OE-Core
|
|
|
|
HOSTTOOLS += " \
|
2017-03-28 03:51:23 +00:00
|
|
|
[ ar as awk basename bash bzip2 cat chgrp chmod chown chrpath cmp cp cpio \
|
|
|
|
cpp cut date dd diff diffstat dirname du echo egrep env expand expr false \
|
|
|
|
fgrep file find flock g++ gawk gcc getconf getopt git grep gunzip gzip \
|
|
|
|
head hostname install ld ldd ln ls make makeinfo md5sum mkdir mknod \
|
2017-04-27 13:28:40 +00:00
|
|
|
mktemp mv nm objcopy objdump od patch perl pod2man pr printf pwd python python2 \
|
2017-04-14 08:05:55 +00:00
|
|
|
python2.7 python3 ranlib readelf readlink rm rmdir rpcgen sed sh sha256sum \
|
|
|
|
sleep sort split stat strings strip tail tar tee test touch tr true uname \
|
|
|
|
uniq wc wget which xargs \
|
2017-03-09 00:14:38 +00:00
|
|
|
"
|
|
|
|
|
|
|
|
# Tools needed to run testimage runtime image testing
|
2017-03-28 03:51:23 +00:00
|
|
|
HOSTTOOLS += "ip ping ps scp ssh stty"
|
2017-03-09 00:14:38 +00:00
|
|
|
|
|
|
|
# Link to these if present
|
2017-03-29 13:45:49 +00:00
|
|
|
HOSTTOOLS_NONFATAL += "aws ccache gcc-ar gpg ld.bfd ld.gold nc sftp socat sudo"
|
2017-03-09 00:14:38 +00:00
|
|
|
|
2017-03-16 16:41:13 +00:00
|
|
|
# Temporary add few more detected in bitbake world
|
|
|
|
HOSTTOOLS_NONFATAL += "join nl size yes zcat"
|
|
|
|
|
2017-09-13 15:49:11 +00:00
|
|
|
# Used by bzr fetcher
|
|
|
|
HOSTTOOLS_NONFATAL += "bzr"
|
|
|
|
|
2012-05-29 12:29:44 +00:00
|
|
|
CCACHE ??= ""
|
2012-06-25 09:31:19 +00:00
|
|
|
# Disable ccache explicitly if CCACHE is null since gcc may be a symlink
|
|
|
|
# of ccache some distributions (e.g., Fedora 17).
|
2016-12-14 21:13:04 +00:00
|
|
|
export CCACHE_DISABLE ??= "${@[0,1][d.getVar('CCACHE') == '']}"
|
2016-06-20 12:13:09 +00:00
|
|
|
# ccache < 3.1.10 will create CCACHE_DIR on startup even if disabled, and
|
|
|
|
# autogen sets HOME=/dev/null so in certain situations builds can fail.
|
|
|
|
# Explicitly export CCACHE_DIR until we can assume ccache >3.1.10 on the host.
|
|
|
|
export CCACHE_DIR ??= "${@os.getenv('HOME')}/.ccache"
|
2012-06-25 09:31:19 +00:00
|
|
|
|
2010-08-12 12:28:50 +00:00
|
|
|
TOOLCHAIN_OPTIONS = " --sysroot=${STAGING_DIR_TARGET}"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2007-11-22 18:05:06 +00:00
|
|
|
export CC = "${CCACHE}${HOST_PREFIX}gcc ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
|
|
|
|
export CXX = "${CCACHE}${HOST_PREFIX}g++ ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
|
2013-12-05 00:49:12 +00:00
|
|
|
export FC = "${CCACHE}${HOST_PREFIX}gfortran ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}"
|
2011-07-27 22:31:28 +00:00
|
|
|
export CPP = "${HOST_PREFIX}gcc -E${TOOLCHAIN_OPTIONS} ${HOST_CC_ARCH}"
|
|
|
|
export LD = "${HOST_PREFIX}ld${TOOLCHAIN_OPTIONS} ${HOST_LD_ARCH}"
|
2005-08-31 10:45:47 +00:00
|
|
|
export CCLD = "${CC}"
|
|
|
|
export AR = "${HOST_PREFIX}ar"
|
2011-07-27 22:31:28 +00:00
|
|
|
export AS = "${HOST_PREFIX}as ${HOST_AS_ARCH}"
|
2005-08-31 10:45:47 +00:00
|
|
|
export RANLIB = "${HOST_PREFIX}ranlib"
|
|
|
|
export STRIP = "${HOST_PREFIX}strip"
|
2006-07-24 08:35:37 +00:00
|
|
|
export OBJCOPY = "${HOST_PREFIX}objcopy"
|
2007-08-08 21:02:39 +00:00
|
|
|
export OBJDUMP = "${HOST_PREFIX}objdump"
|
2013-05-10 10:53:12 +00:00
|
|
|
export STRINGS = "${HOST_PREFIX}strings"
|
2011-02-01 21:15:54 +00:00
|
|
|
export NM = "${HOST_PREFIX}nm"
|
2016-08-01 16:02:55 +00:00
|
|
|
export READELF = "${HOST_PREFIX}readelf"
|
2007-08-01 11:23:51 +00:00
|
|
|
PYTHON = "${@sys.executable}"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
export BUILD_CC = "${CCACHE}${BUILD_PREFIX}gcc ${BUILD_CC_ARCH}"
|
|
|
|
export BUILD_CXX = "${CCACHE}${BUILD_PREFIX}g++ ${BUILD_CC_ARCH}"
|
2013-12-05 00:49:12 +00:00
|
|
|
export BUILD_FC = "${CCACHE}${BUILD_PREFIX}gfortran ${BUILD_CC_ARCH}"
|
2014-10-21 10:50:13 +00:00
|
|
|
export BUILD_CPP = "${BUILD_PREFIX}gcc ${BUILD_CC_ARCH} -E"
|
2011-07-27 22:31:28 +00:00
|
|
|
export BUILD_LD = "${BUILD_PREFIX}ld ${BUILD_LD_ARCH}"
|
|
|
|
export BUILD_CCLD = "${BUILD_PREFIX}gcc ${BUILD_CC_ARCH}"
|
2005-08-31 10:45:47 +00:00
|
|
|
export BUILD_AR = "${BUILD_PREFIX}ar"
|
2011-07-27 22:31:28 +00:00
|
|
|
export BUILD_AS = "${BUILD_PREFIX}as ${BUILD_AS_ARCH}"
|
2005-08-31 10:45:47 +00:00
|
|
|
export BUILD_RANLIB = "${BUILD_PREFIX}ranlib"
|
|
|
|
export BUILD_STRIP = "${BUILD_PREFIX}strip"
|
2011-02-01 21:15:54 +00:00
|
|
|
export BUILD_NM = "${BUILD_PREFIX}nm"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
export MAKE = "make"
|
2016-02-02 14:49:47 +00:00
|
|
|
EXTRA_OEMAKE = ""
|
2011-05-05 16:57:56 +00:00
|
|
|
EXTRA_OECONF = ""
|
2016-05-21 11:30:11 +00:00
|
|
|
export LC_ALL = "en_US.UTF-8"
|
2011-02-02 11:55:34 +00:00
|
|
|
|
2006-08-28 20:36:36 +00:00
|
|
|
##################################################################
|
|
|
|
# Patch handling.
|
|
|
|
##################################################################
|
2015-08-24 22:18:39 +00:00
|
|
|
PATCHTOOL = "quilt"
|
|
|
|
PATCHRESOLVE = "noop"
|
2006-08-28 20:36:36 +00:00
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Build flags and options.
|
|
|
|
##################################################################
|
|
|
|
|
2007-10-29 14:55:48 +00:00
|
|
|
export BUILD_CPPFLAGS = "-isystem${STAGING_INCDIR_NATIVE}"
|
2016-05-11 17:35:28 +00:00
|
|
|
BUILDSDK_CPPFLAGS = ""
|
2005-08-31 10:45:47 +00:00
|
|
|
export CPPFLAGS = "${TARGET_CPPFLAGS}"
|
2007-11-12 11:28:14 +00:00
|
|
|
export TARGET_CPPFLAGS = ""
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
export BUILD_CFLAGS = "${BUILD_CPPFLAGS} ${BUILD_OPTIMIZATION}"
|
2008-01-17 14:28:56 +00:00
|
|
|
BUILDSDK_CFLAGS = "${BUILDSDK_CPPFLAGS} ${BUILD_OPTIMIZATION}"
|
2005-08-31 10:45:47 +00:00
|
|
|
export CFLAGS = "${TARGET_CFLAGS}"
|
2007-11-23 10:04:14 +00:00
|
|
|
export TARGET_CFLAGS = "${TARGET_CPPFLAGS} ${SELECTED_OPTIMIZATION}"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2014-03-02 17:38:33 +00:00
|
|
|
export BUILD_CXXFLAGS = "${BUILD_CFLAGS}"
|
2005-08-31 10:45:47 +00:00
|
|
|
export CXXFLAGS = "${TARGET_CXXFLAGS}"
|
2014-03-02 17:38:33 +00:00
|
|
|
export TARGET_CXXFLAGS = "${TARGET_CFLAGS}"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2007-10-29 14:55:48 +00:00
|
|
|
export BUILD_LDFLAGS = "-L${STAGING_LIBDIR_NATIVE} \
|
2012-01-12 16:30:24 +00:00
|
|
|
-L${STAGING_BASE_LIBDIR_NATIVE} \
|
2007-10-29 14:55:48 +00:00
|
|
|
-Wl,-rpath-link,${STAGING_LIBDIR_NATIVE} \
|
2012-01-12 16:30:24 +00:00
|
|
|
-Wl,-rpath-link,${STAGING_BASE_LIBDIR_NATIVE} \
|
|
|
|
-Wl,-rpath,${STAGING_LIBDIR_NATIVE} \
|
|
|
|
-Wl,-rpath,${STAGING_BASE_LIBDIR_NATIVE} \
|
|
|
|
-Wl,-O1"
|
2008-01-17 10:40:36 +00:00
|
|
|
|
2016-06-22 06:24:16 +00:00
|
|
|
BUILDSDK_LDFLAGS = "-Wl,-O1"
|
2008-01-17 10:40:36 +00:00
|
|
|
|
2011-08-16 22:17:33 +00:00
|
|
|
LINKER_HASH_STYLE ??= "gnu"
|
|
|
|
# mips does not support GNU hash style therefore we override
|
2016-11-08 17:12:24 +00:00
|
|
|
LINKER_HASH_STYLE_mipsarch = "sysv"
|
2016-10-04 11:31:18 +00:00
|
|
|
|
2016-12-14 21:13:04 +00:00
|
|
|
TARGET_LINK_HASH_STYLE ?= "${@['-Wl,--hash-style=gnu',''][d.getVar('LINKER_HASH_STYLE') != 'gnu']}"
|
2011-08-16 22:17:33 +00:00
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
export LDFLAGS = "${TARGET_LDFLAGS}"
|
2011-01-07 16:01:56 +00:00
|
|
|
export TARGET_LDFLAGS = "-Wl,-O1 ${TARGET_LINK_HASH_STYLE}"
|
2009-09-16 22:09:44 +00:00
|
|
|
#export TARGET_LDFLAGS = "-L${STAGING_DIR_TARGET}${libdir} \
|
|
|
|
# -Wl,-rpath-link,${STAGING_DIR_TARGET}${libdir} \
|
2007-11-12 11:28:14 +00:00
|
|
|
# -Wl,-O1"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2011-09-29 22:48:20 +00:00
|
|
|
# Pass parallel make options to the compile task
|
2008-06-02 13:04:33 +00:00
|
|
|
EXTRA_OEMAKE_prepend_task-compile = "${PARALLEL_MAKE} "
|
2011-09-29 22:48:20 +00:00
|
|
|
PARALLEL_MAKEINST ??= "${PARALLEL_MAKE}"
|
|
|
|
# Pass parallel make options to the install task
|
|
|
|
EXTRA_OEMAKE_prepend_task-install = "${PARALLEL_MAKEINST} "
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Optimization flags.
|
|
|
|
##################################################################
|
2016-07-28 10:56:06 +00:00
|
|
|
DEBUG_PREFIX_MAP ?= "-fdebug-prefix-map=${WORKDIR}=/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR} \
|
|
|
|
-fdebug-prefix-map=${STAGING_DIR_NATIVE}= \
|
|
|
|
-fdebug-prefix-map=${STAGING_DIR_HOST}= \
|
2016-02-16 09:14:55 +00:00
|
|
|
"
|
2016-07-28 10:56:06 +00:00
|
|
|
DEBUG_FLAGS ?= "-g -feliminate-unused-debug-types ${DEBUG_PREFIX_MAP}"
|
2016-02-16 09:14:55 +00:00
|
|
|
|
2011-03-29 12:47:40 +00:00
|
|
|
# Disabled until the option works properly -feliminate-dwarf2-dups
|
2011-03-17 23:54:30 +00:00
|
|
|
FULL_OPTIMIZATION = "-O2 -pipe ${DEBUG_FLAGS}"
|
|
|
|
DEBUG_OPTIMIZATION = "-O -fno-omit-frame-pointer ${DEBUG_FLAGS} -pipe"
|
2017-01-05 21:15:08 +00:00
|
|
|
SELECTED_OPTIMIZATION = "${@d.getVar(['FULL_OPTIMIZATION', 'DEBUG_OPTIMIZATION'][d.getVar('DEBUG_BUILD') == '1'])}"
|
2011-11-16 21:17:21 +00:00
|
|
|
SELECTED_OPTIMIZATION[vardeps] += "FULL_OPTIMIZATION DEBUG_OPTIMIZATION"
|
2011-03-17 23:54:30 +00:00
|
|
|
BUILD_OPTIMIZATION = "-O2 -pipe"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2015-02-20 17:44:05 +00:00
|
|
|
##################################################################
|
|
|
|
# Settings used by bitbake-layers.
|
|
|
|
##################################################################
|
|
|
|
BBLAYERS_LAYERINDEX_URL ??= "http://layers.openembedded.org/layerindex/"
|
|
|
|
BBLAYERS_FETCH_DIR ??= "${COREBASE}"
|
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Download locations and utilities.
|
|
|
|
##################################################################
|
|
|
|
|
2016-04-29 10:48:24 +00:00
|
|
|
APACHE_MIRROR = "http://archive.apache.org/dist"
|
2017-05-09 16:19:21 +00:00
|
|
|
DEBIAN_MIRROR = "http://ftp.debian.org/debian/pool"
|
2009-07-02 13:30:04 +00:00
|
|
|
GENTOO_MIRROR = "http://distfiles.gentoo.org/distfiles"
|
|
|
|
GNOME_GIT = "git://git.gnome.org"
|
|
|
|
GNOME_MIRROR = "http://ftp.gnome.org/pub/GNOME/sources"
|
2015-03-09 10:51:11 +00:00
|
|
|
GNU_MIRROR = "http://ftp.gnu.org/gnu"
|
2016-05-25 06:40:26 +00:00
|
|
|
GNUPG_MIRROR = "https://www.gnupg.org/ftp/gcrypt"
|
2006-11-20 17:13:43 +00:00
|
|
|
GPE_MIRROR = "http://gpe.linuxtogo.org/download/source"
|
2017-02-16 09:06:24 +00:00
|
|
|
KERNELORG_MIRROR = "http://cdn.kernel.org/pub"
|
2009-07-02 13:30:04 +00:00
|
|
|
SOURCEFORGE_MIRROR = "http://downloads.sourceforge.net"
|
2005-08-31 10:45:47 +00:00
|
|
|
XLIBS_MIRROR = "http://xlibs.freedesktop.org/release"
|
2006-02-10 11:45:39 +00:00
|
|
|
XORG_MIRROR = "http://xorg.freedesktop.org/releases"
|
2014-05-08 03:44:04 +00:00
|
|
|
SAVANNAH_GNU_MIRROR = "http://download.savannah.gnu.org/releases"
|
|
|
|
SAVANNAH_NONGNU_MIRROR = "http://download.savannah.nongnu.org/releases"
|
2014-05-21 04:47:29 +00:00
|
|
|
CPAN_MIRROR = "http://search.cpan.org/CPAN"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2015-08-31 19:08:01 +00:00
|
|
|
SRC_URI[vardepsexclude] += "\
|
|
|
|
APACHE_MIRROR \
|
|
|
|
CPAN_MIRROR \
|
|
|
|
DEBIAN_MIRROR \
|
|
|
|
GENTOO_MIRROR \
|
|
|
|
GNOME_GIT \
|
|
|
|
GNOME_MIRROR \
|
|
|
|
GNU_MIRROR \
|
2016-05-25 06:40:26 +00:00
|
|
|
GNUPG_MIRROR \
|
2015-08-31 19:08:01 +00:00
|
|
|
GPE_MIRROR \
|
|
|
|
KERNELORG_MIRROR \
|
|
|
|
SAVANNAH_GNU_MIRROR \
|
|
|
|
SAVANNAH_NONGNU_MIRROR \
|
|
|
|
SOURCEFORGE_MIRROR \
|
|
|
|
XLIBS_MIRROR \
|
|
|
|
XORG_MIRROR \
|
|
|
|
"
|
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
# You can use the mirror of your country to get faster downloads by putting
|
2017-05-09 16:19:21 +00:00
|
|
|
# export DEBIAN_MIRROR = "http://ftp.de.debian.org/debian/pool"
|
2005-08-31 10:45:47 +00:00
|
|
|
# into your local.conf
|
|
|
|
|
2012-09-04 09:09:11 +00:00
|
|
|
FETCHCMD_svn = "/usr/bin/env svn --non-interactive --trust-server-cert"
|
2007-07-10 14:05:14 +00:00
|
|
|
FETCHCMD_cvs = "/usr/bin/env cvs"
|
2012-07-09 16:47:01 +00:00
|
|
|
FETCHCMD_wget = "/usr/bin/env wget -t 2 -T 30 -nv --passive-ftp --no-check-certificate"
|
2007-09-05 07:51:00 +00:00
|
|
|
FETCHCMD_bzr = "/usr/bin/env bzr"
|
2008-09-07 10:47:54 +00:00
|
|
|
FETCHCMD_hg = "/usr/bin/env hg"
|
2007-07-10 14:05:14 +00:00
|
|
|
|
2006-02-10 11:45:39 +00:00
|
|
|
SRCDATE = "${DATE}"
|
2011-04-21 10:39:34 +00:00
|
|
|
SRCREV ??= "INVALID"
|
2011-02-14 07:57:59 +00:00
|
|
|
AUTOREV = "${@bb.fetch2.get_autorev(d)}"
|
2016-02-02 14:10:46 +00:00
|
|
|
# Set Dynamically in base.bbclass
|
|
|
|
# SRCPV = "${@bb.fetch2.get_srcrev(d)}"
|
2012-09-14 08:41:59 +00:00
|
|
|
SRCPV[vardepvalue] = "${SRCPV}"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2012-03-08 02:51:10 +00:00
|
|
|
SRC_URI = ""
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2011-04-21 11:26:25 +00:00
|
|
|
# Use pseudo as the fakeroot implementation
|
2010-08-04 13:45:10 +00:00
|
|
|
PSEUDO_LOCALSTATEDIR ?= "${WORKDIR}/pseudo/"
|
Switch to Recipe Specific Sysroots
This patch is comparatively large and invasive. It does only do one thing, switching the
system to build using recipe specific sysroots and where changes could be isolated from it,
that has been done.
With the current single sysroot approach, its possible for software to find things which
aren't in their dependencies. This leads to a determinism problem and is a growing issue in
several of the market segments where OE makes sense. The way to solve this problem for OE is
to have seperate sysroots for each recipe and these will only contain the dependencies for
that recipe.
Its worth noting that this is not task specific sysroots and that OE's dependencies do vary
enormously by task. This did result in some implementation challenges. There is nothing stopping
the implementation of task specific sysroots at some later point based on this work but
that as deemed a bridge too far right now.
Implementation details:
* Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in
TMPDIR/sysroot-components/PACKAGE_ARCH/PN.
* WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files
from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and
RECIPE_SYSROOT_NATIVE.
* This construction is primarily done by a new do_prepare_recipe_sysroot task which runs
before do_configure and consists of a call to the extend_recipe_sysroot function.
* Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native
and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies
for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot
dependencies.
* We have to do a search/replace 'fixme' operation on the files installed into the sysroot to
change hardcoded paths into the correct ones. We create a fixmepath file in the component
directory which lists the files which need this operation.
* Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each
time a new loader is added. These are handled by adding files in bindir with the name
prefixed by "postinst-" and are run in each sysroot as its created if they're present.
This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them.
* Since a recipe can have multiple tasks and these tasks can run against each other at the same
time we have to have a lock when we perform write operations against the sysroot. We also have
to maintain manifests of what we install against a task checksum of the dependency. If the
checksum changes, we remove its files and then add the new ones.
* The autotools logic for filtering the view of m4 files is no longer needed (and was the model
for the way extend_recipe_sysroot works).
* For autotools, we used to build a combined m4 macros directory which had both the native and
target m4 files. We can no longer do this so we use the target sysroot as the default and add
the native sysroot as an extra backup include path. If we don't do this, we'd have to build
target pkg-config before we could built anything using pkg-config for example (ditto gettext).
Such dependencies would be painful so we haven't required that.
* PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy
for each machine. The paths therefore changed, the behaviour did not.
* The ccache class had to be reworked to function with rss.
* The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data
does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal
recipe name therefore remains a bad idea.
* The logic in insane needed tweaks to deal with the new path layout, as did the debug source
file extraction code in package.bbclass.
* The logic in sstate.bbclass had to be rewritten since it previously only performed search and
replace on extracted sstate and we now need this to happen even if the compiled path was
"correct". This in theory could cause a mild performance issue but since the sysroot data
was the main data that needed this and we'd have to do it there regardless with rss, I've opted
just to change the way the class for everything. The built output used to build the sstate output
is now retained and installed rather than deleted.
* The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold
up against testing. This has been rewritten too. There are some assumptions made about paths, we
save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is
here works but is a little hardcoded and an area for future improvement.
* In order to work with eSDK we need a way to build something that looks like the old style sysroot.
"bitbake build-sysroots" will construct such a sysroot based on everything in the components
directory that matches the current MACHINE. It will allow transition of external tools and can
built target or native variants or both. It also supports a clean task. I'd suggest not relying on
this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have
to have built that in a previous bitbake invocation.
* pseudo is run out of its components directory. This is fine as its statically linked.
* The hacks for wayland to see allarch dependencies in the multilib case are no longer needed
and can be dropped.
* wic needed more extensive changes to work with rss and the fixes are in a separate commit series
* Various oe-selftest tweaks were needed since tests did assume the location to binaries and the
combined sysroot in several cases.
* Most missing dependencies this work found have been sent out as separate patches as they were found
but a few tweaks are still included here.
* A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib
sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my
hand. That implementation can probably be neater but this is on the list of things to cleanup later
at this point.
In summary, the impact people will likely see after this change:
* Recipes may fail with missing dependencies, particularly native tools like gettext-native,
glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors
* Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst
* There was a separate patch series dealing with roots postinst native dependency issues. Any postinst
which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS.
There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest
and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean
we've found all the issues.
Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the
task logfiles, not the console so I've intentionally left this like that for now. We can turn it down
easily enough in due course.
(From OE-Core rev: 809746f56df4b91af014bf6a3f28997d6698ac78)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-07 13:54:35 +00:00
|
|
|
PSEUDO_PASSWD ?= "${STAGING_DIR_TARGET}:${PSEUDO_SYSROOT}"
|
2017-05-03 21:13:38 +00:00
|
|
|
PSEUDO_SYSROOT = "${COMPONENTS_DIR}/${BUILD_ARCH}/pseudo-native"
|
2011-09-09 17:21:24 +00:00
|
|
|
export PSEUDO_DISABLED = "1"
|
|
|
|
#export PSEUDO_PREFIX = "${STAGING_DIR_NATIVE}${prefix_native}"
|
|
|
|
#export PSEUDO_BINDIR = "${STAGING_DIR_NATIVE}${bindir_native}"
|
|
|
|
#export PSEUDO_LIBDIR = "${STAGING_DIR_NATIVE}$PSEUDOBINDIR/../lib/pseudo/lib
|
Switch to Recipe Specific Sysroots
This patch is comparatively large and invasive. It does only do one thing, switching the
system to build using recipe specific sysroots and where changes could be isolated from it,
that has been done.
With the current single sysroot approach, its possible for software to find things which
aren't in their dependencies. This leads to a determinism problem and is a growing issue in
several of the market segments where OE makes sense. The way to solve this problem for OE is
to have seperate sysroots for each recipe and these will only contain the dependencies for
that recipe.
Its worth noting that this is not task specific sysroots and that OE's dependencies do vary
enormously by task. This did result in some implementation challenges. There is nothing stopping
the implementation of task specific sysroots at some later point based on this work but
that as deemed a bridge too far right now.
Implementation details:
* Rather than installing the sysroot artefacts into a combined sysroots, they are now placed in
TMPDIR/sysroot-components/PACKAGE_ARCH/PN.
* WORKDIR/recipe-sysroot and WORKDIR/recipe-sysroot-native are built by hardlinking in files
from the sysroot-component trees. These new directories are known as RECIPE_SYSROOT and
RECIPE_SYSROOT_NATIVE.
* This construction is primarily done by a new do_prepare_recipe_sysroot task which runs
before do_configure and consists of a call to the extend_recipe_sysroot function.
* Other tasks need things in the sysroot before/after this, e.g. do_patch needs quilt-native
and do_package_write_deb needs dpkg-native. The code therefore inspects the dependencies
for each task and adds extend_recipe_sysroot as a prefunc if it has populate_sysroot
dependencies.
* We have to do a search/replace 'fixme' operation on the files installed into the sysroot to
change hardcoded paths into the correct ones. We create a fixmepath file in the component
directory which lists the files which need this operation.
* Some files have "postinstall" commands which need to run against them, e.g. gdk-pixbuf each
time a new loader is added. These are handled by adding files in bindir with the name
prefixed by "postinst-" and are run in each sysroot as its created if they're present.
This did mean most sstate postinstalls have to be rewritten but there shouldn't be many of them.
* Since a recipe can have multiple tasks and these tasks can run against each other at the same
time we have to have a lock when we perform write operations against the sysroot. We also have
to maintain manifests of what we install against a task checksum of the dependency. If the
checksum changes, we remove its files and then add the new ones.
* The autotools logic for filtering the view of m4 files is no longer needed (and was the model
for the way extend_recipe_sysroot works).
* For autotools, we used to build a combined m4 macros directory which had both the native and
target m4 files. We can no longer do this so we use the target sysroot as the default and add
the native sysroot as an extra backup include path. If we don't do this, we'd have to build
target pkg-config before we could built anything using pkg-config for example (ditto gettext).
Such dependencies would be painful so we haven't required that.
* PKDDATA_DIR was moved out the sysroot and works as before using sstate to build a hybrid copy
for each machine. The paths therefore changed, the behaviour did not.
* The ccache class had to be reworked to function with rss.
* The TCBOOTSTRAP sysroot for compiler bootstrap is no longer needed but the -initial data
does have to be filtered out from the main recipe sysroots. Putting "-initial" in a normal
recipe name therefore remains a bad idea.
* The logic in insane needed tweaks to deal with the new path layout, as did the debug source
file extraction code in package.bbclass.
* The logic in sstate.bbclass had to be rewritten since it previously only performed search and
replace on extracted sstate and we now need this to happen even if the compiled path was
"correct". This in theory could cause a mild performance issue but since the sysroot data
was the main data that needed this and we'd have to do it there regardless with rss, I've opted
just to change the way the class for everything. The built output used to build the sstate output
is now retained and installed rather than deleted.
* The search and replace logic used in sstate objects also seemed weak/incorrect and didn't hold
up against testing. This has been rewritten too. There are some assumptions made about paths, we
save the 'proper' search and replace operations to fixmepath.cmd but then ignore this. What is
here works but is a little hardcoded and an area for future improvement.
* In order to work with eSDK we need a way to build something that looks like the old style sysroot.
"bitbake build-sysroots" will construct such a sysroot based on everything in the components
directory that matches the current MACHINE. It will allow transition of external tools and can
built target or native variants or both. It also supports a clean task. I'd suggest not relying on
this for anything other than transitional purposes though. To see XXX in that sysroot, you'd have
to have built that in a previous bitbake invocation.
* pseudo is run out of its components directory. This is fine as its statically linked.
* The hacks for wayland to see allarch dependencies in the multilib case are no longer needed
and can be dropped.
* wic needed more extensive changes to work with rss and the fixes are in a separate commit series
* Various oe-selftest tweaks were needed since tests did assume the location to binaries and the
combined sysroot in several cases.
* Most missing dependencies this work found have been sent out as separate patches as they were found
but a few tweaks are still included here.
* A late addition is that extend_recipe_sysroot became multilib aware and able to populate multilib
sysroots. I had hoped not to have to add that complexity but the meta-environment recipe forced my
hand. That implementation can probably be neater but this is on the list of things to cleanup later
at this point.
In summary, the impact people will likely see after this change:
* Recipes may fail with missing dependencies, particularly native tools like gettext-native,
glib-2.0-native and libxml2.0-native. Some hosts have these installed and will mask these errors
* Any recipe/class using SSTATEPOSTINSTFUNCS will need that code rewriting into a postinst
* There was a separate patch series dealing with roots postinst native dependency issues. Any postinst
which expects native tools at rootfs time will need to mark that dependency with PACKAGE_WRITE_DEPS.
There could well be other issues. This has been tested repeatedly against our autobuilders and oe-selftest
and issues found have been fixed. We believe at least OE-Core is in good shape but that doesn't mean
we've found all the issues.
Also, the logging is a bit chatty at the moment. It does help if something goes wrong and goes to the
task logfiles, not the console so I've intentionally left this like that for now. We can turn it down
easily enough in due course.
(From OE-Core rev: 809746f56df4b91af014bf6a3f28997d6698ac78)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-12-07 13:54:35 +00:00
|
|
|
FAKEROOTBASEENV = "PSEUDO_BINDIR=${PSEUDO_SYSROOT}${bindir_native} PSEUDO_LIBDIR=${PSEUDO_SYSROOT}${prefix_native}/lib/pseudo/lib PSEUDO_PREFIX=${PSEUDO_SYSROOT}${prefix_native} PSEUDO_DISABLED=1"
|
|
|
|
FAKEROOTCMD = "${PSEUDO_SYSROOT}${bindir_native}/pseudo"
|
|
|
|
FAKEROOTENV = "PSEUDO_PREFIX=${PSEUDO_SYSROOT}${prefix_native} PSEUDO_LOCALSTATEDIR=${PSEUDO_LOCALSTATEDIR} PSEUDO_PASSWD=${PSEUDO_PASSWD} PSEUDO_NOSYMLINKEXP=1 PSEUDO_DISABLED=0"
|
2011-11-09 15:02:33 +00:00
|
|
|
FAKEROOTNOENV = "PSEUDO_UNLOAD=1"
|
2010-10-22 12:00:40 +00:00
|
|
|
FAKEROOTDIRS = "${PSEUDO_LOCALSTATEDIR}"
|
2010-06-23 14:19:06 +00:00
|
|
|
PREFERRED_PROVIDER_virtual/fakeroot-native ?= "pseudo-native"
|
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Not sure about the rest of this yet.
|
|
|
|
##################################################################
|
|
|
|
|
2012-04-27 04:32:31 +00:00
|
|
|
# Pre-build configuration output
|
|
|
|
BUILDCFG_HEADER = "Build Configuration:"
|
2012-11-26 14:50:47 +00:00
|
|
|
BUILDCFG_VARS = "BB_VERSION BUILD_SYS NATIVELSBSTRING TARGET_SYS MACHINE DISTRO DISTRO_VERSION TUNE_FEATURES TARGET_FPU"
|
2012-04-27 04:32:31 +00:00
|
|
|
BUILDCFG_VARS[type] = "list"
|
|
|
|
BUILDCFG_NEEDEDVARS = "TARGET_ARCH TARGET_OS"
|
|
|
|
BUILDCFG_NEEDEDVARS[type] = "list"
|
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
# Other
|
|
|
|
|
2013-10-06 13:01:33 +00:00
|
|
|
export PKG_CONFIG_DIR = "${STAGING_DIR_HOST}${libdir}/pkgconfig"
|
2007-06-29 07:44:00 +00:00
|
|
|
export PKG_CONFIG_PATH = "${PKG_CONFIG_DIR}:${STAGING_DATADIR}/pkgconfig"
|
2010-08-12 13:36:49 +00:00
|
|
|
export PKG_CONFIG_LIBDIR = "${PKG_CONFIG_DIR}"
|
2011-01-18 08:18:42 +00:00
|
|
|
export PKG_CONFIG_SYSROOT_DIR = "${STAGING_DIR_HOST}"
|
2005-08-31 10:45:47 +00:00
|
|
|
export PKG_CONFIG_DISABLE_UNINSTALLED = "yes"
|
2016-02-06 12:30:02 +00:00
|
|
|
export PKG_CONFIG_SYSTEM_LIBRARY_PATH = "${base_libdir}:${libdir}"
|
|
|
|
export PKG_CONFIG_SYSTEM_INCLUDE_PATH = "${includedir}"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
|
|
|
###
|
|
|
|
### Config file processing
|
|
|
|
###
|
|
|
|
|
2015-08-23 02:38:55 +00:00
|
|
|
# An empty distro leads to :: entries in OVERRIDES and FILEOVERRIDES which
|
2013-11-07 22:35:07 +00:00
|
|
|
# is a bad idea. Setting a dummy value is better than a ton of anonymous python.
|
|
|
|
DISTRO ??= "nodistro"
|
2015-08-23 02:38:55 +00:00
|
|
|
DISTRO_NAME ??= "OpenEmbedded"
|
2010-08-12 14:05:57 +00:00
|
|
|
# Overrides are processed left to right, so the ones that are named later take precedence.
|
|
|
|
# You generally want them to go from least to most specific.
|
2015-08-23 02:38:55 +00:00
|
|
|
#
|
2005-08-31 10:45:47 +00:00
|
|
|
# This means that an envionment variable named '<foo>_arm' overrides an
|
2010-08-12 14:05:57 +00:00
|
|
|
# environment variable '<foo>' (when ${TARGET_ARCH} is arm).
|
2011-05-24 14:04:20 +00:00
|
|
|
# An environment variable '<foo>_qemuarm' overrides '<foo>' and overrides
|
2015-08-23 02:38:55 +00:00
|
|
|
# '<foo>_arm' when ${MACHINE} is 'qemuarm'.
|
|
|
|
# If you use combination ie '<foo>_qemuarm_arm', then '<foo>_qemuarm_arm' will override
|
2011-05-24 14:04:20 +00:00
|
|
|
# '<foo>_qemuarm' and then '<foo>' will be overriden with that value from '<foo>_qemuarm'.
|
|
|
|
# And finally '<foo>_forcevariable' overrides any standard variable, with the highest priority.
|
2005-08-31 10:45:47 +00:00
|
|
|
#
|
|
|
|
# This works for functions as well, they are really just environment variables.
|
2007-12-18 15:04:06 +00:00
|
|
|
# Default OVERRIDES to make compilation fail fast in case of build system misconfiguration.
|
2012-02-11 02:58:28 +00:00
|
|
|
OVERRIDES = "${TARGET_OS}:${TRANSLATED_TARGET_ARCH}:build-${BUILD_OS}:pn-${PN}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}:${CLASSOVERRIDE}:forcevariable"
|
bitbake.conf: exclude whole MACHINEOVERRIDES from OVERRIDES vardeps
* whole MACHINEOVERRIDES can change e.g. between MACHINES with different arm architecture, causing allarch packages to reexecute do_package
bitbake-diffsigs ../shr-core/tmp-eglibc/stamps/all-oe-linux/xserver-nodm-init-2.0-r16.do_package.sigdata.90e760a8f6cecbd87cb2e95f1237e3cc ../shr-core/tmp-eglibc/stamps/all-oe-linux/xserver-nodm-init-2.0-r16.do_package.sigdata.9eeccfd15f25032b3b6b132534660fff
basehash changed from 7618e17d3fda05d1f15246e6800ca0f0 to 97bc4dc8c1521c535bd96b2aa62d8a03
Variable MACHINEOVERRIDES value changed from ${MACHINE}${@bb.utils.contains("TUNE_FEATURES", "armv5", ":armv5", "" ,d)}${@bb.utils.contains("TUNE_FEATURES", "armv4", ":armv4", "" ,d)}:${MACHINE_CLASS} to ${MACHINE}${@bb.utils.contains("TUNE_FEATURES", "armv7a", ":armv7a", "" ,d)}${@bb.utils.contains("TUNE_FEATURES", "armv6", ":armv6", "" ,d)}${@bb.utils.contains("TUNE_FEATURES", "armv5", ":armv5", "" ,d)}${@bb.utils.contains("TUNE_FEATURES", "armv4", ":armv4", "" ,d)}:${MACHINE_CLASS}
(From OE-Core rev: d205aa2b42a4676b1ba587c0375cd6ac7e18e9ce)
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-07-23 14:25:09 +00:00
|
|
|
OVERRIDES[vardepsexclude] = "MACHINEOVERRIDES"
|
2012-02-11 02:58:28 +00:00
|
|
|
CLASSOVERRIDE ?= "class-target"
|
2016-12-14 21:13:04 +00:00
|
|
|
DISTROOVERRIDES ?= "${@d.getVar('DISTRO') or ''}"
|
2011-05-13 18:39:04 +00:00
|
|
|
MACHINEOVERRIDES ?= "${MACHINE}"
|
2011-10-14 12:51:14 +00:00
|
|
|
MACHINEOVERRIDES[vardepsexclude] = "MACHINE"
|
2005-08-31 10:45:47 +00:00
|
|
|
|
2012-12-07 17:38:23 +00:00
|
|
|
FILESOVERRIDES = "${TRANSLATED_TARGET_ARCH}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}"
|
|
|
|
|
2005-08-31 10:45:47 +00:00
|
|
|
##################################################################
|
|
|
|
# Include the rest of the config files.
|
|
|
|
##################################################################
|
|
|
|
|
2012-04-16 07:52:01 +00:00
|
|
|
require conf/abi_version.conf
|
2005-08-31 10:45:47 +00:00
|
|
|
include conf/site.conf
|
|
|
|
include conf/auto.conf
|
|
|
|
include conf/local.conf
|
2017-01-15 18:41:51 +00:00
|
|
|
require conf/multiconfig/${BB_CURRENT_MC}.conf
|
2005-08-31 10:45:47 +00:00
|
|
|
include conf/build/${BUILD_SYS}.conf
|
|
|
|
include conf/machine/${MACHINE}.conf
|
2009-09-18 09:01:33 +00:00
|
|
|
include conf/machine-sdk/${SDKMACHINE}.conf
|
2017-02-22 10:21:42 +00:00
|
|
|
include conf/target/${TARGET_SYS}.conf
|
2005-08-31 10:45:47 +00:00
|
|
|
include conf/distro/${DISTRO}.conf
|
2011-05-10 13:04:57 +00:00
|
|
|
include conf/distro/defaultsetup.conf
|
2005-08-31 10:45:47 +00:00
|
|
|
include conf/documentation.conf
|
2012-09-26 21:50:08 +00:00
|
|
|
include conf/licenses.conf
|
2006-03-20 15:06:33 +00:00
|
|
|
require conf/sanity.conf
|
2006-03-23 22:30:35 +00:00
|
|
|
|
|
|
|
##################################################################
|
|
|
|
# Weak variables (usually to retain backwards compatibility)
|
|
|
|
##################################################################
|
|
|
|
|
2010-07-19 10:31:40 +00:00
|
|
|
DL_DIR ?= "${TOPDIR}/downloads"
|
2010-09-29 10:19:22 +00:00
|
|
|
SSTATE_DIR ?= "${TOPDIR}/sstate-cache"
|
2009-01-02 10:31:44 +00:00
|
|
|
IMAGE_FSTYPES ?= "tar.gz"
|
2016-05-06 11:26:05 +00:00
|
|
|
IMAGE_FSTYPES_DEBUGFS ?= "${IMAGE_FSTYPES}"
|
image.bbclass: check INITRAMFS_MAXSIZE
Usually, the initramfs' maxsize can be 1/2 of ram size since modern
kernel uses tmpfs as initramfs by dafault, and tmpfs allocates 1/2 of
ram by default at boot time, which will be used to locate the initramfs.
Set INITRAMFS_MAXSIZE to 131072K (128M) by default (ram 256M), the
initramfs is small usually, for example, core-image-minimal-initramfs is
about 21M (uncompressed, 17M * 1.3) by default, but if the user add a
lot pkgs to initramfs, we can error and stop to let the user know ealier
rather than fail to boot (e.g., OOM-killer) at boot time.
Please see the bug for more info:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=5963
[YOCTO #5963]
(From OE-Core rev: 155ba626b46bf71acde6c24402fce1682da53b90)
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-25 08:45:59 +00:00
|
|
|
|
2011-12-13 16:19:47 +00:00
|
|
|
INITRAMFS_FSTYPES ?= "cpio.gz"
|
image.bbclass: check INITRAMFS_MAXSIZE
Usually, the initramfs' maxsize can be 1/2 of ram size since modern
kernel uses tmpfs as initramfs by dafault, and tmpfs allocates 1/2 of
ram by default at boot time, which will be used to locate the initramfs.
Set INITRAMFS_MAXSIZE to 131072K (128M) by default (ram 256M), the
initramfs is small usually, for example, core-image-minimal-initramfs is
about 21M (uncompressed, 17M * 1.3) by default, but if the user add a
lot pkgs to initramfs, we can error and stop to let the user know ealier
rather than fail to boot (e.g., OOM-killer) at boot time.
Please see the bug for more info:
https://bugzilla.yoctoproject.org/show_bug.cgi?id=5963
[YOCTO #5963]
(From OE-Core rev: 155ba626b46bf71acde6c24402fce1682da53b90)
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-25 08:45:59 +00:00
|
|
|
# The maximum size in Kbytes for the generated initramfs image size.
|
|
|
|
# Usually, it should be less than 1/2 of ram size, or you may fail to
|
|
|
|
# boot it.
|
|
|
|
INITRAMFS_MAXSIZE ??= "131072"
|
|
|
|
|
2012-08-29 10:38:34 +00:00
|
|
|
DEFAULT_TASK_PROVIDER ?= "packagegroup-base"
|
2007-12-18 15:04:06 +00:00
|
|
|
MACHINE_TASK_PROVIDER ?= "${DEFAULT_TASK_PROVIDER}"
|
2014-07-07 09:33:58 +00:00
|
|
|
|
|
|
|
# The size in Kbytes for the generated image if it is larger than
|
|
|
|
# the required size (du -ks IMAGE_ROOTFS * IMAGE_OVERHEAD_FACTOR),
|
|
|
|
# and no effect if less than it.
|
2014-09-04 07:52:44 +00:00
|
|
|
IMAGE_ROOTFS_SIZE ??= "65536"
|
2006-11-16 14:45:43 +00:00
|
|
|
|
2015-08-23 02:38:55 +00:00
|
|
|
# Forcefully set CACHE now so future changes to things like
|
2007-08-08 21:02:39 +00:00
|
|
|
# MACHINE don't change the path to the cache
|
|
|
|
CACHE := "${CACHE}"
|
|
|
|
|
2014-07-23 07:46:02 +00:00
|
|
|
# Default to setting automatically based on cpu count
|
|
|
|
BB_NUMBER_THREADS ?= "${@oe.utils.cpu_count()}"
|
|
|
|
|
|
|
|
# Default to setting automatically based on cpu count
|
|
|
|
PARALLEL_MAKE ?= "-j ${@oe.utils.cpu_count()}"
|
|
|
|
|
2006-05-09 16:10:18 +00:00
|
|
|
##################################################################
|
|
|
|
# Magic Cookie for SANITY CHECK
|
|
|
|
##################################################################
|
|
|
|
OES_BITBAKE_CONF = "1"
|
2007-06-29 07:44:00 +00:00
|
|
|
|
|
|
|
##################################################################
|
2012-08-29 10:38:34 +00:00
|
|
|
# Machine properties and packagegroup-base stuff
|
2007-06-29 07:44:00 +00:00
|
|
|
##################################################################
|
|
|
|
|
2013-05-29 16:27:51 +00:00
|
|
|
MACHINE_FEATURES ?= ""
|
2007-06-29 07:44:00 +00:00
|
|
|
DISTRO_FEATURES ?= ""
|
|
|
|
|
|
|
|
DISTRO_EXTRA_RDEPENDS ?= ""
|
|
|
|
DISTRO_EXTRA_RRECOMMENDS ?= ""
|
|
|
|
MACHINE_EXTRA_RDEPENDS ?= ""
|
|
|
|
MACHINE_EXTRA_RRECOMMENDS ?= ""
|
|
|
|
MACHINE_ESSENTIAL_EXTRA_RDEPENDS ?= ""
|
|
|
|
MACHINE_ESSENTIAL_EXTRA_RRECOMMENDS ?= ""
|
2013-05-13 10:07:43 +00:00
|
|
|
|
|
|
|
EXTRA_IMAGE_FEATURES ??= ""
|
2008-01-10 23:50:30 +00:00
|
|
|
IMAGE_FEATURES += "${EXTRA_IMAGE_FEATURES}"
|
2007-06-29 07:44:00 +00:00
|
|
|
|
2017-04-11 14:35:40 +00:00
|
|
|
# Native distro features (will always be used for -native, even if they
|
|
|
|
# are not enabled for target)
|
|
|
|
DISTRO_FEATURES_NATIVE ?= "x11"
|
|
|
|
DISTRO_FEATURES_NATIVESDK ?= "x11 libc-charsets libc-locales libc-locale-code"
|
|
|
|
|
|
|
|
# Normally target distro features will not be applied to native builds:
|
|
|
|
# Native distro features on this list will use the target feature value
|
|
|
|
DISTRO_FEATURES_FILTER_NATIVE ?= "api-documentation"
|
|
|
|
DISTRO_FEATURES_FILTER_NATIVESDK ?= "api-documentation"
|
|
|
|
|
2017-01-27 22:29:10 +00:00
|
|
|
DISTRO_FEATURES_BACKFILL = "pulseaudio sysvinit bluez5 gobject-introspection-data ldconfig"
|
2016-03-23 12:52:05 +00:00
|
|
|
MACHINE_FEATURES_BACKFILL = "rtc qemu-usermode"
|
2012-07-10 13:53:55 +00:00
|
|
|
|
2015-05-22 11:30:31 +00:00
|
|
|
COMBINED_FEATURES = "${@oe.utils.set_intersect('DISTRO_FEATURES', 'MACHINE_FEATURES', d)}"
|
2011-11-16 21:17:21 +00:00
|
|
|
COMBINED_FEATURES[vardeps] += "DISTRO_FEATURES MACHINE_FEATURES"
|
2010-03-19 23:12:06 +00:00
|
|
|
|
2013-04-30 14:30:10 +00:00
|
|
|
SERIAL_CONSOLE ??= ""
|
2016-12-14 21:13:04 +00:00
|
|
|
SERIAL_CONSOLES ??= "${@d.getVar('SERIAL_CONSOLE').replace(' ', ';')}"
|
2013-04-30 14:30:10 +00:00
|
|
|
|
2013-08-13 00:45:48 +00:00
|
|
|
NO_RECOMMENDATIONS ?= ""
|
2013-07-24 16:26:08 +00:00
|
|
|
BAD_RECOMMENDATIONS ?= ""
|
|
|
|
|
2010-03-19 23:12:06 +00:00
|
|
|
# Make sure MACHINE isn't exported
|
|
|
|
# (breaks binutils at least)
|
|
|
|
MACHINE[unexport] = "1"
|
|
|
|
|
|
|
|
# Make sure TARGET_ARCH isn't exported
|
2015-08-23 02:38:55 +00:00
|
|
|
# (breaks Makefiles using implicit rules, e.g. quilt, as GNU make has this
|
2010-03-19 23:12:06 +00:00
|
|
|
# in them, undocumented)
|
|
|
|
TARGET_ARCH[unexport] = "1"
|
|
|
|
|
|
|
|
# Make sure DISTRO isn't exported
|
|
|
|
# (breaks sysvinit at least)
|
|
|
|
DISTRO[unexport] = "1"
|
|
|
|
|
2015-08-24 22:18:37 +00:00
|
|
|
# Make sure SHELL isn't exported
|
|
|
|
# (can break any number of things if the user's shell isn't POSIX-compliant,
|
|
|
|
# including the flock command). The user's shell shouldn't affect our builds.
|
|
|
|
SHELL[unexport] = "1"
|
|
|
|
|
2010-12-10 16:56:08 +00:00
|
|
|
# Used by canadian-cross to handle string conversions on TARGET_ARCH where needed
|
2016-12-14 21:13:04 +00:00
|
|
|
TRANSLATED_TARGET_ARCH ??= "${@d.getVar('TARGET_ARCH').replace("_", "-")}"
|
2010-12-30 12:24:18 +00:00
|
|
|
|
2012-08-02 16:45:09 +00:00
|
|
|
# Complete output from bitbake
|
|
|
|
BB_CONSOLELOG ?= "${LOG_DIR}/cooker/${MACHINE}/${DATETIME}.log"
|
2011-11-24 14:50:37 +00:00
|
|
|
|
2010-12-30 12:24:18 +00:00
|
|
|
# Setup our default hash policy
|
2012-06-22 14:04:27 +00:00
|
|
|
BB_SIGNATURE_HANDLER ?= "OEBasicHash"
|
2016-09-09 08:02:54 +00:00
|
|
|
BB_HASHBASE_WHITELIST ?= "TMPDIR FILE PATH PWD BB_TASKHASH BBPATH BBSERVER DL_DIR \
|
2012-10-23 07:52:26 +00:00
|
|
|
SSTATE_DIR THISDIR FILESEXTRAPATHS FILE_DIRNAME HOME LOGNAME SHELL TERM \
|
|
|
|
USER FILESPATH STAGING_DIR_HOST STAGING_DIR_TARGET COREBASE PRSERV_HOST \
|
2013-01-23 14:54:28 +00:00
|
|
|
PRSERV_DUMPDIR PRSERV_DUMPFILE PRSERV_LOCKDOWN PARALLEL_MAKE \
|
2013-10-16 12:18:53 +00:00
|
|
|
CCACHE_DIR EXTERNAL_TOOLCHAIN CCACHE CCACHE_DISABLE LICENSE_PATH SDKPKGSUFFIX \
|
2016-04-02 16:11:56 +00:00
|
|
|
WARN_QA ERROR_QA WORKDIR STAMPCLEAN PKGDATA_DIR BUILD_ARCH SSTATE_PKGARCH \
|
2017-03-30 08:46:33 +00:00
|
|
|
BB_WORKERCONTEXT BB_LIMITEDDEPS extend_recipe_sysroot DEPLOY_DIR"
|
2013-02-06 23:34:52 +00:00
|
|
|
BB_HASHCONFIG_WHITELIST ?= "${BB_HASHBASE_WHITELIST} DATE TIME SSH_AGENT_PID \
|
|
|
|
SSH_AUTH_SOCK PSEUDO_BUILD BB_ENV_EXTRAWHITE DISABLE_SANITY_CHECKS \
|
2016-03-21 05:14:02 +00:00
|
|
|
PARALLEL_MAKE BB_NUMBER_THREADS BB_ORIGENV BB_INVALIDCONF BBINCLUDED \
|
|
|
|
GIT_PROXY_COMMAND ALL_PROXY all_proxy NO_PROXY no_proxy FTP_PROXY ftp_proxy \
|
2016-06-23 12:07:01 +00:00
|
|
|
HTTP_PROXY http_proxy HTTPS_PROXY https_proxy SOCKS5_USER SOCKS5_PASSWD \
|
|
|
|
BB_SETSCENE_ENFORCE"
|
2014-12-01 23:47:47 +00:00
|
|
|
BB_SIGNATURE_EXCLUDE_FLAGS ?= "doc deps depends \
|
2014-03-03 15:44:34 +00:00
|
|
|
lockfiles type vardepsexclude vardeps vardepvalue vardepvalueexclude \
|
|
|
|
file-checksums python func task export unexport noexec nostamp dirs cleandirs \
|
2012-10-23 07:52:26 +00:00
|
|
|
sstate-lockfile-shared prefuncs postfuncs export_func deptask rdeptask \
|
2016-06-23 12:06:57 +00:00
|
|
|
recrdeptask nodeprrecs stamp-extra-info sstate-outputdirs filename lineno \
|
|
|
|
progress"
|
2010-12-30 12:24:18 +00:00
|
|
|
|
2011-06-07 09:27:03 +00:00
|
|
|
MLPREFIX ??= ""
|
2011-07-29 14:21:58 +00:00
|
|
|
MULTILIB_VARIANTS ??= ""
|