thesynapseuk
Posts: 55
Joined: Thu Jul 28, 2011 11:21 am

How easy is it to compile a program from source code?

Tue Jun 05, 2012 4:37 pm

Hi,

I'm looking to make my RPi into a mobile multi-machine emulator. e.g. SNES, NES, Megadrive etc.

Of course I can get source code for an emulator, and I'm sure I could find a tutorial to run 'make' or whatever else I need to compile, but how easy is this going to be?

Is it just a simple case of compiling the source code for the RPi's ARM chip and then I have an executable (which I could then share with others)? Or are there lots of problems to sort out? If so, then that's fine, but where would I start looking for info on how to resolve them (I'm happy for it to be a learning experience in any case).

Cheers.

User avatar
abishur
Posts: 4477
Joined: Thu Jul 28, 2011 4:10 am
Location: USA
Contact: Website

Re: How easy is it to compile a program from source code?

Tue Jun 05, 2012 4:48 pm

The issue with the emulators I've been looking at is that they use openGL rather than openGL ES, additionally, the couple that actually run on the pi, don't have sound working with them yet. So it's not so much an issue of just compiling from source as it is editing the code ;-) Still I'm also dying to see an NES emulator pop up soon!

Moving thread to the media center and gaming subforum.
Dear forum: Play nice ;-)

User avatar
rurwin
Forum Moderator
Forum Moderator
Posts: 4258
Joined: Mon Jan 09, 2012 3:16 pm
Contact: Website

Re: How easy is it to compile a program from source code?

Tue Jun 05, 2012 5:50 pm

To answer the general case...

In the majority of cases you download the source-code and issue three commands:

./configure
make
sudo make install

and the program compiles and installs without any problems.

In a few more cases you will not have the required dependencies installed and will have to give a few apt-get install commands for a few development packages. People on the forum can help with this, and then it goes smoothly. In time you can learn to decode what is needed.

In a few more cases, the developers have not been so conventional and things can get hairy. Or your architecture is off, or you've got the wrong version of libraries installed (and to down-grade them would break other stuff).

And then there is the real show-stopper, where something almost unfixable stops you.

Unfortunately it seems that emulators are in the last category.

Return to “Media centres”