Android app build failed

I’m trying to create an android build using ‘eas build’ but I keep getting the following error :-

> Task :app:compileReleaseJavaWithJavac FAILED
[stderr] 
/home/expo/workingdir/build/android/app/src/main/java/com/gradientfi/poketfinance/MainActivity.java:19: error: package R does not exist
[stderr] 
    setTheme(R.style.AppTheme);
[stderr] 
              ^
[stderr] 
/home/expo/workingdir/build/android/app/src/main/java/com/gradientfi/poketfinance/MainActivity.java:39: error: cannot find symbol
[stderr] 
    return new ReactActivityDelegateWrapper(this, BuildConfig.IS_NEW_ARCHITECTURE_ENABLED, new DefaultReactActivityDelegate(
[stderr] 
                                                  ^
[stderr] 
  symbol:   variable BuildConfig
[stderr] 
  location: class MainActivity
[stderr] 
/home/expo/workingdir/build/android/app/src/main/java/com/gradientfi/poketfinance/MainApplication.java:26: error: cannot find symbol
[stderr] 
        return BuildConfig.DEBUG;
[stderr] 
               ^
[stderr] 
  symbol: variable BuildConfig
[stderr] 
/home/expo/workingdir/build/android/app/src/main/java/com/gradientfi/poketfinance/MainApplication.java:45: error: cannot find symbol
[stderr] 
        return BuildConfig.IS_NEW_ARCHITECTURE_ENABLED;
[stderr] 
               ^
[stderr] 
  symbol: variable BuildConfig
[stderr] 
/home/expo/workingdir/build/android/app/src/main/java/com/gradientfi/poketfinance/MainApplication.java:50: error: cannot find symbol
[stderr] 
        return BuildConfig.IS_HERMES_ENABLED;
[stderr] 
               ^
[stderr] 
  symbol: variable BuildConfig
[stderr] 
/home/expo/workingdir/build/android/app/src/main/java/com/gradientfi/poketfinance/MainApplication.java:63: error: cannot find symbol
[stderr] 
    if (BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
[stderr] 
        ^
[stderr] 
  symbol:   variable BuildConfig
[stderr] 
  location: class MainApplication
[stderr] 
/home/expo/workingdir/build/android/app/src/main/java/com/gradientfi/poketfinance/MainApplication.java:63: error: illegal parenthesized expression
[stderr] 
    if (BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
[stderr] 
       ^
[stderr] 
/home/expo/workingdir/build/android/app/src/main/java/com/gradientfi/poketfinance/MainApplication.java:67: error: cannot find symbol
[stderr] 
    ReactNativeFlipper.initializeFlipper(this, getReactNativeHost().getReactInstanceManager());
[stderr] 
    ^
[stderr] 
  symbol:   variable ReactNativeFlipper
[stderr] 
  location: class MainApplication
[stderr] 
8 errors
w: Detected multiple Kotlin daemon sessions at build/kotlin/sessions
[stderr] 
FAILURE: Build completed with 2 failures.
[stderr] 
1: Task failed with an exception.
[stderr] 
-----------
[stderr] 
* What went wrong:
[stderr] 
Execution failed for task ':app:compileReleaseJavaWithJavac'.
[stderr] 
>
[stderr] 
Compilation failed; see the compiler error output for details.
[stderr] 
* Try:
[stderr] 
> Run with --stacktrace option to get the stack trace.
[stderr] 
> Run with --info or --debug option to get more log output.
[stderr] 
> Run with --scan to get full insights.
[stderr] 
==============================================================================
[stderr] 
2: Task failed with an exception.
[stderr] 
-----------
[stderr] 
* What went wrong:
[stderr] 
java.lang.StackOverflowError (no error message)
[stderr] 
* Try:
[stderr] 
> Run with --stacktrace option to get the stack trace.
[stderr] 
> Run with --info or --debug option to get more log output.
[stderr] 
> Run with --scan to get full insights.
[stderr] 
==============================================================================
[stderr] 
* Get more help at https://help.gradle.org
[stderr] 
BUILD FAILED in 12m 56s
Deprecated Gradle features were used in this build, making it incompatible with Gradle 8.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/7.5.1/userguide/command_line_interface.html#sec:command_line_warnings
Execution optimizations have been disabled for 25 invalid unit(s) of work during this build to ensure correctness.
Please consult deprecation warnings for more details.
1084 actionable tasks: 1084 executed

This is my package.json

{
  "scripts": {
    "start": "expo start --dev-client",
    "android": "expo run:android",
    "ios": "expo run:ios",
    "web": "expo start --web",
    "eject": "expo eject",
    "format": "prettier --write src/**/*.{js,jsx,ts,tsx}",
    "lint": "tslint --fix src/**/*.{ts,tsx}"
  },
  "dependencies": {
    "@babel/preset-typescript": "^7.16.7",
    "@bothrs/expo-mixpanel-analytics": "^3.0.0",
    "@burstware/expo-plaid-link": "^1.0.6",
    "@ethersproject/providers": "^5.7.2",
    "@expo/vector-icons": "^13.0.0",
    "@jsamr/counter-style": "^2.0.2",
    "@jsamr/react-native-li": "^2.3.1",
    "@ramp-network/ramp-instant-sdk": "^4.0.1",
    "@react-native-async-storage/async-storage": "1.17.11",
    "@react-native-community/checkbox": "^0.5.8",
    "@react-native-community/clipboard": "^1.5.1",
    "@react-native-community/datetimepicker": "6.7.3",
    "@react-native-community/masked-view": "^0.1.11",
    "@react-native-community/netinfo": "9.3.7",
    "@react-native-google-signin/google-signin": "^7.2.2",
    "@react-navigation/bottom-tabs": "^6.0.7",
    "@react-navigation/drawer": "^6.1.8",
    "@react-navigation/material-top-tabs": "^6.1.1",
    "@react-navigation/native": "^6.0.4",
    "@react-navigation/native-stack": "^6.2.2",
    "@react-navigation/stack": "^6.0.9",
    "@twotalltotems/react-native-otp-input": "1.3.7",
    "@types/uuid": "^8.3.4",
    "@unimodules/react-native-adapter": "~6.5.0",
    "@walletconnect/react-native-compat": "^2.7.2",
    "@walletconnect/react-native-dapp": "^1.8.0",
    "@walletconnect/sign-client": "^2.7.2",
    "@walletconnect/utils": "^2.7.1",
    "@web3modal/react-native": "^1.0.0-alpha.2",
    "axios": "^0.25.0",
    "babel-plugin-inline-dotenv": "^1.6.0",
    "crypto-browserify": "^3.12.0",
    "date-fns": "^2.25.0",
    "dotenv": "^10.0.0",
    "ethers": "^6.3.0",
    "expo": "^48.0.0",
    "expo-application": "~5.1.1",
    "expo-barcode-scanner": "~12.3.2",
    "expo-build-properties": "~0.6.0",
    "expo-camera": "~13.2.1",
    "expo-cli": "6.0.0",
    "expo-clipboard": "~4.1.2",
    "expo-contacts": "~12.0.1",
    "expo-crypto": "~12.2.1",
    "expo-device": "~5.2.1",
    "expo-file-system": "^15.2.2",
    "expo-image-picker": "^13.1.0",
    "expo-linear-gradient": "~12.1.2",
    "expo-linking": "~4.0.1",
    "expo-local-authentication": "~13.3.0",
    "expo-location": "~15.1.1",
    "expo-modules-core": "~1.2.7",
    "expo-network": "~5.2.1",
    "expo-notifications": "~0.18.1",
    "expo-screen-capture": "~5.1.1",
    "expo-sharing": "~11.2.2",
    "expo-splash-screen": "~0.18.2",
    "expo-status-bar": "~1.4.4",
    "expo-updates": "~0.16.4",
    "expo-web-browser": "~12.1.1",
    "formik": "^2.2.9",
    "https-browserify": "^1.0.0",
    "i18n-iso-countries": "^7.3.0",
    "libphonenumber-js": "^1.10.7",
    "lodash": "^4.17.21",
    "lottie-ios": "3.2.3",
    "lottie-react-native": "5.1.4",
    "moment": "^2.29.1",
    "native-color-picker": "^1.3.5",
    "os-browserify": "^0.3.0",
    "path-browserify": "^1.0.1",
    "radio-buttons-react-native": "^1.0.4",
    "react": "18.2.0",
    "react-dom": "18.2.0",
    "react-native": "0.71.8",
    "react-native-a11y-slider": "^1.2.0",
    "react-native-actions-sheet": "^0.8.7",
    "react-native-barcode-mask": "^1.2.4",
    "react-native-check-box": "^2.1.7",
    "react-native-countdown-component": "^2.7.1",
    "react-native-country-picker-modal": "^2.0.0",
    "react-native-currency-input": "^1.0.1",
    "react-native-currency-picker": "^1.0.5",
    "react-native-dashed-line": "^1.1.0",
    "react-native-date-picker": "^4.2.2",
    "react-native-device-info": "^8.4.9",
    "react-native-dotenv": "^3.2.0",
    "react-native-dropdown-picker": "^5.1.28",
    "react-native-fs": "^2.18.0",
    "react-native-gesture-bottom-sheet": "^1.1.0",
    "react-native-gesture-handler": "~2.9.0",
    "react-native-get-random-values": "~1.8.0",
    "react-native-haptic-feedback": "^1.13.0",
    "react-native-iphone-x-helper": "^1.3.1",
    "react-native-keyboard-aware-scroll-view": "^0.9.5",
    "react-native-keyboard-spacer": "^0.4.1",
    "react-native-mask-text": "^0.5.0",
    "react-native-modal": "^13.0.1",
    "react-native-modalbox": "^2.0.2",
    "react-native-network-info": "^5.2.1",
    "react-native-pager-view": "6.1.2",
    "react-native-paper": "^4.9.2",
    "react-native-paper-tabs": "^0.7.0",
    "react-native-phone-number-input": "^2.1.0",
    "react-native-qrcode-svg": "^6.1.2",
    "react-native-radio-buttons-group": "^2.3.0",
    "react-native-raw-bottom-sheet": "^2.2.0",
    "react-native-reanimated": "~2.14.4",
    "react-native-root-toast": "^3.3.0",
    "react-native-safe-area-context": "4.5.0",
    "react-native-screens": "~3.20.0",
    "react-native-shadow-2": "^6.0.5",
    "react-native-share": "^7.1.2",
    "react-native-smooth-pincode-input": "^1.0.9",
    "react-native-splash-screen": "^3.3.0",
    "react-native-status-bar-height": "^2.6.0",
    "react-native-sticky-keyboard-accessory": "^0.1.3",
    "react-native-svg": "13.4.0",
    "react-native-swipeable-row": "^0.8.1",
    "react-native-swipeable-view-stack": "^1.0.4",
    "react-native-tab-view": "^3.1.1",
    "react-native-toast-message": "^2.1.5",
    "react-native-view-shot": "3.5.0",
    "react-native-wagmi-charts": "^2.1.0",
    "react-native-web": "~0.18.11",
    "react-native-webview": "11.26.0",
    "readable-stream": "^4.3.0",
    "socket.io-client": "^4.4.1",
    "stream-http": "^3.2.0",
    "string.prototype.matchall": "^4.0.6",
    "styled-components": "^5.3.1",
    "uuid": "^8.3.2",
    "vm-browserify": "^1.1.2",
    "yup": "^0.32.11"
  },
  "browser": {
    "crypto": "./crypto.js"
  },
  "devDependencies": {
    "@babel/core": "^7.20.0",
    "@types/lodash": "^4.14.175",
    "@types/react": "~18.0.27",
    "@types/react-dom": "~18.0.10",
    "@types/react-native": "~0.70.6",
    "@types/styled-components": "^5.1.14",
    "prettier": "^2.1.2",
    "tslint": "^6.1.3",
    "tslint-config-airbnb": "^5.11.2",
    "tslint-config-prettier": "^1.18.0",
    "typescript": "^4.9.4"
  },
  "engines": {
    "node": ">=14.0.0 <=16.18.1",
    "npm": "please-use-yarn"
  },
  "resolutions": {
    "@types/react": "17.0.21",
    "expo-linear-gradient": "~11.3.0"
  },
  "private": true,
  "name": "app-v2.v3",
  "version": "1.0.0"
}