You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-12-20 14:16:06 +02:00
When building DLLs on ARM64EC, the default use of `dumpbin -linkermember:1` fails because ARM64EC static libraries use a different linker member format. Use `-linkermember:32` for ARM64EC to correctly extract symbols. Additionally, MSVC inserts $exit_thunk and $entry_thunk symbols for ARM64EC to handle x64 ↔ ARM64 transitions. These are internal thunks and must not be exported. Filter them out when generating the .def file to avoid unresolved symbols or invalid exports. Trim out the leading '#' on ARM64EC function symbols. This is only relevant on ARM64EC, but it is benign to do that filtering on all architectures (such symbols aren't expected on other architectures). Simplify the sed command by removing the symbol address with a sed expression instead of a later "cut" command. This ensures correct symbol extraction and stable DLL generation on ARM64EC targets, while keeping behavior unchanged for other Windows architectures.