mirror of
https://github.com/flatcar/scripts.git
synced 2025-09-23 22:51:03 +02:00
Merge pull request #58 from marineam/baselayout
Baselayout/release file fixes
This commit is contained in:
commit
7ed28ac286
@ -163,6 +163,11 @@ create_base_image() {
|
||||
sudo mkdir -p "${root_fs_dir}/usr/share/oem"
|
||||
sudo mount --bind "${oem_fs_dir}" "${root_fs_dir}/usr/share/oem"
|
||||
|
||||
# First thing first, install baselayout with USE=build to create a
|
||||
# working directory tree. Don't use binpkgs due to the use flag change.
|
||||
sudo -E USE=build ${EMERGE_BOARD_CMD} --root="${root_fs_dir}" \
|
||||
--usepkg=n --buildpkg=n --oneshot --quiet --nodeps sys-apps/baselayout
|
||||
|
||||
# We need to install libc manually from the cross toolchain.
|
||||
# TODO: Improve this? It would be ideal to use emerge to do this.
|
||||
PKGDIR="/var/lib/portage/pkgs"
|
||||
@ -181,6 +186,8 @@ create_base_image() {
|
||||
'usr/include' 'sys-include'
|
||||
# Link-time objects.
|
||||
'*.[ao]'
|
||||
# Empty lib dirs, replaced by symlinks
|
||||
'lib'
|
||||
)
|
||||
pbzip2 -dc --ignore-trailing-garbage=1 "${LIBC_PATH}" | \
|
||||
sudo tar xpf - -C "${root_fs_dir}" ./usr/${CHOST} \
|
||||
|
@ -83,15 +83,15 @@ $COREOS_VERSION_NAME release $COREOS_VERSION_STRING
|
||||
EOF
|
||||
|
||||
# Aaaannd for the new systemd world order
|
||||
# os-release provides a seperate build-id field, so split it from version
|
||||
# os-release provides a separate build-id field, so split it from version
|
||||
OS_ID=$(tr '[:upper:]' '[:lower:]' <<<"$COREOS_VERSION_NAME")
|
||||
OS_VERION_ID="${COREOS_VERSION_STRING#*+}"
|
||||
OS_BUILD_ID="${COREOS_VERSION_STRING%%+*}"
|
||||
OS_VERSION_ID="${COREOS_VERSION_STRING%%+*}"
|
||||
OS_BUILD_ID="${COREOS_VERSION_STRING#*+}"
|
||||
sudo_clobber "${ROOT_FS_DIR}/etc/os-release" <<EOF
|
||||
NAME=$COREOS_VERSION_NAME
|
||||
ID=$OS_ID
|
||||
VERSION=$COREOS_VERSION_STRING
|
||||
VERSION_ID=$OS_VERION_ID
|
||||
VERSION_ID=$OS_VERSION_ID
|
||||
BUILD_ID=$OS_BUILD_ID
|
||||
PRETTY_NAME="$COREOS_VERSION_NAME $COREOS_VERSION_DESCRIPTION"
|
||||
ANSI_COLOR="1;32"
|
||||
|
Loading…
x
Reference in New Issue
Block a user