Skip to content

Commit

Permalink
Hashing for unique-objects-container to use external MD5 function (#1652
Browse files Browse the repository at this point in the history
)

* md5 hash w/wo mex

* add getmd5 dir

* separate class for hash function

* fix CI, warnings

* move to c++

* const in gcc

* tests

* restore mex to stored

* review responses

* fix comment position

* disambiguate constant
  • Loading branch information
cmarooney-stfc authored May 17, 2024
1 parent 8330329 commit 1592b8a
Show file tree
Hide file tree
Showing 12 changed files with 1,115 additions and 33 deletions.
1 change: 1 addition & 0 deletions _LowLevelCode/cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ else()
endif()

set(MEX_FUNCTIONS
"GetMD5"
"cpp_communicator"
"get_ascii_file"
"serialiser"
Expand Down
24 changes: 24 additions & 0 deletions _LowLevelCode/cpp/GetMD5/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
set(
SRC_FILES
"GetMD5.cpp"
)

set(
HDR_FILES
)

if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
# On GCC you must pass OpenMP_CXX_FLAGS to the linker
set(LIBS "${OpenMP_CXX_FLAGS}")
endif()

set(MEX_NAME "GetMD5")
pace_add_mex(
NAME "${MEX_NAME}"
SRC "${SRC_FILES}" "${HDR_FILES}"
LINK_TO "${LIBS}"
)
if(${OPENMP_FOUND})
target_compile_options("${MEX_NAME}" PRIVATE ${OpenMP_CXX_FLAGS})
target_link_options("${MEX_NAME}" PRIVATE ${OpenMP_EXE_LINKER_FLAGS})
endif()
Loading

0 comments on commit 1592b8a

Please sign in to comment.