Tags

, , ,

On a RHEL 4u4 host run the following wget commands to get the necessary source code.

wget http://gd.tuwien.ac.at/graphics/gimp/gtk/v2.6/glib-2.6.4.tar.bz2

wget http://dev.mysql.com/get/Downloads/MySQL-Proxy/mysql-proxy-0.6.1.tar.gz/from/http://mysql.easynet.be/

wget http://luaforge.net/frs/download.php/3132/lua5_1_3_Sources.tar.gz

wget http://monkey.org/~provos/libevent-1.3d.tar.gz

Untar all the files and run configure , make and make install.

To tackle few of the hiccups that you might encounter, you can install glib on to a location that is different from your root.

For Glib 2.6, compile to some dir under your home dir

./configure –prefix=/home/user/mysql-proxy/lib/

Similarly edit the makefile of lua5.1 to change the install location. You can have this installed in the main root too. If so, by default it will go under /usr/local/lib.

After compiling and installing libevent (this can go into the main root), glib and lua set the following environment variables to tell the mysql-proxy configure script where to look for glib and lua.

export LUA_CFLAGS=”-I/home/user/mysql-proxy/lib/include/”
export LUA_LIBS=”-L/home/user/mysql-proxy/lib/lib”

export GLIB_CFLAGS = “-I/home/user/mysql-proxy/lib/include/glib-2.0 -I/home/user/mysql-proxy/lib/lib/glib-2.0/include/”
export GLIB_LIBS=”-L/home/user/mysql-proxy/lib/ -lglib-2.0 -ldl -llua5.1 -lm”

Also you need to install the mysql_config binary into a location in your path variable.

If you had installed lua on the main root you might have to export the LD_LIBRARY_PATH.

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib

Really got to know the internals of building 32 bit and 64 bit software. Sucked at building this pkg but learnt some stuff. Cool stuff with mysql-proxy coming up.

Advertisements