From: Luis Lavena Date: 2012-07-14T03:51:21+09:00 Subject: Re: [RubyInstaller] Re: The Ruby greener test challenge (a Windows challenge) On Fri, Jul 13, 2012 at 2:37 PM, Oleg Sukhodolsky wrote: > Hi, > > I have tried to build ruby with the package and build fails rather early > with the following error: > > configure: creating ./config.status > config.status: creating GNUmakefile > config.status: creating Makefile > config.status: creating ruby-2.0.pc > ---> Compiling > CC = gcc > LD = ld > LDSHARED = gcc -shared -s > CFLAGS = -O3 -fno-omit-frame-pointer -fno-fast-math -g -Wall -Wextra > -Wno-unused-parameter -Wno-parentheses -Wno > -long-long -Wno-missing-field-initializers -Wunused-variable > -Werror=pointer-arith -Werror=write-strings -Werror=declara > tion-after-statement -Werror=implicit-function-declaration > XCFLAGS = -include ruby/config.h -include ruby/missing.h > -D_FORTIFY_SOURCE=2 -fno-strict-overflow -fvisibility=h > idden -DRUBY_EXPORT > CPPFLAGS = -DFD_SETSIZE=32767 -D_WIN32_WINNT=0x0501 -I. > -I.ext/include/i386-mingw32 -I./include -I. > DLDFLAGS = -Wl,--enable-auto-image-base,--enable-auto-import > -Wl,--out-implib=libmsvcrt-ruby200.dll.a msvcrt-rub > y200.def -Wl,--stack,0x00200000,--enable-auto-import > SOLIBS = msvcrt-ruby200.res.o -lshell32 -lws2_32 -limagehlp > compiling main.c > In file included from :0:0: > .ext/include/i386-mingw32/ruby/config.h:127:9: error: macro names must be > identifiers > .ext/include/i386-mingw32/ruby/config.h:129:9: error: macro names must be > identifiers > .ext/include/i386-mingw32/ruby/config.h:131:9: error: macro names must be > identifiers > .ext/include/i386-mingw32/ruby/config.h:133:9: error: macro names must be > identifiers Hello, I believe I mentioned this error before: https://groups.google.com/d/msg/rubyinstaller/A92K_EYJX2A/AufN8RzlGAYJ > > 131 line of the problematic file is: > | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 > > This doesn't looks like a good macro ;) > > Is this a known problem? How I can workaround it? > See link provided above, I got no answer from poster, so will be great get your feedback :) > I use Windows7 64bits, ruby's revision is > d57103b9a2a62a67eb09fc9fb7c2828b53d1a590 > I tested that version last night, and it worked. Can you tell me if other looks like FRAPPS, ANSICON, existing MinGW/Cygwin/MSYS installations around that could be affecting? What "gcc --version" says after you open the command prompt shortcut? Can gcc compile a simple program, like hello world? hello.c: #include int main(void) { puts("Hello world"); return 0; } And compile with "gcc hello.c -o hello.exe" That should work, and if not, then try with "-v" option so we get debug output. Please use pastie.org or gist.github.com if the output you provide is long so we keep readability :) Thank you. -- Luis Lavena AREA 17 - Perfection in design is achieved not when there is nothing more to add, but rather when there is nothing more to take away. Antoine de Saint-Exupéry