From b50aa11e7d6c864fddb7504d903793d9f744af16 Mon Sep 17 00:00:00 2001 From: MilhouseVH Date: Sat, 6 Jul 2019 00:14:40 +0100 Subject: [PATCH 1/6] libdrm: update to libdrm-2.4.99 --- packages/graphics/libdrm/package.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/graphics/libdrm/package.mk b/packages/graphics/libdrm/package.mk index b8d9be5f28..19c7d02369 100644 --- a/packages/graphics/libdrm/package.mk +++ b/packages/graphics/libdrm/package.mk @@ -4,8 +4,8 @@ # Copyright (C) 2018-present Team LibreELEC (https://libreelec.tv) PKG_NAME="libdrm" -PKG_VERSION="2.4.98" -PKG_SHA256="8be0edccaca3abde8b6bb1431b46354c7fab46e9b91cc6946ba65b51f56f1894" +PKG_VERSION="2.4.99" +PKG_SHA256="4dbf539c7ed25dbb2055090b77ab87508fc46be39a9379d15fed4b5517e1da5e" PKG_LICENSE="GPL" PKG_SITE="http://dri.freedesktop.org" PKG_URL="http://dri.freedesktop.org/libdrm/$PKG_NAME-$PKG_VERSION.tar.bz2" From 3e1563cb68286e337cbc350bb52090ed72e7402a Mon Sep 17 00:00:00 2001 From: MilhouseVH Date: Tue, 2 Jul 2019 16:28:25 +0100 Subject: [PATCH 2/6] init: clean up splash image selection --- packages/sysutils/busybox/scripts/init | 24 ++++++++++-------------- 1 file changed, 10 insertions(+), 14 deletions(-) diff --git a/packages/sysutils/busybox/scripts/init b/packages/sysutils/busybox/scripts/init index c0e3340f88..7636b91322 100755 --- a/packages/sysutils/busybox/scripts/init +++ b/packages/sysutils/busybox/scripts/init @@ -409,21 +409,17 @@ load_splash() { if [ -z "$SPLASHIMAGE" ]; then vres="$(fbset 2>/dev/null | awk '/geometry/ { print $3 }')" - if [ -f /flash/oemsplash.png -o -f /flash/oemsplash-1080.png ]; then - if [ -n "$vres" -a -f /flash/oemsplash-$vres.png ]; then - SPLASHIMAGE="/flash/oemsplash-$vres.png" - elif [ -f /flash/oemsplash-1080.png ]; then - SPLASHIMAGE="/flash/oemsplash-1080.png" - else - SPLASHIMAGE="/flash/oemsplash.png" + for s in /flash/oemsplash-${vres}.png \ + /flash/oemsplash-1080.png \ + /flash/oemsplash.png \ + /splash/splash-${vres}.png \ + /splash/splash-1080.png \ + ; do + if [ -f "${s}" ]; then + SPLASHIMAGE="${s}" + break fi - else - if [ -n "$vres" -a -f /splash/splash-$vres.png ]; then - SPLASHIMAGE="/splash/splash-$vres.png" - else - SPLASHIMAGE="/splash/splash-1080.png" - fi - fi + done fi if [ -n "$SPLASHIMAGE" -a -f "$SPLASHIMAGE" ]; then From ff813fca35fdf69eaa1f35489ec52767c8dce674 Mon Sep 17 00:00:00 2001 From: MilhouseVH Date: Fri, 5 Jul 2019 13:50:35 +0100 Subject: [PATCH 3/6] libva: update to libva-2.5.0 --- packages/multimedia/libva/package.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/multimedia/libva/package.mk b/packages/multimedia/libva/package.mk index 9eb697fa86..fe6cd9991a 100644 --- a/packages/multimedia/libva/package.mk +++ b/packages/multimedia/libva/package.mk @@ -3,8 +3,8 @@ # Copyright (C) 2018-present Team LibreELEC (https://libreelec.tv) PKG_NAME="libva" -PKG_VERSION="2.4.1" -PKG_SHA256="68ca8d071dcb84ac82e3c6d7f02a55937d9f690fcb215853f4aa1de8d459812f" +PKG_VERSION="2.5.0" +PKG_SHA256="9b6264dade6b6d3edb59c6c4f3c9217d1d5a195635fc07da875d565f58624418" PKG_ARCH="x86_64" PKG_LICENSE="GPL" PKG_SITE="https://01.org/linuxmedia" From e89045361a4ee41531e47bd2100a3b6f0d23b8e4 Mon Sep 17 00:00:00 2001 From: MilhouseVH Date: Tue, 9 Jul 2019 10:52:49 +0100 Subject: [PATCH 4/6] mesa: update to mesa-19.1.2 --- packages/graphics/mesa/package.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/graphics/mesa/package.mk b/packages/graphics/mesa/package.mk index e1905a9abc..46a948fdfe 100644 --- a/packages/graphics/mesa/package.mk +++ b/packages/graphics/mesa/package.mk @@ -3,8 +3,8 @@ # Copyright (C) 2018-present Team LibreELEC (https://libreelec.tv) PKG_NAME="mesa" -PKG_VERSION="19.1.1" -PKG_SHA256="25793eef8b132732273176015b53d2842a905960e1841c6aca292c6930100edf" +PKG_VERSION="19.1.2" +PKG_SHA256="08d424da157cd8d00c38584a193aab96873be43d617d1cd78b5b8d33cbcb4ef8" PKG_LICENSE="OSS" PKG_SITE="http://www.mesa3d.org/" PKG_URL="https://github.com/mesa3d/mesa/archive/mesa-$PKG_VERSION.tar.gz" From f1614bbac7cad38cb166a567db943669c50d3128 Mon Sep 17 00:00:00 2001 From: MilhouseVH Date: Tue, 9 Jul 2019 18:51:38 +0100 Subject: [PATCH 5/6] xf86-video-nvidia: update to xf86-video-nvidia-430.34 --- packages/x11/driver/xf86-video-nvidia/package.mk | 4 ++-- .../x11/driver/xf86-video-nvidia/udev.d/96-nvidia.rules | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/packages/x11/driver/xf86-video-nvidia/package.mk b/packages/x11/driver/xf86-video-nvidia/package.mk index 6705b14cfd..035943210d 100644 --- a/packages/x11/driver/xf86-video-nvidia/package.mk +++ b/packages/x11/driver/xf86-video-nvidia/package.mk @@ -6,8 +6,8 @@ PKG_NAME="xf86-video-nvidia" # Remember to run "python packages/x11/driver/xf86-video-nvidia/scripts/make_nvidia_udev.py" and commit changes to # "packages/x11/driver/xf86-video-nvidia/udev.d/96-nvidia.rules" whenever bumping version. # Host may require installation of python-lxml and python-requests packages. -PKG_VERSION="430.26" -PKG_SHA256="a7dfb1bdd7591f42bbe501b8a9a80349415bdb51723db3cd11b08ce2e2d4679c" +PKG_VERSION="430.34" +PKG_SHA256="248ed9d3dee62eba86d0e0c7737218666aae204a0c0bb9c557b114db75edc523" PKG_ARCH="x86_64" PKG_LICENSE="nonfree" PKG_SITE="http://www.nvidia.com/" diff --git a/packages/x11/driver/xf86-video-nvidia/udev.d/96-nvidia.rules b/packages/x11/driver/xf86-video-nvidia/udev.d/96-nvidia.rules index 7ac42c7f3d..3a2781071a 100644 --- a/packages/x11/driver/xf86-video-nvidia/udev.d/96-nvidia.rules +++ b/packages/x11/driver/xf86-video-nvidia/udev.d/96-nvidia.rules @@ -232,6 +232,7 @@ ATTRS{device}=="0x1e04", GOTO="configure_nvidia" ATTRS{device}=="0x1e07", GOTO="configure_nvidia" ATTRS{device}=="0x1e30", GOTO="configure_nvidia" ATTRS{device}=="0x1e82", GOTO="configure_nvidia" +ATTRS{device}=="0x1e84", GOTO="configure_nvidia" ATTRS{device}=="0x1e87", GOTO="configure_nvidia" ATTRS{device}=="0x1e90", GOTO="configure_nvidia" ATTRS{device}=="0x1eb0", GOTO="configure_nvidia" @@ -239,13 +240,18 @@ ATTRS{device}=="0x1eb1", GOTO="configure_nvidia" ATTRS{device}=="0x1eb5", GOTO="configure_nvidia" ATTRS{device}=="0x1eb6", GOTO="configure_nvidia" ATTRS{device}=="0x1eb8", GOTO="configure_nvidia" +ATTRS{device}=="0x1ec2", GOTO="configure_nvidia" +ATTRS{device}=="0x1ec7", GOTO="configure_nvidia" ATTRS{device}=="0x1ed0", GOTO="configure_nvidia" ATTRS{device}=="0x1f02", GOTO="configure_nvidia" +ATTRS{device}=="0x1f06", GOTO="configure_nvidia" ATTRS{device}=="0x1f07", GOTO="configure_nvidia" ATTRS{device}=="0x1f08", GOTO="configure_nvidia" ATTRS{device}=="0x1f10", GOTO="configure_nvidia" ATTRS{device}=="0x1f11", GOTO="configure_nvidia" ATTRS{device}=="0x1f36", GOTO="configure_nvidia" +ATTRS{device}=="0x1f42", GOTO="configure_nvidia" +ATTRS{device}=="0x1f47", GOTO="configure_nvidia" ATTRS{device}=="0x1f50", GOTO="configure_nvidia" ATTRS{device}=="0x1f51", GOTO="configure_nvidia" ATTRS{device}=="0x1f82", GOTO="configure_nvidia" From d93bd49a02e7ea1d60e58fc0d95039240fb97620 Mon Sep 17 00:00:00 2001 From: MilhouseVH Date: Sat, 6 Jul 2019 01:07:20 +0100 Subject: [PATCH 6/6] distro-tool: halve the time required to generate workload --- tools/distro-tool | 84 +++++++++++++++++++++++++---------------------- 1 file changed, 44 insertions(+), 40 deletions(-) diff --git a/tools/distro-tool b/tools/distro-tool index 71b3b1473c..f763cd1328 100755 --- a/tools/distro-tool +++ b/tools/distro-tool @@ -702,7 +702,7 @@ help() { Usage: $(basename $0) -d|--download [-t|--target ] [-l|--libreelec ] [-m|--mirror] [-s|--source] [-a|-all] [-p|--package [-r|--revision ]] [--git] [-n|--notnewer] [--check-main | --check-addons] [--check-ver | --check-rev] - [--noprogress] [-T #|--threads #] [-U|--gituser] [-P|--gitpass] [--dry-run] + [--no-progress] [-T #|--threads #] [-U|--gituser] [-P|--gitpass] [--dry-run] [--path-filter path] [--verify-checksum] [-v|--verbose] [-h|--help] Options: @@ -720,8 +720,8 @@ Options: --check-addons: Check newer for add-on packages, ignore main packages --check-ver: Check newer for version-based packages, ignore rev-based/github packages --check-rev: Check newer for rev-based/github packages, ignore version-based packages - --noprogress: Do not show progress indicator - -T, --threads: Number of worker threads, default is 32 + --no-progress: Do not show progress indicator + -T, --threads: Number of download worker threads, default is 16 -U, --gituser: Git username (or source from ~/.git.conf) - avoids API limits -P, --gitpass: Git password (or source from ~/.git.conf) - avoids API limits --dry-run: Don't actually download anything (will still git clone/pull if configured) @@ -754,7 +754,7 @@ generate_work() { local workfile_o local tcount=0 - [ ${PROGRESS} == yes ] && echo -en "Acquiring packages...\r" >&2 + [ ${PROGRESS} = yes ] && echo -en "Acquiring packages...\r" >&2 packages="$(get_packages "${package_name}" "${path_filter}")" pcount="$(echo "${packages}" | wc -l)" @@ -770,7 +770,7 @@ generate_work() { rm -f ${WORKFILES_I}.* ${WORKFILES_O}.* - # Split packages across workers + # Distribute packages across workers tcount=0 for package_name in ${packages}; do tcount=$((tcount + 1)) @@ -778,21 +778,17 @@ generate_work() { echo "$package_name" >>$(printf "%s.%02d" "${WORKFILES_I}" ${tcount}) done - # Generate workload using multiple threads + # Generate workload using multiple "threads" (cores, hopefully...) init_progress - ( - cd $LIBREELEC_DIR - source config/options "" + tcount=0 - tcount=0 - while [ : ]; do - tcount=$((tcount + 1)) - [ ${tcount} -gt ${WORKER_MAX} ] && break - generate_work_worker ${pcount} ${tcount} ${revision} & - done - wait - ) + while [ : ]; do + tcount=$((tcount + 1)) + [ ${tcount} -gt ${WORKER_MAX} ] && break + generate_work_worker ${pcount} ${tcount} ${revision} & + done + wait end_progress @@ -823,7 +819,6 @@ generate_work_worker() { local package_name var comma PKG_URL PKG_SOURCE_NAME PKG_VERSION PKG_IS_ADDON [ -f "${workfile_i}" ] || return 0 - ( # Override exit function so that packages calling exit don't terminate this sub-shell exit() { @@ -832,10 +827,12 @@ generate_work_worker() { cd $LIBREELEC_DIR - while read -r package_name; do - [ ${PROGRESS} == yes ] && progress ${pcount} + source config/options "" - source config/options ${package_name} &>/dev/null || true + while read -r package_name; do + [ ${PROGRESS} = yes ] && progress ${pcount} + + source_package ${package_name} &>/dev/null || true [ -z "${PKG_DIR}" ] && continue if [ -n "${revision}" ]; then @@ -881,24 +878,31 @@ get_package_path() { get_packages() { local package_name="$1" path_filter="$2" + local anchor="@?+?@" - export -f get_package_path + ( + cd $LIBREELEC_DIR - cd $LIBREELEC_DIR + # Generate package caches... + source config/options "" - if [ -n "${path_filter}" ]; then - if [ -n "${package_name}" ]; then - basename $(dirname $(find ${path_filter} -path "*/${package_name}/*" -name package.mk 2>/dev/null) 2>/dev/null | head -1) 2>/dev/null + cache_data="${BUILD}/.cache_package_global ${BUILD}/.cache_package_local" + + if [ -n "${path_filter}" ]; then + if [ -n "${package_name}" ]; then + grep -F "/${path_filter}/" ${cache_data} | grep -F "/${package_name}${anchor}" + else + grep -F "/${path_filter}/" ${cache_data} + fi else - find ${path_filter} -name package.mk -exec bash -c get_package_path "{}" \; 2>/dev/null | cut -d' ' -f1 | sort -u + if [ -n "${package_name}" ]; then + grep -F "/${package_name}${anchor}" ${cache_data} + else + cat ${cache_data} + fi fi - else - if [ -n "${package_name}" ]; then - basename $(dirname $(find packages projects/${PROJECT} -path "*/${package_name}/*" -name package.mk 2>/dev/null) 2>/dev/null | head -1) 2>/dev/null - else - find packages projects/${PROJECT} -name package.mk -exec bash -c get_package_path "{}" \; 2>/dev/null | cut -d' ' -f1 | sort -u - fi - fi + ) | sed "s#${anchor}\$##g;s#/# #g" | awk '{print $NF}' | sort -u + return 0 } @@ -910,7 +914,7 @@ progress() { local count ( flock -x 9 - count=$(($(cat ${LOCKFILE}) + 1)) + count=$(($(< ${LOCKFILE}) + 1)) echo "${count}" >${LOCKFILE} printf "Generating workload... %3d%% (%d of %d)\r" $((count * 100 / $1)) ${count} $1 >&2 ) 9< "${LOCKFILE}" @@ -999,7 +1003,7 @@ while [ : ]; do -v|--verbose) VERBOSE=$((VERBOSE + 1)) ;; - --noprogress) + --no-progress) PROGRESS=no ;; --path-filter) @@ -1023,7 +1027,7 @@ done [ -n "${PACKAGE}" -a ${VERBOSE} -eq 0 ] && VERBOSE=1 -if [ ${DOGIT} == yes ]; then +if [ ${DOGIT} = yes ]; then ( if [ -d ${LIBREELEC_DIR}/.git ]; then cd ${LIBREELEC_DIR} @@ -1043,14 +1047,14 @@ DISTRO_SOURCE="$(get_libreelec_option DISTRO_SRC)" DISTRO_MIRROR="$(get_libreelec_option DISTRO_MIRROR)" LIBREELEC_VER="$(get_libreelec_option LIBREELEC_VERSION)" -if [ ${IS_MIRROR} == no ]; then +if [ ${IS_MIRROR} = no ]; then TARGET_DIR="$(get_abs_path "${TARGET_DIR}/${LIBREELEC_VER}")" else TARGET_DIR="$(get_abs_path "${TARGET_DIR}/mirror")" fi check_exists TARGET_DIR || exit -if [ ${IS_MIRROR} == no ]; then +if [ ${IS_MIRROR} = no ]; then DOWNLOAD_DIR="$(get_abs_path "${DOWNLOAD_DIR}/${LIBREELEC_VER}")" else DOWNLOAD_DIR="$(get_abs_path "${DOWNLOAD_DIR}/mirror")" @@ -1063,7 +1067,7 @@ if [ -n "${REVISION}" -a -z "${PACKAGE}" ]; then fi echo -if [ ${IS_MIRROR} == yes ]; then +if [ ${IS_MIRROR} = yes ]; then echo "Synchronising LibreELEC.tv (branch: $(get_libreelec_branch), version: ${LIBREELEC_VER}) with MIRROR server ${TARGET_DIR}" else echo "Synchronising LibreELEC.tv (branch: $(get_libreelec_branch), version: ${LIBREELEC_VER}) with SOURCE server ${TARGET_DIR}"