Skip to content

Commit

Permalink
Unify type and values of USE_FABRIC env variable with USE_CODEGEN
Browse files Browse the repository at this point in the history
Summary:
This diff unifies the type and value of USE_FABRIC env variable  exposed in Gradle  with the USE_CODEGEN env variable

changelog: [internal] internal

Reviewed By: fkgozali

Differential Revision: D23145658

fbshipit-source-id: 9575f6b50c7a977254e364037d1417b3b1cdb607
  • Loading branch information
mdvacca authored and facebook-github-bot committed Aug 15, 2020
1 parent a397f73 commit 4720ad9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
6 changes: 1 addition & 5 deletions RNTester/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,6 @@ plugins {
* // Root dir for all JS files for the app. Defaults to `root` above.
* jsRootDir: "../..",
*
* // Enable react-native-codegen during build time.
* enableCodegen: true,
*
* // Enable Fabric at build time and runtime.
* enableFabric: true,
*
Expand All @@ -88,8 +85,7 @@ project.ext.react = [
hermesCommand: "../../../node_modules/hermes-engine/%OS-BIN%/hermesc",
enableHermesForVariant: { def v -> v.name.contains("hermes") },
jsRootDir: "$rootDir/RNTester",
enableCodegen: System.getenv('USE_CODEGEN'),
enableFabric: System.getenv("USE_FABRIC") ?: false,
enableFabric: (System.getenv('USE_FABRIC') ?: '0').toBoolean(),
]

apply from: "../../../react.gradle"
Expand Down
6 changes: 3 additions & 3 deletions ReactAndroid/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ def thirdPartyNdkDir = new File("$buildDir/third-party-ndk")
def dependenciesPath = System.getenv("REACT_NATIVE_DEPENDENCIES")

// The 'USE_FABRIC' environment variable will build Fabric C++ code into the bundle
// USE_FABRIC=false will build RN excluding fabric
// USE_FABRIC=true will build RN including fabric
def enableFabric = System.getenv("USE_FABRIC") ?: "false"
// USE_FABRIC=0 will build RN excluding fabric
// USE_FABRIC=1 will build RN including fabric
def enableFabric = (System.getenv('USE_FABRIC') ?: '0').toBoolean()

// The Boost library is a very large download (>100MB).
// If Boost is already present on your system, define the REACT_NATIVE_BOOST_PATH env variable
Expand Down

0 comments on commit 4720ad9

Please sign in to comment.