- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - Linux
- >
- Re: Compilation error in cpp file on HPUX platform
Operating System - Linux
1821638
Members
2973
Online
109633
Solutions
Forums
Categories
Company
Local Language
юдл
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
юдл
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
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
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-07-2006 12:17 AM
тАО03-07-2006 12:17 AM
Hi,
I am trying to compile c++ file on HPUX11.11 platform. Compiler version is A.03.55.
I am getting error as shown below. But the same code worked for other platforms like solaris,linux.
Can anyone tell me what could be the reason for this error?
"Warning 134: "/opt/aCC/include/limits", line 112 # Expected 2 arguments for macro
'max'.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }
^^^
Error 20: "/opt/aCC/include/limits", line 112 # '' expected before ')'.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }
^^^
Error 19: "/opt/aCC/include/limits", line 112 # Unexpected '>'.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }
^^^
Error 24: "/opt/aCC/include/limits", line 112 # ')' expected instead of '?'.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }
^^^
Error 445: "/opt/aCC/include/limits", line 112 # Cannot recover from earlier errors.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }"
Advance Thanks
I am trying to compile c++ file on HPUX11.11 platform. Compiler version is A.03.55.
I am getting error as shown below. But the same code worked for other platforms like solaris,linux.
Can anyone tell me what could be the reason for this error?
"Warning 134: "/opt/aCC/include/limits", line 112 # Expected 2 arguments for macro
'max'.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }
^^^
Error 20: "/opt/aCC/include/limits", line 112 # '
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }
^^^
Error 19: "/opt/aCC/include/limits", line 112 # Unexpected '>'.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }
^^^
Error 24: "/opt/aCC/include/limits", line 112 # ')' expected instead of '?'.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }
^^^
Error 445: "/opt/aCC/include/limits", line 112 # Cannot recover from earlier errors.
static inline T max () RWSTD_INLINE_NO_THROW { return RWSTD_STATIC_CAST(T,0); }"
Advance Thanks
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-07-2006 12:46 AM
тАО03-07-2006 12:46 AM
Re: Compilation error in cpp file on HPUX platform
Hi
There is obviously a difference of order
Macros max has been defined earlier
in you source.You must try to include the
system file first before compiler specific and all other includes.
Steve Steel
There is obviously a difference of order
Macros max has been defined earlier
in you source.You must try to include the
system file first before compiler specific and all other includes.
Steve Steel
If you want truly to understand something, try to change it. (Kurt Lewin)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-07-2006 12:59 AM
тАО03-07-2006 12:59 AM
Re: Compilation error in cpp file on HPUX platform
Thanks Steve. But why the same code is working for Solaris and Linux.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-07-2006 02:08 AM
тАО03-07-2006 02:08 AM
Solution
Because some of the standard header files are different. Almost certainly there is a macro "max" that is interfering. An "#undef max" will probably fix you. Note that Solaris and Linux are not using aCC so you are comparing apples and oranges.
If it ain't broke, I can fix that.
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Learn About
News and Events
Support
© Copyright 2025 Hewlett Packard Enterprise Development LP