Commit c92b286d authored by Kenneth Moreland's avatar Kenneth Moreland
Browse files

Merge branch 'configure-improvements'

parents 5bb098d2 607a073c
......@@ -167,9 +167,13 @@ ENDIF (ICET_USE_MPI)
# Add extra warnings when possible. The IceT build should be clean. I expect
# no warnings when bulding this code.
IF (CMAKE_COMPILER_IS_GNUCC)
SET(ICET_C_FLAGS_WARN "-ansi -Wall -Wno-long-long -Wcast-align -Wextra -Wformat-security -Wshadow -Wunused -Wreturn-type -Wpointer-arith -Wdeclaration-after-statement")
ENDIF (CMAKE_COMPILER_IS_GNUCC)
IF(CMAKE_C_COMPILER_ID STREQUAL "Clang")
SET(CMAKE_COMPILER_IS_CLANG 1)
ENDIF()
IF (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANG)
SET(ICET_C_FLAGS_WARN "-ansi -Wall -Wno-long-long -Wextra -Wformat-security -Wshadow -Wunused -Wreturn-type -Wpointer-arith -Wdeclaration-after-statement")
ENDIF (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_CLANG)
# Configure testing support.
IF (BUILD_TESTING)
......
......@@ -9,8 +9,16 @@ SET(ICET_MPI_SRCS
mpi.c
)
SET(ICET_MPI_HEADERS
../include/IceTMPI.h
)
IF (ICET_USE_MPI)
ICET_ADD_LIBRARY(IceTMPI ${ICET_MPI_SRCS})
ICET_ADD_LIBRARY(IceTMPI ${ICET_MPI_SRCS} ${ICET_MPI_HEADERS})
SET_SOURCE_FILES_PROPERTIES(${ICET_MPI_HEADERS}
PROPERTIES HEADER_FILE_ONLY TRUE
)
TARGET_LINK_LIBRARIES(IceTMPI
IceTCore
......
......@@ -231,11 +231,11 @@ IceTCommunicator icetCreateMPICommunicator(MPI_Comm mpi_comm)
MPI_Errhandler_create(ErrorHandler, &eh);
MPI_Errhandler_set(*((MPI_Comm *)comm->data), eh);
MPI_Errhandler_free(&eh);
#else // MPI_VERSION >= 2
#else /* MPI_VERSION >= 2 */
MPI_Comm_create_errhandler(ErrorHandler, &eh);
MPI_Comm_set_errhandler(*((MPI_Comm *)comm->data), eh);
MPI_Errhandler_free(&eh);
#endif // MPI_VERSION >= 2
#endif /* MPI_VERSION >= 2 */
#endif
return comm;
......
......@@ -6,12 +6,20 @@
#
SET(ICET_GL_SRCS
gl_state.c
gl_draw.c
gl_image.c
)
gl_state.c
gl_draw.c
gl_image.c
)
SET(ICET_GL_HEADERS
../include/IceTGL.h
)
ICET_ADD_LIBRARY(IceTGL ${ICET_GL_SRCS})
ICET_ADD_LIBRARY(IceTGL ${ICET_GL_SRCS} ${ICET_GL_HEADERS})
SET_SOURCE_FILES_PROPERTIES(${ICET_GL_HEADERS}
PROPERTIES HEADER_FILE_ONLY TRUE
)
TARGET_LINK_LIBRARIES(IceTGL
IceTCore
......
......@@ -6,32 +6,60 @@
#
SET(ICET_SRCS
porting.c
context.c
state.c
diagnostics.c
communication.c
tiles.c
timing.c
matrix.c
projections.c
draw.c
image.c
../strategies/common.c
../strategies/select.c
../strategies/direct.c
../strategies/sequential.c
../strategies/split.c
../strategies/reduce.c
../strategies/vtree.c
../strategies/bswap.c
../strategies/radixk.c
../strategies/tree.c
../strategies/automatic.c
)
ICET_ADD_LIBRARY(IceTCore ${ICET_SRCS})
porting.c
context.c
state.c
diagnostics.c
communication.c
tiles.c
timing.c
matrix.c
projections.c
draw.c
image.c
../strategies/common.c
../strategies/select.c
../strategies/direct.c
../strategies/sequential.c
../strategies/split.c
../strategies/reduce.c
../strategies/vtree.c
../strategies/bswap.c
../strategies/radixk.c
../strategies/tree.c
../strategies/automatic.c
)
SET(ICET_HEADERS
../include/IceT.h
../include/IceTDevCommunication.h
../include/IceTDevContext.h
../include/IceTDevDiagnostics.h
../include/IceTDevGLImage.h
../include/IceTDevImage.h
../include/IceTDevMatrix.h
../include/IceTDevPorting.h
../include/IceTDevProjections.h
../include/IceTDevState.h
../include/IceTDevStrategySelect.h
../include/IceTDevTiming.h
cc_composite_func_body.h
cc_composite_template_body.h
compress_func_body.h
compress_template_body.h
decompress_func_body.h
decompress_template_body.h
../strategies/common.h
)
ICET_ADD_LIBRARY(IceTCore ${ICET_SRCS} ${ICET_HEADERS})
SET_SOURCE_FILES_PROPERTIES(${ICET_HEADERS}
PROPERTIES HEADER_FILE_ONLY TRUE
)
IF (UNIX)
# Depend on the math library under Unix.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment