Bram Moolenaar wrote: > Vlad Sandrini wrote: > >> It has to do with the recent ruby changes, because "make" complained >> about an extra "else" in row 218. >> >> I am very clumsy with diff, and I don't have ruby to say the truth, >> but this trick below made me able to compile. >> >> diff -NrU3 ../before\vim72\src\Make_ming.mak .\vim72\src\Make_ming.mak >> --- ../before\vim72\src\Make_ming.mak Thu Mar 11 10:46:19 2010 >> +++ .\vim72\src\Make_ming.mak Thu Mar 11 10:33:17 2010 >> @@ -215,10 +215,12 @@ >> ifndef RUBY_PLATFORM >> ifeq ($(RUBY_VER), 16) >> RUBY_PLATFORM = i586-mswin32 >> -else ifneq ("X$(wildcard, $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386- >> mingw32)", X) >> +else >> +ifneq ("X$(wildcard, $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386- >> mingw32)", X) >> RUBY_PLATFORM = i386-mingw32 >> else >> RUBY_PLATFORM = i386-mswin32 >> +endif >> endif >> endif
At line 218... ifneq ("X$(wildcard, $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32)", X) Why is there a comma just after wildcard? That's looks wrong. Shouldn't that be: ifneq ("X$(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32)", X) Also, the trick with the X is not necessary. This should work: ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32),) But the comma after wildcard was there before the patch so I suspect that the syntax error has to do with the "else ifneq" construct which may not be accepted by all versions of make. (it's fine with GNU-make-3.81 at least). Line 218 (where it complains) is in fact the only place where a "else if" is used in Vim's Makefiles: $ cd vim/src ; grep -n 'else if' Make* Make_ming.mak:218:else ifneq ("X$(wildcard, $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32)", X) To be more conservative, we can replace the... if ... RUBY_VER = .. else if ... RUBY_VER = ... else RUBY_VER =... endif ... with the slightly longer: if ... RUBY_VER = ... else if ... RUBY_VER = ... else RUBY_VER = ... endif endif Attached patch "Make_ming.mak.patch" does that. -- Dominique -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php
diff -r aab202d244b6 src/Make_ming.mak --- a/src/Make_ming.mak Wed Mar 10 17:16:12 2010 +0100 +++ b/src/Make_ming.mak Fri Mar 12 05:03:04 2010 +0100 @@ -215,12 +215,14 @@ ifndef RUBY_PLATFORM ifeq ($(RUBY_VER), 16) RUBY_PLATFORM = i586-mswin32 -else ifneq ("X$(wildcard, $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32)", X) +else +ifneq ($(wildcard $(RUBY)/lib/ruby/$(RUBY_VER_LONG)/i386-mingw32),) RUBY_PLATFORM = i386-mingw32 else RUBY_PLATFORM = i386-mswin32 endif endif +endif ifndef RUBY_INSTALL_NAME ifeq ($(RUBY_VER), 16)