mirror of
https://github.com/ValveSoftware/Proton.git
synced 2025-05-17 08:58:06 +03:00
vrclient: Exclude some unused structs.
This commit is contained in:
parent
1f3b23fbba
commit
4d4acd55cc
@ -219,6 +219,9 @@ all_sources = {}
|
|||||||
all_versions = {}
|
all_versions = {}
|
||||||
unique_structs = []
|
unique_structs = []
|
||||||
|
|
||||||
|
MANUAL_STRUCTS = [
|
||||||
|
"COpenVRContext", # not actually used
|
||||||
|
]
|
||||||
|
|
||||||
UNIX_FUNCS = [
|
UNIX_FUNCS = [
|
||||||
'vrclient_init',
|
'vrclient_init',
|
||||||
@ -1060,6 +1063,12 @@ def find_struct_abis(name):
|
|||||||
|
|
||||||
def struct_needs_conversion(struct):
|
def struct_needs_conversion(struct):
|
||||||
name = canonical_typename(struct)
|
name = canonical_typename(struct)
|
||||||
|
if name in EXEMPT_STRUCTS:
|
||||||
|
return False
|
||||||
|
if name in unique_structs:
|
||||||
|
return False
|
||||||
|
if name in MANUAL_STRUCTS:
|
||||||
|
return True
|
||||||
|
|
||||||
abis = find_struct_abis(name)
|
abis = find_struct_abis(name)
|
||||||
if abis is None:
|
if abis is None:
|
||||||
@ -1698,6 +1707,8 @@ with open('unixlib_generated.cpp', 'w') as file:
|
|||||||
abis['w32'].write_checks(out, "w32_")
|
abis['w32'].write_checks(out, "w32_")
|
||||||
abis['u32'].write_checks(out, "u32_")
|
abis['u32'].write_checks(out, "u32_")
|
||||||
|
|
||||||
|
if name in MANUAL_STRUCTS: continue
|
||||||
|
|
||||||
for sdkver, abis in structs.items():
|
for sdkver, abis in structs.items():
|
||||||
if name not in all_versions[sdkver]: continue
|
if name not in all_versions[sdkver]: continue
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user