comparison tools/patch-tool-mxe @ 2491:14be80e4c69f

Patch tool: Adding some progress messages to long processes.
author Ryan Pavlik <rpavlik@iastate.edu>
date Mon, 07 May 2012 12:45:03 -0500
parents 0db1b21402e9
children b48e499007b7
comparison
equal deleted inserted replaced
2490:0db1b21402e9 2491:14be80e4c69f
44 } 44 }
45 # init 45 # init
46 function init_git { 46 function init_git {
47 setupEnv 47 setupEnv
48 cd $gitsdir 48 cd $gitsdir
49
50 echo "Checking for cached $pkg_file"
49 if [ ! -f $mxedir/pkg/$pkg_file ]; then 51 if [ ! -f $mxedir/pkg/$pkg_file ]; then
50 make -C "$mxedir" download-$pkg 52 make -C "$mxedir" download-$pkg
53 echo "Building the mxe Makefile target 'download-$pkg' to get missing file"
51 if [ ! $? -eq 0 ]; then 54 if [ ! $? -eq 0 ]; then
52 echo "Could not build target download-$pkg - cancelling init." >&2 55 echo "Could not build target download-$pkg - cancelling init." >&2
53 exit 1 56 exit 1
54 fi 57 fi
55 fi 58 fi
59
60 echo "Unpacking archive..."
56 echo $pkg_file | grep "\.tar\.gz" >> /dev/null && tar xf $mxedir/pkg/$pkg_file 61 echo $pkg_file | grep "\.tar\.gz" >> /dev/null && tar xf $mxedir/pkg/$pkg_file
57 echo $pkg_file | grep "\.tar\.bz2" >> /dev/null && tar xf $mxedir/pkg/$pkg_file 62 echo $pkg_file | grep "\.tar\.bz2" >> /dev/null && tar xf $mxedir/pkg/$pkg_file
58 echo $pkg_file | grep "\.tar\.xz" >> /dev/null && xz -dc $mxedir/pkg/$pkg_file | tar xf - 63 echo $pkg_file | grep "\.tar\.xz" >> /dev/null && xz -dc $mxedir/pkg/$pkg_file | tar xf -
59 echo $pkg_file | grep "\.zip" >> /dev/null && unzip $mxedir/pkg/$pkg_file >> /dev/null 64 echo $pkg_file | grep "\.zip" >> /dev/null && unzip $mxedir/pkg/$pkg_file >> /dev/null
65
66 echo "Initializing repo and adding all as first commit"
60 cd $gitsdir/$pkg_subdir && \ 67 cd $gitsdir/$pkg_subdir && \
61 (git init; git add -A; git commit -m "init") > /dev/null 68 (git init; git add -A; git commit -m "init") > /dev/null
69
70 echo "Tagging distribution tarball state"
62 git tag dist 71 git tag dist
63 } 72 }
64 73
65 function export_patch { 74 function export_patch {
66 setupEnv 75 setupEnv