diff --git a/.gitmodules b/.gitmodules index 6a228dff968536e5655283c6208197be025efe3b..746b20b3e40de8fd7deccc646dddc6f8d8383bfe 100644 --- a/.gitmodules +++ b/.gitmodules @@ -16,9 +16,3 @@ [submodule "external/oskar"] path = external/oskar url = https://gitlab.com/ska-telescope/sim/oskar.git -[submodule "external/xtensor-blas"] - path = external/xtensor-blas - url = https://github.com/xtensor-stack/xtensor-blas.git -[submodule "external/xtensor-fftw"] - path = external/xtensor-fftw - url = https://github.com/xtensor-stack/xtensor-fftw.git diff --git a/CMakeLists.txt b/CMakeLists.txt index e94f96f37bf58fa1810a6f43800e315984b9d8e9..89114c6f399945f0c97f75ab2d61d73ad1477ea2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -102,6 +102,7 @@ find_package(Casacore REQUIRED COMPONENTS casa ms tables measures fits) include_directories(SYSTEM ${CASACORE_INCLUDE_DIRS}) # Fetch XTensor and related libraries. +set(XTENSOR_LIBRARIES xtl xtensor xtensor-blas xtensor-fftw) include(external/aocommon/CMake/FetchXTensor.cmake) # Find and include Boost headers (boost::math required for MWA beam) diff --git a/cpp/aterms/CMakeLists.txt b/cpp/aterms/CMakeLists.txt index 001d50b7aec98c00d0aed6b5defeff9d94206d3f..5afd5fb82199c5ea807abc48b0db0b5636f51e56 100644 --- a/cpp/aterms/CMakeLists.txt +++ b/cpp/aterms/CMakeLists.txt @@ -22,13 +22,8 @@ add_library( # Compilation must therefore generate relocatable code set_property(TARGET aterms PROPERTY POSITION_INDEPENDENT_CODE ON) -# Link to XTensor, which is loaded using FetchXTensor.cmake. -target_link_libraries(aterms xtensor) - -# Add the XTensor dependencies that use submodules. -target_include_directories( - aterms SYSTEM PRIVATE ${CMAKE_SOURCE_DIR}/external/xtensor-blas/include - ${CMAKE_SOURCE_DIR}/external/xtensor-fftw/include) +# Link to XTensor libraries, which are loaded using FetchXTensor.cmake. +target_link_libraries(aterms xtensor xtl xtensor-blas xtensor-fftw) install( FILES atermconfig.h diff --git a/cpp/test/CMakeLists.txt b/cpp/test/CMakeLists.txt index 9635adce5438b5486cb314550e92470836947b9b..14a9bfe14cfd19b8e37a9bb7803d9e9e4b269d54 100644 --- a/cpp/test/CMakeLists.txt +++ b/cpp/test/CMakeLists.txt @@ -104,16 +104,18 @@ add_test(NAME download_mocks set_tests_properties(download_mocks PROPERTIES FIXTURES_SETUP mocks) add_executable(unittests ${TEST_FILENAMES}) -target_link_libraries(unittests everybeam ${Boost_LIBRARIES} schaapcommon - xtensor) +target_link_libraries( + unittests + everybeam + ${Boost_LIBRARIES} + schaapcommon + xtensor + xtl + xtensor-fftw) # Required to get the config.h header target_include_directories(unittests PRIVATE ${CMAKE_BINARY_DIR}) -# Add the XTensor dependencies that use submodules. -target_include_directories( - unittests SYSTEM PRIVATE ${CMAKE_SOURCE_DIR}/external/xtensor-fftw/include) - # Add test for automatically (re)building unittests if needed. add_test(NAME buildunittests COMMAND ${CMAKE_COMMAND} --build ${CMAKE_BINARY_DIR} --target unittests) diff --git a/demo/CMakeLists.txt b/demo/CMakeLists.txt index d36841f080c3a06b41362259793ba2abf65b99e7..357cc92a3373c4162713e80938759dbfa983424a 100644 --- a/demo/CMakeLists.txt +++ b/demo/CMakeLists.txt @@ -46,7 +46,7 @@ if(CFITSIO_FOUND) tElementBeamOSKARDipole tElementBeamOSKARSphericalWave) foreach(TEST ${CFITSIO_TESTS}) add_executable(${TEST} ${TEST}.cc) - target_link_libraries(${TEST} PUBLIC beamhelper xtensor) + target_link_libraries(${TEST} PUBLIC beamhelper xtensor xtl) target_include_directories(${TEST} PUBLIC ${CMAKE_BINARY_DIR}) # These are not "tests" in the strict sense of the word, so don't add them to test stack diff --git a/external/aocommon b/external/aocommon index 8e328a112239ad57200db62b450f9c05fc13f390..96a6759920f72e43d086e309d8d291fd8f5546b5 160000 --- a/external/aocommon +++ b/external/aocommon @@ -1 +1 @@ -Subproject commit 8e328a112239ad57200db62b450f9c05fc13f390 +Subproject commit 96a6759920f72e43d086e309d8d291fd8f5546b5 diff --git a/external/xtensor-blas b/external/xtensor-blas deleted file mode 160000 index 66ab0fa7cd53d0b914f89d4d451576a9240ea457..0000000000000000000000000000000000000000 --- a/external/xtensor-blas +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 66ab0fa7cd53d0b914f89d4d451576a9240ea457 diff --git a/external/xtensor-fftw b/external/xtensor-fftw deleted file mode 160000 index e6be85a376624da10629b6525c81759e02020308..0000000000000000000000000000000000000000 --- a/external/xtensor-fftw +++ /dev/null @@ -1 +0,0 @@ -Subproject commit e6be85a376624da10629b6525c81759e02020308