mirror of
https://github.com/lucaspalomodevelop/meshlab.git
synced 2026-03-13 00:07:24 +00:00
remove nexus submodule and download it using cmake
This commit is contained in:
parent
65012cd020
commit
b9c9bb264b
3
.gitmodules
vendored
3
.gitmodules
vendored
@ -2,6 +2,3 @@
|
|||||||
path = src/vcglib
|
path = src/vcglib
|
||||||
url = https://github.com/cnr-isti-vclab/vcglib
|
url = https://github.com/cnr-isti-vclab/vcglib
|
||||||
branch = devel
|
branch = devel
|
||||||
[submodule "src/external/nexus"]
|
|
||||||
path = src/external/nexus
|
|
||||||
url = https://github.com/cnr-isti-vclab/nexus
|
|
||||||
|
|||||||
4
src/external/newuoa.cmake
vendored
4
src/external/newuoa.cmake
vendored
@ -2,11 +2,11 @@
|
|||||||
# Copyright 2019, 2020, Visual Computing Lab, ISTI - Italian National Research Council
|
# Copyright 2019, 2020, Visual Computing Lab, ISTI - Italian National Research Council
|
||||||
# SPDX-License-Identifier: BSL-1.0
|
# SPDX-License-Identifier: BSL-1.0
|
||||||
|
|
||||||
option(ALLOW_BUNDLED_NEWUOA "Allow use of bundled newuoa source" ON)
|
option(MESHLAB_ALLOW_BUNDLED_NEWUOA "Allow use of bundled newuoa source" ON)
|
||||||
|
|
||||||
set(NEWUOA_DIR ${VCGDIR}/wrap/newuoa)
|
set(NEWUOA_DIR ${VCGDIR}/wrap/newuoa)
|
||||||
|
|
||||||
if(ALLOW_BUNDLED_NEWUOA AND EXISTS "${NEWUOA_DIR}/include/newuoa.h")
|
if(MESHLAB_ALLOW_BUNDLED_NEWUOA AND EXISTS "${NEWUOA_DIR}/include/newuoa.h")
|
||||||
message(STATUS "- newuoa - using bundled source")
|
message(STATUS "- newuoa - using bundled source")
|
||||||
add_library(external-newuoa INTERFACE)
|
add_library(external-newuoa INTERFACE)
|
||||||
target_include_directories(external-newuoa INTERFACE ${NEWUOA_DIR}/include)
|
target_include_directories(external-newuoa INTERFACE ${NEWUOA_DIR}/include)
|
||||||
|
|||||||
1
src/external/nexus
vendored
1
src/external/nexus
vendored
@ -1 +0,0 @@
|
|||||||
Subproject commit 9f56edab7cf80d2d4a654e65be087ebd973f66bd
|
|
||||||
27
src/external/nexus.cmake
vendored
27
src/external/nexus.cmake
vendored
@ -2,12 +2,31 @@
|
|||||||
# Copyright 2019, 2020, Visual Computing Lab, ISTI - Italian National Research Council
|
# Copyright 2019, 2020, Visual Computing Lab, ISTI - Italian National Research Council
|
||||||
# SPDX-License-Identifier: BSL-1.0
|
# SPDX-License-Identifier: BSL-1.0
|
||||||
|
|
||||||
option(ALLOW_BUNDLED_NEXUS "Allow use of bundled nexus source" ON)
|
option(MESHLAB_ALLOW_DOWNLOAD_SOURCE_NEXUS "Allow download and use of nexus source" ON)
|
||||||
|
|
||||||
|
if(MESHLAB_ALLOW_DOWNLOAD_SOURCE_NEXUS)
|
||||||
|
# todo - make release of nexus and corto
|
||||||
|
set(NEXUS_DIR ${MESHLAB_EXTERNAL_DOWNLOAD_DIR}/nexus-master)
|
||||||
|
set(CORTO_DIR ${NEXUS_DIR}/src/corto)
|
||||||
|
|
||||||
|
if (NOT EXISTS "${NEXUS_DIR}/CMakeLists.txt")
|
||||||
|
set(NEXUS_LINK https://github.com/cnr-isti-vclab/nexus/archive/refs/heads/master.zip)
|
||||||
|
download_and_unzip(${NEXUS_LINK} ${MESHLAB_EXTERNAL_DOWNLOAD_DIR} "nexus")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (NOT EXISTS "${CORTO_DIR}/CMakeLists.txt")
|
||||||
|
file(REMOVE_RECURSE ${NEXUS_DIR}/src/corto)
|
||||||
|
set(CORTO_LINK https://github.com/cnr-isti-vclab/corto/archive/refs/heads/master.zip)
|
||||||
|
download_and_unzip(${CORTO_LINK} "${NEXUS_DIR}/src/" "corto")
|
||||||
|
file(RENAME ${NEXUS_DIR}/src/corto-master ${NEXUS_DIR}/src/corto)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
message(STATUS "- nexus - using downloaded source")
|
||||||
|
|
||||||
if(ALLOW_BUNDLED_NEXUS AND EXISTS "${CMAKE_CURRENT_LIST_DIR}/nexus/CMakeLists.txt")
|
|
||||||
message(STATUS "- nexus - using bundled source")
|
|
||||||
set (BUILD_NXS_BUILD OFF)
|
set (BUILD_NXS_BUILD OFF)
|
||||||
set (BUILD_NXS_EDIT OFF)
|
set (BUILD_NXS_EDIT OFF)
|
||||||
set (BUILD_NXS_VIEW OFF)
|
set (BUILD_NXS_VIEW OFF)
|
||||||
add_subdirectory(${CMAKE_CURRENT_LIST_DIR}/nexus EXCLUDE_FROM_ALL)
|
add_subdirectory(${NEXUS_DIR} EXCLUDE_FROM_ALL)
|
||||||
|
add_library(external-nexus INTERFACE)
|
||||||
|
target_link_libraries(external-nexus INTERFACE nexus)
|
||||||
endif()
|
endif()
|
||||||
|
|||||||
@ -2,7 +2,7 @@
|
|||||||
# SPDX-License-Identifier: BSL-1.0
|
# SPDX-License-Identifier: BSL-1.0
|
||||||
|
|
||||||
# Only build if we have nexus
|
# Only build if we have nexus
|
||||||
if (TARGET nexus)
|
if (TARGET external-nexus)
|
||||||
|
|
||||||
set(SOURCES filter_io_nxs.cpp)
|
set(SOURCES filter_io_nxs.cpp)
|
||||||
|
|
||||||
@ -10,7 +10,7 @@ if (TARGET nexus)
|
|||||||
|
|
||||||
add_meshlab_plugin(filter_io_nxs MODULE ${SOURCES} ${HEADERS})
|
add_meshlab_plugin(filter_io_nxs MODULE ${SOURCES} ${HEADERS})
|
||||||
|
|
||||||
target_link_libraries(filter_io_nxs PRIVATE nexus)
|
target_link_libraries(filter_io_nxs PRIVATE external-nexus)
|
||||||
|
|
||||||
else()
|
else()
|
||||||
message(STATUS "Skipping filter_io_nxs - missing nexus")
|
message(STATUS "Skipping filter_io_nxs - missing nexus")
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user