[CMake] CPack: Ignoring files using regex

Chris Wood c.c.wood at gmail.com
Mon Jul 29 14:40:53 EDT 2013


I'm trying to get my head round CMake's regex implementation; I have a
folder containing 4 folder and 2 text files:

build/
projectA/
CMakeLists.txt
extrafiles/
README
temp/

one line of CMakeLists.txt is:

set(CPACK_SOURCE_IGNORE_FILES "[^projectA]$")

in my source package that is ten subsequently generated, `build/`
`projectA/` and `extrafiles` are present, but `temp/` and the 2 text
files are not. I'm trying to get to a stage where the regex will
ignore everything in the folder except for `projectA/`, `README` and
`CMakeLists.txt`, but can't work out at the moment how the regex I've
supplied is giving those results.

Any insight will be greatly appreciated!

Chris


More information about the CMake mailing list