diff options
author | Eric Wong <normalperson@yhbt.net> | 2008-06-01 22:24:55 +0000 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2008-06-01 22:24:55 +0000 |
commit | 8a4dff14ad7560aae83e9155d0c62ba7f8c101fd (patch) | |
tree | f9803ea83fa7cb6020e84b78f3fc45b4086e4a13 /bs/mkdist.sh | |
parent | 97698bd4aaf168620205fea26f089e7b1acc869d (diff) | |
download | mpd-8a4dff14ad7560aae83e9155d0c62ba7f8c101fd.tar.gz mpd-8a4dff14ad7560aae83e9155d0c62ba7f8c101fd.tar.xz mpd-8a4dff14ad7560aae83e9155d0c62ba7f8c101fd.zip |
Add the bs build system from mpd-ke
Dealing with autotools is too painful when having
to deal with multiple build environments and
configurations.
git-svn-id: https://svn.musicpd.org/mpd/trunk@7368 09075e82-0dd4-0310-85a5-a0d7c8717e4f
Diffstat (limited to 'bs/mkdist.sh')
-rwxr-xr-x | bs/mkdist.sh | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/bs/mkdist.sh b/bs/mkdist.sh new file mode 100755 index 000000000..130871345 --- /dev/null +++ b/bs/mkdist.sh @@ -0,0 +1,50 @@ +#!/bin/sh +set -e +. bs/pkginfo.sh +head=${1-'HEAD'} +git_ver= +if git rev-parse --git-dir > /dev/null 2>&1; then + git_ver=`git describe $head` + git_ver=`expr "z$git_ver" : 'z.*\(-g[0-9a-f].*\)' || true` + if test -n "$git_ver"; then + dirty=`git diff-index --name-only HEAD 2>/dev/null || true` + if test -n "$dirty"; then + git_ver=$git_ver-dirty + fi + fi +fi + +v=$v$git_ver +dir=$O/$p-$v +rm -rf "$dir" +git tar-tree $head $dir | tar x + +at_files=' +Makefile.in +aclocal.m4 +compile +config.guess +config.h.in +config.sub +configure +depcomp +doc/Makefile.in +install-sh +ltmain.sh +missing +mkinstalldirs +src/Makefile.in +src/mp4ff/Makefile.in +' + +for i in $at_files; do + if test -f $i; then + echo cp $i $dir/$i + cp $i $dir/$i + fi +done + +cd $O +tar c $p-$v | gzip -9 > $p-$v.tar.gz +rm -rf $p-$v +echo "Generated tarball in: $p-$v.tar.gz" |