Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
open-source
logilab-common
Commits
6a0b2b3c95fd
Commit
00b3c873
authored
Apr 20, 2010
by
Sylvain Thénault
Browse files
canonical setup.py
parent
6ec94501eacf
Changes
1
Hide whitespace changes
Inline
Side-by-side
setup.py
View file @
6a0b2b3c
...
...
@@ -30,34 +30,15 @@ sys.modules.pop('__pkginfo__', None)
from
__pkginfo__
import
modname
,
version
,
license
,
short_desc
,
long_desc
,
\
web
,
author
,
author_email
# import optional features
try
:
from
__pkginfo__
import
distname
except
ImportError
:
distname
=
modname
try
:
from
__pkginfo__
import
scripts
except
ImportError
:
scripts
=
[]
try
:
from
__pkginfo__
import
data_files
except
ImportError
:
data_files
=
None
try
:
from
__pkginfo__
import
subpackage_of
except
ImportError
:
subpackage_of
=
None
try
:
from
__pkginfo__
import
include_dirs
except
ImportError
:
include_dirs
=
[]
try
:
from
__pkginfo__
import
ext_modules
except
ImportError
:
ext_modules
=
None
try
:
from
__pkginfo__
import
install_requires
except
ImportError
:
install_requires
=
None
import
__pkginfo__
distname
=
getattr
(
__pkginfo__
,
'distname'
,
modname
)
scripts
=
getattr
(
__pkginfo__
,
'scripts'
,
[])
data_files
=
getattr
(
__pkginfo__
,
'data_files'
,
None
)
subpackage_of
=
getattr
(
__pkginfo__
,
'subpackage_of'
,
None
)
include_dirs
=
getattr
(
__pkginfo__
,
'include_dirs'
,
[])
ext_modules
=
getattr
(
__pkginfo__
,
'ext_modules'
,
None
)
install_requires
=
getattr
(
__pkginfo__
,
'install_requires'
,
None
)
dependency_links
=
getattr
(
__pkginfo__
,
'dependency_links'
,
None
)
STD_BLACKLIST
=
(
'CVS'
,
'.svn'
,
'.hg'
,
'debian'
,
'dist'
,
'build'
)
...
...
@@ -193,6 +174,7 @@ def install(**kwargs):
packages
=
[
modname
]
+
get_packages
(
os
.
getcwd
(),
modname
)
if
USE_SETUPTOOLS
and
install_requires
:
kwargs
[
'install_requires'
]
=
install_requires
kwargs
[
'dependency_links'
]
=
dependency_links
kwargs
[
'packages'
]
=
packages
return
setup
(
name
=
distname
,
version
=
version
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment