C Compilation error in AIX

Posted on 2009-12-19
Last Modified: 2013-11-17
I am getting a lot of a compilation error in AIX server :

"/usr/include/sys/vm_types.h", line 79.25: 1506-334 (S) Identifier vmhwkey_t has already been defined on line 1226 of "dcs_userprm.c".
"/usr/include/sys/vm_types.h", line 80.25: 1506-334 (S) Identifier vpn_t has already been defined on line 1227 of "dcs_userprm.c".
"/usr/include/sys/vm_types.h", line 81.25: 1506-334 (S) Identifier rpn_t has already been defined on line 1228 of "dcs_userprm.c".
"/usr/include/sys/vm_types.h", line 83.25: 1506-334 (S) Identifier ptex_t has already been defined on line 1230 of "dcs_userprm.c".

Is there a compiler flag to overwrite the indentifiers definition or something ?? How do I fix this issue?

The build command is :
xlc -c    -qlanglvl=ansi -D__unix  ....
Question by:prasen120998
    1 Comment
    LVL 45

    Accepted Solution

    Hi prasen,

    It's not a very good idea to try and over-ride system required definitions.  The system functions require the structure to be formatted exactly as the system definition states.  Changing the definition will certainly cause your program to fail.

    Either use the system definitions, or rename your structure to be something different than the system name.

    Good Luck,

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. Please see for the updated article. It is avail…
    A year or so back I was asked to have a play with MongoDB; within half an hour I had downloaded (,  installed and started the daemon, and had a console window open. After an hour or two of playing at the command …
    The goal of this video is to provide viewers with basic examples to understand recursion in the C programming language.
    This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

    746 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now