mirror of
https://github.com/zeldaret/tp
synced 2026-05-23 06:54:28 -04:00
transform-dep.py: fake the -MP compiler option
This commit is contained in:
@@ -50,6 +50,7 @@ def import_d_file(in_file: str) -> str:
|
||||
else:
|
||||
out_lines.append(line.replace('\\', '/'))
|
||||
|
||||
headers: List[str] = []
|
||||
for line in it:
|
||||
suffix = ''
|
||||
if line.endswith(' \\\n'):
|
||||
@@ -59,7 +60,10 @@ def import_d_file(in_file: str) -> str:
|
||||
path = line.strip()
|
||||
|
||||
path = convert_path(path)
|
||||
headers.append(path)
|
||||
out_lines.append(f"\t{path}{suffix}\n")
|
||||
# the metrowerks compiler doesn't support -MP
|
||||
out_lines.extend([f'{header}:\n' for header in headers])
|
||||
|
||||
return ''.join(out_lines)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user