/[baselayout]/branches/baselayout-1_12/sbin/depscan.sh
Gentoo

Diff of /branches/baselayout-1_12/sbin/depscan.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1984 Revision 1985
42 fi 42 fi
43done 43done
44 44
45# Only update if files have actually changed 45# Only update if files have actually changed
46if ! ${update} ; then 46if ! ${update} ; then
47 clock_screw=false 47 clock_screw=0
48 mtime_test="${mysvcdir}/mtime-test.$$" 48 mtime_test="${mysvcdir}/mtime-test.$$"
49 49
50 # If its not there, we have to update, and make sure its present 50 # If its not there, we have to update, and make sure its present
51 # for next mtime testing 51 # for next mtime testing
52 if [[ ! -e "${mysvcdir}/depcache" ]] ; then 52 if [[ ! -e "${mysvcdir}/depcache" ]] ; then
59 do 59 do
60 ! ${update} \ 60 ! ${update} \
61 && is_older_than "${mysvcdir}/depcache" "${config}" \ 61 && is_older_than "${mysvcdir}/depcache" "${config}" \
62 && update=true 62 && update=true
63 63
64 is_older_than "${mtime_test}" "${config}" && clock_screw=true 64 is_older_than "${mtime_test}" "${config}" && clock_screw=1
65 done 65 done
66 rm -f "${mtime_test}" 66 rm -f "${mtime_test}"
67 67
68 ${clock_screw} && \ 68 if [[ ${clock_screw} == 1 ]] ; then
69 ewarn "Some file in '/etc/{conf.d,init.d}' have Modification time in the future!" 69 ewarn "One of the files in /etc/{conf.d,init.d} or /etc/rc.conf"
70 ewarn "has a modification time in the future!"
71 fi
70 72
71 shift 73 shift
72fi 74fi
73 75
74! ${update} && [[ -e "${mysvcdir}/deptree" ]] && exit 0 76! ${update} && [[ -e "${mysvcdir}/deptree" ]] && exit 0
75 77
76ebegin "Caching service dependencies" 78ebegin "Caching service dependencies"
77 79
78# Clean out the non volitile directories ... 80# Clean out the non volatile directories ...
79rm -rf "${mysvcdir}"/dep{cache,tree} "${mysvcdir}"/{broken,snapshot}/* 81rm -rf "${mysvcdir}"/dep{cache,tree} "${mysvcdir}"/{broken,snapshot}/*
80 82
81retval=0 83retval=0
82SVCDIR="${mysvcdir}" 84SVCDIR="${mysvcdir}"
83DEPTYPES="${deptypes}" 85DEPTYPES="${deptypes}"

Legend:
Removed from v.1984  
changed lines
  Added in v.1985

  ViewVC Help
Powered by ViewVC 1.1.20