setup.py 2.34 KB
Newer Older
Kai Willadsen's avatar
Kai Willadsen committed
1
#!/usr/bin/env python3
2 3

import glob
4
import sys
5
from distutils.core import setup
6

7
import meld.build_helpers
8 9
import meld.conf

10 11 12
if sys.version_info[:2] < meld.conf.PYTHON_REQUIREMENT_TUPLE:
    version = ".".join(map(str, meld.conf.PYTHON_REQUIREMENT_TUPLE))
    raise Exception("Meld setup requires Python %s or higher." % version)
13 14 15 16 17 18 19 20

setup(
    name=meld.conf.__package__,
    version=meld.conf.__version__,
    description='Visual diff and merge tool',
    author='Kai Willadsen',
    author_email='kai.willadsen@gmail.com',
    url='http://meldmerge.org',
21
    license='GPLv2+',
22 23 24 25 26 27 28
    classifiers=[
        'Development Status :: 5 - Production/Stable',
        'Environment :: X11 Applications :: GTK',
        'Intended Audience :: Developers',
        'Intended Audience :: System Administrators',
        'License :: OSI Approved :: GNU General Public License v2 or later (GPLv2+)',
        'Programming Language :: Python',
29
        'Programming Language :: Python :: 3 :: Only',
30 31 32 33
        'Topic :: Desktop Environment :: Gnome',
        'Topic :: Software Development',
        'Topic :: Software Development :: Version Control',
    ],
34
    keywords=['diff', 'merge'],
35 36
    packages=[
        'meld',
37
        'meld.matchers',
38 39 40 41
        'meld.ui',
        'meld.vc',
    ],
    package_data={
42 43
        'meld': ['README', 'COPYING', 'NEWS'],
        'meld.vc': ['README', 'COPYING'],
44 45 46 47 48 49
    },
    scripts=['bin/meld'],
    data_files=[
        ('share/man/man1',
         ['meld.1']
         ),
50
        ('share/doc/meld-' + meld.conf.__version__,
51 52
         ['COPYING', 'NEWS']
         ),
Kai Willadsen's avatar
Kai Willadsen committed
53
        ('share/meld',
54
         ['data/meld.css']
Kai Willadsen's avatar
Kai Willadsen committed
55
         ),
56 57 58 59
        ('share/meld/icons',
         glob.glob("data/icons/*.png") +
         glob.glob("data/icons/COPYING*")
         ),
60 61 62
        ('share/meld/styles',
         glob.glob("data/styles/*.xml")
         ),
63 64 65 66 67
        ('share/meld/ui',
         glob.glob("data/ui/*.ui") + glob.glob("data/ui/*.xml")
         ),
    ],
    cmdclass={
68 69 70
        "build_i18n": meld.build_helpers.build_i18n,
        "build_help": meld.build_helpers.build_help,
        "build_icons": meld.build_helpers.build_icons,
Kai Willadsen's avatar
Kai Willadsen committed
71
        "build_data": meld.build_helpers.build_data,
72
        "build_py": meld.build_helpers.build_py,
73
        "install": meld.build_helpers.install,
74
        "install_data": meld.build_helpers.install_data,
75 76
    },
    distclass=meld.build_helpers.MeldDistribution,
77
)