Linux2010. 3. 11. 13:30
이 녀석은 특이하게(?) 도 build 용 디렉토리를 따로 구성해야 한다.
그냥 configure 치면 다음과 같은 에러가 발생한다.

"configure: error: you must configure in a separate build directory"

추천 방법은
# git clone git://sourceware.org/git/glibc.git
# cd glibc
# mkdir build
# cd build
# ../configure
소스를 받고 그 아래와 디렉토리를 만들어 그 곳에서 상위의 configure를 호출하는 것이다.

만약, configure에서 --prefix, --exec-prefix 를 설정해주었다면
make install 시에 그 위치로 설치된다.

하지만, 각종 실행파일의 기본 경로가 --exec-prefix로 고정되서 삽입되는 듯한데 어쩌리오..
# cat Changelog.10
2138 Line
2000-01-04  Ulrich Drepper  <drepper@cygnus.com>

        * Makefile (install): Pass $(install_root) to ldconfig.
        Patch by Akira YOSHIYAMA <yosshy@tkf.att.ne.jp>.

ldconfig 에만 install_root을 넣나본데,
이녀석은 configure에서 설정가능한 항목이 존재하지 않는다.
config.make 파일을 수정해야 하는데, 이값을 넣지 않으면 -prefix 값이 들어가는것으로 생각된다.


[링크 : http://kldp.org/node/39946]
[링크 : http://www.gnu.org/software/libc/manual/html_node/Configuring-and-compiling.html#Configuring-and-compiling]

'Linux' 카테고리의 다른 글

MIME + nautilus(GNOME)  (0) 2010.03.15
glibc는.. 설치시 매~~~우 주의를 요합니다 ㄱ-  (0) 2010.03.11
*.la 파일 - libtool  (0) 2010.03.09
fribidi - Unicode BIDIrectional Algorithm  (0) 2010.03.09
chkconfig  (0) 2010.03.06
Posted by 구차니
Linux2010. 3. 9. 18:31
library 디렉토리를 보면
*.so
*.la
파일이 보인다.

so는 shared Object 이고
la는 머의 약자일려나?

2010.03.10 추가
la는 libtool archive ?

3.4 How to create a .la library (a.k.a. a libtool archive)?
[링크 : http://www.kdevelop.org/mediawiki/index.php/FAQ]

아무튼, la 파일은 텍스트 파일로, libtool에 의해서 사용되며,
라이브러리 정보를 포함하고 있다.

# cat /usr/lib/libgpg-error.la
# libgpg-error.la - a libtool library file
# Generated by ltmain.sh - GNU libtool 1.5.10 (1.1220.2.130 2004/09/19 12:13:49)
#
# Please DO NOT delete this file!
# It is necessary for linking the library.

# The name that we can dlopen(3).
dlname='libgpg-error.so.0'

# Names of this library.
library_names='libgpg-error.so.0.2.1 libgpg-error.so.0 libgpg-error.so'

# The name of the static archive.
old_library='libgpg-error.a'

# Libraries that this one depends upon.
dependency_libs=''

# Version information for libgpg-error.
current=2
age=2
revision=1

# Is this an already installed library?
installed=yes

# Should we warn about portability when linking against -modules?
shouldnotlink=no

# Files to dlopen/dlpreopen
dlopen=''
dlpreopen=''

# Directory that this library needs to be installed in:
libdir='/usr/lib'                                             



[링크 : ttp://filext.com/file-extension/LA]

'Linux' 카테고리의 다른 글

glibc는.. 설치시 매~~~우 주의를 요합니다 ㄱ-  (0) 2010.03.11
glibc 컴파일하기  (0) 2010.03.11
fribidi - Unicode BIDIrectional Algorithm  (0) 2010.03.09
chkconfig  (0) 2010.03.06
ltrace, strace  (0) 2010.03.06
Posted by 구차니
Linux2010. 3. 9. 18:18
GNU FriBidi is an implementation of the Unicode Bidirectional Algorithm (bidi).

fri는 free의 말장난인가?
아무튼, bidi는 양방향의미라는데 음.. 유니코드를 양방향으로 라니.. 무슨 의미일려나?

The latest stable release in the 0.10 series is fribidi-0.10.9.tar.gz (md5sum, signed by Behdad Esfahbod) from August 9, 2007. This release is based on Unicode 5.0.0 character database.

2바이트를 1바이트로(예를들면 ISO-8859?)
1바이트를 2바이트로 변환해주는 녀석인가?

[링크 : http://fribidi.org/]

'Linux' 카테고리의 다른 글

glibc 컴파일하기  (0) 2010.03.11
*.la 파일 - libtool  (0) 2010.03.09
chkconfig  (0) 2010.03.06
ltrace, strace  (0) 2010.03.06
bash 환경설정 - 모든 유저를 한번에 설정하기  (0) 2010.03.04
Posted by 구차니
Linux2010. 3. 6. 22:49
이녀석은 svn 서버 설정하려다가 알게된 녀석이고
한빛미디어/임베디드 리눅스 책에서 언급이 되길래 한번 검색하게 되었다.

chkconfig는 Redhat 계열에 존재하고
debian 계열에서는 update-rc.d 를 이용하라고 한다.

/etc/init.d/서비스이름(스크립트)
chkconfig --add 서비스이름(스크립트)

/etc/init.d/svnserve 라는 파일이 존재하면
chkconfig --add svnserve 라고 입력하면 자동으로 추가해준다.
런레벨 별로 추가가 가능하며 --level 옵션을 주면된다.

[링크 : http://linux.die.net/man/8/chkconfig]
[링크 : http://www.linuxquestions.org/questions/debian-26/chkconfig-equivalent-debian-346901/]

# /sbin/chkconfig --help
chkconfig version 1.3.30 - Copyright (C) 1997-2000 Red Hat, Inc.
This may be freely redistributed under the terms of the GNU Public License.

usage:   chkconfig --list [name]
         chkconfig --add <name>
         chkconfig --del <name>
         chkconfig [--level <levels>] <name> <on|off|reset|resetpriorities>

# /sbin/chkconfig --list
NetworkManager  0:off   1:off   2:off   3:off   4:off   5:off   6:off
NetworkManagerDispatcher        0:off   1:off   2:off   3:off   4:off   5:off   6:off
acpid           0:off   1:off   2:off   3:on    4:on    5:on    6:off
anacron         0:off   1:off   2:on    3:on    4:on    5:on    6:off
apmd            0:off   1:off   2:on    3:on    4:on    5:on    6:off
atd             0:off   1:off   2:off   3:on    4:on    5:on    6:off
autofs          0:off   1:off   2:off   3:on    4:on    5:on    6:off
avahi-daemon    0:off   1:off   2:off   3:on    4:on    5:on    6:off
avahi-dnsconfd  0:off   1:off   2:off   3:off   4:off   5:off   6:off
bluetooth       0:off   1:off   2:on    3:off   4:on    5:off   6:off
capi            0:off   1:off   2:off   3:off   4:off   5:off   6:off
cpuspeed        0:off   1:on    2:on    3:off   4:on    5:off   6:off
crond           0:off   1:off   2:on    3:on    4:on    5:on    6:off
cups            0:off   1:off   2:on    3:on    4:on    5:on    6:off
dc_client       0:off   1:off   2:off   3:off   4:off   5:off   6:off
dc_server       0:off   1:off   2:off   3:off   4:off   5:off   6:off
dhcdbd          0:off   1:off   2:off   3:off   4:off   5:off   6:off
diskdump        0:off   1:off   2:off   3:off   4:off   5:off   6:off
dund            0:off   1:off   2:off   3:off   4:off   5:off   6:off
firstboot       0:off   1:off   2:off   3:on    4:off   5:on    6:off
gpm             0:off   1:off   2:on    3:on    4:on    5:on    6:off
haldaemon       0:off   1:off   2:off   3:on    4:on    5:on    6:off
hidd            0:off   1:off   2:on    3:on    4:on    5:off   6:off
hplip           0:off   1:off   2:on    3:on    4:on    5:off   6:off
httpd           0:off   1:off   2:off   3:off   4:off   5:off   6:off
ip6tables       0:off   1:off   2:on    3:off   4:on    5:off   6:off
iptables        0:off   1:off   2:on    3:off   4:on    5:off   6:off
irda            0:off   1:off   2:off   3:off   4:off   5:off   6:off
irqbalance      0:off   1:off   2:on    3:on    4:on    5:on    6:off
isdn            0:off   1:off   2:on    3:on    4:on    5:off   6:off
kudzu           0:off   1:off   2:off   3:on    4:on    5:on    6:off
lisa            0:off   1:off   2:off   3:off   4:off   5:off   6:off
lm_sensors      0:off   1:off   2:on    3:on    4:on    5:on    6:off
mcstrans        0:off   1:off   2:on    3:on    4:on    5:on    6:off
mdmonitor       0:off   1:off   2:on    3:on    4:on    5:on    6:off
mdmpd           0:off   1:off   2:off   3:off   4:off   5:off   6:off
messagebus      0:off   1:off   2:off   3:on    4:on    5:on    6:off
microcode_ctl   0:off   1:off   2:off   3:off   4:off   5:off   6:off
multipathd      0:off   1:off   2:off   3:off   4:off   5:off   6:off
netdump         0:off   1:off   2:off   3:off   4:off   5:off   6:off
netfs           0:off   1:off   2:off   3:on    4:on    5:on    6:off
netplugd        0:off   1:off   2:off   3:off   4:off   5:off   6:off
network         0:off   1:off   2:on    3:on    4:on    5:on    6:off
nfs             0:off   1:off   2:off   3:on    4:off   5:on    6:off
nfslock         0:off   1:off   2:off   3:on    4:on    5:on    6:off
nscd            0:off   1:off   2:off   3:off   4:off   5:off   6:off
ntpd            0:off   1:off   2:off   3:off   4:off   5:off   6:off
pand            0:off   1:off   2:off   3:off   4:off   5:off   6:off
pcscd           0:off   1:off   2:on    3:on    4:on    5:on    6:off
portmap         0:off   1:off   2:off   3:on    4:on    5:on    6:off
psacct          0:off   1:off   2:off   3:off   4:off   5:off   6:off
rdisc           0:off   1:off   2:off   3:off   4:off   5:off   6:off
readahead_early 0:off   1:off   2:on    3:on    4:on    5:on    6:off
readahead_later 0:off   1:off   2:off   3:off   4:off   5:on    6:off
restorecond     0:off   1:off   2:on    3:on    4:on    5:on    6:off
rpcgssd         0:off   1:off   2:off   3:on    4:on    5:on    6:off
rpcidmapd       0:off   1:off   2:off   3:on    4:on    5:on    6:off
rpcsvcgssd      0:off   1:off   2:off   3:off   4:off   5:off   6:off
rwhod           0:off   1:off   2:off   3:off   4:off   5:off   6:off
saslauthd       0:off   1:off   2:off   3:off   4:off   5:off   6:off
sendmail        0:off   1:off   2:on    3:off   4:on    5:off   6:off
smartd          0:off   1:off   2:on    3:on    4:on    5:on    6:off
smb             0:off   1:off   2:off   3:on    4:off   5:on    6:off
spamassassin    0:off   1:off   2:off   3:off   4:off   5:off   6:off
squid           0:off   1:off   2:off   3:off   4:off   5:off   6:off
sshd            0:off   1:off   2:on    3:on    4:on    5:on    6:off
svnserve        0:off   1:off   2:on    3:on    4:on    5:on    6:off
syslog          0:off   1:off   2:on    3:on    4:on    5:on    6:off
tux             0:off   1:off   2:off   3:off   4:off   5:off   6:off
vncserver       0:off   1:off   2:off   3:on    4:off   5:on    6:off
winbind         0:off   1:off   2:off   3:off   4:off   5:off   6:off
wpa_supplicant  0:off   1:off   2:off   3:off   4:off   5:off   6:off
xfs             0:off   1:off   2:on    3:on    4:on    5:on    6:off
xinetd          0:off   1:off   2:off   3:on    4:on    5:on    6:off
ypbind          0:off   1:off   2:off   3:off   4:off   5:off   6:off
yum-updatesd    0:off   1:off   2:off   3:on    4:on    5:on    6:off

xinetd based services:
        chargen-dgram:  off
        chargen-stream: off
        cvs:            off
        daytime-dgram:  off
        daytime-stream: off
        discard-dgram:  off
        discard-stream: off
        echo-dgram:     off
        echo-stream:    off
        eklogin:        off
        ekrb5-telnet:   off
        gssftp:         off
        klogin:         off
        krb5-telnet:    off
        kshell:         off
        ktalk:          off
        rsync:          off
        tcpmux-server:  off
        tftp:           on
        time-dgram:     off
        time-stream:    off


'Linux' 카테고리의 다른 글

*.la 파일 - libtool  (0) 2010.03.09
fribidi - Unicode BIDIrectional Algorithm  (0) 2010.03.09
ltrace, strace  (0) 2010.03.06
bash 환경설정 - 모든 유저를 한번에 설정하기  (0) 2010.03.04
bash의 alias 제약사항/제한사항  (2) 2010.03.02
Posted by 구차니
Linux2010. 3. 6. 22:13
ltrace는 Library Trace 이고
strace는 System Call / Signal Trace 라고 한다.

ltrace - A library call tracer
strace - trace system calls and signals

한빛미디어의 "임베디드 리눅스" 책을 읽다가
이 녀석이 없었음 책도 못나왔을꺼다라는 저자의 말에 검색 ^^;

[링크 : http://linux.die.net/man/1/ltrace]
[링크 : http://linux.die.net/man/1/strace]
Posted by 구차니
Linux/Ubuntu2010. 3. 4. 11:32
Debian 계열은 rpm 대신 deb 을 이용하고 이것을
지능적으로 관리하는게 apt 매니저이다. rpm은 yum이 해주지만 아무튼
상대적으로 apt에 비하면 많이 부족한 느낌이 든다.

아무튼, 간단하게 요약을 하자면
# sudo apt-get update                   로 repository 정보를 갱신하고(서버에서 새로운 버전정보들을 가져온다.)
# sudo apt-cache search 키워드  로 원하는 패키지가 있는지 검색을 한다.
# sudo apt-cache show 패키지     로 패키지의 내용을 확인하고
# sudo apt-get install 패키지         로 패키지를 설치한다.

그리고 패치등으로 인해 업데이트(일반용어로 사용)를 해야할 프로그램이 있다면
#sudo apt-get upgrade              로 패치된 프로그램을 설치/적용한다.

[링크 : https://help.ubuntu.com/6.10/ubuntu/serverguide/ko/apt-get.html]
2009/09/01 - [Linux/Ubuntu] - apt-cache 패키지 검색 하기

Posted by 구차니
Linux2010. 3. 4. 10:54
로그인 쉘을 위해 실행되는
시스템 전역 초기화 파일인 /etc/profile을 수정하면 모든 사용자에게 적용이 될것으로 예상된다.

debian 도움말에는
/etc/bash.bashrc가 존재하고 이녀석은 login shell
/etc/profile은 interactive shell에 적용된다고 되어있다.

그런데 login shell과 per-interative-shell의 차이가 멀까?

$ man bash
OPTIONS
       In  addition to the single-character shell options documented in the description of the set builtin command, bash
       interprets the following options when it is invoked:

       -c string If the -c option is present, then commands are read from string.  If  there  are  arguments  after  the
                 string, they are assigned to the positional parameters, starting with $0.
       -i        If the -i option is present, the shell is interactive.
       -l        Make bash act as if it had been invoked as a login shell (see INVOCATION below).


INVOCATION
       A login shell is one whose first character of argument zero is a -, or one started with the --login option.

       An interactive shell is one started without non-option arguments and without the -c option whose  standard  input
       and  error  are both connected to terminals (as determined by isatty(3)), or one started with the -i option.  PS1
       is set and $- includes i if bash is interactive, allowing a shell script or a startup file to test this state.


FILES
       /bin/bash
              The bash executable
       /etc/profile
              The systemwide initialization file, executed for login shells
       ~/.bash_profile
              The personal initialization file, executed for login shells
       ~/.bashrc
              The individual per-interactive-shell startup file
       ~/.bash_logout
              The individual login shell cleanup file, executed when a login shell exits
       ~/.inputrc
              Individual readline initialization file

[링크 : http://linux.die.net/man/1/bash]
[링크 : http://www.lq.org/questions/linux-general-1/difference-between-normal-shell-and-login-shell-14983/]

FC6에서 내용확인
$ cat /etc/bashrc
 # /etc/bashrc

 # System wide functions and aliases
 # Environment stuff goes in /etc/profile

 # By default, we want this to get set.
 # Even for non-interactive, non-login shells.

$ cat /etc/profile
# /etc/profile

# System wide environment and startup programs, for login setup
# Functions and aliases go in /etc/bashrc

아무튼, interactive shell은 stdin와 stderr(잉? 왜 stdout이 아니지?)이 둘다 연결된 셸로
우리가 일반적으로 사용하는 녀석으로 생각된다.
결론은 login shell보다는 interactive shell용 환경변수 파일에 alias 등을 지정하는게 좋을듯 하다.
Posted by 구차니
Linux2010. 3. 2. 18:29
alias make='make -j'
를 해놨는데

gmake는 symbolic link로 make로 되어있다.

하지만 alias 특성상, 명령줄 치환을 하기 때문에
입력 당시 gmake가 비록 링크 추적으로 인해서 make가 실행되겠지만,
그렇다고 해서 make가 make -j로 치환되지는 않는다.

2010/03/02 - [프로그램 사용/gcc] - make, gmake
2010/02/26 - [Linux] - make를 더욱 빠르게 하기!


Posted by 구차니
Linux2010. 2. 26. 20:55
find는 기본적으로 하위 디렉토리를 뒤지도록 되어있기 때문에
강제로 현재 디렉토리만 검색을 하기 위해서는 옵션을 해주어야 한다.

아쉽게도 non-recursive 이런 옵션은 없고
-maxdepth 숫자
라는 옵션이 존재한다.

예를 들어 현재 디렉토리에서 크기가 0인 파일을 찾기 위해서는
$ find ./ -maxdepth 1 -size 0c
이라고 하면된다.

find: warning: you have specified the -maxdepth option after a non-option argument -size, but options are not positional (-maxdepth affects tests specified before it as well as those specified after it).  Please specify options before other arguments.

maxdepth는 옵션이고
size는 옵션이 아니므로 순서를 반대로 하면 경고를 발생시킨다.



-maxdepth levels
    Descend at most levels (a non-negative integer) levels of directories below the command line arguments. '-maxdepth 0' means only apply the tests and actions to the command line arguments.

[링크 : http://linux.die.net/man/1/find]

[링크 : http://www.unix.com/unix-dummies-questions-answers/423-using-find-command-only-current-directory.html]
Posted by 구차니
Linux2010. 2. 26. 15:46
bash 에서 history 라고 입력하면
현재까지 입력했던 목록들이 나온다.

그 중에 원하는 번호를 실행하려면
!n
이라고 입력하면된다.

예를 들어 432번에 원하는 명령어가 있다면
!432 이라고 입력하면 된다.

[링크 : http://linux.die.net/man/1/bash]
[링크 : http://www.solanara.net/solanara/bash]
Posted by 구차니