diff --git a/Makefile b/Makefile index 071f7fc..b2382e6 100644 --- a/Makefile +++ b/Makefile @@ -1,17 +1,21 @@ all: PhyloCSF -.PHONY: PhyloCSF CamlPaml cde-package CDE clean +.PHONY: PhyloCSF CamlPaml twt cde-package CDE clean ARCH := $(shell uname).$(shell uname -m) PHYLOCSF_BASE := $(shell pwd) export PHYLOCSF_BASE PhyloCSF: CamlPaml - cd src; $(MAKE) clean; $(MAKE) $(MFLAGS) + cd src; $(MAKE) clean; PATH=$(PATH):$(CURDIR)/twt $(MAKE) $(MFLAGS) cp src/_build/PhyloCSF.native PhyloCSF.$(ARCH) -CamlPaml: - cd lib/CamlPaml; $(MAKE) $(MFLAGS) reinstall +CamlPaml: twt + cd lib/CamlPaml; PATH=$(PATH):$(CURDIR)/twt $(MAKE) $(MFLAGS) reinstall + +twt: + git submodule update --init + cd twt && $(MAKE) cde-package: PhyloCSF CDE rm -rf cde-package cde-package.$(ARCH) @@ -30,4 +34,5 @@ clean: cd src; $(MAKE) clean rm -f PhyloCSF.* rm -rf cde-package* - cd CDE && $(MAKE) clean || true \ No newline at end of file + cd twt && $(MAKE) clean || true + cd CDE && $(MAKE) clean || true diff --git a/README b/README index 1f13453..a6ac663 100644 --- a/README +++ b/README @@ -37,14 +37,14 @@ ocaml-findlib libocamlgsl-ocaml-dev libbatteries-ocaml-dev make * Objective Caml 3.11+, with native code compiler * OCaml findlib * OCaml Batteries Included 1.20+ -* ocamlgsl 0.60+ +* ocamlgsl 0.60 * These can be set up using GODI: http://godi.camlcity.org/ [2] Configure OCaml findlib If you installed findlib (OCaml's package manager) using the Ubuntu -packages, or any other method that led to system-wide installation, you +packages, or another method that led to system-wide installation, you must set some environment variables to make it use a directory to which you have write access. (Alternatively, you can complete the subsequent steps as root, e.g. using sudo) @@ -60,26 +60,7 @@ To verify your configuration, run "Packages will be installed in" should be a directory you can write to, and that same directory should appear in "Search path". -[3] Install ocaml+twt - -The code is written in a dialect of OCaml for which you must install a -preprocessor from: http://people.csail.mit.edu/mikelin/ocaml+twt/ -Download the tarball, extract it, and run - - make install INSTALLDIR=$HOME/directory/in/your/PATH - -or- - sudo make install - -If you obtained this PhyloCSF source distribution by cloning the git -repository, ocaml+twt is available as a submodule. You can run - - git submodule init - git submodule update - cd twt - -and then one of the above 'make install' commands. - -[4] Compile PhyloCSF +[3] Compile PhyloCSF Now just run 'make' in this directory. This will build and install the CamlPaml library, then compile the PhyloCSF executable and copy it to