mirror of
https://github.com/lucaspalomodevelop/meshlab.git
synced 2026-03-19 19:14:42 +00:00
Merge pull request #849 from alemuntoni/external_libs_cmake_option
external is a subdirectory
This commit is contained in:
commit
b3df3660e8
@ -26,6 +26,9 @@ find_package(
|
||||
COMPONENTS OpenGL Xml Network
|
||||
REQUIRED)
|
||||
find_package(OpenMP)
|
||||
if (NOT BUILD_MINI)
|
||||
find_package(Qt5Qml)
|
||||
endif()
|
||||
|
||||
message(STATUS "Searching for required components with bundled fallback")
|
||||
find_package(GLEW)
|
||||
@ -103,14 +106,24 @@ endif()
|
||||
|
||||
### Enter subdirectories
|
||||
|
||||
# VCGLib -- required
|
||||
if(NOT VCGDIR)
|
||||
get_filename_component(VCGDIR "${CMAKE_CURRENT_LIST_DIR}/vcglib" ABSOLUTE)
|
||||
if(NOT EXISTS ${VCGDIR})
|
||||
set(VCGDIR NOTFOUND)
|
||||
endif()
|
||||
endif()
|
||||
set(VCGDIR "${VCGDIR}")
|
||||
|
||||
if(NOT VCGDIR)
|
||||
message(FATAL_ERROR "VCGLib not found. Please clone recursively the MeshLab repo.")
|
||||
endif()
|
||||
|
||||
|
||||
# External
|
||||
set(EXTERNAL_DIR ${CMAKE_CURRENT_SOURCE_DIR}/external)
|
||||
include(${CMAKE_CURRENT_SOURCE_DIR}/external_common.cmake)
|
||||
if(NOT BUILD_MINI)
|
||||
message(STATUS "Searching for optional components")
|
||||
find_package(Qt5Qml)
|
||||
include(${EXTERNAL_DIR}/external.cmake)
|
||||
endif()
|
||||
include(${EXTERNAL_DIR}/external_common.cmake)
|
||||
add_subdirectory(${EXTERNAL_DIR})
|
||||
|
||||
# Start automoc/autouic/autorcc
|
||||
set(CMAKE_AUTOMOC ON)
|
||||
|
||||
11
src/external/CMakeLists.txt
vendored
Normal file
11
src/external/CMakeLists.txt
vendored
Normal file
@ -0,0 +1,11 @@
|
||||
# Copyright 2019, 2020, Collabora, Ltd.
|
||||
# Copyright 2019, 2020, Visual Computing Lab, ISTI - Italian National Research Council
|
||||
# SPDX-License-Identifier: BSL-1.0
|
||||
|
||||
# GLEW - required
|
||||
include(${EXTERNAL_DIR}/glew.cmake)
|
||||
|
||||
if(NOT BUILD_MINI)
|
||||
message(STATUS "Searching for optional components")
|
||||
include(${EXTERNAL_DIR}/external.cmake)
|
||||
endif()
|
||||
@ -12,23 +12,5 @@ if(BUILD_BUNDLED_SOURCES_WITHOUT_WARNINGS)
|
||||
endif()
|
||||
endif()
|
||||
|
||||
# GLEW - required
|
||||
include(${EXTERNAL_DIR}/glew.cmake)
|
||||
|
||||
|
||||
# VCGLib -- required
|
||||
if(NOT VCGDIR)
|
||||
get_filename_component(VCGDIR "${CMAKE_CURRENT_LIST_DIR}/vcglib" ABSOLUTE)
|
||||
if(NOT EXISTS ${VCGDIR})
|
||||
set(VCGDIR NOTFOUND)
|
||||
endif()
|
||||
endif()
|
||||
set(VCGDIR "${VCGDIR}")
|
||||
|
||||
if(NOT VCGDIR)
|
||||
message(FATAL_ERROR "VCGLib not found. Please clone recursively the MeshLab repo.")
|
||||
endif()
|
||||
|
||||
|
||||
# Eigen3 - required
|
||||
include(${EXTERNAL_DIR}/eigen.cmake)
|
||||
@ -8,7 +8,7 @@ if(TARGET external-IDTFConverter)
|
||||
set(SOURCES io_u3d.cpp)
|
||||
|
||||
set(HEADERS io_u3d.h)
|
||||
include_directories("${U3D_DIR}/src/IDTF")
|
||||
include_directories("${EXTERNAL_DIR}/u3d/src/IDTF")
|
||||
|
||||
add_library(io_u3d MODULE ${SOURCES} ${HEADERS})
|
||||
|
||||
|
||||
@ -81,7 +81,7 @@ bool U3DIOPlugin::save(
|
||||
const int mask,
|
||||
const RichParameterList & par,
|
||||
vcg::CallBackPos *,
|
||||
QWidget *parent)
|
||||
QWidget *)
|
||||
{
|
||||
vcg::tri::Allocator<CMeshO>::CompactVertexVector(m.cm);
|
||||
vcg::tri::Allocator<CMeshO>::CompactFaceVector(m.cm);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user