Skip to content

Installing RandLM on Ubuntu

January 16, 2014
  1. Get RandLM source from here http://sourceforge.net/projects/randlm/
  2. Installing some dependencies
    sudo apt-get install sparsehash
  3. Extracting
    mkdir -p /usr/local/src/randlm
    sudo chown username /usr/local/src/randlm/
    tar -xvzf randlm.tar.gz -C /usr/local/src/randlm/
  4. Compiling
    sudo mkdir -p /usr/local/lib/randlm
    sudo chown username /usr/local/lib/randlm
    ./configure --prefix=/usr/local/lib/randlm
    mv aclocal.m4 aclocal.m4_
    aclocal
    autoconf
    make
  5. Installing
    make install
    cp hadoop/m_compute_ngram_counts_batch /usr/local/lib/randlm/bin
    cp hadoop/r_compute_ngram_counts /usr/local/lib/randlm/bin
    cp hadoop/m_compute_ngram_counts_batch /usr/local/lib/randlm/bin/m-compute-ngram-counts-batch
    cp hadoop/r_compute_ngram_counts /usr/local/lib/randlm/bin/r-compute-ngram-counts
    sudo ln -sfn /usr/local/lib/randlm/bin/buildlm /usr/local/bin
    sudo ln -sfn /usr/local/lib/randlm/bin/querylm /usr/local/bin
    sudo ln -sfn /usr/local/lib/randlm/bin/m_compute_ngram_counts_batch /usr/local/bin
    sudo ln -sfn /usr/local/lib/randlm/bin/r_compute_ngram_counts /usr/local/bin
    sudo ln -sfn /usr/local/lib/randlm/bin/m-compute-ngram-counts-batch /usr/local/bin
    sudo ln -sfn /usr/local/lib/randlm/bin/r-compute-ngram-counts /usr/local/bin

From → Uncategorized

Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: