Fix setup

This commit is contained in:
olegart 2016-01-31 14:41:06 +03:00
parent 3b23ed9033
commit 43077dbd49
2 changed files with 11 additions and 6 deletions

4
MANIFEST.in Normal file
View File

@ -0,0 +1,4 @@
include setup.cfg
include setup.py
include LICENSE
recursive-include gerbmerge *.py

View File

@ -39,17 +39,18 @@ if sys.platform == 'win32' or ('bdist_wininst' in sys.argv):
else: else:
# try to find the library location on this platform # try to find the library location on this platform
DestLib = None DestLib = None
if DestLib == None: DestLib = distutils.sysconfig.get_config_var('LIBPYTHON') if DestLib == None: DestLib = distutils.sysconfig.get_python_lib()
if DestLib == None: DestLib = distutils.sysconfig.get_config_var('LIBDEST')
DestDir = os.path.join(DestLib, 'gerbmerge') DestDir = os.path.join(DestLib, 'gerbmerge')
BinFiles = ['misc/gerbmerge'] BinFiles = ['misc/gerbmerge']
BinDir = distutils.sysconfig.get_config_var('BINDIR') BinDir = distutils.sysconfig.get_config_var('BINDIR')
# Create top-level invocation program # Create top-level invocation program
if not os.path.exists('misc'):
os.makedirs('misc')
fid = file('misc/gerbmerge', 'wt') fid = file('misc/gerbmerge', 'wt')
fid.write( \ fid.write( \
r"""#!/bin/sh r"""#!/bin/sh
python %s/site-packages/gerbmerge/gerbmerge.py $* python %s/gerbmerge/gerbmerge.py $*
""" % DestLib) """ % DestLib)
fid.close() fid.close()
@ -72,9 +73,9 @@ For more details on installation or running GerbMerge, see the
URL below. URL below.
""", """,
description = "Merge multiple Gerber/Excellon files", description = "Merge multiple Gerber/Excellon files",
author = "ProvideYourOwn.com", author = "Unwired Devices LLC",
author_email = "", author_email = "info@unwds.com",
url = "https://github.com/provideyourown/gerbmerge", url = "https://github.com/unwireddevices/gerbmerge",
packages = ['gerbmerge'], packages = ['gerbmerge'],
platforms = ['all'], platforms = ['all'],
data_files = [ (DestDir, AuxFiles), data_files = [ (DestDir, AuxFiles),