Skip to content

Commit

Permalink
Fix for build script
Browse files Browse the repository at this point in the history
  • Loading branch information
lkarlslund committed Jan 12, 2024
1 parent b518dd3 commit 0161570
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions build.ps1
Expand Up @@ -15,14 +15,15 @@ function BuildVariants {
$env:GOOS = $currentos

# More sensible naming for x64
if ($currentarch -eq "amd64") {
$currentarch = "x64"
$namearch = $currentarch
if ($namearch -eq "amd64") {
$namearch = "x64"
}

go build -ldflags "$ldflags" -o binaries/$prefix-$currentos-$currentarch-$VERSION$suffix $compileflags $path
go build -ldflags "$ldflags" -o binaries/$prefix-$currentos-$namearch-$VERSION$suffix $compileflags $path
if (Get-Command "cyclonedx-gomod" -ErrorAction SilentlyContinue)
{
cyclonedx-gomod app -json -licenses -output binaries/$prefix-$currentos-$currentarch-$VERSION$suffix.bom.json -main $path .
cyclonedx-gomod app -json -licenses -output binaries/$prefix-$currentos-$namearch-$VERSION$suffix.bom.json -main $path .
}
}
}
Expand Down

0 comments on commit 0161570

Please sign in to comment.