From c1c1dfd533ea5d56b85c3a3cad29216f8dfd747b Mon Sep 17 00:00:00 2001 From: Lightning Date: Fri, 14 Oct 2022 15:50:43 -0700 Subject: [PATCH] Fix z64 building in debug mode (#822) --- tools/build/configure.py | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) diff --git a/tools/build/configure.py b/tools/build/configure.py index 75c6a3297c..053a104ef7 100755 --- a/tools/build/configure.py +++ b/tools/build/configure.py @@ -76,17 +76,9 @@ def write_ninja_rules(ninja: ninja_syntax.Writer, cpp: str, cppflags: str, extra command=f"{cross}ld -T ver/$version/build/undefined_syms.txt -T ver/$version/undefined_syms_auto.txt -T ver/$version/undefined_funcs_auto.txt -Map $mapfile --no-check-sections -T $in -o $out", ) - objcopy_sections = "" - if debug: - ninja.rule("genobjcopy", - description="generate $out", - command=f"$python {BUILD_TOOLS}/genobjcopy.py $in $out", - ) - objcopy_sections = "@ver/$version/build/objcopy_sections.txt " - ninja.rule("z64", description="rom $out", - command=f"{cross}objcopy {objcopy_sections} $in $out -O binary && {BUILD_TOOLS}/rom/n64crc $out", + command=f"{cross}objcopy $in $out -O binary && {BUILD_TOOLS}/rom/n64crc $out", ) ninja.rule("sha1sum", @@ -262,9 +254,6 @@ class Configure: def build_path(self) -> Path: return Path(f"ver/{self.version}/build") - def objcopy_sections_path(self) -> Path: - return self.build_path() / "objcopy_sections.txt" - def undefined_syms_path(self) -> Path: return self.build_path() / "undefined_syms.txt" @@ -657,14 +646,6 @@ class Configure: else: raise Exception(f"don't know how to build {seg.__class__.__name__} '{seg.name}'") - # Create objcopy section list - if debug: - ninja.build( - str(self.objcopy_sections_path()), - "genobjcopy", - str(self.build_path() / "elf_sections.txt"), - ) - # Run undefined_syms through cpp ninja.build( str(self.undefined_syms_path()), @@ -674,8 +655,6 @@ class Configure: # Build elf, z64, ok additional_objects = [str(self.undefined_syms_path())] - if debug: - additional_objects += [str(self.objcopy_sections_path())] ninja.build( str(self.elf_path()),