Permalink
Browse files

Improvements to DAR related to RPMforge-extras, duplicates and RHEL6

  • Loading branch information...
1 parent f19e134 commit 6c81c6d3fbdd606082e3baf98c78426e07393cff @dagwieers committed Nov 17, 2010
Showing with 545 additions and 446 deletions.
  1. +1 −1 Makefile
  2. +2 −1 commands.txt
  3. +6 −15 dar-build
  4. +46 −0 dar-duplicate
  5. +406 −418 dar-functions
  6. +52 −0 dar-metadata
  7. +5 −4 dar-shell
  8. +11 −6 dar-update
  9. +2 −1 dar.conf
  10. +2 −0 dists/el2i/config
  11. +2 −0 dists/el3a/config
  12. +2 −0 dists/el3i/config
  13. +2 −0 dists/el4a/config
  14. +2 −0 dists/el4i/config
  15. +2 −0 dists/el5a/config
  16. +2 −0 dists/el5i/config
View
@@ -9,7 +9,7 @@ sysconfdir=/etc
localstatedir=/var
sbindir=/usr/sbin
-DIST_SCRIPTS=dar-build dar-dotty dar-exec dar-kickoff dar-new dar-prepare dar-repo dar-shell dar-sync dar-update
+DIST_SCRIPTS=dar-build dar-dotty dar-exec dar-kickoff dar-metadata dar-new dar-prepare dar-repo dar-shell dar-sync dar-update
DIST_LIBS=dar-functions
DESTDIR=
View
@@ -2,7 +2,8 @@
### """"""""
### Install build environment
-old=fc3-i386; new=el4-i386; chr=el4i; diff -u <(cut -f1 /dar/pub/rpmforge/persona/dag/state/rpmqa-$old.list) <(cut -f1 /dar/pub/rpmforge/persona/dag/state/rpmqa-$new.list) | grep "^-" | sed -e 's|^-||' | xargs dar-update -d $chr
+#old=fc3-i386; new=el4-i386; chr=el4i; diff -u <(cut -f1 /dar/pub/rpmforge/persona/dag/state/rpmqa-$old.list) <(cut -f1 /dar/pub/rpmforge/persona/dag/state/rpmqa-$new.list) | grep "^-" | sed -e 's|^-||' | xargs dar-update -d $chr
+dar-exec -d el6i yum install $(old=el5i; new=el6i; diff -u <(dar-exec -q -d $old rpm -qa --qf '%{name}\\n' | sort) <(dar-exec -q -d $new rpm -qa --qf '%{name}\\n' | sort) | grep "^-" | sed -e 's|^-||')
### Build missing packages compared to other dist
old=fc3-i386; new=el4-i386; chr=el4i; diff -u <(cut -f1 /dar/pub/rpmforge/persona/dag/state/packages-$old.list) <(cut -f1 /dar/pub/rpmforge/persona/dag/state/packages-$new.list) | grep "^-" | sed -e 's|^-||' | xargs dar-build -n -d $chr
View
@@ -62,7 +62,6 @@ for arg in $PKGS; do
chown -R $BUILD_USER.$BUILD_GROUP "$SPECDIR/"
chmod -R a+r "$SPECDIR/"
- set_tag
set_dists
set_exclude_dist
set_exclusive_dist
@@ -82,6 +81,7 @@ for arg in $PKGS; do
continue
fi
+ set_tag
if [ "$TAG" ]; then
TAGS="$TAG"
fi
@@ -146,20 +146,11 @@ for arg in $PKGS; do
### Check if already build (2 version schemes, multiple disttags)
for disttag in $DISTNAME $DISTTAG; do
for tag in $TAGS; do
- NEWRPMFILE="$app-$VERSION-$RELEASE.$arch.rpm"
- OLDRPMFILE="$app-$VERSION-$RELEASE.$arch.rpm"
- for rpmfile in $NEWRPMFILE $OLDRPMFILE; do
-# echo $rpmfile
- if [ -z "$FORCE_OVERWRITE" -a -f "$PACKAGEDIR/$app/$rpmfile" ]; then
- warning "Package \"$PACKAGEDIR/$app/$rpmfile\" already exists."
-
-# if [ -z "$SOURCE_DISTS" ]; then
-# SOURCE_DISTS="$DISTNICK"
-# fi
-
- continue 4
- fi
- done
+ rpmfile="$app-$VERSION-$RELEASE.$arch.rpm"
+ if [ -z "$FORCE_OVERWRITE" -a -f "$PACKAGEDIR/$app/$rpmfile" ]; then
+ warning "Package \"$PACKAGEDIR/$app/$rpmfile\" already exists."
+ continue 3
+ fi
done
done
View
@@ -0,0 +1,46 @@
+#!/bin/bash
+
+source "/usr/share/dar/dar-functions"
+
+for pkg in /dar/rpms/*; do
+ title=
+ base="$(basename $pkg)"
+ cat <<EOF | while read dist name path; do
+el6 EL6 rhel6s-i386
+el5 EL5 rhel5s-i386
+el4 EL4 rhel4as-i386
+el3 EL3 rhel3as-i386
+el2 EL2 rhel2.1as-i386
+EOF
+ unset ${!dist}
+ for file in /dar/mrepo/$path/{updates,optional}/$base-*.rpm; do
+ if [ -f $file ]; then
+ file=$(basename $file)
+ version="${file#*-}"
+ version="${file%.*.*}"
+ if [ -z "$title" ]; then
+ echo -e "$_BL_$_WH= Found \"$_YE$base/$base.spec$_WH\"$_DE"
+ title="yes"
+ fi
+ echo "### $name ships with $version"
+ echo "%{?$dist:# Tag: rfx}"
+ for file in /dar/packages/$base/*.$dist.rf.*.rpm; do
+ if [ -f $file ]; then
+ mkdir -p /dar/old/$base/
+ mv -v $file /dar/old/$base/
+ fi
+ done
+ for file in /dar/packages/$base/_buildlogs/*.$dist.rf.*.log.gz; do
+ if [ -f $file ]; then
+ mkdir -p /dar/old/$base/_buildlogs/
+ mv -v $file /dar/old/$base/_buildlogs/
+ fi
+ done
+ break
+ fi
+ done
+ done
+# if [ "$title" ]; then
+# echo
+# fi
+done
Oops, something went wrong.

0 comments on commit 6c81c6d

Please sign in to comment.