• Bug#1109714: [PATCH] fix for review

    From Hector Oron@21:1/5 to All on Wed Jul 23 19:50:01 2025
    Hello,

    El mié, 23 jul 2025 a las 19:09, tshah (<[email protected]>) escribió:

    Tried reproducing the issue of ciborium build failure on ppc64el. On checking the logs minutely, got to know that the issue is in one of the source file cdata.go. There is a function declared with no definition: func Addrs() (uintptr, uintptr).

    This patch fixes a build failure of the Ciborium package on the ppc64el architecture. The qml.v1/cdata/cdata.go file defines the Addrs() function, which appears to rely on architecture-specific logic that is not supported on ppc64el. Attempting to
    compile on ppc64el results in an error due to this missing implementation.

    To resolve this, I have:

    Added a Go build tag to cdata.go to exclude it from ppc64el builds.

    Created a new file cdata_stub.go, which is only built on ppc64el, and provides a stub Addrs() function returning default zero values.

    This allows the package to compile successfully on ppc64el, while retaining the original behavior for other platforms.

    The stub ensures compatibility without introducing functional changes or affecting other architectures. I have attached the patch in this mail.


    Could you please consider bringing this upstream at https://gitlab.com/ubports/development/core/ciborium/-/issues if not
    done already?

    Thanks for your work on this.

    Regards
    --
    Héctor Orón -.. . -... .. .- -. -.. . ...- . .-.. --- .--. . .-.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Mike Gabriel@21:1/5 to tshah on Wed Jul 23 21:50:01 2025
    This message is in MIME format and has been PGP signed.

    Hi,

    On Mi 23 Jul 2025 19:08:30 CEST, tshah wrote:

    Tried reproducing the issue of ciborium build failure on ppc64el. On checking the logs minutely, got to know that the issue is in one of
    the source file /cdata.go/. There is a function declared with no definition: f/unc Addrs() (uintptr, uintptr)./

    This patch fixes a build failure of the Ciborium package on the
    ppc64el architecture. The /qml.v1/cdata/cdata.go/  file defines the /Addrs() /function, which appears to rely on architecture-specific
    logic that is not supported on ppc64el. Attempting to compile on
    ppc64el results in an error due to this missing implementation.

    To resolve this, I have:

    *

    Added a Go build tag to |cdata.go| to exclude it from |ppc64el| builds.

    *

    Created a new file |cdata_stub.go|, which is only built on
    |ppc64el|, and provides a stub |Addrs()| function returning default
    zero values.

    This allows the package to compile successfully on |ppc64el|, while retaining the original behavior for other platforms.

    The stub ensures compatibility without introducing functional
    changes or affecting other architectures. I have attached the patch
    in this mail.

    Maybe your patch needs to be extended for other architectures, too? It
    seems most of them suffer the same issue.

    I have asked Guido, the upstream author to chime in on this...

    Mike
    --

    mike gabriel aka sunweaver (Debian Developer)
    mobile: +49 (1520) 1976 148
    landline: +49 (4351) 486 14 27

    GnuPG Fingerprint: 9BFB AEE8 6C0A A5FF BF22 0782 9AF4 6B30 2577 1B31
    mail: [email protected], http://sunweavers.net


    -----BEGIN PGP SIGNATURE-----
    Version: GnuPG v2

    iQIzBAABCgAdFiEEm/uu6GwKpf+/IgeCmvRrMCV3GzEFAmiBOrkACgkQmvRrMCV3 GzEboA/+N4JYInsBrXLUeFcLPrqdlHvqI4fO80mudp+pq7o1abLrQzYWA/jKIlK3 CjA4OtYweS5Y5a4b/u64O6ExIdaqgfYp+whMdLH27o20jdFFcw85N8H5kBUr/xuR +AebwqOf7Gjz0iOJ43TXeQtKboPTTpvmgDCIASoD1Y/VJZlSMY2kAAXFoGsM81T3 4SSIA6+uLhW/j391RxZZKCUtqJWnn1HrRmTzRRZQ6KE0O55Jg7WFNrKaHFvPS/n/ 2S8EIaqjhI54CMLY3V7rSMmpMdKP6sO21wN+9nPBKzNajhJsuweG/FNPchyT7Xfb zJPSIvSFkyzAg6GeEHmznkF0rxn61+Hxk8HBaQ4fRA9X4l2KRmLnUeD3GMl73t46 J5TXsLuWmvCIpnVWr6FW+O0NftPbnqT3g25ZoQMnISSvAeVBfAu7Gj7GxsGA+7Mp 4HQd+K5esLTcAaR+9NF3i0J+89AqSUcLJXgBooZVzJXFFq+nQXzmBnyiP7Y/XoTs t/nKN1KhaAiNS4u2BWGrSss9xVFebfbo0NDcRO1NQ0nU15Cf/oFKj0kCMvQuoFL8 shLq1a5FIzfJxmgwaR55PeKaRGA0B3MLAK0pQ/1/E1FZOJ2xzP+YSoWpC4AzSUjX
    04P
  • From Guido Berhoerster@21:1/5 to [email protected] on Thu Jul 24 09:30:01 2025
    On Wed, 23 Jul 2025 19:40:43 +0000 Mike Gabriel <[email protected]> wrote:
    On Mi 23 Jul 2025 19:08:30 CEST, tshah wrote:

    Tried reproducing the issue of ciborium build failure on ppc64el. On checking the logs minutely, got to know that the issue is in one of
    the source file /cdata.go/. There is a function declared with no definition: f/unc Addrs() (uintptr, uintptr)./

    This patch fixes a build failure of the Ciborium package on the
    ppc64el architecture. The /qml.v1/cdata/cdata.go/  file defines the /Addrs() /function, which appears to rely on architecture-specific
    logic that is not supported on ppc64el. Attempting to compile on
    ppc64el results in an error due to this missing implementation.

    To resolve this, I have:

    *

    Added a Go build tag to |cdata.go| to exclude it from |ppc64el| builds.

    *

    Created a new file |cdata_stub.go|, which is only built on
    |ppc64el|, and provides a stub |Addrs()| function returning default
    zero values.

    This allows the package to compile successfully on |ppc64el|, while retaining the original behavior for other platforms.

    The stub ensures compatibility without introducing functional
    changes or affecting other architectures. I have attached the patch
    in this mail.

    Maybe your patch needs to be extended for other architectures, too? It
    seems most of them suffer the same issue.

    The patch is actually not necessary. The original go-qml-Project
    required architecture-specific hacks to obtain pointers to the
    runtime- and go-main functions for its tests. However, the tests
    have long been removed from the bundled go-qml and the method of
    obtaining the pointers would not work with any newer Go versions
    anyway so the correct fix is to just remove this code. I've done
    this upstream now: https://gitlab.com/ubports/development/core/ciborium/-/merge_requests/20

    --
    Guido Berhoerster

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)