aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/backend/backends.py
diff options
context:
space:
mode:
authorJussi Pakkanen <jpakkane@gmail.com>2021-04-18 21:25:46 +0300
committerJussi Pakkanen <jpakkane@gmail.com>2021-04-18 21:25:46 +0300
commitda5097fca3c37f9842879f5d54dc795ec813a0d2 (patch)
treed01edac46926289e9b630d989ef9ae9fec8d3d3f /mesonbuild/backend/backends.py
parentaaa8a828cb2b50394457894d70952d92f0fe76bd (diff)
downloadmeson-xcodehalfway.zip
meson-xcodehalfway.tar.gz
meson-xcodehalfway.tar.bz2
Xcode: regenerato project file when build conf changes.xcodehalfway
Diffstat (limited to 'mesonbuild/backend/backends.py')
-rw-r--r--mesonbuild/backend/backends.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/mesonbuild/backend/backends.py b/mesonbuild/backend/backends.py
index 90d7b79..04f3d23 100644
--- a/mesonbuild/backend/backends.py
+++ b/mesonbuild/backend/backends.py
@@ -49,6 +49,12 @@ if T.TYPE_CHECKING:
# Assembly files cannot be unitified and neither can LLVM IR files
LANGS_CANT_UNITY = ('d', 'fortran', 'vala')
+class RegenInfo:
+ def __init__(self, source_dir, build_dir, depfiles):
+ self.source_dir = source_dir
+ self.build_dir = build_dir
+ self.depfiles = depfiles
+
class TestProtocol(enum.Enum):
EXITCODE = 0
@@ -1007,6 +1013,16 @@ class Backend:
self.check_clock_skew(deps)
return deps
+ def generate_regen_info(self):
+ deps = self.get_regen_filelist()
+ regeninfo = RegenInfo(self.environment.get_source_dir(),
+ self.environment.get_build_dir(),
+ deps)
+ filename = os.path.join(self.environment.get_scratch_dir(),
+ 'regeninfo.dump')
+ with open(filename, 'wb') as f:
+ pickle.dump(regeninfo, f)
+
def check_clock_skew(self, file_list):
# If a file that leads to reconfiguration has a time
# stamp in the future, it will trigger an eternal reconfigure