From 4a1a5c7bad9fc79c8e8eb38729363a3c11ac5f53 Mon Sep 17 00:00:00 2001 From: Ryan Houdek Date: Sat, 11 Jan 2025 18:04:00 -0800 Subject: [PATCH] Windows: Removes opaque wine_builtin binary Instead generate it with an echo command which is easier to see what it is doing. It's a trivial file that is just a string and 16 zeroes. Brought up by #4267 --- Source/Windows/CMakeLists.txt | 8 +++++++- Source/Windows/wine_builtin.bin | Bin 32 -> 0 bytes 2 files changed, 7 insertions(+), 1 deletion(-) delete mode 100644 Source/Windows/wine_builtin.bin diff --git a/Source/Windows/CMakeLists.txt b/Source/Windows/CMakeLists.txt index 431e37db7f..df9111fa67 100644 --- a/Source/Windows/CMakeLists.txt +++ b/Source/Windows/CMakeLists.txt @@ -12,10 +12,16 @@ function(build_implib name) add_dependencies(${name_ex} ${name_ex}lib) endfunction() +# Output DLL patching binary. Needs to be exactly 32-bytes. +add_custom_target(wine_builtin_patch + COMMAND echo -n 'Wine builtin DLL\\0\\0\\0\\0\\0\\0\\0\\0\\0\\0\\0\\0\\0\\0\\0\\0' > ${CMAKE_BINARY_DIR}/wine_builtin.bin + BYPRODUCTS ${CMAKE_BINARY_DIR}/wine_builtin.bin) + function(patch_library_wine target) + add_dependencies(${target} wine_builtin_patch) add_custom_command( TARGET ${target} POST_BUILD - COMMAND dd bs=32 count=1 seek=2 conv=notrunc if=${CMAKE_SOURCE_DIR}/Source/Windows/wine_builtin.bin of=$ + COMMAND dd bs=32 count=1 seek=2 conv=notrunc if=${CMAKE_BINARY_DIR}/wine_builtin.bin of=$ ) endfunction() diff --git a/Source/Windows/wine_builtin.bin b/Source/Windows/wine_builtin.bin deleted file mode 100644 index ac2c71885769f4a3fe878f6d9d8d64d72dca36fd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 32 ZcmWH~%u7{BD$UF($;?x5@$q3m0|1PT1*ZT2