Commit b4cea01aa6e8d7a405c6ac7a540641984b32d97c
1 parent
1d1a38e1
removed automated download of STIM
Showing
3 changed files
with
24 additions
and
9 deletions
Show diff stats
cmake/FindSTIM.cmake
1 | -include(FindPackageHandleStandardArgs) | ||
2 | - | ||
3 | -set(STIM_INCLUDE_DIR $ENV{STIMLIB_PATH}) | ||
4 | - | ||
5 | -find_package_handle_standard_args(STIM DEFAULT_MSG STIM_INCLUDE_DIR) | ||
6 | - | ||
7 | -if(STIM_FOUND) | ||
8 | - set(STIM_INCLUDE_DIRS ${STIM_INCLUDE_DIR}) | ||
9 | -endif() | ||
10 | \ No newline at end of file | 1 | \ No newline at end of file |
2 | +# finds the STIM library (downloads it if it isn't present) | ||
3 | +# set STIMLIB_PATH to the directory containing the stim subdirectory (the stim repository) | ||
4 | + | ||
5 | +include(FindPackageHandleStandardArgs) | ||
6 | + | ||
7 | +set(STIM_INCLUDE_DIR $ENV{STIMLIB_PATH}) | ||
8 | + | ||
9 | +find_package_handle_standard_args(STIM DEFAULT_MSG STIM_INCLUDE_DIR) | ||
10 | + | ||
11 | +if(STIM_FOUND) | ||
12 | + set(STIM_INCLUDE_DIRS ${STIM_INCLUDE_DIR}) | ||
13 | +elseif(STIM_FOUND) | ||
14 | + #if the STIM library isn't found, download it | ||
15 | + #file(REMOVE_RECURSE ${CMAKE_BINARY_DIR}/stimlib) #remove the stimlib directory if it exists | ||
16 | + #set(STIM_GIT "https://git.stim.ee.uh.edu/codebase/stimlib.git") | ||
17 | + #execute_process(COMMAND git clone --depth 1 ${STIM_GIT} WORKING_DIRECTORY ${CMAKE_BINARY_DIR}) | ||
18 | + #set(STIM_INCLUDE_DIRS "${CMAKE_BINARY_DIR}/stimlib" CACHE TYPE PATH) | ||
19 | + message("STIM library not found. Set the STIMLIB_PATH environment variable to the STIMLIB location.") | ||
20 | + message("STIMLIB can be found here: https://git.stim.ee.uh.edu/codebase/stimlib") | ||
21 | +endif(STIM_FOUND) | ||
22 | + | ||
23 | +find_package_handle_standard_args(STIM DEFAULT_MSG STIM_INCLUDE_DIR) |
stim/envi/agilent_binary.h
stim/image/image.h
@@ -10,6 +10,7 @@ | @@ -10,6 +10,7 @@ | ||
10 | #include <limits> | 10 | #include <limits> |
11 | #include <typeinfo> | 11 | #include <typeinfo> |
12 | #include <fstream> | 12 | #include <fstream> |
13 | +#include <cstring> | ||
13 | 14 | ||
14 | namespace stim{ | 15 | namespace stim{ |
15 | /// This static class provides the STIM interface for loading, saving, and storing 2D images. | 16 | /// This static class provides the STIM interface for loading, saving, and storing 2D images. |