diff --git a/packages/react-native/ReactAndroid/src/main/jni/react/hermes/reactexecutor/CMakeLists.txt b/packages/react-native/ReactAndroid/src/main/jni/react/hermes/reactexecutor/CMakeLists.txt index b28df6a8a2fc59..920732a0db8ed4 100644 --- a/packages/react-native/ReactAndroid/src/main/jni/react/hermes/reactexecutor/CMakeLists.txt +++ b/packages/react-native/ReactAndroid/src/main/jni/react/hermes/reactexecutor/CMakeLists.txt @@ -27,8 +27,4 @@ target_link_libraries( target_compile_reactnative_options(hermes_executor PRIVATE) if(${CMAKE_BUILD_TYPE} MATCHES Debug OR REACT_NATIVE_DEBUG_OPTIMIZED) target_compile_options(hermes_executor PRIVATE -DHERMES_ENABLE_DEBUGGER=1) - - if (HERMES_V1_ENABLED) - target_compile_options(hermes_executor PRIVATE -DHERMES_V1_ENABLED=1) - endif() endif() diff --git a/packages/react-native/ReactAndroid/src/main/jni/react/runtime/hermes/jni/CMakeLists.txt b/packages/react-native/ReactAndroid/src/main/jni/react/runtime/hermes/jni/CMakeLists.txt index 3ec451152cf220..13f7c86023d1a7 100644 --- a/packages/react-native/ReactAndroid/src/main/jni/react/runtime/hermes/jni/CMakeLists.txt +++ b/packages/react-native/ReactAndroid/src/main/jni/react/runtime/hermes/jni/CMakeLists.txt @@ -29,8 +29,4 @@ target_link_libraries(hermesinstancejni target_compile_reactnative_options(hermesinstancejni PRIVATE) if(${CMAKE_BUILD_TYPE} MATCHES Debug OR REACT_NATIVE_DEBUG_OPTIMIZED) target_compile_options(hermesinstancejni PRIVATE -DHERMES_ENABLE_DEBUGGER=1) - - if (HERMES_V1_ENABLED) - target_compile_options(hermesinstancejni PRIVATE -DHERMES_V1_ENABLED=1) - endif() endif () diff --git a/packages/react-native/ReactAndroid/src/main/jni/react/runtime/jni/CMakeLists.txt b/packages/react-native/ReactAndroid/src/main/jni/react/runtime/jni/CMakeLists.txt index 5394cb4af015ec..8987aed037633a 100644 --- a/packages/react-native/ReactAndroid/src/main/jni/react/runtime/jni/CMakeLists.txt +++ b/packages/react-native/ReactAndroid/src/main/jni/react/runtime/jni/CMakeLists.txt @@ -19,10 +19,6 @@ add_library(rninstance target_compile_reactnative_options(rninstance PRIVATE) if(${CMAKE_BUILD_TYPE} MATCHES Debug OR REACT_NATIVE_DEBUG_OPTIMIZED) target_compile_options(rninstance PRIVATE -DHERMES_ENABLE_DEBUGGER=1) - - if (HERMES_V1_ENABLED) - target_compile_options(rninstance PRIVATE -DHERMES_V1_ENABLED=1) - endif() endif () target_merge_so(rninstance) diff --git a/packages/react-native/ReactCommon/cmake-utils/react-native-flags.cmake b/packages/react-native/ReactCommon/cmake-utils/react-native-flags.cmake index d005a4e0b0d89e..b8a420af216d8a 100644 --- a/packages/react-native/ReactCommon/cmake-utils/react-native-flags.cmake +++ b/packages/react-native/ReactCommon/cmake-utils/react-native-flags.cmake @@ -32,4 +32,7 @@ function(target_compile_reactnative_options target_name scope) if(ANDROID) target_compile_definitions(${target_name} ${scope} RN_SERIALIZABLE_STATE) endif() + if(HERMES_V1_ENABLED) + target_compile_definitions(${target_name} ${scope} HERMES_V1_ENABLED=1) + endif() endfunction() diff --git a/packages/react-native/ReactCommon/hermes/executor/CMakeLists.txt b/packages/react-native/ReactCommon/hermes/executor/CMakeLists.txt index cf991e1729b0a6..3731086f6d7dcc 100644 --- a/packages/react-native/ReactCommon/hermes/executor/CMakeLists.txt +++ b/packages/react-native/ReactCommon/hermes/executor/CMakeLists.txt @@ -32,10 +32,6 @@ if(${CMAKE_BUILD_TYPE} MATCHES Debug OR REACT_NATIVE_DEBUG_OPTIMIZED) PRIVATE -DHERMES_ENABLE_DEBUGGER=1 ) - - if (HERMES_V1_ENABLED) - target_compile_options(hermes_executor_common PRIVATE -DHERMES_V1_ENABLED=1) - endif() else() target_compile_options( hermes_executor_common diff --git a/packages/react-native/ReactCommon/hermes/inspector-modern/CMakeLists.txt b/packages/react-native/ReactCommon/hermes/inspector-modern/CMakeLists.txt index d392615a80e909..ed2fbd87135565 100644 --- a/packages/react-native/ReactCommon/hermes/inspector-modern/CMakeLists.txt +++ b/packages/react-native/ReactCommon/hermes/inspector-modern/CMakeLists.txt @@ -23,10 +23,6 @@ if(${CMAKE_BUILD_TYPE} MATCHES Debug OR REACT_NATIVE_DEBUG_OPTIMIZED) PRIVATE -DHERMES_ENABLE_DEBUGGER=1 ) - - if (HERMES_V1_ENABLED) - target_compile_options(hermes_inspector_modern PRIVATE -DHERMES_V1_ENABLED=1) - endif() endif() target_include_directories(hermes_inspector_modern PUBLIC ${REACT_COMMON_DIR}) diff --git a/packages/react-native/ReactCommon/react/runtime/CMakeLists.txt b/packages/react-native/ReactCommon/react/runtime/CMakeLists.txt index 25927837d9b620..0cf910be5bfda1 100644 --- a/packages/react-native/ReactCommon/react/runtime/CMakeLists.txt +++ b/packages/react-native/ReactCommon/react/runtime/CMakeLists.txt @@ -18,10 +18,6 @@ add_library(bridgeless target_compile_reactnative_options(bridgeless PRIVATE) if(${CMAKE_BUILD_TYPE} MATCHES Debug OR REACT_NATIVE_DEBUG_OPTIMIZED) target_compile_options(bridgeless PRIVATE -DHERMES_ENABLE_DEBUGGER=1) - - if (HERMES_V1_ENABLED) - target_compile_options(bridgeless PRIVATE -DHERMES_V1_ENABLED=1) - endif() endif () target_include_directories(bridgeless PUBLIC .) diff --git a/packages/react-native/ReactCommon/react/runtime/hermes/CMakeLists.txt b/packages/react-native/ReactCommon/react/runtime/hermes/CMakeLists.txt index a237dfed110d0a..07b2a26b44222f 100644 --- a/packages/react-native/ReactCommon/react/runtime/hermes/CMakeLists.txt +++ b/packages/react-native/ReactCommon/react/runtime/hermes/CMakeLists.txt @@ -35,8 +35,4 @@ if(${CMAKE_BUILD_TYPE} MATCHES Debug OR REACT_NATIVE_DEBUG_OPTIMIZED) PRIVATE -DHERMES_ENABLE_DEBUGGER=1 ) - - if (HERMES_V1_ENABLED) - target_compile_options(bridgelesshermes PRIVATE -DHERMES_V1_ENABLED=1) - endif() endif()