diff options
| author | Maxim Cournoyer <maxim@guixotic.coop> | 2026-09-02 08:44:35 +0900 |
|---|---|---|
| committer | Maxim Cournoyer <maxim@guixotic.coop> | 2026-09-02 08:44:35 +0900 |
| commit | abbd7868a0982361179e9a6f6860a877edcd7a54 (patch) | |
| tree | 209536b25b7232008ecabfea996cf5df79341d54 /gnu/packages/patches | |
| parent | 631fd912f1a7bd85a30e7c5083579b1c949d2e8a (diff) | |
gnu: libfyaml: Fix build on 32bit architectures.gnome-team
* gnu/packages/patches/libfyaml-vlsize-32bit-fixes.patch: New file.
* gnu/packages/serialization.scm (libfyaml) [source]: Apply patch.
* gnu/local.mk (dist_patch_DATA): Register it.
Diffstat (limited to 'gnu/packages/patches')
| -rw-r--r-- | gnu/packages/patches/libfyaml-vlsize-32bit-fixes.patch | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/gnu/packages/patches/libfyaml-vlsize-32bit-fixes.patch b/gnu/packages/patches/libfyaml-vlsize-32bit-fixes.patch new file mode 100644 index 00000000000..90d388a74da --- /dev/null +++ b/gnu/packages/patches/libfyaml-vlsize-32bit-fixes.patch | |||
| @@ -0,0 +1,36 @@ | |||
| 1 | Combined diffs of commits https://github.com/pantoniou/libfyaml/commit/0982fcefc6a16d4c8cb5b06747d3fc8e630de3ae.diff and https://github.com/pantoniou/libfyaml/commit/9192deaac095f9881cc1e5756dede683f36b09d6.diff. | ||
| 2 | |||
| 3 | Upstream-status: <https://github.com/pantoniou/libfyaml/issues/328> | ||
| 4 | |||
| 5 | diff --git a/include/libfyaml/libfyaml-vlsize.h b/include/libfyaml/libfyaml-vlsize.h | ||
| 6 | index 6ccb7ab1..1b950c4c 100644 | ||
| 7 | --- a/include/libfyaml/libfyaml-vlsize.h | ||
| 8 | +++ b/include/libfyaml/libfyaml-vlsize.h | ||
| 9 | @@ -816,5 +816,5 @@ fy_decode_size_nocheck(const uint8_t *start, size_t *sizep) | ||
| 10 | static inline const uint8_t * | ||
| 11 | fy_skip_size(const uint8_t *start, size_t bufsz) | ||
| 12 | { | ||
| 13 | - return fy_skip_size32(start, bufsz, &sz); | ||
| 14 | + return fy_skip_size32(start, bufsz); | ||
| 15 | } | ||
| 16 | |||
| 17 | static inline const uint8_t * | ||
| 18 | |||
| 19 | diff --git a/include/libfyaml/libfyaml-vlsize.h b/include/libfyaml/libfyaml-vlsize.h | ||
| 20 | index 1b950c4c..acfd78d3 100644 | ||
| 21 | --- a/include/libfyaml/libfyaml-vlsize.h | ||
| 22 | +++ b/include/libfyaml/libfyaml-vlsize.h | ||
| 23 | @@ -810,5 +810,10 @@ fy_decode_size(const uint8_t *start, size_t bufsz, size_t *sizep) | ||
| 24 | static inline const uint8_t * | ||
| 25 | fy_decode_size_nocheck(const uint8_t *start, size_t *sizep) | ||
| 26 | { | ||
| 27 | - return fy_decode_size32_nocheck(start, sizep); | ||
| 28 | + uint64_t sz; | ||
| 29 | + const uint8_t *ret; | ||
| 30 | + | ||
| 31 | + ret = fy_decode_size32_nocheck(start, &sz); | ||
| 32 | + *sizep = (size_t)sz; | ||
| 33 | + return ret; | ||
| 34 | } | ||
| 35 | |||
| 36 | static inline const uint8_t * | ||
