1eb8dc403SDave Cobbley################################################################## 2eb8dc403SDave Cobbley# Standard target filesystem paths. 3eb8dc403SDave Cobbley################################################################## 4eb8dc403SDave Cobbley# 5eb8dc403SDave Cobbley# If changing these values, beware that native/cross/nativesdk bbclass 6eb8dc403SDave Cobbley# files may also need changes to keep in sync. 7eb8dc403SDave Cobbley# 8eb8dc403SDave Cobbley 9eb8dc403SDave Cobbley# Used by multilib code to change the library paths 10eb8dc403SDave Cobbleybaselib = "${BASELIB}" 11eb8dc403SDave Cobbleybaselib[vardepvalue] = "${baselib}" 12eb8dc403SDave CobbleyBASELIB = "lib" 13213cb269SPatrick WilliamsBASELIB:libc-glibc:powerpc64 = "lib64" 14213cb269SPatrick WilliamsBASELIB:libc-glibc:powerpc64le = "lib64" 15eb8dc403SDave Cobbley 16eb8dc403SDave Cobbley# Path prefixes 17eb8dc403SDave Cobbleyexport base_prefix = "" 18eb8dc403SDave Cobbleyexport prefix = "/usr" 19eb8dc403SDave Cobbleyexport exec_prefix = "${prefix}" 20eb8dc403SDave Cobbley 21eb8dc403SDave Cobbleyroot_prefix = "${@bb.utils.contains('DISTRO_FEATURES', 'usrmerge', '${exec_prefix}', '${base_prefix}', d)}" 22eb8dc403SDave Cobbley 23eb8dc403SDave Cobbley# Base paths 24eb8dc403SDave Cobbleyexport base_bindir = "${root_prefix}/bin" 25eb8dc403SDave Cobbleyexport base_sbindir = "${root_prefix}/sbin" 26eb8dc403SDave Cobbleyexport base_libdir = "${root_prefix}/${baselib}" 27eb8dc403SDave Cobbleyexport nonarch_base_libdir = "${root_prefix}/lib" 28eb8dc403SDave Cobbley 29eb8dc403SDave Cobbley# Architecture independent paths 30eb8dc403SDave Cobbleyexport sysconfdir = "${base_prefix}/etc" 31eb8dc403SDave Cobbleyexport servicedir = "${base_prefix}/srv" 32eb8dc403SDave Cobbleyexport sharedstatedir = "${base_prefix}/com" 33eb8dc403SDave Cobbleyexport localstatedir = "${base_prefix}/var" 34169d7bccSPatrick Williamsruntimedir = "${base_prefix}/run" 35eb8dc403SDave Cobbleyexport datadir = "${prefix}/share" 36eb8dc403SDave Cobbleyexport infodir = "${datadir}/info" 37eb8dc403SDave Cobbleyexport mandir = "${datadir}/man" 38eb8dc403SDave Cobbleyexport docdir = "${datadir}/doc" 39eb8dc403SDave Cobbleyexport systemd_unitdir = "${nonarch_base_libdir}/systemd" 40eb8dc403SDave Cobbleyexport systemd_system_unitdir = "${nonarch_base_libdir}/systemd/system" 41eb8dc403SDave Cobbleyexport nonarch_libdir = "${exec_prefix}/lib" 42eb8dc403SDave Cobbleyexport systemd_user_unitdir = "${nonarch_libdir}/systemd/user" 43eb8dc403SDave Cobbley 44eb8dc403SDave Cobbley# Architecture dependent paths 45eb8dc403SDave Cobbleyexport bindir = "${exec_prefix}/bin" 46eb8dc403SDave Cobbleyexport sbindir = "${exec_prefix}/sbin" 47eb8dc403SDave Cobbleyexport libdir = "${exec_prefix}/${baselib}" 48eb8dc403SDave Cobbleyexport libexecdir = "${exec_prefix}/libexec" 49eb8dc403SDave Cobbleyexport includedir = "${exec_prefix}/include" 50eb8dc403SDave Cobbleylocaledir = "${libdir}/locale" 51eb8dc403SDave Cobbley 52eb8dc403SDave Cobbley# Linkage between native/cross/nativesdk layouts 53eb8dc403SDave Cobbleybase_bindir_native = "/bin" 54eb8dc403SDave Cobbleybase_sbindir_native = "/sbin" 55eb8dc403SDave Cobbleysysconfdir_native = "/etc" 56eb8dc403SDave Cobbleyprefix_native = "/usr" 57eb8dc403SDave Cobbleybindir_native = "${prefix_native}/bin" 58eb8dc403SDave Cobbleysbindir_native = "${prefix_native}/sbin" 59eb8dc403SDave Cobbleyincludedir_native = "${prefix_native}/include" 60eb8dc403SDave Cobbleylibdir_native = "${prefix_native}/lib" 61eb8dc403SDave Cobbleylibexecdir_native = "${prefix_native}/libexec" 62eb8dc403SDave Cobbleybase_libdir_native = "/lib" 63eb8dc403SDave Cobbleydatadir_native = "${prefix_native}/share" 64eb8dc403SDave Cobbleybindir_cross = "/bin" 65eb8dc403SDave Cobbleybindir_crossscripts = "${bindir}/crossscripts" 66eb8dc403SDave Cobbleyprefix_nativesdk = "/usr" 67eb8dc403SDave Cobbleybindir_nativesdk = "${prefix_nativesdk}/bin" 68eb8dc403SDave Cobbleysbindir_nativesdk = "${prefix_nativesdk}/sbin" 69eb8dc403SDave Cobbleybase_bindir_nativesdk = "/bin" 70eb8dc403SDave Cobbleybase_sbindir_nativesdk = "/sbin" 71eb8dc403SDave Cobbleyincludedir_nativesdk = "${prefix_nativesdk}/include" 72eb8dc403SDave Cobbleylibdir_nativesdk = "${prefix_nativesdk}/lib" 73eb8dc403SDave Cobbleybase_libdir_nativesdk = "/lib" 74eb8dc403SDave Cobbleylocalstatedir_nativesdk = "/var" 75eb8dc403SDave Cobbley 76eb8dc403SDave Cobbley# 77eb8dc403SDave Cobbley# Cross recipes need to know about the target layout 78eb8dc403SDave Cobbley# := is used carefully here 79eb8dc403SDave Cobbley# 80eb8dc403SDave Cobbleytarget_datadir := "${datadir}" 81eb8dc403SDave Cobbley# Used to find env/perl/python 82eb8dc403SDave CobbleyUSRBINPATH = "${bindir}" 83213cb269SPatrick WilliamsUSRBINPATH:class-native = "/usr/bin" 84213cb269SPatrick WilliamsUSRBINPATH:class-nativesdk = "/usr/bin" 85eb8dc403SDave Cobbley 86eb8dc403SDave Cobbley# Root home directory 87eb8dc403SDave CobbleyROOT_HOME ??= "/home/root" 88eb8dc403SDave Cobbley 89eb8dc403SDave Cobbley# If set to boolean true ('yes', 'y', 'true', 't', '1'), /var/log links to /var/volatile/log. 90eb8dc403SDave Cobbley# If set to boolean false ('no', 'n', 'false', 'f', '0'), /var/log is on persistent storage. 91eb8dc403SDave CobbleyVOLATILE_LOG_DIR ?= "yes" 92eb8dc403SDave Cobbley 936aa7eec5SAndrew Geissler# if set to 'yes': /tmp links to /var/tmp which links to /var/volatile/tmp 946aa7eec5SAndrew Geissler# otherwise: /tmp is on persistent storage 956aa7eec5SAndrew GeisslerVOLATILE_TMP_DIR ?= "yes" 966aa7eec5SAndrew Geissler 977e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[PNBLACKLIST] = "SKIP_RECIPE" 987e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[CVE_CHECK_PN_WHITELIST] = "CVE_CHECK_SKIP_RECIPE" 997e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[CVE_CHECK_WHITELIST] = "CVE_CHECK_IGNORE" 1007e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[MULTI_PROVIDER_WHITELIST] = "BB_MULTI_PROVIDER_ALLOWED" 1017e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[PNBLACKLIST] = "SKIP_RECIPE" 1027e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[SDK_LOCAL_CONF_BLACKLIST] = "ESDK_LOCALCONF_REMOVE" 1037e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[SDK_LOCAL_CONF_WHITELIST] = "ESDK_LOCALCONF_ALLOW" 1047e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[SDK_INHERIT_BLACKLIST] = "ESDK_CLASS_INHERIT_DISABLE" 1057e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[SSTATE_DUPWHITELIST] = "SSTATE_ALLOW_OVERLAP_FILES" 1067e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[SYSROOT_DIRS_BLACKLIST] = "SYSROOT_DIRS_IGNORE" 1077e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[UNKNOWN_CONFIGURE_WHITELIST] = "UNKNOWN_CONFIGURE_OPT_IGNORE" 1087e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[ICECC_USER_CLASS_BL] = "ICECC_CLASS_DISABLE" 1097e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[ICECC_SYSTEM_CLASS_BL] = "ICECC_CLASS_DISABLE" 1107e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[ICECC_USER_PACKAGE_WL] = "ICECC_RECIPE_ENABLE" 1117e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[ICECC_USER_PACKAGE_BL] = "ICECC_RECIPE_DISABLE" 1127e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[ICECC_SYSTEM_PACKAGE_BL] = "ICECC_RECIPE_DISABLE" 1137e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[INHERIT_BLACKLIST] = "is a deprecated variable and no longer needed" 1147e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[TUNEABI_WHITELIST] = "is a deprecated variable and support has been removed" 1157e0e3c0cSAndrew GeisslerBB_RENAMED_VARIABLES[LICENSE_FLAGS_WHITELIST] = "LICENSE_FLAGS_ACCEPTED" 1167e0e3c0cSAndrew Geissler 1179aee5003SAndrew GeisslerBB_RENAMED_VARIABLES[WHITELIST_GPL-3.0-only] = "INCOMPATIBLE_LICENSE_EXCEPTIONS" 1189aee5003SAndrew GeisslerBB_RENAMED_VARIABLES[WHITELIST_GPL-3.0-or-later] = "INCOMPATIBLE_LICENSE_EXCEPTIONS" 1199aee5003SAndrew GeisslerBB_RENAMED_VARIABLES[WHITELIST_LGPL-3.0-only] = "INCOMPATIBLE_LICENSE_EXCEPTIONS" 1209aee5003SAndrew GeisslerBB_RENAMED_VARIABLES[WHITELIST_LGPL-3.0-or-later] = "INCOMPATIBLE_LICENSE_EXCEPTIONS" 1219aee5003SAndrew Geissler 1229aee5003SAndrew Geissler# These are deprecated version and should be updated to approved names 1239aee5003SAndrew GeisslerBB_RENAMED_VARIABLES[WHITELIST_GPL-3.0] = "is deprecated, convert to INCOMPATIBLE_LICENSE_EXCEPTIONS = '<pkg>:GPL-3.0-only'" 1249aee5003SAndrew GeisslerBB_RENAMED_VARIABLES[WHITELIST_GPL-3.0+] = "is deprecated, convert to INCOMPATIBLE_LICENSE_EXCEPTIONS = '<pkg>:GPL-3.0-or-later'" 1259aee5003SAndrew GeisslerBB_RENAMED_VARIABLES[WHITELIST_LGPL-3.0] = "is deprecated, convert to INCOMPATIBLE_LICENSE_EXCEPTIONS = '<pkg>:LGPL-3.0-only'" 1269aee5003SAndrew GeisslerBB_RENAMED_VARIABLES[WHITELIST_LGPL-3.0+] = "is deprecated, convert to INCOMPATIBLE_LICENSE_EXCEPTIONS = '<pkg>:LGPL-3.0-or-later'" 1279aee5003SAndrew Geissler 128eb8dc403SDave Cobbley################################################################## 129eb8dc403SDave Cobbley# Architecture-dependent build variables. 130eb8dc403SDave Cobbley################################################################## 131eb8dc403SDave Cobbley 1321a4b7ee2SBrad Bishop# Immediate expansion since there is no point in repeatedly calling 133eb8dc403SDave Cobbley# os.uname() throughout parsing 134eb8dc403SDave CobbleyBUILD_ARCH := "${@os.uname()[4]}" 135eb8dc403SDave CobbleyBUILD_OS := "${@os.uname()[0].lower()}" 136eb8dc403SDave CobbleyBUILD_VENDOR = "" 137eb8dc403SDave CobbleyBUILD_SYS = "${BUILD_ARCH}${BUILD_VENDOR}-${BUILD_OS}" 138eb8dc403SDave CobbleyBUILD_PREFIX = "" 139eb8dc403SDave CobbleyBUILD_CC_ARCH = "" 140eb8dc403SDave CobbleyBUILD_LD_ARCH = "" 141eb8dc403SDave CobbleyBUILD_AS_ARCH = "" 142eb8dc403SDave CobbleyBUILD_EXEEXT = "" 143eb8dc403SDave Cobbley 144eb8dc403SDave CobbleyHOST_ARCH = "${TARGET_ARCH}" 145eb8dc403SDave CobbleyHOST_OS = "${TARGET_OS}" 146eb8dc403SDave CobbleyHOST_VENDOR = "${TARGET_VENDOR}" 147eb8dc403SDave CobbleyHOST_SYS = "${HOST_ARCH}${HOST_VENDOR}-${HOST_OS}" 148eb8dc403SDave CobbleyHOST_PREFIX = "${TARGET_PREFIX}" 149eb8dc403SDave CobbleyHOST_CC_ARCH = "${TARGET_CC_ARCH}" 150eb8dc403SDave CobbleyHOST_LD_ARCH = "${TARGET_LD_ARCH}" 151eb8dc403SDave CobbleyHOST_AS_ARCH = "${TARGET_AS_ARCH}" 152eb8dc403SDave CobbleyHOST_EXEEXT = "" 153eb8dc403SDave Cobbley 154eb8dc403SDave CobbleyTUNE_ARCH ??= "INVALID" 155eb8dc403SDave CobbleyTUNE_CCARGS ??= "" 156eb8dc403SDave CobbleyTUNE_CCARGS[vardepvalue] = "${TUNE_CCARGS}" 157eb8dc403SDave CobbleyTUNE_LDARGS ??= "" 158eb8dc403SDave CobbleyTUNE_ASARGS ??= "" 159213cb269SPatrick WilliamsTUNE_FEATURES ??= "${TUNE_FEATURES:tune-${DEFAULTTUNE}}" 160eb8dc403SDave CobbleyLIBCEXTENSION ??= "" 161eb8dc403SDave CobbleyABIEXTENSION ??= "" 16219323693SBrad BishopUSE_NLS ??= "yes" 163eb8dc403SDave CobbleySDKUSE_NLS ??= "yes" 164eb8dc403SDave Cobbley 165eb8dc403SDave CobbleyTARGET_ARCH = "${TUNE_ARCH}" 166eb8dc403SDave CobbleyTARGET_OS = "linux${LIBCEXTENSION}${ABIEXTENSION}" 167eb8dc403SDave CobbleyTARGET_VENDOR = "-oe" 16882c905dcSAndrew GeisslerTARGET_SYS = "${TARGET_ARCH}${TARGET_VENDOR}-${TARGET_OS}" 169eb8dc403SDave CobbleyTARGET_PREFIX = "${TARGET_SYS}-" 170eb8dc403SDave CobbleyTARGET_CC_ARCH = "${TUNE_CCARGS}" 171eb8dc403SDave CobbleyTARGET_LD_ARCH = "${TUNE_LDARGS}" 172eb8dc403SDave CobbleyTARGET_AS_ARCH = "${TUNE_ASARGS}" 173eb8dc403SDave Cobbley 174d1e89497SAndrew GeisslerSDKMACHINE ??= "${BUILD_ARCH}" 175eb8dc403SDave CobbleySDK_OS = "${BUILD_OS}" 176eb8dc403SDave CobbleySDK_VENDOR = "-oesdk" 17782c905dcSAndrew GeisslerSDK_SYS = "${SDK_ARCH}${SDK_VENDOR}-${SDK_OS}" 178eb8dc403SDave CobbleySDK_PREFIX = "${SDK_SYS}-" 179eb8dc403SDave CobbleySDK_CC_ARCH = "${BUILD_CC_ARCH}" 180eb8dc403SDave CobbleySDKPKGSUFFIX = "nativesdk" 181eb8dc403SDave CobbleySDK_PACKAGE_ARCHS = "all any noarch ${SDK_ARCH}-${SDKPKGSUFFIX}" 182eb8dc403SDave CobbleySDK_LD_ARCH = "${BUILD_LD_ARCH}" 183eb8dc403SDave CobbleySDK_AS_ARCH = "${BUILD_AS_ARCH}" 184eb8dc403SDave Cobbley 185eb8dc403SDave CobbleyTUNE_PKGARCH ??= "" 186eb8dc403SDave CobbleyPACKAGE_ARCH ??= "${TUNE_PKGARCH}" 187eb8dc403SDave CobbleyMACHINE_ARCH = "${@[d.getVar('TUNE_PKGARCH'), d.getVar('MACHINE')][bool(d.getVar('MACHINE'))].replace('-', '_')}" 188213cb269SPatrick WilliamsPACKAGE_EXTRA_ARCHS ??= "${PACKAGE_EXTRA_ARCHS:tune-${DEFAULTTUNE}}" 189eb8dc403SDave CobbleyPACKAGE_ARCHS = "all any noarch ${PACKAGE_EXTRA_ARCHS} ${MACHINE_ARCH}" 190eb8dc403SDave Cobbley# MACHINE_ARCH shouldn't be included here as a variable dependency 191eb8dc403SDave Cobbley# since machine specific packages are handled using multimachine 192eb8dc403SDave CobbleyPACKAGE_ARCHS[vardepsexclude] = "MACHINE_ARCH" 193eb8dc403SDave Cobbley 194eb8dc403SDave CobbleyMULTIMACH_TARGET_SYS = "${PACKAGE_ARCH}${TARGET_VENDOR}-${TARGET_OS}" 195eb8dc403SDave Cobbley 196eb8dc403SDave Cobbley################################################################## 197eb8dc403SDave Cobbley# Date/time variables. 198eb8dc403SDave Cobbley################################################################## 199eb8dc403SDave Cobbley 200eb8dc403SDave CobbleyDATE := "${@time.strftime('%Y%m%d',time.gmtime())}" 201eb8dc403SDave CobbleyTIME := "${@time.strftime('%H%M%S',time.gmtime())}" 202eb8dc403SDave CobbleyDATETIME = "${DATE}${TIME}" 203eb8dc403SDave Cobbley 204eb8dc403SDave Cobbley################################################################## 205eb8dc403SDave Cobbley# Openembedded Software Prerequisites. 206eb8dc403SDave Cobbley################################################################## 207eb8dc403SDave Cobbley 208eb8dc403SDave Cobbley# python-native should be here but python relies on building 209eb8dc403SDave Cobbley# its own in staging 210eb8dc403SDave CobbleyASSUME_PROVIDED = "\ 211ac69b488SWilliam A. Kennington III bash-native \ 212eb8dc403SDave Cobbley bzip2-native \ 213eb8dc403SDave Cobbley chrpath-native \ 214ac69b488SWilliam A. Kennington III diffstat-native \ 215eb8dc403SDave Cobbley file-native \ 216eb8dc403SDave Cobbley findutils-native \ 217eb8dc403SDave Cobbley gawk-native \ 218eb8dc403SDave Cobbley git-native \ 219eb8dc403SDave Cobbley grep-native \ 220eb8dc403SDave Cobbley hostperl-runtime-native \ 221eb8dc403SDave Cobbley hostpython-runtime-native \ 222ac69b488SWilliam A. Kennington III libgcc-native \ 223ac69b488SWilliam A. Kennington III patch-native \ 224eb8dc403SDave Cobbley sed-native \ 225ac69b488SWilliam A. Kennington III tar-native \ 226ac69b488SWilliam A. Kennington III texinfo-native \ 227ac69b488SWilliam A. Kennington III virtual/crypt-native \ 228ac69b488SWilliam A. Kennington III virtual/libiconv-native \ 229ac69b488SWilliam A. Kennington III virtual/libintl-native \ 230eb8dc403SDave Cobbley wget-native \ 231eb8dc403SDave Cobbley " 232eb8dc403SDave Cobbley# gzip-native should be listed above? 233eb8dc403SDave Cobbley 234eb8dc403SDave Cobbley################################################################## 235eb8dc403SDave Cobbley# Package default variables. 236eb8dc403SDave Cobbley################################################################## 237eb8dc403SDave Cobbley 23819323693SBrad BishopPN = "${@bb.parse.vars_from_file(d.getVar('FILE', False),d)[0] or 'defaultpkgname'}" 23919323693SBrad BishopPV = "${@bb.parse.vars_from_file(d.getVar('FILE', False),d)[1] or '1.0'}" 240220dafdbSAndrew GeisslerPR = "r0" 241eb8dc403SDave CobbleyPE = "" 242eb8dc403SDave CobbleyPF = "${PN}-${EXTENDPE}${PV}-${PR}" 243eb8dc403SDave CobbleyEXTENDPE = "${@['','${PE}_'][int(d.getVar('PE') or 0) > 0]}" 244eb8dc403SDave CobbleyP = "${PN}-${PV}" 245eb8dc403SDave Cobbley 246c9f7865aSAndrew GeisslerPRSERV_PV_AUTOINC = "AUTOINC" 247eb8dc403SDave CobbleyPRAUTO = "" 248eb8dc403SDave CobbleyEXTENDPRAUTO = "${@['.${PRAUTO}', ''][not d.getVar('PRAUTO')]}" 249eb8dc403SDave CobbleyPRAUTOINX = "${PF}" 250eb8dc403SDave Cobbley 251eb8dc403SDave CobbleyPKGV ?= "${PV}" 252eb8dc403SDave CobbleyPKGR ?= "${PR}${EXTENDPRAUTO}" 253eb8dc403SDave CobbleyPKGE ?= "${@['','${PE}'][int(d.getVar('PE') or 0) > 0]}" 254eb8dc403SDave CobbleyEXTENDPKGEVER = "${@['','${PKGE}:'][d.getVar('PKGE').strip() != '']}" 255eb8dc403SDave CobbleyEXTENDPKGV ?= "${EXTENDPKGEVER}${PKGV}-${PKGR}" 256eb8dc403SDave Cobbley 257eb8dc403SDave Cobbley# Base package name 258eb8dc403SDave Cobbley# Automatically derives "foo" from "foo-native", "foo-cross" or "foo-initial" 259eb8dc403SDave Cobbley# otherwise it is the same as PN and P 260eb8dc403SDave CobbleySPECIAL_PKGSUFFIX = "-native -cross -initial -intermediate -crosssdk -cross-canadian" 261eb8dc403SDave CobbleyBPN = "${@oe.utils.prune_suffix(d.getVar('PN'), d.getVar('SPECIAL_PKGSUFFIX').split(), d)}" 262eb8dc403SDave CobbleyBP = "${BPN}-${PV}" 263eb8dc403SDave Cobbley 264eb8dc403SDave Cobbley# Package info. 265eb8dc403SDave Cobbley 266eb8dc403SDave CobbleySECTION = "base" 267eb8dc403SDave CobbleyPRIORITY = "optional" 268eb8dc403SDave CobbleySUMMARY ?= "${PN} version ${PV}-${PR}" 269eb8dc403SDave CobbleyDESCRIPTION ?= "${SUMMARY}." 270eb8dc403SDave Cobbley 271eb8dc403SDave Cobbley# The following two are commented out because they result in a recursive 272eb8dc403SDave Cobbley# definition of the variable in some corner cases. These are left in 273eb8dc403SDave Cobbley# to illustrate the intended behavior. 2740ca19ccfSPatrick Williams#SUMMARY:${PN} ?= "${SUMMARY}" 2750ca19ccfSPatrick Williams#DESCRIPTION:${PN} ?= "${DESCRIPTION}" 276eb8dc403SDave Cobbley 277213cb269SPatrick WilliamsSUMMARY:${PN}-src ?= "${SUMMARY} - Source files" 278213cb269SPatrick WilliamsDESCRIPTION:${PN}-src ?= "${DESCRIPTION} \ 27919323693SBrad BishopThis package contains sources for debugging purposes." 28019323693SBrad Bishop 281213cb269SPatrick WilliamsSUMMARY:${PN}-dbg ?= "${SUMMARY} - Debugging files" 282213cb269SPatrick WilliamsDESCRIPTION:${PN}-dbg ?= "${DESCRIPTION} \ 283eb8dc403SDave CobbleyThis package contains ELF symbols and related sources for debugging purposes." 284eb8dc403SDave Cobbley 285213cb269SPatrick WilliamsSUMMARY:${PN}-dev ?= "${SUMMARY} - Development files" 286213cb269SPatrick WilliamsDESCRIPTION:${PN}-dev ?= "${DESCRIPTION} \ 287eb8dc403SDave CobbleyThis package contains symbolic links, header files, and \ 288eb8dc403SDave Cobbleyrelated items necessary for software development." 289eb8dc403SDave Cobbley 290213cb269SPatrick WilliamsSUMMARY:${PN}-staticdev ?= "${SUMMARY} - Development files (Static Libraries)" 291213cb269SPatrick WilliamsDESCRIPTION:${PN}-staticdev ?= "${DESCRIPTION} \ 292eb8dc403SDave CobbleyThis package contains static libraries for software development." 293eb8dc403SDave Cobbley 294213cb269SPatrick WilliamsSUMMARY:${PN}-doc ?= "${SUMMARY} - Documentation files" 295213cb269SPatrick WilliamsDESCRIPTION:${PN}-doc ?= "${DESCRIPTION} \ 296eb8dc403SDave CobbleyThis package contains documentation." 297eb8dc403SDave Cobbley 298eb8dc403SDave CobbleyLICENSE ??= "INVALID" 299eb8dc403SDave CobbleyMAINTAINER = "OE-Core Developers <openembedded-core@lists.openembedded.org>" 300eb8dc403SDave CobbleyHOMEPAGE = "" 301eb8dc403SDave Cobbley 302eb8dc403SDave Cobbley# Package dependencies and provides. 303eb8dc403SDave Cobbley 304eb8dc403SDave Cobbley# Ensure that -dev packages recommend the corresponding -dev packages of their 305eb8dc403SDave Cobbley# deps, and the same for -dbg. 306eb8dc403SDave CobbleyDEPCHAIN_PRE = "" 307eb8dc403SDave CobbleyDEPCHAIN_POST = "-dev -dbg" 308eb8dc403SDave Cobbley 309eb8dc403SDave CobbleyDEPENDS = "" 310eb8dc403SDave CobbleyPROVIDES = "" 311213cb269SPatrick WilliamsPROVIDES:prepend = "${PN} " 312eb8dc403SDave Cobbley 3137e0e3c0cSAndrew GeisslerBB_MULTI_PROVIDER_ALLOWED = "virtual/libintl virtual/libintl-native virtual/nativesdk-libintl virtual/xserver virtual/update-alternatives-native virtual/update-alternatives" 314eb8dc403SDave Cobbley 315eb8dc403SDave CobbleySOLIBS = ".so.*" 316213cb269SPatrick WilliamsSOLIBS:darwin = ".dylib" 317eb8dc403SDave Cobbley 318eb8dc403SDave CobbleySOLIBSDEV = ".so" 319eb8dc403SDave Cobbley# Due to the ordering of PACKAGES and the naming of the dev symlinks on darwin, 320eb8dc403SDave Cobbley# we can't make the symlinks end up in the -dev packages easily at this point. This hack 321eb8dc403SDave Cobbley# at least means builds aren't completely broken and symlinks don't take up much space. 322213cb269SPatrick WilliamsSOLIBSDEV:darwin = ".dylibbroken" 323eb8dc403SDave Cobbley 32419323693SBrad BishopPACKAGE_DEBUG_SPLIT_STYLE ?= "debug-with-srcpkg" 32519323693SBrad Bishop 326eb8dc403SDave CobbleyPACKAGE_BEFORE_PN ?= "" 32719323693SBrad BishopPACKAGES = "${PN}-src ${PN}-dbg ${PN}-staticdev ${PN}-dev ${PN}-doc ${PN}-locale ${PACKAGE_BEFORE_PN} ${PN}" 328eb8dc403SDave CobbleyPACKAGES_DYNAMIC = "^${PN}-locale-.*" 329eb8dc403SDave CobbleyFILES = "" 330eb8dc403SDave Cobbley 331213cb269SPatrick WilliamsFILES:${PN} = "${bindir}/* ${sbindir}/* ${libexecdir}/* ${libdir}/lib*${SOLIBS} \ 332eb8dc403SDave Cobbley ${sysconfdir} ${sharedstatedir} ${localstatedir} \ 333eb8dc403SDave Cobbley ${base_bindir}/* ${base_sbindir}/* \ 334eb8dc403SDave Cobbley ${base_libdir}/*${SOLIBS} \ 335eb8dc403SDave Cobbley ${base_prefix}/lib/udev ${prefix}/lib/udev \ 336eb8dc403SDave Cobbley ${base_libdir}/udev ${libdir}/udev \ 337eb8dc403SDave Cobbley ${datadir}/${BPN} ${libdir}/${BPN}/* \ 338eb8dc403SDave Cobbley ${datadir}/pixmaps ${datadir}/applications \ 339eb8dc403SDave Cobbley ${datadir}/idl ${datadir}/omf ${datadir}/sounds \ 340eb8dc403SDave Cobbley ${libdir}/bonobo/servers" 341eb8dc403SDave Cobbley 342213cb269SPatrick WilliamsFILES:${PN}-bin = "${bindir}/* ${sbindir}/*" 343eb8dc403SDave Cobbley 344213cb269SPatrick WilliamsFILES:${PN}-doc = "${docdir} ${mandir} ${infodir} ${datadir}/gtk-doc \ 345eb8dc403SDave Cobbley ${datadir}/gnome/help" 346213cb269SPatrick WilliamsSECTION:${PN}-doc = "doc" 347eb8dc403SDave Cobbley 348eb8dc403SDave CobbleyFILES_SOLIBSDEV ?= "${base_libdir}/lib*${SOLIBSDEV} ${libdir}/lib*${SOLIBSDEV}" 349213cb269SPatrick WilliamsFILES:${PN}-dev = "${includedir} ${FILES_SOLIBSDEV} ${libdir}/*.la \ 350eb8dc403SDave Cobbley ${libdir}/*.o ${libdir}/pkgconfig ${datadir}/pkgconfig \ 351eb8dc403SDave Cobbley ${datadir}/aclocal ${base_libdir}/*.o \ 3521a4b7ee2SBrad Bishop ${libdir}/${BPN}/*.la ${base_libdir}/*.la \ 3531a4b7ee2SBrad Bishop ${libdir}/cmake ${datadir}/cmake" 354213cb269SPatrick WilliamsSECTION:${PN}-dev = "devel" 355213cb269SPatrick WilliamsALLOW_EMPTY:${PN}-dev = "1" 356615f2f11SAndrew GeisslerDEV_PKG_DEPENDENCY = "${PN} (= ${EXTENDPKGV})" 357615f2f11SAndrew GeisslerRRECOMMENDS:${PN}-dev = "${DEV_PKG_DEPENDENCY}" 358eb8dc403SDave Cobbley 359213cb269SPatrick WilliamsFILES:${PN}-staticdev = "${libdir}/*.a ${base_libdir}/*.a ${libdir}/${BPN}/*.a" 360213cb269SPatrick WilliamsSECTION:${PN}-staticdev = "devel" 361213cb269SPatrick WilliamsRDEPENDS:${PN}-staticdev = "${PN}-dev (= ${EXTENDPKGV})" 362eb8dc403SDave Cobbley 363213cb269SPatrick WilliamsFILES:${PN}-dbg = "/usr/lib/debug /usr/lib/debug-static /usr/src/debug" 364213cb269SPatrick WilliamsSECTION:${PN}-dbg = "devel" 365213cb269SPatrick WilliamsALLOW_EMPTY:${PN}-dbg = "1" 366eb8dc403SDave Cobbley 36719323693SBrad Bishop# The files list for source packages are dynamically set based on 36819323693SBrad Bishop# PACKAGE_DEBUG_SPLIT_STYLE 369213cb269SPatrick WilliamsFILES:${PN}-src = "" 370213cb269SPatrick WilliamsSECTION:${PN}-src = "devel" 37119323693SBrad Bishop 372213cb269SPatrick WilliamsFILES:${PN}-locale = "${datadir}/locale" 373eb8dc403SDave Cobbley 374eb8dc403SDave Cobbley# File manifest 375eb8dc403SDave Cobbley 376eb8dc403SDave CobbleyFILE_DIRNAME = "${@os.path.dirname(d.getVar('FILE', False))}" 377eb8dc403SDave Cobbley# FILESPATH is set in base.bbclass 378eb8dc403SDave Cobbley#FILESPATH = "${FILE_DIRNAME}/${PF}:${FILE_DIRNAME}/${P}:${FILE_DIRNAME}/${PN}:${FILE_DIRNAME}/${BP}:${FILE_DIRNAME}/${BPN}:${FILE_DIRNAME}/files:${FILE_DIRNAME}" 379eb8dc403SDave Cobbley# This default was only used for checking 380eb8dc403SDave CobbleyFILESEXTRAPATHS ?= "__default:" 381eb8dc403SDave Cobbley 382eb8dc403SDave Cobbley# The default list of fs-perms files to process. If the list is empty only 383eb8dc403SDave Cobbley# the builtin definitions will be used. Builtin definitions included: 384eb8dc403SDave Cobbley# base_prefix, prefix, exec_prefix, base_bindir, base_sbindir, base_libdir, 385eb8dc403SDave Cobbley# datadir, sysconfdir, servicedir, sharedstatedir, localstatedir, infodir, 386*44b3caf2SPatrick Williams# mandir, docdir, bindir, sbindir, libexecdir, libdir and includedir 387eb8dc403SDave CobbleyFILESYSTEM_PERMS_TABLES ?= "${@'files/fs-perms.txt' if oe.types.boolean(d.getVar('VOLATILE_LOG_DIR')) else 'files/fs-perms-persistent-log.txt'}" 388eb8dc403SDave Cobbley 389eb8dc403SDave Cobbley################################################################## 390eb8dc403SDave Cobbley# General work and output directories for the build system. 391eb8dc403SDave Cobbley################################################################## 392eb8dc403SDave Cobbley 39378b72798SAndrew GeisslerTCMODE ??= "default" 39478b72798SAndrew GeisslerTCLIBC ??= "glibc" 39587f5cff0SAndrew GeisslerTC_CXX_RUNTIME ??= "gnu" 396eb8dc403SDave CobbleyTMPDIR ?= "${TOPDIR}/tmp" 397c9f7865aSAndrew Geissler 398517393d9SAndrew GeisslerCACHE = "${TMPDIR}/cache" 399eb8dc403SDave Cobbley# The persistent cache should be shared by all builds 400eb8dc403SDave CobbleyPERSISTENT_DIR = "${TOPDIR}/cache" 401eb8dc403SDave CobbleyLOG_DIR = "${TMPDIR}/log" 402eb8dc403SDave Cobbley 403eb8dc403SDave CobbleySTAMPS_DIR ?= "${TMPDIR}/stamps" 4042a25492cSPatrick WilliamsSTAMP = "${STAMPS_DIR}/${MULTIMACH_TARGET_SYS}/${PN}/${PV}" 405eb8dc403SDave CobbleySTAMPCLEAN = "${STAMPS_DIR}/${MULTIMACH_TARGET_SYS}/${PN}/*-*" 406eb8dc403SDave CobbleyBASE_WORKDIR ?= "${TMPDIR}/work" 4072a25492cSPatrick WilliamsWORKDIR = "${BASE_WORKDIR}/${MULTIMACH_TARGET_SYS}/${PN}/${PV}" 408eb8dc403SDave CobbleyT = "${WORKDIR}/temp" 409eb8dc403SDave CobbleyD = "${WORKDIR}/image" 410eb8dc403SDave CobbleyS = "${WORKDIR}/${BP}" 411eb8dc403SDave CobbleyB = "${S}" 412eb8dc403SDave Cobbley 413eb8dc403SDave CobbleySTAGING_DIR = "${TMPDIR}/sysroots" 414eb8dc403SDave CobbleyCOMPONENTS_DIR = "${STAGING_DIR}-components" 415eb8dc403SDave CobbleyRECIPE_SYSROOT = "${WORKDIR}/recipe-sysroot" 416eb8dc403SDave CobbleyRECIPE_SYSROOT_NATIVE = "${WORKDIR}/recipe-sysroot-native" 417eb8dc403SDave Cobbley 418eb8dc403SDave CobbleySTAGING_DIR_NATIVE = "${RECIPE_SYSROOT_NATIVE}" 419eb8dc403SDave CobbleySTAGING_BINDIR_NATIVE = "${STAGING_DIR_NATIVE}${bindir_native}" 420eb8dc403SDave CobbleySTAGING_BINDIR_CROSS = "${STAGING_BINDIR}/crossscripts" 421eb8dc403SDave CobbleySTAGING_BINDIR_TOOLCHAIN = "${STAGING_DIR_NATIVE}${bindir_native}/${TARGET_ARCH}${TARGET_VENDOR}-${TARGET_OS}" 422eb8dc403SDave CobbleySTAGING_LIBDIR_NATIVE = "${STAGING_DIR_NATIVE}${libdir_native}" 423eb8dc403SDave CobbleySTAGING_LIBEXECDIR_NATIVE = "${STAGING_DIR_NATIVE}${libexecdir_native}" 424eb8dc403SDave CobbleySTAGING_BASE_LIBDIR_NATIVE = "${STAGING_DIR_NATIVE}${base_libdir_native}" 425eb8dc403SDave CobbleySTAGING_SBINDIR_NATIVE = "${STAGING_DIR_NATIVE}${sbindir_native}" 426eb8dc403SDave CobbleySTAGING_INCDIR_NATIVE = "${STAGING_DIR_NATIVE}${includedir_native}" 427eb8dc403SDave CobbleySTAGING_ETCDIR_NATIVE = "${STAGING_DIR_NATIVE}${sysconfdir_native}" 428eb8dc403SDave CobbleySTAGING_DATADIR_NATIVE = "${STAGING_DIR_NATIVE}${datadir_native}" 429eb8dc403SDave Cobbley 430eb8dc403SDave CobbleySTAGING_DIR_HOST = "${RECIPE_SYSROOT}" 431eb8dc403SDave CobbleySTAGING_BINDIR = "${STAGING_DIR_HOST}${bindir}" 432eb8dc403SDave CobbleySTAGING_LIBDIR = "${STAGING_DIR_HOST}${libdir}" 433eb8dc403SDave CobbleySTAGING_LIBEXECDIR = "${STAGING_DIR_HOST}${libexecdir}" 434eb8dc403SDave CobbleySTAGING_BASELIBDIR = "${STAGING_DIR_HOST}${base_libdir}" 435eb8dc403SDave CobbleySTAGING_INCDIR = "${STAGING_DIR_HOST}${includedir}" 436eb8dc403SDave CobbleySTAGING_DATADIR = "${STAGING_DIR_HOST}${datadir}" 437eb8dc403SDave CobbleySTAGING_EXECPREFIXDIR = "${STAGING_DIR_HOST}${exec_prefix}" 438eb8dc403SDave CobbleySTAGING_LOADER_DIR = "${STAGING_DIR_HOST}/loader" 439eb8dc403SDave CobbleySTAGING_FIRMWARE_DIR = "${STAGING_DIR_HOST}/firmware" 440eb8dc403SDave Cobbley 441eb8dc403SDave CobbleySTAGING_DIR_TARGET = "${RECIPE_SYSROOT}" 442eb8dc403SDave Cobbley 443eb8dc403SDave Cobbley# Setting DEPLOY_DIR outside of TMPDIR is helpful, when you are using 444eb8dc403SDave Cobbley# packaged staging and/or multimachine. 445eb8dc403SDave CobbleyDEPLOY_DIR ?= "${TMPDIR}/deploy" 446eb8dc403SDave CobbleyDEPLOY_DIR_IPK = "${DEPLOY_DIR}/ipk" 447eb8dc403SDave CobbleyDEPLOY_DIR_RPM = "${DEPLOY_DIR}/rpm" 448eb8dc403SDave CobbleyDEPLOY_DIR_DEB = "${DEPLOY_DIR}/deb" 449eb8dc403SDave CobbleyDEPLOY_DIR_IMAGE ?= "${DEPLOY_DIR}/images/${MACHINE}" 4505a43b434SAndrew GeisslerDEPLOY_DIR_TOOLS = "${DEPLOY_DIR}/tools" 451eb8dc403SDave Cobbley 452eb8dc403SDave CobbleyPKGDATA_DIR = "${TMPDIR}/pkgdata/${MACHINE}" 453eff27476SAndrew GeisslerPKGDATA_DIR_SDK = "${TMPDIR}/pkgdata/${SDK_SYS}" 454eb8dc403SDave Cobbley 455eb8dc403SDave Cobbley################################################################## 456eb8dc403SDave Cobbley# SDK variables. 457eb8dc403SDave Cobbley################################################################## 458eb8dc403SDave Cobbley 459eb8dc403SDave CobbleySDK_NAME_PREFIX ?= "oecore" 460220dafdbSAndrew GeisslerSDK_NAME = "${SDK_NAME_PREFIX}-${IMAGE_BASENAME}-${SDK_ARCH}-${TUNE_PKGARCH}-${MACHINE}" 461213cb269SPatrick WilliamsSDKPATH = "/usr/local/oe-sdk-hardcoded-buildpath" 462eb8dc403SDave CobbleySDKPATHNATIVE = "${SDKPATH}/sysroots/${SDK_SYS}" 463213cb269SPatrick Williams# The path to default to installing the SDK to 464213cb269SPatrick WilliamsSDKPATHINSTALL = "/usr/local/${SDK_NAME_PREFIX}-${SDK_ARCH}" 465eb8dc403SDave Cobbley 466eb8dc403SDave Cobbley################################################################## 467eb8dc403SDave Cobbley# Kernel info. 468eb8dc403SDave Cobbley################################################################## 469eb8dc403SDave Cobbley 470028142bdSAndrew GeisslerOLDEST_KERNEL = "5.15" 471eb8dc403SDave Cobbley 472eb8dc403SDave Cobbley# SDK_OLDEST_KERNEL can't be set using overrides since there are 473eb8dc403SDave Cobbley# none for the SDK architecture. Best to set it from a machine-sdk 474eb8dc403SDave Cobbley# include file if you need an SDK arch-specific value 475eb8dc403SDave CobbleySDK_OLDEST_KERNEL = "3.2.0" 476eb8dc403SDave Cobbley 477eb8dc403SDave Cobbley# Define where the kernel headers are installed on the target as well as where 478eb8dc403SDave Cobbley# they are staged. 479eb8dc403SDave CobbleyKERNEL_SRC_PATH = "/usr/src/kernel" 480eb8dc403SDave Cobbley 481eb8dc403SDave CobbleySTAGING_KERNEL_DIR = "${TMPDIR}/work-shared/${MACHINE}/kernel-source" 482eb8dc403SDave CobbleySTAGING_KERNEL_BUILDDIR = "${TMPDIR}/work-shared/${MACHINE}/kernel-build-artifacts" 483eb8dc403SDave Cobbley 484eb8dc403SDave Cobbley################################################################## 485eb8dc403SDave Cobbley# Specific image creation and rootfs population info. 486eb8dc403SDave Cobbley################################################################## 487eb8dc403SDave Cobbley 488eb8dc403SDave CobbleyIMAGE_ROOTFS = "${WORKDIR}/rootfs" 489eb8dc403SDave Cobbley 490eb8dc403SDave Cobbley# This option allows for a percentage overage of the actual image size rather than a 491eb8dc403SDave Cobbley# fixed extra space, this is space needed for initial startup and basic operations. 492eb8dc403SDave CobbleyIMAGE_OVERHEAD_FACTOR ?= "1.3" 493eb8dc403SDave Cobbley# This option allows for adding additional space in K above and beyond what the 494eb8dc403SDave Cobbley# IMAGE_OVERHEAD_FACTOR might add. This space is for additional packages, user data, ... 495eb8dc403SDave Cobbley# To set a fixed size then overriding IMAGE_ROOTFS_SIZE with the max size one wants 496eb8dc403SDave Cobbley# should do the trick 497eb8dc403SDave CobbleyIMAGE_ROOTFS_EXTRA_SPACE ?= "0" 498eb8dc403SDave Cobbley 499eb8dc403SDave CobbleyEXTRA_IMAGEDEPENDS = "" 500eb8dc403SDave Cobbley 501eb8dc403SDave Cobbley################################################################## 502eb8dc403SDave Cobbley# Toolchain info. 503eb8dc403SDave Cobbley################################################################## 504eb8dc403SDave Cobbley 505213cb269SPatrick WilliamsPATH: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}:" 506eb8dc403SDave Cobbleyexport PATH 507eb8dc403SDave Cobbley 508eb8dc403SDave Cobbley################################################################## 509eb8dc403SDave Cobbley# Build utility info. 510eb8dc403SDave Cobbley################################################################## 511eb8dc403SDave Cobbley 51295ac1b8dSAndrew Geissler# Directory with symlinks to host tools used by build 513eb8dc403SDave CobbleyHOSTTOOLS_DIR = "${TMPDIR}/hosttools" 514eb8dc403SDave Cobbley 515eb8dc403SDave Cobbley# Tools needed to run builds with OE-Core 516eb8dc403SDave CobbleyHOSTTOOLS += " \ 5175082cc7fSAndrew Geissler [ ar as awk basename bash bunzip2 bzip2 cat chgrp chmod chown chrpath cmp comm cp cpio \ 518eb8dc403SDave Cobbley cpp cut date dd diff diffstat dirname du echo egrep env expand expr false \ 519eb8dc403SDave Cobbley fgrep file find flock g++ gawk gcc getconf getopt git grep gunzip gzip \ 520d159c7fbSAndrew Geissler head hostname iconv id install ld ldd ln ls lz4c make md5sum mkdir mkfifo mknod \ 52182c905dcSAndrew Geissler mktemp mv nm objcopy objdump od patch perl pr printf pwd \ 522d159c7fbSAndrew Geissler python3 pzstd ranlib readelf readlink realpath rm rmdir rpcgen sed seq sh \ 52382c905dcSAndrew Geissler sha1sum sha224sum sha256sum sha384sum sha512sum \ 524eb8dc403SDave Cobbley sleep sort split stat strings strip tail tar tee test touch tr true uname \ 525520786ccSPatrick Williams uniq unzstd wc wget which xargs zstd \ 526eb8dc403SDave Cobbley" 527eb8dc403SDave Cobbley 528eb8dc403SDave Cobbley# Tools needed to run testimage runtime image testing 5291a4b7ee2SBrad BishopHOSTTOOLS += "${@'ip ping ps scp ssh stty' if (bb.utils.contains_any('IMAGE_CLASSES', 'testimage testsdk', True, False, d) or any(x in (d.getVar("BBINCLUDED") or "") for x in ["testimage.bbclass", "testsdk.bbclass"])) else ''}" 530eb8dc403SDave Cobbley 531169d7bccSPatrick Williams# Used by archiver.bbclass when compression is xz 532169d7bccSPatrick WilliamsHOSTTOOLS += "${@'xz' if (('archiver.bbclass' in (d.getVar('BBINCLUDED') or '')) and (d.getVarFlag('ARCHIVER_MODE', 'compression') == 'xz')) else ''}" 533169d7bccSPatrick Williams 534eb8dc403SDave Cobbley# Link to these if present 535eff27476SAndrew GeisslerHOSTTOOLS_NONFATAL += "aws gcc-ar gpg gpg-agent ld.bfd ld.gold nc pigz sftp socat ssh sudo" 536eb8dc403SDave Cobbley 537eb8dc403SDave Cobbley# Temporary add few more detected in bitbake world 538eb8dc403SDave CobbleyHOSTTOOLS_NONFATAL += "join nl size yes zcat" 539eb8dc403SDave Cobbley 540eb8dc403SDave Cobbley# Used by bzr fetcher 541eb8dc403SDave CobbleyHOSTTOOLS_NONFATAL += "bzr" 542eb8dc403SDave Cobbley 543eb8dc403SDave Cobbley# Used by ssh fetcher 544eb8dc403SDave CobbleyHOSTTOOLS_NONFATAL += "scp" 545eb8dc403SDave Cobbley 546864cc43bSPatrick Williams# Used by Mercurial fetcher 547864cc43bSPatrick WilliamsHOSTTOOLS_NONFATAL += "hg" 548864cc43bSPatrick Williams 549da295319SPatrick Williams# Used by gcp fetcher 550da295319SPatrick WilliamsHOSTTOOLS_NONFATAL += "gsutil" 551da295319SPatrick Williams 552c342db35SBrad Bishop# Link to git-lfs if present 553c342db35SBrad BishopHOSTTOOLS_NONFATAL += "git-lfs" 554c342db35SBrad Bishop 555eb8dc403SDave CobbleyCCACHE ??= "" 556eb8dc403SDave Cobbley 557eb8dc403SDave CobbleyTOOLCHAIN_OPTIONS = " --sysroot=${STAGING_DIR_TARGET}" 558eb8dc403SDave Cobbley 559eb8dc403SDave Cobbleyexport CC = "${CCACHE}${HOST_PREFIX}gcc ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}" 560eb8dc403SDave Cobbleyexport CXX = "${CCACHE}${HOST_PREFIX}g++ ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}" 561ac13d5f3SPatrick Williamsexport FC = "${HOST_PREFIX}gfortran ${HOST_CC_ARCH}${TOOLCHAIN_OPTIONS}" 562eb8dc403SDave Cobbleyexport CPP = "${HOST_PREFIX}gcc -E${TOOLCHAIN_OPTIONS} ${HOST_CC_ARCH}" 563eb8dc403SDave Cobbleyexport LD = "${HOST_PREFIX}ld${TOOLCHAIN_OPTIONS} ${HOST_LD_ARCH}" 564eb8dc403SDave Cobbleyexport CCLD = "${CC}" 56519323693SBrad Bishopexport AR = "${HOST_PREFIX}gcc-ar" 566eb8dc403SDave Cobbleyexport AS = "${HOST_PREFIX}as ${HOST_AS_ARCH}" 56719323693SBrad Bishopexport RANLIB = "${HOST_PREFIX}gcc-ranlib" 568eb8dc403SDave Cobbleyexport STRIP = "${HOST_PREFIX}strip" 569eb8dc403SDave Cobbleyexport OBJCOPY = "${HOST_PREFIX}objcopy" 570eb8dc403SDave Cobbleyexport OBJDUMP = "${HOST_PREFIX}objdump" 571eb8dc403SDave Cobbleyexport STRINGS = "${HOST_PREFIX}strings" 572c926e17cSAndrew Geisslerexport NM = "${HOST_PREFIX}gcc-nm" 573eb8dc403SDave Cobbleyexport READELF = "${HOST_PREFIX}readelf" 574eb8dc403SDave CobbleyPYTHON = "${@sys.executable}" 575eb8dc403SDave Cobbley 576eb8dc403SDave Cobbleyexport BUILD_CC = "${CCACHE}${BUILD_PREFIX}gcc ${BUILD_CC_ARCH}" 577eb8dc403SDave Cobbleyexport BUILD_CXX = "${CCACHE}${BUILD_PREFIX}g++ ${BUILD_CC_ARCH}" 578ac13d5f3SPatrick Williamsexport BUILD_FC = "${BUILD_PREFIX}gfortran ${BUILD_CC_ARCH}" 579eb8dc403SDave Cobbleyexport BUILD_CPP = "${BUILD_PREFIX}gcc ${BUILD_CC_ARCH} -E" 580eb8dc403SDave Cobbleyexport BUILD_LD = "${BUILD_PREFIX}ld ${BUILD_LD_ARCH}" 581eb8dc403SDave Cobbleyexport BUILD_CCLD = "${BUILD_PREFIX}gcc ${BUILD_CC_ARCH}" 582eb8dc403SDave Cobbleyexport BUILD_AR = "${BUILD_PREFIX}ar" 583eb8dc403SDave Cobbleyexport BUILD_AS = "${BUILD_PREFIX}as ${BUILD_AS_ARCH}" 584595f6308SAndrew Geisslerexport BUILD_RANLIB = "${BUILD_PREFIX}ranlib -D" 585eb8dc403SDave Cobbleyexport BUILD_STRIP = "${BUILD_PREFIX}strip" 58695ac1b8dSAndrew GeisslerBUILD_OBJCOPY = "${BUILD_PREFIX}objcopy" 58795ac1b8dSAndrew GeisslerBUILD_OBJDUMP = "${BUILD_PREFIX}objdump" 588eb8dc403SDave Cobbleyexport BUILD_NM = "${BUILD_PREFIX}nm" 58995ac1b8dSAndrew GeisslerBUILD_READELF = "${BUILD_PREFIX}readelf" 590eb8dc403SDave Cobbley 591eb8dc403SDave Cobbleyexport MAKE = "make" 592eb8dc403SDave CobbleyEXTRA_OEMAKE = "" 593eb8dc403SDave CobbleyEXTRA_OECONF = "" 594eb8dc403SDave Cobbleyexport LC_ALL = "en_US.UTF-8" 595eb8dc403SDave Cobbleyexport TZ = 'UTC' 596eb8dc403SDave Cobbley 597eb8dc403SDave Cobbley################################################################## 598eb8dc403SDave Cobbley# Patch handling. 599eb8dc403SDave Cobbley################################################################## 600eb8dc403SDave CobbleyPATCHTOOL = "quilt" 601eb8dc403SDave CobbleyPATCHRESOLVE = "noop" 602eb8dc403SDave Cobbley 603eb8dc403SDave Cobbley################################################################## 604eb8dc403SDave Cobbley# Build flags and options. 605eb8dc403SDave Cobbley################################################################## 606eb8dc403SDave Cobbley 607eb8dc403SDave Cobbleyexport BUILD_CPPFLAGS = "-isystem${STAGING_INCDIR_NATIVE}" 608eb8dc403SDave CobbleyBUILDSDK_CPPFLAGS = "" 609eb8dc403SDave Cobbleyexport CPPFLAGS = "${TARGET_CPPFLAGS}" 61096ff1984SBrad BishopTARGET_CPPFLAGS = "" 611eb8dc403SDave Cobbley 612eb8dc403SDave Cobbleyexport BUILD_CFLAGS = "${BUILD_CPPFLAGS} ${BUILD_OPTIMIZATION}" 61319323693SBrad BishopBUILDSDK_CFLAGS = "${BUILDSDK_CPPFLAGS} ${BUILD_OPTIMIZATION} ${DEBUG_PREFIX_MAP}" 614eb8dc403SDave Cobbleyexport CFLAGS = "${TARGET_CFLAGS}" 61596ff1984SBrad BishopTARGET_CFLAGS = "${TARGET_CPPFLAGS} ${SELECTED_OPTIMIZATION}" 616eb8dc403SDave Cobbley 617eb8dc403SDave Cobbleyexport BUILD_CXXFLAGS = "${BUILD_CFLAGS}" 618eb8dc403SDave CobbleyBUILDSDK_CXXFLAGS = "${BUILDSDK_CFLAGS}" 619eb8dc403SDave Cobbleyexport CXXFLAGS = "${TARGET_CXXFLAGS}" 62096ff1984SBrad BishopTARGET_CXXFLAGS = "${TARGET_CFLAGS}" 621eb8dc403SDave Cobbley 622eb8dc403SDave Cobbleyexport BUILD_LDFLAGS = "-L${STAGING_LIBDIR_NATIVE} \ 623eb8dc403SDave Cobbley -L${STAGING_BASE_LIBDIR_NATIVE} \ 62419323693SBrad Bishop -Wl,--enable-new-dtags \ 625eb8dc403SDave Cobbley -Wl,-rpath-link,${STAGING_LIBDIR_NATIVE} \ 626eb8dc403SDave Cobbley -Wl,-rpath-link,${STAGING_BASE_LIBDIR_NATIVE} \ 627eb8dc403SDave Cobbley -Wl,-rpath,${STAGING_LIBDIR_NATIVE} \ 628eb8dc403SDave Cobbley -Wl,-rpath,${STAGING_BASE_LIBDIR_NATIVE} \ 629eb8dc403SDave Cobbley -Wl,-O1" 630eb8dc403SDave Cobbley 631eb8dc403SDave CobbleyBUILDSDK_LDFLAGS = "-Wl,-O1" 632eb8dc403SDave Cobbley 633eb8dc403SDave CobbleyLINKER_HASH_STYLE ??= "gnu" 634eb8dc403SDave Cobbley 635eb8dc403SDave CobbleyTARGET_LINK_HASH_STYLE ?= "${@['-Wl,--hash-style=gnu',''][d.getVar('LINKER_HASH_STYLE') != 'gnu']}" 636eb8dc403SDave Cobbley 6371a4b7ee2SBrad BishopASNEEDED ?= "-Wl,--as-needed" 6381a4b7ee2SBrad Bishop 639eb8dc403SDave Cobbleyexport LDFLAGS = "${TARGET_LDFLAGS}" 6400ca19ccfSPatrick WilliamsTARGET_LDFLAGS = "-Wl,-O1 ${TARGET_LINK_HASH_STYLE} ${ASNEEDED} ${DEBUG_PREFIX_MAP}" 64182c905dcSAndrew Geissler# mips does not support GNU hash style therefore we override 642213cb269SPatrick WilliamsLINKER_HASH_STYLE:mipsarch:libc-musl = "sysv" 643eb8dc403SDave Cobbley 644eb8dc403SDave Cobbley# Pass parallel make options to the compile task 645213cb269SPatrick WilliamsEXTRA_OEMAKE:prepend:task-compile = "${PARALLEL_MAKE} " 646eb8dc403SDave CobbleyPARALLEL_MAKEINST ??= "${PARALLEL_MAKE}" 64793c203f3SPatrick WilliamsPARALLEL_MAKEINST[vardepvalue] = "1" 648eb8dc403SDave Cobbley# Pass parallel make options to the install task 649213cb269SPatrick WilliamsEXTRA_OEMAKE:prepend:task-install = "${PARALLEL_MAKEINST} " 650eb8dc403SDave Cobbley 651eb8dc403SDave Cobbley################################################################## 652eb8dc403SDave Cobbley# Optimization flags. 653eb8dc403SDave Cobbley################################################################## 654ac13d5f3SPatrick WilliamsTARGET_DBGSRC_DIR ?= "/usr/src/debug/${PN}/${PV}" 655eb8dc403SDave Cobbley# Beware: applied last to first 656e760df85SPatrick WilliamsDEBUG_PREFIX_MAP ?= "-fcanon-prefix-map \ 657ac13d5f3SPatrick Williams -fmacro-prefix-map=${S}=${TARGET_DBGSRC_DIR} \ 658ac13d5f3SPatrick Williams -fdebug-prefix-map=${S}=${TARGET_DBGSRC_DIR} \ 659ac13d5f3SPatrick Williams -fmacro-prefix-map=${B}=${TARGET_DBGSRC_DIR} \ 660ac13d5f3SPatrick Williams -fdebug-prefix-map=${B}=${TARGET_DBGSRC_DIR} \ 661eb8dc403SDave Cobbley -fdebug-prefix-map=${STAGING_DIR_HOST}= \ 66292b42cb3SPatrick Williams -fmacro-prefix-map=${STAGING_DIR_HOST}= \ 663eb8dc403SDave Cobbley -fdebug-prefix-map=${STAGING_DIR_NATIVE}= \ 664eb8dc403SDave Cobbley" 665eb8dc403SDave CobbleyDEBUG_FLAGS ?= "-g -feliminate-unused-debug-types ${DEBUG_PREFIX_MAP}" 666eb8dc403SDave Cobbley 667eb8dc403SDave Cobbley# Disabled until the option works properly -feliminate-dwarf2-dups 668eb8dc403SDave CobbleyFULL_OPTIMIZATION = "-O2 -pipe ${DEBUG_FLAGS}" 66919323693SBrad BishopDEBUG_OPTIMIZATION = "-Og ${DEBUG_FLAGS} -pipe" 6701a4b7ee2SBrad BishopSELECTED_OPTIMIZATION = "${@d.getVar(oe.utils.vartrue('DEBUG_BUILD', 'DEBUG_OPTIMIZATION', 'FULL_OPTIMIZATION', d))}" 67119323693SBrad BishopSELECTED_OPTIMIZATION[vardeps] += "FULL_OPTIMIZATION DEBUG_OPTIMIZATION DEBUG_BUILD" 67219323693SBrad BishopBUILD_OPTIMIZATION = "${@oe.utils.vartrue('DEBUG_BUILD', '-Og -g -feliminate-unused-debug-types', '-O2', d)} -pipe" 67319323693SBrad BishopBUILD_OPTIMIZATION[vardeps] += "DEBUG_BUILD" 674eb8dc403SDave Cobbley 675eb8dc403SDave Cobbley################################################################## 676eff27476SAndrew Geissler# Reproducibility 677eff27476SAndrew Geissler################################################################## 678eff27476SAndrew Geissler 679eff27476SAndrew GeisslerSDE_DIR = "${WORKDIR}/source-date-epoch" 680eff27476SAndrew GeisslerSDE_FILE = "${SDE_DIR}/__source_date_epoch.txt" 681eff27476SAndrew GeisslerSDE_DEPLOYDIR = "${WORKDIR}/deploy-source-date-epoch" 682eff27476SAndrew Geissler 683eff27476SAndrew Geisslerexport PYTHONHASHSEED = "0" 684eff27476SAndrew Geisslerexport PERL_HASH_SEED = "0" 685eff27476SAndrew Geisslerexport SOURCE_DATE_EPOCH ?= "${@get_source_date_epoch_value(d)}" 686eff27476SAndrew Geissler# A SOURCE_DATE_EPOCH of '0' might be misinterpreted as no SDE 6877784c429SPatrick WilliamsSOURCE_DATE_EPOCH_FALLBACK ??= "1302044400" 688eff27476SAndrew GeisslerREPRODUCIBLE_TIMESTAMP_ROOTFS ??= "1520598896" 689eff27476SAndrew Geissler 690eff27476SAndrew Geissler################################################################## 691eb8dc403SDave Cobbley# Settings used by bitbake-layers. 692eb8dc403SDave Cobbley################################################################## 693c342db35SBrad BishopBBLAYERS_LAYERINDEX_URL ??= "https://layers.openembedded.org/layerindex/" 694eb8dc403SDave CobbleyBBLAYERS_FETCH_DIR ??= "${COREBASE}" 695eb8dc403SDave Cobbley 696eb8dc403SDave Cobbley################################################################## 697eb8dc403SDave Cobbley# Download locations and utilities. 698eb8dc403SDave Cobbley################################################################## 699eb8dc403SDave Cobbley 700c342db35SBrad BishopAPACHE_MIRROR = "https://archive.apache.org/dist" 701c926e17cSAndrew GeisslerCPAN_MIRROR = "https://search.cpan.org/CPAN" 702eb8dc403SDave CobbleyDEBIAN_MIRROR = "http://ftp.debian.org/debian/pool" 703eb8dc403SDave CobbleyGENTOO_MIRROR = "http://distfiles.gentoo.org/distfiles" 704004d4995SBrad BishopGNOME_GIT = "git://gitlab.gnome.org/GNOME" 705213cb269SPatrick WilliamsGNOME_MIRROR = "https://download.gnome.org/sources/" 706c342db35SBrad BishopGNU_MIRROR = "https://ftp.gnu.org/gnu" 707eb8dc403SDave CobbleyGNUPG_MIRROR = "https://www.gnupg.org/ftp/gcrypt" 708eb8dc403SDave CobbleyGPE_MIRROR = "http://gpe.linuxtogo.org/download/source" 709c342db35SBrad BishopKERNELORG_MIRROR = "https://cdn.kernel.org/pub" 710c926e17cSAndrew GeisslerSAMBA_MIRROR = "http://samba.org/samba/ftp" 711c926e17cSAndrew GeisslerSAVANNAH_GNU_MIRROR = "https://download.savannah.gnu.org/releases" 712c926e17cSAndrew GeisslerSAVANNAH_NONGNU_MIRROR = "https://download.savannah.nongnu.org/releases" 713c342db35SBrad BishopSOURCEFORGE_MIRROR = "https://downloads.sourceforge.net" 714c342db35SBrad BishopXLIBS_MIRROR = "https://xlibs.freedesktop.org/release" 715c68388fcSBrad BishopXORG_MIRROR = "https://www.x.org/releases/" 716eb8dc403SDave Cobbley 717eb8dc403SDave CobbleySRC_URI[vardepsexclude] += "\ 718eb8dc403SDave Cobbley APACHE_MIRROR \ 719eb8dc403SDave Cobbley CPAN_MIRROR \ 720eb8dc403SDave Cobbley DEBIAN_MIRROR \ 721eb8dc403SDave Cobbley GENTOO_MIRROR \ 722eb8dc403SDave Cobbley GNOME_GIT \ 723eb8dc403SDave Cobbley GNOME_MIRROR \ 724eb8dc403SDave Cobbley GNU_MIRROR \ 725eb8dc403SDave Cobbley GNUPG_MIRROR \ 726eb8dc403SDave Cobbley GPE_MIRROR \ 727eb8dc403SDave Cobbley KERNELORG_MIRROR \ 728c926e17cSAndrew Geissler SAMBA_MIRROR \ 729eb8dc403SDave Cobbley SAVANNAH_GNU_MIRROR \ 730eb8dc403SDave Cobbley SAVANNAH_NONGNU_MIRROR \ 731eb8dc403SDave Cobbley SOURCEFORGE_MIRROR \ 732eb8dc403SDave Cobbley XLIBS_MIRROR \ 733eb8dc403SDave Cobbley XORG_MIRROR \ 734eb8dc403SDave Cobbley" 735eb8dc403SDave Cobbley 736eb8dc403SDave Cobbley# You can use the mirror of your country to get faster downloads by putting 737eb8dc403SDave Cobbley# export DEBIAN_MIRROR = "http://ftp.de.debian.org/debian/pool" 738eb8dc403SDave Cobbley# into your local.conf 739eb8dc403SDave Cobbley 740eb8dc403SDave CobbleySRCDATE = "${DATE}" 741eb8dc403SDave CobbleySRCREV ??= "INVALID" 742eb8dc403SDave CobbleyAUTOREV = "${@bb.fetch2.get_autorev(d)}" 7435082cc7fSAndrew GeisslerSRCPV = "" 744eb8dc403SDave Cobbley 745eb8dc403SDave CobbleySRC_URI = "" 746eb8dc403SDave Cobbley 747eb8dc403SDave Cobbley# Use pseudo as the fakeroot implementation 748eb8dc403SDave CobbleyPSEUDO_LOCALSTATEDIR ?= "${WORKDIR}/pseudo/" 749eb8dc403SDave CobbleyPSEUDO_PASSWD ?= "${STAGING_DIR_TARGET}:${PSEUDO_SYSROOT}" 750eb8dc403SDave CobbleyPSEUDO_SYSROOT = "${COMPONENTS_DIR}/${BUILD_ARCH}/pseudo-native" 75190fd73cbSAndrew GeisslerPSEUDO_IGNORE_PATHS = "/usr/,/etc/,/lib,/dev/,/run/,${T},${WORKDIR}/recipe-sysroot,${SSTATE_DIR},${STAMPS_DIR}" 75290fd73cbSAndrew GeisslerPSEUDO_IGNORE_PATHS .= ",${TMPDIR}/sstate-control,${TMPDIR}/buildstats,${TMPDIR}/sysroots-components,${TMPDIR}/pkgdata" 75390fd73cbSAndrew GeisslerPSEUDO_IGNORE_PATHS .= ",${WORKDIR}/deploy-,${WORKDIR}/sstate-build-package_,${WORKDIR}/sstate-install-package_,${WORKDIR}/pkgdata-sysroot" 75490fd73cbSAndrew GeisslerPSEUDO_IGNORE_PATHS .= ",${DEPLOY_DIR},${BUILDHISTORY_DIR},${TOPDIR}/cache,${COREBASE}/scripts,${CCACHE_DIR}" 755f0343792SAndrew Geissler 756eb8dc403SDave Cobbleyexport PSEUDO_DISABLED = "1" 757eb8dc403SDave Cobbley#export PSEUDO_PREFIX = "${STAGING_DIR_NATIVE}${prefix_native}" 758eb8dc403SDave Cobbley#export PSEUDO_BINDIR = "${STAGING_DIR_NATIVE}${bindir_native}" 759eb8dc403SDave Cobbley#export PSEUDO_LIBDIR = "${STAGING_DIR_NATIVE}$PSEUDOBINDIR/../lib/pseudo/lib 760d1e89497SAndrew GeisslerFAKEROOTBASEENV = "PSEUDO_BINDIR=${PSEUDO_SYSROOT}${bindir_native} PSEUDO_LIBDIR=${PSEUDO_SYSROOT}${prefix_native}/lib/pseudo/lib PSEUDO_PREFIX=${PSEUDO_SYSROOT}${prefix_native} PSEUDO_IGNORE_PATHS=${@oe.path.canonicalize(d.getVar('PSEUDO_IGNORE_PATHS'))} PSEUDO_DISABLED=1 PYTHONDONTWRITEBYTECODE=1" 761eb8dc403SDave CobbleyFAKEROOTCMD = "${PSEUDO_SYSROOT}${bindir_native}/pseudo" 762d1e89497SAndrew GeisslerFAKEROOTENV = "PSEUDO_PREFIX=${PSEUDO_SYSROOT}${prefix_native} PSEUDO_LOCALSTATEDIR=${PSEUDO_LOCALSTATEDIR} PSEUDO_PASSWD=${PSEUDO_PASSWD} PSEUDO_NOSYMLINKEXP=1 PSEUDO_IGNORE_PATHS=${@oe.path.canonicalize(d.getVar('PSEUDO_IGNORE_PATHS'))} PSEUDO_DISABLED=0" 763eb8dc403SDave CobbleyFAKEROOTNOENV = "PSEUDO_UNLOAD=1" 764eb8dc403SDave CobbleyFAKEROOTDIRS = "${PSEUDO_LOCALSTATEDIR}" 76590fd73cbSAndrew GeisslerFAKEROOTLOGS = "${WORKDIR}/pseudo/pseudo.log" 766eb8dc403SDave CobbleyPREFERRED_PROVIDER_virtual/fakeroot-native ?= "pseudo-native" 767eb8dc403SDave Cobbley 768eb8dc403SDave Cobbley################################################################## 769eb8dc403SDave Cobbley# Not sure about the rest of this yet. 770eb8dc403SDave Cobbley################################################################## 771eb8dc403SDave Cobbley 772eb8dc403SDave Cobbley# Pre-build configuration output 773c3d88e4dSAndrew GeisslerBUILDCFG_HEADER = "Build Configuration${@" (mc:${BB_CURRENT_MC})" if d.getVar("BBMULTICONFIG") else ""}:" 774eb8dc403SDave CobbleyBUILDCFG_VARS = "BB_VERSION BUILD_SYS NATIVELSBSTRING TARGET_SYS MACHINE DISTRO DISTRO_VERSION TUNE_FEATURES TARGET_FPU" 775eb8dc403SDave CobbleyBUILDCFG_VARS[type] = "list" 776eb8dc403SDave CobbleyBUILDCFG_NEEDEDVARS = "TARGET_ARCH TARGET_OS" 777eb8dc403SDave CobbleyBUILDCFG_NEEDEDVARS[type] = "list" 778eb8dc403SDave Cobbley 779eb8dc403SDave Cobbley# Other 780eb8dc403SDave Cobbley 781eb8dc403SDave Cobbleyexport PKG_CONFIG_DIR = "${STAGING_DIR_HOST}${libdir}/pkgconfig" 782eb8dc403SDave Cobbleyexport PKG_CONFIG_PATH = "${PKG_CONFIG_DIR}:${STAGING_DATADIR}/pkgconfig" 783eb8dc403SDave Cobbleyexport PKG_CONFIG_LIBDIR = "${PKG_CONFIG_DIR}" 784eb8dc403SDave Cobbleyexport PKG_CONFIG_SYSROOT_DIR = "${STAGING_DIR_HOST}" 785eb8dc403SDave Cobbleyexport PKG_CONFIG_DISABLE_UNINSTALLED = "yes" 786eb8dc403SDave Cobbleyexport PKG_CONFIG_SYSTEM_LIBRARY_PATH = "${base_libdir}:${libdir}" 787eb8dc403SDave Cobbleyexport PKG_CONFIG_SYSTEM_INCLUDE_PATH = "${includedir}" 788eb8dc403SDave Cobbley 789c182c62dSAndrew Geissler# Don't allow git to chdir up past WORKDIR so that it doesn't detect the OE 790c182c62dSAndrew Geissler# repository when building a recipe 791c182c62dSAndrew Geisslerexport GIT_CEILING_DIRECTORIES = "${WORKDIR}" 792c182c62dSAndrew Geissler 793eb8dc403SDave Cobbley### 794eb8dc403SDave Cobbley### Config file processing 795eb8dc403SDave Cobbley### 796eb8dc403SDave Cobbley 797eb8dc403SDave Cobbley# An empty distro leads to :: entries in OVERRIDES and FILEOVERRIDES which 798eb8dc403SDave Cobbley# is a bad idea. Setting a dummy value is better than a ton of anonymous python. 799eb8dc403SDave CobbleyDISTRO ??= "nodistro" 800eb8dc403SDave CobbleyDISTRO_NAME ??= "OpenEmbedded" 8011a4b7ee2SBrad Bishop 802eb8dc403SDave Cobbley# Overrides are processed left to right, so the ones that are named later take precedence. 8031a4b7ee2SBrad Bishop# You generally want them to go from least to most specific. This means that: 804d159c7fbSAndrew Geissler# A variable '<foo>:arm' overrides a variable '<foo>' when ${TARGET_ARCH} is arm. 805d159c7fbSAndrew Geissler# A variable '<foo>:qemuarm' overrides '<foo>' and overrides '<foo>:arm' when ${MACHINE} is 'qemuarm'. 806d159c7fbSAndrew Geissler# If you use combination ie '<foo>:qemuarm:arm', then '<foo>:qemuarm:arm' will override 807d159c7fbSAndrew Geissler# '<foo>:qemuarm' and then '<foo>' will be overriden with that value from '<foo>:qemuarm'. 808d159c7fbSAndrew Geissler# And finally '<foo>:forcevariable' overrides any standard variable, with the highest priority. 8091a4b7ee2SBrad Bishop# This works for functions as well, they are really just variables. 810eb8dc403SDave Cobbley# 811520786ccSPatrick WilliamsOVERRIDES = "${TARGET_OS}:${TRANSLATED_TARGET_ARCH}:pn-${PN}:layer-${FILE_LAYERNAME}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}:${CLASSOVERRIDE}${LIBCOVERRIDE}:forcevariable" 812520786ccSPatrick WilliamsFILE_LAYERNAME ??= "config" 8131a4b7ee2SBrad BishopLIBCOVERRIDE ?= "" 814eb8dc403SDave CobbleyCLASSOVERRIDE ?= "class-target" 815eb8dc403SDave CobbleyDISTROOVERRIDES ?= "${@d.getVar('DISTRO') or ''}" 816eb8dc403SDave CobbleyMACHINEOVERRIDES ?= "${MACHINE}" 817eb8dc403SDave Cobbley 818eb8dc403SDave CobbleyFILESOVERRIDES = "${TRANSLATED_TARGET_ARCH}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}" 819eb8dc403SDave Cobbley 820eb8dc403SDave Cobbley################################################################## 821eb8dc403SDave Cobbley# Include the rest of the config files. 822eb8dc403SDave Cobbley################################################################## 823eb8dc403SDave Cobbley 824eb8dc403SDave Cobbleyrequire conf/abi_version.conf 825eb8dc403SDave Cobbleyinclude conf/site.conf 826eb8dc403SDave Cobbleyinclude conf/auto.conf 827eb8dc403SDave Cobbleyinclude conf/local.conf 828eb8dc403SDave Cobbleyrequire conf/multiconfig/${BB_CURRENT_MC}.conf 829eb8dc403SDave Cobbleyinclude conf/machine/${MACHINE}.conf 830eb8dc403SDave Cobbleyinclude conf/machine-sdk/${SDKMACHINE}.conf 831eb8dc403SDave Cobbleyinclude conf/distro/${DISTRO}.conf 832eb8dc403SDave Cobbleyinclude conf/distro/defaultsetup.conf 833eb8dc403SDave Cobbleyinclude conf/documentation.conf 834eb8dc403SDave Cobbleyinclude conf/licenses.conf 835eb8dc403SDave Cobbleyrequire conf/sanity.conf 8368f840685SAndrew Geisslerrequire conf/cve-check-map.conf 83720137395SAndrew Geisslerinclude conf/bblock.conf 838eb8dc403SDave Cobbley 839eb8dc403SDave Cobbley################################################################## 840eb8dc403SDave Cobbley# Weak variables (usually to retain backwards compatibility) 841eb8dc403SDave Cobbley################################################################## 842eb8dc403SDave Cobbley 843eb8dc403SDave CobbleyDL_DIR ?= "${TOPDIR}/downloads" 844eb8dc403SDave CobbleySSTATE_DIR ?= "${TOPDIR}/sstate-cache" 845eb8dc403SDave CobbleyIMAGE_FSTYPES ?= "tar.gz" 846eb8dc403SDave CobbleyIMAGE_FSTYPES_DEBUGFS ?= "tar.gz" 847eb8dc403SDave Cobbley 848eb8dc403SDave CobbleyINITRAMFS_FSTYPES ?= "cpio.gz" 849eb8dc403SDave Cobbley# The maximum size in Kbytes for the generated initramfs image size. 850eb8dc403SDave Cobbley# Usually, it should be less than 1/2 of ram size, or you may fail to 851eb8dc403SDave Cobbley# boot it. 852eb8dc403SDave CobbleyINITRAMFS_MAXSIZE ??= "131072" 853eb8dc403SDave Cobbley 854eb8dc403SDave CobbleyDEFAULT_TASK_PROVIDER ?= "packagegroup-base" 855eb8dc403SDave CobbleyMACHINE_TASK_PROVIDER ?= "${DEFAULT_TASK_PROVIDER}" 856eb8dc403SDave Cobbley 857eb8dc403SDave Cobbley# The size in Kbytes for the generated image if it is larger than 858eb8dc403SDave Cobbley# the required size (du -ks IMAGE_ROOTFS * IMAGE_OVERHEAD_FACTOR), 859eb8dc403SDave Cobbley# and no effect if less than it. 860eb8dc403SDave CobbleyIMAGE_ROOTFS_SIZE ??= "65536" 861eb8dc403SDave Cobbley 862eb8dc403SDave Cobbley# Forcefully set CACHE now so future changes to things like 863eb8dc403SDave Cobbley# MACHINE don't change the path to the cache 864eb8dc403SDave CobbleyCACHE := "${CACHE}" 865eb8dc403SDave Cobbley 866eb8dc403SDave Cobbley# Default to setting automatically based on cpu count 867eb8dc403SDave CobbleyBB_NUMBER_THREADS ?= "${@oe.utils.cpu_count()}" 868eb8dc403SDave Cobbley 869eb8dc403SDave Cobbley# Default to setting automatically based on cpu count 870eb8dc403SDave CobbleyPARALLEL_MAKE ?= "-j ${@oe.utils.cpu_count()}" 871eb8dc403SDave Cobbley 87219323693SBrad Bishop# Default parallelism and resource usage for xz 87382c905dcSAndrew GeisslerXZ_MEMLIMIT ?= "50%" 87482c905dcSAndrew GeisslerXZ_THREADS ?= "${@oe.utils.cpu_count(at_least=2)}" 8755199d831SAndrew GeisslerXZ_THREADS[vardepvalue] = "1" 87682c905dcSAndrew GeisslerXZ_DEFAULTS ?= "--memlimit=${XZ_MEMLIMIT} --threads=${XZ_THREADS}" 87782c905dcSAndrew GeisslerXZ_DEFAULTS[vardepsexclude] += "XZ_MEMLIMIT XZ_THREADS" 87819323693SBrad Bishop 879eff27476SAndrew Geissler# Default parallelism for zstd 880eff27476SAndrew GeisslerZSTD_THREADS ?= "${@oe.utils.cpu_count(at_least=2)}" 881eff27476SAndrew GeisslerZSTD_THREADS[vardepvalue] = "1" 882eff27476SAndrew Geissler 883169d7bccSPatrick WilliamsZSTD_COMPRESSION_LEVEL ?= "-3" 884169d7bccSPatrick WilliamsZSTD_DEFAULTS ?= "--threads=${ZSTD_THREADS} ${ZSTD_COMPRESSION_LEVEL}" 885169d7bccSPatrick WilliamsZSTD_DEFAULTS[vardepsexclude] = "ZSTD_THREADS" 886169d7bccSPatrick Williams 8873b8a17c1SAndrew Geissler# Limit the number of threads that OpenMP libraries will use. Otherwise they 8883b8a17c1SAndrew Geissler# may fallback to using all CPUs 8893b8a17c1SAndrew Geisslerexport OMP_NUM_THREADS = "${BB_NUMBER_THREADS}" 8903b8a17c1SAndrew Geissler 891eb8dc403SDave Cobbley################################################################## 892eb8dc403SDave Cobbley# Magic Cookie for SANITY CHECK 893eb8dc403SDave Cobbley################################################################## 894eb8dc403SDave CobbleyOES_BITBAKE_CONF = "1" 895eb8dc403SDave Cobbley 896eb8dc403SDave Cobbley################################################################## 897eb8dc403SDave Cobbley# Machine properties and packagegroup-base stuff 898eb8dc403SDave Cobbley################################################################## 899eb8dc403SDave Cobbley 900eb8dc403SDave CobbleyMACHINE_FEATURES ?= "" 901169d7bccSPatrick WilliamsSDK_MACHINE_FEATURES ?= "" 902169d7bccSPatrick Williams 903eb8dc403SDave CobbleyDISTRO_FEATURES ?= "" 904eb8dc403SDave Cobbley 905eb8dc403SDave CobbleyDISTRO_EXTRA_RDEPENDS ?= "" 906eb8dc403SDave CobbleyDISTRO_EXTRA_RRECOMMENDS ?= "" 907eb8dc403SDave CobbleyMACHINE_EXTRA_RDEPENDS ?= "" 908eb8dc403SDave CobbleyMACHINE_EXTRA_RRECOMMENDS ?= "" 909eb8dc403SDave CobbleyMACHINE_ESSENTIAL_EXTRA_RDEPENDS ?= "" 910eb8dc403SDave CobbleyMACHINE_ESSENTIAL_EXTRA_RRECOMMENDS ?= "" 911eb8dc403SDave Cobbley 912eb8dc403SDave CobbleyEXTRA_IMAGE_FEATURES ??= "" 913eb8dc403SDave CobbleyIMAGE_FEATURES += "${EXTRA_IMAGE_FEATURES}" 914eb8dc403SDave Cobbley 915eb8dc403SDave Cobbley# Native distro features (will always be used for -native, even if they 916eb8dc403SDave Cobbley# are not enabled for target) 9178f840685SAndrew GeisslerDISTRO_FEATURES_NATIVE ?= "acl x11 ipv6 xattr" 91819323693SBrad BishopDISTRO_FEATURES_NATIVESDK ?= "x11" 919eb8dc403SDave Cobbley 920eb8dc403SDave Cobbley# Normally target distro features will not be applied to native builds: 921eb8dc403SDave Cobbley# Native distro features on this list will use the target feature value 922595f6308SAndrew GeisslerDISTRO_FEATURES_FILTER_NATIVE ?= "api-documentation debuginfod opengl wayland" 923595f6308SAndrew GeisslerDISTRO_FEATURES_FILTER_NATIVESDK ?= "api-documentation debuginfod opengl wayland" 924eb8dc403SDave Cobbley 92596ff1984SBrad BishopDISTRO_FEATURES_BACKFILL = "pulseaudio sysvinit gobject-introspection-data ldconfig" 926eb8dc403SDave CobbleyMACHINE_FEATURES_BACKFILL = "rtc qemu-usermode" 927eb8dc403SDave Cobbley 928eb8dc403SDave CobbleyCOMBINED_FEATURES = "${@oe.utils.set_intersect('DISTRO_FEATURES', 'MACHINE_FEATURES', d)}" 929eb8dc403SDave CobbleyCOMBINED_FEATURES[vardeps] += "DISTRO_FEATURES MACHINE_FEATURES" 930eb8dc403SDave Cobbley 931517393d9SAndrew GeisslerSERIAL_CONSOLES ??= "" 932eb8dc403SDave Cobbley 933c342db35SBrad BishopNO_RECOMMENDATIONS ??= "" 934eb8dc403SDave CobbleyBAD_RECOMMENDATIONS ?= "" 935eb8dc403SDave Cobbley 936eb8dc403SDave Cobbley# Make sure SHELL isn't exported 937eb8dc403SDave Cobbley# (can break any number of things if the user's shell isn't POSIX-compliant, 938eb8dc403SDave Cobbley# including the flock command). The user's shell shouldn't affect our builds. 939eb8dc403SDave CobbleySHELL[unexport] = "1" 940eb8dc403SDave Cobbley 941eb8dc403SDave Cobbley# Used by canadian-cross to handle string conversions on TARGET_ARCH where needed 942eb8dc403SDave CobbleyTRANSLATED_TARGET_ARCH ??= "${@d.getVar('TARGET_ARCH').replace("_", "-")}" 943eb8dc403SDave Cobbley 9449b4d8b0eSAndrew Geissler# Set a default umask to use for tasks for determinism 94592b42cb3SPatrick WilliamsBB_DEFAULT_UMASK ??= "022" 9469b4d8b0eSAndrew Geissler 947eb8dc403SDave Cobbley# Complete output from bitbake 948eb8dc403SDave CobbleyBB_CONSOLELOG ?= "${LOG_DIR}/cooker/${MACHINE}/${DATETIME}.log" 949ac13d5f3SPatrick WilliamsBB_DEFAULT_EVENTLOG ?= "${LOG_DIR}/eventlog/${DATETIME}.json" 950eb8dc403SDave Cobbley 951eb8dc403SDave Cobbley# Setup our default hash policy 952eb8dc403SDave CobbleyBB_SIGNATURE_HANDLER ?= "OEBasicHash" 953f0343792SAndrew GeisslerBB_HASHEXCLUDE_COMMON ?= "TMPDIR FILE PATH PWD BB_TASKHASH BBPATH BBSERVER DL_DIR \ 954f0343792SAndrew Geissler THISDIR FILESEXTRAPATHS FILE_DIRNAME HOME LOGNAME SHELL \ 955eb8dc403SDave Cobbley USER FILESPATH STAGING_DIR_HOST STAGING_DIR_TARGET COREBASE PRSERV_HOST \ 956eb8dc403SDave Cobbley STAMPS_DIR PRSERV_DUMPDIR PRSERV_DUMPFILE PRSERV_LOCKDOWN PARALLEL_MAKE \ 957eb8dc403SDave Cobbley CCACHE_DIR EXTERNAL_TOOLCHAIN CCACHE CCACHE_NOHASHDIR LICENSE_PATH SDKPKGSUFFIX \ 958de0582f0SPatrick Williams WARN_QA WORKDIR STAMPCLEAN PKGDATA_DIR BUILD_ARCH SSTATE_PKGARCH \ 95919323693SBrad Bishop BB_WORKERCONTEXT BB_LIMITEDDEPS BB_UNIHASH extend_recipe_sysroot DEPLOY_DIR \ 960a34c030eSBrad Bishop SSTATE_HASHEQUIV_METHOD SSTATE_HASHEQUIV_REPORT_TASKDATA \ 9613b8a17c1SAndrew Geissler SSTATE_HASHEQUIV_OWNER CCACHE_TOP_DIR BB_HASHSERVE GIT_CEILING_DIRECTORIES \ 962eff27476SAndrew Geissler OMP_NUM_THREADS BB_CURRENTTASK" 9637e0e3c0cSAndrew GeisslerBB_BASEHASH_IGNORE_VARS ?= "${BB_HASHEXCLUDE_COMMON} PSEUDO_IGNORE_PATHS BUILDHISTORY_DIR \ 96492b42cb3SPatrick Williams SSTATE_DIR SOURCE_DATE_EPOCH RUST_BUILD_SYS RUST_HOST_SYS RUST_TARGET_SYS" 9657e0e3c0cSAndrew GeisslerBB_HASHCONFIG_IGNORE_VARS ?= "${BB_HASHEXCLUDE_COMMON} DATE TIME SSH_AGENT_PID \ 9667e0e3c0cSAndrew Geissler SSH_AUTH_SOCK PSEUDO_BUILD BB_ENV_PASSTHROUGH_ADDITIONS DISABLE_SANITY_CHECKS \ 967eb8dc403SDave Cobbley PARALLEL_MAKE BB_NUMBER_THREADS BB_ORIGENV BB_INVALIDCONF BBINCLUDED \ 968eb8dc403SDave Cobbley GIT_PROXY_COMMAND ALL_PROXY all_proxy NO_PROXY no_proxy FTP_PROXY ftp_proxy \ 969eb8dc403SDave Cobbley HTTP_PROXY http_proxy HTTPS_PROXY https_proxy SOCKS5_USER SOCKS5_PASSWD \ 970e760df85SPatrick Williams BB_SETSCENE_ENFORCE BB_CMDLINE BB_SERVER_TIMEOUT BB_NICE_LEVEL" 971eb8dc403SDave CobbleyBB_SIGNATURE_EXCLUDE_FLAGS ?= "doc deps depends \ 97203907ee1SPatrick Williams lockfiles vardepsexclude vardeps vardepvalue vardepvalueexclude \ 97303907ee1SPatrick Williams file-checksums python task nostamp \ 974eb8dc403SDave Cobbley sstate-lockfile-shared prefuncs postfuncs export_func deptask rdeptask \ 975eb8dc403SDave Cobbley recrdeptask nodeprrecs stamp-extra-info sstate-outputdirs filename lineno \ 97682c905dcSAndrew Geissler progress mcdepends number_threads" 9775082cc7fSAndrew GeisslerBB_HASH_CODEPARSER_VALS = "LOGFIFO=/ T=/ WORKDIR=/ DATE=1234 TIME=1234 PV=0.0-1 PN=no-pn METADATA_REVISION=1234 SRC_URI=" 978eb8dc403SDave Cobbley 979eb8dc403SDave CobbleyMLPREFIX ??= "" 980eb8dc403SDave CobbleyMULTILIB_VARIANTS ??= "" 981c342db35SBrad Bishop 982c342db35SBrad Bishop# Older versions of bitbake (< 1.42) don't set BB_UNIHASH. For compatibility with these 983c342db35SBrad Bishop# versions, set BB_UNIHASH equivalent to BB_TASKHASH if unspecified, which is 984c342db35SBrad Bishop# what it would be anyway if the signature generator (e.g. OEEquivHash) doesn't 985c342db35SBrad Bishop# support unihashes. 986c342db35SBrad BishopBB_UNIHASH ?= "${BB_TASKHASH}" 987517393d9SAndrew Geissler 988517393d9SAndrew Geissleroe.sstatesig.find_sstate_manifest[vardepsexclude] = "BBEXTENDCURR BBEXTENDVARIANT OVERRIDES PACKAGE_EXTRA_ARCHS" 989517393d9SAndrew Geissleroe.utils.get_multilib_datastore[vardepsexclude] = "DEFAULTTUNE_MULTILIB_ORIGINAL OVERRIDES" 990517393d9SAndrew Geissleroe.path.format_display[vardepsexclude] = "TOPDIR" 991220dafdbSAndrew Geissleroe.utils.get_bb_number_threads[vardepsexclude] = "BB_NUMBER_THREADS" 992517393d9SAndrew Geissleroe.packagedata.emit_pkgdata[vardepsexclude] = "BB_NUMBER_THREADS" 993220dafdbSAndrew Geissleroe.packagedata.read_subpkgdata_extended[vardepsexclude] = "BB_NUMBER_THREADS" 994