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
Kirill Smelkov
cython
Commits
ce9b4f5c
Commit
ce9b4f5c
authored
Sep 28, 2016
by
Robert Bradshaw
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cleanup cache option.
parent
0fe4f394
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
8 deletions
+5
-8
Cython/Build/Dependencies.py
Cython/Build/Dependencies.py
+3
-3
Cython/Compiler/Main.py
Cython/Compiler/Main.py
+2
-5
No files found.
Cython/Build/Dependencies.py
View file @
ce9b4f5c
...
...
@@ -862,7 +862,7 @@ def cythonize(module_list, exclude=None, nthreads=0, aliases=None, quiet=False,
print
(
"Compiling %s because it changed."
%
source
)
else
:
print
(
"Compiling %s because it depends on %s."
%
(
source
,
dep
))
if
not
force
and
hasattr
(
options
,
'cache'
)
:
if
not
force
and
options
.
cache
:
extra
=
m
.
language
fingerprint
=
deps
.
transitive_fingerprint
(
source
,
extra
)
else
:
...
...
@@ -880,7 +880,7 @@ def cythonize(module_list, exclude=None, nthreads=0, aliases=None, quiet=False,
copy_to_build_dir
(
source
)
m
.
sources
=
new_sources
if
hasattr
(
options
,
'cache'
)
:
if
options
.
cache
:
if
not
os
.
path
.
exists
(
options
.
cache
):
os
.
makedirs
(
options
.
cache
)
to_compile
.
sort
()
...
...
@@ -943,7 +943,7 @@ def cythonize(module_list, exclude=None, nthreads=0, aliases=None, quiet=False,
print
(
"Failed compilations: %s"
%
', '
.
join
(
sorted
([
module
.
name
for
module
in
failed_modules
])))
if
hasattr
(
options
,
'cache'
)
:
if
options
.
cache
:
cleanup_cache
(
options
.
cache
,
getattr
(
options
,
'cache_size'
,
1024
*
1024
*
100
))
# cythonize() is often followed by the (non-Python-buffered)
# compiler output, flush now to avoid interleaving output.
...
...
Cython/Compiler/Main.py
View file @
ce9b4f5c
...
...
@@ -567,11 +567,8 @@ class CompilationOptions(object):
options
[
'language_level'
]
=
int
(
directives
[
'language_level'
])
if
'formal_grammar'
in
directives
and
'formal_grammar'
not
in
kw
:
options
[
'formal_grammar'
]
=
directives
[
'formal_grammar'
]
if
'cache'
in
options
:
if
options
[
'cache'
]
is
True
:
options
[
'cache'
]
=
os
.
path
.
expanduser
(
"~/.cycache"
)
elif
options
[
'cache'
]
in
(
False
,
None
):
del
options
[
'cache'
]
self
.
__dict__
.
update
(
options
)
...
...
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