Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Android] expected buildFiles file CMakeLists.txt to exist #1070

Open
1 of 5 tasks
bulkinav opened this issue Mar 14, 2024 · 8 comments
Open
1 of 5 tasks

[Android] expected buildFiles file CMakeLists.txt to exist #1070

bulkinav opened this issue Mar 14, 2024 · 8 comments
Labels
bug Something isn't working

Comments

@bulkinav
Copy link

What happened?

Hello,

When I'm trying to build the my project (release or begug - it does not matter) with IS_NEW_ARCHITECTURE_ENABLED = TRUE, the following error occurs:

[CXX1409] /app-react/android/app/.cxx/RelWithDebInfo/152f6h3q/arm64-v8a/android_gradle_build.json appRelease|arm64-v8a : expected buildFiles file 'app-react/node_modules/@react-native-async-storage/async-storage/android/build/generated/source/codegen/jni/CMakeLists.txt' to exist

Version

1.22.3

What platforms are you seeing this issue on?

  • Android
  • iOS
  • macOS
  • Windows
  • web

System Information

"react-native": "0.73.6"

IS_NEW_ARCHITECTURE_ENABLED = TRUE
bridgelessEnabled = FALSE

macOS 14.4
Android Studio 2023.2.1

buildToolsVersion = "34.0.0"
minSdkVersion = 23 // Android 6.0 and above
compileSdkVersion = 34 // Android 14 (gives access to new APIs)
targetSdkVersion = 33 // Android 13
ndkVersion = "25.1.8937393"
kotlinVersion = "1.8.22"

Steps to Reproduce

  1. Enable NEW ARCHITECTURE
  2. Build the own project
@saczx
Copy link

saczx commented Mar 15, 2024

Same issue here

@tido64
Copy link
Member

tido64 commented Mar 15, 2024

What versions of the following packages are installed?

  • @react-native-community/cli
  • @react-native-community/cli-platform-android
  • @react-native-community/cli-platform-ios
  • @react-native/gradle-plugin
  • Gradle
  • JDK

I've tested this with 1.22.3 and React Native 0.73 locally and it builds just fine. Do you have a repro we can check out and investigate?

@saczx
Copy link

saczx commented Mar 15, 2024

Hi @tido64 ! The versions of the packages are these:

@react-native-community/cli => 12.3.6
@react-native-community/cli-platform-android => 12.3.6
@react-native-community/cli-platform-ios => 12.3.6
@react-native/gradle-plugin => 0.73.4 
Gradle => distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-all.zip (Android gradle plugin: 8.1.1, Gradle: 8.3)
JDK => openjdk17

@saczx
Copy link

saczx commented Mar 15, 2024

Workaround: I've had manually run ./gradlew generateCodegenArtifactsFromSchema in the android folder and now it seems to be working...

@tido64
Copy link
Member

tido64 commented Mar 15, 2024

Is @react-native-async-storage/async-storage in the package.json where you're running run-android from?

@saczx
Copy link

saczx commented Mar 15, 2024 via email

@tido64
Copy link
Member

tido64 commented Mar 15, 2024

If you have a minimal repro, we can try and have a look. This looks like an issue with codegen, though it's hard to say whether it's a setup issue or a bug. In any case, it has nothing to do with AsyncStorage.

@devethan
Copy link

Workaround: I've had manually run ./gradlew generateCodegenArtifactsFromSchema in the android folder and now it seems to be working...

Also it worked for me. Thanks.
What does this mean?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants