Skip to content

Commit f88e289

Browse files
committed
Revert "[SuiteSparse] Update and split into sub-packages (v2)"
This reverts commit ab42fb3.
1 parent f0046fa commit f88e289

File tree

76 files changed

+504
-1891
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

76 files changed

+504
-1891
lines changed

ports/ceres/0001_cmakelists_fixes.patch

Lines changed: 58 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,63 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt
22
index 8e49c19e..f8c61d92 100644
33
--- a/CMakeLists.txt
44
+++ b/CMakeLists.txt
5-
@@ -430,28 +430,7 @@ if (MINIGLOG)
5+
@@ -292,27 +292,28 @@ if (SUITESPARSE)
6+
# built with SuiteSparse support.
7+
8+
# Check for SuiteSparse and dependencies.
9+
- find_package(SuiteSparse 4.5.6 COMPONENTS CHOLMOD SPQR
10+
- OPTIONAL_COMPONENTS Partition)
11+
- if (SuiteSparse_FOUND)
12+
- set(SuiteSparse_DEPENDENCY "find_dependency(SuiteSparse ${SuiteSparse_VERSION})")
13+
+ find_package(SuiteSparse REQUIRED CONFIG)
14+
+ if (SUITESPARSE_FOUND)
15+
+ set(SuiteSparse_DEPENDENCY "find_dependency(SuiteSparse ${SuiteSparse_VERSION} CONFIG)")
16+
# By default, if all of SuiteSparse's dependencies are found, Ceres is
17+
# built with SuiteSparse support.
18+
message("-- Found SuiteSparse ${SuiteSparse_VERSION}, "
19+
"building with SuiteSparse.")
20+
-
21+
- if (SuiteSparse_NO_CMAKE OR NOT SuiteSparse_DIR)
22+
- install(FILES ${Ceres_SOURCE_DIR}/cmake/FindSuiteSparse.cmake
23+
- ${Ceres_SOURCE_DIR}/cmake/FindMETIS.cmake
24+
- DESTINATION ${RELATIVE_CMAKECONFIG_INSTALL_DIR})
25+
- endif (SuiteSparse_NO_CMAKE OR NOT SuiteSparse_DIR)
26+
- else (SuiteSparse_FOUND)
27+
+ add_library(SuiteSparse::CONFIG ALIAS SuiteSparse::suitesparseconfig)
28+
+ add_library(SuiteSparse::AMD ALIAS SuiteSparse::amd)
29+
+ add_library(SuiteSparse::CAMD ALIAS SuiteSparse::camd)
30+
+ add_library(SuiteSparse::CCOLAMD ALIAS SuiteSparse::ccolamd)
31+
+ add_library(SuiteSparse::COLAMD ALIAS SuiteSparse::colamd)
32+
+ add_library(SuiteSparse::CHOLMOD ALIAS SuiteSparse::cholmod)
33+
+ add_library(SuiteSparse::SPQR ALIAS SuiteSparse::spqr)
34+
+ add_library(METIS::METIS ALIAS metis)
35+
+ else (SUITESPARSE_FOUND)
36+
# Disable use of SuiteSparse if it cannot be found and continue.
37+
message("-- Did not find all SuiteSparse dependencies, disabling "
38+
"SuiteSparse support.")
39+
update_cache_variable(SUITESPARSE OFF)
40+
list(APPEND CERES_COMPILE_OPTIONS CERES_NO_SUITESPARSE)
41+
- endif (SuiteSparse_FOUND)
42+
+ endif (SUITESPARSE_FOUND)
43+
else (SUITESPARSE)
44+
message("-- Building without SuiteSparse.")
45+
list(APPEND CERES_COMPILE_OPTIONS CERES_NO_SUITESPARSE)
46+
@@ -395,9 +396,12 @@ endif()
47+
# GFlags.
48+
if (GFLAGS)
49+
# Don't search with REQUIRED as we can continue without gflags.
50+
- find_package(gflags 2.2.0)
51+
+ find_package(gflags CONFIG REQUIRED)
52+
if (gflags_FOUND)
53+
- if (TARGET gflags)
54+
+ if (TARGET gflags::gflags)
55+
+ if(NOT TARGET gflags)
56+
+ add_library(gflags ALIAS gflags::gflags)
57+
+ endif()
58+
message("-- Found Google Flags (gflags) version ${gflags_VERSION}: ${gflags_DIR}")
59+
else()
60+
message("-- Detected version of gflags: ${gflags_VERSION} does not define "
61+
@@ -430,28 +434,7 @@ if (MINIGLOG)
662
mark_as_advanced(FORCE GLOG_INCLUDE_DIR
763
GLOG_LIBRARY)
864
else (MINIGLOG)
@@ -32,7 +88,7 @@ index 8e49c19e..f8c61d92 100644
3288
endif (MINIGLOG)
3389

3490
if (NOT SCHUR_SPECIALIZATIONS)
35-
@@ -466,7 +445,7 @@ endif (NOT CUSTOM_BLAS)
91+
@@ -466,7 +449,7 @@ endif (NOT CUSTOM_BLAS)
3692

3793
if (BUILD_BENCHMARKS)
3894
# Version 1.3 was first to provide import targets

ports/ceres/0003_fix_exported_ceres_config.patch

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,28 +2,16 @@ diff --git a/cmake/CeresConfig.cmake.in b/cmake/CeresConfig.cmake.in
22
index ceb7e269..5dee7e3c 100644
33
--- a/cmake/CeresConfig.cmake.in
44
+++ b/cmake/CeresConfig.cmake.in
5-
@@ -178,7 +178,10 @@
6-
include(CMakeFindDependencyMacro)
7-
# Optional dependencies
8-
@METIS_DEPENDENCY@
9-
-@SuiteSparse_DEPENDENCY@
10-
+if (@SUITESPARSE@)
11-
+ find_dependency(CHOLMOD)
12-
+ find_dependency(SPQR)
13-
+endif()
14-
@CUDAToolkit_DEPENDENCY@
15-
@Threads_DEPENDENCY@
16-
17-
@@ -195,7 +198,7 @@
5+
@@ -195,7 +195,7 @@ set(CERES_EIGEN_VERSION @Eigen3_VERSION@)
186
# Search quietly to control the timing of the error message if not found. The
197
# search should be for an exact match, but for usability reasons do a soft
208
# match and reject with an explanation below.
219
-find_package(Eigen3 ${CERES_EIGEN_VERSION} QUIET)
22-
+find_dependency(Eigen3 CONFIG ${CERES_EIGEN_VERSION} QUIET)
10+
+find_package(Eigen3 CONFIG ${CERES_EIGEN_VERSION} QUIET)
2311
if (Eigen3_FOUND)
2412
if (NOT Eigen3_VERSION VERSION_EQUAL CERES_EIGEN_VERSION)
2513
# CMake's VERSION check in FIND_PACKAGE() will accept any version >= the
26-
@@ -217,55 +220,7 @@
14+
@@ -217,55 +217,8 @@ else (Eigen3_FOUND)
2715
endif (Eigen3_FOUND)
2816

2917
# glog (and maybe gflags).
@@ -76,6 +64,7 @@ index ceb7e269..5dee7e3c 100644
7664
- endif()
7765
- endif()
7866
-endif(CERES_USES_MINIGLOG)
67+
+include(CMakeFindDependencyMacro)
7968
+find_dependency(glog NO_MODULE)
8069

8170
# Import exported Ceres targets, if they have not already been imported.

ports/ceres/vcpkg.json

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"name": "ceres",
33
"version": "2.2.0",
4-
"port-version": 1,
54
"description": "non-linear optimization package",
65
"homepage": "https://github.com/ceres-solver/ceres-solver",
76
"license": "Apache-2.0",
@@ -50,12 +49,9 @@
5049
]
5150
},
5251
{
53-
"name": "suitesparse-cholmod",
54-
"features": [
55-
"matrixops"
56-
]
57-
},
58-
"suitesparse-spqr"
52+
"name": "suitesparse",
53+
"default-features": false
54+
}
5955
]
6056
},
6157
"tools": {

ports/colmap/vcpkg.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"name": "colmap",
33
"version": "3.11.1",
4-
"port-version": 2,
54
"description": "COLMAP is a general-purpose Structure-from-Motion (SfM) and Multi-View Stereo (MVS) pipeline with a graphical and command-line interface. It offers a wide range of features for reconstruction of ordered and unordered image collections. The software is licensed under the new BSD license.",
65
"homepage": "https://colmap.github.io/",
76
"license": "BSD-3-Clause",

ports/g2o/portfile.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ vcpkg_cmake_configure(
2525
-DBUILD_LGPL_SHARED_LIBS=${BUILD_LGPL_SHARED_LIBS}
2626
-DG2O_BUILD_EXAMPLES=OFF
2727
-DG2O_BUILD_APPS=OFF
28-
-DBUILD_CSPARSE=OFF
2928
)
3029

3130
vcpkg_cmake_install()

ports/g2o/vcpkg.json

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,14 @@
11
{
22
"name": "g2o",
33
"version-date": "2024-12-14",
4-
"port-version": 3,
4+
"port-version": 2,
55
"description": "g2o: A General Framework for Graph Optimization",
66
"homepage": "https://openslam.org/g2o.html",
77
"dependencies": [
88
"ceres",
99
"eigen3",
1010
"lapack",
11-
"suitesparse-cholmod",
12-
"suitesparse-cxsparse",
11+
"suitesparse",
1312
{
1413
"name": "vcpkg-cmake",
1514
"host": true

ports/suitesparse-amd/portfile.cmake

Lines changed: 0 additions & 33 deletions
This file was deleted.

ports/suitesparse-amd/vcpkg.json

Lines changed: 0 additions & 19 deletions
This file was deleted.

ports/suitesparse-btf/portfile.cmake

Lines changed: 0 additions & 36 deletions
This file was deleted.

ports/suitesparse-btf/vcpkg.json

Lines changed: 0 additions & 19 deletions
This file was deleted.

0 commit comments

Comments
 (0)