Fatal error: cyclic dependency in module 'std': std -> _wctype -> __wctype -> std (6.32.0.6 , MAC OS 15)

Hello,

When building root 6.32.06 on MAC OS 15.0.1, after downloading the source tar.gz file, I encounter this error:

FAILED: core/G__Core.cxx lib/Core.pcm etc etc
While building module ‘__wctype’ imported from /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.0.sdk/usr/include/_wctype.h:36:
In file included from :1:
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.0.sdk/usr/include/___wctype.h:72:10: fatal error: cyclic dependency in module ‘std’: std → _wctype → __wctype → std
#include <ctype.h>
^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.0.sdk/usr/include/_wctype.h:36:10: fatal error: could not build module ‘__wctype’
#include <_types/_wctrans_t.h>
etc
etc

From this thread:

I had thought I should not see this problem with 6.32.06?

Thanks,

Mark

From the thread you mention I only see that this should be fixed in 6.34.06, not 6.32.06, or did I miss something? @Danilo ?

It was typo in Danilo posts - 6.34.06 is not exists.

Oops! Sorry! Then @Danilo might take a look

Hi Mark,

Could you confirm you have only one SDK installed on your system?
(see e.g. ROOT on macOS 15 / Xcode 16 - #8 by Danilo )

Cheers,
Danilo

It seems I have many versions (which is odd, because I recall cleaning this up recently!)

ls /Library/Developer/CommandLineTools/SDKs
MacOSX.sdk MacOSX12.1.sdk MacOSX12.3.sdk MacOSX12.sdk MacOSX14.5.sdk MacOSX14.sdk MacOSX15.0.sdk MacOSX15.sdk

So I assume I should be removing all the pre 15 ones?

Cheers,

Mark

Removing the older SDK does not solve the problem.

Do you have a suggestion as to how to solve this?

Even after removing the command line tools, resetting Xcode-select and reinstalling the compilation of ROOT fails with the same issue:

/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX15.1.sdk/usr/include/___wctype.h:72:10: fatal error: cyclic dependency in module ‘std’: std → _wctype → __wctype → std

I think I have finally got to the bottom of this. I inherited a build script from one of the Acts developers that they have been using some time ago, and it looks like this option caused the problem:

-DCMAKE_CXX_STANDARD=17

switching this to 20 allows my compilation to work :slight_smile:

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.