The following issue has been SUBMITTED. 
====================================================================== 
http://www.cmake.org/Bug/view.php?id=15244 
====================================================================== 
Reported By:                Daniele E. Domenichelli
Assigned To:                
====================================================================== 
Project:                    CMake
Issue ID:                   15244
Category:                   CMake
Reproducibility:            N/A
Severity:                   feature
Priority:                   low
Status:                     new
====================================================================== 
Date Submitted:             2014-11-11 19:21 EST
Last Modified:              2014-11-11 19:21 EST
====================================================================== 
Summary:                    Add "cmake -E patch" command line option and
"file(PATCH)" command
Description: 
The ExternalProject module accepts a "PATCH_COMMAND" argument to apply a patch
to a project. In another scenario, one would like be to able to apply a patch to
a downloaded file. Unfortunately neither of these goal can be achieved easily in
a portable way.

- The "patch" command is usually not available on windows.
- "git apply", "hg import", etc work on every platform, but only work for git,
mercurial repositories, etc. and don't work for downloaded archives and files.


It would be nice to have a command line option like "cmake -E patch" to apply a
patch, that accepts the most commonly used options of the "patch" command (at
least -p, -l, -R, and -i). This would ensure that the "PATCH_COMMAND" will work
on every platform.


The "file" command could have a new PATCH argument that accepts(at least) an
input file, the working directory, a STRIP argument (-p1), an IGNORE_WHITESPACE,
and a REVERSE option. The signature could be something like this:
   file(PATCH filename working_dir
        [STRIP levels]
        [IGNORE_WHITESPACE]
        [REVERSE])
This could be used to patch a file after downloading it with "file(DOWNLOAD)"
====================================================================== 

Issue History 
Date Modified    Username       Field                    Change               
====================================================================== 
2014-11-11 19:21 Daniele E. DomenichelliNew Issue                               
    
======================================================================

-- 

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:
http://public.kitware.com/mailman/listinfo/cmake-developers

Reply via email to