These are chat archives for symengine/symengine

Apr 2018
Björn Dahlgren
Apr 27 2018 14:37

I'm working on using CMake in a project of mine which relies on symengine, I noticed that the order in which I call find_package matters: symengine modifies CMAKE_MODULE_PATH:
this works:

message(STATUS "cmake_module_path = ${CMAKE_MODULE_PATH}")

find_package(SymEngine 0.3.0 REQUIRED CONFIG)

with the output:

-- cmake_module_path = /path/to/myproject/cmake

Whereas if I reorder to call find_package on SymEngine first, the second step fails and the output is:

-- cmake_module_path = /opt/symengine-262478e/lib/cmake/symengine

I guess SymEngine's cmake scripts should either append to CMAKE_MODULE_PATH or keep a private(?) copy(?) of the variable? (sorry I'm still quite new to CMake so I might be doing something completely wrong here...)

(the problem that arises is that my FindSUNDIALS.cmake is not detected in the latter case)
Isuru Fernando
Apr 27 2018 15:12
@bjodah, that's a bug. Lines 51 and 58 in should be removed