Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

...

eXpress

...

build

...

instructions

...

on

...

TACC

...

Ranger (in the bash shell)

author's

...

installation

...

instructions:

...

http://bio.math.berkeley.edu/eXpress/tutorial.html#install

...

A few of these commands, like "export" are bash specific commands.  Rather than make this installation guide a shell independent novel, I'll ask users to either translate those commands to your shell of choice or switch to bash (by typing bash at the command line) before proceeding.

On Ranger and Lonestar, we don't need to install cmake or boost, already have that as a module

Setup environment:
Code Block
module swap $TACC_FAMILY_COMPILER gcc
module load cmake
module load boost
{code}

h5. Download source for eXpress and BamTools (both links are availabe in the 
Download source for eXpress and BamTools (both links are availabe in the "author's

...

installation

...

instructions"

...

link

...

above)

...

Code Block
wget http://bio.math.berkeley.edu/eXpress/downloads/express-1.1.01/express-1.1.01-src.tgz
tar zxvf express-1.1.0-src*.tgz
cd ./express*/


# Remember where eXpress unpacked itself
export MY_EXPRESS_DIR=`pwd`

# Download BamTools from github
wget --no-check-certificate https://github.com/downloads/pezmaster31/bamtools/bamtools-1.0.2.tar.gz


# extract BamTools into $MY_EXPRESS_DIR
then install

tar zxvf bamtools-1.0.2*.tar.gz


# strip off the version number from the bamtools cddirectory
mv ./bamtools*/ # Remember where BamTools unpacked itself
./bamtools/
cd ./bamtools
export MY_BAMTOOLS_DIR=`pwd`
{code}

h5. Build bamtools

{code}
Build bamtools
Code Block
cd $MY_BAMTOOLS_DIR
mkdir build
cd build
cmake ..
make
{code}

h5. Build and Install eXpress

{code}
Start building eXpress
Code Block
cd $MY_EXPRESS_DIR/src
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX:PATH=$MY_EXPRESS_DIR ../src
{code}
\# cmake 

cmake doesn't

...

do

...

a

...

good

...

job

...

of

...

building

...

the

...

file

...

"$EXPRESS_DIR/src/build/CMakeFile/express.dir/link.txt"

...

it

...

ignores

...

the

...

links

...

needed

...

for

...

BamTools

...

and

...

Boost,

...

but

...

we

...

can

...

fix

...

that

...

!

This little script is not the prettiest way to do this, but it works as a "cut and paste" way to add what is missing while reusing what we can to make this work on both Ranger and Lonestar.  There's probably a better way to do this within cmake.

Code Block

cp ./CMakeFiles/express.dir/bundleslink.otxt CMakeFiles/express.dir/fld.o CMakeFiles/express.dir/fragments.o CMakeFiles/express.dir/main.o CMakeFiles/express.dir/mapparser.o CMakeFiles/express.dir/markovmodel.o CMakeFiles/express.dir/mismatchmodel.o CMakeFiles/express.dir/robertsfilter.o CMakeFiles/express.dir/sequence.o CMakeFiles/express.dir/targets.o CMakeFiles/express.dir/threadsafety.o \-o express \-rdynamic \-Wl,-rpath,/work/01863/benni/express-1.1.0-src/bamtools/lib \-L/work/01863/benni/express-1.1.0-src/bamtools/lib \-lbamtools \-L/opt/apps/gcc4_4/boost/1.48.0/lib \-lboost_filesystem \-lboost_thread \-lboost_system \-lboost_program_options \-lpthread" > $EXPRESS_DIR/src/build/CMakeFile/express.dir/link.txt 


Edit: I want a way to edit this file, not just overwrite it.  This is a work in progress:

cat link.txt \| sed \link.txt.original
cat ./CMakeFiles/express.dir/link.txt.original|sed -r "s/\s+/\n/g" \| awk \-v TACC_BOOST_INC=$TACC_BOOST_INC 'BEGIN -v TACC_BOOST_LIB=$TACC_BOOST_LIB -v MY_BAMTOOLS_DIR=$MY_BAMTOOLS_DIR 'NR==1{print $0;printf "-II%s\n",TACC_BOOST_INC}; NR>1{print};/rdynamic/ {exit}; END{print}'


{code}
echo "`which c++` -I/opt/apps/gcc4_4/boost/1.48.0/include CMakeFiles/express.dir/biascorrection.o CMakeFiles/express.dir/bundles.o CMakeFiles/express.dir/fld.o CMakeFiles/express.dir/fragments.o CMakeFiles/express.dir/main.o CMakeFiles/express.dir/mapparser.o CMakeFiles/express.dir/markovmodel.o CMakeFiles/express.dir/mismatchmodel.o CMakeFiles/express.dir/robertsfilter.o CMakeFiles/express.dir/sequence.o CMakeFiles/express.dir/targets.o CMakeFiles/express.dir/threadsafety.o -o express -rdynamic -printf "-Wl,-rpath,/work/01863/benni/express-1.1.0-src/bamtools/%s/lib -L/work/01863/benni/express-1.1.0-src/bamtools/L%s/lib -lbamtools -L%s/opt/apps/gcc4_4/boost/1.48.0/liblib/libbamtools.a -L%s -lboost_filesystem -lboost_thread -lboost_system -lboost_program_options -lpthread\n",MY_BAMTOOLS_DIR,MY_BAMTOOLS_DIR,MY_BAMTOOLS_DIR,TACC_BOOST_LIB;}' | tr '\n' ' ' | xargs echo > $EXPRESS_DIR./srcCMakeFiles/build/CMakeFile/express.dir/link.txt
{code}
Finish installing eXpress
Code Block
make CXX_FLAGS="-I$TACC_BOOST_INC \-I../bamtools*/include"-I$MY_BAMTOOLS_DIR/include"
make install

This should put a binary executable called "express" in your $MY_EXPRESS_DIR/bin directory.