This commit is contained in:
Marc Beninca 2024-03-15 10:32:19 +01:00
parent 3eccd76e8c
commit 2eb71e6412
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F
14 changed files with 0 additions and 0 deletions

32
mrmp/subsystem.py Normal file
View file

@ -0,0 +1,32 @@
import os
import catalog
CRT = 'mingw'
MAIN = 'msys'
FAMILIES = [MAIN, 'clang', 'mingw', 'ucrt']
class SubSystem:
def __init__(self, architecture, name):
self.architecture = architecture
self.name = name
# path
list = []
if self.name != MAIN:
list.append(CRT)
list.append(self.name)
if self.name == MAIN:
list.append(self.architecture.name)
self.path = os.path.join(*list)
# catalog
self.catalog = catalog.Catalog(self)
def __str__(self):
lines = [
f'Architecture: {self.architecture.name}',
f' Name: {self.name}',
f' Path: {self.path}',
]
return os.linesep.join(lines)