From 462d71cbef02ef119fc2aa480b98cfeedde46441 Mon Sep 17 00:00:00 2001 From: "Jasper St. Pierre" Date: Mon, 10 May 2021 08:54:07 -0700 Subject: Makefile fixes / JUTNameTab (#129) * Makefile: Fix issues with iconv causing it to break under devkitPro / msys The version of iconv included in devkitPro does not have a -o option, so replace it with normal shell redirection. Also, SHIFT-JIS does not have a mapping for ~, so output the Windows CP932 variant instead, which does. See: https://en.wikipedia.org/wiki/Tilde#Unicode_and_Shift_JIS_encoding_of_wave_dash https://en.wikipedia.org/wiki/Code_page_932_(Microsoft_Windows)#Single-byte_character_differences * Update diff configuration -Bbinary doesn't seem to work with my copy of bjdump (it says it can't decode unknown architecture) Cheese things by using expected/ instead of having the user place things manually. * JUTNameTab * J3DPacket / J3DDrawBuffer * format Co-authored-by: lepelog --- tools/libdol2asm/exporter/makefile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tools/libdol2asm') diff --git a/tools/libdol2asm/exporter/makefile.py b/tools/libdol2asm/exporter/makefile.py index 21cb7cbc25..f06fc51cb9 100644 --- a/tools/libdol2asm/exporter/makefile.py +++ b/tools/libdol2asm/exporter/makefile.py @@ -61,7 +61,7 @@ async def create_library(library: Library): await builder.write(f"{o_path}/%.o: {cpp_path}/%.cpp") await builder.write(f"\t@mkdir -p $(@D)") await builder.write(f"\t@echo building... $<") - await builder.write(f"\t@iconv -f UTF-8 -t SHIFT-JIS -o $@.iconv.cpp $<") + await builder.write(f"\t@iconv -f UTF-8 -t CP932 < $< > $@.iconv.cpp") await builder.write(f"\t@$(CC) $(CFLAGS) $({prefix}_CFLAGS) -c -o $@ $@.iconv.cpp") await builder.write("") @@ -149,7 +149,7 @@ async def create_rel(module: Module, rel_path: Path): await builder.write(f"{o_path}/%.o: {cpp_path}/%.cpp") await builder.write(f"\t@echo [{module.index:>3}] building $@") await builder.write(f"\t@mkdir -p $(@D)") - await builder.write(f"\t@iconv -f UTF-8 -t SHIFT-JIS -o $@.iconv.cpp $<") + await builder.write(f"\t@iconv -f UTF-8 -t CP932 < $< > $@.iconv.cpp") await builder.write(f"\t@$(CC) $(CFLAGS) $({prefix}_CFLAGS) -c -o $@ $@.iconv.cpp") await builder.write("") -- cgit v1.2.3