Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] xbps-src: add back support for 32bit dependencies
@ 2019-09-29 17:18 voidlinux-github
  2019-09-29 17:19 ` [PR PATCH] [Updated] " voidlinux-github
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: voidlinux-github @ 2019-09-29 17:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 606 bytes --]

There is a new pull request by Duncaen against master on the void-packages repository

https://github.com/Duncaen/void-packages 32bit
https://github.com/void-linux/void-packages/pull/14822

xbps-src: add back support for 32bit dependencies
This will use xbps-query to see if packages that don't have a template file already exist and allows building packages like `gcc-multilib` again.
If the package doesn't exist already it will just error out, because `xbps-src` can't switch to a 32bit masterdir to build it. 

A patch file from https://github.com/void-linux/void-packages/pull/14822.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-32bit-14822.patch --]
[-- Type: text/x-diff, Size: 5833 bytes --]

From 8e4092178b3fb5fcce4d5e65a22694445c64c120 Mon Sep 17 00:00:00 2001
From: Duncaen <duncaen@voidlinux.org>
Date: Sun, 29 Sep 2019 19:15:44 +0200
Subject: [PATCH] xbps-src: add back support for 32bit dependencies

---
 common/xbps-src/shutils/build_dependencies.sh | 59 +++++++++++++++----
 1 file changed, 47 insertions(+), 12 deletions(-)

diff --git a/common/xbps-src/shutils/build_dependencies.sh b/common/xbps-src/shutils/build_dependencies.sh
index 6d9d727e0d3..f2bc9288487 100644
--- a/common/xbps-src/shutils/build_dependencies.sh
+++ b/common/xbps-src/shutils/build_dependencies.sh
@@ -145,11 +145,20 @@ install_pkg_deps() {
     # Host build dependencies.
     #
     if [[ ${hostmakedepends} ]]; then
+        local _hostmakedepends=""
         # check validity
         for f in ${hostmakedepends}; do
-            if [ ! -f $XBPS_SRCPKGDIR/$f/template ]; then
-                msg_error "$pkgver: host dependency '$f' does not exist!\n"
+            if [ -f $XBPS_SRCPKGDIR/$f/template ]; then
+                _hostmakedepends+=" $f"
+                continue
+            fi
+            local _repourl=$($XBPS_QUERY_CMD -R -prepository "$f" 2>/dev/null)
+            if [ "$_repourl" ]; then
+                echo "   [host] ${f}: found (${_repourl})"
+                host_binpkg_deps+=("$f")
+                continue
             fi
+            msg_error "$pkgver: host dependency '$f' does not exist!\n"
         done
         while read -r _depname _deprepover _depver _subpkg _repourl; do
             _vpkg=${_subpkg}-${_depver}
@@ -179,18 +188,27 @@ install_pkg_deps() {
                 echo "   [host] ${_vpkg}: not found"
                 host_missing_deps+=("$_vpkg")
             fi
-        done < <($XBPS_CHECKVERS_CMD ${XBPS_SKIP_REMOTEREPOS:+-i} -D $XBPS_DISTDIR -sm ${hostmakedepends})
+        done < <($XBPS_CHECKVERS_CMD ${XBPS_SKIP_REMOTEREPOS:+-i} -D $XBPS_DISTDIR -sm $_hostmakedepends)
     fi
 
     #
     # Host check dependencies.
     #
     if [[ ${checkdepends} ]] && [[ $XBPS_CHECK_PKGS ]]; then
+        local _checkdepends=""
         # check validity
         for f in ${checkdepends}; do
-            if [ ! -f $XBPS_SRCPKGDIR/$f/template ]; then
-                msg_error "$pkgver: check dependency '$f' does not exist!\n"
+            if [ -f $XBPS_SRCPKGDIR/$f/template ]; then
+                _hostmakedepends+=" $f"
+                continue
+            fi
+            local _repourl=$($XBPS_QUERY_CMD -R -prepository "$f" 2>/dev/null)
+            if [ "$_repourl" ]; then
+                echo "   [host] ${f}: found (${_repourl})"
+                host_binpkg_deps+=("$f")
+                continue
             fi
+            msg_error "$pkgver: check dependency '$f' does not exist!\n"
         done
         while read -r _depname _deprepover _depver _subpkg _repourl; do
             _vpkg=${_subpkg}-${_depver}
@@ -220,18 +238,27 @@ install_pkg_deps() {
                 echo "   [check] ${_vpkg}: not found"
                 host_missing_deps+=("$_vpkg")
             fi
-        done < <($XBPS_CHECKVERS_CMD ${XBPS_SKIP_REMOTEREPOS:+-i} -D $XBPS_DISTDIR -sm ${checkdepends})
+        done < <($XBPS_CHECKVERS_CMD ${XBPS_SKIP_REMOTEREPOS:+-i} -D $XBPS_DISTDIR -sm ${_checkdepends})
     fi
 
     #
     # Target build dependencies.
     #
     if [[ ${makedepends} ]]; then
+        local _makedepends=""
         # check validity
         for f in ${makedepends}; do
-            if [ ! -f $XBPS_SRCPKGDIR/$f/template ]; then
-                msg_error "$pkgver: target dependency '$f' does not exist!\n"
+            if [ -f $XBPS_SRCPKGDIR/$f/template ]; then
+                _makedepends+=" $f"
+                continue;
             fi
+            local _repourl=$($XBPS_QUERY_CMD -R -prepository "$f" 2>/dev/null)
+            if [ "$_repourl" ]; then
+                echo "   [target] ${f}: found (${_repourl})"
+                binpkg_deps+=("$f")
+                continue
+            fi
+            msg_error "$pkgver: target dependency '$f' does not exist!\n"
         done
         while read -r _depname _deprepover _depver _subpkg _repourl; do
             _vpkg=${_subpkg}-${_depver}
@@ -261,18 +288,26 @@ install_pkg_deps() {
                 echo "   [target] ${_vpkg}: not found"
                 missing_deps+=("$_vpkg")
             fi
-        done < <($XBPS_CHECKVERS_XCMD ${XBPS_SKIP_REMOTEREPOS:+-i} -D $XBPS_DISTDIR -sm ${makedepends})
+        done < <($XBPS_CHECKVERS_XCMD ${XBPS_SKIP_REMOTEREPOS:+-i} -D $XBPS_DISTDIR -sm ${_makedepends})
     fi
 
     #
     # Target run time dependencies
     #
     if [[ ${depends} ]]; then
+        local __deps=""
         _deps=$(setup_pkg_depends "" 1) || exit 1
         for f in ${_deps}; do
-            if [ ! -f $XBPS_SRCPKGDIR/$f/template ]; then
-                msg_error "$pkgver: runtime dependency '$f' does not exist!\n"
+            if [ -f $XBPS_SRCPKGDIR/$f/template ]; then
+                _hostmakedepends+=" $f"
+                continue
+            fi
+            local _repourl=$($XBPS_QUERY_CMD -R -prepository "$f" 2>/dev/null)
+            if [ "$_repourl" ]; then
+                echo "   [target] ${f}: found (${_repourl})"
+                continue
             fi
+            msg_error "$pkgver: target dependency '$f' does not exist!\n"
         done
         while read -r _depname _deprepover _depver _subpkg _repourl; do
             _vpkg=${_subpkg}-${_depver}
@@ -301,7 +336,7 @@ install_pkg_deps() {
                 echo "   [runtime] ${_vpkg}: not found"
                 missing_rdeps+=("$_vpkg")
             fi
-        done < <($XBPS_CHECKVERS_XCMD ${XBPS_SKIP_REMOTEREPOS:+-i} -D $XBPS_DISTDIR -sm $_deps)
+        done < <($XBPS_CHECKVERS_XCMD ${XBPS_SKIP_REMOTEREPOS:+-i} -D $XBPS_DISTDIR -sm $__deps)
         unset _deps
     fi
 

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2019-10-21 16:37 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-29 17:18 [PR PATCH] xbps-src: add back support for 32bit dependencies voidlinux-github
2019-09-29 17:19 ` [PR PATCH] [Updated] " voidlinux-github
2019-09-29 17:19 ` voidlinux-github
2019-09-29 18:20 ` voidlinux-github
2019-09-29 18:20 ` voidlinux-github
2019-09-29 18:22 ` voidlinux-github
2019-09-29 18:22 ` voidlinux-github
2019-10-21 16:03 ` voidlinux-github
2019-10-21 16:03 ` voidlinux-github
2019-10-21 16:04 ` voidlinux-github
2019-10-21 16:04 ` voidlinux-github
2019-10-21 16:37 ` [PR PATCH] [Merged]: " voidlinux-github

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).