Created
June 7, 2012 09:10
-
-
Save tetsuok/2887723 to your computer and use it in GitHub Desktop.
Build script for Rampion.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh -x | |
| # Build script for Rampion (Gimpel & Smith, NAACL 2012). | |
| # | |
| # Tested rampion v0.1 on Mac OS X 10.7 and Linux. | |
| src=rampion-v0.1.tar.gz | |
| url=http://www.ark.cs.cmu.edu/MT/$src | |
| # detect os, and set the number of jobs to run make. | |
| ncpu= | |
| downloader= | |
| case `uname -s` in | |
| Darwin) | |
| ncpu=4 | |
| downloader="curl -O" | |
| ;; | |
| Linux) | |
| ncpu=20 | |
| downloader=wget | |
| ;; | |
| *) | |
| echo "Unknown platform!" | |
| exit 1 | |
| esac | |
| # Fetch code. | |
| $downloader $url | |
| tar zxvf $src | |
| cd rampion-v0.1 | |
| # First build google-sparsehash. | |
| tar zxvf sparsehash-2.0.2.tar.gz | |
| cd sparsehash-2.0.2 | |
| ./configure --prefix=`pwd`/../external | |
| make -j$ncpu && make check && make install | |
| # Now build rampion | |
| cd ../src | |
| make -j$ncpu |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment