Luma is now available in alpha.Luma is in alpha.What does that mean?
Skip to content
luma.Download Luma
This report lives on GitHub. You are reading it in Luma’s tracker. To add to it, reply there.Open on GitHub

GitHub #9 `patches/libhandy/0005-luma-one-title-row-per-window.patch` is rejected as malformed by GNU patch 2.8 and `git apply`

melikootjeon GitHub · 11 days ago

Summary

On a stock Fedora 44 libhandy-1.8.3-10.fc44 source, patches 0001 to 0004 apply cleanly in order, but
0005-luma-one-title-row-per-window.patch fails with:

patch: **** malformed patch at line 276:    context = gtk_widget_get_style_context (GTK_WIDGET (self->window));

git apply --check reports corrupt patch at ...:277. As a result scripts/packages/build-libhandy.sh stops in %prep.

Cause (as far as I can tell)

The last hunk header is @@ -566,8 +567,19 @@ hdy_window_mixin_new (...), in src/hdy-window-mixin.c. The hunk body has
8 old-side lines (matches the header) but 20 new-side lines (7 context + 13 +), not 19. The hunk is the last
one in the file, so the tools stop reading after 19 new lines and reject the final context line.

Whether the intended header is +567,20 or whether one line is extra, I could not tell without your original; I did not
edit the patch.

Reproduction

# Fedora 44 x86_64 container, GNU patch 2.8 (the patch is architecture-independent)
dnf download --source libhandy        # libhandy-1.8.3-10.fc44.src.rpm
rpm2cpio libhandy-*.src.rpm | cpio -idm
tar xf libhandy-1.8.3.tar.xz && cd libhandy-1.8.3
for n in 0001 0002 0003 0004 0005; do
  patch --batch --forward --fuzz=0 -p1 < patches/libhandy/$n-*.patch
done
# 0001-0004 apply; 0005: "malformed patch at line 276"

Also fails with rpm's default flags (patch -p1 -s --fuzz=0 --no-backup-if-mismatch).

Versions

  • SimplyLuma/luma main at f4cdf77b (2026-10-17). The same blob (git 88e10043c9d0262a7087c0cdf7dbd8361f7d5836) is on
    fp6-alpha1, and in the only commit that adds it, 5ec9305 ("Initial public source baseline"). There is no earlier version.
  • GNU patch 2.8 on Fedora 44.

Question

The FP6 alpha1 release was built, so some copy of this patch applied for you. Is the published file different from
the one your builder used, or is there a tool or flag combination I should use? A corrected file would be welcome.

Second, smaller note

scripts/mobile/compose-fp6-rootfs.sh: LUMA_FP6_INCLUDE_UI=0 skips only config/mobile/ui-packages.txt. The
local_rpms check still requires every shared Luma RPM, including libhandy, gtk3, gtk4, phoc and luma-phosh. The
post-dnf check also requires phosh. If a no-UI composition is meant to work, those requirements would need to be
conditional too; if it is not, ignore this.

Context

I am bringing up Luma Mobile on a OnePlus 5T (MSM8998). This only blocks my attempt to build the userspace
packages locally; no kernel or device work depends on it.

1 reply on GitHub

nmcmil11 days ago· edited

Thanks for the precise report. You were right about the count, and there was a second problem: the hunk had 3 leading but only 2 trailing context lines, so GNU patch also anchors it to end of file and rejects it at --fuzz=0 even with +567,20. Earlier revisions of 0005 had a well-formed final hunk; the published one does not.

#10 regenerates 0005 against libhandy 1.8.3 with 0001-0004 applied. The patched tree is identical to what was intended. 0001-0005 now apply with rpm's default patch -p1 -s --fuzz=0 --no-backup-if-mismatch and with git apply.

On LUMA_FP6_INCLUDE_UI=0: it isn't a headless mode today. It drops only the extra UI package set, and the shared Luma UI stack (libhandy, gtk3/gtk4, phoc, luma-phosh, phosh) is still required, as you found. We'll either gate those checks or rename the switch. Good luck with the 5T bring-up.

Add to this on GitHub

The conversation about this report is on GitHub, so that is where a reply reaches the people in it. If it happens to you too and you would rather not use GitHub, file it here and mention GitHub #9.

Reply on GitHubReport it here