2016-11-29
Goal: Get a working SWIG build of the latest libRETS.
This setup will use Ubuntu with vagrant, a tool for creating development environments with virtual machines on Mac, GNU/Linux, and Windows.
Initial setup:
# See included Vagrantfile.
vagrant up
vagrant ssh
sudo apt-get update && sudo apt-get dist-upgrade
exit
vagrant halt
vagrant up
vagrant ssh
sudo apt-get install autoconf build-essential
sudo apt-get install git
Prepare build:
# vagrant ssh
sudo apt-get install libboost-all-dev libcurl4-openssl-dev openjdk-7-jdk
# Additional dependencies not caught by libRETS configure:
sudo apt-get install libdb-dev libbz2-dev
git clone https://github.com/NationalAssociationOfRealtors/libRETS.git
... and SWIG. First download SWIG 3.0.10 on the host machine (because sourceforge is easier to download in the web browser than curl, given its mirrors) into the same directory that has the Vagrantfile, then:
# vagrant ssh
cd /vagrant/
md5sum swig-3.0.10.tar.gz # bb4ab8047159469add7d00910e203124
tar -xf swig-3.0.10.tar.gz
cd swig-3.0.10
sudo apt-get build-dep swig
./configure --prefix=/usr --without-clisp --without-maximum-compile-warnings
make
sudo make install
Build:
# vagrant ssh
cd ~/libRETS/
git checkout 1.6.2
./autogen.sh
./configure --prefix=/usr # Reports language support, e.g.: With Python 3: yes
make
sudo make install
As a simple test, python3 -m librets
will have empty output if it finds the
librets
import and will report an error if it cannot.