~ubuntu-branches/ubuntu/natty/pysvn/natty

« back to all changes in this revision

Viewing changes to Import/pycxx-6.0.0/setup.py

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2009-02-23 20:08:08 UTC
  • mfrom: (1.1.11 upstream)
  • Revision ID: james.westby@ubuntu.com-20090223200808-t946skprxzf6vjqx
Tags: 1.6.3-0ubuntu1
New upstream version.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
import os, sys
 
2
from glob import glob
 
3
from distutils.command.install import install
 
4
from distutils.core import setup
 
5
 
 
6
headers = glob (os.path.join ("CXX","*.hxx"))
 
7
sources = glob (os.path.join ("Src", "*.cxx")) + \
 
8
          glob (os.path.join ("Src", "*.c"))
 
9
 
 
10
 
 
11
class my_install (install):
 
12
 
 
13
    def finalize_options (self):
 
14
        if not self.install_data or (len(self.install_data) < 8) :
 
15
            self.install_data = "$base/share/python$py_version_short"
 
16
        install.finalize_options (self)
 
17
 
 
18
    def run (self):
 
19
        self.distribution.data_files = [("CXX", sources)]
 
20
        self.distribution.headers = headers
 
21
        install.run (self)
 
22
 
 
23
 
 
24
setup (name             = "CXX",
 
25
       version          = "5.3",
 
26
       maintainer       = "Barry Scott",
 
27
       maintainer_email = "barry-scott@users.sourceforge.net",
 
28
       description      = "Facility for extending Python with C++",
 
29
       url              = "http://cxx.sourceforge.net",
 
30
       
 
31
       cmdclass         = {'install': my_install},
 
32
       packages         = ['CXX'],
 
33
       package_dir      = {'CXX': 'Lib'}
 
34
      )