Browse Source

Use CMake variables instead of as

tags/v0.3.19
Rafael Cardoso Fernandes Sousa 3 years ago
parent
commit
d38110a5ce
1 changed files with 10 additions and 4 deletions
  1. +10
    -4
      cmake/system.cmake

+ 10
- 4
cmake/system.cmake View File

@@ -106,10 +106,16 @@ if (CMAKE_C_COMPILER STREQUAL loongcc)
endif ()

if (POWER)
set (NO_WARMUP 1)
execute_process(COMMAND bash -c "as -v < /dev/null 2>&1 | grep GNU 2>&1 >/dev/null" RESULT_VARIABLE HAVE_GAS)
set(GETARCH_FLAGS "${GETARCH_FLAGS} -DHAVE_GAS=${HAVE_GAS}")
endif()
set(NO_WARMUP 1)
set(HAVE_GAS 1)
if (CMAKE_ASM_COMPILER_ID STREQUAL "GNU")
set(HAVE_GAS 0)
elseif (CMAKE_ASM_COMPILER_ID STREQUAL "Clang")
set(CCOMMON_OPT "${CCOMMON_OPT} -fno-integrated-as")
set(HAVE_GAS 0)
endif ()
set(GETARCH_FLAGS "${GETARCH_FLAGS} -DHAVE_GAS=${HAVE_GAS}")
endif ()

#if don't use Fortran, it will only compile CBLAS.
if (ONLY_CBLAS)


Loading…
Cancel
Save