architecture,distribution,subsystem

This commit is contained in:
Marc Beninca 2021-10-10 15:22:02 +02:00 committed by Marc Beninca
parent 9cd6155f8c
commit f849bca87c
3 changed files with 48 additions and 0 deletions

20
architecture.py Normal file
View file

@ -0,0 +1,20 @@
import os
import distribution
class Architecture:
def __init__(self, name):
self.name = name
self.distribution = distribution.Distribution(self)
# TODO subsystems
self.subsystems = {}
def __str__(self):
lines = [
f'Name: {self.name}',
]
return os.linesep.join(lines)
X86 = Architecture('x86_64')
I86 = Architecture('i686')

12
distribution.py Normal file
View file

@ -0,0 +1,12 @@
import os
class Distribution:
def __init__(self, architecture):
self.architecture = architecture
def __str__(self):
lines = [
f'Architecture: {self.architecture.name}',
]
return os.linesep.join(lines)

16
subsystem.py Normal file
View file

@ -0,0 +1,16 @@
import os
MAIN = 'msys'
class SubSystem:
def __init__(self, architecture):
self.architecture = architecture
self.name = name
def __str__(self):
lines = [
f'Architecture: {self.architecture.name}',
f' Name: {self.name}',
]
return os.linesep.join(lines)