Solaris 10 에서 stdio.h No such file or directory

hjim7158의 이미지

안녕하세요. Solaris 10에서 gcc를 하고 싶은 사람입니다.

결론만 말씀드리면 gcc는 설치되었는데 헤더파일이 없어서
헤더파일을 설치하고 싶습니다. (왕 초보입니다.)

# ls -l /usr/include
-rw-r--r-- 1 root bin 6245 Sep 4 2007 bzlib.h
-rw-r--r-- 1 root bin 1403 Sep 21 2006 demangle.h
drwxr-xr-x 2 root bin 512 Sep 18 10:27 des
-rw-r--r-- 1 root bin 21855 Aug 9 2007 dtrace.h
drwxr-xr-x 2 root bin 512 Sep 18 10:20 fm
-rw-r--r-- 1 root bin 26537 Jan 16 2008 hbaapi.h
drwxr-xr-x 2 root bin 512 Sep 18 10:27 iiim
-rw-r--r-- 1 root bin 69346 Dec 8 2007 ima.h
drwxr-xr-x 2 root bin 512 Sep 18 10:30 ko
lrwxrwxrwx 1 root root 4 Sep 18 10:29 ko_KR.EUC -> ./ko
drwxr-xr-x 2 root bin 512 Sep 18 10:30 libmilter
-rw-r--r-- 1 root bin 83893 Jan 22 2005 libtecla.h
drwxr-xr-x 3 root bin 512 Sep 18 10:23 libxml2
drwxr-xr-x 2 root sys 512 Sep 18 10:28 mle
-rw-r--r-- 1 root bin 1325 Apr 18 2007 mpapi-sun.h
-rw-r--r-- 1 root bin 84590 Apr 18 2007 mpapi.h
-rw-r--r-- 1 root bin 8452 Aug 9 2007 pool.h
drwxr-xr-x 2 root bin 512 Sep 18 10:28 sys
-rw-r--r-- 1 root bin 6746 Jan 10 2005 wsreg.h
-rw-r--r-- 1 root bin 9544 Jan 25 2007 zconf.h
-rw-r--r-- 1 root bin 66188 Jan 25 2007 zlib.h

현재 제가 가지고 있는 헤더파일들 입니다.
libc 라는 것을 설치하라고 하는데 감이 안잡혀 글을 올립니다.

현재 제가 가지고 있는 gcc의 버전은 아래와 같습니다.
# gcc --version
gcc (GCC) 3.4.6
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE

여기에 맞게 헤더파일을 설치하고 싶은데 막막해서 올려봅니다.

# gcc -o a.exe a.c
a.c:1:19: stdio.h: No such file or directory

간단하게 a.exe 파일을 컴파일 하고 싶은데 나오는 Error.

재설치를 해야 하나요? ㅠㅠ

hernian의 이미지

제 블로그에 간략하게 정리 해두었습니다.

http://choopa.tistory.com/entry/solaris-SUN-stdioh-No-such-file-or-directory

결론부터 말씀 드리자면

SUNWhea 라는 패키지가 설치 안되어서 그렇습니다.

패키지 설치 여부는 "pkginfo -i SUNWhea" 라고 치면 나옵니다.

설치가 안되어 있을경우 제 블로그를 따라서 설치 하시기 바랍니다.