]> gitweb.michael.orlitzky.com - dead/census-tools.git/blobdiff - makefile
Added a "Related Projects" heading containing a description of TRAGIS.
[dead/census-tools.git] / makefile
index bfccc236762944d8830f6b51eb797b3de351b124..11a9c5c60c82671876ab45d006a8770c4a213538 100644 (file)
--- a/makefile
+++ b/makefile
@@ -1,6 +1,7 @@
 DB_NAME=census
 DB_USER=postgres
 TIGER_SRID=4269
+SHAPELY_URL=http://pypi.python.org/packages/source/S/Shapely/Shapely-1.0.14.tar.gz
 
 # Root folder for the shapefiles.
 TIGER_ROOT=http://www2.census.gov/geo/tiger/TIGER2009
@@ -28,18 +29,28 @@ PG_SHAREDIR=`pg_config --sharedir`
 
 # Necessary to run test/data without prerequisites.
 #
-.PHONY : test data
+.PHONY : test data lib
 
 
 # The default task, since it comes first in the list.
 #
-all: clean test
+all: clean lib test
 
 
 test:
        ./bin/run_tests
 
 
+# Download or check out any third-party libraries.
+lib:
+       if [ ! -d lib/Shapely ]; then                   \
+               wget -O shapely.tar.gz $(SHAPELY_URL);  \
+               tar -xvzf shapely.tar.gz -C lib/    ;   \
+               rm shapely.tar.gz;                      \
+               mv lib/Shapely* lib/Shapely;            \
+       fi;
+
+
 # Remove byte-compiled python code.
 #
 clean: