Skip to content

[Android][Linux] Building master RNTester on Linux fails while building Folly #28298

@willholen

Description

@willholen

Description:

I'm on the latest git commit, and RNTester fails to build on Linux:

/tmp$ git clone https://github.com/facebook/react-native &&
   cd react-native &&
   npm install && 
   ./gradlew :RNTester:android:app:installJSCDebug
[...]
[armeabi-v7a] Compile++ thumb: folly_json <= FileUtil.cpp
make: Leaving directory '/tmp/react-native/ReactAndroid/src/main/jni/react/jni'
/tmp/react-native/ReactAndroid/build/third-party-ndk/folly/folly/FileUtil.cpp:37:14: error: no matching function for call to 'wrapNoInt'
  return int(wrapNoInt(open, name, flags, mode));
             ^~~~~~~~~
/tmp/react-native/ReactAndroid/build/third-party-ndk/folly/folly/detail/FileUtilDetail.h:34:9: note: candidate template ignored: couldn't infer template argument 'F'
ssize_t wrapNoInt(F f, Args... args) {
        ^
1 error generated.
make: *** [/tmp/fetchleak/sdk/ndk-bundle/build/core/build-binary.mk:478: /tmp/react-native/ReactAndroid/build/tmp/buildReactNdkLib/local/armeabi-v7a/objs/folly_json/folly/FileUtil.o] Error 1
make: *** Waiting for unfinished jobs....
[...]
make: Leaving directory '/tmp/react-native/ReactAndroid/src/main/jni/react/jni'

> Task :ReactAndroid:buildReactNdkLib FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':ReactAndroid:buildReactNdkLib'.
> Process 'command '/tmp/fetchleak/sdk/ndk-bundle/ndk-build'' finished with non-zero exit value 2

React Native version:

Git master, commit 5ebca70 from Mar 12 (Android SDK downloaded today, commandlinetools-linux-6200805_latest.zip)

Steps To Reproduce

  1. Be on Linux. The problem does not appear on macOS.
  2. git clone https://github.com/facebook/react-native
  3. cd react-native
  4. npm install
  5. ./gradlew :RNTester:android:app:installJSCDebug

Expected Results

I expected RNTester to run

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

https://github.com/facebook/react-native/

The first commit that fails is 6e2131b, "Upgrade Folly to v2020.01.13.00 (#27811)". The preceding commit, a3cb377, builds successfully.

Metadata

Metadata

Assignees

No one assigned

    Labels

    StaleThere has been a lack of activity on this issue and it may be closed soon.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions