Closed bang9 closed 1 week ago
There are quite a few functions that use regular expressions to extract configurations in Android, so adding comment-handling logic only to the findLibraryName
function feels a bit odd.
This issue seems to be more of an edge case, so handling it with an issue report should be sufficient.
If, despite using the old architecture, it doesn’t work in the interop layer and is recognized as a new architecture module, please check and remove the following:
libraryName
if it exists in the your-library/android/build.gradle
file.codegenConfig
field if it exists in the your-library/package.json
file.
Summary
Errors
Description
If
libraryName
exists in thebuild.gradle
file on Android, it is identified as a new architecture library during the auto-linking process.The
findLibraryName
function, which determines the config on Android, fetcheslibraryName
simply through a regular expression. Therefore, even if this part is commented out, it will still be recognized.As a result, even if it's an old architecture library, if
libraryName
is commented out as shown below, auto-linking will still attempt to treat it as a new architecture module. This leads to an attempt to link to a non-existent directory during the build process, ultimately causing the build to fail.Logs