restore Openscenegraph compile functionality
This commit is contained in:
parent
0c3bf73b01
commit
245ab83192
1 changed files with 39 additions and 4 deletions
|
@ -32,7 +32,7 @@ FGVERSION="release/3.4.0"
|
||||||
|
|
||||||
LOGFILE=compilation_log.txt
|
LOGFILE=compilation_log.txt
|
||||||
WHATTOBUILD=
|
WHATTOBUILD=
|
||||||
#AVAILABLE VALUES: PLIB OPENRTI SIMGEAR FGFS DATA FGRUN FGO FGX OPENRADAR ATCPIE TERRAGEAR TERRAGEARGUI
|
#AVAILABLE VALUES: PLIB OPENRTI OSG SIMGEAR FGFS DATA FGRUN FGO FGX OPENRADAR ATCPIE TERRAGEAR TERRAGEARGUI
|
||||||
WHATTOBUILDALL=(SIMGEAR FGFS DATA)
|
WHATTOBUILDALL=(SIMGEAR FGFS DATA)
|
||||||
STABLE=
|
STABLE=
|
||||||
APT_GET_UPDATE="y"
|
APT_GET_UPDATE="y"
|
||||||
|
@ -327,6 +327,41 @@ if [[ "$(declare -p WHATTOBUILD)" =~ '['([0-9]+)']="OPENRTI"' ]]; then
|
||||||
_make openrti
|
_make openrti
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
#######################################################
|
||||||
|
# OpenSceneGraph
|
||||||
|
#######################################################
|
||||||
|
OSG_INSTALL_DIR=openscenegraph
|
||||||
|
INSTALL_DIR_OSG=$INSTALL_DIR/$OSG_INSTALL_DIR
|
||||||
|
cd "$CBD"
|
||||||
|
mkdir -p "openscenegraph"
|
||||||
|
if [[ "$(declare -p WHATTOBUILD)" =~ '['([0-9]+)']="OSG"' ]]; then
|
||||||
|
echo "****************************************" | tee -a $LOGFILE
|
||||||
|
echo "**************** OSG *******************" | tee -a $LOGFILE
|
||||||
|
echo "****************************************" | tee -a $LOGFILE
|
||||||
|
cd "$CBD"/openscenegraph
|
||||||
|
_gitDownload http://github.com/openscenegraph/osg.git
|
||||||
|
_gitUpdate OpenSceneGraph-3.2
|
||||||
|
|
||||||
|
if [ "$RECONFIGURE" = "y" ]; then
|
||||||
|
cd "$CBD"
|
||||||
|
mkdir -p build/openscenegraph
|
||||||
|
cd "$CBD"/build/openscenegraph
|
||||||
|
rm -f CMakeCache.txt
|
||||||
|
cmake -DCMAKE_BUILD_TYPE="Release" \
|
||||||
|
-DCMAKE_INSTALL_PREFIX:PATH="$INSTALL_DIR_OSG" ../../openscenegraph/ 2>&1 | tee -a $LOGFILE
|
||||||
|
fi
|
||||||
|
|
||||||
|
_make openscenegraph
|
||||||
|
#FIX FOR 64 BIT COMPILATION
|
||||||
|
if [ -d "$INSTALL_DIR_OSG/lib64" ]; then
|
||||||
|
if [ -L "$INSTALL_DIR_OSG/lib" ]; then
|
||||||
|
echo "link already done"
|
||||||
|
else
|
||||||
|
ln -s "$INSTALL_DIR_OSG/lib64" "$INSTALL_DIR_OSG/lib"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
#######################################################
|
#######################################################
|
||||||
# SIMGEAR
|
# SIMGEAR
|
||||||
#######################################################
|
#######################################################
|
||||||
|
@ -384,7 +419,7 @@ if [[ "$(declare -p WHATTOBUILD)" =~ '['([0-9]+)']="FGFS"' || "$(declare -p WHAT
|
||||||
cmake -DCMAKE_BUILD_TYPE="Release" \
|
cmake -DCMAKE_BUILD_TYPE="Release" \
|
||||||
-DENABLE_FLITE=ON \
|
-DENABLE_FLITE=ON \
|
||||||
-DCMAKE_INSTALL_PREFIX:PATH="$INSTALL_DIR_FGFS" \
|
-DCMAKE_INSTALL_PREFIX:PATH="$INSTALL_DIR_FGFS" \
|
||||||
-DCMAKE_PREFIX_PATH="$INSTALL_DIR_SIMGEAR;$INSTALL_DIR_OPENRTI;$INSTALL_DIR_PLIB" \
|
-DCMAKE_PREFIX_PATH="$INSTALL_DIR_SIMGEAR;$INSTALL_DIR_OSG;$INSTALL_DIR_OPENRTI;$INSTALL_DIR_PLIB" \
|
||||||
$FG_CMAKEARGS \
|
$FG_CMAKEARGS \
|
||||||
../../flightgear 2>&1 | tee -a $LOGFILE
|
../../flightgear 2>&1 | tee -a $LOGFILE
|
||||||
fi
|
fi
|
||||||
|
@ -409,7 +444,7 @@ if [[ "$(declare -p WHATTOBUILD)" =~ '['([0-9]+)']="FGFS"' || "$(declare -p WHAT
|
||||||
echo "#!/bin/sh" > $SCRIPT
|
echo "#!/bin/sh" > $SCRIPT
|
||||||
echo "cd \$(dirname \$0)" >> $SCRIPT
|
echo "cd \$(dirname \$0)" >> $SCRIPT
|
||||||
echo "cd $SUB_INSTALL_DIR/$FGFS_INSTALL_DIR/bin" >> $SCRIPT
|
echo "cd $SUB_INSTALL_DIR/$FGFS_INSTALL_DIR/bin" >> $SCRIPT
|
||||||
echo "export LD_LIBRARY_PATH=../../$SIMGEAR_INSTALL_DIR/lib:../../$OPENRTI_INSTALL_DIR/lib:../../$PLIB_INSTALL_DIR/lib" >> $SCRIPT
|
echo "export LD_LIBRARY_PATH=../../$SIMGEAR_INSTALL_DIR/lib:../../$OSG_INSTALL_DIR/lib:../../$OPENRTI_INSTALL_DIR/lib:../../$PLIB_INSTALL_DIR/lib" >> $SCRIPT
|
||||||
echo "./fgfs --fg-root=\$PWD/../fgdata/ \$@" >> $SCRIPT
|
echo "./fgfs --fg-root=\$PWD/../fgdata/ \$@" >> $SCRIPT
|
||||||
chmod 755 $SCRIPT
|
chmod 755 $SCRIPT
|
||||||
|
|
||||||
|
@ -417,7 +452,7 @@ if [[ "$(declare -p WHATTOBUILD)" =~ '['([0-9]+)']="FGFS"' || "$(declare -p WHAT
|
||||||
echo "#!/bin/sh" > $SCRIPT
|
echo "#!/bin/sh" > $SCRIPT
|
||||||
echo "cd \$(dirname \$0)" >> $SCRIPT
|
echo "cd \$(dirname \$0)" >> $SCRIPT
|
||||||
echo "cd $SUB_INSTALL_DIR/$FGFS_INSTALL_DIR/bin" >> $SCRIPT
|
echo "cd $SUB_INSTALL_DIR/$FGFS_INSTALL_DIR/bin" >> $SCRIPT
|
||||||
echo "export LD_LIBRARY_PATH=../../$SIMGEAR_INSTALL_DIR/lib:../../$OPENRTI_INSTALL_DIR/lib:../../$PLIB_INSTALL_DIR/lib" >> $SCRIPT
|
echo "export LD_LIBRARY_PATH=../../$SIMGEAR_INSTALL_DIR/lib:../../$OSG_INSTALL_DIR/lib:../../$OPENRTI_INSTALL_DIR/lib:../../$PLIB_INSTALL_DIR/lib" >> $SCRIPT
|
||||||
echo "gdb --directory="\$P1"/fgfs/source/src/ --args fgfs --fg-root=\$PWD/../fgdata/ \$@" >> $SCRIPT
|
echo "gdb --directory="\$P1"/fgfs/source/src/ --args fgfs --fg-root=\$PWD/../fgdata/ \$@" >> $SCRIPT
|
||||||
chmod 755 $SCRIPT
|
chmod 755 $SCRIPT
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue