2010-01-26 17:04:51

install MySQL++ on RHEL5.3 (Linux)


http://tangentsoft.net/mysql++/


# install mysql C API
[] yum install mysql.i386 mysql-devel.i386
# check /usr/include/mysql and /usr/lib/mysql

# extract mysql++ sourec into /home/softwares/
[] ln -s /home/softwares/mysql++-3.0.0.9 /opt/mysql++
[] cd /home/softwares/mysql++-3.0.9
[] ./configure --prefix=/opt/mysql++ 


checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking target system type... i686-pc-linux-gnu
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... 
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ANSI C... none needed
checking whether we are using the Intel C compiler... no
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking whether we are using the Intel C++ compiler... no
checking whether we are using the Sun C++ compiler... no
checking for ranlib... ranlib
checking for a BSD-compatible install... /usr/bin/install -c
checking whether ln -s works... yes
checking whether make sets $(MAKE)... yes
checking for ar... ar
checking for strip... strip
checking for nm... nm
checking for command to install directories... /usr/bin/install -c -d
checking if make is GNU make... yes
checking for dependency tracking method... gcc
checking for gcc... (cached) gcc
checking whether we are using the GNU C compiler... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to accept ANSI C... (cached) none needed
checking how to run the C preprocessor... gcc -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking whether -lm is needed to use C math functions... no
checking whether -lsocket is needed... no
checking whether -lnsl is needed... no
checking for MySQL library directory... /usr/lib/mysql
checking for MySQL include directory... /usr/include/mysql
checking if we can link to MySQL C API library directly... yes
checking for mysql_ssl_set in -lmysqlclient... yes
checking for localtime_r()... yes
checking for main in -lintl... no
checking whether we are using the GNU C++ compiler... (cached) yes
checking whether g++ accepts -g... (cached) yes
checking for STL slist extension... , namespace __gnu_cxx
configure: creating ./config.status
config.status: creating doc/userman/userman.dbx
config.status: creating install.hta
config.status: creating lib/Doxyfile
config.status: creating lib/mysql++.h
config.status: creating mysql++.spec
config.status: creating Makefile
config.status: creating config.h
config.status: config.h is unchanged


[] make
[] make install



add the following in .tcshrc

# mysql library
setenv MYSQL_INC_DIR  /usr/include/mysql
setenv MYSQL_LIB_DIR  /usr/lib/mysql
setenv LD_LIBRARY_PATH ${MYSQL_LIB_DIR}:${LD_LIBRARY_PATH}

# mysql++ library
setenv MYSQLPPSYS /opt/mysql++
setenv MYSQLPP_INC_DIR  ${MYSQLPPSYS}/include
setenv MYSQLPP_LIB_DIR  ${MYSQLPPSYS}/lib
setenv LD_LIBRARY_PATH ${MYSQLPP_LIB_DIR}:${LD_LIBRARY_PATH}


Posted by Jeong Han Lee | Permanent link