From e0066b6fa6be36c1a3428ecd53d2527abb07c3d2 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 14 Aug 2024 10:02:56 -0700 Subject: [PATCH] Add NEWLINE_STYLE to cmake install Looks like CMake before 3.20.0 doesn't generate newlines at all without this configuration option. CMake 3.20.0 and prior, however, generates newlines by default which is why this didn't show up in CI or development. Closes #9126 --- crates/c-api/cmake/install-headers.cmake | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/crates/c-api/cmake/install-headers.cmake b/crates/c-api/cmake/install-headers.cmake index 2468cfa77768..528e20823048 100644 --- a/crates/c-api/cmake/install-headers.cmake +++ b/crates/c-api/cmake/install-headers.cmake @@ -11,7 +11,8 @@ set(include_src "${CMAKE_CURRENT_LIST_DIR}/../include") message(STATUS "Installing: ${dst}/wasmtime/conf.h") file(READ "${include_src}/wasmtime/conf.h.in" conf_h) -file(CONFIGURE OUTPUT "${dst}/wasmtime/conf.h" CONTENT "${conf_h}") +file(CONFIGURE OUTPUT "${dst}/wasmtime/conf.h" CONTENT "${conf_h}" + NEWLINE_STYLE CRLF) file(INSTALL "${include_src}/" DESTINATION "${dst}" FILES_MATCHING REGEX "\\.hh?$")