Open JeffreyZhu0201 opened 3 weeks ago
i cant use react-native link on 0.76
This issue does not exist on macOS. I will test it on Windows 10 later to see.
The issue has been reproduced in Windows 10
First, the output error contains garbled characters. You need to set the language to English in android\gradle.properties
-org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m
+org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m -Duser.language=en -Duser.country=US
Then, re-run the build, and you will see the following error: illegal unicode escape
> Task :vpnLib:compileUiDebugJavaWithJavac FAILED
56 actionable tasks: 6 executed, 50 up-to-date
info 💡 Tip: Make sure that you have set up your development environment correctly, by running npx react-native doctor. To read more about doctor command visit: https://github.com/react-native-community/cli/blob/main/packages/cli-doctor/README.md#doctor
D:\XXX\node_modules\react-native-simple-openvpn\vpnLib\build\generated\aidl_source_output_dir\uiDebug\out\com\android\vending\billing\IInAppBillingService.java:3: error: illegal unicode escape
* Using: C:\Users\xxx\AppData\Local\Android\Sdk\build-tools\35.0.0\aidl.exe...
Next, open the location of the error, you will see the following content
/*
* This file is auto-generated. DO NOT MODIFY.
* Using: C:\Users\xxx\AppData\Local\Android\Sdk\build-tools\35.0.0\aidl.exe...
*/
package com.android.vending.billing;
// ...
It is this path Using: C:\Users\xxx\AppData\Local\Android\Sdk\build-tools\35.0.0\aidl.exe...
that caused the build failure
Please modify android\build.gradle
for a temporary solution, then the automatically generated comments will not include that path
buildscript {
ext {
- buildToolsVersion = "35.0.0"
+ buildToolsVersion = "34.0.0"
minSdkVersion = 24
compileSdkVersion = 35
targetSdkVersion = 34
ndkVersion = "26.1.10909125"
kotlinVersion = "1.9.24"
}
}
Bug description:
Cannot import this package with rn 0.76.0 and jdk 17
Environment:
after yarn android: