#!/bin/sh
#echo "post-install....."

PREFIX_PATH="/user/service"
LOG_HOME="$PREFIX_PATH/logs"
HTTPD_LIB="$PREFIX_PATH/httpd/lib"
APR_UTIL="$HTTPD_LIB/apr-util-1"
LB_LIBPQ="$APR_UTIL/libpq.so.5"

mkdir -p $LOG_HOME
mkdir -p $LOG_HOME/httpd

if [ -h /lib/libpq.so.5 ]; then
    rm /lib/libpq.so.5
fi
ln -s $LB_LIBPQ /lib/libpq.so.5

if [ -d /user/service/httpd/logs ]; then 
else
	ln -s $LOG_HOME/httpd /user/service/httpd/logs
fi

