automaint: support importing from any architecture, not just base arch (i586)
This commit is contained in:
parent
67497d1d4f
commit
70548ea687
40
automaint
40
automaint
@ -159,34 +159,46 @@ for a in `seq 1 ${#ARCHS[*]}`; do
|
||||
needportlist[$a-1]="${needport_list[*]}"
|
||||
done
|
||||
|
||||
for p in ${pkglist[0]}; do
|
||||
tmpfile=`mktemp -q -t $me.XXXXXXXX` || {
|
||||
echo "ERROR: cannot create temporary files." >&2
|
||||
exit 1
|
||||
}
|
||||
|
||||
for a in `seq 1 ${#ARCHS[*]}`; do
|
||||
echo -n "${pkglist[$a-1]} " >> $tmpfile
|
||||
done
|
||||
allpkgs="`cat $tmpfile | xargs -n 1 | sort -u | xargs`"
|
||||
rm -f $tmpfile
|
||||
|
||||
for p in ${allpkgs}; do
|
||||
pkgcontinue=
|
||||
needsport=
|
||||
for a in `seq 1 ${#ARCHS[*]}`; do
|
||||
for w in ${warningslist[*]}; do
|
||||
[ "$p" = "$w" ] && { pkgcontinue=1; break; }
|
||||
done
|
||||
[ "$pkgcontinue" ] && continue
|
||||
[ "$pkgcontinue" ] && break
|
||||
|
||||
get_pkg_buildinfo $LOCAL_REPS_BASE_DIR/distromatic/$SOURCE_REPOSITORY ${ARCHS[0]} $p
|
||||
get_pkg_buildinfo $LOCAL_REPS_BASE_DIR/distromatic/$SOURCE_REPOSITORY ${ARCHS[$a-1]} $p
|
||||
|
||||
[ "$pkg_name" ] || {
|
||||
#echo "$p: looks like a new package; skipping."
|
||||
continue
|
||||
}
|
||||
|
||||
for o in ${needportlist[*]}; do
|
||||
[ "$p" = "$o" ] && { needsport=1; break; }
|
||||
done
|
||||
[ "$needsport" -a ! "$PORT_REPOSITORY" ] && continue
|
||||
[ "$needsport" -a ! "$PORT_REPOSITORY" ] && break
|
||||
|
||||
spkg_version=$pkg_version
|
||||
spkg_release=$pkg_release
|
||||
get_pkg_buildinfo $LOCAL_REPS_BASE_DIR/distromatic/$DEST_REPOSITORY ${ARCHS[0]} $p
|
||||
|
||||
[ "$pkg_name" ] || {
|
||||
echo "$p: looks like a new package; skipping."
|
||||
continue
|
||||
}
|
||||
get_pkg_buildinfo $LOCAL_REPS_BASE_DIR/distromatic/$DEST_REPOSITORY ${ARCHS[$a-1]} $p
|
||||
|
||||
if [ "$pkg_version" = "$spkg_version" ]; then
|
||||
if [ "$pkg_release" = "$spkg_release" ]; then
|
||||
echo "$p: same release as upstream; skipping."
|
||||
continue
|
||||
break
|
||||
fi
|
||||
update_type="release"
|
||||
else
|
||||
@ -201,12 +213,12 @@ for p in ${pkglist[0]}; do
|
||||
if [ "$i" = "${#SVER[*]}" ]; then
|
||||
if [[ 64#${SVER[i-1]} -gt 64#89 && 64#${VER[i-1]} -lt 64#80 ]]; then
|
||||
[ "$VERBOSE" ] && echo "$p: dubious beta upgrade from ${VER[i-1]} to ${SVER[i-1]}; skipping."
|
||||
continue
|
||||
break
|
||||
fi
|
||||
update_type="minor"
|
||||
else
|
||||
[ "$VERBOSE" ] && echo "$p: dubious not-minor version update $i/${#SVER[*]}: ${SVER[i-1]} != ${VER[i-1]}; skipping."
|
||||
continue
|
||||
break
|
||||
fi
|
||||
fi
|
||||
if [ "$needsport" ]; then
|
||||
@ -228,6 +240,8 @@ MESSAGE=`cgi_encodevar \"imported <b>$p</b> from <b>$SOURCE_REPOSITORY</b> to <b
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
break
|
||||
done
|
||||
done
|
||||
|
||||
exit 0
|
||||
|
Loading…
Reference in New Issue
Block a user