diff options
-rw-r--r-- | meta-poky/conf/distro/include/gcsections.inc | 22 | ||||
-rw-r--r-- | meta-poky/conf/distro/poky-tiny.conf | 2 |
2 files changed, 24 insertions, 0 deletions
diff --git a/meta-poky/conf/distro/include/gcsections.inc b/meta-poky/conf/distro/include/gcsections.inc new file mode 100644 index 0000000000..dd98943acb --- /dev/null +++ b/meta-poky/conf/distro/include/gcsections.inc | |||
@@ -0,0 +1,22 @@ | |||
1 | CFLAGS_SECTION_REMOVAL = "-ffunction-sections -fdata-sections" | ||
2 | LDFLAGS_SECTION_REMOVAL = "-Wl,--gc-sections" | ||
3 | |||
4 | # packages with build problems using sections | ||
5 | CFLAGS_SECTION_REMOVAL_pn-glibc = "" | ||
6 | LDFLAGS_SECTION_REMOVAL_pn-glibc = "" | ||
7 | CFLAGS_SECTION_REMOVAL_pn-cairo = "" | ||
8 | LDFLAGS_SECTION_REMOVAL_pn-cairo = "" | ||
9 | CFLAGS_SECTION_REMOVAL_pn-perl = "" | ||
10 | LDFLAGS_SECTION_REMOVAL_pn-perl = "" | ||
11 | CFLAGS_SECTION_REMOVAL_pn-grub-efi = "" | ||
12 | LDFLAGS_SECTION_REMOVAL_pn-grub-efi = "" | ||
13 | CFLAGS_SECTION_REMOVAL_pn-grub = "" | ||
14 | LDFLAGS_SECTION_REMOVAL_pn-grub = "" | ||
15 | |||
16 | # set default for target | ||
17 | CFLAGS_append_class-target = " ${CFLAGS_SECTION_REMOVAL}" | ||
18 | LDFLAGS_append_class-target = " ${LDFLAGS_SECTION_REMOVAL}" | ||
19 | |||
20 | # set default for nativesdk | ||
21 | CFLAGS_append_class-nativesdk = " ${CFLAGS_SECTION_REMOVAL}" | ||
22 | LDFLAGS_append_class-nativesdk = " ${LDFLAGS_SECTION_REMOVAL}" | ||
diff --git a/meta-poky/conf/distro/poky-tiny.conf b/meta-poky/conf/distro/poky-tiny.conf index 9a043b1ef5..e125b23d46 100644 --- a/meta-poky/conf/distro/poky-tiny.conf +++ b/meta-poky/conf/distro/poky-tiny.conf | |||
@@ -29,6 +29,8 @@ | |||
29 | # [ ] Modify busybox to allow for DISTRO_FEATURES-like confiruration | 29 | # [ ] Modify busybox to allow for DISTRO_FEATURES-like confiruration |
30 | 30 | ||
31 | require conf/distro/poky.conf | 31 | require conf/distro/poky.conf |
32 | require conf/distro/include/gcsections.inc | ||
33 | |||
32 | DISTRO = "poky-tiny" | 34 | DISTRO = "poky-tiny" |
33 | DISTROOVERRIDES = "poky:poky-tiny" | 35 | DISTROOVERRIDES = "poky:poky-tiny" |
34 | TCLIBC = "musl" | 36 | TCLIBC = "musl" |