Skip to content

Commit 7b9d0c1

Browse files
authored
[SPEC2017] Add CMAKE_C_FLAGS -Wno-implicit-int for 527.cam4_r. (llvm#284)
Without this patch, an error will occurs: ``` cpu2017/benchspec/CPU/527.cam4_r/src/mpi.c:23:1: error: type specifier missing, defaults to 'int'; ISO C99 and later do not support implicit int [-Wimplicit-int] 23 | FORT_NAME( mpi_init_fort , MPI_INIT_FORT) | ^ | int ```
1 parent 79a9dc6 commit 7b9d0c1

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

External/SPEC/CFP2017rate/527.cam4_r/CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,8 @@ speccpu2017_add_include_dirs(
6969
# the netcdf modules are in the build directory for the rate test
7070
include_directories("${CMAKE_CURRENT_BINARY_DIR}/../../CFP2017rate/527.cam4_r")
7171

72+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-implicit-int")
73+
7274
set(CAM4_C_DEFS "-DNO_SHR_VMATH;-DCO2A;-DPERGRO")
7375
list(APPEND CAM4_C_DEFS "-DPLON=144;-DPLAT=96;-DPLEV=26;-DPCNST=3;-DPCOLS=4")
7476
list(APPEND CAM4_C_DEFS "-DPTRM=1;-DPTRN=1;-DPTRK=1")

0 commit comments

Comments
 (0)