JSRF-Decompilation/ghidra/make_header.sh
KeybadeBlox 836b5eaa41 Incorporate known names from Smilebit code
The Yakuza 1 and 2 rereleases on the Wii U export function symbols,
preserving their names, and some debug data was also available in a PS2
release, providing some struct definitions.  These have been used to
rename analogous classes, functions, and member variables to the same
names used by Smilebit, plus a more general imitation of their naming
and typing conventions (i.e. Win32 style).
2026-03-31 20:24:13 -04:00

23 lines
636 B
Bash
Executable file

#!/bin/sh -eu
# Merges all header files in the decompilation into a C header file called
# jsrf.h for importing into Ghidra
# Create output file
printf '%s\n' '// Automatically generated mass header file for Ghidra' > jsrf.h
# Figuring out include order programmatically is awful, so we'll have to add
# all the headers here by hand in an order that functions properly
HEADERS="
XDK/CRT/stddef.h
XDK/Win32.h
XDK/CRT/ehdata.h
XDK/D3D.h
MUSASHI/MMatrix.hpp
JSRF/Action.hpp
JSRF/SaveData.hpp
"
# Process each header file into jsrf.h
for header in $HEADERS; do
awk -f headerconvert.awk "../decompile/src/$header" >> jsrf.h
done