-
Notifications
You must be signed in to change notification settings - Fork 40
Closed
Description
Environment
Mac => 15.5 (24F74)
npm => 10.8.2
node => v20.18.1
Java => openjdk 17.0.12 2024-07-16 LTS
OpenJDK Runtime Environment Microsoft-9911841 (build 17.0.12+7-LTS)
OpenJDK 64-Bit Server VM Microsoft-9911841 (build 17.0.12+7-LTS, mixed mode, sharing)
Ruby => ruby 3.3.0 (2023-12-25 revision 5124f9ac75) [arm64-darwin24]
Python => Python 3.10.0
Package.json:
{
"name": "currencyrnsdk",
"version": "1.0.0",
"private": true,
"scripts": {
"start": "rnef start",
"lint": "eslint .",
"test": "jest",
"ios": "rnef run:ios",
"android": "rnef run:android",
"package:ios": "rnef package:ios --scheme CurrencyrnsdkReact --configuration Release",
"package:aar": "rnef package:aar --variant Release --module-name currencyrnsdkreact",
"publish-local:aar": "pnpm package:aar && rnef publish-local:aar --module-name currencyrnsdkreact"
},
"dependencies": {
"@callstack/react-native-brownfield": "^1.1.0",
"react": "19.1.0",
"react-native": "0.80.1"
},
"devDependencies": {
"@babel/core": "^7.25.2",
"@babel/preset-env": "^7.25.3",
"@babel/runtime": "^7.25.0",
"@expo/fingerprint": "^0.11.6",
"@react-native/babel-preset": "0.80.1",
"@react-native/eslint-config": "0.80.1",
"@react-native/metro-config": "0.80.1",
"@react-native/typescript-config": "0.80.1",
"@rnef/cli": "^0.8.0",
"@rnef/platform-android": "^0.8.0",
"@rnef/platform-ios": "^0.8.0",
"@rnef/plugin-brownfield-android": "^0.8.0",
"@rnef/plugin-brownfield-ios": "^0.8.0",
"@rnef/plugin-metro": "^0.8.0",
"@rnef/welcome-screen": "^0.8.0",
"@types/react": "^19.1.0",
"@types/react-test-renderer": "^19.1.0",
"babel-jest": "^29.6.3",
"eslint": "^8.19.0",
"jest": "^29.6.3",
"prettier": "2.8.8",
"react-test-renderer": "19.1.0",
"typescript": "5.0.4"
},
"peerDependencies": {},
"engines": {
"node": ">=18"
}
}
Description
I'm creating a new project using the command:
npx @rnef/create-app currencyrnsdk
This uses the latest version of @rnef/create-app@0.8.0. However, when I try to build the AAR with npm run publish-local:aar from a clean project setup, the process fails:
currencyrnsdk % npm run publish-local:aar
> currencyrnsdk@1.0.0 publish-local:aar
> pnpm package:aar && rnef publish-local:aar --module-name currencyrnsdkreact
> currencyrnsdk@1.0.0 package:aar /Users/camilo/Documents/Proyectos/POC/currencyrnsdk
> rnef package:aar --variant Release --module-name currencyrnsdkreact
┌ Creating an AAR file
│
◇ Failed to build the AAR [1s]
│
■ /Users/camilo/Documents/Proyectos/POC/currencyrnsdk/android/currencyrnsdkreact/build/generated/autolinking/src/main/java/com/facebook/react/ReactNativeApplicationEntryPoint.java:29: error: package com.currencyrnsdk does not exist
│ if (com.currencyrnsdk.BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
│ ^
│ 1 error
│
│
│ * What went wrong:
│ Execution failed for task ':currencyrnsdkreact:compileReleaseJavaWithJavac'.
│ > Compilation failed; see the compiler output below.
│ /Users/camilo/Documents/Proyectos/POC/currencyrnsdk/android/currencyrnsdkreact/build/generated/autolinking/src/main/java/com/facebook/react/ReactNativeApplicationEntryPoint.java:29: error: package com.currencyrnsdk does not exist
│ if (com.currencyrnsdk.BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
│ ^
│ 1 error
│
│ > Check your code and dependencies to fix the compilation error(s)
│
■ Failed to build the AAR. See the error above for details from Gradle.
│
■ Cause: /Users/camilo/Documents/Proyectos/POC/currencyrnsdk/android/currencyrnsdkreact/build/generated/autolinking/src/main/java/com/facebook/react/ReactNativeApplicationEntryPoint.java:29: error: package com.currencyrnsdk does not exist
│ if (com.currencyrnsdk.BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
│ ^
│ 1 error
│
│ FAILURE: Build failed with an exception.
│
│ * What went wrong:
│ Execution failed for task ':currencyrnsdkreact:compileReleaseJavaWithJavac'.
│ > Compilation failed; see the compiler output below.
│ /Users/camilo/Documents/Proyectos/POC/currencyrnsdk/android/currencyrnsdkreact/build/generated/autolinking/src/main/java/com/facebook/react/ReactNativeApplicationEntryPoint.java:29: error: package com.currencyrnsdk does not exist
│ if (com.currencyrnsdk.BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
│ ^
│ 1 error
│
│ * Try:
│ > Check your code and dependencies to fix the compilation error(s)
│ > Run with --scan to get full insights.
│
│ BUILD FAILED in 1s
ELIFECYCLE Command failed with exit code 1.
Reproducible Demo
- Create a new project using the following command:
npx @rnef/create-app currencyrnsdk - During the setup process, select:
Platforms: iOS and Android
Bundler: Metro
Plugins: brownfield-ios and brownfield-android
- Navigate to the project directory:
cd currencyrnsdk - Run the following command to build the AAR:
npm run publish-local:aar
Metadata
Metadata
Assignees
Labels
No labels