Xcode Intel icc compiler cannot find #include <algorithm>

Hey. I am trying to compile gcc based code on Xcode using the icc compiler (11.1.088) but I have the following error:

catastrophic error: could not open source file "algorithm"

Looking at this file, it is in the gcc include directory, but I get hundreds of errors ...

Does anyone have any suggestions?

Thank.

+3
source share
3 answers

What did you install as the base SDK? And what version of Xcode?

FWIW Xcode 3.2.3 ICC 11.1 ( OS X 10.6, ) - ++, Xcode, #include <algorithm> to main.cc, gcc 4.2 ICC, . SDK (10.6).

, Xcode / ICC, , , , SDK, .

0

, , .

:

:

#ifdef __cplusplus
#include <algorithm>
#endif

#include ( .pch Xcode ), Objective-C, , -, algorithm ++ . , Objective-C Objective-C ++ (.mm), , , .

+2

This problem occurred on my machine while developing an iOS application. Xcode version 4.6.3 (4H1503) and iOS version 6.0

I use AppCode for development, and the IDE (by accident) added the following import statement:

#import <c++/4.2.1/ext/algorithm>
0
source

Source: https://habr.com/ru/post/1776192/


All Articles