| … | … | @@ -113,6 +113,25 @@ INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR} |
| 113 | 113 | INCLUDE(OpenCogMacros) |
| 114 | 114 | INCLUDE(OpenCogGuile) |
| 115 | 115 | |
| 116 | # ---------------------------------------------------------- |
| 117 | # Check if RocksStorage is available by trying to load the Guile module |
| 118 | |
| 119 | IF (HAVE_GUILE) |
| 120 | EXECUTE_PROCESS( |
| 121 | COMMAND guile -c "(use-modules (opencog persist-rocks))" |
| 122 | RESULT_VARIABLE ROCKS_MODULE_RESULT |
| 123 | OUTPUT_QUIET ERROR_QUIET |
| 124 | ) |
| 125 | |
| 126 | IF (ROCKS_MODULE_RESULT EQUAL 0) |
| 127 | SET(HAVE_ROCKS_STORAGE 1) |
| 128 | ADD_DEFINITIONS(-DHAVE_ROCKS_STORAGE) |
| 129 | MESSAGE(STATUS "RocksStorage found - enabling storage tests") |
| 130 | ELSE () |
| 131 | MESSAGE(STATUS "RocksStorage not found - skipping storage tests") |
| 132 | ENDIF () |
| 133 | ENDIF (HAVE_GUILE) |
| 134 | |
| 116 | 135 | # ========================================================== |
| 117 | 136 | # Decide what to build, based on the packages found. |
| 118 | 137 | |