Skip to content

Commit

Permalink
Merge pull request #37 from gentryx/master
Browse files Browse the repository at this point in the history
call Autotools from CMake to make sure code generation works as intended
  • Loading branch information
jeffhammond committed Jun 28, 2017
2 parents 5909f06 + 2edb574 commit 3107abb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,8 @@
add_custom_command(
OUTPUT "${CMAKE_CURRENT_SOURCE_DIR}/bigmpiconf.h"
COMMAND "./autogen.sh"
COMMAND "./configure"
WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/..")

file(GLOB SOURCES "${CMAKE_CURRENT_SOURCE_DIR}/*.c")
add_library(bigmpi ${LIB_LINKAGE_TYPE} ${SOURCES})
add_library(bigmpi ${LIB_LINKAGE_TYPE} ${SOURCES} "bigmpiconf.h")
2 changes: 2 additions & 0 deletions test/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
file(GLOB TESTS "test_*.c")

include_directories("${CMAKE_CURRENT_SOURCE_DIR}/../src")

foreach(test ${TESTS})
string(REPLACE ".c" "" buffer0 ${test})
string(REPLACE "${CMAKE_SOURCE_DIR}" "" buffer1 ${buffer0})
Expand Down

0 comments on commit 3107abb

Please sign in to comment.