blob: 4e85cab2d1989c55873324c25006b0d7d6cba06f [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001inherit relocatable
2
3# Cross packages are built indirectly via dependency,
4# no need for them to be a direct target of 'world'
5EXCLUDE_FROM_WORLD = "1"
6
7CLASSOVERRIDE = "class-cross"
8PACKAGES = ""
9PACKAGES_DYNAMIC = ""
10PACKAGES_DYNAMIC_class-native = ""
11
12HOST_ARCH = "${BUILD_ARCH}"
13HOST_VENDOR = "${BUILD_VENDOR}"
14HOST_OS = "${BUILD_OS}"
15HOST_PREFIX = "${BUILD_PREFIX}"
16HOST_CC_ARCH = "${BUILD_CC_ARCH}"
17HOST_LD_ARCH = "${BUILD_LD_ARCH}"
18HOST_AS_ARCH = "${BUILD_AS_ARCH}"
19
Patrick Williamsc0f7c042017-02-23 20:41:17 -060020export lt_cv_sys_lib_dlsearch_path_spec = "${libdir} ${base_libdir} /lib /lib64 /usr/lib /usr/lib64"
21
Brad Bishop6e60e8b2018-02-01 10:27:11 -050022STAGING_DIR_HOST = "${RECIPE_SYSROOT_NATIVE}"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050023
24PACKAGE_ARCH = "${BUILD_ARCH}"
25
Brad Bishop6e60e8b2018-02-01 10:27:11 -050026MULTIMACH_TARGET_SYS = "${BUILD_ARCH}${BUILD_VENDOR}-${BUILD_OS}"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050027
28export PKG_CONFIG_DIR = "${exec_prefix}/lib/pkgconfig"
29export PKG_CONFIG_SYSROOT_DIR = ""
30
Brad Bishop6e60e8b2018-02-01 10:27:11 -050031TARGET_CPPFLAGS = ""
32TARGET_CFLAGS = ""
33TARGET_CXXFLAGS = ""
34TARGET_LDFLAGS = ""
35
Patrick Williamsc124f4f2015-09-15 14:41:29 -050036CPPFLAGS = "${BUILD_CPPFLAGS}"
37CFLAGS = "${BUILD_CFLAGS}"
38CXXFLAGS = "${BUILD_CFLAGS}"
39LDFLAGS = "${BUILD_LDFLAGS}"
40LDFLAGS_build-darwin = "-L${STAGING_LIBDIR_NATIVE}"
41
42TOOLCHAIN_OPTIONS = ""
43
Brad Bishop6e60e8b2018-02-01 10:27:11 -050044# This class encodes staging paths into its scripts data so can only be
45# reused if we manipulate the paths.
46SSTATE_SCAN_CMD ?= "${SSTATE_SCAN_CMD_NATIVE}"
47
Patrick Williamsc124f4f2015-09-15 14:41:29 -050048# Path mangling needed by the cross packaging
49# Note that we use := here to ensure that libdir and includedir are
50# target paths.
Brad Bishopd7bf8c12018-02-25 22:55:05 -050051target_base_prefix := "${root_prefix}"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050052target_prefix := "${prefix}"
53target_exec_prefix := "${exec_prefix}"
54target_base_libdir = "${target_base_prefix}/${baselib}"
55target_libdir = "${target_exec_prefix}/${baselib}"
56target_includedir := "${includedir}"
57
58# Overrides for paths
59CROSS_TARGET_SYS_DIR = "${TARGET_SYS}"
60prefix = "${STAGING_DIR_NATIVE}${prefix_native}"
61base_prefix = "${STAGING_DIR_NATIVE}"
62exec_prefix = "${STAGING_DIR_NATIVE}${prefix_native}"
63bindir = "${exec_prefix}/bin/${CROSS_TARGET_SYS_DIR}"
64sbindir = "${bindir}"
65base_bindir = "${bindir}"
66base_sbindir = "${bindir}"
67libdir = "${exec_prefix}/lib/${CROSS_TARGET_SYS_DIR}"
68libexecdir = "${exec_prefix}/libexec/${CROSS_TARGET_SYS_DIR}"
69
70do_populate_sysroot[sstate-inputdirs] = "${SYSROOT_DESTDIR}/${STAGING_DIR_NATIVE}/"
71do_populate_sysroot[stamp-extra-info] = ""
72do_packagedata[stamp-extra-info] = ""
73
74do_install () {
75 oe_runmake 'DESTDIR=${D}' install
76}
77
78USE_NLS = "no"
79
Patrick Williamsc0f7c042017-02-23 20:41:17 -060080export CC = "${BUILD_CC}"
81export CXX = "${BUILD_CXX}"
82export FC = "${BUILD_FC}"
83export CPP = "${BUILD_CPP}"
84export LD = "${BUILD_LD}"
85export CCLD = "${BUILD_CCLD}"
86export AR = "${BUILD_AR}"
87export AS = "${BUILD_AS}"
88export RANLIB = "${BUILD_RANLIB}"
89export STRIP = "${BUILD_STRIP}"
90export NM = "${BUILD_NM}"
91
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050092inherit nopackages
Brad Bishop316dfdd2018-06-25 12:45:53 -040093
94python do_addto_recipe_sysroot () {
95 bb.build.exec_func("extend_recipe_sysroot", d)
96}
97addtask addto_recipe_sysroot after do_populate_sysroot