Magellan Linux

Diff of /trunk/mage/usr/lib/mage/depwalker.sh

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

revision 2280 by niro, Wed Nov 20 12:20:12 2013 UTC revision 2281 by niro, Wed Nov 20 12:21:28 2013 UTC
# Line 127  depwalking() Line 127  depwalking()
127    
128   DFILE="$1"   DFILE="$1"
129    
130     if [[ ${DEBUG} = 1 ]]
131     then
132     echo "DEBUG: depwalking magefile '${DFILE}'" >&2
133     echo >&2
134     fi
135    
136   source ${DFILE}   source ${DFILE}
137    
138   # forced nodeps   # forced nodeps
# Line 185  depwalking() Line 191  depwalking()
191    
192   if [ -z "${MY_DEPEND}" ]   if [ -z "${MY_DEPEND}" ]
193   then   then
194     if [[ ${DEBUG} = 1 ]]
195     then
196     echo "DEBUG: MY_DEPEND is empty; deps of '${DFILE}' ignored" >&2
197     fi
198   return 1   return 1
199   fi   fi
200    
# Line 235  depwalking() Line 245  depwalking()
245   then   then
246   depwalking ${HIGHEST_DEPFILE}   depwalking ${HIGHEST_DEPFILE}
247   ALLDEPS="${ALLDEPS} ${HIGHEST_DEPFILE}"   ALLDEPS="${ALLDEPS} ${HIGHEST_DEPFILE}"
248     if [[ ${DEBUG} = 1 ]]
249     then
250     echo "DEBUG: added '${HIGHEST_DEPFILE}' to ALLDEPS" >&2
251     fi
252   fi   fi
253   fi   fi
254   done << EOF   done << EOF
# Line 265  then Line 279  then
279   # get the highest mage file from mage-db   # get the highest mage file from mage-db
280   MAGEFILE="$(get_highest_magefile ${PCAT} ${PNAME})"   MAGEFILE="$(get_highest_magefile ${PCAT} ${PNAME})"
281    
282     if [[ ${DEBUG} = 1 ]]
283     then
284     echo "DEBUG: dep='${dep}'" >&2
285     echo "DEBUG: PCAT='${PCAT}'" >&2
286     echo "DEBUG: PNAME='${PNAME}'" >&2
287     echo "DEBUG: MAGEFILE='${MAGEFILE}'" >&2
288     fi
289    
290   # if no install candidate was found, record this   # if no install candidate was found, record this
291   # and process with the next one   # and process with the next one
292   if [[ -z ${MAGEFILE} ]]   if [[ -z ${MAGEFILE} ]]
293   then   then
294   NO_UPGRADE_CANDIDATE="${NO_UPGRADE_CANDIDATE} ${PCAT}/${PNAME}"   NO_UPGRADE_CANDIDATE="${NO_UPGRADE_CANDIDATE} ${PCAT}/${PNAME}"
295     if [[ ${DEBUG} = 1 ]]
296     then
297     echo "DEBUG: added to NO_UPGRADE_CANDIDATE" >&2
298     fi
299   continue   continue
300   fi   fi
301    
# Line 277  then Line 303  then
303   PVER="$(magename2pver ${MAGEFILE})"   PVER="$(magename2pver ${MAGEFILE})"
304   PBUILD="$(magename2pbuild ${MAGEFILE})"   PBUILD="$(magename2pbuild ${MAGEFILE})"
305    
306     if [[ ${DEBUG} = 1 ]]
307     then
308     echo "DEBUG: PVER='${PVER}'" >&2
309     echo "DEBUG: PBUILD='${PBUILD}'" >&2
310     fi
311    
312   # do not walk files which are installed   # do not walk files which are installed
313   if [ ! -d ${INSTALLDB}/${PCAT}/${PNAME}-${PVER}-${PBUILD} ]   if [ ! -d ${INSTALLDB}/${PCAT}/${PNAME}-${PVER}-${PBUILD} ]
314   then   then
# Line 287  then Line 319  then
319   # (if not exists already)   # (if not exists already)
320   if checklist_alldeps "${MAGEFILE}"   if checklist_alldeps "${MAGEFILE}"
321   then   then
322     if [[ ${DEBUG} = 1 ]]
323     then
324     echo "DEBUG: added '${MAGEFILE}' to ALLDEPS" >&2
325     fi
326   ALLDEPS="${ALLDEPS} ${MAGEFILE}"   ALLDEPS="${ALLDEPS} ${MAGEFILE}"
327   fi   fi
328     else
329     if [[ ${DEBUG} = 1 ]]
330     then
331     echo "DEBUG: ignored package" >&2
332     echo >&2
333     fi
334   fi   fi
335   done   done
336  else  else
# Line 308  then Line 350  then
350   # (if not exists already)   # (if not exists already)
351   if checklist_alldeps "${MAGEFILE}"   if checklist_alldeps "${MAGEFILE}"
352   then   then
353     if [[ ${DEBUG} = 1 ]]
354     then
355     echo "DEBUG: added '${MAGEFILE}' to ALLDEPS" >&2
356     fi
357   ALLDEPS="${ALLDEPS} ${MAGEFILE}"   ALLDEPS="${ALLDEPS} ${MAGEFILE}"
358   fi   fi
359  fi  fi

Legend:
Removed from v.2280  
changed lines
  Added in v.2281