2.0.0 stable build error on iOS – `hidden_headers/Logger.h` not found

Description

Upgrading from 2.0.0-rc.3 to 2.0.0 produces an error when building for iOS, 2.0.0-rc.3 is working without issue.

[12:46:26]: ▸ Linking React
[12:46:26]: ▸ Compiling WorkletsCache.cpp
[12:46:26]: ▸ Compiling WorkletEventHandler.cpp
[12:46:26]: ▸ Compiling UIResponder+Reanimated.mm
[12:46:26]: ▸ Compiling ShareableValue.cpp
[12:46:26]: ▸ Compiling Scheduler.cpp
[12:46:26]: ▸ Compiling RuntimeDecorator.cpp
[12:46:26]: ▸ ❌  /Users/levi/src/project/native/node_modules/react-native-reanimated/Common/cpp/headers/Tools/ReanimatedHiddenHeaders.h:10:14: '../../hidden_headers/Logger.h' file not found
[12:46:26]: ▸     #include "../../hidden_headers/Logger.h"
[12:46:26]: ▸ ^

This appears to be related to #1775 however I haven’t been able to find any reports of others facing the same issue and beleive that it’s likely related to something specific in our brownfield app, but haven’t been able to find a way to solve it in userland.

I’m not sure this is necessarily a bug, but any pointers on resolving it would be incredibly helpful.

Screenshots

image

Steps To Reproduce

I’m trying to put together a minimal reproduction, but our app is quite large closed source, so I haven’t been able to extract a reproduction yet. At this stage I’m looking for tips/suggestions.

Expected behavior

App builds.

Actual behavior

App build fails. 😅

Snack or minimal code example

TBD

Package versions

  • React: 16.13.1
  • React Native: 0.63.4
  • React Native Reanimated: 2.0.0
  • NodeJS: 15.3.0

4 thoughts on “2.0.0 stable build error on iOS – `hidden_headers/Logger.h` not found

  1. Dug into this a bit more this morning and changing the paths slightly in ReanimatedHiddenHeaders.h allows a project that uses use_frameworks! to compile.

    #if defined(ONANDROID)
        #include "Logger.h"
        #include "LoggerInterface.h"
        #include "SpeedChecker.h"
    #else
    -    #include "../../Logger.h"
    -    #include "../../LoggerInterface.h"
    -    #include "../../SpeedChecker.h"
    +    #include "Common/cpp/hidden_headers/Logger.h"
    +    #include "Common/cpp/hidden_headers/LoggerInterface.h"
    +    #include "Common/cpp/hidden_headers/SpeedChecker.h"
    #endif

    Raised a PR with this suggested change #1810