[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Sheflug] tar files



This is pretty much how I build kde, but I add a safeguard of checking
if a command fails or not e.g. I create a "command" function:-


command() {
   cmd="$*"
   if $cmd;
   then
      echo "$cmd for succeeded"
   else
      echo "$cmd for failed"
      exit 1;
   fi
}


and in the for loop:-

 make distclean;
 command ./configure --with-qt-dir=$QTDIR --prefix=$KDEDIR
 command make;
 command make install;

  Dave.





On Fri, 2002-10-11 at 18:27, Eric E Moore wrote:
> Douglas G Mckendrick <Rhinecourt [at] btopenworld.com> writes:
> 
> > Is there a command I can use that will open, make and install a batch of tar 
> > files.  Or is it best to do each individually?
> 
> probably you'd want to write a small shellscript to do it, but you'd
> need to make assumptions about the build/install process.  something
> like:
> 
> for i in *.tar
> do
>     tar xf $i
>     pushd `basename $i .tar`
>     ./configure
>     make
>     make install
>     popd
> done
> 
> would do most GNU tools, but I'd not really want to try it, if
> anything went wrong, god only knows what'd happen, and it's no big
> deal to do them individually (usually :)
> 
> -- 
> Eric E. Moore
-- 
Dr. David Holden. (Systems Developer)
check-out : crystallography journals online <http://journals.iucr.org>

Thanks in advance:-
Please avoid sending me Word or PowerPoint attachments.
See: <http://www.fsf.org/philosophy/no-word-attachments.html>

Personal Links:-
Recommended reading : http://www.oreilly.com/catalog/dbnationtp/
UK Privacy (R.I.P)  : http://www.stand.org.uk/commentary.php3
Public GPG key available on request.

-- 99% of politicians give the rest a bad name --
------------------------------------------------- 

___________________________________________________________________

Sheffield Linux User's Group -
http://www.sheflug.co.uk/mailfaq.html

  GNU the choice of a complete generation.