Bug 273827 - [new port] devel/laminar: Lightweight CI service
Summary: [new port] devel/laminar: Lightweight CI service
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: Joel Bodenmann
URL: https://laminar.ohwg.net/
Keywords:
Depends on:
Blocks:
 
Reported: 2023-09-15 12:41 UTC by Marian Cingel
Modified: 2023-12-20 13:13 UTC (History)
2 users (show)

See Also:


Attachments
laminar support (17.02 KB, patch)
2023-09-15 12:41 UTC, Marian Cingel
no flags Details | Diff
Updated patch - the previous one had one unecessarry 'laminar' subfolder (16.65 KB, patch)
2023-09-15 19:57 UTC, Marian Cingel
no flags Details | Diff
Fixed rapidjson dependency (16.73 KB, patch)
2023-09-16 09:48 UTC, Marian Cingel
no flags Details | Diff
Enable aarch64, powerpc64. Enable automatic reload configuration using 'libinotify' (18.29 KB, patch)
2023-10-09 22:00 UTC, Marian Cingel
no flags Details | Diff
pass poudriere testport (19.44 KB, patch)
2023-11-03 21:36 UTC, Marian Cingel
no flags Details | Diff
GH_TAGNAME refers to commit supporting FBSD (8.38 KB, patch)
2023-11-07 22:54 UTC, Marian Cingel
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marian Cingel 2023-09-15 12:41:56 UTC
Created attachment 244886 [details]
laminar support
Comment 1 Marian Cingel 2023-09-15 19:57:10 UTC
Created attachment 244902 [details]
Updated patch - the previous one had one unecessarry 'laminar' subfolder
Comment 2 Yonas Yanfa 2023-09-15 23:09:13 UTC
@Marian

Thanks for uploading! This works for me. There was a missing build dependency on rapidjson:


BUILD_DEPENDS+= ${LOCALBASE}/include/rapidjson/rapidjson.h:devel/rapidjson
Comment 3 Marian Cingel 2023-09-16 09:48:15 UTC
Created attachment 244928 [details]
Fixed rapidjson dependency

@Yonas
Fixed, thanks.
Comment 4 Joel Bodenmann freebsd_committer freebsd_triage 2023-09-21 16:06:15 UTC
Thank you for your submission!

Could you work with upstream to resolve the ONLY_FOR_ARCHS limitation? aarch64 is a tier 1 platform so we try to have everything working there too unless it's a platform specific port.
Comment 5 Marian Cingel 2023-09-21 19:53:33 UTC
@joel

If you want to support aarch64 or some other small reasonable set of architectures (Power9, RiscV, ..) that is not a problem, I can do it in few days, but I cannot get rid of ONLY_FOR_ARCHS limitation.

The reason is that the linker is directly used to link a binary blob (compressed .html, .js, .css) into an object file. And in case of LLVM linker ("ld.lld") and --format=binary (-b) flag, the linker requires to explicitly set what is the "emulation" type (output format + arch + endian + abi). CMake does not provide any builtin variable to express this kind of linker feature - so I created a conversion based on CMAKE_SYSTEM_PROCESSOR. GNU_LD does not have such a problem.
Comment 6 Joel Bodenmann freebsd_committer freebsd_triage 2023-09-25 14:54:11 UTC
From what I can tell, having support for all tier 1 platforms (which are amd64 and aarch64 as of 14.0) would be desirable.

The general limitation for other archs seems to make sense given the limitation/requirement you laid out.
Comment 7 Graham Perrin 2023-10-07 14:58:39 UTC
@jbo please: where you are the assignee for reports such as this, are you happy for the status to be in progress?

^Triage: 

* status (open)
* URL.
Comment 8 Joel Bodenmann freebsd_committer freebsd_triage 2023-10-07 15:03:19 UTC
(In reply to Graham Perrin from comment #7)
I / we tend to update the status to 'in progress' once that the committer actually starts applying the patch locally and performing build tests. That is not the case here yet.
Comment 9 Marian Cingel 2023-10-09 22:00:53 UTC
Created attachment 245536 [details]
Enable aarch64, powerpc64. Enable automatic reload configuration using 'libinotify'
Comment 10 Joel Bodenmann freebsd_committer freebsd_triage 2023-10-31 10:23:39 UTC
Did you run this through poudriere-testport (successfully)?
Comment 11 Marian Cingel 2023-11-03 21:36:16 UTC
Created attachment 246087 [details]
pass poudriere testport

Updated to pass poudriere (in previous version, cmake downloaded external .js libraries during configure phase)
Comment 12 Joel Bodenmann freebsd_committer freebsd_triage 2023-11-07 10:43:30 UTC
I just noticed that some of the patched changes seem to have been committed to upstream: https://github.com/ohwgiles/laminar/commit/277a59f1cba75fa763e5838b3443f11686dd5ebb

Could you update the port accordingly before we merge this?
Comment 13 Marian Cingel 2023-11-07 22:54:19 UTC
Created attachment 246187 [details]
GH_TAGNAME refers to commit supporting FBSD
Comment 14 Marian Cingel 2023-11-07 22:54:45 UTC
(In reply to Joel Bodenmann from comment #12)
Done.
Comment 15 commit-hook freebsd_committer freebsd_triage 2023-12-20 13:12:25 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=181bdf41a334781d1a858ec8f26d679ec9871374

commit 181bdf41a334781d1a858ec8f26d679ec9871374
Author:     Marian Cingel <cingel.marian@gmail.com>
AuthorDate: 2023-09-15 12:27:40 +0000
Commit:     Joel Bodenmann <jbo@FreeBSD.org>
CommitDate: 2023-12-20 12:54:26 +0000

    devel/laminar: New port

    Laminar is a lightweight client-server CI service written in C++ and
    configured by environment variables. It comes with a built-in webserver
    and uses simple .run shell scripts as jobs.

    PR:                     273827
    Approved by:            tcberner (mentor)
    Differential Revision:  https://reviews.freebsd.org/D42877

 devel/Makefile                            |  1 +
 devel/laminar/Makefile (new)              | 72 +++++++++++++++++++++++++++++++
 devel/laminar/distinfo (new)              |  9 ++++
 devel/laminar/files/laminard.env.in (new) | 64 +++++++++++++++++++++++++++
 devel/laminar/files/laminard.in (new +x)  | 32 ++++++++++++++
 devel/laminar/pkg-descr (new)             |  5 +++
 devel/laminar/pkg-plist (new)             | 10 +++++
 7 files changed, 193 insertions(+)
Comment 16 Joel Bodenmann freebsd_committer freebsd_triage 2023-12-20 13:13:15 UTC
Committed - Thanks!

Apologies that this took so long.