mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-06 00:48:18 -07:00
sci-mathematics/highs: fix amd and metis unbundling patches
My patches (*I* stole them from Fedora) to unbundle sci-libs/amd and sci-libs/metis would link against those libraries even when it was unnecessary. François Bissey has updated the patches to link against those libraries only in HiPO builds. Thank you! The revbump may not be necessary with --as-needed, but HiGHS builds relatively quickly and I'd rather not have to think about it. Closes: https://bugs.gentoo.org/975409 Signed-off-by: Michael Orlitzky <mjo@gentoo.org>
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
diff --git a/cmake/sources.cmake b/cmake/sources.cmake
|
||||
index 31e0630..354de9e 100644
|
||||
index 1e605de..f3cfeb0 100644
|
||||
--- a/cmake/sources.cmake
|
||||
+++ b/cmake/sources.cmake
|
||||
@@ -257,18 +257,6 @@ set(hipo_util_headers
|
||||
@@ -259,18 +259,6 @@ set(hipo_util_headers
|
||||
ipm/hipo/auxiliary/VectorOperations.h)
|
||||
|
||||
set(hipo_orderings_sources
|
||||
@@ -21,7 +21,7 @@ index 31e0630..354de9e 100644
|
||||
../extern/metis/GKlib/error.c
|
||||
../extern/metis/GKlib/mcore.c
|
||||
../extern/metis/GKlib/memory.c
|
||||
@@ -296,9 +284,6 @@ set(hipo_orderings_sources
|
||||
@@ -298,9 +286,6 @@ set(hipo_orderings_sources
|
||||
../extern/rcm/rcm.cpp)
|
||||
|
||||
set(hipo_orderings_headers
|
||||
@@ -32,17 +32,17 @@ index 31e0630..354de9e 100644
|
||||
../extern/metis/GKlib/gk_defs.h
|
||||
../extern/metis/GKlib/gk_macros.h
|
||||
diff --git a/highs/CMakeLists.txt b/highs/CMakeLists.txt
|
||||
index 7e90ad5..99ae0d1 100644
|
||||
index 7e90ad5..c92d997 100644
|
||||
--- a/highs/CMakeLists.txt
|
||||
+++ b/highs/CMakeLists.txt
|
||||
@@ -158,6 +158,7 @@ else()
|
||||
@@ -234,6 +234,7 @@ else()
|
||||
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/highs/hipo/factorhighs>
|
||||
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/highs/hipo/ipm>
|
||||
)
|
||||
+ target_link_libraries(highs PRIVATE amd)
|
||||
|
||||
|
||||
target_sources(highs PRIVATE ${sources} ${headers} ${win_version_file})
|
||||
+ target_link_libraries(highs PRIVATE amd)
|
||||
|
||||
# Optional Cuda
|
||||
if (CUPDLP_GPU)
|
||||
if (NOT USE_CMAKE_FIND_BLAS)
|
||||
if(APPLE)
|
||||
diff --git a/highs/ipm/hipo/factorhighs/Analyse.cpp b/highs/ipm/hipo/factorhighs/Analyse.cpp
|
||||
index 587c71a..e638240 100644
|
||||
--- a/highs/ipm/hipo/factorhighs/Analyse.cpp
|
||||
@@ -83,6 +83,3 @@ index b0ba1d7..6a11446 100644
|
||||
permutations[i].data(), control, info);
|
||||
log_.printDevInfo("AMD done\n");
|
||||
|
||||
--
|
||||
2.53.0
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
diff --git a/cmake/sources.cmake b/cmake/sources.cmake
|
||||
index 354de9e..06917f7 100644
|
||||
index f3cfeb0..b47d5ff 100644
|
||||
--- a/cmake/sources.cmake
|
||||
+++ b/cmake/sources.cmake
|
||||
@@ -257,56 +257,9 @@ set(hipo_util_headers
|
||||
@@ -259,56 +259,9 @@ set(hipo_util_headers
|
||||
ipm/hipo/auxiliary/VectorOperations.h)
|
||||
|
||||
set(hipo_orderings_sources
|
||||
@@ -60,17 +60,17 @@ index 354de9e..06917f7 100644
|
||||
|
||||
# redefinition of 'kHighsInf'
|
||||
diff --git a/highs/CMakeLists.txt b/highs/CMakeLists.txt
|
||||
index 99ae0d1..f2d873b 100644
|
||||
index c92d997..8eda6bd 100644
|
||||
--- a/highs/CMakeLists.txt
|
||||
+++ b/highs/CMakeLists.txt
|
||||
@@ -159,6 +159,7 @@ else()
|
||||
@@ -235,6 +235,7 @@ else()
|
||||
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/highs/hipo/ipm>
|
||||
)
|
||||
target_link_libraries(highs PRIVATE amd)
|
||||
+ target_link_libraries(highs PRIVATE metis)
|
||||
|
||||
target_sources(highs PRIVATE ${sources} ${headers} ${win_version_file})
|
||||
target_link_libraries(highs PRIVATE amd)
|
||||
+ target_link_libraries(highs PRIVATE metis)
|
||||
|
||||
# Optional Cuda
|
||||
if (CUPDLP_GPU)
|
||||
if (NOT USE_CMAKE_FIND_BLAS)
|
||||
if(APPLE)
|
||||
diff --git a/highs/ipm/hipo/factorhighs/Analyse.cpp b/highs/ipm/hipo/factorhighs/Analyse.cpp
|
||||
index e638240..0d9b4e5 100644
|
||||
--- a/highs/ipm/hipo/factorhighs/Analyse.cpp
|
||||
@@ -115,6 +115,3 @@ index 6a11446..37cca65 100644
|
||||
options, permutations[i].data(), iperm.data());
|
||||
|
||||
log_.printDevInfo("Metis done\n");
|
||||
--
|
||||
2.53.0
|
||||
|
||||
|
||||
Reference in New Issue
Block a user