@@ -24,23 +24,23 @@ def add_nitrogen_files(spec)
2424
2525 spec . dependency "NitroModules"
2626
27- current_source_files = spec . attributes_hash [ 'source_files' ] || [ ]
27+ current_source_files = Array ( spec . attributes_hash [ 'source_files' ] )
2828 spec . source_files = current_source_files + [
2929 # Generated cross-platform specs
3030 "nitrogen/generated/shared/**/*.{h,hpp,c,cpp,swift}" ,
3131 # Generated bridges for the cross-platform specs
3232 "nitrogen/generated/ios/**/*.{h,hpp,c,cpp,mm,swift}" ,
3333 ]
3434
35- current_public_header_files = spec . attributes_hash [ 'public_header_files' ] || [ ]
35+ current_public_header_files = Array ( spec . attributes_hash [ 'public_header_files' ] )
3636 spec . public_header_files = current_public_header_files + [
3737 # Generated specs
3838 "nitrogen/generated/shared/**/*.{h,hpp}" ,
3939 # Swift to C++ bridging helpers
4040 "nitrogen/generated/ios/RNQuickSQLite-Swift-Cxx-Bridge.hpp"
4141 ]
4242
43- current_private_header_files = spec . attributes_hash [ 'private_header_files' ] || [ ]
43+ current_private_header_files = Array ( spec . attributes_hash [ 'private_header_files' ] )
4444 spec . private_header_files = current_private_header_files + [
4545 # iOS specific specs
4646 "nitrogen/generated/ios/c++/**/*.{h,hpp}" ,
@@ -52,5 +52,7 @@ def add_nitrogen_files(spec)
5252 "CLANG_CXX_LANGUAGE_STANDARD" => "c++20" ,
5353 # Enables C++ <-> Swift interop (by default it's only C)
5454 "SWIFT_OBJC_INTEROP_MODE" => "objcxx" ,
55+ # Enables stricter modular headers
56+ "DEFINES_MODULE" => "YES" ,
5557 } )
5658end
0 commit comments