Linker configuration: Add missing platforms

The following platforms were missing:
* Android
* WindowsCE, WindowsPhone, WindowsStore and WindowsKernelModeDriver

And enhance various Apple platforms support (iOS, tvOS, etc...)

Fixes: #26439
This commit is contained in:
Marc Chevrier
2024-11-12 16:42:47 +01:00
parent 7f2dba2748
commit d2997ab601
50 changed files with 246 additions and 9 deletions

View File

@@ -29,7 +29,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-ASM${ASM_DIALECT} OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-ASM${ASM_DIALECT} OPTIONAL)
endif ()
set(CMAKE_ASM${ASM_DIALECT}_LINKER_INFORMATION_LOADED 1)

View File

@@ -31,7 +31,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-C OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-C OPTIONAL)
endif ()
_cmake_common_linker_platform_flags(C)

View File

@@ -31,7 +31,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-CUDA OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-CUDA OPTIONAL)
endif ()
_cmake_common_linker_platform_flags(CUDA)

View File

@@ -31,7 +31,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-CXX OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-CXX OPTIONAL)
endif ()
_cmake_common_linker_platform_flags(CXX)

View File

@@ -31,7 +31,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-Fortran OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-Fortran OPTIONAL)
endif ()
_cmake_common_linker_platform_flags(Fortran)

View File

@@ -31,7 +31,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-HIP OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-HIP OPTIONAL)
endif ()
_cmake_common_linker_platform_flags(HIP)

View File

@@ -31,7 +31,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-OBJC OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-OBJC OPTIONAL)
endif ()
_cmake_common_linker_platform_flags(OBJC)

View File

@@ -31,7 +31,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-OBJCXX OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-OBJCXX OPTIONAL)
endif ()
_cmake_common_linker_platform_flags(OBJCXX)

View File

@@ -31,7 +31,7 @@ endif()
# We specify the platform linker information in the system file.
if (NOT _INCLUDED_FILE)
include(Platform/Linker/${CMAKE_SYSTEM_NAME}-Swift OPTIONAL)
include(Platform/Linker/${CMAKE_EFFECTIVE_SYSTEM_NAME}-Swift OPTIONAL)
endif ()
_cmake_common_linker_platform_flags(Swift)

View File

@@ -0,0 +1,5 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
# GNU is the default linker
include(Platform/Linker/Android-GNU-ASM)

View File

@@ -0,0 +1,5 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
# GNU is the default linker
include(Platform/Linker/Android-GNU-C)

View File

@@ -0,0 +1,5 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
# GNU is the default linker
include(Platform/Linker/Android-GNU-CXX)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Linux-GNU-ASM)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Linux-GNU-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Linux-GNU-CXX)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Linux-LLD-ASM)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Linux-LLD-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Linux-LLD-CXX)

View File

@@ -0,0 +1,5 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
# MSVC is the default linker
include(Platform/Linker/WindowsCE-MSVC-C)

View File

@@ -0,0 +1,5 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
# MSVC is the default linker
include(Platform/Linker/WindowsCE-MSVC-CXX)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-CXX)

View File

@@ -0,0 +1,5 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
# MSVC is the default linker
include(Platform/Linker/WindowsKernelModeDriver-MSVC-C)

View File

@@ -0,0 +1,5 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
# MSVC is the default linker
include(Platform/Linker/WindowsKernelModeDriver-MSVC-CXX)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-CXX)

View File

@@ -0,0 +1,15 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
block(SCOPE_FOR POLICIES)
cmake_policy(SET CMP0054 NEW)
if(CMAKE_ASM_SIMULATE_ID STREQUAL "MSVC")
# MSVC is the default linker
include(Platform/Linker/WindowsPhone-MSVC-ASM)
else()
# GNU is the default linker
include(Platform/Linker/WindowsPhone-GNU-ASM)
endif()
endblock()

View File

@@ -0,0 +1,15 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
block(SCOPE_FOR POLICIES)
cmake_policy(SET CMP0054 NEW)
if(CMAKE_C_SIMULATE_ID STREQUAL "MSVC")
# MSVC is the default linker
include(Platform/Linker/WindowsPhone-MSVC-C)
else()
# GNU is the default linker
include(Platform/Linker/WindowsPhone-GNU-C)
endif()
endblock()

View File

@@ -0,0 +1,15 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
block(SCOPE_FOR POLICIES)
cmake_policy(SET CMP0054 NEW)
if(CMAKE_CXX_SIMULATE_ID STREQUAL "MSVC")
# MSVC is the default linker
include(Platform/Linker/WindowsPhone-MSVC-CXX)
else()
# GNU is the default linker
include(Platform/Linker/WindowsPhone-GNU-CXX)
endif()
endblock()

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-GNU-ASM)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-GNU-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-GNU-CXX)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-LLD-ASM)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-LLD-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-LLD-CXX)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-ASM)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-CXX)

View File

@@ -0,0 +1,15 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
block(SCOPE_FOR POLICIES)
cmake_policy(SET CMP0054 NEW)
if(CMAKE_ASM_SIMULATE_ID STREQUAL "MSVC")
# MSVC is the default linker
include(Platform/Linker/WindowsStore-MSVC-ASM)
else()
# GNU is the default linker
include(Platform/Linker/WindowsStore-GNU-ASM)
endif()
endblock()

View File

@@ -0,0 +1,15 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
block(SCOPE_FOR POLICIES)
cmake_policy(SET CMP0054 NEW)
if(CMAKE_C_SIMULATE_ID STREQUAL "MSVC")
# MSVC is the default linker
include(Platform/Linker/WindowsStore-MSVC-C)
else()
# GNU is the default linker
include(Platform/Linker/WindowsStore-GNU-C)
endif()
endblock()

View File

@@ -0,0 +1,15 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
block(SCOPE_FOR POLICIES)
cmake_policy(SET CMP0054 NEW)
if(CMAKE_CXX_SIMULATE_ID STREQUAL "MSVC")
# MSVC is the default linker
include(Platform/Linker/WindowsStore-MSVC-CXX)
else()
# GNU is the default linker
include(Platform/Linker/WindowsStore-GNU-CXX)
endif()
endblock()

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-GNU-ASM)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-GNU-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-GNU-CXX)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-LLD-ASM)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-LLD-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-LLD-CXX)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-ASM)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-C)

View File

@@ -0,0 +1,4 @@
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
include(Platform/Linker/Windows-MSVC-CXX)