| ปกติแล้วการ install package บน Aix ส่วนใหญ่เราจะใช้ rpm package ในการ install แต่ก็มีหลายเหตุผลที่เราไม่สามารถ install package ด้วย rpm ได้จึงจำเป็นต้อง make install ด้วย source file |
| ข้อดีของการ install rpm package |
| - ไม่มีปัญหาเรื่อง file dependency |
| - ง่ายในการ install |
| - source file ทั้งหมดไม่มี bug สามารถ install ได้เลยไม่มีปัญหา |
| ข้อเสีย |
| - ไม่สามารถกำหนด prefix ตำแหน่ง path ที่ต้องการจะ install ได้ ปกติแล้วการ install rpm package จะติดตั้งไว้ที่ default path เสมอ -> /opt/freeware |
| - เมื่อไม่สามารถกำหนด prefix path ที่ต้องการได้ ปัญหาที่ตามมาคือ library version ที่ใช้งานอยู่ หากเรามี Application หลายๆ ตัวที่ทำงานอยู่บนเครื่อง Server เดียวกัน ก็อาจมีปัญหาได้เพราะ Application แต่ละตัวอาจ requirement version library ที่ต่างกันได้ |
| |
| ข้อดีการ make install จาก source file |
| - กำหนด prefix path ที่ต้องการได้ |
| - กำหนดให้ Application ที่ทำงานอยู่บนเครื่องเดียวกัน เลือกใช้ library version แตกต่างกันได้ |
| ข้อเสีย |
| - ปัญหาเรื่อง file dependency ซึ่งเราต้องหาว่าแต่ละ package requirement หา version ใดก่อนหลัง ถึงจะสามารถ install ได้ |
| - ปัญหา bug ของ source file ซึ่งบางครั้งเราจำเป็นต้องแก้ code เพื่อให้สามารถ build ได้ ซึ่งยากลำบากพอสมควร |
| |
| เราได้รวบรวม 3rdParty Software ที่จำเป็นในการใช้งานบน Aix 5.3 เพื่อทำการ make install source file ให้สามารถใช้งาน application ประเภท middle ware ได้แก่ Apache, Php, Java, Jboss ได้ ซึ่งเป็นการทำงานที่ค่อนข้างลำบากพอสมควร ทางทีมงานจึงได้แบ่งปันประสบการณ์เพื่อเป็นแนวทางและการแก้ปัญหาดังกล่าวไว้เป็นกรณีศึกษาต่อไป |
|
| |
|
|
| No |
Source Name |
Config & Make Install |
| 1 |
libgcc-4.2.0-3.aix5.3.ppc.rpm |
rpm -ivh libgcc-4.2.0-3.aix5.3.ppc.rpm |
| 2 |
libstdc++-4.2.0-3.aix5.3.ppc.rpm |
rpm -ivh libstdc++-4.2.0-3.aix5.3.ppc.rpm |
| 3 |
libstdc++-devel-4.2.0-3.aix5.3.ppc.rpm |
rpm -ivh libstdc++-devel-4.2.0-3.aix5.3.ppc.rpm |
| 4 |
gcc-4.2.0-3.aix5.3.ppc.rpm |
rpm -ivh gcc-4.2.0-3.aix5.3.ppc.rpm |
| 5 |
gcc-c++-4.2.0-3.aix5.3.ppc.rpm |
rpm -ivh gcc-c++-4.2.0-3.aix5.3.ppc.rpm |
| |
***fixed gcc 4.2 version***
# cd /opt/freeware/lib/gcc/powerpc-ibm-aix5.3.0.0/4.2.0/include/c++
# ln cstdio cstdio,v1.1.1.1
# sed -e '/fgetpos/ d' -e '/fsetpos/ d' \
-e '/fopen/ d' -e '/freopen/ d' \
cstdio,v1.1.1.1 >cstdio,v1.2
# ln -f cstdio,v1.2 cstdio
***export command***
export PATH=/usr/local/opt/freeware/bin:/opt/freeware/bin:$PATH &&
export LIBPATH=/usr/local/opt/freeware/lib:/opt/freeware/lib:$LIBPATH &&
export CC="/opt/freeware/bin/gcc" &&
export CFLAGS="-I/usr/local/opt/freeware/include -DHAVE_LONG_LONG" &&
export LDFLAGS="-L/usr/local/opt/freeware/lib" &&
export CPPFLAGS="-I/usr/local/opt/freeware/include -DHAVE_LONG_LONG" &&
export PKG_CONFIG="/usr/local/opt/freeware/bin/pkg-config" &&
export PKG_CONFIG_PATH="/usr/local/opt/freeware/lib/pkgconfig" &&
export GLIB_CONFIG="/usr/local/opt/freeware/bin/glib-config" &&
export GLIB_CFLAGS="-I/usr/local/opt/freeware/include" &&
export GLIB_LIBS="-L/usr/local/opt/freeware/lib" |
| |
|
|
| 6 |
make-3.80.tar.gz |
gunzip < make-3.80.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 7 |
pkg-config-0.20.tar.gz |
gunzip < pkg-config-0.20.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 8 |
libpcap-0.8.3.tar.gz |
gunzip < libpcap-0.8.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --enable-yydebug --enable-pcap_debug --enable-shared
make
make install
|
| |
|
|
| 9 |
less-382.tar.gz |
gunzip < less-382.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 10 |
m4-1.4.4.tar.gz |
gunzip < m4-1.4.4.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 11 |
bison-2.3.tar.gz |
gunzip < bison-2.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 12 |
autoconf-2.59.tar.gz |
gunzip < autoconf-2.59.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 13 |
libtool-1.5.22.tar.gz |
gunzip < libtool-1.5.22.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 14 |
automake-1.9.6.tar.gz |
gunzip < automake-1.9.6.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 15 |
zlib-1.2.3.tar.gz |
gunzip < zlib-1.2.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 16 |
libpng-1.2.10.tar.gz |
gunzip < libpng-1.2.10.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-zlib
######## vi config.h - comment ###############
/* Define to rpl_malloc if the replacement function should be used. */
/*#define malloc rpl_malloc*/
make
make install
|
| |
|
|
| 17 |
libiconv-1.13.tar.gz |
gunzip < libiconv-1.13.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 18 |
gettext-0.10.40.tar.gz |
gunzip < gettext-0.10.40.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-included-gettext --with-gnu-ld
make
make install
|
| |
|
|
| 19 |
urw-fonts.tar.gz |
gunzip < urw-fonts.tar.gz | tar xvf -
|
| |
|
|
| 20 |
pth-1.4.0.tar.gz |
gunzip < pth-1.4.0.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 21 |
readline-4.3.tar.gz |
gunzip < readline-4.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 22 |
sed-4.1.1.tar.gz |
gunzip < sed-4.1.1.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 23 |
tar-1.14.tar.gz |
gunzip < tar-1.14.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 24 |
tcpdump-3.8.1.tar.gz |
gunzip < tcpdump-3.8.1.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-libpcap --enable-pcap_debug --enable-yydebug
make
make install
|
| |
|
|
| 25 |
tcsh-6.13.00.tar.gz |
gunzip < tcsh-6.13.00.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 26 |
texinfo-4.6.tar.gz |
gunzip < texinfo-4.6.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 27 |
render-0.8.tar.gz |
gunzip < render-0.8.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make install
|
| |
|
|
| 28 |
xrender-0.8.3.tar.gz |
gunzip < xrender-0.8.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install
|
| |
|
|
| 29 |
popt-1.7.tar.gz |
gunzip < popt-1.7.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install
|
| |
|
|
| 30 |
pcre-3.7.tar.gz |
gunzip < pcre-3.7.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --disable-shared
make
make install
|
| |
|
|
| 31 |
bzip2-1.0.5.tar.gz |
gunzip < bzip2-1.0.5.tar.gz | tar xvf -
make install PREFIX=/usr/local/opt/freeware
|
| |
|
|
| 32 |
bash-2.02.1.tar.gz |
gunzip < bash-2.02.1.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 33 |
coreutils-5.2.1.tar.gz |
gunzip < coreutils-5.2.1.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install
|
| |
|
|
| 34 |
flex-2.5.4a.tar.gz |
gunzip < flex-2.5.4a.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 35 |
expat-2.0.1.tar.gz |
gunzip < expat-2.0.1.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install
|
| |
|
|
| 36 |
diffutils-2.8.1.tar.gz |
gunzip < diffutils-2.8.1.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install
|
| |
|
|
| 37 |
findutils-4.1.20.tar.gz |
gunzip < findutils-4.1.20.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 38 |
gdbm-1.8.3.tar.gz |
gunzip < gdbm-1.8.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install |
| |
|
|
| 39 |
gawk-3.1.3.tar.gz |
gunzip < gawk-3.1.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install |
| |
|
|
| 40 |
jpegsrc.v6b.tar.gz |
gunzip < jpegsrc.v6b.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --enable-static --enable-shared
make
make install |
| |
|
|
| 41 |
libxml2-2.6.30.tar.gz |
gunzip < libxml2-2.6.30.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --enable-static --enable-shared
make
make install
|
| |
|
|
| 42 |
libxslt-1.1.26.tar.gz |
gunzip < libxslt-1.1.26.tar.gz | tar xvf -
touch libtoolT
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld \
--with-libxml-prefix=/usr/local/opt/freeware \
--with-libxml-include-prefix=/usr/local/opt/freeware/include \
--with-libxml-libs-prefix=/usr/local/opt/freeware/lib
|
| |
|
|
| 43 |
gzip-1.2.4.4294967298.tar.gz |
gunzip < gzip-1.2.4.4294967298.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 44 |
glib-1.2.8.tar.gz |
gunzip < glib-1.2.8.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 45 |
tiff-3.8.2.tar.gz |
gunzip < tiff-3.8.2.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install |
| |
|
|
| 46 |
zip-2.32.tar.gz |
gunzip < zip-2.32.tar.gz | tar xvf -
make -f unix/Makefile generic_gcc
make -f unix/Makefile install BINDIR="/usr/local/opt/freeware/bin" MANDIR="/usr/local/opt/freeware/man/man1"
|
| |
|
|
| 47 |
unzip-5.52.tar.gz |
gunzip < unzip-5.52.tar.gz | tar xvf -
make -f unix/Makefile LOCAL_UNZIP=-D_FILE_OFFSET_BITS=64 \
CC="gcc ${BUILD64}" LD='$(CC)' CF="-O -Wall -I. -DUSE_UNSHRINK" \
unzips
make -f unix/Makefile install prefix="/usr/local/opt/freeware"
|
| |
|
|
| 48 |
glib-2.14.1.tar.gz |
gunzip < glib-2.14.1.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --enable-static --enable-shared
make
make install
|
| |
|
|
| 49 |
xextproto-7.0.3.tar.gz |
gunzip < xextproto-7.0.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make install
|
| |
|
|
| 50 |
grep-2.5.1.tar.gz |
gunzip < grep-2.5.1.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install |
| |
|
|
| 51 |
freetype1_1.4pre.20050518.orig.tar.gz |
gunzip < freetype1_1.4pre.20050518.orig.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --disable-shared
make
make install
|
| |
|
|
| 52 |
freetype-2.1.10.tar.gz |
gunzip < freetype-2.1.10.tar.gz | tar xvf -
GNUMAKE=/usr/local/opt/freeware/bin/make ./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 53 |
fontconfig-2.2.2.tar.gz |
gunzip < fontconfig-2.2.2.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --with-freetype-config=/usr/local/opt/freeware/bin/freetype-config --with-freetype-includes=/usr/local/opt/freeware/include/freetype2
make
make install |
| |
|
|
| 54 |
pixman-0.18.0.tar.gz |
gunzip < pixman-0.18.0.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install |
| |
|
|
| 55 |
cairo-1.8.10.tar.gz |
gunzip < cairo-1.8.10.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install |
| |
|
|
| 56 |
db-4.3.29.NC.tar.gz |
gunzip < db-4.3.29.NC.tar.gz | tar xvf -
cd build_unix
../dist/configure --prefix=/usr/local/opt/freeware --disable-largefile
make
make install
|
| |
|
|
| 57 |
openssl-0.9.8n.tar.tar |
gunzip < openssl-0.9.8n.tar.tar | tar xvf -
./Configure aix-cc
./config shared --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 58 |
prngd-0.9.29.tar.gz |
gunzip < prngd-0.9.29.tar.gz | tar xvf -
make
cp prngd /usr/local/opt/freeware/bin
|
| |
|
|
| 59 |
atk-1.10.3.tar.gz |
gunzip < atk-1.10.3.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --disable-glibtest
make
make install
|
| |
|
|
| 60 |
xcursor-1.0.2.tar.gz |
gunzip < xcursor-1.0.2.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 61 |
gtk+-1.2.8.tar.gz |
gunzip < gtk+-1.2.8.tar.gz | tar xvf -
rm config.cache
make clean
./configure --prefix=/usr/local/opt/freeware --with-gnu-ld
make
make install
|
| |
|
|
| 62 |
lsof_4.66.tar.gz |
gunzip < lsof_4.66.tar.gz | tar xvf -
cd lsof_4.66/lsof_4.66_src
./Configure aixgcc
[n]
[n]
make
./lsof -h
cp lsof /usr/local/opt/freeware/bin
cp lib/liblsof.a /usr/local/opt/freeware/lib
|
| |
|
|
| 63 |
pango-1.10.2.tar.gz |
gunzip < pango-1.10.2.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --enable-static --with-cairo
make
make install
|
| |
|
|
| 64 |
ghostscript-8.63.tar.gz |
gunzip < ghostscript-8.63.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware
make
make install
|
| |
|
|
| 65 |
ghostscript-fonts-std-6.0.tar.gz |
gunzip < ghostscript-fonts-std-6.0.tar.gz | tar xvf -
|
| |
|
|
| 66 |
openldap-2.3.27.tgz |
gunzip < openldap-2.3.27.tgz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --enable-aci
make depend
make
make install
|
| |
|
|
| 67 |
graphviz-2.16.tar.gz |
gunzip < graphviz-2.16.tar.gz | tar xvf -
./configure --prefix=/usr/local/opt/freeware --enable-static
make
make install
|
| |
|
|
| 68 |
httpd-2.2.15.tar.gz |
gunzip < httpd-2.2.15.tar.gz | tar xvf -export
./configure -C --enable-so --prefix=/usr/local/opt/freeware/apache2
make
make install
|
| |
|
|
| 69 |
php-5.3.2.tar.gz |
export ORACLE_HOME=/opt/app/oracle/product/10204
***ln oci***
ln -s /opt/app/oracle/oci/10204_64/sdk /opt/app/oracle/product/10204/lib32/sdk
ln -s /opt/app/oracle/oci/10204_64/sdk /opt/app/oracle/product/10204/lib/sdk
gunzip < php-5.3.2.tar.gz | tar xvf -
***fixed oci8***
cp oci8.c php-5.3.2/ext/oci8
./configure --prefix=/usr/local/opt/freeware/php5 \
--with-oci8=$ORACLE_HOME \
--with-pdo-oci=$ORACLE_HOME \
--with-zlib-dir=/usr/local/opt/freeware \
--with-zlib \
--with-png-dir=/usr/local/opt/freeware \
--with-openssl=/usr/local/opt/freeware \
--with-xsl=/usr/local/opt/freeware \
--with-ldap=/usr/local/opt/freeware \
--with-libxml-dir=/usr/local/opt/freeware \
--with-apxs2=/usr/local/opt/freeware/apache2/bin/apxs \
--with-config-file-path=/usr/local/opt/freeware/apache2/conf \
--enable-zip \
--enable-cli \
--enable-exif \
--enable-ftp \
--enable-sockets \
--enable-pcntl \
--enable-sigchild \
--enable-soap \
--enable-shmop \
--enable-sysvshm \
--enable-sysvsem \
--enable-sysvmsg \
--without-iconv
make
cp .libs/libphp5.so /usr/local/opt/freeware/apache2/modules
make install-build install-headers install-programs install-pear
make install-cli
cp php.ini-product /usr/local/opt/freeware/apache2/conf/php.ini
***vi apache2/conf/httpd.conf***
ServerName 192.168.1.9:80
LoadModule php5_module modules/libphp5.so
AddType application/x-httpd-php .php
DirectoryIndex index.php
User nobody
Group nobody
***start/stop apache***
./apachectl -k start
./apachectl -k stop
|
| |
|
|
| 70 |
mysql-3.23.58-ibm-aix5.1.0.0-powerpc.tar.gz |
gunzip mysql-3.23.58-ibm-aix5.1.0.0-powerpc.tar.gz | tar xvf -
tar xvf mysql-3.23.58-ibm-aix5.1.0.0-powerpc.tar
mv mysql-3.23.58-ibm-aix5.1.0.0-powerpc /usr/local/opt/freeware/mysql
|
| |
|
|
| 71 |
jboss-4.2.2.GA.zip |
unzip jboss-4.2.2.GA.zip
mv jboss-4.2.2.GA /usr/local/opt/freeware/jboss
|
| |
|
|
| 72 |
j664redist.tar.gz |
gunzip j664redist.tar.gz | tar xvf -
tar xvf- j664redist.tar
mv sdk /usr/local/opt/freeware/java16
|
| |
|
|
| |
|
|
| |
|
|