Getting port version
Solene Rapenne
solene at perso.pw
Mon Jul 4 16:58:26 UTC 2016
Hello
I am not sure but maybe you can find a tool for building packages in ports-mgmt ? I was thinking about portmaster for example.
Kind regards
Le 4 juillet 2016 18:23:30 GMT+02:00, Baho Utot <baho-utot at columbus.rr.com> a écrit :
>I am creating a bourne script ( I would use python but that is not in
>base ) to build packages.
>
>Synth, poudiere etc will not work, this is for a raspberry pi 2 and
>those tools don't run on the platform
>
>I need to get the port version from the port
>
> 1. so I can construct a string and have a look see if that port
>is already in the repository
>
> 2. I want to know what version I am building
>
>I have tried:
>
>#!/bin/sh
>
>for a in "dns/unbound ports-mgmt/pkg lang/perl5.20" ; do
> VERSION="$( grep PORTVERSION= /usr/ports/${a}/Makefile )"
>
> printf "Package: %s Version: %s\n" "${a}" "${VERSION##*=}"
>
>done
>
>
>That fails because all ports don't follow that, for instance:
>
> lang/perl5.20 has PORTVERSION= ${PERL_VERSION}
>
> ports-mgmt/pkg has DISTVERSION= <what ever>
>
>Is there some other way I can fetch the version from the Makefile?
>
>
>
>_______________________________________________
>freebsd-questions at freebsd.org mailing list
>https://lists.freebsd.org/mailman/listinfo/freebsd-questions
>To unsubscribe, send any mail to
>"freebsd-questions-unsubscribe at freebsd.org"
More information about the freebsd-questions
mailing list