mirror of
https://github.com/zeldaret/oot3d.git
synced 2026-09-26 13:33:22 -04:00
a87ddae432
* pull known Actor functions GLOBAL_ASMs into their cpp files * attempt to pull unidentified actor functions GLOBAL_ASMs into their corresponding source files by scanning the call-graph
23 lines
589 B
Python
23 lines
589 B
Python
import os
|
|
import subprocess
|
|
import sys
|
|
from pathlib import Path
|
|
|
|
sourceFile: str = sys.argv[1]
|
|
|
|
includePaths: list[Path] = ["include",
|
|
"library/3ds_sdk/include",
|
|
"src/game"]
|
|
|
|
ccArgs = "-o ctx.c -E "
|
|
for include in includePaths:
|
|
ccArgs = ccArgs + f"-I{include} "
|
|
|
|
if 'ARMCC_PATH' in os.environ:
|
|
CC: Path = Path(os.environ['ARMCC_PATH']) / "win_32-pentium/armcc.exe"
|
|
else:
|
|
print("ARMCC_PATH environment variable is not set, trying gcc")
|
|
CC: Path = Path("gcc")
|
|
|
|
subprocess.run(f"{CC} {ccArgs} {sourceFile}", shell=True)
|