mesonbuild/meson

compiler.run() current working directory and cleanup

開放

#2,519 建立於 2017年10月22日

 (2 則留言) (0 個反應) (0 位負責人)Python (1,465 個分叉)batch import
bugcompilershelp wanted

倉庫指標

星標
 (4,978 顆星)
PR 合併指標
 (PR 指標待抓取)

描述

I need to run code that writes files in compiler.run(). Turns out the current working directory is the same as for the meson (or ninja) invocation. If I don't manually clean up the generated files in the code being run, they're left behind.

I'd like to be able to pass the workdir to compiler.run() not unlike test() workdir, and/or have the code executed in a temporary directory that's automatically discarded afterwards. Having to do this yourself in a C or C++ code snippet is tedious at best.

貢獻者指南