To build the Linux distribution-neutral installer you have the following options
make -f Makefile pkg-posix
<--- builds a release self-extracting package
make -f Makefile pkg-posix-test
<--- builds a test release self-extracting package
make -f Makefile pkg-posix-snapshot
<--- builds a snapshot release self-extracting package
Now for the nightly build installer the command is
make -f Makefile pkg-posix-nightly
<--- builds a snapshot release self-extracting package for the nightly build
(the difference in the nightly build is that the package naming and the installation folder naming changes, in order to be able to coexist with a normal Oolite installation; the "-trunk" is used as label in this case)
At this point I need to explain a small 4-step trick that we perform in order for the installer to work in various distros
(e.g. Fedora, openSUSE, debian, [X,K,L]Ubuntu, Mint, Slax etc. -
back in 2009 it even worked on a Linpus Lite based Acer One!!! )
(this is why we call it "distribution-neutral"... it's not for ALL the Linux distros but for many of them.)
Step 1
The main libraries, that Oolite depends on, have been manually installed from source (i.e. configure, make & make install) in the system that is used to produce the publicly released installer.
Step 2 improvement alert!-improvement alert!-improvement alert!
The source code script
deps/Linux-deps/[x86, x86_64]/lib_linker/make_so_links.sh
is used to generate symbolic links pointing to the libraries, to be packaged, using the short name of the library.
This symbolic link name is used at the time of compiler objects linking (see GNUmakefile).
Step 3
The installer is packaged to carry these exact same libraries.
The binaries packaged are located in the source code tree folder
deps/Linux-deps/[x86, x86_64]/lib
NOTE: These libraries will NOT be installed in the user's system. They will just be copied, during Oolite installation, in
Oolite[-trunk]/oolite-deps/lib/
installation folder, they will only be visible by Oolite and they will be deleted when Oolite is uninstalled.
Step 4
One final step is performed every time the user is actually executing Oolite. The command
export LD_LIBRARY_PATH=${OOLITE_ROOT}/oolite-deps/lib
is executed to indicate to Oolite to look into this path first for its libraries, before the standard set of directories.
I know that this is a "trick" and does not follow any Linux standard or best practices but...
- it has proven to work for more than 10 years (does anyone still remember the Autopackage era?)
- it doesn't mess with the user's system libraries
- it gives a safe uninstall to the user (library dependencies of other applications are not impacted)
- troubleshooting a user's issue is contained to Oolite code and not to any bleeding edge latest version library the user may have in the system.
- it has made the Nightly Build for Linux feasible
- avoid the operational activities nightmare to support various Linux distros, flavors, versions native installation policies
- one package format fits all (avoids also the debate between competing installation package formats for Linux such as .rpm and .deb)
- Oolite new releases can be scheduled independently of each distro processes, policies and release schedules for new versions of third party software:
- Oolite Linux can be released together with Mac and Windows
- any new Oolite Linux release is made available, for all Linux users that have Oolite running, simultaneously and independently to their respective Linux distro
- common Oolite file hierarchy system for all Linux distros
- makes feasible a common and simple functionality of upgrading from one Oolite version to the most current one, without the need of downloading the full version (call me
oolite-update
).
- easier troubleshooting (specially when you give instructions to the user for locating installation files)
- All of the above considering the handful of near (or already there) middle-aged people that are managing Oolite in parallel with RL.
- For as much as it worth, Linux users with distros dated as back as 2009 (e.g. just tested v1.80 and trunk on a debian "lenny") can still play current versions of Oolite.
QCS wrote:...If I can come up with something useful and nice in the next half year, I'll let you guys know and you can then see for yourself
I am also interested in this attempt, so as soon as you have something working, I will be more than willing to test it in order not to risk any of the aforementioned benefits of the current approach (or as less as possible).