>> Delete Reply from No. 0 article
No. RE: RE: MySQL 최적화 컴파일.. 방법!

등록 2003-02-04 01:46:00     조회 6
이름 dopesoul    

		pgcc 로는 에러가납니다.
제가 해서 그런진 몰라도 lib 무슨 파일 컴파일도중
에러를 내뱉습니다.
설치후에는 아래 postscript 를 실행해도 좋습니다.
 전 컴파일과정만을 다루었을 뿐입니다. 설치를 다루진 않았습니다.
 : 메뉴얼을 보면 이렇게 나와있습니다.
:
:      shell> groupadd mysql
:      shell> useradd -g mysql mysql
:      shell> cd /usr/local
:      shell> gunzip < /path/to/mysql-VERSION-OS.tar.gz | tar xvf -
:      shell> ln -s mysql-VERSION-OS mysql
:      shell> cd mysql
:      shell> scripts/mysql_install_db
:      shell> chown -R root  /usr/local/mysql
:      shell> chown -R mysql /usr/local/mysql/data
:      shell> chgrp -R mysql /usr/local/mysql
:      shell> chown -R root /usr/local/mysql/bin
:      shell> bin/safe_mysqld --user=mysql &
:
: 순서대로 하시면 설치가 바로 됩니다.
:
: p .s 소스도 PGCC 로 컴파일하면 20~30%의 성능향상이 있다는 보고입니다.(-_-)
:
: : 설날을 투자해서.. mysql 을 업그레이드 해보자.. 하고 문서를 수집하던중
: :
: : " Binary 를 받아서 설치하십시요. 당신이 컴파일한 코드는 아무리 노력
: : 해도 최적화 되지 않습니다 mysql 에서도 binary 가 가장 최적화 되었
: : 다고 합니다"
: :
: : 라는 글을 보았다. 아무래도 그렇겠지. 만든놈이 컴파일한게 -_-;
: : 제일 좋지 않을까..
: :
: : 바이너리를 다운받았다. 허나 바이너리를 어떻게 설치해야 하는가..
: : 막막했다. binary 를 /usr/local/mysql 로 옮겼다 쳐도, with-charset
: : 옵션이라던가, localstatedir 즉 db 가 위치하는곳은 어떻게정하는지..
: : 잘 모르겠다.
: :
: : 그래서 mysql 홈페이지를 뒤지던중..(메뉴얼 찾기가 참 힘들더라..)
: : MySQL ab 라고 하는 집단(아마도 개발이나 컴파일을 맡는 집단?)
: : 에서 컴파일을 했다고 하길래..(binary 배포판을)
: :
: : 쭉 읽어보니 그쪽에서 컴파일한 옵션을 발견할수 있었다.
: : 이대로 한다면 내가 원하는 옵션을 추가하여 바이너리와 거의 동급의
: : 성능을 기대할수 있겠군.. 하는 생각이 문득 들었다.
: : (바이너리의 성능이 최고라고들 하므로)
: :
: : 물론 보신분은 많겠지만 유용한 자료일것이라 생각되어 이곳에 올리기로
: : 했다. (못되도 1원짜리는 되지않을까 -_- 안되면 5전이라도..)
: :
: : Linux 2.4.xx i386 with gcc 2.95.3
: : CFLAGS="-O2 -mcpu=pentiumpro" CXX=gcc CXXFLAGS="-O2 -mcpu=pentiumpro -felide-constructors" ./configure --prefix=/usr
: : /local/mysql --with-extra-charsets=complex --enable-thread-safe-client --enable-local-infile --enable-assembler --di
: : sable-shared --with-client-ldflags=-all-static --with-mysqld-ldflags=-all-static Linux 2.4.xx ia64 with ecc (Intel C
: : ++ Itanium Compiler 7.0) CC=ecc CFLAGS=-tpp1 CXX=ecc CXXFLAGS=-tpp1 ./configure --prefix=/usr/local/mysql --with-ext
: : ra-charsets=complex --enable-thread-safe-client --enable-local-infile Linux 2.4.xx alpha with ccc (Compaq C V6.2-505
: :  / Compaq C++ V6.3-006) CC=ccc CFLAGS="-fast -arch generic" CXX=cxx CXXFLAGS="-fast -arch generic -noexceptions -nor
: : tti" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-thread-safe-client --enable-local-
: : infile --with-mysqld-ldflags=-non_shared --with-client-ldflags=-non_shared --disable-shared Linux 2.2.xx sparc with 
: : egcs 1.1.2 CC=gcc CFLAGS="-O3 -fno-omit-frame-pointer" CXX=gcc CXXFLAGS="-O3 -fno-omit-frame-pointer -felide-constru
: : ctors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-thread
: : -safe-client --enable-local-infile --enable-assembler --disable-shared Linux 2.4.xx s390 with gcc 2.95.3 CFLAGS="-O2
: : " CXX=gcc CXXFLAGS="-O2 -felide-constructors" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --
: : enable-thread-safe-client --enable-local-infile --disable-shared --with-client-ldflags=-all-static --with-mysqld-ldf
: : lags=-all-static Sun Solaris 2.8 sparc with gcc 3.2 CC=gcc CFLAGS="-O3 -fno-omit-frame-pointer" CXX=gcc CXXFLAGS="-O
: : 3 -fno-omit-frame-pointer -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql --wi
: : th-extra-charsets=complex --enable-thread-safe-client --enable-local-infile --enable-assembler --with-named-z-libs=n
: : o --with-named-curses-libs=-lcurses --disable-shared Sun Solaris 2.9 sparc with gcc 2.95.3 CC=gcc CFLAGS="-O3 -fno-o
: : mit-frame-pointer" CXX=gcc CXXFLAGS="-O3 -fno-omit-frame-pointer -felide-constructors -fno-exceptions -fno-rtti" ./c
: : onfigure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-thread-safe-client --enable-local-infile -
: : -enable-assembler --with-named-curses-libs=-lcurses --disable-shared Sun Solaris 2.9 sparc with cc-5.0 (Sun Forte 5.
: : 0) CC=cc-5.0 CXX=CC ASFLAGS="-xarch=v9" CFLAGS="-Xa -xstrconst -mt -D_FORTEC_ -xarch=v9" CXXFLAGS="-noex -mt -D_FORT
: : EC_ -xarch=v9" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-thread-safe-client --ena
: : ble-local-infile --enable-assembler --with-named-z-libs=no --enable-thread-safe-client --disable-shared IBM AIX 4.3.
: : 2 ppc with gcc 3.2.1 CFLAGS="-O2 -mcpu=powerpc -Wa,-many " CXX=gcc CXXFLAGS="-O2 -mcpu=powerpc -Wa,-many -felide-con
: : structors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-th
: : read-safe-client --enable-local-infile --with-named-z-libs=no --disable-shared IBM AIX 5.1.0 ppc with gcc 3.2.1 CFLA
: : GS="-O2 -mcpu=powerpc -Wa,-many" CXX=gcc CXXFLAGS="-O2 -mcpu=powerpc -Wa,-many -felide-constructors -fno-exceptions 
: : -fno-rtti" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --with-server-suffix="-pro" --enable-
: : thread-safe-client --enable-local-infile --with-named-z-libs=no --disable-shared --with-innodb HP-UX 10.20 pa-risc1.
: : 1 with gcc 3.1 CFLAGS="-DHPUX -I/opt/dce/include -O3 -fPIC" CXX=gcc CXXFLAGS="-DHPUX -I/opt/dce /include -felide-con
: : structors -fno-exceptions -fno-rtti -O3 -fPIC" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex -
: : -enable-thread-safe-client --enable-local-infile --with-pthread --with-named-thread-libs=-ldce --with-lib-ccflags=-f
: : PIC --disable-shared HP-UX 11.11 pa-risc2.0 with aCC (HP ANSI C++ B3910B A.03.33) CC=cc CXX=aCC CFLAGS=+DD64 CXXFLAG
: : S=+DD64 ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-thread-safe-client --enable-loc
: : al-infile --disable-shared Apple MacOS X 10.2 powerpc with gcc 3.1 CC=gcc CFLAGS="-O3 -fno-omit-frame-pointer" CXX=g
: : cc CXXFLAGS="-O3 -fno-omit-frame-pointer -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/l
: : ocal/mysql --with-extra-charsets=complex --enable-thread-safe-client --enable-local-infile --disable-shared FreeBSD 
: : 4.7 i386 with gcc 2.95.4 CFLAGS=-DHAVE_BROKEN_REALPATH ./configure --prefix=/usr/local/mysql --with-extra-charsets=c
: : omplex --enable-thread-safe-client --enable-local-infile --enable-assembler --with-named-z-libs=not-used --disable-s
: : hared URL 은 다음과 같다. http://www.mysql.com/doc/en/MySQL_binaries.html : : 다른 Third-party 머쉰에서
: : 의 컴파일 옵션도 다루고 있었다. SCO Unix 3.2v5.0.6 i386 with gcc 2.95.3 CFLAGS="-O3 -mpentium" LDFLAGS=
: : -static CXX=gcc CXXFLAGS="-O3 -mpentium -felide-constructors" ./configure --prefix=/usr/local/mysql --with-extra-cha
: : rsets=complex --enable-thread-safe-client --enable-local-infile --with-named-z-libs=no --enable-thread-safe-client -
: : -disable-shared Caldera Open Unix 8.0.0 i386 with CC 3.2 CC=cc CFLAGS="-O" CXX=CC ./configure --prefix=/usr/local/my
: : sql --with-extra-charsets=complex --enable-thread-safe-client --enable-local-infile --with-named-z-libs=no --enable-
: : thread-safe-client --disable-shared Compaq Tru64 OSF/1 V5.1 732 alpha with cc/cxx (Compaq C V6.3-029i / DIGITAL C++ 
: : V6.1-027) CC="cc -pthread" CFLAGS="-O4 -ansi_alias -ansi_args -fast -inline speed -speculate all" CXX="cxx -pthread"
: :  CXXFLAGS="-O4 -ansi_alias -fast -inline speed -speculate all -noexceptions -nortti" ./configure --prefix=/usr/local
: : /mysql --with-extra-charsets=complex --enable-thread-safe-client --enable-local-infile --with-prefix=/usr/local/mysq
: : l --with-named-thread-libs="-lpthread -lmach -lexc -lc" --disable-shared --with-mysqld-ldflags=-all-static SGI Irix 
: : 6.5 IP32 with gcc 3.0.1 CC=gcc CFLAGS="-O3 -fno-omit-frame-pointer" CXXFLAGS="-O3 -fno-omit-frame-pointer -felide-co
: : nstructors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex --enable-t
: : hread-safe-client --enable-local-infile --disable-shared 이후에 나온 컴파일 옵션. gcc 의 버전에 유의
: : 하자. Linux 2.2.x with x686 with gcc 2.95.2 CFLAGS="-O3 -mpentiumpro" CXX=gcc CXXFLAGS="-O3 -mpentiumpro -felide-c
: : onstructors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql --enable-assembler --with-mysqld-ldflag
: : s=-all-static --disable-shared --with-extra-charsets=complex SunOS 4.1.4 2 sun4c with gcc 2.7.2.1 CC=gcc CXX=gcc CXX
: : FLAGS="-O3 -felide-constructors" ./configure --prefix=/usr/local/mysql --disable-shared --with-extra-charsets=comple
: : x --enable-assembler SunOS 5.5.1 (and above) sun4u with egcs 1.0.3a or 2.90.27 or gcc 2.95.2 and newer CC=gcc CFLAGS
: : ="-O3" CXX=gcc CXXFLAGS="-O3 -felide-constructors -fno-exceptions -fno-rtti" ./configure --prefix=/usr/local/mysql -
: : -with-low-memory --with-extra-charsets=complex --enable-assembler SunOS 5.6 i86pc with gcc 2.8.1 CC=gcc CXX=gcc CXXF
: : LAGS=-O3 ./configure --prefix=/usr/local/mysql --with-low-memory --with-extra-charsets=complex BSDI BSD/OS 3.1 i386 
: : with gcc 2.7.2.1 CC=gcc CXX=gcc CXXFLAGS=-O ./configure --prefix=/usr/local/mysql --with-extra-charsets=complex BSDI
: :  BSD/OS 2.1 i386 with gcc 2.7.2 CC=gcc CXX=gcc CXXFLAGS=-O3 ./configure --prefix=/usr/local/mysql --with-extra-chars
: : ets=complex AIX 2 4 with gcc 2.7.2.2 CC=gcc CXX=gcc CXXFLAGS=-O3 ./configure --prefix=/usr/local/mysql --with-extra-
: : charsets=complex 다음과 같은 말도 덧붙였다. If you want to compile a debug version of MySQL, you should a
: : dd --with-debug or --with-debug=full to the preceding configure lines and remove any -fomit-frame-pointer options. 
: : 그리고 아래에 코멘트를 달수있는데, 한국사람이 다녀갔다는 말을 한마디 씩 하면 어떨
: : 까 -_-? 나도 지금 이 글을 쓰면서 위의 옵션으로 컴파일 하고있는 중이다.
: : 아참, 혹시 저 옵션을 사용할줄 모르는가?
: :
: : export 옵션으로 하면된다. 예를 들면
: :
: : CC="뭐뭐다"
: : export CC
: :
: : 이런식이다.
: :
: : CXXFLAGS 는 c++ 의 Flag 옵션이다.
: :
: :
: : --
: : 커널컴파일초보가..
:
: --
: http://www.sungmanjin.com -_---커널컴파일초보가..
[관리자] 패스워드를 입력 하십시오. 답장이 존재하면 함께 삭제됩니다.[ 목록 | 이전 ]
패스워드:    

Copyleft 1999-2026 by JSBoard Open Project
Theme Designed by IDOO All right reserved