frerich / clcache

A compiler cache for MSVC, much like ccache for gcc
Other
324 stars 83 forks source link

ENH: monkey: patch distsutils if USE_CLCACHE is set #287

Closed ghost closed 7 years ago

ghost commented 7 years ago

The goal here is to patch distutils to use clcache if the environment variable is set. This currently needs a test that I will add shortly.

Closes #284.

ghost commented 7 years ago

Unmarking as WIP because this mostly done except for errors that I haven't caught. Appveyor failed for a different reason, but feels like a separate PR.

ghost commented 7 years ago

Follow up to appveyor failure is #288.

ghost commented 7 years ago

@frerich Okay to merge.

ghost commented 7 years ago
clcache\monkey.py:17: error: Name 'ccompiler' already defined
clcache\monkey.py:24: error: Too many arguments
clcache\monkey.py:27: error: Too many arguments
clcache\monkey.py:31: error: Too many arguments
clcache\monkey.py:38: error: Too many arguments
clcache\monkey.py:40: error: Cannot assign to a method
clcache\monkey.py:40: error: Incompatible types in assignment (expression has type "Callable[[Any, List[str], VarArg(Any), KwArg(Any)], None]", variable has type "Callable[[CCompiler, List[str]], None]")
ghost commented 7 years ago

@frerich Ping.

frerich commented 7 years ago

@xoviat Thanks for pinging me, I'm currently a bit swamped. I just looked at this code again, and as far as I'm concerned, it's good to go - thanks a lot for your effort (and thanks for the test!). I'll merge this now.

Just one thing I'd like to ask for: can you maybe add a section to the Integration wiki page which explains how to enable clcache when using distutils?