mirror of
https://github.com/flatcar/scripts.git
synced 2025-08-09 05:56:58 +02:00
Merge pull request #657 from dm0-/perl-glsa
Update Perl to fix the last GLSA
This commit is contained in:
commit
66dca6ab85
@ -120,7 +120,7 @@ cat <<EOF
|
|||||||
target: stage1
|
target: stage1
|
||||||
# stage1 packages aren't published, save in tmp
|
# stage1 packages aren't published, save in tmp
|
||||||
pkgcache_path: ${TEMPDIR}/stage1-${ARCH}-packages
|
pkgcache_path: ${TEMPDIR}/stage1-${ARCH}-packages
|
||||||
update_seed: yes
|
#update_seed: yes
|
||||||
EOF
|
EOF
|
||||||
catalyst_stage_default
|
catalyst_stage_default
|
||||||
}
|
}
|
||||||
|
@ -176,25 +176,33 @@ done
|
|||||||
|
|
||||||
"${BUILD_LIBRARY_DIR}/set_lsb_release" --root /
|
"${BUILD_LIBRARY_DIR}/set_lsb_release" --root /
|
||||||
|
|
||||||
EMERGE_FLAGS="-uNv --with-bdeps=y --select"
|
EMERGE_FLAGS=( -uNv --with-bdeps=y --select )
|
||||||
REBUILD_FLAGS=""
|
REBUILD_FLAGS=()
|
||||||
if [ "${FLAGS_usepkg}" -eq "${FLAGS_TRUE}" ]; then
|
if [ "${FLAGS_usepkg}" -eq "${FLAGS_TRUE}" ]; then
|
||||||
EMERGE_FLAGS="${EMERGE_FLAGS} --usepkg"
|
EMERGE_FLAGS+=( --usepkg )
|
||||||
if [[ "${FLAGS_usepkgonly}" -eq "${FLAGS_TRUE}" ]]; then
|
if [[ "${FLAGS_usepkgonly}" -eq "${FLAGS_TRUE}" ]]; then
|
||||||
EMERGE_FLAGS+=" --usepkgonly --rebuilt-binaries n"
|
EMERGE_FLAGS+=( --usepkgonly --rebuilt-binaries n )
|
||||||
fi
|
fi
|
||||||
if [ "${FLAGS_getbinpkg}" -eq "${FLAGS_TRUE}" ]; then
|
if [ "${FLAGS_getbinpkg}" -eq "${FLAGS_TRUE}" ]; then
|
||||||
EMERGE_FLAGS="${EMERGE_FLAGS} --getbinpkg"
|
EMERGE_FLAGS+=( --getbinpkg )
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Only update toolchain when binpkgs are available.
|
# Only update toolchain when binpkgs are available.
|
||||||
EMERGE_FLAGS+=" $(get_binonly_args $(get_chost_list))"
|
EMERGE_FLAGS+=( $(get_binonly_args $(get_chost_list)) )
|
||||||
REBUILD_FLAGS+=" $(get_binonly_args $(get_chost_list))"
|
REBUILD_FLAGS+=( $(get_binonly_args $(get_chost_list)) )
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "${FLAGS_jobs}" -ne -1 ]]; then
|
if [[ "${FLAGS_jobs}" -ne -1 ]]; then
|
||||||
EMERGE_FLAGS+=" --jobs=${FLAGS_jobs}"
|
EMERGE_FLAGS+=( "--jobs=${FLAGS_jobs}" )
|
||||||
REBUILD_FLAGS+=" --jobs=${FLAGS_jobs}"
|
REBUILD_FLAGS+=( "--jobs=${FLAGS_jobs}" )
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Force rebuilding some misbehaving Perl modules for the 5.22 upgrade.
|
||||||
|
if : || portageq has_version / '<dev-lang/perl-5.22'; then
|
||||||
|
EMERGE_FLAGS+=(
|
||||||
|
--reinstall-atoms='dev-perl/File-Slurp dev-perl/Locale-gettext perl-core/File-Temp'
|
||||||
|
--usepkg-exclude='dev-perl/File-Slurp dev-perl/Locale-gettext perl-core/File-Temp'
|
||||||
|
)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Perform an update of coreos-devel/sdk-depends and world in the chroot.
|
# Perform an update of coreos-devel/sdk-depends and world in the chroot.
|
||||||
@ -203,7 +211,7 @@ EMERGE_CMD="emerge"
|
|||||||
# In first pass, update portage and toolchains. Lagged updates of both
|
# In first pass, update portage and toolchains. Lagged updates of both
|
||||||
# can cause serious issues later.
|
# can cause serious issues later.
|
||||||
info "Updating basic system packages"
|
info "Updating basic system packages"
|
||||||
sudo -E ${EMERGE_CMD} --quiet ${EMERGE_FLAGS} \
|
sudo -E ${EMERGE_CMD} --quiet "${EMERGE_FLAGS[@]}" \
|
||||||
dev-util/ccache \
|
dev-util/ccache \
|
||||||
sys-apps/portage \
|
sys-apps/portage \
|
||||||
sys-devel/crossdev \
|
sys-devel/crossdev \
|
||||||
@ -221,7 +229,7 @@ if [[ "${FLAGS_skip_toolchain_update}" -eq "${FLAGS_FALSE}" && \
|
|||||||
|
|
||||||
for cross_chost in "${CROSS_CHOSTS[@]}"; do
|
for cross_chost in "${CROSS_CHOSTS[@]}"; do
|
||||||
info "Updating cross ${cross_chost} toolchain"
|
info "Updating cross ${cross_chost} toolchain"
|
||||||
install_cross_toolchain "${cross_chost}" --quiet ${EMERGE_FLAGS}
|
install_cross_toolchain "${cross_chost}" --quiet "${EMERGE_FLAGS[@]}"
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -229,14 +237,14 @@ fi
|
|||||||
CHROMITE_BIN="${GCLIENT_ROOT}/chromite/bin"
|
CHROMITE_BIN="${GCLIENT_ROOT}/chromite/bin"
|
||||||
if [ "${FLAGS_workon}" -eq "${FLAGS_TRUE}" ]; then
|
if [ "${FLAGS_workon}" -eq "${FLAGS_TRUE}" ]; then
|
||||||
for pkg in $("${CHROMITE_BIN}/cros_list_modified_packages" --host); do
|
for pkg in $("${CHROMITE_BIN}/cros_list_modified_packages" --host); do
|
||||||
EMERGE_FLAGS+=" --reinstall-atoms=${pkg} --usepkg-exclude=${pkg}"
|
EMERGE_FLAGS+=( "--reinstall-atoms=${pkg}" "--usepkg-exclude=${pkg}" )
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Second pass, update everything else.
|
# Second pass, update everything else.
|
||||||
EMERGE_FLAGS+=" --deep"
|
EMERGE_FLAGS+=( --deep )
|
||||||
info "Updating all SDK packages"
|
info "Updating all SDK packages"
|
||||||
sudo -E ${EMERGE_CMD} ${EMERGE_FLAGS} \
|
sudo -E ${EMERGE_CMD} "${EMERGE_FLAGS[@]}" \
|
||||||
coreos-devel/sdk-depends world
|
coreos-devel/sdk-depends world
|
||||||
|
|
||||||
info "Removing obsolete packages"
|
info "Removing obsolete packages"
|
||||||
@ -244,7 +252,7 @@ sudo -E ${EMERGE_CMD} --quiet --depclean @unavailable
|
|||||||
|
|
||||||
if portageq list_preserved_libs / >/dev/null; then
|
if portageq list_preserved_libs / >/dev/null; then
|
||||||
info "Rebuilding packages linked against old libraries"
|
info "Rebuilding packages linked against old libraries"
|
||||||
sudo -E ${EMERGE_CMD} ${REBUILD_FLAGS} @preserved-rebuild
|
sudo -E ${EMERGE_CMD} "${REBUILD_FLAGS[@]}" @preserved-rebuild
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Automatically discard all CONFIG_PROTECT'ed files. Those that are
|
# Automatically discard all CONFIG_PROTECT'ed files. Those that are
|
||||||
|
Loading…
Reference in New Issue
Block a user