User:Bvictor

From SPCTools

(Difference between revisions)
Jump to: navigation, search
Revision as of 12:56, 24 August 2010
Bvictor (Talk | contribs)

← Previous diff
Revision as of 12:58, 24 August 2010
Bvictor (Talk | contribs)

Next diff →
Line 48: Line 48:
http://sourceforge.net/projects/sashimi/files. http://sourceforge.net/projects/sashimi/files.
-It should unpack automatically and you should have a folder called TPP-4.0.0 in your default download location. Move the folder to your home directory.+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=== ===XML::Parser===
Line 55: Line 55:
In terminal (home directory): In terminal (home directory):
sudo cpan 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 \verb|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'. +(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=== ===Problems with JAVA===

Revision as of 12:58, 24 August 2010

Contents

Important!

  • These guidelines are a simplified 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 Max 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 notice that as I go.
  • 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/system

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).

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://distfiles.macports.org/MacPorts/MacPorts-1.9.1-10.6-SnowLeopard.dmg

Just 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 gwet
   sudo port install coreutils
   sudo port install gd2

Gnuplot was already on my system. I did not need to install it. If you don't have it (terminal: 'which gnuplot'), you can also get it with MacPorts. ('sudo port install gnuplot' should do the trick)

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 already in it) Copy/paste these 2 lines to the bottom of the .profile file:

   JAVA_HOME=/Library/Java/Home
   export JAVA_HOME;

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

Ok, now you should be ready to continue.

Make all

In terminal (home directory):

   cd TPP-4.0.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.0.0/CGI/Makefile

(if that doesn't work, you can 'cd TPP-4.0.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.0.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 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',      					# full path to cp
   'mv'          => '/bin/mv',             			# full path to mv
   'md5'         => '/sbin/md5',     			# full path to md5sum
   'echo'        => '/bin/echo',       			# full path to echo
   'head'        => '/usr/bin/head',      			# full path to head
   'tail'        => '/usr/bin/tail',       		# full path to tail
   'touch'       => '/usr/bin/touch',      		# full path to touch
   'wc'          => '/usr/bin/wc',         		# full path to wc
   'wget'        => '/opt/local/bin/wget',      # full path to wc
   'cygpath'     => 'cygpath',   				# full path to cygpath  -- cygwin only

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 'http://xxx.xxx.x.xx/' address that will appear.

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. I added #... where you might need to make a change.

   ##### 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"	# check/adjust
   <Directory "/usr/local/tpp/schema">	# check/adjust
   AllowOverride None
   Options Includes Indexes FollowSymLinks MultiViews
   Order allow,deny
   Allow from all
   </Directory>
   Alias /tpp/data "/Library/WebServer/Documents/thegpm/tpp/data" # check/adjust
   <Directory "/Library/WebServer/Documents/thegpm/tpp/data"> # check/adjust
   AllowOverride None
   Options Includes Indexes FollowSymLinks MultiViews
   Order allow,deny
   Allow from all
   </Directory>
   Alias /tpp/cgi-bin "/usr/local/tpp/cgi-bin"	# check/adjust
   <Directory "/usr/local/tpp/cgi-bin">	# check/adjust
   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/ # check/adjust
   SetEnv WEBSERVER_URL http://xxx.xxx.x.xx/ # put in the correct numbers.
   </Directory>


In terminal (home directory):

   sudo /usr/sbin/apachectl restart

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

http://xxx.xxx.x.xx/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.

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

Personal tools