1# Distributed under the OSI-approved BSD 3-Clause License. See accompanying 2# file Copyright.txt or https://cmake.org/licensing for details. 3 4 5# This file is used by EnableLanguage in cmGlobalGenerator to 6# determine that the selected ASM compiler works. 7# For assembler this can only check whether the compiler has been found, 8# because otherwise there would have to be a separate assembler source file 9# for each assembler on every architecture. 10 11 12set(_ASM_COMPILER_WORKS 0) 13 14if(CMAKE_ASM${ASM_DIALECT}_COMPILER) 15 set(_ASM_COMPILER_WORKS 1) 16endif() 17 18# when using generic "ASM" support, we must have detected the compiler ID, fail otherwise: 19if("ASM${ASM_DIALECT}" STREQUAL "ASM") 20 if(NOT CMAKE_ASM${ASM_DIALECT}_COMPILER_ID) 21 set(_ASM_COMPILER_WORKS 0) 22 endif() 23endif() 24 25set(CMAKE_ASM${ASM_DIALECT}_COMPILER_WORKS ${_ASM_COMPILER_WORKS} CACHE INTERNAL "") 26