Board index FlightGear Support Installation Linux

[TUTORIAL] Compiling from Git on Arch

Installing FlightGear, scenery, aircraft etc. on Linux systems like Ubuntu.

[TUTORIAL] Compiling from Git on Arch

Postby junior-s » Sun Apr 06, 2014 11:46 pm

Hello,

This tutorial was made for those who'd like to run FG Git on Arch.

Note: Since Arch is aimed at advanced Linux users, so is this tutorial.
I tested this method with a fresh-install of Arch + kdebase + kdebase-workspace + kdemultimedia-kmix". You shouldn't have problems with other Desktop Environments.

Method one: Using the Default script from Debian/Ubuntu

1. If you don't have the package "base-devel" yet, please do install it.
2- After that, the following packages are required:
openscenegraph git fltk plib cmake svn lib32-openal cvs freealut libpng scons python-imaging freeglut abs gettext boost libpng12 openexr ogre


You can install them with:
Code: Select all
sudo pacman -S openscenegraph git fltk plib cmake svn lib32-openal cvs freealut libpng scons python-imaging freeglut abs gettext boost libpng12 openexr ogre


3. Now, download the script to a folder of your choice. Mine is /home/junior/Documents/Games/FlightGear/Game/compile.sh
4. Enable it to be executable
Code: Select all
$ chmod +x script.sh

5. Now let's install the game:

Code: Select all
$ ./script.sh -a n -p n -j x SIMGEAR

Note: Change the value of "-j x" to the number of cores you want to use to build. I have 2 cores, so I use "-j 2".
Code: Select all
$ ./script.sh -a n -p n -j x FGFS

Code: Select all
$ ./script.sh -a n -p n -j x DATA

Code: Select all
$ ./script.sh -a n -p n -j x FGRUN

Note: Building DATA will download at least 14 GB of data. It's a good idea to leave it overnight.
Note 2: On FGRun, you might get the following error when launching the game
Scenery needs a parameter

To fix it, simply hit "Prev" (on FGRun) till you get to the first page. Delete the current scenery path and change to
/home/your_user/path_to_compiling_folder/install/fgfs/fgdata/Scenery

Note 3: Your autostart file will NOT be saved at the desired compiling folder. It will still remain at /home/your-user/.fgfs

You should be now ready to fly.

Method 2: Using an altered Script to Arch

Alternatively, you can download Brisa's script with my edits to fit Arch install. You can download it here: http://pastebin.com/n4gmmgZt

To review the changes I made you can use a Text comparing tool. I use this: http://text-compare.com/

Installing:

2. Install the "base-devel" package if not yet installed;

3. Now, download the script to a folder of your choice. Mine is /home/junior/Documents/Games/FlightGear/Game/compile.sh
4. Enable it to be executable
Code: Select all
$ chmod +x script.sh

5. Now let's install the game:
Code: Select all
$ ./script.sh -j x SIMGEAR

When prompted to type your root password, please do it so the required packages can be installed. The same to the other builds (fgrun, fgfs and data)
Code: Select all
$ ./script.sh -j x FGFS

Code: Select all
$ ./script.sh -j x DATA

Code: Select all
$ ./script.sh -j x FGRUN
Last edited by junior-s on Thu Apr 10, 2014 2:04 am, edited 1 time in total.
junior-s
Retired
 
Posts: 212
Joined: Tue May 21, 2013 3:27 am
Location: Wonderland
Callsign: junior-s
Version: GIT
OS: Arch Linux

Re: [TUTORIAL] Compiling Git on Arch

Postby Gijs » Mon Apr 07, 2014 8:22 am

Could you please add this to the wiki? Forum topics get lost much easier over time than wiki articles ;-)
Airports: EHAM, EHLE, KSFO
Aircraft: 747-400
User avatar
Gijs
Moderator
 
Posts: 9544
Joined: Tue Jul 03, 2007 3:55 pm
Location: Delft, the Netherlands
Callsign: PH-GYS
Version: Git
OS: Windows 10

Re: [TUTORIAL] Compiling Git on Arch

Postby sanhozay » Mon Apr 07, 2014 11:52 am

Strictly speaking, shouldn't the title be "Compiling Flightgear from Git", as you are not compiling Git itself? I know that in Flightgear world, "Git" colloquially means "the latest development version from the Git repository" but it is potentially confusing, especially for people who really do want to compile Git and end up on here or on a wiki page via a search engine.
sanhozay
 
Posts: 1207
Joined: Thu Dec 26, 2013 12:57 pm
Location: EGNM
Callsign: G-SHOZ
Version: Git
OS: Ubuntu 16.04

Re: [TUTORIAL] Compiling Git on Arch

Postby Hooray » Mon Apr 07, 2014 12:55 pm

Agreed with both previous comments, in fact I originally also expected the other thread to be about something else - but then I figured out that it was referring to FlightGear/next from git.
And a wiki article/tutorial would be great
Please don't send support requests by PM, instead post your questions on the forum so that all users can contribute and benefit
Thanks & all the best,
Hooray
Help write next month's newsletter !
pui2canvas | MapStructure | Canvas Development | Programming resources
Hooray
 
Posts: 12707
Joined: Tue Mar 25, 2008 9:40 am
Pronouns: THOU

Re: [TUTORIAL] Compiling Git on Arch

Postby junior-s » Mon Apr 07, 2014 3:51 pm

OK with everyone :)
junior-s
Retired
 
Posts: 212
Joined: Tue May 21, 2013 3:27 am
Location: Wonderland
Callsign: junior-s
Version: GIT
OS: Arch Linux

Re: [TUTORIAL] Compiling Git on Arch

Postby Johannes » Tue Apr 08, 2014 10:17 am

Whit this command
Code: Select all
$ ./script.sh -a n -p n -j x DATA

I get this error:
Code: Select all
GIT DATA FROM git://gitorious.org/fg/fgdata.git  ...
+ '[' '!' -e fgdata ']'
+ git clone git://gitorious.org/fg/fgdata.git fgdata
Cloning into 'fgdata'...
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
+ exit

Is there a solution for this?
Johannes
 
Posts: 39
Joined: Wed Sep 18, 2013 7:41 am
OS: Arch Linux

Re: [TUTORIAL] Compiling Git on Arch

Postby F-JJTH » Tue Apr 08, 2014 11:45 am

The only solution is to re-run the script. This is not a problem with the script, this problem is beacuse of the connection between you and gitorious.org

Regards,
Clément
User avatar
F-JJTH
 
Posts: 696
Joined: Fri Sep 09, 2011 12:02 pm

Re: [TUTORIAL] Compiling Git on Arch

Postby junior-s » Tue Apr 08, 2014 2:29 pm

F-JJTH wrote in Tue Apr 08, 2014 11:45 am:The only solution is to re-run the script. This is not a problem with the script, this problem is beacuse of the connection between you and gitorious.org

Regards,
Clément

Yes. It's a problem with the connection.

I've had this too. The only solution is to way a few minutes and re-try.
junior-s
Retired
 
Posts: 212
Joined: Tue May 21, 2013 3:27 am
Location: Wonderland
Callsign: junior-s
Version: GIT
OS: Arch Linux

Re: [TUTORIAL] Compiling Git on Arch

Postby Johannes » Wed Apr 09, 2014 4:21 pm

Thank you for your answers.
Now it worked, and I have the git-version of Flightgear working!
Last edited by Johannes on Thu May 15, 2014 9:46 am, edited 1 time in total.
Johannes
 
Posts: 39
Joined: Wed Sep 18, 2013 7:41 am
OS: Arch Linux

Re: [TUTORIAL] Compiling Git on Arch

Postby junior-s » Wed Apr 09, 2014 8:58 pm

A quick note:

To update DATA you must do:
$ cd path_to_game/insta/fgfs/fgdata

$ git pull
junior-s
Retired
 
Posts: 212
Joined: Tue May 21, 2013 3:27 am
Location: Wonderland
Callsign: junior-s
Version: GIT
OS: Arch Linux

Re: [TUTORIAL] Compiling from Git on Arch

Postby Johannes » Fri Apr 11, 2014 11:02 am

Why?
If you give the normal command, then the script checks if the data already exist; when yes, then it does 'git pull' for you. That's how I understood it, but maybe I'm wrong?
Johannes
 
Posts: 39
Joined: Wed Sep 18, 2013 7:41 am
OS: Arch Linux

Re: [TUTORIAL] Compiling from Git on Arch

Postby junior-s » Fri Apr 11, 2014 4:48 pm

Johannes wrote in Fri Apr 11, 2014 11:02 am:Why?
If you give the normal command, then the script checks if the data already exist; when yes, then it does 'git pull' for you. That's how I understood it, but maybe I'm wrong?

It won't update everything :) Not on Arch.
junior-s
Retired
 
Posts: 212
Joined: Tue May 21, 2013 3:27 am
Location: Wonderland
Callsign: junior-s
Version: GIT
OS: Arch Linux

Re: [TUTORIAL] Compiling from Git on Arch

Postby chris_blues » Thu May 08, 2014 7:33 pm

Quite nice, your tutorial! I also vote for a wiki-page!

And maybe we can merge the two scripts! It should be fairly easy to add another if to check /etc/issue for any string ARCH in it, and change apt-get to pacman and the packages names accordingly.
I don't know, who maintains the download_and_compile.sh, but I find, your work should be made available easily, thus, integrate it in the existing script...

just my 2 pennies...

Edit:
Sorry /etc/issue contains this:
Code: Select all
Arch Linux \r (\l)

Last edited by chris_blues on Mon May 12, 2014 10:29 am, edited 3 times in total.
Don't hesitate to let me know if I'm incorrect or just annoying! As long as you do it gently! :)
Debian stable 64bit - i7 8x2.8GHz - 20GB RAM - GeForce GTS 450
Citation II
User avatar
chris_blues
Retired
 
Posts: 1577
Joined: Mon May 03, 2010 2:30 pm
Location: claws of real life
Callsign: chris_blues
Version: GIT
OS: Debian stable 64

Re: [TUTORIAL] Compiling from Git on Arch

Postby chris_blues » Thu May 08, 2014 7:36 pm

junior-s wrote in Fri Apr 11, 2014 4:48 pm:It won't update everything :) Not on Arch.

What do you mean? I build myself a script to update every custom aircraft, scenery, and SimGear, FlightGear, FGData and all the stuff. It always worked for me with this line in it for fgdata:
Code: Select all
./download_and_compile.sh -a n -p n -j 3 DATA

I know, the -j option is unneccessary in this case, since there's no make involved, but I guess I was to lazy to erase it...
Don't hesitate to let me know if I'm incorrect or just annoying! As long as you do it gently! :)
Debian stable 64bit - i7 8x2.8GHz - 20GB RAM - GeForce GTS 450
Citation II
User avatar
chris_blues
Retired
 
Posts: 1577
Joined: Mon May 03, 2010 2:30 pm
Location: claws of real life
Callsign: chris_blues
Version: GIT
OS: Debian stable 64

Re: [TUTORIAL] Compiling from Git on Arch

Postby junior-s » Fri May 23, 2014 2:51 am

chris_blues wrote in Thu May 08, 2014 7:36 pm:
junior-s wrote in Fri Apr 11, 2014 4:48 pm:It won't update everything :) Not on Arch.

What do you mean? I build myself a script to update every custom aircraft, scenery, and SimGear, FlightGear, FGData and all the stuff. It always worked for me with this line in it for fgdata:
Code: Select all
./download_and_compile.sh -a n -p n -j 3 DATA

I know, the -j option is unneccessary in this case, since there's no make involved, but I guess I was to lazy to erase it...

If you use only the "UPDATE" option it won't update everything, so you have to manually add "DATA", "FGRUN" and so on. If you try to update it with "UPDATE DATA" it won't update, so you have to update as I said. At least that's what I have to do :P
junior-s
Retired
 
Posts: 212
Joined: Tue May 21, 2013 3:27 am
Location: Wonderland
Callsign: junior-s
Version: GIT
OS: Arch Linux

Next

Return to Linux

Who is online

Users browsing this forum: No registered users and 0 guests