You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Properly handle paths with spaces in autolinking (#47388)
Summary:
Pull Request resolved: #47388Fixes#47364Fixes#47377Fixes#37124
We're having problems is a path contains a space ' ' because when autolinking,
the `add_subdirectory()` function of CMake consider the path with space as 2 parameters.
This fixes it by properly quoting the path.
Changelog:
[Android] [Fixed] - Properly handle paths with spaces in autolinking
Reviewed By: cipolleschi
Differential Revision: D65434413
fbshipit-source-id: b9147482f98f7e222405cc8d9e6f3c17a5f4ed02
Copy file name to clipboardExpand all lines: packages/gradle-plugin/react-native-gradle-plugin/src/main/kotlin/com/facebook/react/tasks/GenerateAutolinkingNewArchitecturesFileTask.kt
+7-4
Original file line number
Diff line number
Diff line change
@@ -59,15 +59,15 @@ abstract class GenerateAutolinkingNewArchitecturesFileTask : DefaultTask() {
59
59
val cxxModuleCMakeListsPath = dep.cxxModuleCMakeListsPath
60
60
if (libraryName !=null&& cmakeListsPath !=null) {
61
61
// If user provided a custom cmakeListsPath, let's honor it.
62
-
val nativeFolderPath =cmakeListsPath.replace("CMakeLists.txt", "")
62
+
val nativeFolderPath =sanitizeCmakeListsPath(cmakeListsPath)
Copy file name to clipboardExpand all lines: packages/gradle-plugin/react-native-gradle-plugin/src/test/kotlin/com/facebook/react/tasks/GenerateAutolinkingNewArchitecturesFileTaskTest.kt
0 commit comments