]> pilppa.org Git - libcharencoding.git/blob - autobuild.sh
support for /usr/local/lib64 dir
[libcharencoding.git] / autobuild.sh
1 #!/bin/sh
2
3 PREFIX=${PREFIX:=/usr/local}
4
5 if ! [ -d /lib64 ] ;
6 then
7         LIBDIR=${LIBDIR:=$PREFIX/lib}
8 else
9         LIBDIR=${LIBDIR:=$PREFIX/lib64}
10 fi
11 export PKG_CONFIG_PATH=$LIBDIR/pkgconfig:$PKG_CONFIG_PATH
12
13 if ! [ -e Makefile ] ;
14 then
15         echo "No Makefile available, generating it."
16         libtoolize --automake --force --copy
17         autoreconf --install
18         ./configure --prefix=$PREFIX --libdir=$LIBDIR
19 else
20         echo "Makefile found, no need to generate it."
21 fi
22 make