Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cython
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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Gwenaël Samain
cython
Commits
0855d80e
Commit
0855d80e
authored
Nov 10, 2009
by
David Cournapeau
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Optional setuptools-based cython build
parent
8b27f1d8
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
24 additions
and
3 deletions
+24
-3
Cython/Compiler/Main.py
Cython/Compiler/Main.py
+2
-0
setup.py
setup.py
+18
-3
setupegg.py
setupegg.py
+4
-0
No files found.
Cython/Compiler/Main.py
View file @
0855d80e
...
...
@@ -741,6 +741,8 @@ def compile(source, options = None, c_compile = 0, c_link = 0,
# Main command-line entry point
#
#------------------------------------------------------------------------
def
setuptools_main
():
return
main
(
command_line
=
1
)
def
main
(
command_line
=
0
):
args
=
sys
.
argv
[
1
:]
...
...
setup.py
View file @
0855d80e
...
...
@@ -40,11 +40,25 @@ else:
'Compiler/*.pxd'
,
'Runtime/*.pyx'
]}
if
os
.
name
==
"posix"
:
scripts
=
[
"bin/cython"
]
# This dict is used for passing extra arguments that are setuptools
# specific to setup
setuptools_extra_args
=
{}
if
'setuptools'
in
sys
.
modules
:
setuptools_extra_args
[
'zip_safe'
]
=
False
setuptools_extra_args
[
'entry_points'
]
=
{
'console_scripts'
:
[
'cython = Cython.Compiler.Main:setuptools_main'
,
]
}
scripts
=
[]
else
:
if
os
.
name
==
"posix"
:
scripts
=
[
"bin/cython"
]
else
:
scripts
=
[
"cython.py"
]
try
:
if
sys
.
version_info
[
0
]
>=
3
:
raise
ValueError
...
...
@@ -93,6 +107,7 @@ except ValueError:
print
(
"ERROR: %s"
%
sys
.
exc_info
()[
1
])
print
(
"Extension module compilation failed, using plain Python implementation"
)
setup_args
.
update
(
setuptools_extra_args
)
from
Cython.Compiler.Version
import
version
...
...
setupegg.py
0 → 100644
View file @
0855d80e
#!/usr/bin/env python
"""Wrapper to run setup.py using setuptools."""
import
setuptools
execfile
(
'setup.py'
)
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