Bugfix
authorDaniel Abrecht <public@danielabrecht.ch>
Sun, 12 Dec 2021 22:00:11 +0000 (23:00 +0100)
committerDaniel Abrecht <public@danielabrecht.ch>
Sun, 12 Dec 2021 22:01:28 +0000 (23:01 +0100)
chroot-build-helper/real-makefile
script/dparepo

index 364d0d9d2a88972b3a7ad785c81993a0e732611d..8196b3cd1d42c3abe2e24df96c5f85a096ebe22c 100644 (file)
@@ -126,14 +126,7 @@ repo-add@%:
        set -x; \
        cd "build-env/$(DISTRO)/$(RELEASE)/rootfs/root/$(patsubst repo-add@%,%,$@)/"; \
        name="$$(printf '%s' *.changes)"; \
-       cp "$$name" ".$$name"; \
-       sed -i 's/\.ddeb$$/.deb/' ".$$name"; \
-       for ddeb in *.ddeb; \
-         do if [ -f "$$ddeb" ]; \
-           then ln -sf "$$ddeb" "$$(basename "$$ddeb" .ddeb).deb"; \
-         fi;  \
-       done; \
-       addrepo.sh ".$$name"
+       addrepo.sh "$$name"
 
 clean-repo: $(addprefix clean-repo@,$(PACKAGES_TO_BUILD))
 reset-repo: $(addprefix reset-repo@,$(PACKAGES_TO_BUILD))
index 464d43467a69bbc20c1340579bbdb25503b3dfd7..6d677e5446bb6639bb70db9408ef25fdd2afd95e 100755 (executable)
@@ -117,6 +117,17 @@ do_add(){
   fi
   component="$1"; shift
   deb="$1"; shift
+  case "$deb" in
+    *.changes)
+      dir="$(dirname "$deb")"
+      sed -n '/^Files:$/ { :s; n; s/^ \([^ ]\+ \)\+\([^ ]\+\)$/\2/p; b s }' <"$deb" |
+      while IFS= read -r file
+      do
+        do_add "$component" "$dir/$file"
+      done
+      return 0
+    ;;
+  esac
   control="$(deb_get_control_file "$obase/$deb")"
   package="$(basename "$(sed -n 's/^Package: *\(.*\)/\1/p' <<<"$control")")"
   arch="$(sed -n 's/^Architecture: *\(.*\)/\1/p' <<<"$control")"