Page MenuHomeFreeBSD

graphics/nvidia-drm-kmod: Make distinfo auto-merged on build
Needs ReviewPublic

Authored by junchoon_dec.sakura.ne.jp on Sat, May 10, 2:27 PM.
Tags
None
Referenced Files
F118852609: D50282.diff
Mon, Jun 2, 2:51 PM
Unknown Object (File)
Fri, May 30, 7:25 PM
Unknown Object (File)
Mon, May 26, 1:34 PM
Unknown Object (File)
Wed, May 14, 1:52 PM
Subscribers
None

Details

Reviewers
manu
kbowling
ashafer
arrowd
Group Reviewers
x11
Summary

graphics/nvidia-drm-kmod: Make distinfo auto-merged on build

Currently, distinfo for graphics/nvidia-drm-*-kmod are required
to be updated manually when whichever of x11/nvidia-driver and
corresponding graphics/drm-*-kmod is upgraded, not to be forgotton
to be updated/committed.

And with graphics/drm-*-kmod part, although the contents of
their distfile always 100% matches, the downloaded filename
differs as of the differences of the method for downloading,
avoiding to simply replace corresponding part of distinfo
with the ones for gaphics/drm-*-kmod.

This change removes existing distinfo from graphics/nvidia-drm-*-kmod
and merges distinfo for x11/nvidia-driver and corresponding
graphics/drm-*-kmod on-the-fly on fetch and cleans up on
clean phase of builds.

This distinfo merges should be sane, as each source distinfo are already
confirmed by their maintainers / committers on commit.

Also includes changes of distfile names for DRM part to match
with graphics/drm-*-kmod to allow auto-merge.

This change depends on D50142 that splits distinfo of x11/nvidia-driver
into master and each legacy ports.

Depends on: D50142

Diff Detail

Repository
R11 FreeBSD ports repository
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

Now that distinfo's are separated, why do we need this autogen stuff at all?

I do see the improvement here for the drm maintainers not having to deal with all this, but I'd like someone with more ports infra experience to evaluate the implementation.

graphics/nvidia-drm-kmod/Makefile.common
9

as in the other rev the portrevision does not need to be bumped here since the package will not change

Rebase after commit 3adb70282914 and commit 8495963ac01c.
Stopped bumping PORTREVISION as pointed out by kbowling@.

Note that commit 9506d5a4e713 does not affect this review (prerequisite for this, though)..

So, while I am still not sure what problem we're solving here, this what I came up with:

diff --git a/x11/nvidia-driver/Makefile.common b/x11/nvidia-driver/Makefile.common
index 1236ca04b803..ff5e84ea5197 100644
--- a/x11/nvidia-driver/Makefile.common
+++ b/x11/nvidia-driver/Makefile.common
@@ -26,3 +26,20 @@ NVVERSION=   ${DISTVERSION:S/./.0/}                          # allow minor > 99
 NVVERSION=     ${DISTVERSION}
 .  endif
 .endif
+
+MAKESUM_PORTS= graphics/nvidia-drm-510-kmod \
+               graphics/nvidia-drm-515-kmod \
+               graphics/nvidia-drm-61-kmod \
+               graphics/nvidia-drm-66-kmod \
+               x11/nvidia-driver \
+               x11/nvidia-driver-304 \
+               x11/nvidia-driver-340 \
+               x11/nvidia-driver-390 \
+               x11/nvidia-driver-470
+
+.ifndef REAL_MAKESUM
+makesum:
+.  for p in ${MAKESUM_PORTS}
+       ${MAKE} -C ${PORTSDIR}/${p} makesum REAL_MAKESUM=yes
+.  endfor
+.endif

Now running make makesum for any port that includes x11/nvidia-driver/Makefile.common causes recursive makesum on all ${MAKESUM_PORTS}. Does that solve the problem?

Thanks for the idea!

With this approach, graphics/drm-[510|515|61|66]-kmod need the same, too.
This is because graphics/nvidia-drm-[510|515|61|66]-kmod requires distfiles of both x11/nvidia-driver and corresponding graphics/drm-[510|515|61|66]-kmod.

And as graphics/nvidia-drm-[510|515|61|66]-kmod don't support legacy versions of drivers, x11/nvidia-driver-[304|340|390|470], these can be dropped.

Anyway, what approach manu@ wants is quite important here, as he is maintaining graphics/drm-[510|515|61|66]-kmod..

graphics/nvidia-drm-kmod/Makefile.common
9

Stopped bumping PORTREVISION.

Rebase after commit 940ca091de52.
Keeping concept until manu@ pops in as the de-facto maintainer of graphics/drm-*-kmod.

I'm ok for this but keep in mind that we will still need to bump PORTREVISION on nvidia kmod when we update drm-*-kmod so I'm not sure it's worth doing all that tbh

I'm ok for this but keep in mind that we will still need to bump PORTREVISION on nvidia kmod when we update drm-*-kmod so I'm not sure it's worth doing all that tbh

Thanks for your comment!

So as x11/nvidia-driver updates. And once something wrong happenes, fixes are still needed.

The advantage of this would be avoiding any of distinfo for graphics/nvidia-drm-*-kmod is/are missed to be updated.
Official pkg for DRM-related kmods are often broken for anything except the very Release that official pkgs are built on.

And on kernel updates, usually rebuild/reinstall is necessary. In these cases, missed bump are not affect. So a bit of delay would be allowable.

Even if auto-merging is not accepted, changes for distfile names would help you.
With changes of line 7 and 11 of graphics/nvidia-drm/Makefile.common, distfile names match with graphics/drm-*-kmod. At least these 2 lines would be worth committing.

Should I split out line 7 and 11 of graphics/nvidia-drm-kmod/Makefile.common, which renames drm-*-kmod part of distfiles to match graphics/drm-*-kmod, to be a separate review and make this (D50282) to depend on it?