summaryrefslogtreecommitdiffstats
path: root/meta-xilinx-standalone/conf/distro
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@amd.com>2023-04-12 15:30:04 -0700
committerMark Hatle <mark.hatle@amd.com>2023-04-13 09:47:49 -0500
commit8c32e90f438b92b4f52b3e942fb60eacd5bec842 (patch)
treee7985b0b428d792393aa7ff2ea9dc47f53142f41 /meta-xilinx-standalone/conf/distro
parent1b71f4b7059c98a172d1e814cb78afaeb86ed0e2 (diff)
downloadmeta-xilinx-8c32e90f438b92b4f52b3e942fb60eacd5bec842.tar.gz
xilinx-standalone.inc: Remove security_flags.inc
Inclusion of security_flags.inc lead to a number of problems with the baremetal distributions: *ARM v8* aarch64-xilinx-elf-ld: testA53.elf: error: PHDR segment not covered by LOAD segment aarch64-xilinx-elf-ld: warning: testA53.elf has a LOAD segment with RWX permissions *ARM v7* arm-xilinx-eabi-ld: .../aarch32-xilinx-eabi/usr/lib/thumb/v7-a+fp/hard/crtbegin.o: relocation R_ARM_THM_MOVW_ABS_NC against `a local symbol' can not be used when making a shared object; recompile with -fPIC The configuration that works: export CFLAGS=" -O2 -pipe -g -feliminate-unused-debug-types " export CXXFLAGS=" -O2 -pipe -g -feliminate-unused-debug-types " export LDFLAGS="-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,-z,relro,-z,now" export CPPFLAGS="" Configuration that provides the warnings/errors: export CFLAGS=" -O2 -pipe -g -feliminate-unused-debug-types " export CXXFLAGS=" -O2 -pipe -g -feliminate-unused-debug-types " export LDFLAGS="-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed " export CPPFLAGS="" The LDFLAGS was introdued by the security_flags.inc, the SECURITY_CFLGAS:class-target ?= "" and SECURITY_LDFLAGS:class-target ?= "" was supposed to prevent this, however the cross compiler is built in the cross or canadian-cross or other context and NOT target. Additionally the SDK environment is configured in the nativesdk environment, so the default values may not match the configured (target) compiler and CFLAGS. Removing security_flags.inc resolves both of these issues, as the security flags don't really do anything on a baremetal configuration, by default, anyway. Signed-off-by: Mark Hatle <mark.hatle@amd.com>
Diffstat (limited to 'meta-xilinx-standalone/conf/distro')
-rw-r--r--meta-xilinx-standalone/conf/distro/xilinx-standalone.inc4
1 files changed, 0 insertions, 4 deletions
diff --git a/meta-xilinx-standalone/conf/distro/xilinx-standalone.inc b/meta-xilinx-standalone/conf/distro/xilinx-standalone.inc
index 4b51dd1b..f86a5971 100644
--- a/meta-xilinx-standalone/conf/distro/xilinx-standalone.inc
+++ b/meta-xilinx-standalone/conf/distro/xilinx-standalone.inc
@@ -39,12 +39,8 @@ TOOLCHAIN_HOST_TASK:append:sdkmingw32 = " nativesdk-mingw-w64-winpthreads"
39# do so. 39# do so.
40DISABLE_STATIC:class-target ?= "" 40DISABLE_STATIC:class-target ?= ""
41 41
42SECURITY_CFLAGS:class-target ?= ""
43SECURITY_LDFLAGS:class-target ?= ""
44
45require conf/distro/include/no-static-libs.inc 42require conf/distro/include/no-static-libs.inc
46require conf/distro/include/yocto-uninative.inc 43require conf/distro/include/yocto-uninative.inc
47require conf/distro/include/security_flags.inc
48INHERIT += "uninative" 44INHERIT += "uninative"
49 45
50BB_SIGNATURE_HANDLER ?= "OEEquivHash" 46BB_SIGNATURE_HANDLER ?= "OEEquivHash"