]> git.k1024.org Git - pyxattr.git/blob - setup.py
Merge pull request #9 from ahknight/osx-support
[pyxattr.git] / setup.py
1 #!/usr/bin/python
2
3 import distutils
4 import platform
5 try:
6   from setuptools import setup, Extension
7 except ImportError:
8   from distutils.core import setup, Extension
9
10 long_desc = """This is a C extension module for Python which
11 implements extended attributes manipulation. It is a wrapper on top
12 of the attr C library - see attr(5)."""
13 version = "0.5.6"
14 author = "Iustin Pop"
15 author_email = "iustin@k1024.org"
16 libraries = []
17 if platform.system() == 'Linux':
18     libraries.append("attr")
19 macros = [
20     ("_XATTR_VERSION", '"%s"' % version),
21     ("_XATTR_AUTHOR", '"%s"' % author),
22     ("_XATTR_EMAIL", '"%s"' % author_email),
23     ]
24 setup(name = "pyxattr",
25       version = version,
26       description = "Filesystem extended attributes for python",
27       long_description = long_desc,
28       author = author,
29       author_email = author_email,
30       url = "http://pyxattr.k1024.org/",
31       download_url = "http://pyxattr.k1024.org/downloads/",
32       license = "LGPL",
33       ext_modules = [Extension("xattr", ["xattr.c"],
34                                libraries=libraries,
35                                define_macros=macros,
36                                extra_compile_args=["-Wall", "-Werror", "-Wsign-compare"],
37                                )],
38       test_suite = "test",
39       platforms = ["Linux"],
40       )