From 30b9a391ac42ed735b33bf1e374a145b577620a7 Mon Sep 17 00:00:00 2001 From: Raphaƫl Hertzog Date: Thu, 19 Dec 2019 19:07:59 +0100 Subject: Fix "--debian-installer cdrom" and its interaction with binary_package-lists apt-ftparchive is not able to differentiate between .deb and .udeb so we have to install them in different pool directories so that we can regenerate the Packages files without having the .udeb show up unexpectedly. Since binary_package-lists can overwrite the Packages files generated in installer_debian-installer we have to ensure that it also updates the Release file created formerly. Ideally we should find a way to avoid the duplication of this logic. Gbp-Dch: Full --- scripts/build/binary_package-lists | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'scripts/build/binary_package-lists') diff --git a/scripts/build/binary_package-lists b/scripts/build/binary_package-lists index 54725b580..599ab884a 100755 --- a/scripts/build/binary_package-lists +++ b/scripts/build/binary_package-lists @@ -129,6 +129,15 @@ then mv "${FILE}" binary/${POOL}/${SECTION}/"${LETTER}"/"${SOURCE}" done + if [ -e chroot/etc/os-release ] + then + _VERSION="$(. chroot/etc/os-release && echo ${VERSION_ID})" + fi + + if [ -n "${_VERSION}" ]; then + _LB_APT_VERSION_OPT='-o APT::FTPArchive::Release::Version="'"${_VERSION}"'"' + fi + cd binary for SECTION in ${POOL}/* @@ -144,6 +153,21 @@ then gzip -9 -c ${DISTS}/${LB_PARENT_DISTRIBUTION_BINARY}/${SECTION}/binary-${LB_ARCHITECTURES}/Packages > ${DISTS}/${LB_PARENT_DISTRIBUTION_BINARY}/${SECTION}/binary-${LB_ARCHITECTURES}/Packages.gz done + if [ -d dists/${LB_PARENT_DISTRIBUTION_BINARY} ]; then + apt-ftparchive \ + -o APT::FTPArchive::Release::Origin="Debian" \ + -o APT::FTPArchive::Release::Label="Debian" \ + -o APT::FTPArchive::Release::Suite="${LB_PARENT_DISTRIBUTION_BINARY}" \ + ${_LB_APT_VERSION_OPT} \ + -o APT::FTPArchive::Release::Codename="${LB_PARENT_DISTRIBUTION_BINARY}" \ + -o APT::FTPArchive::Release::Date="$(date -R)" \ + -o APT::FTPArchive::Release::Architectures="${LB_ARCHITECTURES}" \ + -o APT::FTPArchive::Release::Components="${LB_PARENT_ARCHIVE_AREAS}" \ + -o APT::FTPArchive::Release::Description="Last updated: $(date -R)" \ + release dists/${LB_PARENT_DISTRIBUTION_BINARY} \ + > dists/${LB_PARENT_DISTRIBUTION_BINARY}/Release + fi + cd "${OLDPWD}" rm -f chroot/bin/Packages -- cgit v1.2.3