On 7/22/07, Mathieu Malaterre <[EMAIL PROTECTED]> wrote:
Hi Brandon,

  I think you can use this trick to work around your issue:

http://www.cmake.org/pipermail/cmake/2007-May/014317.html

  STRING(REGEX REPLACE "\r?\n" ";" ENT "${input}")
  FOREACH(line ${ENT})
  # do the match on each line

Thanks for the cross-platform \r\n CR+LF hint.  Last night I tried to
match \n, but it didn't seem to be working.  Actually it was matching
fine, but my output only had \n in it, and a Windows shell needs CR+LF
to go down a line.

Injecting semicolons is really dangerous though.  What if your file
already has semicolons?  In my code, FILE(...) followed by
STRING(REGEX ...) is destroying the semicolons in the file.  I need to
get to the bottom of that.


Cheers,
Brandon Van Every
_______________________________________________
CMake mailing list
CMake@cmake.org
http://www.cmake.org/mailman/listinfo/cmake

Reply via email to