"$@"
}
-notedir () {
- local dir=$1
+setdir () {
+ dir=$1
echo "==================== $dir ===================="
}
gettar () {
- local dir=$1
+ setdir $1
local url=$2
- notedir $dir
if ! test -d $dir; then
local dlfile="${url##*/}"
rm -f "$dlfile"
fi
}
+dirx () {
+ cd $dir
+ x "$@"
+ cd ..
+}
+
stdconfigure () {
- local dir=$1
- cd $dir
- PKG_CONFIG=/u/iwj/work/Rump-kernels/junk/pkg-config \
- x ../rumpuser-xen/app-tools/rumpapp-xen-configure ./configure \
+ dirx env PKG_CONFIG=/u/iwj/work/Rump-kernels/junk/pkg-config \
+ ../rumpuser-xen/app-tools/rumpapp-xen-configure ./configure \
--prefix=$HOME/work/Rump-kernels/prefix --disable-shared
- cd ..
}
stdmake () {
- local dir=$1
- cd $dir
- x ../rumpuser-xen/app-tools/rumpapp-xen-make -j4
- cd ..
+ dirx ../rumpuser-xen/app-tools/rumpapp-xen-make -j4
}
stdmakeinstall () {
- local dir=$1
- cd $dir
- x ../rumpuser-xen/app-tools/rumpapp-xen-make install
- cd ..
+ dirx ../rumpuser-xen/app-tools/rumpapp-xen-make install
}
want () {
- local dir=$1
- local url=$2
- gettar $dir "$url"
- stdconfigure $dir
- stdmake $dir
- stdmakeinstall $dir
+ gettar $1 "$2"
+ stdconfigure
+ stdmake
+ stdmakeinstall
}
gettar zlib-1.2.8 http://zlib.net/zlib-1.2.8.tar.gz
-CC=$HOME/work/Rump-kernels/rumpuser-xen/app-tools/rumpapp-xen-cc \
- ./configure --static --prefix=$HOME/work/Rump-kernels/prefix \
+dirx env CC=$HOME/work/Rump-kernels/rumpuser-xen/app-tools/rumpapp-xen-cc \
+ ./configure --static --prefix=$HOME/work/Rump-kernels/prefix \
--libdir=$HOME/work/Rump-kernels/prefix/lib \
--includedir=$HOME/work/Rump-kernels/prefix/include
-
-
+stdmake
+stdmakeinstall
want libffi-3.1 ftp://sourceware.org/pub/libffi/libffi-3.1.tar.gz
want glib-2.32.4 http://ftp.gnome.org/pub/gnome/sources/glib/2.32/glib-2.32.4.tar.xz
+