I filed a bug about this
(http://public.kitware.com/Bug/view.php?id=7757), and Bill told me
about CMAKE_CURRENT_LIST_FILE.
CMAKE_CURRENT_LIST_FILE
Full path to the listfile currently being processed.
As CMake processes the listfiles in your project this
That's what I tried first, however CMAKE_CURRENT_SOURCE_DIR points to
where you called FIND_PACKAGE from and not from where the
FindMyPackage.cmake lives.
James
On Mon, Sep 29, 2008 at 5:03 PM, Michael Jackson
[EMAIL PROTECTED] wrote:
include(${CMAKE_CURRENT_SOURCE_DIR}/extrastuff.cmake)
Just
Sure, but how can I do this from within FindMyPackage.cmake?
Doing find_file(FindMyPackage.cmake PATHS ${CMAKE_MODULE_PATH}) seems
less robust than having a true mechanism to discover the path of a
file no matter where it was included from.
James
On Tue, Sep 30, 2008 at 7:24 AM, Michael Jackson
James Bigler wrote:
Sure, but how can I do this from within FindMyPackage.cmake?
Leave off the .cmake.
include(extrastuff)
should work if CMAKE_MODULE_PATH is set correctly.
-Bill
___
CMake mailing list
CMake@cmake.org
include(${CMAKE_CURRENT_SOURCE_DIR}/extrastuff.cmake)
Just guessing but it seems like it should work..
Mike
On Sep 29, 2008, at 6:30 PM, James Bigler wrote:
Is it possible to include a file that is local to a module?
I want to do this:
FIND_PACKAGE(MyPackage)
MyPackage.cmake: