Skip to content
Snippets Groups Projects
Commit ea8a8ae0 authored by incardon's avatar incardon
Browse files

fixing install script

parent 8c3bd510
No related branches found
No related tags found
No related merge requests found
#! /bin/bash
source script/discover_os
discover_os
## Check and try to install the prerequisites
script/pre_req
......@@ -105,12 +108,13 @@ if [ $MPI_installed -eq 1 ]; then
echo -e "\033[1;34;5m ----------------- MPI ----------------- \033[0m"
echo -e " MPI has been installed into: \033[1m $HOME/MPI \033[0m"
echo ""
echo -e "\033[1;34m On Linux: \033[0m"
echo -e "\033[1m export PATH=\"\$PATH:\$HOME/MPI \" \033[0m "
echo -e "\033[1m export LD_LIBRARY_PATH=\"\$LD_LIBRARY_PATH:\$HOME/MPI/lib\" \033[0m "
echo -e "\033[1;34m On OSX: \033[0m"
echo -e "\033[1m export PATH=\"\$PATH:\$HOME/MPI \" \033[0m "
echo -e "\033[1m export DYLD_LIBRARY_PATH=\"\$DYLD_LIBRARY_PATH:\$HOME/MPI/lib\" \033[0m"
if [ x"$platform" = "linux" ]; then
echo -e "\033[1m export PATH=\"\$PATH:\$HOME/MPI \" \033[0m "
echo -e "\033[1m export LD_LIBRARY_PATH=\"\$LD_LIBRARY_PATH:\$HOME/MPI/lib\" \033[0m "
else
echo -e "\033[1m export PATH=\"\$PATH:\$HOME/MPI \" \033[0m "
echo -e "\033[1m export DYLD_LIBRARY_PATH=\"\$DYLD_LIBRARY_PATH:\$HOME/MPI/lib\" \033[0m"
fi
fi
if [ $METIS_installed -eq 1 ]; then
......@@ -119,11 +123,11 @@ if [ $METIS_installed -eq 1 ]; then
echo -e "\033[1;34;5m ---------------- METIS ---------------- \033[0m"
echo -e " METIS has been installed into: \033[1m $HOME/METIS \033[0m"
echo ""
echo -e "\033[1;34m On Linux: \033[0m"
echo -e "\033[1m export LD_LIBRARY_PATH=\"\$LD_LIBRARY_PATH:\$HOME/METIS/lib\" \033[0m "
echo -e "\033[1;34m On OSX: \033[0m"
echo -e "\033[1m export DYLD_LIBRARY_PATH=\"\$DYLD_LIBRARY_PATH:\$HOME/METIS/lib\" \033[0m"
if [ x"$platform" = "linux" ]; then
echo -e "\033[1m export LD_LIBRARY_PATH=\"\$LD_LIBRARY_PATH:\$HOME/METIS/lib\" \033[0m "
else
echo -e "\033[1m export DYLD_LIBRARY_PATH=\"\$DYLD_LIBRARY_PATH:\$HOME/METIS/lib\" \033[0m"
fi
fi
if [ $BOOST_installed -eq 1 ]; then
......@@ -132,12 +136,11 @@ if [ $BOOST_installed -eq 1 ]; then
echo -e "\033[1;34;5m ---------------- BOOST ---------------- \033[0m"
echo -e " BOOST has been installed into: \033[1m $HOME/BOOST \033[0m"
echo ""
echo -e "\033[1;34m On Linux: \033[0m"
echo -e "\033[1m export LD_LIBRARY_PATH=\"\$LD_LIBRARY_PATH:\$HOME/BOOST/lib\" \033[0m "
echo -e "\033[1;34m On OSX: \033[0m"
echo -e "\033[1m export DYLD_LIBRARY_PATH=\"\$DYLD_LIBRARY_PATH:\$HOME/BOOST/lib\" \033[0m"
if [ x"$platform" = "linux" ]; then
echo -e "\033[1m export LD_LIBRARY_PATH=\"\$LD_LIBRARY_PATH:\$HOME/BOOST/lib\" \033[0m "
else
echo -e "\033[1m export DYLD_LIBRARY_PATH=\"\$DYLD_LIBRARY_PATH:\$HOME/BOOST/lib\" \033[0m"
fi
fi
echo ""
echo ""
#! /bin/bash
source script/discover_package_manager
source script/discover_os
platform=unknown
if [[ "$OSTYPE" == "linux-gnu" ]]; then
echo -e "We are on\033[1;34m LINUX \033[0m"
platform=linux
elif [[ "$OSTYPE" == "darwin"* ]]; then
echo -e "We are on\033[1;34m MAC OSX \033[0m"
platform=osx
elif [[ "$OSTYPE" == "cygwin" ]]; then
echo -e "We are on\033[1;34m CYGWIN \033[0m"
echo "This platform is not supported"
exit 1
elif [[ "$OSTYPE" == "msys" ]]; then
echo -e "We are on\033[1;34m Microsoft Window \033[0m"
echo "This platform is not supported"
exit 1
elif [[ "$OSTYPE" == "win32" ]]; then
echo -e "We are on\033[1;34m Microsoft Window \033[0m"
echo "This platform is not supported"
exit 1
elif [[ "$OSTYPE" == "freebsd"* ]]; then
echo -e "We are on\033[1;34m FREEBSD \033[0m"
echo "This platform is not supported"
exit 1
else
echo -e "We are on an\033[1;34m unknown OS \033[0m"
echo "This platform is not supported"
exit 1
fi
discover_os
discover_package_manager $platform
pcman=discover_package_manager_ret
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment