toolchain updates for flight pro 8096 kyro cross compilation #24
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
These changes allow the
linux_app.cmake
macros to correctly build binaries and shared objects. The preconditions for using this toolchain with the sfpro is that the Intrinsyc instructions for setting up the cross-compilation environment and the DSPAL/SLPI dev env have been completed.Note: by removing the search path to
sdsprpc.so
(${HEXAGON_SDK_ROOT}/${SDKLIB}/common/remote/ship/UbuntuARM_${RELEASE}
), we allow the linker to find the correctsdsprpc.so
(correct in the sense that it is a soft-float abi). Without this change, the following error aboutVFP register arguments
occurs:The linker is complaining that the compiler being used (from the Intrinsyc cross-compiler toolchain) does not have a hard-float abi, but the
sdsprpc.so
in the Hexagon SDK does [1]. This is verified usingreadelf -A libsdsprpc.so
:However, when we check the lib in the target sysroot:
$ readelf -A Qualcomm/cross_compiler/sysroots/aarch64-oe-linux/usr/lib/libsdsprpc.so Attribute Section: aeabi File Attributes Tag_CPU_name: "7-A" Tag_CPU_arch: v7 Tag_CPU_arch_profile: Application Tag_ARM_ISA_use: Yes Tag_THUMB_ISA_use: Thumb-2 Tag_FP_arch: VFPv3 Tag_Advanced_SIMD_arch: NEONv1 Tag_ABI_PCS_wchar_t: 4 Tag_ABI_FP_rounding: Needed Tag_ABI_FP_denormal: Needed Tag_ABI_FP_exceptions: Needed Tag_ABI_FP_number_model: IEEE 754 Tag_ABI_align_needed: 8-byte Tag_ABI_enum_size: int Tag_ABI_HardFP_use: Deprecated Tag_CPU_unaligned_access: v6
That line is not present because a soft-float abi is being used.
It seems that using the
qurt_bundle
CMake macro does not expose this problem because of theadd_custom_target
stanza:where
APPS_COMPILER
tends to be passed in asQualcomm/ARM_Tools/gcc-4.9-2014.11/bin/arm-linux-gnueabihf-gcc
, which has a hard-float abi [2].[1]: This is likely related to the fact that Snapdragon 820 has a Kyro CPU, based on ARMv8-A (64 bit), but for some reason the yocto linux shipped is 32-bit.
[2]: Maybe this is actually itself a problem? Why do we have both soft-float and hard-float abi compilers? Why is the shipped OS 32-bit?