982
edits
| Line 2: | Line 2: | ||
== Current Status of development on the team clone: fg-download-and-compile-fgmeta.git == | == Current Status of development on the team clone: fg-download-and-compile-fgmeta.git == | ||
* FGMeta master and next currently contain script version 1.9. | * FGMeta master and next currently contain script version 1.9.13 | ||
* Team clone branches | * Team clone branches | ||
** master is a copy of what is on fgmeta | ** master is a copy of what is on fgmeta | ||
** | ** Script_1.9.14 changes are related to logging are extensive | ||
*** removal of | tee -a $LOGFILE, 2>&1 | tee -a $LOGFILE and >> $LOGFILE | *** removal of | tee -a $LOGFILE, 2>&1 | tee -a $LOGFILE and >> $LOGFILE | ||
*** addition of a section to recursively call the script with original options and parameters plus 2>&1 | tee -a $LOGFILE | *** addition of a section to recursively call the script with original options and parameters plus 2>&1 | tee -a $LOGFILE | ||
*** renaming the log file: download_and_compile.log | *** renaming the log file: download_and_compile.log | ||
*** addition of a separate log file download_and_compile_summary.log containing only time stamped results of build steps | *** addition of a separate log file download_and_compile_summary.log containing only time stamped results of build steps | ||
*** cleanup task: lowercase all variables that are not used as environment variables. This is the current accepted practice for bash scripts. | *** cleanup task: lowercase all variables that are not used as environment variables. This is the current accepted practice for bash scripts. | ||
*** cleanup task: use a "Here Document" for help | *** cleanup task: use a "Here Document" for help | ||
*** cleanup task: get rid of all that my_slash stuff in the fgx section | *** cleanup task: get rid of all that my_slash stuff in the fgx section | ||
*** cleanup task: in the component build sections use cd to move between directories using full path names where needed. remove relative cd commands. remove necessity to return to current build directory at the end of each component. | |||
*** maintenance task: Default versions of OSG for each version of flightgear | |||
** feature_modify_fltk. produce a script to modify the paths in ~/fltk/flightgear/org/fgrun.prefs to point to the current directory | |||
** feature_symlinks | ** feature_symlinks | ||
*** A robust implementation of directory management allowing a single downloaded set of sources and fgdata to support multiple builds | *** A robust implementation of directory management allowing a single downloaded set of sources and fgdata to support multiple builds | ||
** feature_fgmeta_cmake | ** feature_fgmeta_cmake | ||
*** an implementation that makes use of the fgmeta cmake super build | *** an implementation that makes use of the fgmeta cmake super build | ||
fg-download-and-compile-fgmeta.git is currently a one man show. YOU could make it a real team. Additional testers and coders welcome. | fg-download-and-compile-fgmeta.git is currently a one man show. YOU could make it a real team. Additional testers and coders welcome. Bash coding guidance directly related to the script is available, just ask. For general bash questions ask the folks on irc.freenode.net/8001. There's some real experts there and they're very willing to help. As usual with such channels, do your homework. People on #bash have had a look at the script a few months ago and made several good suggestions that have made their way into the maintenance list for the script above. | ||
=== Script Overview -- Discussion of why the script was originally developed and where it might go from here === | === Script Overview -- Discussion of why the script was originally developed and where it might go from here === | ||
The download_and_compile.sh script was originally developed as an easy way to get the latest flightgear features in the hands of non-developers and to entice new developers to the project with an easy way to get a workable build environment in place. Suggestions have been made to move the script in the direction of a more general purpose tool that might also support work on build servers. | The download_and_compile.sh script was originally developed as an easy way to get the latest flightgear features in the hands of non-developers and to entice new developers to the project with an easy way to get a workable build environment in place. Suggestions have been made to move the script in the direction of a more general purpose tool that might also support or complement work on build servers. | ||
=== Script Requirements -- in general terms, what the script should produce === | === Script Requirements -- in general terms, what the script should produce === | ||
=== Functional requirements --Specifics of what the script should produce === | === Functional requirements --Specifics of what the script should produce === | ||
# bash | |||
# shell script (currently bash) with options and parameters | |||
# install any pre-requisite development packages | # install any pre-requisite development packages | ||
# download or update sources as needed | # download or update sources as needed | ||
| Line 46: | Line 45: | ||
# minimal load on network resources | # minimal load on network resources | ||
# support for building with different versions of underlying packages such as boost, OSG, etc | # support for building with different versions of underlying packages such as boost, OSG, etc | ||
# logging of build steps | # logging of build steps with statistics and evaluation of build results (success, failure etc) | ||
=== Current Script Features === | === Current Script Features === | ||
| Line 66: | Line 65: | ||
The script currently uses bash associative arrays for determining the version to download and build. | The script currently uses bash associative arrays for determining the version to download and build. | ||
once selected, the version information is stored in bash variables | once selected, the version information is stored in bash variables | ||
bash variables are used to | bash variables are used to | ||
| Line 78: | Line 77: | ||
The script will build everything in the directory it is run from. | The script will build everything in the directory it is run from. | ||
The script does not need to be in the directory you are building in. If you build separate versions, the current version of the script will download everything for each version. to avoid this, you can set up symbolic links to sources and to the correct version of fgdata before running the script. | The script does not need to be in the directory you are building in. If you build separate versions, the current version of the script will download everything for each version. to avoid this, you can set up symbolic links to sources and to the correct version of fgdata before running the script. The script has built in support for this, but you have to use a specific directory structure to take advantage of it: | ||
The following directory structure will support building multiple versions and variations on builds for flightgear with minimal use of network resources | |||
* <your working directory for building flightgear> | |||
** fgdata-<version> | |||
*** fgdata | |||
** fgdata-<2nd version> | |||
*** fgdata | |||
** fgsrc | |||
*** fgfs/flightgear | |||
*** openrti/openrti | |||
*** simgear/simgear | |||
** othersrc | |||
*** OpenSceneGraph | |||
**** OpenSceneGraph-3.0.1 | |||
**** OpenSceneGraph-3.1.0 | |||
**** OpenSceneGraph-3.2.0 | |||
*** plib-1.8.5 | |||
**** plib | |||
** download_and_compile.sh | |||
** stable | |||
*** build | |||
*** install | |||
** 2.12.0 | |||
*** build | |||
*** install | |||
** 3.0.0 | |||
*** build | |||
*** install | |||
** master | |||
*** build | |||
*** install | |||
** next | |||
*** build | |||
*** install | |||
If you setup the following directories and file on first use, the script will use them when you run ../download_and_compile.sh from stable, next, master, 2.12.0, 3.0,0 or stable. | |||
* <your working directory for building flightgear> | |||
** download_and_compile.sh | |||
** stable | |||
** next | |||
** master | |||
** 2.12.0 | |||
** 3.0.0 | |||
Example: | |||
cd <your working directory for building flightgear> | |||
wget download_and_compile.sh wget https://www.gitorious.org/fg/fgmeta/raw/master:download_and_compile.sh | |||
mkdir -p stable | |||
mkdir -p next | |||
cd stable | |||
../download_and_compile.sh -sxv | |||
cd ../next | |||
../download_and_compile.sh -p n -xv | |||
== Future Script Versions == | == Future Script Versions == | ||
edits