From 583d00012e75b0739df93c06fd957a102e1bb9d7 Mon Sep 17 00:00:00 2001 From: Matthias Volk Date: Mon, 30 Sep 2019 20:31:45 +0200 Subject: [PATCH] Fixed loading of build config --- setup.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index de75c00..171fc8c 100755 --- a/setup.py +++ b/setup.py @@ -164,8 +164,6 @@ class CMakeBuild(build_ext): def initialize_options(self): build_ext.initialize_options(self) - # Load setup config - self.config.load_from_file("build/build_config.cfg") # Set default values for custom cmdline flags self.storm_dir = None self.disable_dft = None @@ -175,6 +173,9 @@ class CMakeBuild(build_ext): def finalize_options(self): build_ext.finalize_options(self) + # Load setup config + # This can only be done after the finalization step, because otherwise build_temp is not initialized yet. + self.config.load_from_file(os.path.join(self.build_temp, "build_config.cfg")) # Update setup config self.config.update("storm_dir", self.storm_dir) self.config.update("disable_dft", self.disable_dft)