New Go Packaging Guidelines landed in rawhide (koji) today


Fedora’s new Go packaging macros landed in rawhide (koji) today.

The corresponding Fedora Go packaging conventions are therefore
EFFECTIVE for new rawhide builds. For the first time in Fedora’s
history, we will be able to perform Go package builds conforming to an
approved Fedora Packaging Guideline.

Packaging documentation:
<a href="" title=""></a>
and approval: <a href="" title=""></a>
The go-rpm-templates package provides more complete info.

F31 change page:
<a href="" title=""></a>
and approval: <a href="" title=""></a>

While the guidelines will feel familiar to anyone who created a Fedora
Go packages in the last two years, they DO include a backwards-
incompatible change. Making GOPATH manipulation robust required moving
the corresponding logic to %prep with a new %goprep macro.

Therefore, existing specs are expected to fail without the addition of
the %goprep call.

This is of course not the end of the road, just a key step.

It opens the way to a mass cleanup and refresh of the Fedora Go stack.
<a href="" title=""></a>

A preview of this refresh is available here:
<a href="" title=""></a>

Enormous thanks to
– Robert-André Mauchin (eclipseo) for the gigantic work done reviewing
updating and cleaning-up all those packages, and to
– Elliott Sales de Andrade (Qulogic), that picked up maintenance of
golist and fixed many of its long-standing bugs and limitations.

Many thanks to the mock, rpm and redhat-rpm-config maintainers,
that integrated the changes, we built upon (Igor Gnatenko, Florian
Festi, Miroslav Suchý, Panu Matilainen)

The macro set supports Go DynamicBuildRequires
<a href="" title=""></a>

They will be usable in mock as soon as rpm 4.15 lands
<a href="" title=""></a>

Use in koji or copr will have to wait for the corresponding refresh
buldsystem-side. So this part of the change is a technology preview for

Best regards,