2011-05-21 12:00:59 +00:00
|
|
|
#!/usr/bin/env python
|
2014-09-22 21:15:33 +00:00
|
|
|
# -*- coding: utf-8 -*-
|
2007-07-04 08:24:30 +00:00
|
|
|
#
|
2008-11-23 04:58:01 +00:00
|
|
|
# Copyright (C) 2007 Andrew Resch <andrewresch@gmail.com>
|
2014-09-22 21:15:33 +00:00
|
|
|
# Copyright (C) 2009 Damien Churchill <damoxc@gmail.com>
|
2008-07-14 20:42:11 +00:00
|
|
|
#
|
2014-09-22 21:15:33 +00:00
|
|
|
# This file is part of Deluge and is licensed under GNU General Public License 3.0, or later, with
|
|
|
|
# the additional special exception to link portions of this program with the OpenSSL library.
|
|
|
|
# See LICENSE for more details.
|
2007-07-04 08:24:30 +00:00
|
|
|
#
|
|
|
|
|
2014-09-03 23:27:11 +00:00
|
|
|
import glob
|
2012-11-14 12:27:41 +00:00
|
|
|
import os
|
|
|
|
import platform
|
2014-09-03 23:27:11 +00:00
|
|
|
import sys
|
2014-09-03 21:28:28 +00:00
|
|
|
from distutils import cmd
|
2007-09-16 01:24:08 +00:00
|
|
|
from distutils.command.build import build as _build
|
2008-11-25 22:21:14 +00:00
|
|
|
from distutils.command.clean import clean as _clean
|
2015-08-24 22:35:24 +00:00
|
|
|
from distutils.command.install_data import install_data as _install_data
|
2013-05-06 06:34:26 +00:00
|
|
|
|
2014-09-03 23:27:11 +00:00
|
|
|
from setuptools import find_packages, setup
|
2014-09-25 20:05:57 +00:00
|
|
|
from setuptools.command.test import test as _test
|
2014-09-03 23:27:11 +00:00
|
|
|
|
|
|
|
import msgfmt
|
|
|
|
from version import get_version
|
|
|
|
|
2009-07-22 23:52:18 +00:00
|
|
|
try:
|
|
|
|
from sphinx.setup_command import BuildDoc
|
|
|
|
except ImportError:
|
|
|
|
class BuildDoc(object):
|
|
|
|
pass
|
|
|
|
|
2013-05-06 06:34:26 +00:00
|
|
|
|
2008-02-03 01:04:26 +00:00
|
|
|
def windows_check():
|
2008-10-23 11:27:37 +00:00
|
|
|
return platform.system() in ('Windows', 'Microsoft')
|
2008-02-03 01:04:26 +00:00
|
|
|
|
2015-09-20 17:39:20 +00:00
|
|
|
|
|
|
|
def osx_check():
|
|
|
|
return platform.system() == "Darwin"
|
|
|
|
|
2012-02-20 16:56:20 +00:00
|
|
|
desktop_data = 'deluge/ui/data/share/applications/deluge.desktop'
|
|
|
|
|
2014-09-03 21:28:28 +00:00
|
|
|
|
2014-09-25 20:05:57 +00:00
|
|
|
class PyTest(_test):
|
2014-09-21 14:37:29 +00:00
|
|
|
|
|
|
|
def initialize_options(self):
|
2014-09-25 20:05:57 +00:00
|
|
|
_test.initialize_options(self)
|
2014-09-21 14:37:29 +00:00
|
|
|
self.pytest_args = []
|
|
|
|
|
|
|
|
def finalize_options(self):
|
2014-09-25 20:05:57 +00:00
|
|
|
_test.finalize_options(self)
|
2014-09-21 14:37:29 +00:00
|
|
|
self.test_args = []
|
|
|
|
self.test_suite = True
|
|
|
|
|
|
|
|
def run_tests(self):
|
|
|
|
import pytest
|
|
|
|
errcode = pytest.main(self.test_args)
|
|
|
|
sys.exit(errcode)
|
|
|
|
|
|
|
|
|
2014-09-19 18:10:09 +00:00
|
|
|
class BuildTranslations(cmd.Command):
|
2012-01-02 16:53:28 +00:00
|
|
|
description = 'Compile .po files into .mo files & create .desktop file'
|
2007-09-16 01:24:08 +00:00
|
|
|
|
2008-11-29 01:22:29 +00:00
|
|
|
user_options = [
|
2015-08-25 12:20:14 +00:00
|
|
|
('build-lib', None, 'lib build folder'),
|
2014-09-03 21:28:28 +00:00
|
|
|
('develop', 'D', 'Compile translations in develop mode (deluge/i18n)')
|
2008-11-29 01:22:29 +00:00
|
|
|
]
|
2013-05-06 06:34:26 +00:00
|
|
|
boolean_options = ['develop']
|
2008-11-29 01:22:29 +00:00
|
|
|
|
2007-09-16 01:24:08 +00:00
|
|
|
def initialize_options(self):
|
2008-11-29 01:22:29 +00:00
|
|
|
self.build_lib = None
|
2013-05-06 06:34:26 +00:00
|
|
|
self.develop = False
|
2007-09-16 01:24:08 +00:00
|
|
|
|
|
|
|
def finalize_options(self):
|
2008-11-29 01:22:29 +00:00
|
|
|
self.set_undefined_options('build', ('build_lib', 'build_lib'))
|
2007-09-16 01:24:08 +00:00
|
|
|
|
|
|
|
def run(self):
|
|
|
|
po_dir = os.path.join(os.path.dirname(__file__), 'deluge/i18n/')
|
2011-07-13 20:49:25 +00:00
|
|
|
|
2013-05-06 06:34:26 +00:00
|
|
|
if self.develop:
|
2011-07-10 00:20:13 +00:00
|
|
|
basedir = po_dir
|
|
|
|
else:
|
|
|
|
basedir = os.path.join(self.build_lib, 'deluge', 'i18n')
|
2011-07-13 20:49:25 +00:00
|
|
|
|
2011-07-22 18:12:47 +00:00
|
|
|
if not windows_check():
|
|
|
|
# creates the translated desktop file
|
2014-09-03 21:28:28 +00:00
|
|
|
intltool_merge = 'intltool-merge'
|
|
|
|
intltool_merge_opts = '--utf8 --quiet --desktop-style'
|
|
|
|
desktop_in = 'deluge/ui/data/share/applications/deluge.desktop.in'
|
2011-07-22 18:12:47 +00:00
|
|
|
print('Creating desktop file: %s' % desktop_data)
|
2014-09-03 21:28:28 +00:00
|
|
|
os.system('C_ALL=C ' + '%s ' * 5 % (intltool_merge, intltool_merge_opts,
|
|
|
|
po_dir, desktop_in, desktop_data))
|
2011-07-13 20:49:25 +00:00
|
|
|
|
|
|
|
print('Compiling po files from %s...' % po_dir),
|
2007-09-16 01:24:08 +00:00
|
|
|
for path, names, filenames in os.walk(po_dir):
|
|
|
|
for f in filenames:
|
2014-09-03 21:28:28 +00:00
|
|
|
upto_date = False
|
2007-09-16 01:24:08 +00:00
|
|
|
if f.endswith('.po'):
|
|
|
|
lang = f[:len(f) - 3]
|
|
|
|
src = os.path.join(path, f)
|
2011-07-10 00:20:13 +00:00
|
|
|
dest_path = os.path.join(basedir, lang, 'LC_MESSAGES')
|
2007-09-16 01:24:08 +00:00
|
|
|
dest = os.path.join(dest_path, 'deluge.mo')
|
|
|
|
if not os.path.exists(dest_path):
|
|
|
|
os.makedirs(dest_path)
|
|
|
|
if not os.path.exists(dest):
|
2011-07-13 20:49:25 +00:00
|
|
|
sys.stdout.write('%s, ' % lang)
|
|
|
|
sys.stdout.flush()
|
2007-09-16 01:24:08 +00:00
|
|
|
msgfmt.make(src, dest)
|
|
|
|
else:
|
|
|
|
src_mtime = os.stat(src)[8]
|
|
|
|
dest_mtime = os.stat(dest)[8]
|
|
|
|
if src_mtime > dest_mtime:
|
2011-07-13 20:49:25 +00:00
|
|
|
sys.stdout.write('%s, ' % lang)
|
|
|
|
sys.stdout.flush()
|
2007-09-16 01:24:08 +00:00
|
|
|
msgfmt.make(src, dest)
|
2011-07-13 20:49:25 +00:00
|
|
|
else:
|
2014-09-03 21:28:28 +00:00
|
|
|
upto_date = True
|
2011-07-22 18:12:47 +00:00
|
|
|
|
2014-09-03 21:28:28 +00:00
|
|
|
if upto_date:
|
2011-07-13 20:49:25 +00:00
|
|
|
sys.stdout.write(' po files already upto date. ')
|
|
|
|
sys.stdout.write('\b\b \nFinished compiling translation files. \n')
|
2007-09-16 01:24:08 +00:00
|
|
|
|
2013-05-06 06:34:26 +00:00
|
|
|
|
2014-09-19 18:10:09 +00:00
|
|
|
class BuildPlugins(cmd.Command):
|
2015-08-25 12:20:14 +00:00
|
|
|
description = 'Build plugins into .eggs'
|
2008-11-23 05:57:35 +00:00
|
|
|
|
2013-05-06 06:34:26 +00:00
|
|
|
user_options = [
|
2015-08-25 12:20:14 +00:00
|
|
|
('install-dir=', None, 'develop install folder'),
|
2014-09-03 21:28:28 +00:00
|
|
|
('develop', 'D', 'Compile plugins in develop mode')
|
2013-05-06 06:34:26 +00:00
|
|
|
]
|
|
|
|
boolean_options = ['develop']
|
2011-06-05 15:58:27 +00:00
|
|
|
|
|
|
|
def initialize_options(self):
|
2013-05-06 06:34:26 +00:00
|
|
|
self.install_dir = None
|
|
|
|
self.develop = False
|
2011-06-05 15:58:27 +00:00
|
|
|
|
|
|
|
def finalize_options(self):
|
|
|
|
pass
|
|
|
|
|
|
|
|
def run(self):
|
|
|
|
# Build the plugin eggs
|
2015-08-25 12:20:14 +00:00
|
|
|
plugin_path = 'deluge/plugins/*'
|
2011-06-05 15:58:27 +00:00
|
|
|
|
2014-09-03 21:28:28 +00:00
|
|
|
for path in glob.glob(plugin_path):
|
2015-08-25 12:20:14 +00:00
|
|
|
if os.path.exists(os.path.join(path, 'setup.py')):
|
2013-05-06 06:34:26 +00:00
|
|
|
if self.develop and self.install_dir:
|
2015-08-25 12:20:14 +00:00
|
|
|
os.system('cd ' + path + '&& ' + sys.executable +
|
|
|
|
' setup.py develop --install-dir=%s' % self.install_dir)
|
2013-05-06 06:34:26 +00:00
|
|
|
elif self.develop:
|
2015-08-25 12:20:14 +00:00
|
|
|
os.system('cd ' + path + '&& ' + sys.executable + ' setup.py develop')
|
2013-05-06 06:34:26 +00:00
|
|
|
else:
|
2015-08-25 12:20:14 +00:00
|
|
|
os.system('cd ' + path + '&& ' + sys.executable + ' setup.py bdist_egg -d ..')
|
2011-06-05 15:58:27 +00:00
|
|
|
|
|
|
|
|
2014-09-19 18:10:09 +00:00
|
|
|
class EggInfoPlugins(cmd.Command):
|
2015-08-25 12:20:14 +00:00
|
|
|
description = 'Create .egg-info directories for plugins'
|
2011-06-05 15:58:27 +00:00
|
|
|
|
|
|
|
user_options = []
|
|
|
|
|
|
|
|
def initialize_options(self):
|
|
|
|
pass
|
|
|
|
|
|
|
|
def finalize_options(self):
|
|
|
|
pass
|
|
|
|
|
|
|
|
def run(self):
|
|
|
|
# Build the plugin eggs
|
2015-08-25 12:20:14 +00:00
|
|
|
plugin_path = 'deluge/plugins/*'
|
2011-06-05 15:58:27 +00:00
|
|
|
|
2014-09-03 21:28:28 +00:00
|
|
|
for path in glob.glob(plugin_path):
|
2015-08-25 12:20:14 +00:00
|
|
|
if os.path.exists(os.path.join(path, 'setup.py')):
|
|
|
|
os.system('cd ' + path + '&& ' + sys.executable + ' setup.py egg_info')
|
2011-06-05 15:58:27 +00:00
|
|
|
|
|
|
|
|
2014-09-19 18:10:09 +00:00
|
|
|
class Build(_build):
|
2014-09-23 08:09:49 +00:00
|
|
|
sub_commands = [('build_trans', None), ('build_plugins', None)] + _build.sub_commands
|
2014-09-03 21:28:28 +00:00
|
|
|
|
2007-09-16 01:24:08 +00:00
|
|
|
def run(self):
|
2015-08-25 12:20:14 +00:00
|
|
|
# Run all sub-commands (at least those that need to be run).
|
2007-09-16 01:24:08 +00:00
|
|
|
_build.run(self)
|
2013-05-06 06:34:26 +00:00
|
|
|
try:
|
|
|
|
from deluge._libtorrent import lt
|
2015-08-25 12:20:14 +00:00
|
|
|
print('Found libtorrent version: %s' % lt.version)
|
2013-05-06 06:34:26 +00:00
|
|
|
except ImportError, e:
|
2015-08-25 12:20:14 +00:00
|
|
|
print('Warning libtorrent not found: %s' % e)
|
2013-05-06 06:34:26 +00:00
|
|
|
|
2007-09-16 01:24:08 +00:00
|
|
|
|
2015-08-24 22:35:24 +00:00
|
|
|
class InstallData(_install_data):
|
|
|
|
"""Custom class to fix 'setup install' copying data files to incorrect location. (Bug #1389)"""
|
|
|
|
|
|
|
|
def finalize_options(self):
|
|
|
|
self.install_dir = None
|
|
|
|
self.set_undefined_options('install', ('install_data', 'install_dir'),
|
|
|
|
('root', 'root'), ('force', 'force'),)
|
|
|
|
|
|
|
|
def run(self):
|
|
|
|
_install_data.run(self)
|
|
|
|
|
|
|
|
|
2014-09-19 18:10:09 +00:00
|
|
|
class CleanPlugins(cmd.Command):
|
2015-08-25 12:20:14 +00:00
|
|
|
description = 'Cleans the plugin folders'
|
|
|
|
user_options = [('all', 'a', 'Remove all build output, not just temporary by-products')]
|
2008-11-25 22:21:14 +00:00
|
|
|
boolean_options = ['all']
|
|
|
|
|
|
|
|
def initialize_options(self):
|
|
|
|
self.all = None
|
|
|
|
|
|
|
|
def finalize_options(self):
|
|
|
|
self.set_undefined_options('clean', ('all', 'all'))
|
|
|
|
|
|
|
|
def run(self):
|
2015-08-25 12:20:14 +00:00
|
|
|
print('Cleaning the plugin\'s folders...')
|
2008-11-25 22:21:14 +00:00
|
|
|
|
2015-08-25 12:20:14 +00:00
|
|
|
plugin_path = 'deluge/plugins/*'
|
2008-11-25 22:21:14 +00:00
|
|
|
|
2014-09-03 21:28:28 +00:00
|
|
|
for path in glob.glob(plugin_path):
|
2015-08-25 12:20:14 +00:00
|
|
|
if os.path.exists(os.path.join(path, 'setup.py')):
|
|
|
|
c = 'cd ' + path + ' && ' + sys.executable + ' setup.py clean'
|
2008-11-25 22:21:14 +00:00
|
|
|
if self.all:
|
2015-08-25 12:20:14 +00:00
|
|
|
c += ' -a'
|
|
|
|
print('Calling \'%s\'' % c)
|
2008-11-25 22:21:14 +00:00
|
|
|
os.system(c)
|
|
|
|
|
|
|
|
# Delete the .eggs
|
2015-08-25 12:20:14 +00:00
|
|
|
if path[-4:] == '.egg':
|
|
|
|
print('Deleting %s' % path)
|
2008-11-25 22:21:14 +00:00
|
|
|
os.remove(path)
|
|
|
|
|
2015-08-25 12:20:14 +00:00
|
|
|
egg_info_dir_path = 'deluge/plugins/*/*.egg-info'
|
2011-06-05 15:58:27 +00:00
|
|
|
|
2014-09-03 21:28:28 +00:00
|
|
|
for path in glob.glob(egg_info_dir_path):
|
2011-06-05 15:58:27 +00:00
|
|
|
# Delete the .egg-info's directories
|
2015-08-25 12:20:14 +00:00
|
|
|
if path[-9:] == '.egg-info':
|
|
|
|
print('Deleting %s' % path)
|
2011-06-05 15:58:27 +00:00
|
|
|
for fpath in os.listdir(path):
|
|
|
|
os.remove(os.path.join(path, fpath))
|
|
|
|
os.removedirs(path)
|
|
|
|
|
2015-08-25 12:20:14 +00:00
|
|
|
root_egg_info_dir_path = 'deluge*.egg-info'
|
2012-01-09 19:58:37 +00:00
|
|
|
|
2014-09-03 21:28:28 +00:00
|
|
|
for path in glob.glob(root_egg_info_dir_path):
|
2015-08-25 12:20:14 +00:00
|
|
|
print('Deleting %s' % path)
|
2012-01-09 19:58:37 +00:00
|
|
|
for fpath in os.listdir(path):
|
|
|
|
os.remove(os.path.join(path, fpath))
|
|
|
|
os.removedirs(path)
|
|
|
|
|
2013-05-06 06:34:26 +00:00
|
|
|
|
2014-09-19 18:10:09 +00:00
|
|
|
class Clean(_clean):
|
2014-09-23 08:09:49 +00:00
|
|
|
sub_commands = _clean.sub_commands + [('clean_plugins', None)]
|
2008-11-25 22:21:14 +00:00
|
|
|
|
|
|
|
def run(self):
|
|
|
|
# Run all sub-commands (at least those that need to be run)
|
|
|
|
for cmd_name in self.get_sub_commands():
|
|
|
|
self.run_command(cmd_name)
|
|
|
|
_clean.run(self)
|
|
|
|
|
2012-01-02 16:53:28 +00:00
|
|
|
if os.path.exists(desktop_data):
|
2015-08-25 12:20:14 +00:00
|
|
|
print('Deleting %s' % desktop_data)
|
2012-01-02 16:53:28 +00:00
|
|
|
os.remove(desktop_data)
|
|
|
|
|
2007-09-16 01:24:08 +00:00
|
|
|
cmdclass = {
|
2014-09-20 17:55:21 +00:00
|
|
|
'build': Build,
|
|
|
|
'build_trans': BuildTranslations,
|
|
|
|
'build_plugins': BuildPlugins,
|
2014-09-25 20:05:57 +00:00
|
|
|
'build_docs': BuildDoc,
|
2015-08-24 22:35:24 +00:00
|
|
|
'install_data': InstallData,
|
2014-09-20 17:55:21 +00:00
|
|
|
'clean_plugins': CleanPlugins,
|
|
|
|
'clean': Clean,
|
2014-09-21 14:37:29 +00:00
|
|
|
'egg_info_plugins': EggInfoPlugins,
|
|
|
|
'test': PyTest,
|
2007-09-16 01:24:08 +00:00
|
|
|
}
|
|
|
|
|
2015-08-27 10:27:37 +00:00
|
|
|
# Data files to be installed to the system.
|
|
|
|
_data_files = []
|
2015-09-20 17:39:20 +00:00
|
|
|
if not windows_check() and not osx_check():
|
2015-08-27 10:27:37 +00:00
|
|
|
_data_files = [
|
2015-09-20 20:36:29 +00:00
|
|
|
('share/icons/hicolor/scalable/apps', ['deluge/ui/data/icons/hicolor/scalable/apps/deluge.svg']),
|
2015-08-27 10:27:37 +00:00
|
|
|
('share/icons/hicolor/128x128/apps', ['deluge/ui/data/icons/hicolor/128x128/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/16x16/apps', ['deluge/ui/data/icons/hicolor/16x16/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/192x192/apps', ['deluge/ui/data/icons/hicolor/192x192/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/22x22/apps', ['deluge/ui/data/icons/hicolor/22x22/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/24x24/apps', ['deluge/ui/data/icons/hicolor/24x24/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/256x256/apps', ['deluge/ui/data/icons/hicolor/256x256/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/32x32/apps', ['deluge/ui/data/icons/hicolor/32x32/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/36x36/apps', ['deluge/ui/data/icons/hicolor/36x36/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/48x48/apps', ['deluge/ui/data/icons/hicolor/48x48/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/64x64/apps', ['deluge/ui/data/icons/hicolor/64x64/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/72x72/apps', ['deluge/ui/data/icons/hicolor/72x72/apps/deluge.png']),
|
|
|
|
('share/icons/hicolor/96x96/apps', ['deluge/ui/data/icons/hicolor/96x96/apps/deluge.png']),
|
|
|
|
('share/pixmaps', ['deluge/ui/data/pixmaps/deluge.png', 'deluge/ui/data/pixmaps/deluge.xpm']),
|
|
|
|
('share/man/man1', [
|
|
|
|
'docs/man/deluge.1',
|
|
|
|
'docs/man/deluged.1',
|
|
|
|
'docs/man/deluge-gtk.1',
|
|
|
|
'docs/man/deluge-web.1',
|
|
|
|
'docs/man/deluge-console.1'])
|
|
|
|
]
|
|
|
|
|
|
|
|
if os.path.exists(desktop_data):
|
|
|
|
_data_files.append(('share/applications', [desktop_data]))
|
2011-07-22 18:12:47 +00:00
|
|
|
|
2010-10-31 09:18:09 +00:00
|
|
|
entry_points = {
|
2015-08-25 12:20:14 +00:00
|
|
|
'console_scripts': [
|
|
|
|
'deluge-console = deluge.ui.console:start',
|
|
|
|
'deluge-web = deluge.ui.web:start',
|
|
|
|
'deluged = deluge.main:start_daemon'
|
2010-10-31 09:18:09 +00:00
|
|
|
],
|
2015-08-25 12:20:14 +00:00
|
|
|
'gui_scripts': [
|
|
|
|
'deluge = deluge.main:start_ui',
|
|
|
|
'deluge-gtk = deluge.ui.gtkui:start'
|
2010-10-31 09:18:09 +00:00
|
|
|
]
|
|
|
|
}
|
|
|
|
|
|
|
|
if windows_check():
|
2015-08-25 12:20:14 +00:00
|
|
|
entry_points['console_scripts'].extend([
|
|
|
|
'deluge-debug = deluge.main:start_ui',
|
|
|
|
'deluge-web-debug = deluge.ui.web:start',
|
|
|
|
'deluged-debug = deluge.main:start_daemon'])
|
2010-10-31 09:18:09 +00:00
|
|
|
|
2015-09-04 18:43:06 +00:00
|
|
|
_package_data = {}
|
|
|
|
_package_data['deluge'] = [
|
|
|
|
'ui/data/pixmaps/*.png',
|
|
|
|
'ui/data/pixmaps/*.svg',
|
|
|
|
'ui/data/pixmaps/*.ico',
|
|
|
|
'ui/data/pixmaps/*.gif',
|
|
|
|
'ui/data/pixmaps/flags/*.png',
|
|
|
|
'plugins/*.egg',
|
|
|
|
'i18n/*/LC_MESSAGES/*.mo']
|
|
|
|
_package_data['deluge.ui.web'] = [
|
|
|
|
'index.html',
|
|
|
|
'css/*.css',
|
|
|
|
'icons/*.png',
|
|
|
|
'images/*.gif',
|
|
|
|
'images/*.png',
|
|
|
|
'js/*.js',
|
|
|
|
'js/extjs/*.js',
|
|
|
|
'render/*.html',
|
|
|
|
'themes/css/*.css',
|
|
|
|
'themes/images/*/*.gif',
|
|
|
|
'themes/images/*/*.png',
|
|
|
|
'themes/images/*/*/*.gif',
|
|
|
|
'themes/images/*/*/*.png']
|
|
|
|
_package_data['deluge.ui.gtkui'] = ['glade/*.ui']
|
|
|
|
|
|
|
|
_version = get_version(prefix='deluge-', suffix='.dev0')
|
|
|
|
|
|
|
|
if 'dev' in _version:
|
|
|
|
_exclude_package_data = {}
|
|
|
|
else:
|
|
|
|
_exclude_package_data = {"deluge.ui.web": ["*-debug.js", '*-debug.css']}
|
|
|
|
|
2007-07-04 08:24:30 +00:00
|
|
|
# Main setup
|
|
|
|
setup(
|
2015-08-25 12:20:14 +00:00
|
|
|
name='deluge',
|
2015-09-04 18:43:06 +00:00
|
|
|
version=_version,
|
2015-08-25 12:20:14 +00:00
|
|
|
fullname='Deluge Bittorrent Client',
|
|
|
|
description='Bittorrent Client',
|
|
|
|
author='Andrew Resch, Damien Churchill',
|
|
|
|
author_email='andrewresch@gmail.com, damoxc@gmail.com',
|
|
|
|
keywords='torrent bittorrent p2p fileshare filesharing',
|
|
|
|
long_description='''Deluge is a bittorrent client that utilizes a
|
2009-05-05 19:07:05 +00:00
|
|
|
daemon/client model. There are various user interfaces available for
|
2009-05-05 19:04:53 +00:00
|
|
|
Deluge such as the GTKui, the webui and a console ui. Deluge uses
|
2015-08-25 12:20:14 +00:00
|
|
|
libtorrent in it's backend to handle the bittorrent protocol.''',
|
|
|
|
url='http://deluge-torrent.org',
|
|
|
|
license='GPLv3',
|
2014-09-03 21:28:28 +00:00
|
|
|
cmdclass=cmdclass,
|
2014-09-21 14:37:29 +00:00
|
|
|
tests_require=['pytest'],
|
2014-09-03 21:28:28 +00:00
|
|
|
data_files=_data_files,
|
2015-09-04 18:43:06 +00:00
|
|
|
package_data=_package_data,
|
|
|
|
exclude_package_data=_exclude_package_data,
|
2015-08-25 12:20:14 +00:00
|
|
|
packages=find_packages(exclude=['plugins', 'docs', 'tests']),
|
|
|
|
namespace_packages=['deluge', 'deluge.plugins'],
|
2014-09-03 21:28:28 +00:00
|
|
|
entry_points=entry_points
|
2008-07-10 04:40:13 +00:00
|
|
|
)
|