forked from rosa/hakurei
For upcoming azalea integration. The API is quite ugly right now to ease migration. Signed-off-by: Ophestra <cat@gensokyo.uk>
42 lines
889 B
Go
42 lines
889 B
Go
package rosa
|
|
|
|
import "hakurei.app/internal/pkg"
|
|
|
|
func (t Toolchain) newZstd(s *S) (pkg.Artifact, string) {
|
|
const (
|
|
version = "1.5.7"
|
|
checksum = "4XhfR7DwVkwo1R-TmYDAJOcx9YXv9WSFhcFUe3hWEAMmdMLPhFaznCqYIA19_xxV"
|
|
)
|
|
return s.NewPackage(t, "zstd", version, newFromGitHubRelease(
|
|
"facebook/zstd",
|
|
"v"+version,
|
|
"zstd-"+version+".tar.gz",
|
|
checksum,
|
|
pkg.TarGzip,
|
|
), &PackageAttr{
|
|
// tests Makefile assumes writable source
|
|
Writable: true,
|
|
Chmod: true,
|
|
}, &CMakeHelper{
|
|
Append: []string{"build", "cmake"},
|
|
Test: `
|
|
make -C /usr/src/zstd/tests datagen
|
|
ZSTD_BIN=/cure/programs/zstd /usr/src/zstd/tests/playTests.sh
|
|
`,
|
|
},
|
|
Make,
|
|
Diffutils,
|
|
), version
|
|
}
|
|
func init() {
|
|
native.MustRegister(&Artifact{
|
|
f: Toolchain.newZstd,
|
|
|
|
Name: "zstd",
|
|
Description: "a fast compression algorithm",
|
|
Website: "https://facebook.github.io/zstd/",
|
|
|
|
ID: 12083,
|
|
})
|
|
}
|