[baseimage]: Download picocom version 3.1-2 from stretch-backports; No longer build from source (#1946)

This commit is contained in:
Joe LeVeque 2018-08-17 17:38:20 -07:00 committed by lguohan
parent f05ee30d53
commit 98082d56a0
8 changed files with 10 additions and 59 deletions

View File

@ -229,6 +229,11 @@ sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y in
tcptraceroute \ tcptraceroute \
mtr-tiny mtr-tiny
# Install certain fundamental packages from stretch-backports in order to get
# more up-to-date (but potentially less stable) versions
sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y -t stretch-backports install \
picocom
sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y download \ sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y download \
grub-pc-bin grub-pc-bin
@ -237,9 +242,6 @@ sudo mv $FILESYSTEM_ROOT/grub-pc-bin*.deb $FILESYSTEM_ROOT/$PLATFORM_DIR/x86_64-
sudo dpkg --root=$FILESYSTEM_ROOT -i target/debs/libwrap0_*.deb || \ sudo dpkg --root=$FILESYSTEM_ROOT -i target/debs/libwrap0_*.deb || \
sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y install -f sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y install -f
sudo dpkg --root=$FILESYSTEM_ROOT -i target/debs/picocom_*.deb || \
sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y install -f
## Disable kexec supported reboot which was installed by default ## Disable kexec supported reboot which was installed by default
sudo sed -i 's/LOAD_KEXEC=true/LOAD_KEXEC=false/' $FILESYSTEM_ROOT/etc/default/kexec sudo sed -i 's/LOAD_KEXEC=true/LOAD_KEXEC=false/' $FILESYSTEM_ROOT/etc/default/kexec

View File

@ -5,3 +5,4 @@ deb http://debian-archive.trafficmanager.net/debian/ stretch main contrib non-fr
deb-src http://debian-archive.trafficmanager.net/debian/ stretch main contrib non-free deb-src http://debian-archive.trafficmanager.net/debian/ stretch main contrib non-free
deb http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free deb http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free
deb-src http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free deb-src http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free
deb http://debian-archive.trafficmanager.net/debian/ stretch-backports main contrib non-free

View File

@ -1,2 +1,3 @@
deb http://debian-archive.trafficmanager.net/debian/ stretch main contrib non-free deb http://debian-archive.trafficmanager.net/debian/ stretch main contrib non-free
deb http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free deb http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free
deb http://debian-archive.trafficmanager.net/debian/ stretch-backports main contrib non-free

View File

@ -1,11 +0,0 @@
# picocom packages
PICOCOM_VERSION = 3.1-2
export PICOCOM_VERSION
PICOCOM = picocom_$(PICOCOM_VERSION)_amd64.deb
$(PICOCOM)_SRC_PATH = $(SRC_PATH)/picocom
SONIC_MAKE_DEBS += $(PICOCOM)
SONIC_STRETCH_DEBS += $(PICOCOM)

View File

@ -462,8 +462,7 @@ $(addprefix $(TARGET_PATH)/, $(SONIC_INSTALLERS)) : $(TARGET_PATH)/% : \
$(BASH) \ $(BASH) \
$(LIBWRAP) \ $(LIBWRAP) \
$(LIBPAM_TACPLUS) \ $(LIBPAM_TACPLUS) \
$(LIBNSS_TACPLUS) \ $(LIBNSS_TACPLUS)) \
$(PICOCOM)) \
$$(addprefix $(TARGET_PATH)/,$$($$*_DOCKERS)) \ $$(addprefix $(TARGET_PATH)/,$$($$*_DOCKERS)) \
$$(addprefix $(PYTHON_WHEELS_PATH)/,$(SONIC_CONFIG_ENGINE)) \ $$(addprefix $(PYTHON_WHEELS_PATH)/,$(SONIC_CONFIG_ENGINE)) \
$$(addprefix $(PYTHON_WHEELS_PATH)/,$(SONIC_PLATFORM_COMMON_PY2)) $$(addprefix $(PYTHON_WHEELS_PATH)/,$(SONIC_PLATFORM_COMMON_PY2))

View File

@ -6,7 +6,7 @@ RUN echo "deb http://debian-archive.trafficmanager.net/debian/ stretch main cont
echo "deb-src http://debian-archive.trafficmanager.net/debian/ stretch main contrib non-free" >> /etc/apt/sources.list && \ echo "deb-src http://debian-archive.trafficmanager.net/debian/ stretch main contrib non-free" >> /etc/apt/sources.list && \
echo "deb http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free" >> /etc/apt/sources.list && \ echo "deb http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free" >> /etc/apt/sources.list && \
echo "deb-src http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free" >> /etc/apt/sources.list && \ echo "deb-src http://debian-archive.trafficmanager.net/debian-security/ stretch/updates main contrib non-free" >> /etc/apt/sources.list && \
echo 'deb http://debian-archive.trafficmanager.net/debian stretch-backports main' >> /etc/apt/sources.list echo "deb http://debian-archive.trafficmanager.net/debian stretch-backports main" >> /etc/apt/sources.list
## Make apt-get non-interactive ## Make apt-get non-interactive
ENV DEBIAN_FRONTEND=noninteractive ENV DEBIAN_FRONTEND=noninteractive
@ -201,9 +201,7 @@ RUN apt-get update && apt-get install -y \
# For pam_tacplus build # For pam_tacplus build
autoconf-archive \ autoconf-archive \
# For initramfs # For initramfs
bash-completion \ bash-completion
# For picocom
pandoc
# For linux build # For linux build
RUN apt-get -y build-dep linux RUN apt-get -y build-dep linux

View File

@ -1,28 +0,0 @@
.ONESHELL:
SHELL = /bin/bash
.SHELLFLAGS += -e
MAIN_TARGET = picocom_$(PICOCOM_VERSION)_amd64.deb
$(addprefix $(DEST)/, $(MAIN_TARGET)): $(DEST)/% :
# Remove any stale files
rm -rf ./picocom-3.1
# Get source package
wget -NO picocom_$(PICOCOM_VERSION).dsc "https://sonicstorage.blob.core.windows.net/packages/debian/picocom_3.1-2.dsc?sv=2015-04-05&sr=b&sig=puo9KA27jT9Ey%2FkxRPBLIm30gFDdQJF85VKA7vuv9hk%3D&se=2155-07-10T08%3A03%3A50Z&sp=r"
wget -NO picocom_$(PICOCOM_VERSION).debian.tar.xz "https://sonicstorage.blob.core.windows.net/packages/debian/picocom_3.1-2.debian.tar.xz?sv=2015-04-05&sr=b&sig=4HPuUi2FTb0AzCEsH9%2FsSfj17qIukyyOdRrHQFtjyBE%3D&se=2155-07-10T08%3A04%3A23Z&sp=r"
wget -NO picocom_3.1.orig.tar.gz "https://sonicstorage.blob.core.windows.net/packages/debian/picocom_3.1.orig.tar.gz?sv=2015-04-05&sr=b&sig=RjQ84sf%2B%2FQuI%2B0PAcbPHXvnlNAuP%2BQoVrp2xzDJZfX4%3D&se=2155-07-10T08%3A04%3A45Z&sp=r"
dpkg-source -x picocom_$(PICOCOM_VERSION).dsc
# Build source and Debian packages
pushd picocom-3.1
patch -p0 < ../debhelper_10.patch
dpkg-buildpackage -rfakeroot -b -us -uc -j$(SONIC_CONFIG_MAKE_JOBS)
popd
# Move the newly-built .deb packages to the destination directory
mv $(DERIVED_TARGETS) $* $(DEST)/
$(addprefix $(DEST)/, $(DERIVED_TARGETS)): $(DEST)/% : $(DEST)/$(MAIN_TARGET)

View File

@ -1,11 +0,0 @@
--- debian/control.old 2018-08-17 08:05:35.996230100 +0000
+++ debian/control 2018-08-17 08:05:43.712230100 +0000
@@ -3,7 +3,7 @@
Priority: optional
Maintainer: Matt Palmer <mpalmer@debian.org>
Uploaders: W. Martin Borgert <debacle@debian.org>
-Build-Depends: debhelper (>= 11),
+Build-Depends: debhelper (>= 10),
pandoc
Standards-Version: 4.1.3
Rules-Requires-Root: no