@@ -66,6 +66,7 @@ val prefabHeadersDir = project.file("$buildDir/prefab-headers")
6666// Native versions which are defined inside the version catalog (libs.versions.toml)
6767val BOOST_VERSION = libs.versions.boost.get()
6868val DOUBLE_CONVERSION_VERSION = libs.versions.doubleconversion.get()
69+ val FAST_FLOAT_VERSION = libs.versions.fast_float.get()
6970val FMT_VERSION = libs.versions.fmt.get()
7071val FOLLY_VERSION = libs.versions.folly.get()
7172val GLOG_VERSION = libs.versions.glog.get()
@@ -183,6 +184,7 @@ val preparePrefab by
183184 // react_nativemodule_core
184185 Pair (File (buildDir, " third-party-ndk/boost/boost_1_83_0/" ).absolutePath, " " ),
185186 Pair (File (buildDir, " third-party-ndk/double-conversion/" ).absolutePath, " " ),
187+ Pair (File (buildDir, " third-party-ndk/fast_float/include/" ).absolutePath, " " ),
186188 Pair (File (buildDir, " third-party-ndk/fmt/include/" ).absolutePath, " " ),
187189 Pair (File (buildDir, " third-party-ndk/folly/" ).absolutePath, " " ),
188190 Pair (File (buildDir, " third-party-ndk/glog/exported/" ).absolutePath, " " ),
@@ -312,6 +314,28 @@ val prepareFolly by
312314 into(" $thirdPartyNdkDir /folly" )
313315 }
314316
317+ val downloadFastFloat by
318+ tasks.creating(Download ::class ) {
319+ dependsOn(createNativeDepsDirectories)
320+ src(" https://github.com/fastfloat/fast_float/archive/${FAST_FLOAT_VERSION } .tar.gz" )
321+ onlyIfModified(true )
322+ overwrite(false )
323+ retries(5 )
324+ quiet(true )
325+ dest(File (downloadsDir, " fast_float-${FAST_FLOAT_VERSION } .tar.gz" ))
326+ }
327+
328+ val prepareFastFloat by
329+ tasks.registering(Copy ::class ) {
330+ dependsOn(if (dependenciesPath != null ) emptyList() else listOf (downloadFastFloat))
331+ from(dependenciesPath ? : tarTree(downloadFastFloat.dest))
332+ from(" src/main/jni/third-party/fast_float/" )
333+ include(" fast_float-${FAST_FLOAT_VERSION } /include/*" , " CMakeLists.txt" )
334+ eachFile { this .path = this .path.removePrefix(" fast_float-${FAST_FLOAT_VERSION } /" ) }
335+ includeEmptyDirs = false
336+ into(" $thirdPartyNdkDir /fast_float" )
337+ }
338+
315339val downloadFmt by
316340 tasks.creating(Download ::class ) {
317341 dependsOn(createNativeDepsDirectories)
@@ -549,6 +573,7 @@ android {
549573 " generateCodegenArtifactsFromSchema" ,
550574 prepareBoost,
551575 prepareDoubleConversion,
576+ prepareFastFloat,
552577 prepareFmt,
553578 prepareFolly,
554579 prepareGlog,
0 commit comments