On Tue, Jun 30, 2020 at 8:10 AM Stuart Henderson <stu@spacehopper.org>
wrote:
> On 2020/06/30 02:56, Abel Abraham Camarillo Ojeda wrote:
> > (cc maintainer)
> >
> > Some programs (ntopng trying to use influx backend) complain they
> > can't know the version of influxdb, expected:
> >
> > $ influx -version
> > InfluxDB shell version: 1.6.6
> > $
> >
> > got:
> >
> > $ influx -version
> > InfluxDB shell version: unknown
> > $
> >
> > To reproduce:
> >
> > # (fresh install of 6.7/amd64)
> > # pkg_add influxdb;
> > # influx -version;
> > InfluxDB shell version: unknown
> > #
> >
> > Maybe it's related or similar to issue #6777
> > https://github.com/influxdata/influxdb/issues/6777
> >
> > which suggests to:
> >
> > > You have to include the linker flags mentioned in this issue above. To
> > add the version information, you have to add a -ldflags="-X
> > main.version=%pkgver%" to the go install command.
> >
> > before digging further into this (and because I have no experience
> > with go ports + vendor tarballs and such), I seek the wisdom
> > of ports@
> >
> > Thanks for any ideas
>
> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/databases/influxdb/Makefile,v
> retrieving revision 1.13
> diff -u -p -r1.13 Makefile
> --- Makefile 29 Apr 2020 11:36:54 -0000 1.13
> +++ Makefile 30 Jun 2020 13:10:37 -0000
> @@ -4,7 +4,7 @@ COMMENT = time-series datastore for metr
>
> V = 1.6.6
> DISTNAME = influxdb-${V}
> -REVISION = 0
> +REVISION = 1
>
> HOMEPAGE = https://influxdata.com
> # selfhosted because we bundle go deps
> @@ -39,6 +39,8 @@ USE_GMAKE = Yes
> SUBST_VARS = VARBASE
>
> NO_TEST = Yes
> +
> +MODGO_LDFLAGS += -X main.version=$V
>
> do-build:
> cd ${WRKSRC} && ${MODGO_BUILD_CMD} ./...
>
>
Thanks! I see its already committed
regards
No comments:
Post a Comment