Re: Bad QUOTESED expression in src/Makefile

2006-09-01 Thread Alexey I. Froloff
* Alexey I. Froloff raorn@ [060831 01:27]:
 I think QUOTESED should look like:

 QUOTESED = sed -e 's/[\\]/\\/g' -e 's/\\//' -e 's/\\;$$/;/'

Patch attached.

-- 
Regards,
Sir Raorn.
diff -cdrN ../vim70-orig/src/Makefile src/Makefile
*** ../vim70-orig/src/Makefile  Fri Sep  1 17:18:36 2006
--- src/MakefileFri Sep  1 17:34:02 2006
***
*** 2206,2212 
  auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in
CC=$(CC) $(OSDEF_CFLAGS) srcdir=$(srcdir) sh $(srcdir)/osdef.sh
  
! QUOTESED = sed -e 's//\\/g' -e 's/\\//' -e 's/\\;$$/;/'
  auto/pathdef.c: Makefile auto/config.mk
[EMAIL PROTECTED] creating $@
[EMAIL PROTECTED] '/* pathdef.c */'  $@
--- 2206,2212 
  auto/osdef.h: auto/config.h osdef.sh osdef1.h.in osdef2.h.in
CC=$(CC) $(OSDEF_CFLAGS) srcdir=$(srcdir) sh $(srcdir)/osdef.sh
  
! QUOTESED = sed -e 's/[\\]/\\/g' -e 's/\\//' -e 's/\\;$$/;/'
  auto/pathdef.c: Makefile auto/config.mk
[EMAIL PROTECTED] creating $@
[EMAIL PROTECTED] '/* pathdef.c */'  $@


signature.asc
Description: Digital signature


Re: Bad QUOTESED expression in src/Makefile

2006-09-01 Thread Bram Moolenaar

Alexey Froloff wrote:

 There is QUOTESED expression for creating auto/pathdef.c:
 
 QUOTESED = sed -e 's//\\/g' -e 's/\\//' -e 's/\\;$$/;/'
 ...
   @echo 'char_u *default_vim_dir = (char_u *)$(VIMRCLOC);' | $(QUOTESED)  
 $@
 
 However:
 
 gcc -c -I. -Iproto -DHAVE_CONFIG_H -pipe -Wall -O2 -march=pentium4 
 -DSYS_VIMRC_FILE=\/etc/vim/vimrc\ -DSYS_GVIMRC_FILE=\/etc/vim/gvimrc\ 
 -o objects/pathdef.o auto/pathdef.c
 auto/pathdef.c:7: error: 'etc' undeclared here (not in a function)
 auto/pathdef.c:7: error: 'vim' undeclared here (not in a function)
 auto/pathdef.c:7: error: stray '\' in program
 auto/pathdef.c:7: error: stray '\' in program
 auto/pathdef.c:7: error: 'vimrc' undeclared here (not in a function)
 auto/pathdef.c:7: error: expected ',' or ';' before string constant
 auto/pathdef.c:7: error: stray '\' in program
 auto/pathdef.c:7: error: stray '\' in program
 
 $ grep all_cflags auto/pathdef.c
 char_u *all_cflags = (char_u *)gcc -c -I. -Iproto -DHAVE_CONFIG_H -pipe 
 -Wall -O2 -march=pentium4 -DSYS_VIMRC_FILE=\\/etc/vim/vimrc\\ 
 -DSYS_GVIMRC_FILE=\\/etc/vim/gvimrc\\  
 
 I think QUOTESED should look like:
 
 QUOTESED = sed -e 's/[\\]/\\/g' -e 's/\\//' -e 's/\\;$$/;/'

That looks like a good solution.

-- 
   They now pass three KNIGHTS impaled to a tree.  With their feet off the
   ground,  with one lance through the lot of them, they are skewered up
   like a barbecue.
 Monty Python and the Holy Grail PYTHON (MONTY) PICTURES LTD

 /// Bram Moolenaar -- [EMAIL PROTECTED] -- 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://ICCF-Holland.org///


Re: Bad QUOTESED expression in src/Makefile

2006-08-31 Thread A.J.Mechelynck

Alexey I. Froloff wrote:

* A.J.Mechelynck antoine.mechelynck@ [060831 02:48]:
Hmmm... it seems you configured a nonstandard location for your system 
vimrc and gvimrc.

I have CFLAGS with escaped quotes.  Backslashes should be escaped
too.

; compiling pathdef.c gives me no errors or warnings whatsoever. How did 
you configure yours?

CFLAGS=-DSYS_VIMRC_FILE=\/etc/vim/vimrc\ 
-DSYS_GVIMRC_FILE=\/etc/vim/gvimrc\



Try removing that line (undefining $CFLAGS), running make reconfig and 
making soft links, as follows:


cd /usr/local/vim
ln -sv /etc/vimrc /etc/gvimrc .

(don't forget the dot at the end). The -v (verbose) is optional; the -s 
is required to make a soft link. This way, when gvim looks for the 
system vimrc and gvimrc in $VIM, it will find your /etc/vimrc and 
/etc/gvimrc.



I see a configure argument --prefix, but I guess that's not what you 
want. The above assumes that you aren't using it, but the principle is 
the same if you are.



Best regards,
Tony.


Bad QUOTESED expression in src/Makefile

2006-08-30 Thread Alexey I. Froloff
There is QUOTESED expression for creating auto/pathdef.c:

QUOTESED = sed -e 's//\\/g' -e 's/\\//' -e 's/\\;$$/;/'
...
  @echo 'char_u *default_vim_dir = (char_u *)$(VIMRCLOC);' | $(QUOTESED)  $@

However:

gcc -c -I. -Iproto -DHAVE_CONFIG_H -pipe -Wall -O2 -march=pentium4 
-DSYS_VIMRC_FILE=\/etc/vim/vimrc\ -DSYS_GVIMRC_FILE=\/etc/vim/gvimrc\   
  -o objects/pathdef.o auto/pathdef.c
auto/pathdef.c:7: error: 'etc' undeclared here (not in a function)
auto/pathdef.c:7: error: 'vim' undeclared here (not in a function)
auto/pathdef.c:7: error: stray '\' in program
auto/pathdef.c:7: error: stray '\' in program
auto/pathdef.c:7: error: 'vimrc' undeclared here (not in a function)
auto/pathdef.c:7: error: expected ',' or ';' before string constant
auto/pathdef.c:7: error: stray '\' in program
auto/pathdef.c:7: error: stray '\' in program

$ grep all_cflags auto/pathdef.c
char_u *all_cflags = (char_u *)gcc -c -I. -Iproto -DHAVE_CONFIG_H -pipe 
-Wall -O2 -march=pentium4 -DSYS_VIMRC_FILE=\\/etc/vim/vimrc\\ 
-DSYS_GVIMRC_FILE=\\/etc/vim/gvimrc\\  

I think QUOTESED should look like:

QUOTESED = sed -e 's/[\\]/\\/g' -e 's/\\//' -e 's/\\;$$/;/'

-- 
Regards,
Sir Raorn.


signature.asc
Description: Digital signature


Re: Bad QUOTESED expression in src/Makefile

2006-08-30 Thread Alexey I. Froloff
* A.J.Mechelynck antoine.mechelynck@ [060831 02:48]:
 Hmmm... it seems you configured a nonstandard location for your system 
 vimrc and gvimrc.
I have CFLAGS with escaped quotes.  Backslashes should be escaped
too.

 ; compiling pathdef.c gives me no errors or warnings whatsoever. How did 
 you configure yours?
CFLAGS=-DSYS_VIMRC_FILE=\/etc/vim/vimrc\ 
-DSYS_GVIMRC_FILE=\/etc/vim/gvimrc\

-- 
Regards,
Sir Raorn.


signature.asc
Description: Digital signature