mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-06-03 10:32:40 +00:00
Add new option DEP_DOWNLOAD_DIR and go with URLs everywhere
This commit is contained in:
20
deps/CMakeLists.txt
vendored
20
deps/CMakeLists.txt
vendored
@@ -32,6 +32,7 @@ if (NPROC EQUAL 0)
|
||||
endif ()
|
||||
|
||||
set(DESTDIR "${CMAKE_CURRENT_BINARY_DIR}/destdir" CACHE PATH "Destination directory")
|
||||
set(DEP_DOWNLOAD_DIR ${CMAKE_CURRENT_BINARY_DIR} CACHE PATH "Path for downloaded source packages.")
|
||||
|
||||
option(DEP_DEBUG "Build debug variants (only applicable on Windows)" ON)
|
||||
|
||||
@@ -46,6 +47,7 @@ endif()
|
||||
# option(DEP_BUILD_IGL_STATIC "Build IGL as a static library. Might cause link errors and increase binary size." OFF)
|
||||
|
||||
message(STATUS "PrusaSlicer deps DESTDIR: ${DESTDIR}")
|
||||
message(STATUS "PrusaSlicer dowload dir for source packages: ${DEP_DOWNLOAD_DIR}")
|
||||
message(STATUS "PrusaSlicer deps debug build: ${DEP_DEBUG}")
|
||||
|
||||
find_package(Git REQUIRED)
|
||||
@@ -71,6 +73,7 @@ function(prusaslicer_add_cmake_project projectname)
|
||||
dep_${projectname}
|
||||
EXCLUDE_FROM_ALL ON
|
||||
INSTALL_DIR ${DESTDIR}/usr/local
|
||||
DOWNLOAD_DIR ${DEP_DOWNLOAD_DIR}/${projectname}
|
||||
${_gen}
|
||||
CMAKE_ARGS
|
||||
-DCMAKE_INSTALL_PREFIX:STRING=${DESTDIR}/usr/local
|
||||
@@ -187,23 +190,6 @@ set(_dep_list
|
||||
${EXPAT_PKG}
|
||||
)
|
||||
|
||||
if ("${CMAKE_SIZEOF_VOID_P}" STREQUAL "8")
|
||||
# Patch the boost::polygon library with a custom one.
|
||||
ExternalProject_Add(dep_boost_polygon
|
||||
EXCLUDE_FROM_ALL ON
|
||||
GIT_REPOSITORY "https://github.com/prusa3d/polygon"
|
||||
GIT_TAG prusaslicer_gmp
|
||||
DEPENDS dep_Boost
|
||||
CONFIGURE_COMMAND ""
|
||||
BUILD_COMMAND ""
|
||||
INSTALL_COMMAND ${CMAKE_COMMAND} -E copy_directory
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/dep_boost_polygon-prefix/src/dep_boost_polygon/include/boost/polygon"
|
||||
"${DESTDIR}/usr/local/include/boost/polygon"
|
||||
)
|
||||
# Only override boost::Polygon Voronoi implementation with Vojtech's GMP hacks on 64bit platforms.
|
||||
list(APPEND _dep_list "dep_boost_polygon")
|
||||
endif ()
|
||||
|
||||
if (MSVC)
|
||||
# Experimental
|
||||
#list(APPEND _dep_list "dep_qhull")
|
||||
|
||||
Reference in New Issue
Block a user