[CMake] ExternalProject + PREFIX + CPACK - cannot get the good path
Eric Noulard
eric.noulard at gmail.com
Tue Jul 18 10:23:00 EDT 2017
>
>
>> Which makes me think, if you primary goal is to package an external
>> project, wouldn't it be simpler to add support for a "PACKAGE" step to
>> ExternalProject ? Or is this external project meant to be packaged in the
>> same package as the project using it?
>>
>
> I cannot add a package step as the external project do not support
> packaging, it is only a configure / make / make install project. That is
> why I use CPack.
> But I package it as a separate package.
>
Yep I understand that.
My suggestion was precisely to **add** a package step to ExternalProject
unless it doesn't make sense for ExternalProject_Add
May be you can do that with ExternalProject_Add_Step in your own
CMakeLists.txt ?
Something like (untested):
ExternalProject_Add_Step(sqlcipher package
COMMAND "cpack"
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMENT "Package with cpack"
DEPENDEES "install"
)
I don't know much about ExternalProject internals so I may be wrong.
Anyway, the DESTDIR=/tmp make package does the trick for me but I still can
> implement an integrated solution if it is useful for others ?
>
As I said this trick is only a way to throw away (in /tmp) the default
install command which is called by
make (or make package) as the part of the install step
of ExternalProject_Add.
--
Eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20170718/a285d3e0/attachment.html>
More information about the CMake
mailing list