Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 16 Apr 2024 04:19:34 +0100
From:      Jamie Landeg-Jones <jamie@catflap.org>
To:        void@f-m.fm, freebsd-ports@FreeBSD.org
Subject:   Re: holding rust at a particular version
Message-ID:  <202404160319.43G3JYV4025119@donotpassgo.dyslexicfish.net>
In-Reply-To: <Zh1eNMWjIAPDkljJ@int21h>
References:  <Zh0srdWHPh9JlW8p@int21h> <Zh1dN-TT3iUVUsj1@over-yonder.net> <Zh1eNMWjIAPDkljJ@int21h>

next in thread | previous in thread | raw e-mail | index | archive | help
void <void@f-m.fm> wrote:

> On Mon, Apr 15, 2024 at 12:00:39PM -0500, Matthew D. Fuller wrote:
> >On Mon, Apr 15, 2024 at 02:33:33PM +0100 I heard the voice of
> >void, and lo! it spake thus:
> >> Is it possible, either within poudriere or using traditional ports,
> >> to not have ports building fetching latest rust?
> >>
> >> rust 1.76 is already installed. 1.77 is in the ports tree.
> >> 1.76 is the latest for -current on arm64 on the pkg builders.
> >
> >This sounds like the better phrasing is "let poudriere keep using the
> >old upstream package of a dependancy even if the ports tree has a
> >newer version currently".
>
> yes ;)

I don't use poudriere, but for normal port buidling, and
specifically for rust, set this is /etc/make.conf:

CARGO_BUILDDEP= "any-version"

If you then install a new rust port, it won't require updating rust.

However, as you noticed, all the rust ports get version-bumped when
there is a new rust, so presumably if your setup does a "build all new ports",
then they will be affected by this.

Secondly, I'm sure some people reading this are screaming in horror - there
are obviously reasons why it's been decided to bump all the rust ports,
support and security issues based on previous rust versions being just two,
so, take this advice with a pinch of salt.
 
To answer the more general question as Matthew phrased it:

As Dimitry pointed out, this depends on different versions of the port
being in the port tree, and for this, use DEFAULT_VERSIONS.

Seeing as I've already probably freaked out the ports guys, I may as well
go all in:

On my slower machines I less care about, I have a script that automatically
sets the DEFAULT_VERSIONS for various things (in a file /var/run/port-default.versions.mk
that is loaded by make.conf) to the latest currently installed version - but
only if that version is still a valid port in the ports tree.

It's here if you're interested: https://www.catflap.org/jamie/freebsd/

Cheers, Jamie




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202404160319.43G3JYV4025119>