Install PostGIS and PGrouting on Debian Wheezy from source
#!/bin/bash
#install postgis
apt-get install libxml++2.6-dev libgeos-3.3.3 libgeos-dev libgdal-dev gdal-bin libproj-dev binutils
wget http://postgis.refractions.net/download/postgis-2.0.0.tar.gz
tar xfvz postgis-2.0.0.tar.gz
cd postgis-2.0.0
./configure
make
sudo make install
sudo ldconfig
sudo make comments-install
sudo ln -sf /usr/share/postgresql-common/pg_wrapper /usr/local/bin/shp2pgsql
sudo ln -sf /usr/share/postgresql-common/pg_wrapper /usr/local/bin/pgsql2shp
sudo ln -sf /usr/share/postgresql-common/pg_wrapper /usr/local/bin/raster2pgsql
# install pgrouting
sudo apt-get install build-essential subversion cmake debhelper fakeroot postgresql-9.1-postgis postgresql-server-dev-9.1 libboost1.49-dev libcgal9 libcgal-dev
wget https://codeload.github.com/pgRouting/pgrouting/zip/pgrouting-2.0.0 -O pgrouting-2.0.0.zip
unzip pgrouting-2.0.0.zip
cd pgrouting-pgrouting-2.0.0/
mkdir build
cd build
cmake -L ..
make
sudo make install
# createdb -E UTF8 -T template0 --lc-collate=en_US.UTF-8 --lc-ctype=en_US.UTF-8 -D pg_default -O postgres routing;
# psql
# \c routing
# CREATE EXTENSION postgis;
# CREATE EXTENSION postgis_topology;
# CREATE EXTENSION pgrouting;
# CREATE EXTENSION postgis_sfcgal;
# CREATE EXTENSION fuzzystrmatch;
# CREATE EXTENSION address_standardizer;
# CREATE EXTENSION address_standardizer_data_us;
# CREATE EXTENSION postgis_tiger_geocoder;