Bug 281182 - www/firefox needs a rustix/src/backend/libc/fs/syscalls.rs patch analogous to the one under lang/rust/files/armv7/
Summary: www/firefox needs a rustix/src/backend/libc/fs/syscalls.rs patch analogous to...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: freebsd-gecko (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-01 08:07 UTC by Mark Millard
Modified: 2024-11-15 10:31 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (gecko)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mark Millard 2024-09-01 08:07:00 UTC
For rust 1.79.0_1 vs. firefox 129.0.2_2 , the only difference needed
for the content of the patch files was the file path:

# diff /usr/ports/lang/rust/files/armv7/patch-vendor_rustix_src_backend_libc_fs_syscalls.rs /usr/ports/www/firefox/files/patch-third__party_rust_rustix_src_backend_libc_fs_syscalls.rs | more
5,6c5,6
< --- vendor/rustix-0.38.28/src/backend/libc/fs/syscalls.rs.orig        2024-05-06 16:29:17.182875000 +0200
< +++ vendor/rustix-0.38.28/src/backend/libc/fs/syscalls.rs     2024-05-06 16:29:48.897744000 +0200
---
> --- third_party/rust/rustix/src/backend/libc/fs/syscalls.rs.orig      2024-05-06 16:29:17.182875000 +0200
> +++ third_party/rust/rustix/src/backend/libc/fs/syscalls.rs   2024-05-06 16:29:48.897744000 +0200

But rust and firefox have progressed since then. However, a similar point
may well apply to the updated pair.

This will mat†er if someone ever tries to get armv7 firefox to build
(and work): This appears to be one of multiple things that are broken
for that context, one I happen to have figured out via a suggestion
someone made on a list.
Comment 1 Mark Millard 2024-09-01 12:40:38 UTC
(In reply to Mark Millard from comment #0)

Hmm. I should have noted a limitation of my experiment with
the patch for the armv7 context. lang/rust's Makefile has:

.if exists(${PATCHDIR}/${ARCH}${BOOTSTRAPS_SUFFIX})
EXTRA_PATCHES+= ${PATCHDIR}/${ARCH}${BOOTSTRAPS_SUFFIX}
.endif

(with appropriate bsd.port.pre.mk and bsd.port.post.mk use)

and it has:

# find files/*/*
files/armv7/patch-compiler_rustc__driver__impl_src_signal__handler.rs
files/armv7/patch-vendor_rustix_src_backend_libc_fs_syscalls.rs
files/riscv64/patch-vendor_openssl-src_src_lib.rs
files/riscv64/patch-vendor_rustc__ap__rustc__target_src_spec_riscv64gc__unknown__freebsd.rs

I did not replicate the files/armv7/ aspect of the structure for my
test. One could imagine that I had used:

files/armv7/third__party_rust_rustix_src_backend__libc_fs_syscalls.rs

instead, with the additional Makefile content. This would avoid using
the patch on anything but armv7, just like lang/rust does via using:

files/armv7/patch-vendor_rustix_src_backend_libc_fs_syscalls.rs