mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-12-28 06:14:26 +03:00
go-modules: Cleanup submodule detection
Also, only build the sources that matter for distribution
This commit is contained in:
parent
fecf412767
commit
1a045673f6
@ -55,12 +55,10 @@ go.stdenv.mkDerivation ( args // {
|
||||
go install $buildFlags "''${buildFlagsArray[@]}" -p $NIX_BUILD_CORES -v $goPackagePath/$p
|
||||
done
|
||||
else
|
||||
find . -type d | while read d; do
|
||||
for i in $d/*.go; do
|
||||
(cd go/src
|
||||
find $goPackagePath -type f -name \*.go -exec dirname {} \; | sort | uniq | while read d; do
|
||||
go install $buildFlags "''${buildFlagsArray[@]}" -p $NIX_BUILD_CORES -v $d
|
||||
break
|
||||
done
|
||||
done
|
||||
done)
|
||||
fi
|
||||
|
||||
runHook postBuild
|
||||
@ -74,12 +72,10 @@ go.stdenv.mkDerivation ( args // {
|
||||
go test -p $NIX_BUILD_CORES -v $goPackagePath/$p
|
||||
done
|
||||
else
|
||||
find . -type d | while read d; do
|
||||
for i in $d/*_test.go; do
|
||||
(cd go/src
|
||||
find $goPackagePath -type f -name \*_test.go -exec dirname {} \; | sort | uniq | while read d; do
|
||||
go test -p $NIX_BUILD_CORES -v $d
|
||||
break
|
||||
done
|
||||
done
|
||||
done)
|
||||
fi
|
||||
|
||||
runHook postCheck
|
||||
|
Loading…
Reference in New Issue
Block a user