manywaypark's Blog
개발, 검색, 함수

C 함수 manual page

tips & tricks/Linux/Unix 2009. 10. 5. 14:15 by manywaypark
man printf 했을 때 아무 것도 안 나와서 당황한 적이 있는가?
각종 C 함수 등에관한 man page는
sudo apt-get install manpages-dev

로 package 하나만 설치하면 잘 보인다.

happy hackin'

svn(subversion) build

tips & tricks/Linux/Unix 2009. 9. 17. 16:38 by manywaypark
현재 최신 기준으로 배포 페이지에서 파일 두개(subversion-1.6.5.tar.bz2, subversion-deps-1.6.5.tar.bz2) 만 다운로드 받아서 같은 디렉토리에서 압축을 풀고, sudo make install 하면 된다.
mkdir svn_build
cd svn_build
wget http://subversion.tigris.org/downloads/subversion-1.6.5.tar.bz2
wget http://subversion.tigris.org/downloads/subversion-deps-1.6.5.tar.bz2
tar xjf subversion-1.6.5.tar.bz2
tar xjf subversion-deps-1.6.5.tar.bz2
cd subversion-deps-1.6.5
make
sudo make install


예전에 한번 했던 일(오래된 redhat깔린 개발장비, 패키지관리 절대 안되는 박스에 svn 깔기)인데, 다시 다른 박스에서 하려니 헷갈렸다. subversion-deps를 안받았더니 이상한 경고메시지들이 떴는데 그 경고 메시지 따라 하나하나 하려니 머리에 쥐가났다. Orz.
DRY 차원에서 정리.
이번에는 라이브러리 몇개가 표준 경로에 있지 않아서 CPPFLAGS 환경변수 설정으로 경로를 추가해 줘야했다 (CPPFLAGS=-I/path/to/lib/include/ ./configure).
관리안되는 공용 서버는 정말 골칫덩어리다.

happy hackin'
git diff --no-prefix > patchfile # 패치 생성
cd path/to/top/                  # 이동
patch -p0 < patchfile            # 적용

--no-prefix 옵션 없이 생성된 patch 파일이 있다면,
patch -p1 < patchfile

참고: patching with git diff

happy hackin'
문제:
lyx에서 문서를 랜더링할때 다음과 같은 에러를 내면서 안되는 경우가 있다.
Warning: Document class not available
----------------------------------------
The layout file requested by this document,
IEEEtran.layout,
is not usable. This is probably because a LaTeX
class or style file required by it is not
available. See the Customization documentation
for more information.
LyX will not be able to produce output.
Error: Couldn't export file
----------------------------------------

해결: package 하나만 설치하면 된다.
sudo apt-get install texlive-publishers
lyx에서 tools > reconfigure 하는 것도 잊지 말자.
예전에 한번 문제가 되어서 해결했던 것인데, 다시 다른 박스의 ubuntu에서 예전에 작성했던 문서 소스를 rendering하려니 make 에러가 났다. 1시간 가량 삽질. Orz

happy hackin'
djbdns를 설치하려했는데, 의존성이 걸린 daemontools-run이 제대로 설치 되지 않는 문제가 발생했다.
환경: ubuntu intrepid

에러 메시지:

[...]
Adding SV inittab entry...
cp: cannot stat `/etc/inittab': No such file or directory

dpkg: error processing daemontools-run (--install):
 subprocess post-installation script returned error exit status 1
Errors were encountered while processing:
 daemontools-run

해결:

다음을 /etc/apt/sources.list에 추가해서 patch된 버전을 인스톨(apt-get update후 apt-get install)한다.
deb http://ppa.launchpad.net/amoog/amoog-devel/ubuntu jaunty main
deb-src http://ppa.launchpad.net/amoog/amoog-devel/ubuntu jaunty main

인증 관련해서 apt-get update가 실패하면
sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com E6090F843576F6EDB9FB63DE24BDD6095AFE82CE

참고:

happy hackin'
에러:
$ sudo apt-get install djbdns
......
Setting up daemontools (1:0.76-3) ...
Setting up daemontools-run (1:0.76-3) ...
grep: /etc/inittab: No such file or directory
grep: /etc/inittab: No such file or directory
grep: /etc/inittab: No such file or directory
grep: /etc/inittab: No such file or directory
grep: /etc/inittab: No such file or directory
Adding SV inittab entry...
cp: cannot stat `/etc/inittab': No such file or directory
dpkg: error processing daemontools-run (--configure):
 subprocess post-installation script returned error exit status 1
Setting up djbdns (1:1.05-2) ...
Setting up ucspi-tcp (1:0.88-2) ...
Errors were encountered while processing:
 daemontools-run
E: Sub-process /usr/bin/dpkg returned an error code (1)

해결:
$ sudo apt-get remove daemontools-run --purge

참고:

happy hackin'
문제
다음과 같은 오류메시지가 로그에 쌓이면서 제대로 동작하지 않는 경우가 있다.
IOError: [Errno 95] Operation not supported: '/var/spool/caldavd'

해결
/var/spool/caldavd 디렉토리가 포함된 파티션의 파일시스템이 ext2나 ext3라면, /etc/fstab 에서 마운트옵션에 user_xattr를 추가해주면 된다.

참고
패키지에 포함된 README.Debian
happy hackin'
SOME_ENV_VAR := VALUE


happy hackin'
OpenOffice에서 다음과 같은 에러를 내며 기능이 실행되지 않았다.
javaldx: Could not find a Java Runtime Environment!

Tools > Options > Java 에서 설정하라는 말은 헛소리인듯하고,

그냥,
$ sudo apt-get install openoffice.org-java-common

해결되었다.

참고: http://ubuntuforums.org/showthread.php?t=627559

happy hackin'

[TIP] 초간단 Cygwin/X 설정

tips & tricks/Win 2009. 1. 15. 13:40 by manywaypark
설치할 cygwin package:
 xorg-x11-server, xinit, xorg-x11-docs, X-start-menu-icons

cygwin을 기본 디렉토리에 설치하지 않았다면,
\path\to\your\cygwin\bin\startxwin.bat 편집:
SET CYGWIN_ROOT=\path\to\your\cygwin

startxwin.bat를 실행하거나, 시작 > 프로그램 > Cygwin-X > XWin Server

putty로 원격 서버 접속 후 X 응용프로그램 실행해서 확인.
(putty의 Connection > SSH > X11 에서 Enable X11 forwarding 활성화 되어있어야함)

참고: http://x.cygwin.com/docs/ug/setup-cygwin-x-installing.html

happy hackin'

2013-04-18 package 명 변경: xorg-x11-server -> xorg-server


1 ··· 11 12 13 14 15 16 
분류 전체보기 (306)
잡담 (20)
함수형 언어 (65)
emacs (16)
java (18)
tips & tricks (154)
사랑 (1)
가사 (0)
독서 (4)
mobile (6)
비함수형 언어 (2)

공지사항

최근에 올라온 글

최근에 달린 댓글

최근에 받은 트랙백

05-06 13:08