Loading ...
Sorry, an error occurred while loading the content.
 

Re: vim7 configure check for tcl

Expand Messages
  • Bram Moolenaar
    ... Yes, if that is so then the other backslashes also need to be doubled. To be prepared for other arguments in the future it should be changed to also put
    Message 1 of 4 , Dec 4, 2005
      > | Ciaran McCreesh wrote:
      > | > The vim7 configure check for tcl seems to need more backslashes to
      > | > avoid dumping bogus extra parts of TCL_DEFS into CFLAGS. I think the
      > | > attached patch should do it.
      > | >
      > | > Further details of the errors and a tclConfig.sh that triggers this
      > | > can be found at https://bugs.gentoo.org/show_bug.cgi?id=113823 .
      > |
      > | Can you explain why there need to be four backslashes to match with
      > | one? There are two to match one backslash, that's the normal way to
      > | use a pattern.
      >
      > We're trying to match a backslash followed by a space, which ordinarily
      > would use '\\ '. However, we're inside `` quotes, so backslashes need
      > to be doubled up.

      Yes, if that is so then the other backslashes also need to be doubled.

      To be prepared for other arguments in the future it should be changed
      to also put back the escaped white space afterwards:

      TCL_DEFS=`echo $TCL_DEFS | sed -e 's/\\\\ /\\\\X/g' | tr ' ' '\012' | sed -e '/^-[^D]/d' -e '/-D[^_]/d' -e 's/-D_/ -D_/' | tr '\012' ' ' | sed -e 's/\\\\X/\\\\ /g'`

      I also added a "g" flag to replace more than one "\ " by "\X".

      --
      FATHER: Make sure the Prince doesn't leave this room until I come and
      get him.
      FIRST GUARD: Not ... to leave the room ... even if you come and get him.
      FATHER: No. Until I come and get him.
      SECOND GUARD: Hic.
      "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD

      /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
      /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
      \\\ download, build and distribute -- http://www.A-A-P.org ///
      \\\ help me help AIDS victims -- http://www.ICCF.nl ///
    Your message has been successfully submitted and would be delivered to recipients shortly.