On 2022/11/10 10:58, Stefan Hagen wrote:
> Hello,
> 
> some go ports seem to have trouble when they are built within a git
> checkout. This happens for example when the ports tree was checked out 
> via git and the pobj dir is within the checkout path (which is the current 
> [debateable] default) with PORTSDIR=/usr/ports and WRKOBJDIR=$PORTSDIR/pobj
> 
> There was a change in go 1.18 where the -buildvcs default was flipped
> to "on".
> 
> It checks for ".git" and then calls git to figure out the build 
> revision.
> 
> Let's turn this off for ports.
> 
> Tested with sysutils/hcloud, net/gomuks and www/reader.
> 
> OK?
> 
> Best Regards,
> Stefan
> 
> Index: lang/go/go.port.mk
> ===================================================================
> RCS file: /cvs/ports/lang/go/go.port.mk,v
> retrieving revision 1.53
> diff -u -p -u -p -r1.53 go.port.mk
> --- lang/go/go.port.mk        28 May 2022 01:46:40 -0000      1.53
> +++ lang/go/go.port.mk        10 Nov 2022 10:41:55 -0000
> @@ -104,7 +104,7 @@ SEPARATE_BUILD ?= Yes
>  CATEGORIES +=                lang/go
>  
>  MODGO_BUILD_TARGET = ${MODGO_BUILD_CMD} ${ALL_TARGET}
> -MODGO_FLAGS +=               -v -p=${MAKE_JOBS}
> +MODGO_FLAGS +=               -v -buildvcs=false -p=${MAKE_JOBS}
>  
>  .if empty(DEBUG)
>  # by default omit symbol table, debug information and DWARF symbol table
> 

Apart from anything else, the build results shouldn't differ depending on
whether git is installed or not (as they might do with the default
buildvcs=auto).

OK

Reply via email to