view tools/touch_suffixes.sh @ 232:dbf0b2cff3af

save suffix based build work
author ray@terran.dlink.ua
date Wed, 30 Nov 2011 16:09:50 +0200
parents
children
line wrap: on
line source
#!/bin/sh

TARGET=$1
echo ${TARGET}

DIRNAME=`dirname ${TARGET}`
FILENAME=`basename ${TARGET}`
SUFFIXES=`echo ${FILENAME} | sed 's/\\./ /g'`

FILE=""
for p in ${SUFFIXES} ; do
	if [ -z "${FILE}" ]; then
		FILE="${p}"
		continue;
	fi
	FILE="${FILE}.${p}"
	if [ ! -f ${DIRNAME}/${FILE} ]; then
		# Make it very old
		touch -t 197000000000 ${DIRNAME}/${FILE}
	fi
done


exit 0