@@ -702,13 +702,20 @@ fn configure_cmake(
702
702
// macOS
703
703
cfg. define ( "CMAKE_SYSTEM_NAME" , "Darwin" ) ;
704
704
} else if target. contains ( "ios" ) {
705
- cfg. define ( "CMAKE_SYSTEM_NAME" , "iOS" ) ;
705
+ // FIXME(madsmtm): compiler-rt's CMake setup is kinda weird, it seems like they do
706
+ // version testing etc. for macOS (i.e. Darwin), even while building for iOS?
707
+ //
708
+ // So for now we set it to "Darwin", but ideally this should be set to "iOS".
709
+ cfg. define ( "CMAKE_SYSTEM_NAME" , "Darwin" ) ;
706
710
} else if target. contains ( "tvos" ) {
707
- cfg. define ( "CMAKE_SYSTEM_NAME" , "tvOS" ) ;
711
+ // FIXME(madsmtm): See above, we should be using "tvOS" here.
712
+ cfg. define ( "CMAKE_SYSTEM_NAME" , "Darwin" ) ;
708
713
} else if target. contains ( "visionos" ) {
709
- cfg. define ( "CMAKE_SYSTEM_NAME" , "visionOS" ) ;
714
+ // FIXME(madsmtm): See above, we should be using "visionOS" here.
715
+ cfg. define ( "CMAKE_SYSTEM_NAME" , "Darwin" ) ;
710
716
} else if target. contains ( "watchos" ) {
711
- cfg. define ( "CMAKE_SYSTEM_NAME" , "watchOS" ) ;
717
+ // FIXME(madsmtm): See above, we should be using "watchOS" here.
718
+ cfg. define ( "CMAKE_SYSTEM_NAME" , "Darwin" ) ;
712
719
} else if target. contains ( "none" ) {
713
720
// "none" should be the last branch
714
721
cfg. define ( "CMAKE_SYSTEM_NAME" , "Generic" ) ;
0 commit comments