Compiling

Talk about your skill passion! Ask questions, get feedback, post something cool!

Moderator: samw3

User avatar
PFC
Posts: 633
Joined: Sun Dec 16, 2007 5:57 pm
Location: Canada

Compiling

Postby PFC » Mon Feb 02, 2009 7:39 am

*sigh*

Tried to compile pgreloaded (pygame2) from svn
FAIL

has anyone ever managed to compile an opensource project from source on windows?

I have tried multiple projects in the past... all have failed to produce anything useful.
I'm just wondering what tools you guys use. Following tutorials and instructions never seem to yield good results.

I think I might just keep on programming blindly until I get my linux laptop back to actually test the code(where compiling isn't some form of black-magic mixed in with some voodoo)
User avatar
Kukanani
Posts: 258
Joined: Tue Sep 23, 2008 7:55 pm

Re: Compiling

Postby Kukanani » Mon Feb 02, 2009 8:35 am

has anyone ever managed to compile an opensource project from source on windows?
Nope. Although my problems are with C++. I've tried:
OGRE
ogreode
ogreBullet
ogreNewt
Irrlicht
Crystal Space

I failed at every one. Windows just has this...thing with opensource.

Kukanani
"Blessed is the one whose way is blameless, who walks in the law of the Lord"
Psalm 119:1
User avatar
PFC
Posts: 633
Joined: Sun Dec 16, 2007 5:57 pm
Location: Canada

Re: Compiling

Postby PFC » Mon Feb 02, 2009 10:19 am

well I've decided to install virtual box to give it direct IO to my hard drive in order to attempt to install linux on this machine... I think I'll start by running live off of the ISO in order to install sidux onto a usb drive, boot off of usb drive, resize partitions, reboot into windows and load virtual machine from the ISO to install to free space and set up sidux

If this works... then I can compile pgreloaded :D

(doing it this way as I do not have a burner to burn the cd and I only have a cd drive while I only have a dvd version of the os)

I don't know how running a virtual machine on a pIII with only 512MB ram is goona go...
User avatar
vibrokatana
Posts: 42
Joined: Wed Apr 01, 2009 8:52 pm
Location: FL
Contact:

Re: Compiling

Postby vibrokatana » Thu Apr 02, 2009 1:32 pm

You can also try mingw, which has GCC, bash, make and other useful tools. I use it for my projects as it is really easy to swap between osx and windows and keep on working.
User avatar
PFC
Posts: 633
Joined: Sun Dec 16, 2007 5:57 pm
Location: Canada

Re: Compiling

Postby PFC » Fri Apr 03, 2009 3:49 pm

thanks, I think I`ll try that again :)
User avatar
vibrokatana
Posts: 42
Joined: Wed Apr 01, 2009 8:52 pm
Location: FL
Contact:

Re: Compiling

Postby vibrokatana » Fri Apr 03, 2009 5:43 pm

Kukanani wrote:Windows just has this...thing with opensource.
Most of it stems from compiler incompatibilities. Despite the language being an open spec not all compilers support it fully, or induce their own behavior.

For instance this code segment will compile fine in GCC, but VC++ will not compile it (last time I checked, which was about 2 years ago);

Code: Select all

void sample_function(const int size)
{
    int test[size];
}
For the most part projects will try to keep things working between them, but you can just imagine the fun of having to write compiler specific code (luckily the compilers usually have macros that allow you to differentiate via the preprocessor and there is __APPLE__ and __WINDOWS__ macros which makes writing platform specific code pretty easy, from a shooting yourself in the foot then lighting yourself on fire kinda way).
User avatar
SSquared
Posts: 1351
Joined: Sun Dec 16, 2007 9:14 am
Location: The Beautiful Pacific Northwest
Contact:

Re: Compiling

Postby SSquared » Fri Apr 03, 2009 8:41 pm

I'm curious to know what GCC is actually doing with that example. How much space does GCC set aside? It doesn't really make sense. A C++ compiler doesn't know how much memory to allocate on the stack.

Visual Studio has been known to be behind the C++ standard, but with VS 2005 they spent some concerted effort to get up-to-date and have also worked out a lot of the problems they had with the Standard Template Library.
My quote: Have I mentioned I love C# and the iPad?
Another quote: Have I mentioned I love the iPad?
User avatar
vibrokatana
Posts: 42
Joined: Wed Apr 01, 2009 8:52 pm
Location: FL
Contact:

Re: Compiling

Postby vibrokatana » Fri Apr 03, 2009 9:06 pm

SSquared wrote:I'm curious to know what GCC is actually doing with that example. How much space does GCC set aside? It doesn't really make sense. A C++ compiler doesn't know how much memory to allocate on the stack.
This is the assembly GCC spits out on my macbook. I typed the function name as test below, so it deviates slightly from the above example. I am only familiar with MIPS, so I can't make much of it. Maybe later I will look up the operations and see what is going on.

[code] .text
.globl _test
_test:
pushl %ebp
movl %esp, %ebp
subl $40, %esp
movl %esp, %eax
movl %eax, %edx
movl 8(%ebp), %eax
sall $2, %eax
addl $15, %eax
addl $15, %eax
shrl $4, %eax
sall $4, %eax
subl %eax, %esp
movl %esp, -28(%ebp)
movl -28(%ebp), %eax
addl $15, %eax
shrl $4, %eax
sall $4, %eax
movl %eax, -28(%ebp)
movl -28(%ebp), %eax
movl %eax, -12(%ebp)
movl %edx, %esp
leave
ret
.subsections_via_symbols[/code]


SSquared wrote:Visual Studio has been known to be behind the C++ standard, but with VS 2005 they spent some concerted effort to get up-to-date and have also worked out a lot of the problems they had with the Standard Template Library.
Maybe, maybe not. VC++ is only available on one platform and is a bigger pain to work with once you get used to GCC. I don't even bother with it anymore, especially since MSFT has moved on to .NET (mainly C# and VB, C++.NET looks like a nightmare).
User avatar
jestermax
Posts: 398
Joined: Sun Dec 16, 2007 9:14 am
Location: Ontario, Canada

Re: Compiling

Postby jestermax » Sat Apr 04, 2009 11:38 am

I've compiled Ogre3d and OpenScenegraph from source on my windows laptop with VS2995. What problems are you having? I don't remember having any major issues other than OSG took like 3 hours to compile cause it's an aging laptop.

Who is online

Users browsing this forum: No registered users and 9 guests

cron