kopia lustrzana https://github.com/OpenDroneMap/ODM
rodzic
63a1e890e7
commit
045ace6f3e
13
configure.sh
13
configure.sh
|
@ -6,6 +6,12 @@ install() {
|
|||
export PYTHONPATH=$RUNPATH/SuperBuild/install/lib/python2.7/dist-packages:$RUNPATH/SuperBuild/src/opensfm:$PYTHONPATH
|
||||
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$RUNPATH/SuperBuild/install/lib
|
||||
|
||||
if [[ $2 =~ ^[0-9]+$ ]] ; then
|
||||
processes=$2
|
||||
else
|
||||
processes=$(nproc)
|
||||
fi
|
||||
|
||||
## Before installing
|
||||
echo "Updating the system"
|
||||
sudo apt-get update
|
||||
|
@ -97,12 +103,12 @@ install() {
|
|||
echo "Compiling SuperBuild"
|
||||
cd ${RUNPATH}/SuperBuild
|
||||
mkdir -p build && cd build
|
||||
cmake .. && make -j$(nproc)
|
||||
cmake .. && make -j$processes
|
||||
|
||||
echo "Compiling build"
|
||||
cd ${RUNPATH}
|
||||
mkdir -p build && cd build
|
||||
cmake .. && make -j$(nproc)
|
||||
cmake .. && make -j$processes
|
||||
|
||||
echo "Configuration Finished"
|
||||
}
|
||||
|
@ -123,7 +129,7 @@ reinstall() {
|
|||
|
||||
usage() {
|
||||
echo "Usage:"
|
||||
echo "bash configure.sh <install|update|uninstall|help>"
|
||||
echo "bash configure.sh <install|update|uninstall|help> [nproc]"
|
||||
echo "Subcommands:"
|
||||
echo " install"
|
||||
echo " Installs all dependencies and modules for running OpenDroneMap"
|
||||
|
@ -133,6 +139,7 @@ usage() {
|
|||
echo " Removes SuperBuild and build modules. Does not uninstall dependencies"
|
||||
echo " help"
|
||||
echo " Displays this message"
|
||||
echo "[nproc] is an optional argument that can set the number of processes for the make -j tag. By default it uses $(nproc)"
|
||||
}
|
||||
|
||||
if [[ $1 =~ ^(install|reinstall|uninstall|usage)$ ]]; then
|
||||
|
|
Ładowanie…
Reference in New Issue