Commit Graph

84 Commits

Author SHA1 Message Date
Mizux Seiha
b0a78201dd cmake: Fix GLPK support (Fix #3312)
* Eigen was spuriously enabling fortran
* Missing GLKP helpers functions
2022-06-09 12:39:57 +02:00
Corentin Le Molgat
a8ffe28948 cmake: install internal doc. 2022-04-06 11:15:59 +02:00
Corentin Le Molgat
3c6f88de3b c++: Add USE_LP_PARSER define (#3201) 2022-03-25 11:12:00 +01:00
Corentin Le Molgat
57b182d2df make: Create a bundle lib on windows 2022-03-08 11:02:04 +00:00
Corentin Le Molgat
ffb5ea4dc3 make: Fix RPATH in [fz_]archive 2022-03-04 09:17:01 +01:00
Mizux Seiha
32b101b9ee cmake: Fixup for pdlp 2022-02-25 23:43:01 +01:00
Mizux Seiha
cde1771554 cmake(cpp): Add model_builder wrappers 2022-02-24 08:29:43 +01:00
Corentin Le Molgat
e01e061bb6 cmake: cpp.cmake cleanup 2022-02-23 16:17:47 +01:00
Laurent Perron
357ff08581 fix C++20 for windows when compiling pdlp 2022-02-19 16:21:46 +01:00
Laurent Perron
0266492da6 more work on makefiles/cmake.cpp 2022-02-19 15:05:17 +01:00
Corentin Le Molgat
761982a17f cmake: Add PDLP support 2022-02-17 15:02:23 +01:00
Geoffrey Gunter
68f4e80e2c Fix CMake package config file (#3068)
* Fix CMake package config file

There are currently a few issues with how the COIN-OR dependencies are
resolved when using `find_package(ortools CONFIG)` to add or-tools to
an external CMake project.

* With CMake >=3.9.6, we try to find the Clp and Cbc packages using the
  CONFIG mode of `find_package`. This always fails since neither
  library provides a CMake config file.

* If we address the above issue by instead using the MODULE mode of
  `find_package`, then we need to add `FindCbc.cmake` and
  `FindCpl.cmake` scripts to the CMAKE_MODULE_PATH in order to teach
  CMake how to find these dependencies. I propose that or-tools should
  install these scripts alongside its config file so that they're
  available to external CMake projects.

* Finally, the `FindCbc.cmake` script included with or-tools defines the
  variable `CBC_FOUND` when it's successful, rather than `Cbc_FOUND` as
  expected (CMake variables are case-sensitive). The `FindCpl.cmake`
  script has a similar issue. As a result, even when the above two
  points are addressed, `find_package(ortools CONFIG)` will still fail
  because CMake erroneously thinks that these two dependencies weren't
  succesfully found.

This commit attempts to address the above issues with the following
changes:

* The or-tools CMake config file is modified to allow searching for Cbc
  and Cpl using the MODULE mode of `find_package`.

* `FindCbc.cmake` and `FindCpl.cmake` are installed with the CMake
  package config files and are added to the CMAKE_MODULE_PATH if
  `USE_COINOR` was truthy.

* The `FindCbc.cmake` and `FindCpl.cmake` files are modified to change
  the case of variables they export.

* Only install FindXXX.cmake modules if COIN-OR support was enabled
2022-01-14 08:38:37 +01:00
Corentin Le Molgat
323df716f3 cmake: Make BUILD_LP_PARSER optional (OFF by default) 2021-11-22 17:17:43 +01:00
Corentin Le Molgat
cfa0eec941 Add lp_parser 2021-11-19 14:02:44 +01:00
Mizux Seiha
d0e7970c6b cmake: Added GLPK support and docs
* Use Mizux/GLPK (Tag 5.0)
* cmake: Fix swig flags
* cmake: Update ortoolsConfig.cmake
2021-11-17 14:04:57 +01:00
Mizux Seiha
5713958c45 cmake: Use PROJECT_NAMESPACE 2021-11-17 12:28:42 +01:00
Laurent Perron
f6fa781fa4 split ortools/data into ortools/scheduling and ortools/packing 2021-09-28 15:58:37 +02:00
Corentin Le Molgat
1be12af58f cmake: cleanup 2021-09-17 15:13:11 +02:00
Mizux Seiha
4a025e23c0 cmake: Add init 2021-03-21 16:19:12 +01:00
Mizux Seiha
eb01323f0f cmake: Fix build 2021-03-18 02:49:30 +01:00
Mizux Seiha
e4344ec7c9 cmake: Propagate use of PROTOC_PRG 2021-01-08 17:49:26 +01:00
Mizux Seiha
1108b8cb1c cmake: fix install in cpp.cmake 2020-11-16 11:16:08 +01:00
Mizux Seiha
9bf38e15d0 cmake: Fix cpp build 2020-11-09 14:04:49 +01:00
Mizux Seiha
660109cbae cmake: move dependencies check 2020-11-09 10:00:35 +01:00
Mizux Seiha
409ebffd3b Introduce OR_TOOLS_AS_DYNAMIC_LIB
should fix Makefile based build since is generate a static lib
so declspec(dllimport/dllexport) is not needed.
2020-10-24 00:50:59 +02:00
Mizux Seiha
93af69fb0f cmake: remove gflags and glog deps 2020-10-24 00:50:31 +02:00
Mizux Seiha
f57d9cc0a0 cmake: fix windows build 2020-10-19 23:02:01 +02:00
Mizux Seiha
53bf463517 cmake: Fix gscip 2020-10-19 11:27:02 +02:00
Mizux Seiha
18e00b36c4 cmake: cleanup 2020-10-19 10:38:52 +02:00
Laurent Perron
aeeb233f92 add statusor to cmake 2020-10-18 18:00:00 +02:00
Mizux Seiha
aa73e901b4 cmake: Refactor sample tests 2020-09-19 17:21:50 +02:00
Mizux Seiha
7d149a6530 cmake: examples management cleanup 2020-09-13 00:04:50 +02:00
Mizux Seiha
6f6025edb1 cmake: Try to fix external protobuf usage (#2128) 2020-08-19 23:08:01 +02:00
Mizux Seiha
f992206a9a Force use of C++17
Routing use c++17 features (e.g. structured binding)
ref: https://en.cppreference.com/w/cpp/language/structured_binding
2020-08-14 14:07:58 +02:00
Mizux Seiha
a8e830eef9 cmake: cleanup 2020-08-10 11:46:36 +02:00
Mizux Seiha
cc2fdb6e7a cmake: Fix USE_SCIP=OFF 2020-08-06 16:38:32 +02:00
Mizux Seiha
71d92bad4c cmake: Use CMP0091 to control runtime library on Windows 2020-07-31 17:55:19 +02:00
Mizux Seiha
4beaa8a320 cmake: add XPRESS_PATH compile definition 2020-07-31 14:18:15 +02:00
Mizux Seiha
3b7d00802e cmake: use of BUILD_EXAMPLES 2020-07-31 11:27:08 +02:00
Mizux Seiha
a1837ad6b7 cmake: link against absl::stacktrace
note: needed to build on freeBSD using clang.
2020-07-19 01:37:04 +02:00
Mizux Seiha
41a5d2674c cmake: remove unneeded install
All dependencies are built using FetchContent so we don't rely anymore
on configure time dependencies install...
2020-07-17 13:16:40 +02:00
Mizux Seiha
08d7a58ddd cmake: rewrite custom FetchContent
note: before cmake 3.18 FetchContent does not support
SOURCE_SUBDIR which is needed for protobuf
2020-07-17 13:16:22 +02:00
Mizux Seiha
86af6c5725 CMake: SCIP update 2020-07-03 16:17:27 +02:00
Mizux Seiha
1a1da66113 cmake: SCIP cleanup 2020-07-02 23:39:46 +02:00
Mizux Seiha
b7fb6d4209 Update CMake 2020-07-01 21:01:27 +02:00
Mizux Seiha
cc21b5b702 Fix CMake build 2020-06-26 01:01:42 +02:00
Corentin Le Molgat
91090ce34f Fix tab in cmake files 2020-05-27 17:13:48 +02:00
Mizux Seiha
edd6c3cc0e cmake: Change build output layout 2020-05-25 10:12:41 +02:00
Mizux Seiha
5168cb1d40 cmake(xcode): Fix compilation 2020-05-18 14:15:47 +02:00
Laurent Perron
1cfd653bb2 fix cmake 2020-05-07 11:32:13 +02:00