Skip to content
This repository was archived by the owner on May 21, 2019. It is now read-only.

[DoNotMergeYet] fix cross compiling to ARM when using cmake #17

Merged
merged 2 commits into from
Mar 16, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions cmake/config-ix.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -207,8 +207,11 @@ elseif(NOT APPLE) # Supported archs for Apple platforms are generated later
test_target_arch(mips "" "-mips32r2" "--target=mips-linux-gnu")
test_target_arch(mips64 "" "-mips64r2" "--target=mips64-linux-gnu" "-mabi=n64")
elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "arm")
test_target_arch(arm "" "-march=armv7-a" "-mfloat-abi=soft")
test_target_arch(armhf "" "-march=armv7-a" "-mfloat-abi=hard")
if("${COMPILER_RT_DEFAULT_TARGET_TRIPLE}" MATCHES "eabihf")
test_target_arch(armhf "" "-march=armv7-a" "-mfloat-abi=hard")
else()
test_target_arch(arm "" "-march=armv7-a" "-mfloat-abi=soft")
endif()
elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "aarch32")
test_target_arch(aarch32 "" "-march=armv8-a")
elseif("${COMPILER_RT_DEFAULT_TARGET_ARCH}" MATCHES "aarch64")
Expand Down
71 changes: 36 additions & 35 deletions lib/builtins/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -220,8 +220,6 @@ else () # MSVC
endif () # if (NOT MSVC)

set(arm_SOURCES
arm/adddf3vfp.S
arm/addsf3vfp.S
arm/aeabi_cdcmp.S
arm/aeabi_cdcmpeq_check_nan.c
arm/aeabi_cfcmp.S
Expand All @@ -242,40 +240,11 @@ set(arm_SOURCES
arm/bswapdi2.S
arm/bswapsi2.S
arm/comparesf2.S
arm/divdf3vfp.S
arm/divmodsi4.S
arm/divsf3vfp.S
arm/divsi3.S
arm/eqdf2vfp.S
arm/eqsf2vfp.S
arm/extendsfdf2vfp.S
arm/fixdfsivfp.S
arm/fixsfsivfp.S
arm/fixunsdfsivfp.S
arm/fixunssfsivfp.S
arm/floatsidfvfp.S
arm/floatsisfvfp.S
arm/floatunssidfvfp.S
arm/floatunssisfvfp.S
arm/gedf2vfp.S
arm/gesf2vfp.S
arm/gtdf2vfp.S
arm/gtsf2vfp.S
arm/ledf2vfp.S
arm/lesf2vfp.S
arm/ltdf2vfp.S
arm/ltsf2vfp.S
arm/modsi3.S
arm/muldf3vfp.S
arm/mulsf3vfp.S
arm/nedf2vfp.S
arm/negdf2vfp.S
arm/negsf2vfp.S
arm/nesf2vfp.S
arm/restore_vfp_d8_d15_regs.S
arm/save_vfp_d8_d15_regs.S
arm/subdf3vfp.S
arm/subsf3vfp.S
arm/switch16.S
arm/switch32.S
arm/switch8.S
Expand All @@ -301,12 +270,9 @@ set(arm_SOURCES
arm/sync_fetch_and_xor_4.S
arm/sync_fetch_and_xor_8.S
arm/sync_synchronize.S
arm/truncdfsf2vfp.S
arm/udivmodsi4.S
arm/udivsi3.S
arm/umodsi3.S
arm/unorddf2vfp.S
arm/unordsf2vfp.S
${GENERIC_SOURCES})

set(aarch64_SOURCES
Expand All @@ -328,7 +294,42 @@ set(aarch64_SOURCES
trunctfsf2.c
${GENERIC_SOURCES})

set(armhf_SOURCES ${arm_SOURCES})
set(armhf_SOURCES
arm/adddf3vfp.S
arm/addsf3vfp.S
arm/divdf3vfp.S
arm/divsf3vfp.S
arm/eqdf2vfp.S
arm/eqsf2vfp.S
arm/extendsfdf2vfp.S
arm/fixdfsivfp.S
arm/fixsfsivfp.S
arm/fixunsdfsivfp.S
arm/fixunssfsivfp.S
arm/floatsidfvfp.S
arm/floatsisfvfp.S
arm/floatunssidfvfp.S
arm/floatunssisfvfp.S
arm/gedf2vfp.S
arm/gesf2vfp.S
arm/gtdf2vfp.S
arm/gtsf2vfp.S
arm/ledf2vfp.S
arm/lesf2vfp.S
arm/ltdf2vfp.S
arm/ltsf2vfp.S
arm/muldf3vfp.S
arm/mulsf3vfp.S
arm/nedf2vfp.S
arm/nesf2vfp.S
arm/restore_vfp_d8_d15_regs.S
arm/save_vfp_d8_d15_regs.S
arm/subdf3vfp.S
arm/subsf3vfp.S
arm/truncdfsf2vfp.S
arm/unorddf2vfp.S
arm/unordsf2vfp.S
${arm_SOURCES})
set(armv7_SOURCES ${arm_SOURCES})
set(armv7s_SOURCES ${arm_SOURCES})
set(arm64_SOURCES ${aarch64_SOURCES})
Expand Down