Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider representing packages in kernel module overlay repositories #611

Open
grahamperrin opened this issue Dec 13, 2024 · 24 comments
Open

Comments

@grahamperrin
Copy link
Contributor

With https://www.freshports.org/graphics/drm-61-kmod/#packages as an example, we currently have:

  • 6.1.92_3 under amd64 for FreeBSD:14:latest
  • 6.1.92 under amd64 for FreeBSD:14:quarterly.

I guess that eventually, there might be additional rows with (for example):

  • 6.1.92.1402000_3 under amd64 for FreeBSD:14:kmods_latest
  • 6.1.92.1402000_3 under amd64 for FreeBSD:14:kmods_quarterly

Early days. My thoughts are far from formed.

Below, for reference, package annotations before and after a switch:

  • from kmods_quarterly_2
  • to kmods_latest_2

– no difference, at this time.

drm-61-kmod before and after a switch
root@fourteen-pkgbase:~ # date ; pkg query '%o %v %At:%Av' drm-61-kmod
Fri Dec 13 07:36:59 GMT 2024
graphics/drm-61-kmod 6.1.92.1402000_3 FreeBSD_version:1402000
graphics/drm-61-kmod 6.1.92.1402000_3 repo_type:binary
graphics/drm-61-kmod 6.1.92.1402000_3 repository:FreeBSD-kmods
root@fourteen-pkgbase:~ # ee /usr/local/etc/pkg/repos/FreeBSD-kmods.conf

root@fourteen-pkgbase:~ # pkg -vv | grep -B 1 -e url -e priority
  FreeBSD-ports: { 
    url             : "pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/quarterly",
    enabled         : yes,
    priority        : 0,
--
  FreeBSD-base: { 
    url             : "pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/base_release_2",
    enabled         : yes,
    priority        : 0,
--
  FreeBSD-kmods: { 
    url             : "pkg+https://pkg.freebsd.org/FreeBSD:14:amd64/kmods_latest_2",
    enabled         : yes,
    priority        : 5,
--
  local-poudriere: { 
    url             : "file:///usr/local/poudriere/data/packages/fourteen-default",
    enabled         : yes,
    priority        : 3
root@fourteen-pkgbase:~ # pkg update
Updating FreeBSD-ports repository catalogue...
FreeBSD-ports repository is up to date.
Updating FreeBSD-base repository catalogue...
FreeBSD-base repository is up to date.
Updating FreeBSD-kmods repository catalogue...
pkg: Repository FreeBSD-kmods has a wrong packagesite, need to re-create database
Fetching meta.conf: 100%    178 B   0.2kB/s    00:01    
Fetching data.pkg: 100%   12 KiB  12.6kB/s    00:01    
Processing entries: 100%
The provides database is up-to-date.
FreeBSD-kmods repository update completed. 43 packages processed.
Updating local-poudriere repository catalogue...
local-poudriere repository is up to date.
All repositories are up to date.
root@fourteen-pkgbase:~ # pkg upgrade --quiet --force --repository FreeBSD-kmods graphics/drm-61-kmod
root@fourteen-pkgbase:~ # pkg upgrade --force --repository FreeBSD-kmods graphics/drm-61-kmod
Updating FreeBSD-kmods repository catalogue...
FreeBSD-kmods repository is up to date.
All repositories are up to date.
The following 1 package(s) will be affected (of 0 checked):

Installed packages to be REINSTALLED:
        drm-61-kmod-6.1.92.1402000_3 [FreeBSD-kmods]

Number of packages to be reinstalled: 1

3 MiB to be downloaded.

Proceed with this action? [y/N]: n
root@fourteen-pkgbase:~ # pkg upgrade --quiet --force --yes --repository FreeBSD-kmods graphics/drm-61-kmod
root@fourteen-pkgbase:~ # pkg query '%o %v %At:%Av' drm-61-kmod
graphics/drm-61-kmod 6.1.92.1402000_3 FreeBSD_version:1402000
graphics/drm-61-kmod 6.1.92.1402000_3 repo_type:binary
graphics/drm-61-kmod 6.1.92.1402000_3 repository:FreeBSD-kmods
root@fourteen-pkgbase:~ # pkg info drm-61-kmod
drm-61-kmod-6.1.92.1402000_3
Name           : drm-61-kmod
Version        : 6.1.92.1402000_3
Installed on   : Fri Dec 13 07:39:48 2024 GMT
Origin         : graphics/drm-61-kmod
Architecture   : FreeBSD:14:amd64
Prefix         : /usr/local
Categories     : kld graphics
Licenses       : MIT and GPLv2 and BSD2CLAUSE
Maintainer     : [email protected]
WWW            : https://github.com/freebsd/drm-kmod/
Comment        : DRM drivers modules
Annotations    :
        FreeBSD_version: 1402000
        repo_type      : binary
        repository     : FreeBSD-kmods
Flat size      : 17.0MiB
Description    :
amdgpu, i915, and radeon DRM drivers modules.
Currently corresponding to Linux 6.1 DRM.
This version is for FreeBSD 14-STABLE 1400508
and above.
root@fourteen-pkgbase:~ # date ; uptime
Fri Dec 13 07:40:48 GMT 2024
 7:40AM  up  3:20, 1 user, load averages: 0.93, 0.57, 0.43
root@fourteen-pkgbase:~ # 

@dlangille I guess that you knew (privately) of recent developments before things became public. If not: this can be a heads-up.

Context, in Reddit:

@dlangille
Copy link
Contributor

dlangille commented Dec 13, 2024

relevant announcement: https://lists.freebsd.org/archives/freebsd-ports/2024-December/006997.html

I think you're asking for FreshPorts to add

Something like: https://news.freshports.org/2021/02/10/adding-freebsd14-to-the-list-of-build-packages/

The key challenge: can these packages be related back to something already in FreshPorts?

Fetching data:

[14:49 mydev dvl ~/tmp/FreshPorts-Issue-611] % fetch -o 14-latest-quarterly.txz https://pkg.freebsd.org/FreeBSD:14:amd64/quarterly/packagesite.txz 
[14:51 mydev dvl ~/tmp/FreshPorts-Issue-611] % fetch -o 14-base_release_2.txz https://pkg.freebsd.org/FreeBSD:14:amd64/base_release_2/packagesite.txz
[14:51 mydev dvl ~/tmp/FreshPorts-Issue-611] % fetch -o 14-kmods_latest_2.txz https://pkg.freebsd.org/FreeBSD:14:amd64/kmods_latest_2/packagesite.txz
[14:53 mydev dvl ~/tmp/FreshPorts-Issue-611] % ls -l
total 7362
-rw-r--r--  1 dvl dvl   38368 2024.11.29 00:10 14-base_release_2.txz
-rw-r--r--  1 dvl dvl   12552 2024.12.12 23:09 14-kmods_latest_2.txz
-rw-r--r--  1 dvl dvl 7459912 2024.12.12 13:11 14-latest-quarterly.txz

@dlangille
Copy link
Contributor

Extracting data:

[14:54 mydev dvl ~/tmp/FreshPorts-Issue-611] % mkdir base_release_2
[14:54 mydev dvl ~/tmp/FreshPorts-Issue-611] % cd base_release_2
[14:54 mydev dvl ~/tmp/FreshPorts-Issue-611/base_release_2] % tar -xzf ../14-base_release_2.txz

[14:54 mydev dvl ~/tmp/FreshPorts-Issue-611/base_release_2] % ls -l
total 2
-rw-r--r--  1 dvl dvl 320764 2024.11.29 00:10 packagesite.yaml
-rw-r--r--  1 dvl dvl    451 1970.01.01 00:00 packagesite.yaml.pub
-rw-r--r--  1 dvl dvl    256 1970.01.01 00:00 packagesite.yaml.sig
[14:54 mydev dvl ~/tmp/FreshPorts-Issue-611/base_release_2] % cd ..


[14:54 mydev dvl ~/tmp/FreshPorts-Issue-611] % mkdir kmods_latest_2
[14:54 mydev dvl ~/tmp/FreshPorts-Issue-611] % cd kmods_latest_2
[14:55 mydev dvl ~/tmp/FreshPorts-Issue-611/kmods_latest_2] % tar -xzf ../14-kmods_latest_2.txz

[14:55 mydev dvl ~/tmp/FreshPorts-Issue-611/kmods_latest_2] % ls -l
total 30
-rw-r--r--  1 dvl dvl 56894 2024.12.12 23:09 packagesite.yaml
-rw-r--r--  1 dvl dvl   451 1970.01.01 00:00 packagesite.yaml.pub
-rw-r--r--  1 dvl dvl   256 1970.01.01 00:00 packagesite.yaml.sig

@dlangille
Copy link
Contributor

Looking at the first few fields of the first record in each file:

[14:58 mydev dvl ~/tmp/FreshPorts-Issue-611/base_release_2] % head -1 packagesite.yaml
{"name":"FreeBSD-wpa-man","origin":"base","version":"14.2","comment": ...

[14:57 mydev dvl ~/tmp/FreshPorts-Issue-611/kmods_latest_2] % head -1 packagesite.yaml
{"name":"uarduno","origin":"comms/uarduno","version":"1.02.1402000_1","comment": ...

The origin for base_release_2 does not refer to a port.

However, the kmods_latest_2 entry does: https://www.freshports.org/comms/uarduno/

@dlangille
Copy link
Contributor

If I can make this an ABI, it will slot into FreshPorts seamlessly I think. One issue: there is no latest or quarterly for this, which affects database queries - which assume there is always both.

@dlangille
Copy link
Contributor

The usual method seems to work:

[15:12 mydev dvl ~/tmp/FreshPorts-Issue-611] % jq -rc '[.origin, .name, .version] | @tsv' < kmods_latest_2/packagesite.yaml > kmods_latest_2/packagesite.csv 
[15:14 mydev dvl ~/tmp/FreshPorts-Issue-611] % head kmods_latest_2/packagesite.csv
comms/uarduno	uarduno	1.02.1402000_1
misc/utouch-kmod	utouch-kmod	0.0.5.1402000
sysutils/sysctlinfo-kmod	sysctlinfo-kmod	20221211.1402000_1
emulators/parallels-tools	parallels-tools	0.1.2.1402000_1
graphics/plasma-kmod	plasma-kmod	0.1.1402000_4
net/vether-kmod	vether-kmod	g20211214.1402000_1
sysutils/sysctlbyname-improved-kmod	sysctlbyname-improved-kmod	20221211.1402000
net/realtek-re-kmod	realtek-re-kmod	1100.00.1402000_1
multimedia/pwcbsd	pwcbsd	1.4.1.1402000_15
net/wifi-firmware-rtw88-kmod	wifi-firmware-rtw88-kmod	20241017.1402000_1

@dlangille
Copy link
Contributor

I repeated the process for quarterly:

[15:20 mydev dvl ~/tmp/FreshPorts-Issue-611/kmods_quarterly_2] % sort packagesite.csv | head
comms/opencbm-kmod	opencbm-kmod	0.4.99.104.1402000_2
comms/uarduno	uarduno	1.02.1402000_1
emulators/open-vm-kmod	open-vm-kmod	12.5.0.1402000,2
emulators/parallels-tools	parallels-tools	0.1.2.1402000_1
graphics/drm-515-kmod	drm-515-kmod	5.15.160.1402000_2
graphics/drm-61-kmod	drm-61-kmod	6.1.92.1402000_3
graphics/gpu-firmware-amd-kmod	gpu-firmware-amd-kmod-aldebaran	20230625.1402000_2
graphics/gpu-firmware-intel-kmod	gpu-firmware-intel-kmod-skylake	20230625.1402000
graphics/gpu-firmware-radeon-kmod	gpu-firmware-radeon-kmod-aruba	20220511.1402000
graphics/plasma-kmod	plasma-kmod	0.1.1402000_4

@dlangille
Copy link
Contributor

What is needed to know what to download?

These are the two active downloads:

https://pkg.freebsd.org/FreeBSD:14:amd64/kmods_latest_2/packagesite.txz
https://pkg.freebsd.org/FreeBSD:14:amd64/kmods_quarterly_2/packagesite.txz

Meaning, I need to know we have: 14.2

@dlangille
Copy link
Contributor

I think we can store the results in here, using kmod in the package_set column.

freshports.dvl=# select * from packages limit 10;
   id    | abi_id | package_set |       package_name        | package_version | port_id 
---------+--------+-------------+---------------------------+-----------------+---------
 4738600 |     27 | latest      | php83-pecl-uploadprogress | 2.0.2           |   20241
 4738745 |     27 | latest      | php81-pecl-uploadprogress | 2.0.2           |   20241
 4743648 |     27 | latest      | p5-Gtk3                   | 0.034_2         |   38440
 5722196 |     30 | latest      | treepy.el-emacs_devel_nox | 0.1.2_13        |   50812
 5722198 |     30 | latest      | py311-fugashi             | 1.3.2           |  119122
 5780756 |     11 | latest      | yarn-node23               | 1.22.19         |  120371
 5780757 |     11 | latest      | websocketd                | 0.4.1_23        |   47568
 5780758 |     11 | latest      | sse2neon                  | 1.7.0           |  120372
 4749758 |     27 | latest      | xfce4-dashboard           | 1.0.0_3         |   35801
 5780761 |     11 | latest      | poudriere-dsh2dsh         | 3.4.99.20240812 |  120380
(10 rows)

@dlangille
Copy link
Contributor

dlangille commented Dec 13, 2024

Not unexpected:

freshports.dvl=*# insert into packages (abi_id, package_set, package_name, package_version, port_id) values (27, 'kmod', 'uarduno', '1.02.1402000_1', 28279);
ERROR:  invalid input value for enum package_sets: "kmod"
LINE 1: ...ckage_name, package_version, port_id) values (27, 'kmod', 'u...
                                                             ^
freshports.dvl=!# rollback;
ROLLBACK
freshports.dvl=# ALTER TYPE public.package_sets ADD VALUE 'kmod' AFTER 'quarterly';
ALTER TYPE
freshports.dvl=# insert into packages (abi_id, package_set, package_name, package_version, port_id) values (27, 'kmod', 'uarduno', '1.02.1402000_1', 28279);
INSERT 0 1
freshports.dvl=# 

@dlangille
Copy link
Contributor

Here we show kmod for my one manually inserted row:

kmod

@grahamperrin
Copy link
Contributor Author

Wow. Carry on.

@dlangille
Copy link
Contributor

dlangille commented Dec 13, 2024

When a new row is added to the abi table, a trigger adds these values to the packages_last_checked table:

   IF TG_OP = 'INSERT' THEN
      INSERT INTO packages_last_checked(abi_id, package_set)
            VALUES (NEW.id, 'latest'),
                   (NEW.id, 'quarterly'),
                   (NEW.id, 'kmod');
   END IF;

Which means we have to update that table with all abi values with kmod.

EDIT: We don't need FreeBSD:13:* values.

freshports.dvl=# begin;
BEGIN
freshports.dvl=*# insert into packages_last_checked(abi_id, package_set)
select id, 'kmod' from abi;
INSERT 0 22
freshports.dvl=*# commit;
COMMIT
freshports.dvl=# 

Might be better with:

insert into packages_last_checked(abi_id, package_set)
select id, 'kmod' from abi where name not like 'FreeBSD:13:%';

Fixed the original data via:

freshports.dvl=# begin;
BEGIN
freshports.dvl=*# delete from packages_last_checked where abi_id in (select id from abi where name like 'FreeBSD:13:%');
DELETE 24
freshports.dvl=*# select abi.name, PLC.* from packages_last_checked plc join abi on plc.abi_id = abi.id and package_set = 'kmod' order by name;

@dlangille
Copy link
Contributor

After running sudo /usr/local/etc/periodic/hourly/900.freshports-check-repos-for-new-builds, we have dates:

freshports.dvl=# select * from packages_last_checked where package_set = 'kmod';
 abi_id | package_set |         last_checked         |       repo_date        | import_date | processed_date 
--------+-------------+------------------------------+------------------------+-------------+----------------
      2 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     11 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     20 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     21 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     10 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     58 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     24 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     57 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     26 | kmod        | 2024-12-13 21:40:14.95907+00 | 2024-12-13 10:46:14+00 |             | 
     27 | kmod        | 2024-12-13 21:40:14.95907+00 | 2024-12-13 10:31:11+00 |             | 
     28 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     29 | kmod        | 2024-12-13 21:40:14.95907+00 | 2024-12-13 10:39:14+00 |             | 
     30 | kmod        | 2024-12-13 21:40:14.95907+00 | 2024-12-13 10:52:55+00 |             | 
     59 | kmod        | 2024-12-13 21:40:14.95907+00 | 2024-12-13 10:59:42+00 |             | 
     33 | kmod        | 2024-12-13 21:40:14.95907+00 | 2024-12-13 11:06:41+00 |             | 
     56 | kmod        | 2024-12-13 21:40:14.95907+00 | 2024-12-13 11:13:37+00 |             | 
     54 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     47 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     49 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     60 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     52 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 
     55 | kmod        | 2024-12-13 21:40:14.95907+00 |                        |             | 

@dlangille
Copy link
Contributor

When that script ran we were told in the logs:

Dec 13 21:40:23 dvl-ingress01 check_repos_for_new_stuff.py[48307]: Number of repos ready for import: 7.
They are: 
['FreeBSD:14:aarch64/kmod : Fri, 13 Dec 2024 10:46:14 GMT',
 'FreeBSD:14:amd64/kmod : Fri, 13 Dec 2024 10:31:11 GMT',
 'FreeBSD:14:armv7/kmod : Fri, 13 Dec 2024 10:39:14 GMT',
 'FreeBSD:14:i386/kmod : Fri, 13 Dec 2024 10:52:55 GMT',
 'FreeBSD:14:powerpc/kmod : Fri, 13 Dec 2024 10:59:42 GMT',
 'FreeBSD:14:powerpc64/kmod : Fri, 13 Dec 2024 11:06:41 GMT',
 'FreeBSD:14:powerpc64le/kmod : Fri, 13 Dec 2024 11:13:37 GMT']

This seems right.

@dlangille
Copy link
Contributor

However, the code is not set up to fetch the appropriate URLS:

Dec 13 21:40:24 dvl-ingress01 FreshPorts[48734]: /var/db/freshports/signals/new_repo_ready_for_import exists. About to run import_packagesite.py via system() (/usr/local/libexec/freshports)
Dec 13 21:40:24 dvl-ingress01 FreshPorts[48734]: details are: /usr/local/libexec/freshports/import_packagesite.py >> /var/log/freshports/jobs_waiting.log (/usr/local/libexec/freshports)

*** /var/log/freshports/freshports-daemon.log ***
Dec 13 21:40:24 dvl-ingress01 freshports[15932]: yes, there is a job waiting

*** /var/log/freshports/freshports.log ***
Dec 13 21:40:25 dvl-ingress01 import_packagesite.py[48736]: Starting up
Dec 13 21:40:25 dvl-ingress01 import_packagesite.py[48736]: we have 7 repos to process
Dec 13 21:40:25 dvl-ingress01 import_packagesite.py[48736]: importing FreeBSD:14:aarch64/kmod
Dec 13 21:40:25 dvl-ingress01 import_packagesite.py[48736]: command is: /usr/local/libexec/freshports/fetch-extract-parse-import-one-abi.sh FreeBSD:14:aarch64 kmod
Dec 13 21:40:25 dvl-ingress01 fetch-extract-parse-import-one-abi.sh[48748]: starting /usr/local/libexec/freshports/fetch-extract-parse-import-one-abi.sh
Dec 13 21:40:25 dvl-ingress01 fetch-extract-parse-import-one-abi.sh[48752]: creating /var/db/freshports/packagesite/FreeBSD:14:aarch64/kmod
Dec 13 21:40:25 dvl-ingress01 fetch-extract-parse-import-one-abi.sh[48757]: cd /var/db/freshports/packagesite/FreeBSD:14:aarch64/kmod/
Dec 13 21:40:25 dvl-ingress01 fetch-extract-parse-import-one-abi.sh[48761]: fetch --quiet https://pkg.freebsd.org/FreeBSD:14:aarch64/kmod/meta.conf
Dec 13 21:40:25 dvl-ingress01 fetch-extract-parse-import-one-abi.sh[48766]: WARNING: unable to fetch https://pkg.freebsd.org/FreeBSD:14:aarch64/kmod/meta.conf - using default values.
Dec 13 21:40:25 dvl-ingress01 fetch-extract-parse-import-one-abi.sh[48770]: rm -f packagesite.txz packagesite.tar
...

@dlangille
Copy link
Contributor

dlangille commented Dec 13, 2024

And now we have this:

(pay no attention to the 12 conversations)

Screen Shot 2024-12-13 at 5 13 00 PM

@dlangille
Copy link
Contributor

dlangille commented Dec 13, 2024

notes to self:

  • does package notification subscription work with kmod?

  • appearing in package notification emails for FreeBSD:14:amd64::latest- not sure this is expected.

comms/opencbm-kmod
  updated:
          new version: 0.4.99.104.1401000_2
          old version: 0.4.99.104_2

emulators/virtualbox-ose-kmod
  updated:
          new version: 6.1.50.1401000
          old version: 6.1.50

@grahamperrin
Copy link
Contributor Author

relevant announcement: lists.freebsd.org/archives/freebsd-ports/2024-December/006997.html

Exactly (with the cross-post to freebsd-stable).

My tests with RELEASE, in Reddit, preceded the call for testing … hopefully no confusion as a result.

@grahamperrin
Copy link
Contributor Author

#611 (comment)

And now we have this:

Looking ahead: might there arise a need for additional rows?

To distinguish between e.g.:

Assuming that versions will, occasionally, differ.

@dlangille
Copy link
Contributor

note to self:

#611 (comment)

And now we have this:

Looking ahead: might there arise a need for additional rows?

To distinguish between e.g.:

Assuming that versions will, occasionally, differ.

At present, using kmod for fetching data requires special handling, to translate kmod to kmods_latest_2 - I should instead add kmods_latest_2 and kmods_quarterly_2 and avoid that conversion. At present, there's not enough data.

Let's call that a package_set, as in latest and quarterly. If the trend continues, we'll have kmods_latest_3 and kmods_quarterly_3 for FreeBSD 14.3, and kmods_latest_4 and kmods_quarterly_4 for FreeBSD 13.4.

From what I can tell, this will need to be manually maintained.

@dlangille
Copy link
Contributor

It also complicates the database queries already in place, which depends upon quarterly, and latest.

It we have just kmod, we do this. If we have multiple kmod package sets, the following function gets more complex.

CREATE OR REPLACE FUNCTION public.portpackages(
        a_port_id integer)
    RETURNS TABLE(package_name text, abi text, package_version_kmod text, package_version_latest text, package_version_quarterly text, last_checked_kmod text, repo_date_kmod text
    LANGUAGE 'sql'
    COST 100
    STABLE PARALLEL UNSAFE
    ROWS 1000

AS $BODY$
    WITH
      pkg AS (SELECT * FROM packages WHERE port_id = a_port_id)
    SELECT pn.package_name,
           abi.name AS abi,
           max(pkg.package_version)           FILTER (WHERE pkg.package_set = 'kmod')      AS package_version_kmod,
           max(pkg.package_version)           FILTER (WHERE pkg.package_set = 'latest')    AS package_version_latest,
           max(pkg.package_version)           FILTER (WHERE pkg.package_set = 'quarterly') AS package_version_quarterly,

           max(iso_date(PLC.last_checked))    FILTER (where PLC.package_set = 'kmod')      AS last_checked_kmod,
           max(iso_date(PLC.repo_date))       FILTER (where PLC.package_set = 'kmod')      AS repo_date_kmod,
           max(iso_date(PLC.import_date))     FILTER (where PLC.package_set = 'kmod')      AS import_date_kmod,
           max(iso_date(PLC.processed_date))  FILTER (where PLC.package_set = 'kmod')      AS processed_date_kmod,

           max(iso_date(PLC.last_checked))    FILTER (where PLC.package_set = 'latest')    AS last_checked_latest,
           max(iso_date(PLC.repo_date))       FILTER (where PLC.package_set = 'latest')    AS repo_date_latest,
           max(iso_date(PLC.import_date))     FILTER (where PLC.package_set = 'latest')    AS import_date_latest,
           max(iso_date(PLC.processed_date))  FILTER (where PLC.package_set = 'latest')    AS processed_date_latest,

           max(iso_date(PLC.last_checked))    FILTER (where PLC.package_set = 'quarterly') AS last_checked_quarterly,
           max(iso_date(PLC.repo_date))       FILTER (where PLC.package_set = 'quarterly') AS repo_date_quarterly,
           max(iso_date(PLC.import_date))     FILTER (where PLC.package_set = 'quarterly') AS import_date_quarterly,
           max(iso_date(PLC.processed_date))  FILTER (where PLC.package_set = 'quarterly') AS processed_date_quarterly
      FROM abi
           CROSS JOIN (SELECT DISTINCT package_name FROM pkg) pn
           LEFT JOIN pkg ON (pkg.abi_id = abi.id AND pkg.package_name = pn.package_name)
           JOIN packages_last_checked PLC ON PLC.abi_id  = abi.id
     GROUP BY pn.package_name, abi.name
     ORDER BY pn.package_name, abi.name;
$BODY$;

@dlangille
Copy link
Contributor

dlangille commented Dec 14, 2024

It may be better to list kernel modules separately. No sense showing it for every port. There are only 230 kernel modules in the tree.

It may be easier to list them only separately on the page for those ports. Otherwise, it looks like this:

samdrucker-kmod

Then, we could do:

      ABI	aarch64	amd64	armv6	armv7	i386	powerpc	powerpc64	powerpc64le
stable/13
releng/13.3
releng/13.4
stable/14
releng/14.1
releng/14.2 
main (was previously referred to here as stable/15)

I think that makes the most sense.

@dlangille
Copy link
Contributor

From #612 we have:

freshports.dvl=# select *, split_part(name, '/', 2), split_part(name, '/', 1)
from supported_releases order by split_part(name, '/', 2) DESC;
 id |    name     | enabled | split_part | split_part 
----+-------------+---------+------------+------------
  2 | releng/14.2 | t       | 14.2       | releng
  3 | releng/14.1 | t       | 14.1       | releng
  1 | stable/14   | t       | 14         | stable
  5 | releng/13.4 | t       | 13.4       | releng
  6 | releng/13.3 | t       | 13.3       | releng
  4 | stable/13   | t       | 13         | stable
(6 rows)

freshports.dvl=# 

@grahamperrin
Copy link
Contributor Author

#611 (comment)

Nit:

stable/15

– e.g. 15.0-CURRENT could/should be:

main

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

2 participants