From 92e4b2e78b8c3b8d0be02f612049ecdf2b451dc8 Mon Sep 17 00:00:00 2001 From: Corentin Le Molgat Date: Wed, 5 Mar 2025 15:51:26 +0100 Subject: [PATCH 1/3] Revert "remove dead cmake code" This reverts commit 14005fea48bf5cdd2df1cabcf0bd1fab6b220732. --- ortools/algorithms/python/CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ortools/algorithms/python/CMakeLists.txt b/ortools/algorithms/python/CMakeLists.txt index 19e4d8e7d1..87e29473d1 100644 --- a/ortools/algorithms/python/CMakeLists.txt +++ b/ortools/algorithms/python/CMakeLists.txt @@ -30,3 +30,10 @@ endif() target_link_libraries(knapsack_solver_pybind11 PRIVATE ${PROJECT_NAMESPACE}::ortools) add_library(${PROJECT_NAMESPACE}::knapsack_solver_pybind11 ALIAS knapsack_solver_pybind11) + +if(BUILD_TESTING) + file(GLOB PYTHON_SRCS "*_test.py") + foreach(FILE_NAME IN LISTS PYTHON_SRCS) + add_python_test(FILE_NAME ${FILE_NAME}) + endforeach() +endif() From e0f3e6c05ca4425c40bb7ac4c6f2bdbb430803a7 Mon Sep 17 00:00:00 2001 From: Corentin Le Molgat Date: Fri, 7 Mar 2025 08:00:23 +0100 Subject: [PATCH 2/3] fixup --- go.mod | 4 ++-- tools/doc/gen_ref_doc.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 07d157f42b..28d32ef94d 100644 --- a/go.mod +++ b/go.mod @@ -3,6 +3,6 @@ module github.com/google/or-tools go 1.22.2 require ( - github.com/golang/glog v1.2.2 - google.golang.org/protobuf v1.36.5 + github.com/golang/glog v1.2.2 + google.golang.org/protobuf v1.36.5 ) diff --git a/tools/doc/gen_ref_doc.py b/tools/doc/gen_ref_doc.py index a952b4060b..303c43ab21 100755 --- a/tools/doc/gen_ref_doc.py +++ b/tools/doc/gen_ref_doc.py @@ -161,7 +161,7 @@ def create_section_data(): 'ortools/graph/connectivity.h ' + 'ortools/graph/eulerian_path.h ' + 'ortools/graph/graph.h ' + 'ortools/graph/graphs.h ' + 'ortools/graph/hamiltonian_path.h ' + - 'ortools/graph/io.h ' + 'ortools/graph/iterators.h ' + + 'ortools/graph/graph_io.h ' + 'ortools/graph/iterators.h ' + 'ortools/graph/linear_assignment.h ' + 'ortools/graph/max_flow.h ' + 'ortools/graph/min_cost_flow.h ' + 'ortools/graph/minimum_spanning_tree.h ' + From b513292d1a0c7e0db7faa5261e0bedab2efaffab Mon Sep 17 00:00:00 2001 From: Mizux Seiha Date: Thu, 6 Mar 2025 11:48:48 +0100 Subject: [PATCH 3/3] nqueens.cc fixup --- examples/cpp/nqueens.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/cpp/nqueens.cc b/examples/cpp/nqueens.cc index ff2a0ae1d0..a6ec13fa00 100644 --- a/examples/cpp/nqueens.cc +++ b/examples/cpp/nqueens.cc @@ -29,6 +29,7 @@ #include "ortools/base/logging.h" #include "ortools/base/map_util.h" #include "ortools/base/types.h" +#include "ortools/constraint_solver/constraint_solver.h" #include "ortools/constraint_solver/constraint_solveri.h" ABSL_FLAG(bool, print, false, "If true, print one of the solution."); @@ -39,7 +40,6 @@ ABSL_FLAG( int, size, 0, "Size of the problem. If equal to 0, will test several increasing sizes."); ABSL_FLAG(bool, use_symmetry, false, "Use Symmetry Breaking methods"); -ABSL_DECLARE_FLAG(bool, cp_disable_solve); static const int kNumSolutions[] = { 1, 0, 0, 2, 10, 4, 40, 92, 352, 724, 2680, 14200, 73712, 365596, 2279184};