URL
https://opencores.org/ocsvn/openrisc/openrisc/trunk
Subversion Repositories openrisc
[/] [openrisc/] [trunk/] [rtos/] [rtems/] [tools/] [build/] [lock-directory.in] - Rev 30
Go to most recent revision | Compare with Previous | Blame | View Log
#!@KSH@## $Id: lock-directory.in,v 1.2 2001-09-27 12:02:53 chris Exp $## Make a directory write protected# Used to write protect the install point after a build# to prevent inadvertant overwriting.## is a particular command available on this machine?#cmd_avail(){set -- `type $1 2>&1`if [ "$2" = "not" -a "$3" = "found" ] || [ "$3" = "not" -a "$4" = "found" ]thenreturn 1elsereturn 0fi}lock_directory() {l_dir=$1/. # get any symlink out of the way using '.'if [ -d $l_dir ]thenfind $l_dir -type d -perm -0200 -print | $XARGS chmod -wfi}# Use gnu xargs if available; faster, more reliable in generalXARGS=xargscmd_avail gxargs && XARGS=gxargsfor dirdolock_directory $dirdone# Local Variables: ***# mode:ksh ***# End: ***
Go to most recent revision | Compare with Previous | Blame | View Log
