Use distutils to install Python oils module (port from trunk).
authordbs <dbs@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Sun, 6 Jan 2008 19:09:51 +0000 (19:09 +0000)
committerdbs <dbs@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Sun, 6 Jan 2008 19:09:51 +0000 (19:09 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/branches/acq-experiment@8328 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/src/Makefile
Open-ILS/src/python/Makefile [new file with mode: 0644]
Open-ILS/src/python/setup.py [new file with mode: 0644]

index ab499ae..9e21990 100644 (file)
@@ -138,11 +138,11 @@ perl-install:
        mkdir -p $(TEMPLATEDIR)
        cp -r templates/marc $(TEMPLATEDIR)
 
+# -----------------------------------------------------------------------------------
+
 python-install:
        @echo $@
-       @echo "Installing Python modules to $(PYTHONDIR)"
-       mkdir -p $(PYTHONDIR)
-       cp -r python/* $(PYTHONDIR)
+       make -C python install
 
 # -----------------------------------------------------------------------------------
 
@@ -210,4 +210,5 @@ clean:
        make -C extras clean
        make -C apachemods clean
        make -C c-apps clean
+       make -C python clean
 
diff --git a/Open-ILS/src/python/Makefile b/Open-ILS/src/python/Makefile
new file mode 100644 (file)
index 0000000..ec18882
--- /dev/null
@@ -0,0 +1,16 @@
+# vim:noet:ts=4
+
+install: python-install
+
+python-build:
+       @echo $@
+       python setup.py build
+
+python-install:
+       @echo $@
+       python setup.py install
+
+clean:
+       @echo $@
+       rm -fr build
+       find . -name "*.pyc" -exec rm -f {} \;
diff --git a/Open-ILS/src/python/setup.py b/Open-ILS/src/python/setup.py
new file mode 100644 (file)
index 0000000..91abf1d
--- /dev/null
@@ -0,0 +1,16 @@
+#!/usr/bin/env python
+from distutils.core import setup
+import os, os.path
+
+dir = os.path.dirname(__file__)
+
+setup(name='Evergreen',
+    version='1.2',
+    requires='OpenSRF',
+    description='Evergreen Python Modules',
+    author='Bill Erickson',
+    author_email='open-ils-dev@list.georgialibraries.org',
+    url='http://www.open-ils.org/',
+    packages=['oils', 'oils.utils'],
+    package_dir={'': dir}
+)