Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
setuptools
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jérome Perrin
setuptools
Commits
139d5ff5
Commit
139d5ff5
authored
Feb 05, 2000
by
Greg Ward
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Tweaked various comments, docstrings, and error messages.
parent
7c7b43f5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
+12
-2
command/build_ext.py
command/build_ext.py
+12
-2
No files found.
command/build_ext.py
View file @
139d5ff5
...
@@ -103,6 +103,11 @@ class BuildExt (Command):
...
@@ -103,6 +103,11 @@ class BuildExt (Command):
if
exec_py_include
!=
py_include
:
if
exec_py_include
!=
py_include
:
self
.
include_dirs
.
insert
(
0
,
exec_py_include
)
self
.
include_dirs
.
insert
(
0
,
exec_py_include
)
# XXX how the heck are 'self.define' and 'self.undef' supposed to
# be set?
# set_final_options ()
def
run
(
self
):
def
run
(
self
):
...
@@ -152,6 +157,11 @@ class BuildExt (Command):
...
@@ -152,6 +157,11 @@ class BuildExt (Command):
def
check_extensions_list
(
self
,
extensions
):
def
check_extensions_list
(
self
,
extensions
):
"""Ensure that the list of extensions (presumably provided as a
command option 'extensions') is valid, i.e. it is a list of
2-tuples, where the tuples are (extension_name, build_info_dict).
Raise DistutilsValueError if the structure is invalid anywhere;
just returns otherwise."""
if
type
(
extensions
)
is
not
ListType
:
if
type
(
extensions
)
is
not
ListType
:
raise
DistutilsValueError
,
\
raise
DistutilsValueError
,
\
...
@@ -171,7 +181,7 @@ class BuildExt (Command):
...
@@ -171,7 +181,7 @@ class BuildExt (Command):
if
type
(
ext
[
1
])
is
not
DictionaryType
:
if
type
(
ext
[
1
])
is
not
DictionaryType
:
raise
DistutilsValueError
,
\
raise
DistutilsValueError
,
\
"second element of each tuple in 'ext_modules' "
+
\
"second element of each tuple in 'ext_modules' "
+
\
"must be a dictionary"
"must be a dictionary
(build info)
"
# end sanity-check for
# end sanity-check for
...
@@ -197,7 +207,7 @@ class BuildExt (Command):
...
@@ -197,7 +207,7 @@ class BuildExt (Command):
sources
=
build_info
.
get
(
'sources'
)
sources
=
build_info
.
get
(
'sources'
)
if
sources
is
None
or
type
(
sources
)
not
in
(
ListType
,
TupleType
):
if
sources
is
None
or
type
(
sources
)
not
in
(
ListType
,
TupleType
):
raise
DistutilsValueError
,
\
raise
DistutilsValueError
,
\
(
"in
ext_modules
option (extension '%s'), "
+
(
"in
'ext_modules'
option (extension '%s'), "
+
"'sources' must be present and must be "
+
"'sources' must be present and must be "
+
"a list of source filenames"
)
%
extension_name
"a list of source filenames"
)
%
extension_name
sources
=
list
(
sources
)
sources
=
list
(
sources
)
...
...
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