$ cat
/proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 15
model : 4
model name : Intel(R) Pentium(R) 4 CPU 2.66GHz
stepping : 9
cpu MHz : 2659.968
cache size : 1024 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 5
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 apic mtrr pge mca cmov
pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe lm
constant_tsc up pebs bts pni dtes64 monitor ds_cpl tm2 cid cx16 xtpr
lahf_lm
bogomips : 5319.93
clflush size : 64
cache_alignment : 128
address sizes : 36 bits physical, 48 bits virtual
power management:
$ cat
cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 13
model name : Intel(R) Pentium(R) M processor 1.20GHz
stepping : 8
cpu MHz : 1196.000
cache size : 2048 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 2
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 sep mtrr pge mca cmov
clflush dts acpi mmx fxsr sse sse2 ss tm pbe bts est tm2
bogomips : 4246.73
clflush size : 64
cache_alignment : 64
address sizes : 32 bits physical, 32 bits virtual
power management:
항상켜기
$ cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 13
model name : Intel(R) Pentium(R) M processor 1.20GHz
stepping : 8
cpu MHz : 1196.000
cache size : 2048 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 2
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 sep mtrr pge mca cmov
clflush dts acpi mmx fxsr sse sse2 ss tm pbe bts est tm2
bogomips : 5872.02
clflush size : 64
cache_alignment : 64
address sizes : 32 bits physical, 32 bits virtual
power management:
최대배터리
$ cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 13
model name : Intel(R) Pentium(R) M processor 1.20GHz
stepping : 8
cpu MHz : 1196.000
cache size : 2048 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 2
wp : yes
flags : fpu vme de pse tsc msr pae mce cx8 sep mtrr pge mca cmov
clflush dts acpi mmx fxsr sse sse2 ss tm pbe bts est tm2
bogomips : 2510.02
clflush size : 64
cache_alignment : 64
address sizes : 32 bits physical, 32 bits virtual
power management:
$ cat
/proc/cpuinfo
Processor : Intel XScale-PXA255 rev 6 (v5l)
BogoMIPS : 396.56
Features : swp half thumb fastmult edsp
CPU implementor : 0x69
CPU architecture: 5TE
CPU variant : 0x0
CPU part : 0x2d0
CPU revision : 6
Cache type : undefined 5
Cache clean : undefined 5
Cache lockdown : undefined 5
Cache unified : harvard
I size : 16384
I assoc : 16
I line length : 32
I sets : 32
D size : 16384
D assoc : 16
D line length : 32
D sets : 32
Hardware : TynuxBox-X Development Platform
Revision : 0000
Serial : 0000000000000000
shenzhen{bzhu}$ gmake -version
GNU Make version 3.71, by
Richard Stallman and Roland McGrath.
Copyright (C) 1988, 89, 90, 91, 92, 93, 94 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.
shenzhen{bzhu}$ make -version
GNU Make 3.80
Copyright (C) 2002 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.
-l library
Search the library named library when linking. (The second alternative with the library as a separate argu-
ment is only for POSIX compliance and is not recommended.)
It makes a difference where in the command you write this option; the linker searches and processes libraries
and object files in the order they are specified. Thus, foo.o -lz bar.o searches library z after file foo.o
but before bar.o. If bar.o refers to functions in z, those functions may not be loaded.
The linker searches a standard list of directories for the library, which is actually a file named libli-
brary.a. The linker then uses this file as if it had been specified precisely by name.
The directories searched include several standard system directories plus any that you specify with -L.
Normally the files found this way are library files---archive files whose members are object files. The
linker handles an archive file by scanning through it for members which define symbols that have so far been
referenced but not defined. But if the file that is found is an ordinary object file, it is linked in the
usual fashion. The only difference between using an -l option and specifying a file name is that -l sur-
rounds library with lib and .a and searches several directories.
-Ldir
Add directory dir to the list of directories to be searched for -l.
LIBRARY_PATH
The value of LIBRARY_PATH is a colon-separated list of directories, much like PATH. When configured as a
native compiler, GCC tries the directories thus specified when searching for special linker files, if it
can’t find them using GCC_EXEC_PREFIX. Linking using GCC also uses these directories when searching for
ordinary libraries for the -l option (but directories specified with -L come first).
아마 2.4와 2.6이 혼합되어 설치되어있고, 2.6이 정상설치가 되지 않은듯 싶다.
옵션에 따라서 이러한 오류가 발생했다.
# gcc py.c -I/usr/local/include/python2.6 -L/usr/local/lib/libpython2.6.a
/tmp/cc88iTD7.o: In function `main':
py.c:(.text+0x12): undefined reference to `Py_Initialize'
py.c:(.text+0x26): undefined reference to `PyRun_SimpleStringFlags'
py.c:(.text+0x2b): undefined reference to `Py_Finalize'
collect2: ld returned 1 exit status
# gcc py.c -I/usr/local/include/python2.6 -lpython2.6
/usr/local/lib/libpython2.6.a(posixmodule.o): In function
`posix_tmpnam':
./Modules/posixmodule.c:7180: warning: the use of `tmpnam_r' is
dangerous, better use `mkstemp'
/usr/local/lib/libpython2.6.a(posixmodule.o): In function
`posix_tempnam':
./Modules/posixmodule.c:7135: warning: the use of `tempnam' is
dangerous, better use `mkstemp'
/usr/local/lib/libpython2.6.a(signalmodule.o): In function
`timeval_from_double':
./Modules/signalmodule.c:106: undefined reference to `floor'
./Modules/signalmodule.c:107: undefined reference to `fmod'
./Modules/signalmodule.c:106: undefined reference to `floor'
./Modules/signalmodule.c:107: undefined reference to `fmod'
/usr/local/lib/libpython2.6.a(floatobject.o): In function `float_pow':
Objects/floatobject.c:972: undefined reference to `pow'
/usr/local/lib/libpython2.6.a(floatobject.o): In function
`float_divmod':
Objects/floatobject.c:856: undefined reference to `fmod'
/usr/local/lib/libpython2.6.a(floatobject.o): In function `float_rem':
Objects/floatobject.c:834: undefined reference to `fmod'
/usr/local/lib/libpython2.6.a(longobject.o): In function
`PyLong_FromString':
Objects/longobject.c:1610: undefined reference to `log'
Objects/longobject.c:1610: undefined reference to `log'
/usr/local/lib/libpython2.6.a(dynload_shlib.o): In function
`_PyImport_GetDynLoadFunc':
Python/dynload_shlib.c:94: undefined reference to `dlsym'
Python/dynload_shlib.c:130: undefined reference to `dlopen'
Python/dynload_shlib.c:141: undefined reference to `dlsym'
Python/dynload_shlib.c:133: undefined reference to `dlerror'
/usr/local/lib/libpython2.6.a(thread.o): In function
`_pythread_pthread_set_stacksize':
Python/thread_pthread.h:519: undefined reference to
`pthread_attr_setstacksize'
/usr/local/lib/libpython2.6.a(thread.o): In function
`PyThread_release_lock':
Python/thread_pthread.h:374: undefined reference to `sem_post'
/usr/local/lib/libpython2.6.a(thread.o): In function
`PyThread_free_lock':
Python/thread_pthread.h:320: undefined reference to `sem_destroy'
/usr/local/lib/libpython2.6.a(thread.o): In function
`PyThread_allocate_lock':
Python/thread_pthread.h:296: undefined reference to `sem_init'
/usr/local/lib/libpython2.6.a(thread.o): In function
`PyThread_acquire_lock':
Python/thread_pthread.h:351: undefined reference to `sem_trywait'
Python/thread_pthread.h:349: undefined reference to `sem_wait'
/usr/local/lib/libpython2.6.a(thread.o): In function
`PyThread_start_new_thread':
Python/thread_pthread.h:171: undefined reference to
`pthread_attr_setstacksize'
Python/thread_pthread.h:181: undefined reference to `pthread_create'
Python/thread_pthread.h:197: undefined reference to `pthread_detach'
/usr/local/lib/libpython2.6.a(thread.o): In function
`PyThread_release_lock':
Python/thread_pthread.h:374: undefined reference to `sem_post'
Python/thread_pthread.h:374: undefined reference to `sem_post'
Python/thread_pthread.h:374: undefined reference to `sem_post'
/usr/local/lib/libpython2.6.a(thread.o): In function
`PyThread_allocate_lock':
Python/thread_pthread.h:296: undefined reference to `sem_init'
Python/thread_pthread.h:296: undefined reference to `sem_init'
/usr/local/lib/libpython2.6.a(posixmodule.o): In function
`posix_forkpty':
posixmodule.c:(.text+0x2653): undefined reference to `forkpty'
/usr/local/lib/libpython2.6.a(posixmodule.o): In function
`posix_openpty':
posixmodule.c:(.text+0x26fc): undefined reference to `openpty'
/usr/local/lib/libpython2.6.a(complexobject.o): In function `_Py_c_abs':
Objects/complexobject.c:214: undefined reference to `hypot'
/usr/local/lib/libpython2.6.a(complexobject.o): In function `_Py_c_pow':
Objects/complexobject.c:143: undefined reference to `hypot'
Objects/complexobject.c:144: undefined reference to `pow'
Objects/complexobject.c:145: undefined reference to `atan2'
Objects/complexobject.c:151: undefined reference to `cos'
Objects/complexobject.c:152: undefined reference to `sin'
Objects/complexobject.c:148: undefined reference to `exp'
Objects/complexobject.c:149: undefined reference to `log'
collect2: ld returned 1 exit status
컴파일시 각종 헤더들의 위치, 라이브러리들의위치
그리고 설치할 위치들을 설정하고,
컴파일할 프로그램의 세부 패키지를 설정한다.
아래는 ffmpeg의 configure --help 내용중 일부이다.
Standard options: --prefix=PREFIX install in PREFIX [] --bindir=DIR install binaries in DIR [PREFIX/bin] --datadir=DIR install data files in DIR [PREFIX/share/ffmpeg] --libdir=DIR install libs in DIR [PREFIX/lib] --shlibdir=DIR install shared libs in DIR [PREFIX/lib] --incdir=DIR install includes in DIR [PREFIX/include] --mandir=DIR install man page in DIR [PREFIX/share/man]
Advanced options (experts only): --enable-cross-compile assume a cross-compiler is used
--arch=ARCH select architecture []
--target-os=OS compiler targets OS []
--cross-prefix=PREFIX use PREFIX for compilation tools []
--source-path=PATH path to source code
[/home/morpheuz/st7109/target_ori/root/ffmpeg] --sysroot=PATH root of cross-build tree --sysinclude=PATH location of cross-build system headers --target-exec=CMD command to run executables on target --target-path=DIR path to view of build directory on target --nm=NM use nm tool --as=AS use assembler AS [] --cc=CC use C compiler CC [gcc] --ld=LD use linker LD --host-cc=HOSTCC use host C compiler HOSTCC --host-cflags=HCFLAGS use HCFLAGS when compiling for host --host-ldflags=HLDFLAGS use HLDFLAGS when linking for host --host-libs=HLIBS use libs HLIBS when linking for host --extra-cflags=ECFLAGS add ECFLAGS to CFLAGS [] --extra-ldflags=ELDFLAGS add ELDFLAGS to LDFLAGS [] --extra-libs=ELIBS add ELIBS [] --extra-version=STRING version string suffix [] --build-suffix=SUFFIX library name suffix [] --cpu=CPU select the minimum required CPU (affects instruction selection, may crash on older CPUs) --disable-yasm disable use of yasm assembler --enable-pic build position-independent code
이녀석의 경우 arch 와 target-os를 조합해서 cross compiler prefix를 만들어 낸다.
예를들어 sh4-linux의 경우 --enable-cross-compile--arch=sh4 --target-os=linux 라고 하면
자동으로 sh4-linux- 접두를 붙이게 된다.
하지만, target 에만 존재하는 library를 끌어 오려면 어떤 옵션을 써야 하나.. 후우..