Skip to content

Commit

Permalink
fix ballgown install
Browse files Browse the repository at this point in the history
  • Loading branch information
mjoppich committed May 15, 2019
2 parents aef0009 + 62e50ba commit 71cf890
Show file tree
Hide file tree
Showing 21 changed files with 222 additions and 84 deletions.
40 changes: 23 additions & 17 deletions install_templates/install_apple_first.igui
Original file line number Diff line number Diff line change
Expand Up @@ -4,31 +4,37 @@ echo "First Time Mac OS Setup"

if [ "$(uname)" == "Darwin" ]; then

echo "Dependencies: pip "
echo "Installing Dependencies"

if [ ! "$2" = "" ]; then

HASPORTS=`which port`
if [ -z "$HASPORTS" ]
then
(>&2 echo "PLEASE INSTALL MACPORTS FIRST")
(>&2 echo "YOU CAN DOWNLOAD MACPORTS FROM")
source ~/.bashrc
source ~/.bash_profile

HASBREW=`which brew`

if [ -z "$HASBREW" ]; then

(>&2 echo "PLEASE INSTALL homebrew FIRST")
(>&2 echo "YOU CAN DOWNLOAD homebrew FROM")
(>&2 echo "")
(>&2 echo "https://www.macports.org/")
(>&2 echo "https://brew.sh")
(>&2 echo "")
(>&2 echo "If you installed homebrew and this warning persists run brew doctor")
(>&2 echo "and add brew to your PATH: echo \'export PATH=\"/usr/local/bin:\$PATH\"\' >> ~/.bash_profile")
else
echo "Installing dependencies: gcc@8, pip, python3, pip3"

echo $2 | sudo -S mkdir -p /usr/local/lib
echo $2 | sudo -S mkdir -p /usr/local/Frameworks

echo "Installing dependencies: Mac pip, python36, pip36 as python3 and pip3"
echo $2 | sudo -S easy_install pip

echo $2 | sudo -S port -N install python36
echo $2 | sudo port select --set python3 python36

echo $2 | sudo -S port -N install py36-pip
echo $2 | sudo -S port select --set pip3 pip36
echo $2 |sudo chown -R $(whoami) $(brew --prefix)/*
brew install gcc@8 python3

echo $2 | sudo -S port -N install wget gcc8
curl https://bootstrap.pypa.io/get-pip.py -o /tmp/get-pip.py
python3 /tmp/get-pip.py

echo "Enjoy bioGUI!"
echo "Enjoy bioGUI!"

fi

Expand Down
4 changes: 2 additions & 2 deletions install_templates/install_ballgown.igui
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ if [ ! "$2" = "" ]; then

echo "Dependencies: $DEP_PACKAGES R: devtools, RSkittleBrewer, ballgown"
echo $2 | sudo -S apt-get update
echo $2 | sudo -S apt-get install $DEP_PACKAGES
echo $2 | sudo -S apt-get -y install r-base zlibc zlib1g zlib1g-dev libxml2-dev libcurl4-openssl-dev

fi

Expand All @@ -26,7 +26,7 @@ echo "options(repos = c(CRAN = \"https://cran.rstudio.com\"))" > ~/.Rprofile
RLIBSUSER=`Rscript -e "cat(Sys.getenv('R_LIBS_USER'))"`
mkdir -p $RLIBUSER

Rscript -e "source(\"http://bioconductor.org/biocLite.R\"); install.packages(\"devtools\"); devtools::install_github('alyssafrazee/RSkittleBrewer'); biocLite(\"ballgown\", lib.loc=Sys.getenv('R_LIBS_USER'), lib=Sys.getenv('R_LIBS_USER'));"
Rscript -e "source(\"http://bioconductor.org/biocLite.R\"); install.packages(\"devtools\"); install.packages(\"dplyr\"); devtools::install_github('alyssafrazee/RSkittleBrewer'); biocLite(\"ballgown\", lib.loc=Sys.getenv('R_LIBS_USER'), lib=Sys.getenv('R_LIBS_USER'));"

RSCRIPT=`which Rscript`

Expand Down
22 changes: 12 additions & 10 deletions install_templates/install_bowtie1.igui
Original file line number Diff line number Diff line change
@@ -1,22 +1,24 @@
#! Install Bowtie1

if [ "$(uname)" == "Darwin" ]; then
source ~/.bash_profile
else
echo ""
fi

if [ ! "$2" = "" ]; then

if [ "$(uname)" == "Darwin" ]; then

echo "Installing brew gcc"
brew install gcc

echo "bowtie1 install module is not compatible with Mac OS. Use bowtie2"
exit;

else

echo "Installing dependencies"
echo $2 | sudo -S apt-get update
echo $2 | sudo -S apt-get -y install python

pip install numpy scipy pysam
fi
echo "Installing dependencies"
echo $2 | sudo -S apt-get update
echo $2 | sudo -S apt-get -y install libtbb-dev
fi

else
echo "No sudo password, not installing dependencies"
Expand Down Expand Up @@ -64,7 +66,7 @@ if [ $# -gt 2 ]; then
fi

APPBINARYESC="${PROGDIRESC}/${PROG}/"
APPBINARY="${PROGDIRESC}/${PROG}/bowtie"
APPBINARY="${PROGDIRESC}/${PROG}/bowtie-align-s"
if [ -z "$(ls -A ${APPBINARYESC})" ] || [ ! -f ${APPBINARY} ]; then
(>&2 echo ${APPBINARYESC})
(>&2 ls ${APPBINARYESC})
Expand Down
17 changes: 11 additions & 6 deletions install_templates/install_bowtie2.igui
Original file line number Diff line number Diff line change
@@ -1,14 +1,17 @@
#! Install Bowtie2 2.2.9

if [ "$(uname)" == "Darwin" ]; then
source ~/.bash_profile
else
echo ""
fi

if [ ! "$2" = "" ]; then

if [ "$(uname)" == "Darwin" ]; then

echo "Installing brew gcc tbb"
brew install gcc tbb

alias gcc='gcc-8'
alias g++='g++-8'
echo "Installing brew wget gcc@8 tbb"
brew install wget gcc@8 tbb


else
Expand Down Expand Up @@ -38,6 +41,8 @@ fi
## create progdir
mkdir -p "$PROGDIR"

rm -rf ${PROGDIR}/${PROG}/

#download and unzip
wget https://sourceforge.net/projects/bowtie-bio/files/bowtie2/2.3.4.3/bowtie2-2.3.4.3-source.zip/download -O "$PROGDIR/$PROG.zip"

Expand Down Expand Up @@ -65,7 +70,7 @@ fi


APPBINARYESC="${PROGDIRESC}/${PROG}/"
APPBINARY="${PROGDIRESC}/${PROG}/bowtie2"
APPBINARY="${PROGDIRESC}/${PROG}/bowtie2-align-s"
if [ -z "$(ls -A ${APPBINARYESC})" ] || [ ! -f ${APPBINARY} ]; then
(>&2 echo ${APPBINARYESC})
(>&2 ls ${APPBINARYESC})
Expand Down
10 changes: 8 additions & 2 deletions install_templates/install_bwa.igui
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
#! Install bwa 0.7.17 (sourceforge)

if [ "$(uname)" == "Darwin" ]; then
source ~/.bash_profile
else
echo ""
fi

if [ ! "$2" = "" ]; then

if [ "$(uname)" == "Darwin" ]; then

echo "Installing brew gcc tbb"
brew install gcc tbb
echo "Installing brew gcc@8"
brew install gcc@8

else

Expand Down
19 changes: 13 additions & 6 deletions install_templates/install_featurecounts.igui
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
#! Install featureCounts (github)


if [ "$(uname)" == "Darwin" ]; then
source ~/.bash_profile
else
echo ""
fi

if [ ! "$2" = "" ]; then

if [ "$(uname)" == "Darwin" ]; then

echo "Installing brew gcc"
brew install gcc

alias gcc='gcc-8'
alias g++='g++-8'
brew install gcc@8

else

Expand Down Expand Up @@ -57,7 +58,13 @@ mv */* .
cd "$PROGDIR/$PROG/src"

if [ "$(uname)" == "Darwin" ]; then
make -f Makefile.MacOS
echo "Compile MAC OS"

echo "Modifying Makefile.MacOS"
sed -i '' 's/CC \= gcc/CC \= \$\{GCC\}/g' Makefile.MacOS

echo "Compiling subread"
LDFLAGS="-L/usr/local/lib" CPPFLAGS="-I/usr/local/include/" make -f Makefile.MacOS GCC=gcc-8 CC_EXEC=gcc-8
else
make -f Makefile.Linux
fi
Expand Down
8 changes: 6 additions & 2 deletions install_templates/install_graphmap.igui
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
#! Install graphmap (github))


if [ "$(uname)" == "Darwin" ]; then
source ~/.bash_profile
else
echo ""
fi

if [ ! "$2" = "" ]; then

if [ "$(uname)" == "Darwin" ]; then

echo "Installing brew gcc"
brew install gcc
brew install gcc@8

alias gcc='gcc-8'
alias g++='g++-8'
Expand Down
18 changes: 14 additions & 4 deletions install_templates/install_hisat.igui
Original file line number Diff line number Diff line change
@@ -1,11 +1,21 @@
#! Install hisat2 (github)

if [ "$(uname)" == "Darwin" ]; then
source ~/.bash_profile
else
echo ""
fi

if [ ! "$2" = "" ]; then

if [ "$(uname)" == "Darwin" ]; then

echo "Installing brew gcc"
brew install gcc
echo "Installing brew gcc gawk"
echo "Installing gawk only for libmpfr.4.dylib ..."
brew install gcc@8 gawk

alias gcc='gcc-8'
alias g++='g++-8'

alias gcc='gcc-8'
alias g++='g++-8'
Expand Down Expand Up @@ -106,8 +116,8 @@ fi

$NCCMD <<EOF

<template description="hisat2 2.1.0 aligner" title="hisat2 2.1.0">
<window title="hisat2 2.1.0 aligner">
<template description="hisat2 aligner (github)" title="hisat2 (github)">
<window title="hisat2 aligner (github)">
<vgroup>

<group title="Alignment Information">
Expand Down
24 changes: 21 additions & 3 deletions install_templates/install_mm_asm_racon.igui
Original file line number Diff line number Diff line change
@@ -1,11 +1,17 @@
#! Install minimap2/miniasm/racon (github)

if [ "$(uname)" == "Darwin" ]; then
source ~/.bash_profile
else
echo ""
fi

if [ ! "$2" = "" ]; then

if [ "$(uname)" == "Darwin" ]; then

echo "Installing Dependencies (mac)"
brew install cmake gcc
brew install cmake gcc@8
else

echo "Installing Dependencies (aptitude/Ubuntu)"
Expand Down Expand Up @@ -41,11 +47,23 @@ mkdir -p "$PROGDIR/$PROG"

cd "$PROGDIR/$PROG"
git clone https://github.com/lh3/minimap2 minimap2
cd minimap2 && make
cd minimap2

if [ "$(uname)" == "Darwin" ]; then
make CC=gcc-8
else
make
fi

cd "$PROGDIR/$PROG"
git clone https://github.com/lh3/miniasm miniasm
cd miniasm && make
cd miniasm

if [ "$(uname)" == "Darwin" ]; then
make CC=gcc-8
else
make
fi

cd "$PROGDIR/$PROG"
git clone --recursive https://github.com/isovic/racon.git racon
Expand Down
22 changes: 16 additions & 6 deletions install_templates/install_msempire.igui
Original file line number Diff line number Diff line change
@@ -1,19 +1,25 @@
#! Install ms-EmpiRe

if [ "$(uname)" == "Darwin" ]; then

echo "This Install Module is not compatible with Mac OS. If desperately needed, contact bioGUI authors."
exit
source ~/.bash_profile
else
echo ""
fi

echo "Dependencies: r-base"
if [ ! "$2" = "" ]; then

if [ "$(uname)" == "Darwin" ]; then

echo "Installing R"
echo "Installing R and setting PATH for R libraries"
brew install gcc
brew link --overwrite gcc
brew install openblas
brew install libgit2 libxml2 openssl
brew install r

CC=clang CXX=clang++ Rscript -e 'install.packages("git2r", repos="https://cran.cnr.berkeley.edu/")'

else

echo "Installing dependencies"
Expand All @@ -39,14 +45,18 @@ fi
PROGDIRESC=$(echo $PROGDIR | sed 's/ /\\ /g')
APPBINARYDIR="${PROGDIR}/${PROG}/"

rm -rf "$PROGDIR/$PROG"

## create progdir
mkdir -p "$PROGDIR/$PROG"

cd "$PROGDIR/$PROG"

wget https://gist.githubusercontent.com/mjoppich/e4e9f0c706ac93737fdc0f64642b9ef1/raw/a8c03cf3ea0909a52e431c668d797482d1fd774b/runEmpire.R
wget https://gist.githubusercontent.com/mjoppich/e4e9f0c706ac93737fdc0f64642b9ef1/raw/a163610e0a7f1b3d70bdc594921b5a3a25294a2a/runEmpire.R

LDFLAGS="-L/usr/local/opt/openblas/lib" CPPFLAGS="-I/usr/local/opt/openblas/include" Rscript runEmpire.R

RSCRIPTPATH=`which Rscript`

if [ $# -gt 2 ]; then

Expand Down Expand Up @@ -142,7 +152,7 @@ $NCCMD <<EOF

<const id="bindir">${APPBINARYDIR}/</const>

<execute program="run_msempire" location="" exec="Rscript" param="\${bindir}/runEmpire.R \${msempire_expression_rel} \${msempire_pdata_rel} \${msempire_output_rel} \${msempire_sample_regex}" wsl="WSLsel">
<execute program="run_msempire" location="" exec="$RSCRIPTPATH" param="\${bindir}/runEmpire.R \${msempire_expression_rel} \${msempire_pdata_rel} \${msempire_output_rel} \${msempire_sample_regex}" wsl="WSLsel">
<output type="COUT" color="green" to="outputstream1" />
<output type="CERR" color="red" to="outputstream2" />
</execute>
Expand Down
4 changes: 2 additions & 2 deletions install_templates/install_pureseqtm.igui
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ if [ ! "$2" = "" ]; then

echo $2 | sudo -S dpkg --add-architecture i386
echo $2 | sudo -S apt-get update
echo $2 | sudo -S apt-get install libc6:i386 libncurses5:i386 libstdc++6:i386 gcc-multilib
echo $2 | sudo -S apt-get -y install libc6:i386 libncurses5:i386 libstdc++6:i386 gcc-multilib

fi

Expand Down Expand Up @@ -166,7 +166,7 @@ $NCCMD <<EOF
<if comp="IS_SET" value1="pureseqtm_plot" sep=" "><const>-P 1</const></if>
</add>

<execute program="run_pureseqtm" location="" exec="sh" param="\${bindir}/PureseqTM.sh \${cl} wsl="WSLsel">
<execute program="run_pureseqtm" location="" exec="sh" param="\${bindir}/PureseqTM.sh" \${cl} wsl="WSLsel">
<output type="FILE_STD" color="green" location="\${pureseqtm_output}" />
<output type="CERR" color="red" to="outputstream2" />
</execute>
Expand Down

0 comments on commit 71cf890

Please sign in to comment.