Fixing failure building RN codegen CLI on Windows (#34791)

Summary:
Ensuring the file paths uses forward slashes as separator to avoid the characters from being interpreted as ASCII escape characters.

## Changelog

Fixing build failure building RN codegen CLI on Windows. Ensuring the file paths uses forward slashes as separator to avoid the characters from being interpreted as ASCII escape characters.

[Android] [Fixed] - Fixing failure building RN codegen CLI on Windows

Pull Request resolved: https://github.com/facebook/react-native/pull/34791

Test Plan: Ensured RN main branch builds on Windows with new architecture turned on.

Reviewed By: cipolleschi

Differential Revision: D39889468

Pulled By: cipolleschi

fbshipit-source-id: 7d79eac9f433908cc86dd7ca2eec841739ef6365

# Conflicts:
#	ReactAndroid/cmake-utils/ReactNative-application.cmake
This commit is contained in:
Anandraj Govindan
2022-10-11 13:23:51 +01:00
committed by Lorenzo Sciandra
parent e2645a59f6
commit 0c2f55d05f
@@ -18,14 +18,19 @@ set(CMAKE_VERBOSE_MAKEFILE on)
include(${REACT_ANDROID_DIR}/cmake-utils/Android-prebuilt.cmake)
file(GLOB input_SRC CONFIGURE_DEPENDS
set(BUILD_DIR ${PROJECT_BUILD_DIR})
if(CMAKE_HOST_WIN32)
string(REPLACE "\\" "/" BUILD_DIR ${BUILD_DIR})
endif()
file(GLOB input_SRC CONFIGURE_DEPENDS
*.cpp
${PROJECT_BUILD_DIR}/generated/rncli/src/main/jni/*.cpp)
${BUILD_DIR}/generated/rncli/src/main/jni/*.cpp)
add_library(${CMAKE_PROJECT_NAME} SHARED ${input_SRC})
target_include_directories(${CMAKE_PROJECT_NAME}
PUBLIC
target_include_directories(${CMAKE_PROJECT_NAME}
PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}
${PROJECT_BUILD_DIR}/generated/rncli/src/main/jni)