From 35f5168c82cc5130becf17eda20bf8f6bb3c73eb Mon Sep 17 00:00:00 2001 From: Greg DiCristofaro Date: Mon, 27 Sep 2021 19:50:26 -0400 Subject: [PATCH] updates and remove unused comments --- .../scripts/install_autopsy_from_zip.sh | 1 + installation/scripts/install_prereqs_osx.sh | 18 +----- .../scripts/install_prereqs_ubuntu.sh | 63 +------------------ installation/scripts/install_tsk_from_src.sh | 1 - unix_setup.sh | 2 +- 5 files changed, 7 insertions(+), 78 deletions(-) diff --git a/installation/scripts/install_autopsy_from_zip.sh b/installation/scripts/install_autopsy_from_zip.sh index 272a7cd4f2..f195e612c6 100644 --- a/installation/scripts/install_autopsy_from_zip.sh +++ b/installation/scripts/install_autopsy_from_zip.sh @@ -76,4 +76,5 @@ if [[ $? -ne 0 ]]; then exit 1 else echo "Autopsy setup done." + echo "Autopsy can be launched at $AUTOPSY_EXTRACTED_PATH/bin/autopsy" fi diff --git a/installation/scripts/install_prereqs_osx.sh b/installation/scripts/install_prereqs_osx.sh index 9553631fa0..7a3e90cc4c 100644 --- a/installation/scripts/install_prereqs_osx.sh +++ b/installation/scripts/install_prereqs_osx.sh @@ -18,19 +18,5 @@ then exit 1 fi -OPEN_JDK_LN=/usr/local/opt/openjdk && \ -rm $ && \ -ln -s $JAVA_HOME $OPEN_JDK_LN -if [[ $? -ne 0 ]] -then - echo "Unable to properly set up $OPEN_JDK_LN." >> /dev/stderr - exit 1 -fi - -# Test your link file creation to ensure it is pointing at the correct java developement kit: -echo "/usr/local/opt/openjdk now is:" -ls -l /usr/local/opt/openjdk - -# check version -echo "Java Version is:" -java -version \ No newline at end of file +java_path=$(/usr/libexec/java_home -v 1.8) +echo "Java 1.8 path: $java_path" \ No newline at end of file diff --git a/installation/scripts/install_prereqs_ubuntu.sh b/installation/scripts/install_prereqs_ubuntu.sh index 6ec2e1534e..f2217dae3f 100644 --- a/installation/scripts/install_prereqs_ubuntu.sh +++ b/installation/scripts/install_prereqs_ubuntu.sh @@ -10,13 +10,6 @@ if [[ $? -ne 0 ]]; then fi echo "Installing all apt dependencies..." -# other possible dependencies taken from https://github.com/sleuthkit/autopsy/pull/4743/files -# sudo apt -y install ca-certificates g++ gcc gpg java-common libafflib-dev libboost-dev libgl1-mesa-dri libgl1-mesa-glx libsolr-java libsqlite3-dev libswt-gtk-4-java libtika-java openjfx postgresql software-properties-common sqlite3 wget zip zlib1-dev - -# other possible dependencies taken from https://github.com/sleuthkit/autopsy/pull/5111/files -# sudo apt -y install autopoint libsqlite3-dev libcppunit-dev - -# TODO multi user dependencies? sudo apt update && sudo apt -y build-dep imagemagick libmagickcore-dev && sudo apt -y install build-essential autoconf libtool git-core automake git zip wget ant \ @@ -32,46 +25,6 @@ if [[ $? -ne 0 ]]; then exit 1 fi -# echo "Cloning source for libde265 and libheif..." -# pushd /usr/src/ && \ -# sudo git clone https://github.com/strukturag/libde265.git && \ -# sudo git clone https://github.com/strukturag/libheif.git && \ -# popd -# if [[ $? -ne 0 ]] -# then -# popd -# echo "Failed to retrieve libde265 and libheif repos" >> /dev/stderr -# exit 1 -# fi - -# echo "Installing libde265..." -# pushd /usr/src/libde265/ && \ -# sudo ./autogen.sh && \ -# sudo ./configure && \ -# sudo make && \ -# sudo make install && \ -# popd -# if [[ $? -ne 0 ]] -# then -# popd -# echo "Failed to install libde265" >> /dev/stderr -# exit 1 -# fi - -# echo "Installing libheif..." -# pushd /usr/src/libheif/ && \ -# sudo ./autogen.sh && \ -# sudo ./configure && \ -# sudo make && \ -# sudo make install && \ -# popd -# if [[ $? -ne 0 ]] -# then -# popd -# echo "Failed to install libheif" >> /dev/stderr -# exit 1 -# fi - echo "Installing ImageMagick..." pushd /usr/src/ && sudo wget https://www.imagemagick.org/download/ImageMagick.tar.gz && @@ -106,16 +59,6 @@ if [[ $? -ne 0 ]]; then exit 1 fi -# https://unix.stackexchange.com/questions/117467/how-to-permanently-set-environmental-variables -# echo "Setting JAVA_HOME..." -# export JAVA_HOME=/usr/lib/jvm/bellsoft-java8-full-amd64 && \ -# echo "Java home is now: $JAVA_HOME" && \ -# echo 'export JAVA_HOME=/usr/lib/jvm/bellsoft-java8-full-amd64' | tee ~/.profile ~/.bashrc -# if [[ $? -ne 0 ]] -# then -# echo "Failed to set up JAVA_HOME in bash_rc" >> /dev/stderr -# exit 1 -# fi - -# echo "Java version is:" -# java -version +echo "Autopsy prerequisites installed." +echo "Java path at /usr/lib/jvm/bellsoft-java8-full-amd64: " +ls /usr/lib/jvm/bellsoft-java8-full-amd64 \ No newline at end of file diff --git a/installation/scripts/install_tsk_from_src.sh b/installation/scripts/install_tsk_from_src.sh index 01a8947047..f497d2e290 100644 --- a/installation/scripts/install_tsk_from_src.sh +++ b/installation/scripts/install_tsk_from_src.sh @@ -53,7 +53,6 @@ fi echo "Installing Sleuthkit..." pushd $SLEUTHKIT_SRC_DIR && - # export CPPFLAGS="-I/usr/local/opt/libpq/include" && \ ./bootstrap && ./configure && make && diff --git a/unix_setup.sh b/unix_setup.sh index 79d857a1c1..8f4c5c3480 100644 --- a/unix_setup.sh +++ b/unix_setup.sh @@ -45,7 +45,7 @@ fi # Verify Java was installed and configured echo -n "Checking for Java..." -if [ -n "$JAVA_PATH"]; then +if [ -n "$JAVA_PATH" ]; then if [ -x "$JAVA_PATH/bin/java" ]; then sed -Ei '/^#?\s*jdkhome=/d' etc/autopsy.conf echo "jdkhome=$JAVA_PATH" >> etc/autopsy.conf