2010-04-06 09:28:43 +00:00
|
|
|
import sys
|
2010-04-06 06:58:56 +00:00
|
|
|
import os.path as op
|
|
|
|
|
2010-04-06 16:04:32 +00:00
|
|
|
from setuptools import setup
|
2010-04-06 06:58:56 +00:00
|
|
|
from distutils.extension import Extension
|
|
|
|
|
|
|
|
exts = []
|
|
|
|
|
2010-04-06 09:28:43 +00:00
|
|
|
if sys.platform == 'darwin':
|
|
|
|
exts.append(Extension(
|
2010-04-06 16:04:32 +00:00
|
|
|
'_send2trash_osx',
|
|
|
|
[op.join('modules', 'send2trash_osx.c')],
|
2010-04-06 09:28:43 +00:00
|
|
|
extra_link_args=['-framework', 'CoreServices'],
|
|
|
|
))
|
|
|
|
if sys.platform == 'win32':
|
|
|
|
exts.append(Extension(
|
2010-04-06 16:04:32 +00:00
|
|
|
'_send2trash_win',
|
|
|
|
[op.join('modules', 'send2trash_win.c')],
|
2010-04-06 09:28:43 +00:00
|
|
|
extra_link_args = ['shell32.lib'],
|
|
|
|
))
|
2010-04-06 06:58:56 +00:00
|
|
|
|
|
|
|
setup(
|
|
|
|
name='Send2Trash',
|
|
|
|
version='1.0.0',
|
|
|
|
author='Hardcoded Software',
|
|
|
|
author_email='hsoft@hardcoded.net',
|
|
|
|
packages=['send2trash'],
|
|
|
|
scripts=[],
|
|
|
|
ext_modules = exts,
|
|
|
|
url='http://www.hardcoded.net/docs/send2trash/',
|
|
|
|
license='LICENSE',
|
|
|
|
description='Send file to trash natively under Mac OS X, Windows and Linux.',
|
|
|
|
)
|