Installing FlightGear at a differnt location

Hi there,

as my standard volume (root & co.) is only 35GB, which is already bigger than the suggested value during installation. But as many programs don’t ask the user in which location they should be installed, they start to clog this volume and I want to install Flightgear somewhere else.

But unfortunately it does not support to choose an installation location during the installation process.

Looking into the FlightGear wiki I found 3 environment variables which should solve this problem:
FG_ROOT
FG_SCENERY
FG_AIRCRAFT

So I decided to try to set those variables, which I ha to find out, should in OpenSuse set in /etc/profile.local


FG_ROOT=/home/joe/FG
FG_SCENERY=/home/data2/flightgear/scenes
FG_AIRCRAFT=/home/data2/flightgear/aircraft

To be on the save side, I restarted the OS and tried to

ECHO $FG_ROOT

and … got nothing !!! The Env. Vars were not set … and the OpenSusee installation of FlightGear did not install where I want it to be.

So can someone here explain me under which circumstances OpenSuse is willing to process the profile.local file and set those variables ?

Or is there a new file / location for user defined environment variables in Leap or … ?

TIA, Joe

That is strange, this is what I get

henk@boven:~> ECHO $FG_ROOT
If 'ECHO' is not a typo you can use command-not-found to lookup the package that contains it, like this:
    cnf ECHO
henk@boven:~> 

And btw, that is what I expected to get.

Hi, I meanwhile have found information on the internet that in Linux there are 3 different files for environment variables:

/etc/bash.bashrc (in OpenSuse one should use : /ect/bash.bashrc.local )
/etc/environment
/etc/profile (in OpenSuse one should use : /etc/profile.local )

so I have put the following 3 lines in all 3 files, as for me from the information I found, a clear functional differentiation is not possible:


FG_ROOT=/home/joe/FG
FG_SCENERY=/home/data2/flightgear/scenes
FG_AIRCRAFT=/home/data2/flightgear/aircraft

To be on the save side, I restarted the OS again and tried to

printenv | sort

and now it works !!! I hope that Flightgear will now care about these env. vars. during installation … Fought hard for it lol!

But I still would like to know what are the differences of these 3 environment variable files ?
Is this due to the organic growth of Linux or is there some kind of logic behind it ?
Want to insert the env.vars in the future only in the “right” file :wink:

TIA, Joe

If you install via RPM then I doubt that the environment variable will matter since the RPM will put thing where it puts things

You did not say what file system you use BTRFS or ext4. BTRFS has a recommended size of 40 gig for / because it uses snapper to take snapshots and that does eat up disk space. For ext4 35 gig is way plenty for just about anything you care to do

profile files are in general used by all shells.

bashrc files are, as the name implicates, used by Bash.

Read:

man bash

specialy the INVOCATION section.

And /etc/environment:

henk@boven:~> cat /etc/environment
#
# This file is parsed by pam_env module
#
# Syntax: simple "KEY=VAL" pairs on seperate lines
#
henk@boven:~>

It looks as being a PAM associated file. I assume not applicable to your problem.