more house keeping
[nyanlinux.git] / builders / mtdev-1.1.6 / builder.sh
blobdeddd897f1c0b324c8b3335bef5d0940313c1fa2
1 src_name=mtdev
2 version=${pkg_name##*-}
3 slot=$version
4 archive_name=$src_name-$version.tar.bz2
5 url0=http://bitmath.org/code/$pkg_name/$archive_name
7 pkg_dir=$pkgs_dir_root/$src_name-$version
8 rm -Rf $pkg_dir
9 mkdir -p $pkgs_dir_root
10 cp -f $src_dir_root/$archive_name $pkgs_dir_root
11 cd $pkgs_dir_root
12 tar xf $archive_name
14 build_dir=$builds_dir_root/$src_name-$version
15 rm -Rf $build_dir
16 mkdir -p $build_dir
17 cd $build_dir
19 export PKG_CONFIG_LIBDIR=
21 export "CC=$target_gnu_triple-gcc -isystem /nyan/glibc/current/include -isystem /nyan/linux-headers/current/include -B/nyan/glibc/current/lib -L/nyan/glibc/current/lib -Wl,-rpath-link,/nyan/glibc/current/lib -static-libgcc"
22 export 'CFLAGS=-O2 -pipe -fPIC'
23 $pkg_dir/configure \
24 --prefix=/nyan/mtdev/$slot \
25 --disable-shared \
26 --enable-static
27 unset CFLAGS
28 unset CC
30 make -j $threads_n
31 make install
33 # cleanup and tidying
34 rm -f /nyan/$src_name/$slot/lib/*.la
35 strip -s /nyan/$src_name/$slot/bin/* || true
37 rm -Rf $build_dir $pkg_dir