question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Can't build from source

See original GitHub issue

Description

I tried enabling new architecture and I can’t build from source. Here is the error message

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:mergeDexRelease'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.DexMergingTaskDelegate
   > There was a failure while executing work items
      > A failure occurred while executing com.android.build.gradle.internal.tasks.DexMergingWorkAction
         > com.android.builder.dexing.DexArchiveMergerException: Error while merging dex archives: 
           Learn how to resolve the issue at https://developer.android.com/studio/build/dependencies#duplicate_classes.
           Type com.facebook.react.viewmanagers.ActivityIndicatorViewManagerInterface is defined multiple times: /Users/micko/Desktop/projects/react-native/PomodoroTimer/android/app/build/intermediates/project_dex_archive/release/out/com/facebook/react/viewmanagers/ActivityIndicatorViewManagerInterface.dex, /Users/micko/Desktop/projects/react-native/PomodoroTimer/node_modules/react-native/ReactAndroid/build/.transforms/c32b107ab68b409a985007cb93ee8b39/transformed/classes/classes.dex

Version

0.69.4

Output of npx react-native info

System:
    OS: macOS 12.5
    CPU: (8) arm64 Apple M1
    Memory: 117.61 MB / 8.00 GB
    Shell: 5.8.1 - /bin/zsh
  Binaries:
    Node: 16.16.0 - ~/.nvm/versions/node/v16.16.0/bin/node
    Yarn: Not Found
    npm: 8.11.0 - ~/.nvm/versions/node/v16.16.0/bin/npm
    Watchman: 2022.07.04.00 - /opt/homebrew/bin/watchman
  Managers:
    CocoaPods: 1.11.3 - /opt/homebrew/bin/pod
  SDKs:
    iOS SDK:
      Platforms: DriverKit 21.4, iOS 15.5, macOS 12.3, tvOS 15.4, watchOS 8.5
    Android SDK: Not Found
  IDEs:
    Android Studio: Chipmunk 2021.2.1 Patch 2 Chipmunk 2021.2.1 Patch 2
    Xcode: 13.4.1/13F100 - /usr/bin/xcodebuild
  Languages:
    Java: 11.0.16 - /usr/bin/javac
  npmPackages:
    @react-native-community/cli: Not Found
    react: 18.0.0 => 18.0.0 
    react-native: 0.69.4 => 0.69.4 
    react-native-macos: Not Found
  npmGlobalPackages:
    *react-native*: Not Found

Steps to reproduce

I was just following the docs and couldn’t build from source.

Snack, code example, screenshot, or link to a repository

/

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
cortinicocommented, Aug 16, 2022

Do you need to see some specific file or something else?

I would need to have a repo where I can checkout and build locally (or at least see how you configured the files). We might have a bigger bug that we’d like to address if this is the case.

1reaction
M1ck0commented, Sep 13, 2022

It is all good now when using latest version.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Could not be compiled. Try rebuilding from source manually.
"Could not be compiled. Try rebuilding from source manually." · Close Unreal and Visual Studio · Delete the following folders: Binaries, Build, Intermediate, ......
Read more >
Cant build from source? · Issue #1406 · pytorch/audio - GitHub
I just cloned the repo and tried to build from source. Im geting this error after solving a problem about not cuda home...
Read more >
Can't build unreal 4.26 from source. Error C4668 and MSB3073
Once this is all confirmed, right-click the UE4 project under the Solution Explorer and select Rebuild.
Read more >
Unreal Project Could Not Be Compiled, Try Re-Building From ...
Your browser can't play this video. Learn more. Switch camera ... Unreal Project Could Not Be Compiled, Try Re- Building From Source Manually....
Read more >
Why I can't build - Stack Overflow
The "no source available" error is because you built the app in release without debug info included ("Incremental Build of configuration Release ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found