无法在Solaris 10中包含sys / proc.h

时间:2015-01-22 07:14:27

标签: c++ c gcc solaris solaris-10

以下是相同的代码:

#include <sys/proc.h>
int main(){
        return 0;
}

这是图书馆:

ROHIT root@solaris-demo:/$ ls -ltr /usr/include/sys/proc.h
-rw-r--r--   1 root     bin        30063 Jan 11  2013 /usr/include/sys/proc.h

这是编译结果:

ROHIT root@solaris-demo:/var/tmp/$ gcc test.c 
In file included from test.c:1:
/usr/include/sys/proc.h:367: error: syntax error before "klgrpset_t"

有谁能帮助我了解这个错误背后的原因和可能的解决方法?

以下是有关我的编译器和操作系统版本的其他信息:

ROHIT root@solaris-demo:/var/tmp/$ which gcc
/usr/sfw/bin/gcc
ROHIT root@solaris-demo:/var/tmp/$ 
ROHIT root@solaris-demo:/var/tmp/$ gcc -v
Reading specs from /usr/sfw/lib/gcc/i386-pc-solaris2.10/3.4.3/specs
Configured with: /builds/sfw10-gate/usr/src/cmd/gcc/gcc-3.4.3/configure --prefix=/usr/sfw --with-as=/usr/sfw/bin/gas --with-gnu-as --with-ld=/usr/ccs/bin/ld --without-gnu-ld --enable-languages=c,c++ --enable-shared
Thread model: posix
gcc version 3.4.3 (csl-sol210-3_4-branch+sol_rpath)
ROHIT root@solaris-demo:/var/tmp/$ 
ROHIT root@solaris-demo:/var/tmp/$ uname -a
SunOS solaris-demo 5.10 Generic_147148-26 i86pc i386 i86pc
ROHIT root@solaris-demo:/var/tmp/$ 
ROHIT root@solaris-demo:/var/tmp/$ cat /etc/release
                    Oracle Solaris 10 8/11 s10x_u10wos_17b X86
  Copyright (c) 1983, 2011, Oracle and/or its affiliates. All rights reserved.
                            Assembled 23 August 2011

0 个答案:

没有答案