TPP:Installing the Trans-Proteomic Pipeline (TPP) 4.4.0 on Mac OS X 10.6.4

From SPCTools

Jump to: navigation, search

Contents

Important!

  • These guidelines are a simplified and updated version of the guidelines you can find here:

http://tools.proteomecenter.org/wiki/index.php?title=TPP:Installing_on_Mac_OSX

  • As stated in the previous version of the guidelines, the TPP is currently not officially supported on Mac OS X.
  • In NO way am I responsible if something goes wrong with your computer, your data or whatever!!!
  • This only covers the installation. I don't know yet if all components are working or not (maybe I forgot some symbolic link here or there...) I'll update the bottom part of this page if I encounter any problems.
  • It is perfectly possible that I have something on my computer that you don't (or vice versa), so what I write here might not work for you. You are welcome to update the file with your version of the installation. It can only be beneficial for future users.

Author

Bjorn Victor

A very big THANK YOU to Ulrich auf dem Keller, for his help, patience and countless emails.

Introduction and updates

This version is aimed towards people who (like me) have limited experience with UNIX.

I'm using Mac OS X 10.6.4 and TPP-4.4.0 (Vuvuzela) on a MacBook Pro (2 GHz Intel Core Duo).

UPDATE: I'm now using 4.4 rev 1. Installation of 4.4 rev 1 was the same as described here for 4.4.0.

UPDATE 2: I've now updated to TPP v4.5 RAPTURE rev 2, Build 201203071418 using the method described here for 4.4.0. My system is now Mac OS 10.6.8 (Snow Leopard).

X!Tandem, PeptideProphet, InterProphet and ProteinProphet work on both the command line and the Petunia GUI. No other functions tested.

For those using Mac OS 10.7 (Lion), it seems necessary to perform additional changes:

- Building on OS X 10.7.3 http://groups.google.com/group/spctools-discuss/browse_thread/thread/a621bd24683b6c3f/535576a9ad354495?lnk=gst&q=4.5.1#535576a9ad354495

- Partial success at build of TPP Rapture Rev 2 on OSX Lion: http://groups.google.com/group/spctools-discuss/browse_thread/thread/22758e20e30c3335

UPDATE 3: I've updated to TPP v4.6 OCCUPY rev 2. System is still 10.6.8. I needed to make this adjustment in order to get the IONS2 Lorikeet viewer to work:

- TPP 4.6.1 problems: ions2 / Lorikeet and iProphet (iModelParser.cgi) plots https://groups.google.com/forum/?fromgroups=#!topic/spctools-discuss/ADPgFv1wtcA

Specifically:

Before running the make all command, I needed to edit this file: src/Visualization/Comet/plot-msms/plot-msms-js.cxx .

Find the lines that print the HTML portion of the Javascript tags (lines 107-116 or so) and change the web paths from:

  printf("   <script type=\"text/javascript\" src=\"/ISB/html/js/jquery.min.js\"></script>\n");

...to something like:

  printf("   <script type=\"text/javascript\" src=\"/tpp/html/js/jquery.min.js\"></script>\n");

...and build again. Note that this path is the web-accessible path, and not the full system path.

What you need

Apple's Developer Tools

These can be found on the installation DVD that came with your mac. It's also available from the Apple website (after a free registration):

http://developer.apple.com/technologies/xcode.html

MacPorts

You can download it here:

http://www.macports.org/install.php

Find the .dmg for your system (mine is Snow Leopard) and follow the instructions on the screen to install it.

When that is done, open terminal (Applications - Utilities - Terminal.app) and type:

   sudo port -v selfupdate

Now you're ready to install the packages. Whenever you are asked to install extra stuff, just say 'yes'.

In terminal (home directory):

   sudo port install wget
   sudo port install coreutils
   sudo port install gd2
   sudo port install gnuplot
   sudo ln -s /opt/local/bin/gnuplot /usr/bin/gnuplot

The TPP

Get the TPP from sourceforge:

http://sourceforge.net/projects/sashimi/files.

It should unpack automatically and you should have a folder called TPP-4.4.0 in your default download location. Move the folder to your home directory.

XML::Parser

I needed to get the XML::Parser from CPAN.

In terminal (home directory):

   sudo cpan

(If you've never done this before, that command will start a configuration process where you can answer all questions with default options. Once finished you should have the cpan shell where you type 'install XML::Parser'. If asked for installing dependencies always say 'yes'. Finally you will get a message if XML::Parser is up to date. Exit the cpan shell by typing 'exit'.

Problems with JAVA

I had lots of problems with JAVA. When typing 'env' in a terminal window of the home directory, JAVA was not on the list. I finally found a solution that worked for me:

In terminal (home directory):

   emacs .profile

(a file should open with some text about Macports already in it) Copy/paste these 2 lines to the bottom of the .profile file:

   JAVA_HOME=/System/Library/Frameworks/JavaVM.framework/Versions/1.6.0/Home
   export JAVA_HOME;

Save and exit emacs (ctrl-x-s; ctrl-x-c)

Then, in terminal, browse to TPP-4.4.0/src and do the same there (although the file will be blank there).

One more change is needed before we continue:

Change TPP-4.0.0/src/Quantitation/Pepc/build.xml line 43

  <property name="jdk.home.1.6" value="${java.home}/.."/> 

to

  <property name="jdk.home.1.6" value="${java.home}"/> 

same in TPP-4.0.0/src/Quantitation/Pepc/PepcView/build.xml line 52

Ok, now you should be ready to continue.

Make all

In terminal (home directory):

   cd TPP-4.4.0/src
   make all

Now you must wait for quite a bit of time while the code scrolls over your screen. When all is done, you should see a few 'BUILD SUCCESSFUL' messages in the last part of the terminal output. If not, my suggestion would be to google the errors you get and ask around at the discussion group

http://groups.google.com/group/spctools-discuss

If successful, you can continue:

In terminal (home directory):

   sudo mkdir /usr/local/tpp
   sudo chmod -R a+rw  /usr/local/tpp
   open TPP-4.4.0/CGI/Makefile

(if that doesn't work, you can 'cd TPP-4.4.0/CGI', then 'open .' (yes, that's "open space dot"). In the finder window, you can open the file with a text editor) You must change line 47 from

   cp -rfu tpp_gui/users/* <math>{CGI_USERS_DIR}

to

   cp -rf tpp_gui/users/* </math>{CGI_USERS_DIR}

since there is no -u flag in OS X.

Make install

In terminal (home directory):

   cd TPP-4.4.0/src
   make install

After that you have to adjust '/usr/local/tpp/cgi-bin/tpp_gui.pl' to match your system.

In terminal (home directory):

   open /usr/local/tpp/cgi-bin/tpp_gui.pl

(or 'cd /usr/local/tpp/cgi-bin', then 'open .' and manually open the 'tpp_gui.pl' with a text editor)

Go to line 47 and modify the path to your tpp/bin. On my system it looks like this:

   my $tppbin = readconfig('tppbin',"/usr/local/tpp/bin/");  # Location of TPP bin

Go to line 56 and modify the paths to match your system (in terminal (home directory), you can type 'which cp', 'which mv', ... to see the path. Below is my system.)

   'chdir'       => 'cd',
   'cp'          => '/bin/cp',      		
   'mv'          => '/bin/mv',             	
   'md5'         => '/sbin/md5',     	
   'echo'        => '/bin/echo',       	
   'head'        => '/usr/bin/head',    
   'tail'        => '/usr/bin/tail',       	
   'touch'       => '/usr/bin/touch',   
   'wc'          => '/usr/bin/wc',         	
   'wget'        => '/opt/local/bin/wget',      
   'cygpath'     => 'cygpath',   			  
   'rm'          => '/bin/rm',       

After this, you must also modify the 'tpp_gui_config.pl' file.

In terminal (home directory):

   open /usr/local/tpp/cgi-bin/tpp_gui_config.pl

Type the lines below somewhere in the middle (you'll see the first line of the code in the file as well).

   # for example, you might want to uncomment the next line to make x!tandem...
   'pipeline'  => 'Tandem',   # one of [Sequest Mascot SpectraST Tandem]  
   'base_dir'  => '/usr/local/tpp/cgi-bin/',
   'tpp_bin_url' => '/tpp/cgi-bin',
   'www_root' => '/Library/WebServer/Documents/thegpm/',
   'data_dir' => '/Library/WebServer/Documents/thegpm/tpp/data',

then, in terminal (home directory):

   mkdir /Library/WebServer/Documents/thegpm
   cd /Library/WebServer/Documents/thegpm
   mkdir tpp
   cd tpp
   mkdir data 
   cd ~
   sudo chown -R www /Library/WebServer/Documents/thegpm/tpp/data

(the 'thegpm' folder is really not needed, but not wrong as well. I did not realise that at the time I was installing the TPP. However, in the next file you're about to edit, you'll see the 'thegpm' folder a few times, so if you leave it out now, you'll need to leave it out later as well!)

Open your system preferences and go to sharing. Check the Web sharing box and write down the 'xxxxxxx.local' address that is found at the top of the window (next to the edit button).

The apache2 config file

Get textwrangler

http://www.barebones.com/products/textwrangler

This editor allows you to edit locked files by giving your sudo credentials. Open TextWrangler and use 'Open file by name' to open '/etc/apache2/httpd.conf'

In '/private/etc/apache2/httpd.conf', edit the 'DocumentRoot' and also the '<Directory' some lines below:

   # DocumentRoot: The directory out of which you will serve your
   # documents. By default, all requests are taken from this directory, but
   # symbolic links and aliases may be used to point to other locations.
   #
   DocumentRoot "/Library/WebServer/Documents/thegpm"
   ...
   #
   # This should be changed to whatever you set DocumentRoot to.
   #
   <Directory "/Library/WebServer/Documents/thegpm">
   #
   

Now scroll to the end of the file and append this piece of code. You must also check/adjust all the info in the text.

##### Added for TPP ######
  Alias /tpp/html "/usr/local/tpp/html"
  <Directory "/usr/local/tpp/html">
   AllowOverride None
  Options Includes Indexes FollowSymLinks MultiViews
  Order allow,deny
  Allow from all
  </Directory>
  Alias /tpp/schema "/usr/local/tpp/schema"	
  <Directory "/usr/local/tpp/schema">	
  AllowOverride None
  Options Includes Indexes FollowSymLinks MultiViews
  Order allow,deny
  Allow from all
  </Directory>
  Alias /tpp/data "/Library/WebServer/Documents/thegpm/tpp/data" 
  <Directory "/Library/WebServer/Documents/thegpm/tpp/data"> 
  AllowOverride None
  Options Includes Indexes FollowSymLinks MultiViews
  AddType text/html .shtml
  AddHandler server-parsed .shtml
  Order allow,deny
  Allow from all
  </Directory>
  Alias /tpp/cgi-bin "/usr/local/tpp/cgi-bin"	
  <Directory "/usr/local/tpp/cgi-bin">	
  AllowOverride None
  Options ExecCGI Includes Indexes FollowSymLinks MultiViews
  AddHandler cgi-script .pl .cgi
  Order allow,deny
  Allow from all
  SetEnv WEBSERVER_ROOT /Library/WebServer/Documents/thegpm/ 
  SetEnv WEBSERVER_URL http://**********.local  
  SetEnv WEBSERVER_TMP /tmp/ 
  </Directory>

It may be necessary to restart the apache server. This should do the trick:

   sudo /usr/sbin/apachectl restart

Now, in safari, enter this link (with correct numbers!!)

http://xxxxxx.local/tpp/cgi-bin/tpp_gui.pl

If all went well, you should have the TPP in front of you. You can log in as guest (pw = guest).

If all is not well, I direct you to the google discussion group or the section below.

http://groups.google.com/group/spctools-discuss

Problems and how to fix them

  • Error 1: Unable to access xml file via webserver, so cannot check xml file for changes ()

Fixed by Ulrich: open /usr/local/tpp/html/PepXMLViewer.html and change line 115 from

   document.getElementById('msgs').innerHTML += "
(URL: " + http_req.url + ")";

to

   document.getElementById('msgs').innerHTML += "
(URL: " + http_req.url ")";
  • Error 2: When trying to use the GUI for, say, X!Tandem, the GUI complains that it cannot find the tandem command.

In terminal (home directory) check if env contains the path to the tpp. You should see this somewhere in the path: /usr/local/tpp/bin. If you do not, type "emacs .profile" and add this to it: "export PATH=/usr/local/tpp/bin:$PATH". Close with ctrl X+S and ctrl X+C.

Personal tools