From fcb2a614b6ccfafd46632755c68dc68bf1df676e Mon Sep 17 00:00:00 2001 From: Michael Marineau Date: Thu, 25 Jul 2013 23:15:01 -0400 Subject: [PATCH 1/3] fix(set_lsb_release): swap BUILD_ID and VERSION_ID This is what happens when you run off without finishing testing. --- build_library/set_lsb_release | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build_library/set_lsb_release b/build_library/set_lsb_release index 097e938832..9424a47fd0 100755 --- a/build_library/set_lsb_release +++ b/build_library/set_lsb_release @@ -85,8 +85,8 @@ EOF # Aaaannd for the new systemd world order # os-release provides a seperate 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_VERION_ID="${COREOS_VERSION_STRING%%+*}" +OS_BUILD_ID="${COREOS_VERSION_STRING#*+}" sudo_clobber "${ROOT_FS_DIR}/etc/os-release" < Date: Thu, 25 Jul 2013 23:03:04 -0400 Subject: [PATCH 2/3] fix(build_image): Fix baselayout install in final images. The basic system directory structure including the lib symlinks were fixed for sysroot in the following commits but the image build uses an entirely different bit of code to do the exact same set of hacks. Port those changes to the image building code to hopefully make all happy. 2ae0c30f4ec3eb57581494151e4fe7a035af342f ac931bd088781b226a16f1fffc768edaf0f1ab94 --- build_library/base_image_util.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/build_library/base_image_util.sh b/build_library/base_image_util.sh index e32858e501..997c0a8a64 100755 --- a/build_library/base_image_util.sh +++ b/build_library/base_image_util.sh @@ -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} \ From 2acc703cc8789b8a20aa6cd02b8556aedf577181 Mon Sep 17 00:00:00 2001 From: Michael Marineau Date: Fri, 26 Jul 2013 00:02:11 -0400 Subject: [PATCH 3/3] fix(set_lsb_release): Spelling is for suckers --- build_library/set_lsb_release | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/build_library/set_lsb_release b/build_library/set_lsb_release index 9424a47fd0..93bb9cc737 100755 --- a/build_library/set_lsb_release +++ b/build_library/set_lsb_release @@ -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_VERSION_ID="${COREOS_VERSION_STRING%%+*}" OS_BUILD_ID="${COREOS_VERSION_STRING#*+}" sudo_clobber "${ROOT_FS_DIR}/etc/os-release" <