forked from lthn/blockchain
Customize build folder layout based on compiler
Updated the layout method to set different build and generator folder paths depending on whether the compiler is MSVC or not. This improves compatibility with multi-configuration generators on MSVC and single-configuration generators on other platforms.
This commit is contained in:
parent
89c6833845
commit
ba3296cec6
1 changed files with 7 additions and 1 deletions
|
|
@ -39,7 +39,13 @@ class BlockchainConan(ConanFile):
|
|||
deps.generate()
|
||||
|
||||
def layout(self):
|
||||
cmake_layout(self)
|
||||
multi = True if self.settings.get_safe("compiler") == "msvc" else False
|
||||
if multi:
|
||||
self.folders.generators = os.path.join("build", "generators")
|
||||
self.folders.build = "build"
|
||||
else:
|
||||
self.folders.generators = os.path.join("build", str(self.settings.build_type).lower(), "generators")
|
||||
self.folders.build = os.path.join("build", str(self.settings.build_type).lower())
|
||||
|
||||
def build(self):
|
||||
cmake = CMake(self)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue