From 342d9894f5730d7c37134cc14727fca1a9d1d99d Mon Sep 17 00:00:00 2001 From: r00t Date: Tue, 21 Jul 2015 15:06:28 -0400 Subject: [PATCH] FINALLY. testing cross-distro after many tweaks. also switched to github mirrors for the UEFI shells because sourceforge sucks. --- bin/build.sh | 14 +------------- extra/pre-build.d/etc/apacman.conf | 4 ++-- lib/01-mk.chroot.func.sh | 10 +++++++--- lib/08-will_it_blend.func.sh | 3 +++ lib/09-stuffy.func.sh | 4 ++-- lib/prereqs/Antergos/meta | 3 +++ lib/prereqs/Arch/meta | 3 +++ lib/prereqs/Mageia/meta | 2 +- lib/prereqs/Manjaro/meta | 3 +++ 9 files changed, 25 insertions(+), 21 deletions(-) diff --git a/bin/build.sh b/bin/build.sh index 099f621..decb71d 100755 --- a/bin/build.sh +++ b/bin/build.sh @@ -103,7 +103,7 @@ fi set -e USERNAME_REAL="$(grep ${BUILD_USERNAME} /etc/passwd | cut -f5 -d':')" -cat > VERSION_INFO.txt << EOF +cat > ${BASEDIR}/VERSION_INFO.txt << EOF Version: ${VERSION} Build: ${BUILD} Time: ${BUILDTIME} @@ -137,18 +137,6 @@ release_me 64 > /dev/null 2>&1 release_me 32 > /dev/null 2>&1 # do we need to perform any updates? -if [[ -f "${CHROOTDIR}root.x86_64/root/chroot" || -f "${CHROOTDIR}root.i686/root/chroot" ]]; -then - chroot_wrapper 64 - chroot_wrapper 32 - if [[ "${HOST_DIST}" == "CentOS" || "${HOST_DIST}" == "RHEL" ]]; - centos_is_stupid - fi - will_it_blend 64 - will_it_blend 32 - yo_dj -fi - if [[ ${1} == "update" ]]; then mentos diff --git a/extra/pre-build.d/etc/apacman.conf b/extra/pre-build.d/etc/apacman.conf index d0c9ca2..3723234 100644 --- a/extra/pre-build.d/etc/apacman.conf +++ b/extra/pre-build.d/etc/apacman.conf @@ -25,8 +25,8 @@ noedit=1 skipinteg=1 #skiptest=1 #warn=1 -tmpdir=/var/tmp/apacman -TMPDIR=/var/tmp/apacman +#tmpdir=/var/tmp/apacman +#TMPDIR=/var/tmp/apacman # # CONFIGURATION diff --git a/lib/01-mk.chroot.func.sh b/lib/01-mk.chroot.func.sh index 19920a4..091b420 100755 --- a/lib/01-mk.chroot.func.sh +++ b/lib/01-mk.chroot.func.sh @@ -109,10 +109,10 @@ function mkchroot { echo "Local: ${LOCSUM32}" echo "Remote: ${CKSUM32}" echo "Fetching fresh copy." - curl -o latest.32.tar.gz "${RLSDIR}/${CURRLS32}" >> "${LOGFILE}.${FUNCNAME}" 2>&1 + curl -o latest.32.tar.gz "${RLSDIR}/${CURRLS32}" fi else - curl -o latest.32.tar.gz "${RLSDIR}/${CURRLS32}" >> "${LOGFILE}.${FUNCNAME}" 2>&1 + curl -o latest.32.tar.gz "${RLSDIR}/${CURRLS32}" fi if [ ! -f "${CHROOTDIR32}/etc/pacman.d/gnupg/trustdb.gpg" ] || [ ! -f "${CHROOTDIR64}/etc/pacman.d/gnupg/trustdb.gpg" ]; @@ -147,6 +147,7 @@ HOME_URL="https://www.archlinux.org/" SUPPORT_URL="https://bbs.archlinux.org/" BUG_REPORT_URL="https://bugs.archlinux.org/" EOF + cp ${BASEDIR}/VERSION_INFO.txt ${BASEDIR}/root.${i}/. done # And make it usable. @@ -364,4 +365,7 @@ EOF } -mkchroot +if [[ ! -f "${BASEDIR}/root.x86_64/VERSION_INFO.txt" && ! -f "${BASEDIR}/root.x86_64/VERSION_INFO.txt" ]]; +then + mkchroot +fi diff --git a/lib/08-will_it_blend.func.sh b/lib/08-will_it_blend.func.sh index 97531a5..c4ae162 100644 --- a/lib/08-will_it_blend.func.sh +++ b/lib/08-will_it_blend.func.sh @@ -2,6 +2,9 @@ function will_it_blend () { FUNCNAME="will_it_blend" + SQUASH_CMD="mksquashfs" + SQUASH_OPTS="-noappend -comp xz" + local ARCHSUFFIX="${1}" if [[ "${1}" == "64" ]]; then diff --git a/lib/09-stuffy.func.sh b/lib/09-stuffy.func.sh index 2935707..5a5c900 100644 --- a/lib/09-stuffy.func.sh +++ b/lib/09-stuffy.func.sh @@ -23,12 +23,12 @@ function stuffy { if [ ! -f "${TEMPDIR}/EFI/shellx64_v2.efi" ]; then # EFI Shell 2.0 for UEFI 2.3+ ( http://sourceforge.net/apps/mediawiki/tianocore/index.php?title=UEFI_Shell ) - curl -o ${TEMPDIR}/EFI/shellx64_v2.efi https://svn.code.sf.net/p/edk2/code/trunk/edk2/ShellBinPkg/UefiShell/X64/Shell.efi >> "${LOGFILE}.${FUNCNAME}" 2>&1 + curl -o ${TEMPDIR}/EFI/shellx64_v2.efi "https://github.com/tianocore/edk2/blob/master/ShellBinPkg/UefiShell/X64/Shell.efi?raw=true" >> "${LOGFILE}.${FUNCNAME}" 2>&1 fi if [ ! -f "${TEMPDIR}/EFI/shellx64_v1.efi" ]; then # EFI Shell 1.0 for non UEFI 2.3+ ( http://sourceforge.net/apps/mediawiki/tianocore/index.php?title=Efi-shell ) - curl -o ${TEMPDIR}/EFI/shellx64_v1.efi https://svn.code.sf.net/p/edk2/code/trunk/edk2/EdkShellBinPkg/FullShell/X64/Shell_Full.efi >> "${LOGFILE}.${FUNCNAME}" 2>&1 + curl -o ${TEMPDIR}/EFI/shellx64_v1.efi "https://github.com/tianocore/edk2/blob/master/EdkShellBinPkg/FullShell/X64/Shell_Full.efi?raw=true" >> "${LOGFILE}.${FUNCNAME}" 2>&1 fi # now for setting up loader config/entries. maybe add memtest or something in the future? i dunno. diff --git a/lib/prereqs/Antergos/meta b/lib/prereqs/Antergos/meta index 8199262..1fca5c3 100644 --- a/lib/prereqs/Antergos/meta +++ b/lib/prereqs/Antergos/meta @@ -10,6 +10,9 @@ function distro_specific_tweaks { # For some reason, I can't get "yes y | " to parse correctly with eval. And Arch isn't smart enough # to figure out that if I enable the multilib repos, *I want multilib gcc*. Fuck it. We'll just remove it first. + pacman -S --needed haveged >> "${LOGFILE}.${FUNCNAME}" 2>&1 + haveged + set +e for pkg_override in gcc gcc-libs; do diff --git a/lib/prereqs/Arch/meta b/lib/prereqs/Arch/meta index 88230d1..1320802 100644 --- a/lib/prereqs/Arch/meta +++ b/lib/prereqs/Arch/meta @@ -10,6 +10,9 @@ function distro_specific_tweaks { # For some reason, I can't get "yes y | " to parse correctly with eval. And Arch isn't smart enough # to figure out that if I enable the multilib repos, *I want multilib gcc*. Fuck it. We'll just remove it first. + pacman -S --needed haveged >> "${LOGFILE}.${FUNCNAME}" 2>&1 + haveged + set +e for pkg_override in gcc gcc-libs; do diff --git a/lib/prereqs/Mageia/meta b/lib/prereqs/Mageia/meta index 56dd871..4f62a30 100644 --- a/lib/prereqs/Mageia/meta +++ b/lib/prereqs/Mageia/meta @@ -1,7 +1,7 @@ NAME='Mageia' SUPPORTED='yes' CHECK_METHOD='egrep "^Mageia\ release\ " /etc/mageia-release' -PKG_MGR='urpmi --force ${pkgname}' +PKG_MGR='urpmi --force --auto ${pkgname}' PRE_RUN='urpmi.update -a' PKG_CHK='rpm -q ${pkgname} | egrep "^${pkgname}-[0-9]"' URL='https://www.mageia.org/' diff --git a/lib/prereqs/Manjaro/meta b/lib/prereqs/Manjaro/meta index 57df8b6..647493c 100644 --- a/lib/prereqs/Manjaro/meta +++ b/lib/prereqs/Manjaro/meta @@ -10,6 +10,9 @@ function distro_specific_tweaks { # For some reason, I can't get "yes y | " to parse correctly with eval. And Arch isn't smart enough # to figure out that if I enable the multilib repos, *I want multilib gcc*. Fuck it. We'll just remove it first. + pacman -S --needed haveged >> "${LOGFILE}.${FUNCNAME}" 2>&1 + haveged + set +e for pkg_override in gcc gcc-libs; do