바뀜

둘러보기로 가기 검색하러 가기
321 바이트 제거됨 ,  2017년 8월 29일 (화) 22:08
편집 요약 없음
ftp://ftp.gnu.org/pub/gnu/ncurses/ 에서 최신 버전의 NCurses를 다운받습니다. 2015.12.27 기준으로 최신 버전인 [ftp://ftp.gnu.org/pub/gnu/ncurses/ncurses-6.0.tar.gz ncurses-6.0]을 설치하겠습니다.
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/Downloads# wget ftp://ftp.gnu.org/pub/gnu/ncurses/ncurses-6.0.tar.gz
--2015-12-27 14:47:12-- ftp://ftp.gnu.org/pub/gnu/ncurses/ncurses-6.0.tar.gz
root@RaspberryPi:~/Downloads#
</syntaxhighlightpre>
다운 받은 ncurses 파일의 압축을 해제합니다.
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/Downloads# ls
ncurses-6.0.tar.gz
ncurses-6.0 ncurses-6.0.tar.gz
root@RaspberryPi:~/Downloads#
</syntaxhighlightpre>
압축을 해제한 ncurses-6.0 폴더로 이동합니다.
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/Downloads# cd ncurses-6.0
root@RaspberryPi:~/Downloads/ncurses-6.0#
</syntaxhighlightpre>
=== ./configure ===
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/Downloads/ncurses-6.0# ./configure
(...생략...)
root@RaspberryPi:~/Downloads/ncurses-6.0#
</syntaxhighlightpre>
=== make ===
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/Downloads/ncurses-6.0# make
make[1]: Leaving directory '/root/Downloads/ncurses-6.0/misc'
root@RaspberryPi:~/Downloads/ncurses-6.0#
</syntaxhighlightpre>
=== make install ===
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/Downloads/ncurses-6.0# make install
installing std
make[1]: Leaving directory '/root/Downloads/ncurses-6.0/misc'
root@RaspberryPi:~/Downloads/ncurses-6.0#
</syntaxhighlightpre
== 설치 확인 ==
=== Hello World 프로그램 ===
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/NCurses# vi hello.c
</syntaxhighlightpre>
hello.c 소스
=== 컴파일 ===
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/NCurses# gcc -o hello hello.c -lncurses
root@RaspberryPi:~/NCurses#
</syntaxhighlightpre>
=== 실행 ===
<syntaxhighlight lang=""pre>
root@RaspberryPi:~/NCurses# ls
hello hello.c
root@RaspberryPi:~/NCurses# ./hello
</syntaxhighlightpre>
''hello'' 파일을 실행하면 Hello World가 출력됩니다.
<syntaxhighlight lang=""pre>
Hello World
</syntaxhighlightpre>

둘러보기 메뉴