ladybird/Kernel/mkmap.sh
Gunnar Beutner 67f0c0d5f0 Kernel+LibELF: Don't demangle symbols in the kernel
Instead we should just generate kernel.map in such a way that it already
contains demangled symbols.
2021-07-06 19:08:22 +02:00

12 lines
289 B
Bash

#!/bin/sh
tmp=$(mktemp)
if [ -f Kernel32 ]; then
kernel_binary=Kernel32
else
kernel_binary=Kernel64
fi
nm -n $kernel_binary | awk '{ if ($2 != "a") print; }' | uniq > "$tmp"
printf "%08x\n" "$(wc -l "$tmp" | cut -f1 -d' ')" > kernel.map
c++filt < "$tmp" >> kernel.map
rm -f "$tmp"