johnmcfarlane / cnl

A Compositional Numeric Library for C++
Boost Software License 1.0
633 stars 63 forks source link

Replace CMAKE_TOOLCHAIN_FILE with CMAKE_PROJECT_INCLUDE_BEFORE #990

Open johnmcfarlane opened 2 years ago

johnmcfarlane commented 2 years ago

Hypothesis: CMake toolchain files are not the right place to customise the build; they are for configuring toolchains only. There are other, more appropriate ways to vary builds in the way that the workflows require.

Test this hypothesis by replacing the toolchain files with something more suitable. Setting one of the PROJECT_INCLUDE variables seems like one possible avenue of exploration.

Acceptance criteria: the end result is that the pipeline runs as it does currently, but with little or no reliance on CMake toolchain files.

phyBrackets commented 2 years ago

you mean CONAN_CMAKE_TOOLCHAIN_FILE to CONAN_CMAKE_PROJECT_INCLUDE_BEFORE right?

johnmcfarlane commented 2 years ago

For CMake variables which are environment variables, I tend to pass them in via Conan profiles in the [env] section, but I'm not fussy - whatever works!

On Mon 17 Jan 2022, 10:50 Shivam, @.***> wrote:

you mean CONAN_CMAKE_TOOLCHAIN_FILE to CONAN_CMAKE_PROJECT_INCLUDE_BEFORE right?

— Reply to this email directly, view it on GitHub https://github.com/johnmcfarlane/cnl/issues/990#issuecomment-1014384813, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAFTGNYZY4UAH4JK7WU3RY3UWPX7RANCNFSM5K7RP2YQ . You are receiving this because you authored the thread.Message ID: @.***>

phyBrackets commented 2 years ago

So , if i tried to make these specific changes , then how can i test that they work fine ? before commit the changes.

johnmcfarlane commented 2 years ago

@phyBrackets description updated