https://bugs.gentoo.org/771744 https://github.com/WebKit/WebKit/pull/12358 From 5cda2bac84e6900401810b56ba4de82de714cae0 Mon Sep 17 00:00:00 2001 From: Sam James Date: Tue, 4 Apr 2023 04:31:01 +0100 Subject: [PATCH] postprocess-asm rule doesn't respect RUBY_EXECUTABLE https://bugs.webkit.org/show_bug.cgi?id=254965 Reviewed by NOBODY (OOPS!). postprocess-asm is a Ruby script with #/!/usr/bin/env ruby as its shebang which looks up Ruby in PATH. webkit, however, has RUBY_EXECUTABLE as a CMake option. It's possible for the Ruby used by CMake (and the other rules during the build) to be different to the first Ruby found in PATH. This makes the usage for postprocess-asm consistent with other uses in webkit. * Source/JavaScriptCore/CMakeLists.txt --- a/Source/JavaScriptCore/CMakeLists.txt +++ b/Source/JavaScriptCore/CMakeLists.txt @@ -1507,7 +1507,7 @@ endif () if (CMAKE_COMPILER_IS_GNUCXX AND GCC_OFFLINEASM_SOURCE_MAP) message(STATUS "Enabling asm postprocessing") - set(LowLevelInterpreter_LAUNCHER "${JavaScriptCore_SCRIPTS_SOURCES_DIR}/postprocess-asm") + set(LowLevelInterpreter_LAUNCHER "${RUBY_EXECUTABLE} ${JavaScriptCore_SCRIPTS_SOURCES_DIR}/postprocess-asm") get_target_property(PROP_RULE_LAUNCH_COMPILE LowLevelInterpreterLib RULE_LAUNCH_COMPILE) if (PROP_RULE_LAUNCH_COMPILE) set(LowLevelInterpreter_LAUNCHER "${LowLevelInterpreter_LAUNCHER} ${PROP_RULE_LAUNCH_COMPILE}")