[CMake] Patch utility is installed, but my ExternalProject build step fails to execute it

Rolf Eike Beer eike at sf-mail.de
Mon Feb 25 03:37:14 EST 2013


David Brown wrote:
> I'm trying to patch and build a Makefile-based project using the
> ExternalProject module. My patch command looks like this:
> 
>     PATCH_COMMAND "patch -p1 -t -N <
> ${CMAKE_CURRENT_SOURCE_DIR}/IntelDFP.patch"
> 
> When building, however, I get this:
> 
>     [ 10%] Performing patch step for 'IntelDFP'
>     /bin/sh: 1: patch -p1 -t -N <
> /home/david/Projects/db/IntelDFP.patch: not found
> 
> I'm certain that the patch utility is installed and that the patch
> file path is correct. If I run that command myself, it works fine. So
> why does the CMake-generated Makefile fail to execute it?

If it is GNU patch I suggest you use -i instead of piping, this has the chance 
to work without a shell being available.

Eike
-- 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130225/3c2c1aa5/attachment.pgp>


More information about the CMake mailing list