aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/project/platform.py
diff options
context:
space:
mode:
Diffstat (limited to 'project/platform.py')
-rw-r--r--project/platform.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/project/platform.py b/project/platform.py
index 249238e..8eb7f3e 100644
--- a/project/platform.py
+++ b/project/platform.py
@@ -45,3 +45,11 @@ class Platform(Enum):
if self is Platform.X64:
return 64
raise NotImplementedError(f'unsupported platform: {self}')
+
+ def get_cmake_arch(self):
+ '''Maps to CMake's -A argument for MSVC.'''
+ if self is Platform.X86:
+ return 'Win32'
+ if self is Platform.X64:
+ return 'x64'
+ raise NotImplementedError(f'unsupported platform: {self}')