Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 15 Jan 2005 16:23:55 -0500
From:      Timothy Luoma <lists@tntluoma.com>
To:        FreeBSD-Questions Questions <freebsd-questions@freebsd.org>
Subject:   Re: make "make" quieter?
Message-ID:  <C2D5E321-673B-11D9-A288-000D93AD26C8@tntluoma.com>
In-Reply-To: <65F6863C-66C2-11D9-A44D-000D93AD26C8@tntluoma.com>
References:  <200501150605.j0F65Ket011697@mp.cs.niu.edu> <65F6863C-66C2-11D9-A44D-000D93AD26C8@tntluoma.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On Jan 15, 2005, at 1:55 AM, Timothy Luoma wrote:

> -s looks promising (d'oh, checked make.conf settings but not man 
> page... far too late, must sleep)

it's still too chatty.  Configure makes a lot of noise.

> Actually the redirect works well, esp. now that someone explained the 
> redirect (new to 'sudo' too)

spoke too soon.  it didn't work.  I think it has something to do with 
zsh.

Anyway, I decided that what I really wanted was a lot of the installs 
anyway, in some organized fashion, so I made a shell script, which 
works fine under 'sudo'

Here it is in case anyone is curious

TjL



#!/bin/sh

#
#       the purpose of this script is to suppress the output of
#       'make install clean' and to log it to a file
#


NAME=`basename $0`

LOG_DIR=/var/db/installs

         if [ ! -d "$LOG_DIR" ]
         then
                 mkdir -p "$LOG_DIR" ||\
                 (echo "$NAME: FATAL cannot find or create $LOG_DIR" && 
exit 1)
         fi

PWD_SAFE=`echo $PWD | sed 's#/#.#g; s#^.##g'`

INSTALL_LOG="$LOG_DIR/$PWD_SAFE"

# we touch the log.  if it already exists, we don't care, we'll just 
append to it
touch $INSTALL_LOG

echo "

---
$NAME: BEGINNING log of make install clean from $PWD which started at 
`date`

" >> $INSTALL_LOG

(make install clean  2>&1) >> $INSTALL_LOG

EXITCODE="$?"

echo "

$NAME: END log of make install clean from $PWD which finished at `date`
" >> $INSTALL_LOG


if [ "$EXITCODE" = "0" ]
then
         echo "$0: make install clean done from $PWD, logged to 
$INSTALL_LOG"
else

echo -n "

NOTE:   'make install clean' finished in $PWD
         Logged to $INSTALL_LOG

         DID NOT EXIT CLEANLY: $EXITCODE

"

fi
exit 0

# EOF



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?C2D5E321-673B-11D9-A288-000D93AD26C8>