Fwd: Re: Question about CMAKE_MODULE_PATH

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Fwd: Re: Question about CMAKE_MODULE_PATH

Steven Truppe




-------- Forwarded Message --------
Subject: Re: [CMake] Question about CMAKE_MODULE_PATH
Date: Mon, 18 Feb 2019 16:58:26 +0100
From: [hidden email] [hidden email]
To: Kyle Edwards [hidden email]


here is my code:


set(MODULE_PATH "compile/tools/cmake/modules")

LIST(APPEND CMAKE_MODULE_PATH ${MODULE_PATH})

now i try to include with

INCLUDE(basic_tests)

and i get an error that the file can't be found when typing cmake ../ from within my build path.



On 18.02.19 16:54, Kyle Edwards wrote:
On Mon, 2019-02-18 at 16:50 +0100, [hidden email] wrote:
Doesn't the content of CMAKE_MODULE_PATH should also include the path
to
the default modules ??
The default modules are automatically checked by CMake, independently
of the contents of CMAKE_MODULE_PATH. They should not normally be
present in CMAKE_MODULE_PATH.

i try to load custom modules. i use


list(append CMAKE_MODULE_PATH "/mypathtomdoules")
The "append" argument should be uppercase:

list(APPEND CMAKE_MODULE_PATH "/mypathtomodules")

Did you receive any warnings about an invalid argument to list()?

Kyle


--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Re: Question about CMAKE_MODULE_PATH

CMake mailing list
On Mon, 2019-02-18 at 17:04 +0100, [hidden email] wrote:




-------- Forwarded Message --------
Subject: Re: [CMake] Question about CMAKE_MODULE_PATH
Date: Mon, 18 Feb 2019 16:58:26 +0100
From: [hidden email] [hidden email]
To: Kyle Edwards [hidden email]


here is my code:


set(MODULE_PATH "compile/tools/cmake/modules")

Try this instead:

set(MODULE_PATH "${CMAKE_SOURCE_DIR}/compile/tools/cmake/modules")

Kyle

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Re: Question about CMAKE_MODULE_PATH

Steven Truppe
In reply to this post by Steven Truppe

Thank you, that did the trick. Now my other question is there a function in cmake that does abort the build/makefile generation process ? for example if i find out the system is not 64bit - is there something like quit() ?

On 18.02.19 17:04, [hidden email] wrote:




-------- Forwarded Message --------
Subject: Re: [CMake] Question about CMAKE_MODULE_PATH
Date: Mon, 18 Feb 2019 16:58:26 +0100
From: [hidden email] [hidden email]
To: Kyle Edwards [hidden email]


here is my code:


set(MODULE_PATH "compile/tools/cmake/modules")

LIST(APPEND CMAKE_MODULE_PATH ${MODULE_PATH})

now i try to include with

INCLUDE(basic_tests)

and i get an error that the file can't be found when typing cmake ../ from within my build path.



On 18.02.19 16:54, Kyle Edwards wrote:
On Mon, 2019-02-18 at 16:50 +0100, [hidden email] wrote:
Doesn't the content of CMAKE_MODULE_PATH should also include the path
to
the default modules ??
The default modules are automatically checked by CMake, independently
of the contents of CMAKE_MODULE_PATH. They should not normally be
present in CMAKE_MODULE_PATH.

i try to load custom modules. i use


list(append CMAKE_MODULE_PATH "/mypathtomdoules")
The "append" argument should be uppercase:

list(APPEND CMAKE_MODULE_PATH "/mypathtomodules")

Did you receive any warnings about an invalid argument to list()?

Kyle



--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Re: Question about CMAKE_MODULE_PATH

Gonzalo Garramuño
El 18/2/19 a las 13:15, [hidden email] escribió:

> Thank you, that did the trick. Now my other question is there a
> function in cmake that does abort the build/makefile generation
> process ? for example if i find out the system is not 64bit - is there
> something like quit() ?
>
>
message( FATAL_ERROR "your quit message" )

--
Gonzalo Garramuño

--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: Re: Question about CMAKE_MODULE_PATH

Steven Truppe
Thanks alot!

On 18.02.19 17:20, Gonzalo Garramuño wrote:

> El 18/2/19 a las 13:15, [hidden email] escribió:
>
>> Thank you, that did the trick. Now my other question is there a
>> function in cmake that does abort the build/makefile generation
>> process ? for example if i find out the system is not 64bit - is
>> there something like quit() ?
>>
>>
> message( FATAL_ERROR "your quit message" )
>
--

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
https://cmake.org/mailman/listinfo/cmake