I'm building extension with CMake
setup( ... cmdclass={'build_ext':Cmakebuildclass} )
where Cmakebuildclass is a custom class. Inside run() function of this class, I'm building the extension It creates a temporary build directory where all artifacts get stored. However, at the end I try to access it but it fails
Cmakebuildclass
error: [Errno 2] No such file or directory: 'build/temp.linux-x86_64-3.6
Temporary build directory [e.g. build/temp.linux-x86_64-3.6] gets deleted once the targets are built.
build/temp.linux-x86_64-3.6
It's copied over to the lib folder within build generally build/lib.linux-x86_64-3.6/ So use build_lib variable instead of build_temp
build/lib.linux-x86_64-3.6/
For code: https://github.com/python/cpython/blob/e5fe509054183bed9aef42c92da8407d339e8af8/Lib/distutils/command/build_ext.py#L108
Details: https://github.com/python/cpython/blob/e5fe509054183bed9aef42c92da8407d339e8af8/Lib/distutils/command/build_ext.py#L57-L60
1.4m articles
1.4m replys
5 comments
57.0k users