Announcements

Help us improve the Power & Sensing Selection Guide. Share feedback

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
lock attach
Attachments are accessible only for community members.
Aishwarya
Level 1
Level 1
First reply posted First question asked Welcome!

I am doing google test in Aurix IDE V1.8.0. I have c source file along with c++ files but it showing some error. Have anyone  faced the same issue or know how to do google test using the same.

@Aurix397 

@User13836 

0 Likes
1 Solution

This seem to be normal application related issues. The unrecognized pragma warning is generated when a pragma which is supported by a different compiler but not supported by the compiler included in the ADS is used. You can verify if maybe a similar pragma does exist for the ADS compiler and replace this in the source code.

The #error line is preprocessor related. You need to review the content of the header file to determine how to mitigate this error. Probably some preprocessor define is missing or the source code includes a compiler product check like if GCC compiler do this if another compiler do that. And if the TASKING compiler is not included in that list the source code will need an overhaul.

 

Best regards,

Ulrich Kloidt
TASKING tools support

View solution in original post

0 Likes
4 Replies
User13836
Level 6
Level 6
50 likes received 50 solutions authored 100 sign-ins

I've no experience in using GoogleTest. But the issue itself is likely caused by a missing include folder entry. The error message indicates that the header file named gtest-port.h includes an include line like:

#include "sys/stat.h"

Supposed the stat.h header file does exist, it cannot be located. Please ensure that menu:

Project >> Properties >> C/C++ Build >> Settings >> TASKING C/C++ Compiler >> Include Paths

does include an entry which points to the folder which includes the 'sys' subfolder. Then the compiler can combine this entry plus the 'sys/stat.h' to locate the header file.

If you cannot modify the content of the Include Paths menu, you need to disable option:

Auto-discover compiler include paths

in menu:

Project >> Properties >> AURIX Development Studio >> Build

first.

Best regards,

Ulrich Kloidt
TASKING tools support

0 Likes
lock attach
Attachments are accessible only for community members.

As u mentioned I added the folder then getting other errors like this.

0 Likes

This seem to be normal application related issues. The unrecognized pragma warning is generated when a pragma which is supported by a different compiler but not supported by the compiler included in the ADS is used. You can verify if maybe a similar pragma does exist for the ADS compiler and replace this in the source code.

The #error line is preprocessor related. You need to review the content of the header file to determine how to mitigate this error. Probably some preprocessor define is missing or the source code includes a compiler product check like if GCC compiler do this if another compiler do that. And if the TASKING compiler is not included in that list the source code will need an overhaul.

 

Best regards,

Ulrich Kloidt
TASKING tools support

0 Likes
Di_W
Moderator
Moderator
Moderator
500 solutions authored 1000 replies posted 250 solutions authored

An example is send to your email. illd_tc375_ads_blinky_led_cpp.zip

0 Likes