- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
My current project build can be done using 3 compilers namely ICL, VC10 and VC05. Every compilation needs its set of pragmas in header/source files. Is there any way to select them conditionaly based on what compiler I specify in my build.
I faintly remember that I have used compiler attributes to do this. But I also dont want compiler to give any error if it does not understand other compilers attributes.
In short I need something like this.
Header.h
//If ICL
#pragma icl_op1
#pragma icl_op2
//else if VC10
#pragma vc_10_op1
#pragma vc_10_op2
//else if VC05
#pragma vc_05_op1
#pragma vc_05_op2
Now I want to fill those "//If ICL or //else if VC10" comments.
My current project build can be done using 3 compilers namely ICL, VC10 and VC05. Every compilation needs its set of pragmas in header/source files. Is there any way to select them conditionaly based on what compiler I specify in my build.
I faintly remember that I have used compiler attributes to do this. But I also dont want compiler to give any error if it does not understand other compilers attributes.
In short I need something like this.
Header.h
//If ICL
#pragma icl_op1
#pragma icl_op2
//else if VC10
#pragma vc_10_op1
#pragma vc_10_op2
//else if VC05
#pragma vc_05_op1
#pragma vc_05_op2
Now I want to fill those "//If ICL or //else if VC10" comments.
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Intel compiler has predefined macros __ICL and __INTEL_COMPILER. You may use this in header to recognize Intel compiler and may use for appropriate processing.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page