get_subsystems
This commit is contained in:
parent
b155d8ad83
commit
d03d9ebcbf
2 changed files with 25 additions and 13 deletions
22
msys.py
22
msys.py
|
@ -4,14 +4,28 @@ ARCHITECTURES_BITS = {
|
|||
'x86_64': 64,
|
||||
'i686': 32,
|
||||
}
|
||||
ARCHITECTURES_SUBSYSTEMS = {
|
||||
'x86_64': ['msys', 'clang64', 'mingw64', 'ucrt64'],
|
||||
'i686': ['msys', 'clang32', 'mingw32'],
|
||||
}
|
||||
CATALOG = '.files'
|
||||
CHARSET = 'u8'
|
||||
CRT = 'mingw'
|
||||
DISTRIBUTION = 'distrib'
|
||||
SIGNATURE = '.sig'
|
||||
SUBSYSTEM = 'msys'
|
||||
|
||||
ARCHITECTURES_SUBSYSTEMS = {
|
||||
'x86_64': [SUBSYSTEM, 'clang64', 'mingw64', 'ucrt64'],
|
||||
'i686': [SUBSYSTEM, 'clang32', 'mingw32'],
|
||||
}
|
||||
SUBSYSTEMS = [SUBSYSTEM, 'clang', 'mingw', 'ucrt']
|
||||
|
||||
|
||||
def get_subsystems(architecture, families):
|
||||
list = []
|
||||
bits = ARCHITECTURES_BITS[architecture]
|
||||
for family in families:
|
||||
if family == SUBSYSTEM:
|
||||
subsystem = family
|
||||
else:
|
||||
subsystem = f'{family}{bits}'
|
||||
if subsystem in ARCHITECTURES_SUBSYSTEMS[architecture]:
|
||||
list.append(subsystem)
|
||||
return list
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue