> checking for gcc... gcc
> checking whether the C compiler works... no
> configure: error: in `/d/Multimedia/Builds/rubyinstaller/sandbox/src-
> libffi/i686
> -pc-mingw32':
> configure: error: C compiler cannot create executables
> See `config.log' for more details
> rake aborted!
> Command failed with status (77): [sh -c "./configure --enable-static --
> disab...]
>
> [...]
> Is the git repository's version of rubyinstaller broken, or am I doing
> something wrong?
Well, the error seems clear to me, for some reason libffi can't be
compiled with that compiler and will require some checking.
Can you attempt to build libffi outside RubyInstaller to determine if
the issue is that?
--
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
Interesting, I get a failure but a different failure signature when I try
rake ffi dkver=mingw64-32-4.5.4
...
Temporarily enhancing PATH to include DevKit...
cd sandbox/src-libffi
sh -c "./configure --enable-static --disable-shared --prefix=C:/projects/rubyinstaller-git/sandbox/libffi"
checking build system type... i686-pc-mingw32
checking host system type... i686-pc-mingw32
checking target system type... i686-pc-mingw32
continue configure in default builddir "./i686-pc-mingw32"
....exec /bin/sh .././configure "--srcdir=.." "--enable-builddir=i686-pc-mingw32" "mingw32"
checking build system type... i686-pc-mingw32
checking host system type... i686-pc-mingw32
checking target system type... i686-pc-mingw32
checking for gsed... sed
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking for gcc... i686-w64-mingw32-gcc
checking whether the C compiler works... no
configure: error: in `/c/projects/rubyinstaller-git/sandbox/src-libffi/i686-pc-mingw32':
configure: error: C compiler cannot create executables
See `config.log' for more details
rake aborted!
Command failed with status (77): [sh -c "./configure --enable-static --disab...]
Tasks: TOP => ffi => dependencies:ffi:configure => C:/projects/rubyinstaller-git/sandbox/.checkpoints/.ffi-configure
...and my `config.log` looks like http://pastie.org/2762264 and briefly glancing over the first configure failure it appears to be library search path related as the compile test can't find important libs like `-lmsvcrt` and `-lkernel32`
Jon
---
blog: http://jonforums.github.com/
twitter: @jonforums
Most people die of a sort of creeping common sense, and discover when it
is too late that the only things one never regrets are one's mistakes.
- Oscar Wilde
Luis is right. There's something about our RubyInstaller + DevKit build environment that's causing the problem.
I'm able to build the same simple program via CMD.EXE after putting a `mingw64-32-4.5.4` DevKit on PATH. However, when I try to build using the following, I get the same configure test failure we both see.
*** FAILING SCENARIO ***
C:\projects\rubyinstaller-git>rake devkit:sh dkver=mingw64-32-4.5.4
mkdir -p C:/projects/rubyinstaller-git/sandbox/.checkpoints
...
Temporarily enhancing PATH to include DevKit...
sh-3.1$ cd /C/Users/Jon/Documents/CDev/sandbox/
sh-3.1$ cat conftest.c
int main()
{
;
return 0;
}
sh-3.1$ gcc --version
gcc.exe (GCC) 4.5.4 20110812 (prerelease)
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
sh-3.1$ gcc -o conftest.exe conftest.c
C:\projects\rubyinstaller-git\sandbox\devkit\mingw\bin/i686-w64-mingw32-ld.exe: cannot find crt2.o: No such file or directory
...
C:\projects\rubyinstaller-git\sandbox\devkit\mingw\bin/i686-w64-mingw32-ld.exe: cannot find -lmsvcrt
collect2: ld returned 1 exit status
*** PASSING SCENARIO ***
C:\Users\Jon\Documents\CDev\sandbox>\DevKit-w64\devkitvars.bat
Adding the DevKit to PATH...
C:\Users\Jon\Documents\CDev\sandbox>echo %PATH%
C:\DevKit-w64\bin;C:\DevKit-w64\mingw\bin;C:\Program Files\Gimp-2.7.4\bin;
...
C:\Users\Jon\Documents\CDev\sandbox>gcc --version
gcc (GCC) 4.5.4 20110812 (prerelease)
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
C:\Users\Jon\Documents\CDev\sandbox>type conftest.c
int main()
{
;
return 0;
}
C:\Users\Jon\Documents\CDev\sandbox>gcc -o conftest.exe conftest.c
I'm not sure if it got a bug report or is similar to https://github.com/oneclick/rubyinstaller/issues/76
Need a bit more info on what you're trying to do and your system. If you're trying to build for a 64bit Windows system you'll want to use the 64bit DevKit similar to
rake ruby19 dkver=tdm-64-4.6.1
and you can build a standalone 64bit DevKit like:
rake devkit dkver=tdm-64-4.6.1 sfx=1
and look in the pkg/ subdirectory. Note that this is *not* a mingw-w64 based 64bit DevKit, but it should work for you.
If you're trying to build for 32bit, the 32bit mingw-w64 DevKit's haven't got a lot of attention as of late. Let me know if you're interested in 32bit via mingw-w64 and I'll take a look into when I get a spare moment.
> Also I found Jon's post on building rubinius<http://jonforums.github.com/ruby/2011/07/17/building-rubinius-on-windows-1.html> and
> tried doing it.
> I'm guessing that along the way instead of running *deprefix.rb*
> you guys just something else.
>
> But if I do run *deprefix.rb* I get a linking error or something
> while trying to test the C compiler:
> *collect2: cannot find 'ld'*
> *
> *
> That's really isn't a big deal though from the way it looks
> like you guys set the folder up, but I thought I would post
> it incase it is relevant.
> *
> *
> If there isn't a bug report lemme know and I'll create one.
> *
> *
> *
> *
Please try a cmd.exe command prompt instead of power shell.
Also ensure gcc can compile a simple hello world example.
Sorry for top posting. Sent from mobile.
--
You received this message because you are subscribed to the Google Groups "RubyInstaller" group.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyinstaller/-/iSVgBH7dCuwJ.
To post to this group, send email to rubyin...@googlegroups.com.
To unsubscribe from this group, send email to rubyinstalle...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyinstaller?hl=en.
See troubleshooting Page about similar issue. Will try tdm-64 as soon get back to my desk.
Sorry for top posting. Sent from mobile.
--
You received this message because you are subscribed to the Google Groups "RubyInstaller" group.
To view this discussion on the web visit https://groups.google.com/d/msg/rubyinstaller/-/uVSujvUr9PcJ.
Uh-oh...I'm going to check an old mingw-w64 DevKit build I have as we may have oops'd the build recipe...more in a bit.
Here's what I get from a freshly built mingw-w64 DevKit
C:\Users\Jon\Documents\CDev\sandbox>type helloworld.c
#include <stdio.h>
int main(int argc, char *argv[]) { printf("Hello World!\n");return 0; }
C:\Users\Jon\Documents\CDev\sandbox>\DevKit-w64\devkitvars.bat
Adding the DevKit to PATH...
C:\Users\Jon\Documents\CDev\sandbox>echo %PATH%
C:\DevKit-w64\bin;C:\DevKit-w64\mingw\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem
C:\Users\Jon\Documents\CDev\sandbox>gcc --version
gcc (GCC) 4.5.4 20110812 (prerelease)
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
C:\Users\Jon\Documents\CDev\sandbox>gcc -Wall -o hw.exe helloworld.c
helloworld.c:1:19: fatal error: stdio.h: No such file or directory
compilation terminated.
Also, unless the Rubinius folks have fixed things, once you get a working DevKit you're likely looking at this https://github.com/rubinius/rubinius/issues/1164 issue.
I also recall that the vm on Windows was ~187MB while on OSX it was ~18MB.
Jon
---
Fail fast. Fail often. Fail publicly. Learn. Adapt. Repeat.
http://thecodeshop.github.com | http://jonforums.github.com/
twitter: @jonforums
That's not it...my build from 10/26/2011 fails the same way. Since you're trying to build Rubinius, this is going to be a problem.
Will try to find time to look into tomorrow if Luis doesn't find it first ;)
So, got in front of my computer.
Used mingw64-32-4.6.3 as DevKit:
https://gist.github.com/1953830
Configure worked.
Windows 7 x64 Ultimate.
Building now, libffi seems to build properly.
However, word of advice with this: this build of mingw-w64 will
dynamically link against stdc++ and others, which will require these
DLLs be placed along the compiled source.
I'll try with the other DevKit (4.5.4) but I do believe is broken.
Also works for me.
> However, word of advice with this: this build of mingw-w64 will
> dynamically link against stdc++ and others, which will require these
> DLLs be placed along the compiled source.
Luis raises a *very* important point that at least (2) DLLs from the 4.6.3 DevKit need be used with Rubinius if and when you get it to build. IIRC they are `libstdc++-6.dll` and `libgcc_s_sjlj-1.dll` but I don't experiment with Rubinius any more.
TL;DR: use the mingw64-32-4.6.3 and don't worry about renaming binaries as in my 4.5.4 based blog post.
There's two versions of binary mingw-w64 downloads, the rubenvb build and their automated buildbot builds. IIRC, they have different internal packaging.
We switched from the automated build (4.5.4) to focus on using the rubenvb builds (4.6.3) for multiple reasons. I *suspect* this commit and friends don't play well with the old 4.5.4 buildbot layout
https://github.com/oneclick/rubyinstaller/commit/aa52f0920c6a48f4d0a5b1340feb90b75be23d77
I've not been happy with the mingw-w64 mingw buildbot builds (for many reasons) and will likely remove support for the current 4.5.4 build rather than fixing it. I may take a little time to validate my suspicion, but let us know how far you get on Rubinius using the mingw64-32-4.6.3 DevKit.
If 4.6.3 works well enough for you, wish mingw64-32-4.5.4 a safe trip, as it's not long for this repo ;)
Jon
> So, got in front of my computer.
>
> Used mingw64-32-4.6.3 as DevKit:
>
> https://gist.github.com/1953830Also works for me.
Luis raises a *very* important point that at least (2) DLLs from the 4.6.3 DevKit need be used with Rubinius if and when you get it to build. IIRC they are `libstdc++-6.dll` and `libgcc_s_sjlj-1.dll` but I don't experiment with Rubinius any more.
We switched from the automated build (4.5.4) to focus on using the rubenvb builds (4.6.3) for multiple reasons. I *suspect* this commit and friends don't play well with the old 4.5.4 buildbot layout
https://github.com/oneclick/rubyinstaller/commit/aa52f0920c6a48f4d0a5b1340feb90b75be23d77
If 4.6.3 works well enough for you, wish mingw64-32-4.5.4 a safe trip, as it's not long for this repo ;)