diff --git a/.cursor/environment.json b/.cursor/environment.json new file mode 100644 index 0000000..ebf4ee1 --- /dev/null +++ b/.cursor/environment.json @@ -0,0 +1,4 @@ +{ + "name": "simplybs", + "install": "./.cursor/install.sh" +} diff --git a/.cursor/install.sh b/.cursor/install.sh new file mode 100755 index 0000000..81e3e0d --- /dev/null +++ b/.cursor/install.sh @@ -0,0 +1,49 @@ +#!/usr/bin/env bash +# Idempotent environment bootstrap for simplybs. +# Runs after the repository is checked out. The dev loop is just `go run .`, +# so this only warms the Go module/build caches (which also validates the +# toolchain). go and gh are provided by the base image. +set -euo pipefail + +cd "$(dirname "$0")/.." + +echo "==> go version" +go version + +echo "==> go mod download" +go mod download + +echo "==> go build ./..." +go build ./... + +# --- simplybs cache env vars -------------------------------------------- +# Make the cache settings available to every command on the box. Two places: +# * /etc/environment -> picked up by PAM for all sessions (no shell +# expansion allowed, so we write resolved values). +# * /etc/profile.d/ -> sourced by login shells (keeps the dynamic form). +configure_cache_env() { + local repo="mrcyjanek/simplybs_private" + local tag="v0-sbs-${USER}-$(go env GOOS)-$(go env GOARCH)" + + echo "==> configuring SIMPLYBS_CACHE_* (tag=${tag}, repo=${repo})" + + # /etc/environment: replace any prior entries, then append resolved values. + sudo touch /etc/environment + sudo sed -i '/^SIMPLYBS_CACHE_TAG=/d;/^SIMPLYBS_CACHE_REPO=/d' /etc/environment + printf 'SIMPLYBS_CACHE_TAG=%s\nSIMPLYBS_CACHE_REPO=%s\n' "$tag" "$repo" \ + | sudo tee -a /etc/environment >/dev/null + + # /etc/profile.d: dynamic exports for login shells (safe if go is missing). + sudo tee /etc/profile.d/simplybs-cache.sh >/dev/null <<'EOF' +export SIMPLYBS_CACHE_REPO=mrcyjanek/simplybs_private +if command -v go >/dev/null 2>&1; then + export SIMPLYBS_CACHE_TAG="v0-sbs-${USER}-$(go env GOOS)-$(go env GOARCH)" +else + export SIMPLYBS_CACHE_TAG="v0-sbs-${USER}-linux-amd64" +fi +EOF +} + +configure_cache_env + +echo "==> install complete" diff --git a/.gitignore b/.gitignore index 6e5411a..2afbea0 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,13 @@ .buildlib -*.tar.gz \ No newline at end of file +*.tar.gz +.build +ct-config +.DS_Store +logs + +*.log +*.pid + +# Local Windows Cygwin+clang seed (keep README only) +patches/native/_/windows_amd64_cygwin_clang/** +!patches/native/_/windows_amd64_cygwin_clang/README.md diff --git a/AGENTS.md b/AGENTS.md new file mode 100644 index 0000000..776b3bc --- /dev/null +++ b/AGENTS.md @@ -0,0 +1,104 @@ +# AGENTS.md + +`simplybs` is a cross-compilation build system written in Go. Package definitions +live in `packages/*.json` (and `packages/native/*.json`); patches live in `patches/`. + +## Dev loop + +The tool is run directly from source — there is no separate build step for +day-to-day work: + +```bash +go run . +``` + +Common invocations: + +```bash +go run . -host x86_64-linux-gnu -package zlib -list # show a package + its dep tree +go run . -host x86_64-linux-gnu -package zlib -download # fetch sources (verifies sha256) +go run . -host x86_64-linux-gnu -package zlib -build # build a package (+ its deps) +go run . -world -host -build # build everything for a host +``` + +Supported host triplets are defined in `host/main.go` (e.g. `x86_64-linux-gnu`, +`aarch64-linux-android`, `x86_64-w64-mingw32`, `aarch64-apple-darwin`). + +## rust-std (all platforms) + +`rust-std` builds the Rust standard library (`library/std`, stage 1) for a +given `-host` triplet. **“All platforms”** means every entry in +`host.SupportedHosts` — pass them as a comma-separated `-host` list: + +| `-host` (simplybs triplet) | Rust target (`$RUST_TRIPLET`) | +| --- | --- | +| `x86_64-linux-gnu` | `x86_64-unknown-linux-gnu` | +| `aarch64-linux-gnu` | `aarch64-unknown-linux-gnu` | +| `x86_64-w64-mingw32` | `x86_64-pc-windows-gnu` | +| `aarch64-apple-darwin` | `aarch64-apple-darwin` | +| `x86_64-apple-darwin` | `x86_64-apple-darwin` | +| `aarch64-apple-ios` | `aarch64-apple-ios` | +| `aarch64-apple-ios-simulator` | `aarch64-apple-ios-sim` | +| `aarch64-linux-android` | `aarch64-linux-android` | +| `x86_64-linux-android` | `x86_64-linux-android` | +| `armv7a-linux-androideabi` | `armv7-linux-androideabi` | + +```bash +go run . -host \ + aarch64-apple-darwin,x86_64-apple-darwin,aarch64-apple-ios,aarch64-apple-ios-simulator,\ + x86_64-w64-mingw32,x86_64-linux-gnu,aarch64-linux-gnu,aarch64-linux-android,\ + x86_64-linux-android,armv7a-linux-androideabi \ + -package rust-std -build +``` + +Each host build is independent (separate artifact under `.buildlib/_/built/`). +Requires `native/rust` (and the full native toolchain for that target) to already be built. + +## After editing packages — always run lint + +Whenever you add or change a package definition (new source, new git ref, bumped +version, new dependency, etc.), regenerate metadata and validate with: + +```bash +go run . -lint +``` + +`-lint` reformats every `packages/**.json`, checks for invalid/cyclic +dependencies, and regenerates the checked-in `sources.json`. Commit the resulting +`sources.json` changes together with your package edits. + +To generate git `download` entries from repos you've checked out locally: + +```bash +go run ./cmd/gengitdeps # prints download JSON to stdout +``` + +## Tests + +```bash +go test ./... +``` + +Note: `host.TestHosts` is data-driven from `packages/native/_.json` and may +already fail on a clean checkout — unrelated to environment setup. + +## Tooling + +`go` and `gh` are provided by the base image; there is nothing else to install. + +## Cache environment variables + +`install.sh` exports the shared cache settings box-wide (via `/etc/environment` +and `/etc/profile.d/simplybs-cache.sh`), so every command sees them: + +- `SIMPLYBS_CACHE_TAG=v0-sbs---` (e.g. `v0-sbs-ubuntu-linux-amd64`) +- `SIMPLYBS_CACHE_REPO=mrcyjanek/simplybs_private` + +When both are set, cache is enabled: `-build` auto-pulls needed artifacts and +auto-pushes new/changed ones (see README). Explicit flags: + +```bash +go run . -host x86_64-linux-gnu -package zlib -cache-pull +go run . -host x86_64-linux-gnu -package zlib -build +go run . -host x86_64-linux-gnu -package zlib -cache-push +``` diff --git a/README.md b/README.md index 7381319..5336290 100644 --- a/README.md +++ b/README.md @@ -31,7 +31,7 @@ All package definitions live inside of this repo (this is going to change soon * // (soon) "source" indicationg a package that only contains source code (e.g. that was pulled using custom tools such as `repo` or are too complex for the built in system to handle) "type": "host", // where to find the source code - "download": { + "download": [{ // "tar.gz" indicates a (who wouldn't have guessed) .tar.gz archive that will be extracted before build steps occur // "tar.bz2" indicares a (no way.. is it gonna be..) .tar.bz2 archive that will be extracted.. you get the drill // "git" indicates a Git repository being used @@ -50,24 +50,24 @@ All package definitions live inside of this repo (this is going to change soon * // build all packages recursively but it won't inherit parent dependencies) "*-android*:native/android_ndk", // all is a magic keyword that works just like * - "all:native/make", - "all:native/libtool" + "*:native/make", + "*:native/libtool" ], "build": { "env": [ // same logic as in dependencies applies, most variables are available during this phase (like $PREFIX or $HOST) - "all:CFLAGS=$CFLAGS -fPIC", - "all:config_opts=--prefix=$PREFIX --static", - "all:LIBTOOL=$PREFIX/native/bin/libtool", - "all:CROSS_PREFIX=$HOST-" + "*:CFLAGS=$CFLAGS -fPIC", + "*:config_opts=--prefix=$PREFIX --static", + "*:LIBTOOL=$NATIVEPREFIX/bin/libtool", + "*:CROSS_PREFIX=$HOST-" ], "steps": [ // step-by-step instructions to build the package. - "all:./configure $config_opts", - "all:sed -i.bak s\\|^AR=.*\\|AR=$AR\\|g Makefile", - "all:sed -i.bak s\\|^ARFLAGS=.*\\|ARFLAGS=$ARFLAGS\\|g Makefile", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:./configure $config_opts", + "*:sed -i.bak s\\|^AR=.*\\|AR=$AR\\|g Makefile", + "*:sed -i.bak s\\|^ARFLAGS=.*\\|ARFLAGS=$ARFLAGS\\|g Makefile", + "*:make -j$NUM_CORES", + "*:make DESTDIR=$STAGING_DIR install" ] } } @@ -75,8 +75,54 @@ All package definitions live inside of this repo (this is going to change soon * ## Usage -In order to build, let's say, `libtor` for armv7a-linux-androideabi you would run the following command (on either a Mac or Linux x64 device). +In order to build, let's say, `tor` for armv7a-linux-androideabi you would run the following command (on either a Mac or Linux x64 device). ``` -$ go run . -host armv7a-linux-androideabi -package libtor -build -``` \ No newline at end of file +$ go run . -host armv7a-linux-androideabi -package tor -build +``` + +## Recommended / "official" cache settings + +```bash +SIMPLYBS_ENV_DIR=/opt/_ +``` + +## Build cache (GitHub Releases) + +Built package archives are content-addressed (`package-version-<8-char-hash>`). +They can be shared via a rolling GitHub Release without downloading the whole +cache on every run. + +Cache is enabled only when **both** required variables are set: + +| Variable | Required | Purpose | +| --- | --- | --- | +| `SIMPLYBS_CACHE_TAG` | yes | Release tag (e.g. `v0-sbs-$USER-$GOOS-$GOARCH`) | +| `SIMPLYBS_CACHE_REPO` | yes | `owner/repo` hosting the release | +| `SIMPLYBS_GH` | no | Optional path to `gh` | + +```bash +# export SIMPLYBS_CACHE_TAG=v0-sbs-$USER-$(go env GOOS)-$(go env GOARCH) +# export SIMPLYBS_CACHE_REPO=mrcyjanek/simplybs_private +``` + +With those set, `-build` auto-pulls the needed package tree up front, pulls +per-package inside `EnsureBuilt` as a fallback, pushes each package after a +successful local build, and runs a final tree push for anything still missing +on the release: + +```bash +go run . -host x86_64-linux-gnu -package zlib -build +``` + +Explicit pull/push still work: + +```bash +go run . -host x86_64-linux-gnu -package zlib -cache-pull +go run . -cache-push # all local built/ +go run . -host x86_64-linux-gnu -package zlib -cache-push # that package tree only +``` + +Push only uploads local artifacts that are not already on the release (a +package rebuild with a new hash is a new asset name, so “changed” caches +upload naturally). diff --git a/builder/builder_darwin_arm64.go b/builder/builder_darwin_arm64.go index d4e880e..e647fb2 100644 --- a/builder/builder_darwin_arm64.go +++ b/builder/builder_darwin_arm64.go @@ -1,17 +1 @@ package builder - -var HostBuilder = Builder{ - GlobalEnv: []string{ - "all:HOST=aarch64-apple-darwin", - "all:TARGET=aarch64-apple-darwin", - "all:OSX_MIN_VERSION=10.15", - "all:CC=/usr/bin/clang", - "all:CXX=/usr/bin/clang++", - "all:AR=" + shellOutput("xcrun --sdk macosx --find ar"), - "all:RANLIB=" + shellOutput("xcrun --sdk macosx --find ranlib"), - "all:STRIP=" + shellOutput("xcrun --sdk macosx --find strip"), - "all:NM=" + shellOutput("xcrun --sdk macosx --find nm"), - "all:OTOOL=" + shellOutput("xcrun --sdk macosx --find otool"), - "all:INSTALL_NAME_TOOL=" + shellOutput("xcrun --sdk macosx --find install_name_tool"), - }, -} diff --git a/builder/builder_linux_amd64.go b/builder/builder_linux_amd64.go index 0898bfa..e647fb2 100644 --- a/builder/builder_linux_amd64.go +++ b/builder/builder_linux_amd64.go @@ -1,17 +1 @@ package builder - -var HostBuilder = Builder{ - GlobalEnv: []string{ - "all:HOST=x86_64-linux-gnu", - "all:TARGET=x86_64-linux-gnu", - "all:CC=clang", - "all:CXX=clang++", - "all:AR=ar", - "all:RANLIB=ranlib", - "all:STRIP=strip", - "all:NM=nm", - "all:OTOOL=otool", - "all:AUTOMAKE=automake", - "all:INSTALL_NAME_TOOL=install_name_tool", - }, -} diff --git a/builder/builder_linux_arm64.go b/builder/builder_linux_arm64.go index 8816f60..e647fb2 100644 --- a/builder/builder_linux_arm64.go +++ b/builder/builder_linux_arm64.go @@ -1,17 +1 @@ package builder - -var HostBuilder = Builder{ - GlobalEnv: []string{ - "all:HOST=aarch64-linux-gnu", - "all:TARGET=aarch64-linux-gnu", - "all:CC=clang", - "all:CXX=clang++", - "all:AR=ar", - "all:RANLIB=ranlib", - "all:STRIP=strip", - "all:NM=nm", - "all:OTOOL=otool", - "all:AUTOMAKE=automake", - "all:INSTALL_NAME_TOOL=install_name_tool", - }, -} diff --git a/builder/builder_windows_amd64.go b/builder/builder_windows_amd64.go new file mode 100644 index 0000000..e647fb2 --- /dev/null +++ b/builder/builder_windows_amd64.go @@ -0,0 +1 @@ +package builder diff --git a/builder/default.go b/builder/default.go index 632cccd..729697a 100644 --- a/builder/default.go +++ b/builder/default.go @@ -1,20 +1,28 @@ package builder import ( - "os/exec" - "strings" + "log" + "runtime" ) -type Builder struct { - GlobalEnv []string +func GetName() string { + return runtime.GOOS + "_" + runtime.GOARCH } -var Builders = []string{"darwin_arm64", "linux_amd64", "linux_arm64"} - -func shellOutput(cmd string) string { - output, err := exec.Command("bash", "-c", cmd).Output() - if err != nil { - return "$(" + cmd + ")" +func NativeTriplet() string { + switch GetName() { + case "darwin_arm64": + return "aarch64-apple-darwin" + case "linux_amd64": + return "x86_64-linux-gnu" + case "linux_arm64": + return "aarch64-linux-gnu" + case "windows_amd64": + return "x86_64-pc-cygwin" + default: + log.Fatalf("unknown builder: %s", GetName()) + return "" } - return strings.TrimSpace(string(output)) } + +var Builders = []string{"darwin_arm64", "linux_amd64", "linux_arm64", "windows_amd64"} diff --git a/cmd/archive/archive.go b/cmd/archive/archive.go new file mode 100644 index 0000000..70be08b --- /dev/null +++ b/cmd/archive/archive.go @@ -0,0 +1,40 @@ +package archive + +import ( + "log" + "sort" + + "github.com/mrcyjanek/simplybs/crash" + "github.com/mrcyjanek/simplybs/utils" + "github.com/mrcyjanek/simplybs/utils/download" +) + +func Archive() { + sources, err := utils.LoadSourcesFile() + crash.Handle(err) + + repoURLs := make([]string, 0, len(sources.Repositories)) + for url := range sources.Repositories { + repoURLs = append(repoURLs, url) + } + sort.Strings(repoURLs) + + for i, url := range repoURLs { + log.Printf("Ensuring git bundle %d/%d: %s", i+1, len(repoURLs), url) + bundlePath := utils.SourcePathForGitURL(url) + if err := utils.EnsureGitBundle(bundlePath, url); err != nil { + log.Fatalf("Failed to ensure git bundle for %s: %v", url, err) + } + } + + downloads := utils.UniqueDownloads(sources.Downloads) + for i, entry := range downloads { + log.Printf("Ensuring download %d/%d: %s", i+1, len(downloads), entry.URL) + path := utils.SourcePathForFileURL(entry.URL) + if err := download.EnsureDownloadFile("archive", path, entry.URL, entry.Sha256); err != nil { + log.Fatalf("Failed to download %s: %v", entry.URL, err) + } + } + + log.Printf("Archive complete: %d git repos, %d unique downloads", len(repoURLs), len(downloads)) +} diff --git a/cmd/buildweb/builder_matrix.tpl b/cmd/buildweb/builder_matrix.tpl deleted file mode 100644 index 5c03b04..0000000 --- a/cmd/buildweb/builder_matrix.tpl +++ /dev/null @@ -1,178 +0,0 @@ - - - - {{.Builder}} Build Matrix - - - -
- ← Back to Package List - -

{{.Builder}} Build Matrix

-

Builder: {{.Builder}} | Total packages: {{len .Packages}}

- -
- - - - - {{range getTargets}} - - {{end}} - - - - {{range .Packages}} - {{$pkg := .}} - - - {{range getTargets}} - {{$target := .}} - {{$found := false}} - {{range $pkg.BuiltFiles}} - {{if and (eq .Builder $.Builder) (eq .Target $target)}} - {{$found = true}} - - {{end}} - {{end}} - {{if not $found}} - - {{end}} - {{end}} - - {{end}} - -
Package{{.}}
- {{.Package.Package}} - - - ✓ - - - - ✗ - -
-
-
- - \ No newline at end of file diff --git a/cmd/buildweb/buildweb.go b/cmd/buildweb/buildweb.go deleted file mode 100644 index fec5bc7..0000000 --- a/cmd/buildweb/buildweb.go +++ /dev/null @@ -1,466 +0,0 @@ -package buildweb - -import ( - "archive/tar" - "compress/gzip" - "fmt" - "html/template" - "io" - "log" - "os" - "path/filepath" - "runtime" - "sort" - "strings" - "sync" - - _ "embed" - - "github.com/mrcyjanek/simplybs/builder" - "github.com/mrcyjanek/simplybs/crash" - "github.com/mrcyjanek/simplybs/host" - "github.com/mrcyjanek/simplybs/pack" -) - -func getGlobPattern(entry string) string { - if strings.Contains(entry, ":") { - parts := strings.SplitN(entry, ":", 2) - return parts[0] - } - return "" -} - -func getGlobContent(entry string) string { - if strings.Contains(entry, ":") { - parts := strings.SplitN(entry, ":", 2) - return parts[1] - } - return entry -} - -func dependencyExists(dep string, packages []*pack.Package) bool { - for _, pkg := range packages { - if pkg.Package == dep { - return true - } - } - return false -} - -func formatFileSize(bytes int64) string { - const unit = 1024 - if bytes < unit { - return fmt.Sprintf("%d B", bytes) - } - div, exp := int64(unit), 0 - for n := bytes / unit; n >= unit; n /= unit { - div *= unit - exp++ - } - return fmt.Sprintf("%.1f %cB", float64(bytes)/float64(div), "KMGTPE"[exp]) -} - -type ArchiveFileInfo struct { - Name string - Size int64 -} - -func listArchiveContents(archivePath string) ([]ArchiveFileInfo, error) { - file, err := os.Open(archivePath) - if err != nil { - return nil, err - } - defer file.Close() - - gzReader, err := gzip.NewReader(file) - if err != nil { - return nil, err - } - defer gzReader.Close() - - tarReader := tar.NewReader(gzReader) - var files []ArchiveFileInfo - - for { - header, err := tarReader.Next() - if err == io.EOF { - break - } - if err != nil { - return nil, err - } - - if header.Typeflag == tar.TypeReg { - files = append(files, ArchiveFileInfo{ - Name: header.Name, - Size: header.Size, - }) - } - } - - return files, nil -} - -func scanBuiltFilesAllPlatforms(packageName string, packageVersion string) []pack.BuiltFile { - var builtFiles []pack.BuiltFile - baseBuildDir := host.DataDirRoot() - - targets := make([]string, 0, len(host.SupportedHosts)) - for k := range host.SupportedHosts { - targets = append(targets, k) - } - - for _, builderName := range builder.Builders { - builderDir := filepath.Join(baseBuildDir, builderName) - if _, err := os.Stat(builderDir); os.IsNotExist(err) { - continue - } - - for _, target := range targets { - buildOutputDir := filepath.Join(builderDir, "built", target, packageName) - buildOutputDir = filepath.Dir(buildOutputDir) - - if _, err := os.Stat(buildOutputDir); os.IsNotExist(err) { - continue - } - - files, err := os.ReadDir(buildOutputDir) - if err != nil { - continue - } - - for _, file := range files { - fileName := file.Name() - fsFilepath := filepath.Join(buildOutputDir, fileName) - if !strings.Contains(fsFilepath, packageName) { - continue - } - if !strings.HasSuffix(fileName, ".tar.gz") { - continue - } - - nameWithoutExt := strings.TrimSuffix(fileName, ".tar.gz") - parts := strings.Split(nameWithoutExt, "-") - if len(parts) < 3 { - continue - } - - archPathRelative := filepath.Join(builderName, "built", target, filepath.Dir(packageName), fileName) - infoPathRelative := filepath.Join(builderName, "built", target, filepath.Dir(packageName), strings.TrimSuffix(fileName, ".tar.gz")+".info.txt") - - fullArchPath := filepath.Join(baseBuildDir, archPathRelative) - info, err := os.Stat(fullArchPath) - var fileSize int64 - if err == nil { - fileSize = info.Size() - } - id := strings.Split(parts[len(parts)-1], ".")[0] - - builtFiles = append(builtFiles, pack.BuiltFile{ - Builder: builderName, - Target: target, - ID: id, - InfoPath: infoPathRelative, - ArchPath: archPathRelative, - FileSize: fileSize, - }) - } - } - } - - return builtFiles -} - -func getAllPackagesWithBuildsAllPlatforms() []*pack.PackageWithBuilds { - packages := pack.GetAllPackages() - packagesWithBuilds := make([]*pack.PackageWithBuilds, len(packages)) - - for i, pkg := range packages { - builtFiles := scanBuiltFilesAllPlatforms(pkg.Package, pkg.Version) - packagesWithBuilds[i] = &pack.PackageWithBuilds{ - Package: pkg, - BuiltFiles: builtFiles, - } - } - - return packagesWithBuilds -} - -func BuildWeb() { - - webDir := filepath.Join(host.DataDirRoot(), "web") - - if _, err := os.Stat(webDir); !os.IsNotExist(err) { - err := os.RemoveAll(webDir) - crash.Handle(err) - } - err := os.MkdirAll(webDir, 0755) - crash.Handle(err) - - packagesWithBuilds := getAllPackagesWithBuildsAllPlatforms() - - for i, pkg := range packagesWithBuilds { - builderTargetMap := make(map[string]pack.BuiltFile) - for _, builtFile := range pkg.BuiltFiles { - key := builtFile.Builder + "/" + builtFile.Target - if _, exists := builderTargetMap[key]; !exists { - builderTargetMap[key] = builtFile - } - } - - var filteredBuilds []pack.BuiltFile - for _, builtFile := range builderTargetMap { - filteredBuilds = append(filteredBuilds, builtFile) - } - packagesWithBuilds[i].BuiltFiles = filteredBuilds - } - - packages := make([]*pack.Package, len(packagesWithBuilds)) - for i, pwb := range packagesWithBuilds { - packages[i] = pwb.Package - } - - funcMap := template.FuncMap{ - "getGlobPattern": getGlobPattern, - "getGlobContent": getGlobContent, - "depExists": func(dep string) bool { - return dependencyExists(dep, packages) - }, - "getRelativePath": func(fromPackage, toPackage string) string { - fromDepth := strings.Count(fromPackage, "/") - upPath := strings.Repeat("../", fromDepth) - if toPackage == "index" { - return upPath + "index.html" - } - return upPath + toPackage + ".html" - }, - "formatFileSize": formatFileSize, - "getMirrorPath": func(pkg *pack.PackageWithBuilds) string { - packageDepth := strings.Count(pkg.Package.Package, "/") - upPath := strings.Repeat("../", packageDepth+1) // +1 to get out of web directory - - return fmt.Sprintf("%ssource/%s-%s.%s", upPath, pkg.Package.Package, pkg.Package.Version, pkg.Package.Download.Kind) - }, - "getBuiltFilePath": func(packageName, filePath string) string { - packageDepth := strings.Count(packageName, "/") - upPath := strings.Repeat("../", packageDepth+1) // +1 to get out of web directory - return upPath + filePath - }, - "getBuildMatrix": func(pkg *pack.PackageWithBuilds) map[string]map[string]*pack.BuiltFile { - builders := make([]string, len(builder.Builders)) - copy(builders, builder.Builders) - sort.Strings(builders) - - targets := make([]string, 0, len(host.SupportedHosts)) - for k := range host.SupportedHosts { - targets = append(targets, k) - } - sort.Strings(targets) - - matrix := make(map[string]map[string]*pack.BuiltFile) - for _, builder := range builders { - matrix[builder] = make(map[string]*pack.BuiltFile) - for _, target := range targets { - matrix[builder][target] = nil - } - } - - for i := range pkg.BuiltFiles { - bf := &pkg.BuiltFiles[i] - if matrix[bf.Builder] != nil { - matrix[bf.Builder][bf.Target] = bf - } - } - - return matrix - }, - "getBuilders": func() []string { - builders := make([]string, len(builder.Builders)) - copy(builders, builder.Builders) - sort.Strings(builders) - return builders - }, - "getTargets": func() []string { - targets := make([]string, 0, len(host.SupportedHosts)) - for k := range host.SupportedHosts { - targets = append(targets, k) - } - sort.Strings(targets) - return targets - }, - "getBuildProgress": func(pkg *pack.PackageWithBuilds) int { - totalCombinations := len(builder.Builders) * len(host.SupportedHosts) - if totalCombinations == 0 { - return 0 - } - - actualBuilds := len(pkg.BuiltFiles) - return (actualBuilds * 100) / totalCombinations - }, - } - - log.Printf("Generating index page...") - generateIndexPage(packagesWithBuilds, webDir, funcMap) - - log.Printf("Generating %d package pages...", len(packagesWithBuilds)) - for i, pkgWithBuilds := range packagesWithBuilds { - log.Printf("\tProgress: %d/%d packages\n", i+1, len(packagesWithBuilds)) - generatePackagePage(pkgWithBuilds, webDir, funcMap) - } - - log.Printf("Generating %d builder matrix pages...\n", len(builder.Builders)) - for i, builderName := range builder.Builders { - log.Printf("\tGenerating matrix for %s (%d/%d)\n", builderName, i+1, len(builder.Builders)) - generateBuilderMatrixPage(builderName, packagesWithBuilds, webDir, funcMap) - } - - totalFiles := 0 - for _, pkgWithBuilds := range packagesWithBuilds { - totalFiles += len(pkgWithBuilds.BuiltFiles) - } - - log.Printf("Generating %d file detail pages...\n", totalFiles) - fileCount := 0 - wg := sync.WaitGroup{} - semaphore := make(chan struct{}, runtime.NumCPU()) - for _, pkgWithBuilds := range packagesWithBuilds { - for _, builtFile := range pkgWithBuilds.BuiltFiles { - fileCount++ - log.Printf("\tProgress: %d/%d file pages\n", fileCount, totalFiles) - wg.Add(1) - semaphore <- struct{}{} - go func(pkgWithBuilds *pack.PackageWithBuilds, builtFile pack.BuiltFile) { - defer wg.Done() - generateFilePage(pkgWithBuilds, &builtFile, webDir, funcMap) - <-semaphore - }(pkgWithBuilds, builtFile) - } - } - - wg.Wait() - - log.Printf("Generated static website with %d packages, %d builder matrices, and %d file details in %s\n", len(packages), len(builder.Builders), totalFiles, webDir) -} - -//go:embed index.tpl -var indexTemplate string - -func generateIndexPage(packagesWithBuilds []*pack.PackageWithBuilds, webDir string, funcMap template.FuncMap) { - - tmpl, err := template.New("index").Funcs(funcMap).Parse(indexTemplate) - crash.Handle(err) - - file, err := os.Create(filepath.Join(webDir, "index.html")) - crash.Handle(err) - defer file.Close() - - err = tmpl.Execute(file, packagesWithBuilds) - crash.Handle(err) -} - -//go:embed package.tpl -var packageTemplate string - -func generatePackagePage(pkgWithBuilds *pack.PackageWithBuilds, webDir string, funcMap template.FuncMap) { - funcMap["add"] = func(a, b int) int { - return a + b - } - - tmpl, err := template.New("package").Funcs(funcMap).Parse(packageTemplate) - crash.Handle(err) - - path := filepath.Join(webDir, pkgWithBuilds.Package.Package+".html") - err = os.MkdirAll(filepath.Dir(path), 0755) - crash.Handle(err) - - file, err := os.Create(path) - crash.Handle(err) - defer file.Close() - - err = tmpl.Execute(file, pkgWithBuilds) - crash.Handle(err) -} - -//go:embed builder_matrix.tpl -var builderMatrixTemplate string - -func generateBuilderMatrixPage(builderName string, packagesWithBuilds []*pack.PackageWithBuilds, webDir string, funcMap template.FuncMap) { - tmpl, err := template.New("builder_matrix").Funcs(funcMap).Parse(builderMatrixTemplate) - crash.Handle(err) - - path := filepath.Join(webDir, "builder_"+builderName+".html") - err = os.MkdirAll(filepath.Dir(path), 0755) - crash.Handle(err) - - file, err := os.Create(path) - crash.Handle(err) - defer file.Close() - - data := struct { - Builder string - Packages []*pack.PackageWithBuilds - }{ - Builder: builderName, - Packages: packagesWithBuilds, - } - - err = tmpl.Execute(file, data) - crash.Handle(err) -} - -//go:embed file_details.tpl -var fileDetailsTemplate string - -type ArchiveInfo struct { - Files []ArchiveFileInfo - TotalSize int64 -} - -var filePageMutex sync.Mutex - -var funcMapMutex sync.Mutex - -func generateFilePage(pkg *pack.PackageWithBuilds, builtFile *pack.BuiltFile, webDir string, funcMap template.FuncMap) { - funcMapMutex.Lock() - funcMap["getArchiveInfo"] = func(archPath string) ArchiveInfo { - baseBuildDir := host.DataDirRoot() - fullPath := filepath.Join(baseBuildDir, archPath) - files, err := listArchiveContents(fullPath) - if err != nil { - return ArchiveInfo{Files: []ArchiveFileInfo{}, TotalSize: 0} - } - - var totalSize int64 - for _, file := range files { - totalSize += file.Size - } - - return ArchiveInfo{Files: files, TotalSize: totalSize} - } - funcMapMutex.Unlock() - - filePageMutex.Lock() - tmpl, err := template.New("file_details").Funcs(funcMap).Parse(fileDetailsTemplate) - crash.Handle(err) - filePageMutex.Unlock() - - fileName := fmt.Sprintf("%s-%s-%s.html", pkg.Package.Package, pkg.Package.Version, builtFile.ID) - path := filepath.Join(webDir, "files", builtFile.Builder, builtFile.Target, fileName) - err = os.MkdirAll(filepath.Dir(path), 0755) - crash.Handle(err) - - file, err := os.Create(path) - crash.Handle(err) - defer file.Close() - - data := struct { - Package *pack.PackageWithBuilds - BuiltFile *pack.BuiltFile - }{ - Package: pkg, - BuiltFile: builtFile, - } - - err = tmpl.Execute(file, data) - crash.Handle(err) -} diff --git a/cmd/buildweb/file_details.tpl b/cmd/buildweb/file_details.tpl deleted file mode 100644 index 2534998..0000000 --- a/cmd/buildweb/file_details.tpl +++ /dev/null @@ -1,244 +0,0 @@ - - - - {{.Package.Package.Package}} - {{.BuiltFile.Builder}}/{{.BuiltFile.Target}} Archive Contents - - - -
- ← Back to Package - ← Back to {{.BuiltFile.Builder}} - -

{{.Package.Package.Package}}

-
- {{.BuiltFile.Builder}} - {{.BuiltFile.Target}} -
- - - -
-

Build Information

- - - - - - - -
Package{{.Package.Package.Package}}
Version{{.Package.Package.Version}}
Builder{{.BuiltFile.Builder}}
Target{{.BuiltFile.Target}}
Build ID{{.BuiltFile.ID}}
Archive Size{{formatFileSize .BuiltFile.FileSize}}
-
- -
-

Archive Contents

- {{$archiveInfo := getArchiveInfo .BuiltFile.ArchPath}} - {{if $archiveInfo.Files}} -
-
{{len $archiveInfo.Files}} files in archive
-
- Total uncompressed size: {{formatFileSize $archiveInfo.TotalSize}} -
-
-
-
-
File Path
-
Size
-
- {{range $archiveInfo.Files}} -
-
{{.Name}}
-
{{formatFileSize .Size}}
-
- {{end}} -
- {{else}} -
-
Unable to read archive contents
-
Archive may be corrupted or use an unsupported format
-
- {{end}} -
-
- - \ No newline at end of file diff --git a/cmd/buildweb/index.tpl b/cmd/buildweb/index.tpl deleted file mode 100644 index 1dfe04c..0000000 --- a/cmd/buildweb/index.tpl +++ /dev/null @@ -1,134 +0,0 @@ - - - - Package Information - - - -
-

Package Information

-

Total packages: {{len .}}

- -
-

Builder Matrices

-
- {{range getBuilders}} - {{.}} - {{end}} -
-
- - - - - - - - - {{range .}} - - - - - - - - {{end}} -
PackageVersionTypeBuild ProgressDetails
{{.Package.Package}}{{.Package.Version}} - {{.Package.Type}} - - {{$progress := getBuildProgress .}} -
-
-
{{$progress}}%
-
-
View Details →
-
- -` \ No newline at end of file diff --git a/cmd/buildweb/package.tpl b/cmd/buildweb/package.tpl deleted file mode 100644 index fc8aad0..0000000 --- a/cmd/buildweb/package.tpl +++ /dev/null @@ -1,513 +0,0 @@ - - - - {{.Package.Package}} - Package Details - - - -
- ← Back to Package List - -

{{.Package.Package}}

- -
-

Basic Information

- - - - -
Package Name{{.Package.Package}}
Version{{.Package.Version}}
Type{{.Package.Type}}
-
- -
-

Source Download

- - - - -
Kind{{.Package.Download.Kind}}
URL{{.Package.Download.URL}}
SHA256{{.Package.Download.Sha256}}
-
- - {{if .Package.Dependencies}} -
-

Dependencies Explorer

-
- {{range .Package.Dependencies}} - {{$pattern := getGlobPattern .}} - {{$dep := getGlobContent .}} -
-
- {{if $pattern}} - {{$pattern}} - {{else}} - all - {{end}} -
-
- {{if depExists $dep}} - {{$dep}} - {{else}} - {{$dep}} - {{end}} -
-
- {{end}} -
-
- {{end}} - - {{if .Package.Build.Env}} -
-

Build Environment

-
- {{range .Package.Build.Env}} - {{$pattern := getGlobPattern .}} - {{$content := getGlobContent .}} -
-
- {{if $pattern}} - {{$pattern}} - {{else}} - all - {{end}} -
-
- {{$content}} -
-
- {{end}} -
-
- {{end}} - - {{if .Package.Build.Steps}} -
-

Build Steps

-
- {{range $index, $step := .Package.Build.Steps}} - {{$pattern := getGlobPattern $step}} - {{$content := getGlobContent $step}} -
-
{{add $index 1}}.
-
- {{if $pattern}} - {{$pattern}} - {{else}} - all - {{end}} -
-
- {{$content}} -
-
- {{end}} -
-
- {{end}} - -
-

Build Matrix

-
- - - - - {{range getBuilders}} - - {{end}} - - - - {{$matrix := getBuildMatrix .}} - {{range getTargets}} - {{$target := .}} - - - {{range getBuilders}} - {{$builder := .}} - {{$build := index (index $matrix $builder) $target}} - - {{end}} - - {{end}} - -
Target / Builder{{.}}
{{$target}} - {{if $build}} - - ✓ - - {{else}} - - ✗ - - {{end}} -
-
-
- - {{if .BuiltFiles}} -
-

Available Downloads

-
- {{range .BuiltFiles}} -
-
-
{{.Target}}
-
{{.Builder}}
-
-
-
- Size: - {{formatFileSize .FileSize}} -
-
- Build ID: - {{.ID}} -
-
- -
- {{end}} -
-
- {{end}} - -
- - \ No newline at end of file diff --git a/cmd/gengitdeps/go.mod b/cmd/gengitdeps/go.mod new file mode 100644 index 0000000..a449114 --- /dev/null +++ b/cmd/gengitdeps/go.mod @@ -0,0 +1,3 @@ +module github.com/mrcyjanek/simplybs/cmd/gengitdeps + +go 1.25.2 diff --git a/cmd/gengitdeps/main.go b/cmd/gengitdeps/main.go new file mode 100644 index 0000000..989ba97 --- /dev/null +++ b/cmd/gengitdeps/main.go @@ -0,0 +1,155 @@ +package main + +import ( + "encoding/json" + "fmt" + "os" + "os/exec" + "path/filepath" + "strings" +) + +type Download struct { + Kind string `json:"kind"` + Path string `json:"path,omitempty"` + SHA256 string `json:"sha256"` + URL string `json:"url"` +} + +type Output struct { + Download []Download `json:"download"` +} + +func main() { + currentDir, err := os.Getwd() + if err != nil { + fmt.Fprintf(os.Stderr, "Error getting current directory: %v\n", err) + os.Exit(1) + } + + var downloads []Download + + // Walk the directory tree + err = filepath.Walk(currentDir, func(path string, info os.FileInfo, err error) error { + if err != nil { + return err + } + + // Check if this is a .git directory (or symlink to one) + if info.Name() == ".git" { + // Check if it's a directory or a symlink to a directory + isGitDir := info.IsDir() + if !isGitDir && info.Mode()&os.ModeSymlink != 0 { + // It's a symlink, check if it points to a directory + target, err := os.Stat(path) + if err == nil && target.IsDir() { + isGitDir = true + } + } + + if !isGitDir { + return filepath.SkipDir + } + + // Get the repository directory (parent of .git) + repoDir := filepath.Dir(path) + + // Get git commit hash + commitHash, err := getGitCommit(repoDir) + if err != nil { + fmt.Fprintf(os.Stderr, "Warning: Could not get commit for %s: %v\n", repoDir, err) + return filepath.SkipDir + } + + // Get git remote URL + remoteURL, err := getGitRemoteURL(repoDir) + if err != nil { + fmt.Fprintf(os.Stderr, "Warning: Could not get remote URL for %s: %v\n", repoDir, err) + return filepath.SkipDir + } + + // Calculate relative path from current directory + relPath, err := filepath.Rel(currentDir, repoDir) + if err != nil { + fmt.Fprintf(os.Stderr, "Warning: Could not get relative path for %s: %v\n", repoDir, err) + return filepath.SkipDir + } + + download := Download{ + Kind: "git", + SHA256: commitHash, + URL: remoteURL, + } + + // Add path only if it's not the current directory + if relPath != "." { + download.Path = relPath + } + + downloads = append(downloads, download) + + // Skip further traversal into this .git directory + return filepath.SkipDir + } + + return nil + }) + + if err != nil { + fmt.Fprintf(os.Stderr, "Error walking directory: %v\n", err) + os.Exit(1) + } + + // Output JSON + output := Output{Download: downloads} + encoder := json.NewEncoder(os.Stdout) + encoder.SetIndent("", " ") + if err := encoder.Encode(output); err != nil { + fmt.Fprintf(os.Stderr, "Error encoding JSON: %v\n", err) + os.Exit(1) + } +} + +func getGitCommit(repoDir string) (string, error) { + cmd := exec.Command("git", "rev-parse", "HEAD") + cmd.Dir = repoDir + output, err := cmd.Output() + if err != nil { + return "", err + } + return strings.TrimSpace(string(output)), nil +} + +func getGitRemoteURL(repoDir string) (string, error) { + // Try origin first + cmd := exec.Command("git", "config", "--get", "remote.origin.url") + cmd.Dir = repoDir + output, err := cmd.Output() + if err == nil { + return strings.TrimSpace(string(output)), nil + } + + // If origin doesn't exist, get the first available remote + cmd = exec.Command("git", "remote") + cmd.Dir = repoDir + output, err = cmd.Output() + if err != nil { + return "", err + } + + remotes := strings.Split(strings.TrimSpace(string(output)), "\n") + if len(remotes) == 0 || remotes[0] == "" { + return "", fmt.Errorf("no remotes found") + } + + // Get the URL of the first remote + firstRemote := remotes[0] + cmd = exec.Command("git", "config", "--get", fmt.Sprintf("remote.%s.url", firstRemote)) + cmd.Dir = repoDir + output, err = cmd.Output() + if err != nil { + return "", err + } + + return strings.TrimSpace(string(output)), nil +} diff --git a/cmd/lint/lint.go b/cmd/lint/lint.go index a8676b7..d6214f2 100644 --- a/cmd/lint/lint.go +++ b/cmd/lint/lint.go @@ -6,29 +6,31 @@ import ( "log" "os" "path/filepath" - "sort" "strings" + "github.com/mrcyjanek/simplybs/builder" "github.com/mrcyjanek/simplybs/crash" "github.com/mrcyjanek/simplybs/host" "github.com/mrcyjanek/simplybs/pack" - "github.com/ryanuber/go-glob" + "github.com/mrcyjanek/simplybs/utils" + "github.com/mrcyjanek/simplybs/utils/ifstring" ) type OrderedPackage struct { - Package string `json:"package"` - Version string `json:"version"` - Type string `json:"type"` - Download map[string]interface{} `json:"download,omitempty"` - Dependencies []string `json:"dependencies,omitempty"` - Patches []string `json:"patches,omitempty"` - Build map[string]interface{} `json:"build,omitempty"` + Package string `json:"package"` + Version string `json:"version"` + Type string `json:"type"` + Download []map[string]interface{} `json:"download,omitempty"` + Dependencies []string `json:"dependencies,omitempty"` + Patches []string `json:"patches,omitempty"` + ExportEnv *[]string `json:"export-env,omitempty"` + Build map[string]interface{} `json:"build,omitempty"` } func Lint() { fixFormatting() ensureSaneDependencies() - + createSourcesFile() } func fixFormatting() { @@ -61,28 +63,21 @@ func fixFormatting() { if v, ok := data["type"].(string); ok { ordered.Type = v } - if v, ok := data["download"].(map[string]interface{}); ok { - ordered.Download = v + if v, ok := data["download"].([]interface{}); ok { + ordered.Download = make([]map[string]interface{}, len(v)) + for i, download := range v { + if m, ok := download.(map[string]interface{}); ok { + ordered.Download[i] = m + } + } } if v, ok := data["dependencies"].([]interface{}); ok { - nativeDeps := []string{} - otherDeps := []string{} - + ordered.Dependencies = make([]string, 0, len(v)) for _, dep := range v { if s, ok := dep.(string); ok { - parts := strings.Split(s, ":") - depName := parts[len(parts)-1] - if strings.HasPrefix(depName, "native") { - nativeDeps = append(nativeDeps, s) - } else { - otherDeps = append(otherDeps, s) - } + ordered.Dependencies = append(ordered.Dependencies, s) } } - - sort.Strings(nativeDeps) - sort.Strings(otherDeps) - ordered.Dependencies = append(nativeDeps, otherDeps...) } if v, ok := data["patches"].([]interface{}); ok { patches := make([]string, len(v)) @@ -93,15 +88,23 @@ func fixFormatting() { } ordered.Patches = patches } + if _, exists := data["export-env"]; exists { + exportEnv := []string{} + if v, ok := data["export-env"].([]interface{}); ok { + for _, env := range v { + if s, ok := env.(string); ok { + exportEnv = append(exportEnv, s) + } + } + } + ordered.ExportEnv = &exportEnv + } if v, ok := data["build"].(map[string]interface{}); ok { ordered.Build = v } var buf bytes.Buffer - encoder := json.NewEncoder(&buf) - encoder.SetEscapeHTML(false) - encoder.SetIndent("", " ") - err = encoder.Encode(ordered) + err = utils.NewIndentedEncoder(&buf).Encode(ordered) crash.Handle(err) contentNew := bytes.TrimSuffix(buf.Bytes(), []byte("\n")) @@ -137,24 +140,28 @@ func ensureValidName(pkg *pack.Package) { func ensureValidDependencies(pkg *pack.Package) { for _, dep := range pkg.Dependencies { - split := strings.Split(dep, ":") - if len(split) <= 1 { - log.Printf("Package %s has invalid dependency %s", pkg.Package, dep) - continue - } - prefix := split[0] + is := ifstring.ParseIfString(dep) usedIn := 0 for _, host := range host.SupportedHosts { - if glob.Glob(prefix, host.Triplet) { + if is.HostGlob().Match(host.Triplet) { usedIn++ } } - if usedIn == 0 && prefix != "all" && prefix != "none" { - log.Printf("Package %s is not used in any of host.SupportedHosts %s", pkg.Package, prefix) + usedInBuilder := 0 + for _, b := range builder.Builders { + if is.BuilderGlob().Match(b) { + usedInBuilder++ + } + } + if usedIn == 0 && is.Host != "none" { + log.Printf("Package %s is not used in any of host.SupportedHosts %s", pkg.Package, is.Host) + } + if usedInBuilder == 0 && is.Builder != "none" { + log.Printf("Package %s is not used in any of builder.Builders %s", pkg.Package, is.Builder) } - _, err := pack.FindPackage(split[1]) + _, err := pack.FindPackage(is.Content) if err != nil { log.Printf("Package %s has invalid dependency %s: %v", pkg.Package, dep, err) } @@ -178,15 +185,11 @@ func checkCyclesForHost(pkgs []*pack.Package, hostTriplet string) { for _, dep := range pkg.Dependencies { var actualDep string - if strings.Contains(dep, ":") { - prefix := strings.Split(dep, ":")[0] - if !glob.Glob(prefix, hostTriplet) && prefix != "all" { - continue - } - actualDep = dep[strings.Index(dep, ":")+1:] - } else { - actualDep = dep + is := ifstring.ParseIfString(dep) + if is.HostGlob().Match(hostTriplet) { + continue } + actualDep = is.Content graph[pkg.Package] = append(graph[pkg.Package], actualDep) } } @@ -235,3 +238,65 @@ func dfsCycleDetection(packageName string, graph map[string][]string, color map[ color[packageName] = 2 return false } + +func createSourcesFile() { + log.Println("Creating sources.json file...") + sources, err := utils.LoadSourcesFile() + if err != nil { + if os.IsNotExist(err) { + sources = utils.NewSourcesFile() + } else { + log.Fatalf("Failed to load sources.json: %v", err) + } + } else if sources.Repositories == nil { + sources.Repositories = make(map[string]utils.RepositoryInfo) + } + + currentRefs := 0 + currentDownloads := 0 + + pkgs := pack.GetAllPackages() + for _, pkg := range pkgs { + content, err := os.ReadFile(filepath.Join(host.GetPackagesDir(), pkg.Package+".json")) + if err != nil { + log.Printf("Failed to read package %s: %v", pkg.Package, err) + continue + } + + beforeRefs := utils.CountGitRefs(sources) + beforeDownloads := len(sources.Downloads) + utils.MergeDownloadsFromJSON(sources, content) + currentRefs += utils.CountGitRefs(sources) - beforeRefs + currentDownloads += len(sources.Downloads) - beforeDownloads + } + + beforeHistoricRefs := utils.CountGitRefs(sources) + beforeHistoricDownloads := len(sources.Downloads) + + if err := utils.CollectHistoricDownloads(sources); err != nil { + log.Printf("Warning: historic source collection skipped: %v", err) + } + + historicRefs := utils.CountGitRefs(sources) - beforeHistoricRefs + historicDownloads := len(sources.Downloads) - beforeHistoricDownloads + + sourcesJSON, err := utils.MarshalSourcesFile(sources) + if err != nil { + log.Fatalf("Failed to marshal sources.json: %v", err) + } + + if err := os.WriteFile("sources.json", sourcesJSON, 0644); err != nil { + log.Fatalf("Failed to write sources.json: %v", err) + } + + log.Printf( + "Created sources.json with %d repositories (%d git refs, %d downloads); current packages added %d refs and %d downloads, history added %d refs and %d downloads", + len(sources.Repositories), + utils.CountGitRefs(sources), + len(sources.Downloads), + currentRefs, + currentDownloads, + historicRefs, + historicDownloads, + ) +} diff --git a/cmd/release/main.go b/cmd/release/main.go index 4555afe..a153f7e 100644 --- a/cmd/release/main.go +++ b/cmd/release/main.go @@ -30,6 +30,7 @@ func main() { {"linux", "amd64"}, {"linux", "arm64"}, {"darwin", "arm64"}, + {"windows", "amd64"}, } if err := createReleaseDirectory(); err != nil { diff --git a/crash/handle.go b/crash/handle.go index e74aeab..82b8447 100644 --- a/crash/handle.go +++ b/crash/handle.go @@ -4,6 +4,6 @@ import "log" func Handle(err error) { if err != nil { - log.Fatalln(err) + log.Panicln(err) } } diff --git a/go.mod b/go.mod index 6586144..2aa132b 100644 --- a/go.mod +++ b/go.mod @@ -1,33 +1,11 @@ module github.com/mrcyjanek/simplybs -go 1.24.5 +go 1.25.0 require ( - github.com/go-git/go-git/v5 v5.12.0 - github.com/ryanuber/go-glob v1.0.0 - github.com/ulikunitz/xz v0.5.12 + github.com/gobwas/glob v0.2.3 + github.com/ulikunitz/xz v0.5.15 + golang.org/x/term v0.45.0 ) -require ( - dario.cat/mergo v1.0.0 // indirect - github.com/Microsoft/go-winio v0.6.1 // indirect - github.com/ProtonMail/go-crypto v1.0.0 // indirect - github.com/cloudflare/circl v1.3.7 // indirect - github.com/cyphar/filepath-securejoin v0.2.4 // indirect - github.com/emirpasic/gods v1.18.1 // indirect - github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 // indirect - github.com/go-git/go-billy/v5 v5.5.0 // indirect - github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect - github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect - github.com/kevinburke/ssh_config v1.2.0 // indirect - github.com/pjbgf/sha1cd v0.3.0 // indirect - github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 // indirect - github.com/skeema/knownhosts v1.2.2 // indirect - github.com/xanzy/ssh-agent v0.3.3 // indirect - golang.org/x/crypto v0.37.0 // indirect - golang.org/x/mod v0.12.0 // indirect - golang.org/x/net v0.39.0 // indirect - golang.org/x/sys v0.32.0 // indirect - golang.org/x/tools v0.13.0 // indirect - gopkg.in/warnings.v0 v0.1.2 // indirect -) +require golang.org/x/sys v0.47.0 // indirect diff --git a/go.sum b/go.sum index 8a7c773..c5cee52 100644 --- a/go.sum +++ b/go.sum @@ -1,149 +1,8 @@ -dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk= -dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= -github.com/Microsoft/go-winio v0.5.2/go.mod h1:WpS1mjBmmwHBEWmogvA2mj8546UReBk4v8QkMxJ6pZY= -github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= -github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= -github.com/ProtonMail/go-crypto v1.0.0 h1:LRuvITjQWX+WIfr930YHG2HNfjR1uOfyf5vE0kC2U78= -github.com/ProtonMail/go-crypto v1.0.0/go.mod h1:EjAoLdwvbIOoOQr3ihjnSoLZRtE8azugULFRteWMNc0= -github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be h1:9AeTilPcZAjCFIImctFaOjnTIavg87rW78vTPkQqLI8= -github.com/anmitsu/go-shlex v0.0.0-20200514113438-38f4b401e2be/go.mod h1:ySMOLuWl6zY27l47sB3qLNK6tF2fkHG55UZxx8oIVo4= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio= -github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= -github.com/bwesterb/go-ristretto v1.2.3/go.mod h1:fUIoIZaG73pV5biE2Blr2xEzDoMj7NFEuV9ekS419A0= -github.com/cloudflare/circl v1.3.3/go.mod h1:5XYMA4rFBvNIrhs50XuiBJ15vF2pZn4nnUKZrLbUZFA= -github.com/cloudflare/circl v1.3.7 h1:qlCDlTPz2n9fu58M0Nh1J/JzcFpfgkFHHX3O35r5vcU= -github.com/cloudflare/circl v1.3.7/go.mod h1:sRTcRWXGLrKw6yIGJ+l7amYJFfAXbZG0kBSc8r4zxgA= -github.com/cyphar/filepath-securejoin v0.2.4 h1:Ugdm7cg7i6ZK6x3xDF1oEu1nfkyfH53EtKeQYTC3kyg= -github.com/cyphar/filepath-securejoin v0.2.4/go.mod h1:aPGpWjXOXUn2NCNjFvBE6aRxGGx79pTxQpKOJNYHHl4= -github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= -github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/elazarl/goproxy v0.0.0-20230808193330-2592e75ae04a h1:mATvB/9r/3gvcejNsXKSkQ6lcIaNec2nyfOdlTBR2lU= -github.com/elazarl/goproxy v0.0.0-20230808193330-2592e75ae04a/go.mod h1:Ro8st/ElPeALwNFlcTpWmkr6IoMFfkjXAvTHpevnDsM= -github.com/emirpasic/gods v1.18.1 h1:FXtiHYKDGKCW2KzwZKx0iC0PQmdlorYgdFG9jPXJ1Bc= -github.com/emirpasic/gods v1.18.1/go.mod h1:8tpGGwCnJ5H4r6BWwaV6OrWmMoPhUl5jm/FMNAnJvWQ= -github.com/gliderlabs/ssh v0.3.7 h1:iV3Bqi942d9huXnzEF2Mt+CY9gLu8DNM4Obd+8bODRE= -github.com/gliderlabs/ssh v0.3.7/go.mod h1:zpHEXBstFnQYtGnB8k8kQLol82umzn/2/snG7alWVD8= -github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 h1:+zs/tPmkDkHx3U66DAb0lQFJrpS6731Oaa12ikc+DiI= -github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376/go.mod h1:an3vInlBmSxCcxctByoQdvwPiA7DTK7jaaFDBTtu0ic= -github.com/go-git/go-billy/v5 v5.5.0 h1:yEY4yhzCDuMGSv83oGxiBotRzhwhNr8VZyphhiu+mTU= -github.com/go-git/go-billy/v5 v5.5.0/go.mod h1:hmexnoNsr2SJU1Ju67OaNz5ASJY3+sHgFRpCtpDCKow= -github.com/go-git/go-git-fixtures/v4 v4.3.2-0.20231010084843-55a94097c399 h1:eMje31YglSBqCdIqdhKBW8lokaMrL3uTkpGYlE2OOT4= -github.com/go-git/go-git-fixtures/v4 v4.3.2-0.20231010084843-55a94097c399/go.mod h1:1OCfN199q1Jm3HZlxleg+Dw/mwps2Wbk9frAWm+4FII= -github.com/go-git/go-git/v5 v5.12.0 h1:7Md+ndsjrzZxbddRDZjF14qK+NN56sy6wkqaVrjZtys= -github.com/go-git/go-git/v5 v5.12.0/go.mod h1:FTM9VKtnI2m65hNI/TenDDDnUf2Q9FHnXYjuz9i5OEY= -github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= -github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= -github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= -github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= -github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 h1:BQSFePA1RWJOlocH6Fxy8MmwDt+yVQYULKfN0RoTN8A= -github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99/go.mod h1:1lJo3i6rXxKeerYnT8Nvf0QmHCRC1n8sfWVwXF2Frvo= -github.com/kevinburke/ssh_config v1.2.0 h1:x584FjTGwHzMwvHx18PXxbBVzfnxogHaAReU4gf13a4= -github.com/kevinburke/ssh_config v1.2.0/go.mod h1:CT57kijsi8u/K/BOFA39wgDQJ9CxiF4nAY/ojJ6r6mM= -github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= -github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= -github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= -github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= -github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= -github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= -github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= -github.com/onsi/gomega v1.27.10 h1:naR28SdDFlqrG6kScpT8VWpu1xWY5nJRCF3XaYyBjhI= -github.com/onsi/gomega v1.27.10/go.mod h1:RsS8tutOdbdgzbPtzzATp12yT7kM5I5aElG3evPbQ0M= -github.com/pjbgf/sha1cd v0.3.0 h1:4D5XXmUUBUl/xQ6IjCkEAbqXskkq/4O7LmGn0AqMDs4= -github.com/pjbgf/sha1cd v0.3.0/go.mod h1:nZ1rrWOcGJ5uZgEEVL1VUM9iRQiZvWdbZjkKyFzPPsI= -github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= -github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= -github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= -github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= -github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= -github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= -github.com/ryanuber/go-glob v1.0.0 h1:iQh3xXAumdQ+4Ufa5b25cRpC5TYKlno6hsv6Cb3pkBk= -github.com/ryanuber/go-glob v1.0.0/go.mod h1:807d1WSdnB0XRJzKNil9Om6lcp/3a0v4qIHxIXzX/Yc= -github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 h1:n661drycOFuPLCN3Uc8sB6B/s6Z4t2xvBgU1htSHuq8= -github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3/go.mod h1:A0bzQcvG0E7Rwjx0REVgAGH58e96+X0MeOfepqsbeW4= -github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/skeema/knownhosts v1.2.2 h1:Iug2P4fLmDw9f41PB6thxUkNUkJzB5i+1/exaj40L3A= -github.com/skeema/knownhosts v1.2.2/go.mod h1:xYbVRSPxqBZFrdmDyMmsOs+uX1UZC3nTN3ThzgDxUwo= -github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= -github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= -github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= -github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= -github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= -github.com/ulikunitz/xz v0.5.12 h1:37Nm15o69RwBkXM0J6A5OlE67RZTfzUxTj8fB3dfcsc= -github.com/ulikunitz/xz v0.5.12/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= -github.com/xanzy/ssh-agent v0.3.3 h1:+/15pJfg/RsTxqYcX6fHqOXZwwMP+2VyYWJeWM2qQFM= -github.com/xanzy/ssh-agent v0.3.3/go.mod h1:6dzNDKs0J9rVPHPhaGCukekBHKqfl+L3KghI1Bc68Uw= -github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= -golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= -golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4= -golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU= -golang.org/x/crypto v0.37.0 h1:kJNSjF/Xp7kU0iB2Z+9viTPMW4EqqsrywMXLJOOsXSE= -golang.org/x/crypto v0.37.0/go.mod h1:vg+k43peMZ0pUMhYmVAWysMK35e6ioLh3wB8ZCAfbVc= -golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= -golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/mod v0.12.0 h1:rmsUpXtvNzj340zd98LZ4KntptpfRHwpFOHG188oHXc= -golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= -golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= -golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= -golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY= -golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= -golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= -golang.org/x/net v0.39.0 h1:ZCu7HMWDxpXpaiKdhzIfaltL9Lp31x/3fCP11bc6/fY= -golang.org/x/net v0.39.0/go.mod h1:X7NRbYVEA+ewNkCNyJ513WmMdQ3BineSwVtN2zD/d+E= -golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.3.0 h1:ftCYgMx6zT/asHUrPw8BLLscYtGznsLAnjq5RH9P66E= -golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= -golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.32.0 h1:s77OFDvIQeibCmezSnk/q6iAfkdiQaJi4VzroCFrN20= -golang.org/x/sys v0.32.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k= -golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= -golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc= -golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= -golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= -golang.org/x/term v0.31.0 h1:erwDkOK1Msy6offm1mOgvspSkslFnIGsFnxOKoufg3o= -golang.org/x/term v0.31.0/go.mod h1:R4BeIy7D95HzImkxGkTW1UQTtP54tio2RyHz7PwK0aw= -golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= -golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= -golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= -golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= -golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= -golang.org/x/text v0.24.0 h1:dd5Bzh4yt5KYA8f9CJHCP4FB4D51c2c6JvN37xJJkJ0= -golang.org/x/text v0.24.0/go.mod h1:L8rBsPeo2pSS+xqN0d5u2ikmjtmoJbDBT1b7nHvFCdU= -golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= -golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= -golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= -golang.org/x/tools v0.13.0 h1:Iey4qkscZuv0VvIt8E0neZjtPVQFSc870HQ448QgEmQ= -golang.org/x/tools v0.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58= -golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= -gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= -gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= -gopkg.in/warnings.v0 v0.1.2 h1:wFXVbFY8DY5/xOe1ECiWdKCzZlxgshcYVNkBHstARME= -gopkg.in/warnings.v0 v0.1.2/go.mod h1:jksf8JmL6Qr/oQM2OXTHunEvvTAsrWBLb6OOjuVWRNI= -gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= -gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= -gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= -gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +github.com/gobwas/glob v0.2.3 h1:A4xDbljILXROh+kObIiy5kIaPYD8e96x1tgBhUI5J+Y= +github.com/gobwas/glob v0.2.3/go.mod h1:d3Ez4x06l9bZtSvzIay5+Yzi0fmZzPgnTbPcKjJAkT8= +github.com/ulikunitz/xz v0.5.15 h1:9DNdB5s+SgV3bQ2ApL10xRc35ck0DuIX/isZvIk+ubY= +github.com/ulikunitz/xz v0.5.15/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= +golang.org/x/sys v0.47.0 h1:o7XGOvZQCADBQQ4Y7VNq2dRWQR7JmOUW8Kxx4ZsNgWs= +golang.org/x/sys v0.47.0/go.mod h1:4GL1E5IUh+htKOUEOaiffhrAeqysfVGipDYzABqnCmw= +golang.org/x/term v0.45.0 h1:NwWyBmoJCbfTHpxrWoZ9C6/VxOf7ic219I8xZZFdrf0= +golang.org/x/term v0.45.0/go.mod h1:9aqxs0blBcrm/n0L9QW0aRVD+ktan8ssZromtqJC43w= diff --git a/host/main.go b/host/main.go index 3b35d82..98d69cf 100644 --- a/host/main.go +++ b/host/main.go @@ -2,17 +2,14 @@ package host import ( "os" - "os/exec" "path/filepath" "runtime" - "strings" "github.com/mrcyjanek/simplybs/crash" ) type Host struct { Triplet string - Env []string } func GetPackagesDir() string { @@ -43,196 +40,33 @@ func DataDir() string { return filepath.Join(DataDirRoot(), runtime.GOOS+"_"+runtime.GOARCH) } -func (h *Host) GetEnvPath() string { - return filepath.Join(DataDir(), "env", h.Triplet) +func (h *Host) GetNativeEnvPath() string { + if os.Getenv("SIMPLYBS_NATIVE_ENV_DIR") != "" { + return filepath.Join(os.Getenv("SIMPLYBS_NATIVE_ENV_DIR")) + } + dir := DataDirRoot() + return filepath.Join(dir, "env-native") } -var SupportedHosts = map[string]*Host{ - "aarch64-apple-darwin": { - Triplet: "aarch64-apple-darwin", - Env: []string{ - "all:HOST=aarch64-apple-darwin", - "all:TARGET=aarch64-apple-darwin", - "all:OSX_MIN_VERSION=10.15", - "all:LD64_VERSION=609", - "all:CC_target=arm64-apple-darwin", - "all:CC=" + shellOutput("xcrun -f clang") + " -target $CC_target -mmacosx-version-min=$OSX_MIN_VERSION --sysroot " + shellOutput("xcrun --sdk macosx --show-sdk-path") + " -I" + shellOutput("xcrun --sdk macosx --show-sdk-path") + "/usr/include -I$PREFIX/include", - "all:CXX=" + shellOutput("xcrun -f clang++") + " -target $CC_target -mmacosx-version-min=$OSX_MIN_VERSION --sysroot " + shellOutput("xcrun --sdk macosx --show-sdk-path") + " -I" + shellOutput("xcrun --sdk macosx --show-sdk-path") + "/usr/include -I$PREFIX/include", - "all:CFLAGS=", - "all:CXXFLAGS=$CFLAGS -stdlib=libc++", - "all:RANLIB=" + shellOutput("xcrun -f ranlib"), - "all:AR=" + shellOutput("xcrun -f ar"), - "all:LIBTOOL=" + shellOutput("xcrun -f libtool"), - "all:SDK_PATH=" + shellOutput("xcrun --sdk macosx --show-sdk-path"), - }, - }, - "x86_64-apple-darwin": { - Triplet: "x86_64-apple-darwin", - Env: []string{ - "all:HOST=x86_64-apple-darwin", - "all:TARGET=x86_64-apple-darwin", - "all:OSX_MIN_VERSION=10.15", - "all:LD64_VERSION=609", - "all:CC_target=x86_64-apple-darwin", - "all:CC=" + shellOutput("xcrun -f clang") + " -target $CC_target -mmacosx-version-min=$OSX_MIN_VERSION --sysroot " + shellOutput("xcrun --sdk macosx --show-sdk-path") + " -I" + shellOutput("xcrun --sdk macosx --show-sdk-path") + "/usr/include -I$PREFIX/include", - "all:CXX=" + shellOutput("xcrun -f clang++") + " -target $CC_target -mmacosx-version-min=$OSX_MIN_VERSION --sysroot " + shellOutput("xcrun --sdk macosx --show-sdk-path") + " -I" + shellOutput("xcrun --sdk macosx --show-sdk-path") + "/usr/include -I$PREFIX/include", - "all:CFLAGS=", - "all:CXXFLAGS=$CFLAGS -stdlib=libc++", - "all:RANLIB=" + shellOutput("xcrun -f ranlib"), - "all:AR=" + shellOutput("xcrun -f ar"), - "all:LIBTOOL=" + shellOutput("xcrun -f libtool"), - "all:SDK_PATH=" + shellOutput("xcrun --sdk macosx --show-sdk-path"), - }, - }, - "aarch64-apple-ios": { - Triplet: "aarch64-apple-ios", - Env: []string{ - "all:HOST=aarch64-apple-ios", - "all:TARGET=aarch64-apple-ios", - "all:IOS_MIN_VERSION=12", - "all:LD64_VERSION=609", - "all:CC_target=aarch64-apple-ios", - "all:CC=" + shellOutput("xcrun -f clang") + " -target $CC_target -mios-version-min=$IOS_MIN_VERSION --sysroot " + shellOutput("xcrun --sdk iphoneos --show-sdk-path") + " -I" + shellOutput("xcrun --sdk iphoneos --show-sdk-path") + "/usr/include -I$PREFIX/include", - "all:CXX=" + shellOutput("xcrun -f clang++") + " -target $CC_target -mios-version-min=$IOS_MIN_VERSION --sysroot " + shellOutput("xcrun --sdk iphoneos --show-sdk-path") + " -I" + shellOutput("xcrun --sdk iphoneos --show-sdk-path") + "/usr/include -I$PREFIX/include", - "all:CFLAGS=", - "all:CXXFLAGS=$CFLAGS -stdlib=libc++", - "all:RANLIB=" + shellOutput("xcrun -f ranlib"), - "all:AR=" + shellOutput("xcrun -f ar"), - "all:LIBTOOL=" + shellOutput("xcrun -f libtool"), - "all:SDK_PATH=" + shellOutput("xcrun --sdk iphoneos --show-sdk-path"), - }, - }, - "aarch64-apple-ios-simulator": { - Triplet: "aarch64-apple-ios-simulator", - Env: []string{ - "all:HOST=aarch64-apple-ios-simulator", - "all:TARGET=aarch64-apple-ios-simulator", - "all:IOS_MIN_VERSION=12", - "all:LD64_VERSION=609", - "all:CC_target=aarch64-apple-ios-simulator", - "all:CC=" + shellOutput("xcrun -f clang") + " -target $CC_target -mios-version-min=$IOS_MIN_VERSION --sysroot " + shellOutput("xcrun --sdk iphonesimulator --show-sdk-path") + " -I" + shellOutput("xcrun --sdk iphonesimulator --show-sdk-path") + "/usr/include -I$PREFIX/include", - "all:CXX=" + shellOutput("xcrun -f clang++") + " -target $CC_target -mios-version-min=$IOS_MIN_VERSION --sysroot " + shellOutput("xcrun --sdk iphonesimulator --show-sdk-path") + " -I" + shellOutput("xcrun --sdk iphonesimulator --show-sdk-path") + "/usr/include -I$PREFIX/include", - "all:CFLAGS=", - "all:CXXFLAGS=$CFLAGS -stdlib=libc++", - "all:RANLIB=" + shellOutput("xcrun -f ranlib"), - "all:AR=" + shellOutput("xcrun -f ar"), - "all:LIBTOOL=" + shellOutput("xcrun -f libtool"), - "all:SDK_PATH=" + shellOutput("xcrun --sdk iphonesimulator --show-sdk-path"), - }, - }, - "x86_64-linux-musl": { - Triplet: "x86_64-linux-musl", - Env: []string{ - "all:HOST=x86_64-linux-musl", - "all:TARGET=x86_64-linux-musl", - "all:CC_target=x86_64-linux-musl", - "all:CC=x86_64-linux-musl-gcc", - "all:CXX=x86_64-linux-musl-g++", - "all:CXXFLAGS=$CFLAGS", - "all:RANLIB=x86_64-linux-musl-ranlib", - "all:AR=x86_64-linux-musl-ar", - "all:AS=x86_64-linux-musl-as", - "all:LIBTOOL=x86_64-linux-musl-libtool", - "all:OBJCOPY=x86_64-linux-musl-objcopy", - "all:OBJDUMP=x86_64-linux-musl-objdump", - "all:STRIP=x86_64-linux-musl-strip", - "all:READELF=x86_64-linux-musl-readelf", - "all:LD=x86_64-linux-musl-ld", - "all:NM=x86_64-linux-musl-nm", - }, - }, - "x86_64-linux-gnu": { - Triplet: "x86_64-linux-gnu", - Env: []string{ - "all:HOST=x86_64-linux-gnu", - "all:TARGET=x86_64-linux-gnu", - "all:CC_target=x86_64-linux-gnu", - "all:CC=x86_64-linux-gnu-gcc", - "all:CXX=x86_64-linux-gnu-g++", - "all:CXXFLAGS=$CFLAGS", - "all:RANLIB=x86_64-linux-gnu-ranlib", - "all:AR=x86_64-linux-gnu-ar", - "all:AS=x86_64-linux-gnu-as", - "all:LIBTOOL=x86_64-linux-gnu-libtool", - "all:OBJCOPY=x86_64-linux-gnu-objcopy", - "all:OBJDUMP=x86_64-linux-gnu-objdump", - "all:STRIP=x86_64-linux-gnu-strip", - "all:READELF=x86_64-linux-gnu-readelf", - "all:LD=x86_64-linux-gnu-ld", - "all:NM=x86_64-linux-gnu-nm", - }, - }, - "aarch64-linux-gnu": { - Triplet: "aarch64-linux-gnu", - Env: []string{ - "all:HOST=aarch64-linux-gnu", - "all:TARGET=aarch64-linux-gnu", - "all:CC_target=aarch64-linux-gnu", - "all:CC=aarch64-linux-gnu-gcc", - "all:CXX=aarch64-linux-gnu-g++", - "all:CFLAGS=", - "all:CXXFLAGS=$CFLAGS", - "all:RANLIB=aarch64-linux-gnu-ranlib", - "all:AR=aarch64-linux-gnu-ar", - "all:LIBTOOL=aarch64-linux-gnu-libtool", - }, - }, - "aarch64-linux-android": { - Triplet: "aarch64-linux-android", - Env: []string{ - "all:HOST=aarch64-linux-android", - "all:TARGET=aarch64-linux-android", - "all:CC_target=aarch64-linux-android", - "all:CC=aarch64-linux-android21-clang", - "all:CXX=aarch64-linux-android21-clang++", - "all:CFLAGS=", - "all:CXXFLAGS=$CFLAGS -stdlib=libc++", - "all:RANLIB=llvm-ranlib", - "all:AR=llvm-ar", - "all:AS=llvm-as", - "all:LIBTOOL=libtool", - "all:ANDROID_NDK_HOME=$PREFIX/native/", - "all:LDFLAGS=$PREFIX/usr/lib/libc++_static.a $PREFIX/usr/lib/libc++abi.a -lm -lc -llog", - }, - }, - "x86_64-linux-android": { - Triplet: "x86_64-linux-android", - Env: []string{ - "all:HOST=x86_64-linux-android", - "all:TARGET=x86_64-linux-android", - "all:CC_target=x86_64-linux-android", - "all:CC=x86_64-linux-android21-clang", - "all:CXX=x86_64-linux-android21-clang++", - "all:CFLAGS=", - "all:CXXFLAGS=$CFLAGS", - "all:RANLIB=llvm-ranlib", - "all:AR=llvm-ar", - "all:LIBTOOL=llvm-libtool", - "all:ANDROID_NDK_HOME=$PREFIX/native/", - }, - }, - "armv7a-linux-androideabi": { - Triplet: "armv7a-linux-androideabi", - Env: []string{ - "all:HOST=armv7a-linux-androideabi", - "all:TARGET=armv7a-linux-androideabi", - "all:CC_target=armv7a-linux-androideabi", - "all:CC=armv7a-linux-androideabi21-clang", - "all:CXX=armv7a-linux-androideabi21-clang++", - "all:CFLAGS=", - "all:CXXFLAGS=$CFLAGS", - "all:RANLIB=llvm-ranlib", - "all:AR=llvm-ar", - "all:LIBTOOL=llvm-libtool", - "all:ANDROID_NDK_HOME=$PREFIX/native/", - }, - }, +func (h *Host) GetEnvPath() string { + if os.Getenv("SIMPLYBS_ENV_DIR") != "" { + return filepath.Join(os.Getenv("SIMPLYBS_ENV_DIR")) + } + dir := DataDirRoot() + return filepath.Join(dir, "env") } -func shellOutput(cmd string) string { - output, err := exec.Command("bash", "-c", cmd).Output() - if err != nil { - return "$(" + cmd + ")" - } - return strings.TrimSpace(string(output)) +// aarch64-apple-darwin,x86_64-apple-darwin,aarch64-apple-ios,aarch64-apple-ios-simulator,x86_64-w64-mingw32,x86_64-linux-gnu,aarch64-linux-gnu,aarch64-linux-android,x86_64-linux-android,armv7a-linux-androideabi + +var SupportedHosts = map[string]*Host{ + "aarch64-apple-darwin": {Triplet: "aarch64-apple-darwin"}, + "x86_64-apple-darwin": {Triplet: "x86_64-apple-darwin"}, + "aarch64-apple-ios": {Triplet: "aarch64-apple-ios"}, + "aarch64-apple-ios-simulator": {Triplet: "aarch64-apple-ios-simulator"}, + "x86_64-w64-mingw32": {Triplet: "x86_64-w64-mingw32"}, + "x86_64-linux-gnu": {Triplet: "x86_64-linux-gnu"}, + "aarch64-linux-gnu": {Triplet: "aarch64-linux-gnu"}, + "aarch64-linux-android": {Triplet: "aarch64-linux-android"}, + "x86_64-linux-android": {Triplet: "x86_64-linux-android"}, + "armv7a-linux-androideabi": {Triplet: "armv7a-linux-androideabi"}, } diff --git a/host/main_test.go b/host/main_test.go new file mode 100644 index 0000000..5df9e34 --- /dev/null +++ b/host/main_test.go @@ -0,0 +1,87 @@ +package host_test + +import ( + "fmt" + "os" + "path/filepath" + "strings" + "testing" + + "github.com/mrcyjanek/simplybs/builder" + "github.com/mrcyjanek/simplybs/host" + "github.com/mrcyjanek/simplybs/pack" + "github.com/mrcyjanek/simplybs/utils/ifstring" +) + +func chdirRepoRoot(t *testing.T) { + t.Helper() + wd, err := os.Getwd() + if err != nil { + t.Fatal(err) + } + for { + if _, err := os.Stat(filepath.Join(wd, "packages", "native", "_.json")); err == nil { + if err := os.Chdir(wd); err != nil { + t.Fatal(err) + } + return + } + parent := filepath.Dir(wd) + if parent == wd { + t.Fatal("could not find repo root (packages/native/_.json)") + } + wd = parent + } +} + +func TestHosts(t *testing.T) { + chdirRepoRoot(t) + meta, err := pack.FindPackage("native/_") + if err != nil { + t.Fatal(err) + } + for triplet := range host.SupportedHosts { + t.Run("Env vars: "+triplet, func(t *testing.T) { + assertEnv(t, triplet, meta.ExportEnv) + }) + } +} + +func assertEnv(t *testing.T, triplet string, exportEnv []string) { + keys := []string{} + for _, envVar := range exportEnv { + is := ifstring.ParseIfString(envVar) + if !is.Matches(triplet, builder.GetName()) { + continue + } + key := strings.Split(is.Content, "=")[0] + keys = append(keys, key) + } + var required = []string{ + "TARGET", + "CC", + "CXX", + "CFLAGS", + "AR", + "RANLIB", + "NM", + "STRIP", + "CXXFLAGS", + "CPPFLAGS", + "LDFLAGS", + "CMAKE_SYSTEM_NAME", + "ARCH", + } + for _, req := range required { + exists := false + for _, has := range keys { + if has == req { + exists = true + } + } + if !exists { + fmt.Println(triplet, "doesn't have", req) + t.Fail() + } + } +} diff --git a/main.go b/main.go index 27275cb..02fac2c 100644 --- a/main.go +++ b/main.go @@ -6,7 +6,7 @@ import ( "log" "strings" - cmd "github.com/mrcyjanek/simplybs/cmd/buildweb" + "github.com/mrcyjanek/simplybs/cmd/archive" "github.com/mrcyjanek/simplybs/cmd/lint" "github.com/mrcyjanek/simplybs/crash" "github.com/mrcyjanek/simplybs/host" @@ -14,7 +14,7 @@ import ( ) func main() { - log.SetFlags(log.LstdFlags | log.Lshortfile) + log.SetFlags(log.Lshortfile) argList := flag.Bool("list", false, "List all supported hosts (value is depth)") argHost := flag.String("host", "", "The host to build for") argPkg := flag.String("package", "", "The package(s) to build (comma-separated)") @@ -22,20 +22,19 @@ func main() { argExtract := flag.Bool("extract", false, "Extract packages") argDownload := flag.Bool("download", false, "Download package sources") argBuild := flag.Bool("build", false, "Build packages") - argBuildWeb := flag.Bool("buildweb", false, "Generate static website with package information") argLint := flag.Bool("lint", false, "Lint packages") + argArchive := flag.Bool("archive", false, "Download all sources from sources.json") argVersion := flag.Bool("v", false, "Show version") argShell := flag.Bool("shell", false, "Extract source and start shell with build environment") argCleanup := flag.Bool("cleanup", false, "Remove everything except current built archives") + argCachePull := flag.Bool("cache-pull", false, "Download needed build-cache artifacts (requires SIMPLYBS_CACHE_TAG and SIMPLYBS_CACHE_REPO)") + argCachePush := flag.Bool("cache-push", false, "Upload new/changed local build-cache artifacts (requires SIMPLYBS_CACHE_TAG and SIMPLYBS_CACHE_REPO)") + // argQuiet := flag.Bool("quiet", false, "Redirect stdout and stderr to /dev/null") flag.Parse() if *argVersion { fmt.Println("simplybs version 0.0.0") return } - if *argBuildWeb { - cmd.BuildWeb() - return - } if *argCleanup { pack.Cleanup() return @@ -44,35 +43,70 @@ func main() { lint.Lint() return } + if *argArchive { + archive.Archive() + return + } packageNames := []*pack.Package{} if *argWorld { packageNames = pack.GetAllPackages() - } else { + } else if *argPkg != "" { packageNames = pack.GetPackagesByList(*argPkg) } + if *argCachePush && *argPkg == "" && !*argWorld { + // Push every local built artifact for this builder that is not on the release. + if err := pack.CachePush(nil, nil); err != nil { + crash.Handle(err) + } + return + } + if len(packageNames) == 0 { crash.Handle(fmt.Errorf("no valid -package names or -world provided")) } if *argDownload { for _, pkg := range packageNames { - pkg.DownloadSource() + for _, download := range pkg.Download { + pkg.DownloadSource(download) + } } log.Println("Downloaded all sources") return } - hosts := strings.Split(*argHost, ",") - for _, h := range hosts { + if *argCachePull || *argCachePush { + if *argHost == "" { + crash.Handle(fmt.Errorf("-cache-pull/-cache-push with -package requires -host")) + } + hosts := strings.SplitSeq(*argHost, ",") + for h := range hosts { + host := host.SupportedHosts[h] + if host == nil { + crash.Handle(fmt.Errorf("host %s not supported", h)) + } + if *argCachePull { + if err := pack.CachePull(packageNames, host); err != nil { + crash.Handle(err) + } + } + if *argCachePush { + if err := pack.CachePush(packageNames, host); err != nil { + crash.Handle(err) + } + } + } + return + } + + hosts := strings.SplitSeq(*argHost, ",") + for h := range hosts { host := host.SupportedHosts[h] if host == nil { crash.Handle(fmt.Errorf("host %s not supported", h)) } buildForHost(host, packageNames, *argList, *argExtract, *argBuild, *argShell) - if *argBuildWeb { - cmd.BuildWeb() - } } } @@ -84,21 +118,26 @@ func buildForHost(host *host.Host, packageNames []*pack.Package, list bool, extr return } - if extract { - for _, pkg := range packageNames { - pkg.ExtractEnv(host, host.GetEnvPath()) - } - } - if build { + if pack.CacheEnabled() { + log.Printf("cache: enabled (tag=%s repo=%s); auto pull/push", pack.CacheTag(), pack.CacheRepo()) + if err := pack.CachePull(packageNames, host); err != nil { + log.Printf("cache: auto-pull failed: %v", err) + } + } for _, pkg := range packageNames { pkg.EnsureBuilt(host, true) } + if pack.CacheEnabled() { + if err := pack.CachePush(packageNames, host); err != nil { + log.Printf("cache: auto-push failed: %v", err) + } + } } if extract { for _, pkg := range packageNames { log.Printf("Extracting env for package: %s", pkg.Package) - pkg.ExtractEnv(host, host.GetEnvPath()) + pkg.ExtractEnv(host, host.GetEnvPath(), host.GetNativeEnvPath()) } } diff --git a/pack/build.go b/pack/build.go index 6ad0d56..d002ed5 100644 --- a/pack/build.go +++ b/pack/build.go @@ -1,53 +1,88 @@ package pack import ( + "fmt" "log" "os" "os/exec" + "path" "path/filepath" "strings" + "github.com/mrcyjanek/simplybs/builder" + "github.com/mrcyjanek/simplybs/crash" "github.com/mrcyjanek/simplybs/host" "github.com/mrcyjanek/simplybs/utils" - "github.com/ryanuber/go-glob" + downloadpkg "github.com/mrcyjanek/simplybs/utils/download" + "github.com/mrcyjanek/simplybs/utils/ifstring" ) func (p *Package) EnsureBuilt(h *host.Host, buildDependencies bool) { buildPath := p.GenerateBuildPath(h, "built") + ".info.txt" info, err := os.ReadFile(buildPath) if err != nil { - log.Printf("[%s] No build cache found, building...", p.Package) + // Selective remote pull: only this package's assets (by short-hash name). + if TryPullPackageCache(p, h) { + info, err = os.ReadFile(buildPath) + } + } + if err != nil { + log.Printf("[%s][%s] No build cache found, building...", h.Triplet, p.Package) p.BuildPackage(h, true) return } if string(info) == p.GeneratePackageInfo(h) { - log.Printf("[%s] Build cache found, skipping build...", p.Package) + log.Printf("[%s][%s] Build cache found, skipping build...", h.Triplet, p.Package) return } - log.Printf("[%s] Build cache found, but info mismatch, rebuilding...", p.Package) + log.Printf("[%s][%s] Build cache found, but info mismatch, rebuilding...", h.Triplet, p.Package) p.BuildPackage(h, true) } -func (p *Package) ExtractEnv(host *host.Host, envPath string) { +func (p *Package) ExtractEnv(host *host.Host, envPath string, envNativePath string) { archive := p.GenerateBuildPath(host, "built") + ".tar.gz" + archiveNative := p.GenerateBuildPath(host, "built") + "_native.tar.gz" err := utils.ExtractTarGz(archive, envPath) if err != nil { - log.Fatalf("Failed to extract archive %s: %v", archive, err) + log.Panicf("Failed to extract archive %s: %v", archive, err) + } + err = utils.ExtractTarGz(archiveNative, envNativePath) + if err != nil { + log.Panicf("Failed to extract archive %s: %v", archive, err) + } + env := p.GetEnv(host) + newEnv := []string{} + for k, v := range env { + newEnv = append(newEnv, k+"="+v) + } + exportEnv := p.GetExportEnv(host) + exportEnvLines := []string{} + for k, v := range exportEnv { + exportEnvLines = append(exportEnvLines, k+"="+v) + } + os.MkdirAll(envPath, 0750) + safeName := strings.ReplaceAll(p.Package, "/", "_") + if p.Type == "native" { + writeDotEnv(envNativePath+"/_source_me@"+safeName, newEnv) + writeDotEnv(envNativePath+"/_source_me_export@"+safeName, exportEnvLines) + } else { + writeDotEnv(envPath+"/_source_me@"+safeName, newEnv) + writeDotEnv(envPath+"/_source_me_export@"+safeName, exportEnvLines) } } -func (p *Package) DownloadSource() { - sourcePath := p.GenerateBuildPath(&host.Host{}, "source") +func (p *Package) DownloadSource(download *Download) { + sourcePath := p.GenerateSourceBuildPath(download) os.MkdirAll(filepath.Dir(sourcePath), 0755) - if p.Download.Kind == "none" { + if download.Kind == "none" { return } if _, err := os.Stat(sourcePath); os.IsNotExist(err) { var err error - if p.Download.Kind == "git" { - err = utils.DownloadGit(p.Package, sourcePath, p.Download.URL, p.Download.Sha256) + if download.Kind == "git" { + err = utils.DownloadGit(p.Package, sourcePath, download.URL) } else { - err = utils.DownloadFile(p.Package, sourcePath, p.Download.URL, p.Download.Sha256, false) + err = downloadpkg.DownloadFile(p.Package, sourcePath, download.URL, download.Sha256, false) } if err != nil { log.Fatalf("Failed to download source: %v", err) @@ -56,117 +91,211 @@ func (p *Package) DownloadSource() { } func (p *Package) ExtractSource(host *host.Host, buildPath string) { - sourcePath := p.GenerateBuildPath(host, "source") - p.DownloadSource() - var err error - switch p.Download.Kind { - case "tar.bz2": - err = utils.ExtractTarBz2(sourcePath, buildPath) - case "tar.gz": - err = utils.ExtractTarGz(sourcePath, buildPath) - case "tar.xz": - err = utils.ExtractTarXz(sourcePath, buildPath) - case "git": - os.MkdirAll(buildPath, 0755) - err = os.CopyFS(buildPath, os.DirFS(sourcePath)) - case "none": - return - default: - log.Fatalf("Unsupported archive kind: %s", p.Download.Kind) + for _, download := range p.Download { + p.DownloadSource(download) } - if err != nil { - log.Fatalf("Failed to extract archive %s: %v", sourcePath, err) + var err error + for _, download := range p.Download { + if download.Kind == "none" { + continue + } + sourcePath := p.GenerateSourceBuildPath(download) + actualBuildPath := buildPath + if download.Path != "" { + actualBuildPath = filepath.Join(buildPath, download.Path) + } + switch download.Kind { + case "tar.bz2": + err = utils.ExtractTarBz2(sourcePath, actualBuildPath) + case "tar.gz": + err = utils.ExtractTarGz(sourcePath, actualBuildPath) + case "tar.xz": + err = utils.ExtractTarXz(sourcePath, actualBuildPath) + case "git": + err = utils.ExtractGitCloneBundle(sourcePath, actualBuildPath, download.Sha256) + case "blob": + os.MkdirAll(filepath.Dir(actualBuildPath), 0755) + err = utils.Copy(sourcePath, actualBuildPath) + default: + log.Fatalf("Unsupported archive kind: %s", download.Kind) + } + + if err != nil { + log.Fatalf("Failed to extract archive %s: %v", sourcePath, err) + } } } func (p *Package) BuildPackage(h *host.Host, buildDependencies bool) { - p.buildPackageInternal(h, buildDependencies) } +func filteredDependencyPackages(deps []string, h *host.Host) []*Package { + var pkgs []*Package + for _, dep := range deps { + is := ifstring.ParseIfString(dep) + if !is.Matches(h.Triplet, builder.GetName()) { + continue + } + d, err := FindPackage(is.Content) + if err != nil { + log.Fatalf("Package %s not found in build", is.Content) + } + pkgs = append(pkgs, d) + } + return pkgs +} + +func wipeDirContents(dir string) { + if entries, err := os.ReadDir(dir); err == nil { + for _, entry := range entries { + utils.RemoveAll(filepath.Join(dir, entry.Name())) + } + } +} + +func resetBuildDirs() { + for _, dir := range []string{ + filepath.Join(host.DataDir(), "work"), + filepath.Join(host.DataDir(), "staging"), + } { + utils.RemoveAll(dir) + } +} + +func parseStepProfile(content string) (profile, cmd string) { + if strings.HasPrefix(content, "@") { + rest := content[1:] + if idx := strings.IndexByte(rest, ' '); idx != -1 { + return rest[:idx], rest[idx+1:] + } + return rest, "" + } + return "", content +} + +func (p *Package) envForStep(h *host.Host, profileName string) map[string]string { + return p.envForStepFrom(p.GetEnv(h), h, profileName) +} + +func (p *Package) envForStepFrom(env map[string]string, h *host.Host, profileName string) map[string]string { + env = copyEnv(env) + if profileName == "" { + return env + } + prof, ok := p.Build.Profiles[profileName] + if !ok { + log.Fatalf("[%s] unknown build profile %q", p.Package, profileName) + } + for _, k := range prof.Unset { + delete(env, k) + } + if len(prof.Env) > 0 { + env = utils.AppendEnv(env, prof.Env, h) + } + return env +} + func (p *Package) buildPackageInternal(h *host.Host, buildDependencies bool) { var deps []*Package if buildDependencies { - for _, dep := range p.Dependencies { - if strings.Contains(dep, ":") { - prefix := strings.Split(dep, ":")[0] - if !glob.Glob(prefix, h.Triplet) && prefix != "all" { - continue - } - dep = dep[strings.Index(dep, ":")+1:] - } else { - log.Fatalf("Invalid dependency: %s", dep) - } - d, err := FindPackage(dep) - if err != nil { - log.Fatalf("Package %s not found in build", dep) - } - deps = append(deps, d) + deps = filteredDependencyPackages(p.Dependencies, h) + for _, d := range deps { d.EnsureBuilt(h, false) } } envPath := h.GetEnvPath() - os.RemoveAll(envPath) + wipeDirContents(envPath) + nativeEnvPath := h.GetNativeEnvPath() + wipeDirContents(nativeEnvPath) os.MkdirAll(envPath, 0755) for _, dep := range deps { - dep.ExtractEnv(h, envPath) + dep.ExtractEnv(h, envPath, nativeEnvPath) } + resetBuildDirs() buildPath := p.GenerateBuildPath(h, "work") stagingPath := p.GenerateBuildPath(h, "staging") - os.RemoveAll(buildPath) - os.RemoveAll(stagingPath) os.MkdirAll(buildPath, 0755) os.MkdirAll(stagingPath, 0755) - defer os.RemoveAll(buildPath) - defer os.RemoveAll(stagingPath) + defer utils.RemoveAll(buildPath) + defer utils.RemoveAll(stagingPath) p.ExtractSource(h, buildPath) - infoPath := filepath.Join(stagingPath, h.GetEnvPath(), "usr", "share", "buildlib", p.ShortName(h)+".txt") + infoPath := filepath.Join(utils.DestDirJoin(stagingPath, p.prefixPath(h)), ".buildlib", p.ShortName(h)+".txt") os.MkdirAll(filepath.Dir(infoPath), 0755) err := os.WriteFile(infoPath, []byte(p.GeneratePackageInfo(h)), 0644) if err != nil { log.Fatalf("Failed to write build info %s: %v", infoPath, err) } - for _, step := range p.Build.Steps { - if strings.Contains(step, ":") { - prefix := strings.Split(step, ":")[0] - if !glob.Glob(prefix, h.Triplet) && prefix != "all" { - continue - } - step = step[strings.Index(step, ":")+1:] - } else { - log.Fatalf("Invalid step: %s", step) + builderName := builder.GetName() + for _, step := range ifstring.FilterContent(p.Build.Steps, h.Triplet, builderName) { + profileName, stepCmd := parseStepProfile(step) + baseEnv := p.GetEnv(h) + profileName = utils.ExpandEnvFromMap(profileName, baseEnv) + if profileName == "" && strings.HasPrefix(step, "@") { + continue } - - cmd := exec.Command("sh", "-c", step) + nativePrefix := h.GetNativeEnvPath() + tmpDir := filepath.Join(nativePrefix, "_", "tmp") + os.MkdirAll(tmpDir, 0755) + shell := utils.ResolveShellForBuild(nativePrefix, buildPath) + cmd := exec.Command(shell, "-c", stepCmd) cmd.Dir = buildPath pathEnv := utils.GetHostPath() - env := p.GetEnv(h) - - cmd.Env = append(cmd.Env, []string{ - "STAGING_DIR=" + stagingPath, - "HOST=" + h.Triplet, - "PREFIX=" + h.GetEnvPath(), - "PATH=" + h.GetEnvPath() + "/native/bin:" + env["PATH"] + ":" + pathEnv, - }...) + env := p.envForStepFrom(baseEnv, h, profileName) + + hostTriplet := h.Triplet + if p.Type == "native" { + hostTriplet = builder.NativeTriplet() + } + + // Explicit env only — do not inherit the parent process environment. + overrides := map[string]string{ + "STAGING_DIR": utils.ToShellPath(stagingPath), + "HOST": hostTriplet, + "PREFIX": utils.ToShellPath(h.GetEnvPath()), + "NATIVEPREFIX": utils.ToShellPath(nativePrefix), + "PATH": utils.BuildStepPATH(nativePrefix, h.GetEnvPath(), env["PATH"], pathEnv), + "TEMP": utils.ToShellPath(tmpDir), + "TMP": utils.ToShellPath(tmpDir), + "TMPDIR": utils.ToShellPath(tmpDir), + "CYGWIN": "nodosfilewarning", + "MSYS": "nodosfilewarning", + "MSYS_NO_PATHCONV": "1", + "MSYS2_ARG_CONV_EXCL": "*", + } for k, v := range env { - cmd.Env = append(cmd.Env, k+"="+v) + overrides[k] = v } + cmd.Env = utils.ProcessEnv(overrides) + + writeDotEnv(path.Join(buildPath, "_source_me"), cmd.Env) - log.Printf("Executing step: %s", step) - cmd.Stderr = os.Stderr - cmd.Stdout = os.Stdout - err := cmd.Run() + log.Printf("Executing step: %s", stepCmd) + if profileName != "" { + log.Printf("Using build profile: %s", profileName) + } + err := utils.RunLive(cmd) if err != nil { - log.Fatalf("[%s] build step failed: %s, error: %v, %s", p.Package, step, err, cmd.Dir) + log.Fatalf("[%s] build step failed: %s, error: %v, %s", p.Package, stepCmd, err, cmd.Dir) } } builtArchivePath := p.GenerateBuildPath(h, "built") + ".tar.gz" + builtNativeArchivePath := p.GenerateBuildPath(h, "built") + "_native.tar.gz" os.MkdirAll(filepath.Dir(builtArchivePath), 0755) - err = utils.CreateTarGz(filepath.Join(stagingPath, h.GetEnvPath()), builtArchivePath) + os.MkdirAll(filepath.Dir(builtNativeArchivePath), 0755) + stagedNative := utils.DestDirJoin(stagingPath, h.GetNativeEnvPath()) + stagedHost := utils.DestDirJoin(stagingPath, h.GetEnvPath()) + os.MkdirAll(stagedNative, 0755) + os.MkdirAll(stagedHost, 0755) + err = utils.CreateTarGz(stagedNative, builtNativeArchivePath) + if err != nil { + log.Fatalf("Failed to create archive %s: %v", builtArchivePath, err) + } + err = utils.CreateTarGz(stagedHost, builtArchivePath) if err != nil { log.Fatalf("Failed to create archive %s: %v", builtArchivePath, err) } @@ -178,54 +307,112 @@ func (p *Package) buildPackageInternal(h *host.Host, buildDependencies bool) { } log.Printf("Package built successfully: %s", builtArchivePath) + TryPushPackageCache(p, h) +} + +func writeDotEnv(path string, env []string) { + f, err := os.Create(path) + if err != nil { + crash.Handle(err) + } + defer f.Close() + + var b strings.Builder + b.WriteString("#!/bin/bash\n") + + for _, kv := range env { + if kv == "" { + continue + } + + parts := strings.SplitN(kv, "=", 2) + key := parts[0] + val := "" + if len(parts) > 1 { + val = parts[1] + } + // Skip keys that are not valid bash identifiers (e.g. inherited Windows names). + if !isBashIdent(key) { + continue + } + + escapedVal := shellEscape(val) + + b.WriteString(fmt.Sprintf("export %s=%s\n", key, escapedVal)) + } + + f.WriteString(b.String()) +} + +func isBashIdent(name string) bool { + if name == "" { + return false + } + for i, r := range name { + if r == '_' || (r >= 'A' && r <= 'Z') || (r >= 'a' && r <= 'z') { + continue + } + if i > 0 && r >= '0' && r <= '9' { + continue + } + return false + } + return true +} +func shellEscape(value string) string { + if value == "" { + return "\"\"" + } + + replacer := strings.NewReplacer( + `\`, `\\`, + `"`, `\"`, + "`", "\\`", + `$`, `\$`, + ) + escaped := replacer.Replace(value) + + return "\"" + escaped + "\"" } func (p *Package) StartShell(h *host.Host) { log.Printf("Starting shell for package: %s for host %s", p.Package, h.Triplet) + resetBuildDirs() buildPath := p.GenerateBuildPath(h, "work") - os.RemoveAll(buildPath) os.MkdirAll(buildPath, 0755) log.Printf("Extracting source for package: %s", p.Package) - for _, depName := range p.Dependencies { - if strings.Contains(depName, ":") { - prefix := strings.Split(depName, ":")[0] - if !glob.Glob(prefix, h.Triplet) && prefix != "all" { - continue - } - depName = depName[strings.Index(depName, ":")+1:] - } else { - log.Fatalf("Invalid dependency: %s", depName) - } - dep, err := FindPackage(depName) - if err != nil { - log.Fatalf("Package %s not found in build", depName) - } - dep.ExtractEnv(h, h.GetEnvPath()) + for _, dep := range filteredDependencyPackages(p.Dependencies, h) { + dep.ExtractEnv(h, h.GetEnvPath(), h.GetNativeEnvPath()) } p.ExtractSource(h, buildPath) env := p.GetEnv(h) pathEnv := utils.GetHostPath() + nativePrefix := h.GetNativeEnvPath() + os.MkdirAll(filepath.Join(nativePrefix, "_", "tmp"), 0755) userShell := os.Getenv("SHELL") if userShell == "" { - userShell = "/bin/sh" + userShell = utils.ResolveShell(nativePrefix) } + fmt.Print("\n\n") + builderName := builder.GetName() + for _, step := range ifstring.FilterContent(p.Build.Steps, h.Triplet, builderName) { + fmt.Printf("%s;\n", utils.ExpandEnvFromMap(step, env)) + } + fmt.Print("\n\n") for _, step := range p.Build.Steps { - if strings.Contains(step, ":") { - prefix := strings.Split(step, ":")[0] - if !glob.Glob(prefix, h.Triplet) && prefix != "all" { - log.Printf("[no match] %s", step) - continue - } - log.Printf(" [match] %s", step) - } else { - log.Fatalf("Invalid step: %s", step) + is := ifstring.ParseIfString(step) + if !is.Matches(h.Triplet, builderName) { + log.Printf("[no match] %s", utils.ExpandEnvFromMap(step, env)) + continue } + log.Printf(" [match] %s", utils.ExpandEnvFromMap(is.Content, env)) } + fmt.Print("\n\n") log.Printf("Starting %s in %s with build environment for %s", userShell, buildPath, h.Triplet) log.Printf("Type 'exit' to leave the shell") @@ -235,16 +422,30 @@ func (p *Package) StartShell(h *host.Host) { cmd.Stdout = os.Stdout cmd.Stderr = os.Stderr - cmd.Env = append(cmd.Env, []string{ - "HOST=" + h.Triplet, - "PREFIX=" + h.GetEnvPath(), - "PATH=" + h.GetEnvPath() + "/native/bin:" + env["PATH"] + ":" + pathEnv, - "TERM=" + os.Getenv("TERM"), - }...) + hostTriplet := h.Triplet + if p.Type == "native" { + hostTriplet = builder.NativeTriplet() + } + overrides := map[string]string{ + "HOST": hostTriplet, + "PREFIX": utils.ToShellPath(h.GetEnvPath()), + "NATIVEPREFIX": utils.ToShellPath(nativePrefix), + "PATH": utils.BuildStepPATH(nativePrefix, h.GetEnvPath(), env["PATH"], pathEnv), + "TEMP": utils.ToShellPath(filepath.Join(nativePrefix, "_", "tmp")), + "TMP": utils.ToShellPath(filepath.Join(nativePrefix, "_", "tmp")), + "TMPDIR": utils.ToShellPath(filepath.Join(nativePrefix, "_", "tmp")), + "CYGWIN": "nodosfilewarning", + "MSYS": "nodosfilewarning", + } + if term := os.Getenv("TERM"); term != "" { + overrides["TERM"] = term + } for k, v := range env { - cmd.Env = append(cmd.Env, k+"="+v) + overrides[k] = v } + cmd.Env = utils.ProcessEnv(overrides) + writeDotEnv(path.Join(buildPath, "_source_me"), cmd.Env) err := cmd.Run() if err != nil { diff --git a/pack/cache.go b/pack/cache.go new file mode 100644 index 0000000..246d5e3 --- /dev/null +++ b/pack/cache.go @@ -0,0 +1,475 @@ +package pack + +import ( + "encoding/json" + "fmt" + "io" + "log" + "os" + "os/exec" + "path/filepath" + "strings" + "sync" + + "github.com/mrcyjanek/simplybs/host" +) + +// Remote build-cache assets live on a GitHub release. Paths under +// DataDir()/built are flattened with '+' so release asset names stay flat: +// +// x86_64-linux-gnu/zlib-1.3.1-deadbeef.tar.gz +// -> x86_64-linux-gnu+zlib-1.3.1-deadbeef.tar.gz +// +// Pull only requests assets for the packages needed by the current build +// (by short-hash filename). Push only uploads local files that are missing +// from the release (content changes produce a new short-hash name). +// +// Cache is enabled only when both SIMPLYBS_CACHE_TAG and SIMPLYBS_CACHE_REPO +// are set; EnsureBuilt then auto-pulls missing artifacts. + +const cacheAssetSuffixes = 3 // .info.txt, .tar.gz, _native.tar.gz + +var ( + remoteAssetsOnce sync.Once + remoteAssets map[string]bool + remoteAssetsErr error +) + +// CacheTag returns SIMPLYBS_CACHE_TAG (empty if unset). +func CacheTag() string { + return os.Getenv("SIMPLYBS_CACHE_TAG") +} + +// CacheRepo returns SIMPLYBS_CACHE_REPO (owner/repo; empty if unset). +func CacheRepo() string { + return os.Getenv("SIMPLYBS_CACHE_REPO") +} + +// CacheEnabled reports whether remote build cache is configured. +// Both SIMPLYBS_CACHE_TAG and SIMPLYBS_CACHE_REPO must be set. +func CacheEnabled() bool { + return CacheTag() != "" && CacheRepo() != "" +} + +func requireCacheConfig() (tag, repo string, err error) { + tag = CacheTag() + repo = CacheRepo() + if tag == "" || repo == "" { + return "", "", fmt.Errorf("cache: set both SIMPLYBS_CACHE_TAG and SIMPLYBS_CACHE_REPO") + } + return tag, repo, nil +} + +func ghCmd(args ...string) *exec.Cmd { + bin := os.Getenv("SIMPLYBS_GH") + if bin == "" { + bin = "gh" + } + repo := CacheRepo() + if repo == "" { + return exec.Command(bin, args...) + } + return exec.Command(bin, append([]string{"-R", repo}, args...)...) +} + +// AssetNameForRel converts a path relative to DataDir()/built into a flat +// release asset name. +func AssetNameForRel(rel string) string { + rel = filepath.ToSlash(rel) + if strings.Contains(rel, "/") { + return strings.ReplaceAll(rel, "/", "+") + } + return rel +} + +// RelFromAssetName reverses AssetNameForRel. +func RelFromAssetName(name string) string { + return strings.ReplaceAll(name, "+", "/") +} + +// BuiltRelPaths returns the paths (relative to DataDir()/built) for a +// package's cache artifacts on host h. +func (p *Package) BuiltRelPaths(h *host.Host) []string { + base := p.GenerateBuildPath(h, "built") + builtRoot := filepath.Join(host.DataDir(), "built") + relBase, err := filepath.Rel(builtRoot, base) + if err != nil { + log.Fatalf("cache: relative path for %s: %v", base, err) + } + relBase = filepath.ToSlash(relBase) + return []string{ + relBase + ".info.txt", + relBase + ".tar.gz", + relBase + "_native.tar.gz", + } +} + +// CollectNeededPackages returns pkg plus its transitive dependencies for h. +func CollectNeededPackages(pkgs []*Package, h *host.Host) []*Package { + seen := map[string]*Package{} + var walk func(*Package) + walk = func(p *Package) { + if p == nil { + return + } + if _, ok := seen[p.Package]; ok { + return + } + seen[p.Package] = p + for _, dep := range filteredDependencyPackages(p.Dependencies, h) { + walk(dep) + } + } + for _, p := range pkgs { + walk(p) + } + out := make([]*Package, 0, len(seen)) + for _, p := range seen { + out = append(out, p) + } + return out +} + +func neededAssetNames(pkgs []*Package, h *host.Host) []string { + needed := CollectNeededPackages(pkgs, h) + names := make([]string, 0, len(needed)*cacheAssetSuffixes) + for _, p := range needed { + for _, rel := range p.BuiltRelPaths(h) { + names = append(names, AssetNameForRel(rel)) + } + } + return names +} + +func loadRemoteAssets(tag string) (map[string]bool, error) { + remoteAssetsOnce.Do(func() { + remoteAssets = map[string]bool{} + cmd := ghCmd("release", "view", tag, "--json", "assets") + out, err := cmd.Output() + if err != nil { + stderr := "" + if exitErr, ok := err.(*exec.ExitError); ok { + stderr = string(exitErr.Stderr) + } + msg := strings.ToLower(stderr + string(out) + err.Error()) + if strings.Contains(msg, "not found") || strings.Contains(msg, "could not find") || strings.Contains(msg, "http 404") { + log.Printf("cache: release %q not found; treating as empty", tag) + return + } + remoteAssetsErr = fmt.Errorf("gh release view %s: %w%s", tag, err, formatStderr(stderr)) + return + } + var parsed struct { + Assets []struct { + Name string `json:"name"` + } `json:"assets"` + } + if err := json.Unmarshal(out, &parsed); err != nil { + remoteAssetsErr = err + return + } + for _, a := range parsed.Assets { + remoteAssets[a.Name] = true + } + }) + return remoteAssets, remoteAssetsErr +} + +func formatStderr(stderr string) string { + stderr = strings.TrimSpace(stderr) + if stderr == "" { + return "" + } + return ": " + stderr +} + +func resetRemoteAssetsCache() { + remoteAssetsOnce = sync.Once{} + remoteAssets = nil + remoteAssetsErr = nil +} + +func ensureRelease(tag string) error { + view := ghCmd("release", "view", tag) + if err := view.Run(); err == nil { + return nil + } + create := ghCmd("release", "create", tag, + "--title", "simplybs build cache", + "--notes", "Rolling cache of simplybs build artifacts (per-package, content-addressed by short hash).", + ) + create.Stdout = os.Stdout + create.Stderr = os.Stderr + return create.Run() +} + +func downloadAsset(tag, assetName, destPath string) error { + if err := os.MkdirAll(filepath.Dir(destPath), 0755); err != nil { + return err + } + staging, err := os.MkdirTemp("", "simplybs-cache-*") + if err != nil { + return err + } + defer os.RemoveAll(staging) + + cmd := ghCmd("release", "download", tag, "-p", assetName, "-D", staging) + cmd.Stdout = os.Stdout + cmd.Stderr = os.Stderr + if err := cmd.Run(); err != nil { + return err + } + src := filepath.Join(staging, assetName) + // gh may write the literal asset name; if the pattern matched a file with + // a different on-disk name, pick the sole file in staging. + if _, err := os.Stat(src); err != nil { + entries, readErr := os.ReadDir(staging) + if readErr != nil { + return err + } + if len(entries) != 1 || entries[0].IsDir() { + return fmt.Errorf("cache: expected one downloaded file for %s", assetName) + } + src = filepath.Join(staging, entries[0].Name()) + } + tmp := destPath + ".tmp" + if err := copyFile(src, tmp); err != nil { + return err + } + return os.Rename(tmp, destPath) +} + +func copyFile(src, dst string) error { + in, err := os.Open(src) + if err != nil { + return err + } + defer in.Close() + out, err := os.OpenFile(dst, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, 0644) + if err != nil { + return err + } + defer out.Close() + _, err = io.Copy(out, in) + return err +} + +// TryPullPackageCache downloads missing built artifacts for one package from +// the GitHub release cache. Returns true when a complete local cache is present +// afterwards (either already was, or was fetched). +func TryPullPackageCache(p *Package, h *host.Host) bool { + if !CacheEnabled() { + return false + } + tag := CacheTag() + assets, err := loadRemoteAssets(tag) + if err != nil { + log.Printf("cache: failed to list release assets: %v", err) + return false + } + builtRoot := filepath.Join(host.DataDir(), "built") + ok := true + for _, rel := range p.BuiltRelPaths(h) { + dest := filepath.Join(builtRoot, filepath.FromSlash(rel)) + if _, err := os.Stat(dest); err == nil { + continue + } + name := AssetNameForRel(rel) + if !assets[name] { + ok = false + continue + } + log.Printf("[%s][%s] cache pull: %s", h.Triplet, p.Package, name) + if err := downloadAsset(tag, name, dest); err != nil { + log.Printf("[%s][%s] cache pull failed for %s: %v", h.Triplet, p.Package, name, err) + ok = false + } + } + return ok +} + +// CachePull downloads only the built artifacts needed for pkgs on host h. +func CachePull(pkgs []*Package, h *host.Host) error { + tag, _, err := requireCacheConfig() + if err != nil { + return err + } + assets, err := loadRemoteAssets(tag) + if err != nil { + return fmt.Errorf("cache: list assets: %w", err) + } + + builtRoot := filepath.Join(host.DataDir(), "built") + names := neededAssetNames(pkgs, h) + toDownload := 0 + skippedLocal := 0 + missingRemote := 0 + for _, name := range names { + rel := RelFromAssetName(name) + dest := filepath.Join(builtRoot, filepath.FromSlash(rel)) + if _, err := os.Stat(dest); err == nil { + skippedLocal++ + continue + } + if !assets[name] { + missingRemote++ + continue + } + log.Printf("cache: download %s", name) + if err := downloadAsset(tag, name, dest); err != nil { + return fmt.Errorf("cache: download %s: %w", name, err) + } + toDownload++ + } + log.Printf("cache pull: downloaded=%d already-local=%d not-on-release=%d needed=%d tag=%s", + toDownload, skippedLocal, missingRemote, len(names), tag) + return nil +} + +// TryPushPackageCache uploads this package's built artifacts that are missing +// from the release. No-op when cache is disabled or everything is already remote. +func TryPushPackageCache(p *Package, h *host.Host) { + if !CacheEnabled() { + return + } + tag := CacheTag() + if err := ensureRelease(tag); err != nil { + log.Printf("[%s][%s] cache push: ensure release: %v", h.Triplet, p.Package, err) + return + } + assets, err := loadRemoteAssets(tag) + if err != nil { + log.Printf("[%s][%s] cache push: list assets: %v", h.Triplet, p.Package, err) + return + } + builtRoot := filepath.Join(host.DataDir(), "built") + var uploadPaths []string + var uploadNames []string + for _, rel := range p.BuiltRelPaths(h) { + name := AssetNameForRel(rel) + if assets[name] { + continue + } + abs := filepath.Join(builtRoot, filepath.FromSlash(rel)) + if _, err := os.Stat(abs); err != nil { + continue + } + uploadPaths = append(uploadPaths, abs) + uploadNames = append(uploadNames, name) + } + if len(uploadPaths) == 0 { + return + } + if err := uploadAssets(tag, uploadPaths, uploadNames); err != nil { + log.Printf("[%s][%s] cache push failed: %v", h.Triplet, p.Package, err) + return + } + for _, name := range uploadNames { + assets[name] = true + log.Printf("[%s][%s] cache push: %s", h.Triplet, p.Package, name) + } +} + +func uploadAssets(tag string, uploadPaths, uploadNames []string) error { + staging, err := os.MkdirTemp("", "simplybs-cache-upload-*") + if err != nil { + return err + } + defer os.RemoveAll(staging) + + staged := make([]string, 0, len(uploadPaths)) + for i, src := range uploadPaths { + dst := filepath.Join(staging, uploadNames[i]) + if err := copyFile(src, dst); err != nil { + return err + } + staged = append(staged, dst) + } + + log.Printf("cache push: uploading %d file(s) to %s...", len(staged), tag) + args := append([]string{"release", "upload", tag}, staged...) + cmd := ghCmd(args...) + cmd.Stdout = os.Stdout + cmd.Stderr = os.Stderr + if err := cmd.Run(); err != nil { + return fmt.Errorf("cache: upload: %w", err) + } + log.Printf("cache push: uploaded=%d tag=%s", len(staged), tag) + return nil +} + +// CachePush uploads local built artifacts that are not yet on the release. +// When pkgs is non-empty, only artifacts for those packages (and their deps) +// on host h are considered; otherwise every file under DataDir()/built is. +func CachePush(pkgs []*Package, h *host.Host) error { + tag, _, err := requireCacheConfig() + if err != nil { + return err + } + if err := ensureRelease(tag); err != nil { + return fmt.Errorf("cache: ensure release: %w", err) + } + resetRemoteAssetsCache() + assets, err := loadRemoteAssets(tag) + if err != nil { + return fmt.Errorf("cache: list assets: %w", err) + } + + builtRoot := filepath.Join(host.DataDir(), "built") + var uploadPaths []string + var uploadNames []string + + consider := func(absPath, name string) { + if assets[name] { + return + } + uploadPaths = append(uploadPaths, absPath) + uploadNames = append(uploadNames, name) + } + + if len(pkgs) > 0 && h != nil { + for _, name := range neededAssetNames(pkgs, h) { + rel := RelFromAssetName(name) + abs := filepath.Join(builtRoot, filepath.FromSlash(rel)) + if _, err := os.Stat(abs); err != nil { + continue + } + consider(abs, name) + } + } else { + if _, err := os.Stat(builtRoot); os.IsNotExist(err) { + log.Printf("cache: built dir not found: %s", builtRoot) + return nil + } + err := filepath.WalkDir(builtRoot, func(path string, d os.DirEntry, err error) error { + if err != nil { + return err + } + if d.IsDir() { + return nil + } + rel, err := filepath.Rel(builtRoot, path) + if err != nil { + return err + } + consider(path, AssetNameForRel(rel)) + return nil + }) + if err != nil { + return err + } + } + + if len(uploadPaths) == 0 { + log.Printf("cache push: nothing to upload (tag=%s remote-assets=%d)", tag, len(assets)) + return nil + } + + if err := uploadAssets(tag, uploadPaths, uploadNames); err != nil { + return err + } + for _, name := range uploadNames { + assets[name] = true + } + return nil +} diff --git a/pack/cache_test.go b/pack/cache_test.go new file mode 100644 index 0000000..0bdd6df --- /dev/null +++ b/pack/cache_test.go @@ -0,0 +1,413 @@ +package pack + +import ( + "encoding/json" + "fmt" + "os" + "path/filepath" + "strings" + "testing" + + "github.com/mrcyjanek/simplybs/host" +) + +func chdirRepoRoot(t *testing.T) { + t.Helper() + wd, err := os.Getwd() + if err != nil { + t.Fatal(err) + } + for { + if _, err := os.Stat(filepath.Join(wd, "packages", "native", "_.json")); err == nil { + if err := os.Chdir(wd); err != nil { + t.Fatal(err) + } + return + } + parent := filepath.Dir(wd) + if parent == wd { + t.Fatal("could not find repo root (packages/native/_.json)") + } + wd = parent + } +} + +func TestAssetNameRoundTrip(t *testing.T) { + cases := []string{ + "zlib-1.3.1-deadbeef.tar.gz", + "x86_64-linux-gnu/zlib-1.3.1-deadbeef.tar.gz", + "x86_64-linux-gnu/native_foo/bar-1.0-abcd1234.info.txt", + } + for _, rel := range cases { + name := AssetNameForRel(rel) + got := RelFromAssetName(name) + if filepath.ToSlash(got) != filepath.ToSlash(rel) { + t.Fatalf("round-trip %q -> %q -> %q", rel, name, got) + } + if rel != filepath.Base(rel) && !containsPlus(name) { + t.Fatalf("expected '+' in asset name for nested path, got %q", name) + } + } +} + +func containsPlus(s string) bool { + for i := 0; i < len(s); i++ { + if s[i] == '+' { + return true + } + } + return false +} + +func TestCacheEnabledRequiresTagAndRepo(t *testing.T) { + t.Setenv("SIMPLYBS_CACHE_TAG", "") + t.Setenv("SIMPLYBS_CACHE_REPO", "") + if CacheEnabled() { + t.Fatal("expected cache disabled with neither set") + } + t.Setenv("SIMPLYBS_CACHE_TAG", "v0-sbs-test") + if CacheEnabled() { + t.Fatal("expected cache disabled with only TAG set") + } + t.Setenv("SIMPLYBS_CACHE_TAG", "") + t.Setenv("SIMPLYBS_CACHE_REPO", "owner/repo") + if CacheEnabled() { + t.Fatal("expected cache disabled with only REPO set") + } + t.Setenv("SIMPLYBS_CACHE_TAG", "v0-sbs-test") + t.Setenv("SIMPLYBS_CACHE_REPO", "owner/repo") + if !CacheEnabled() { + t.Fatal("expected cache enabled when both set") + } + if CacheTag() != "v0-sbs-test" || CacheRepo() != "owner/repo" { + t.Fatalf("CacheTag/CacheRepo = %q / %q", CacheTag(), CacheRepo()) + } +} + +func TestRequireCacheConfig(t *testing.T) { + t.Setenv("SIMPLYBS_CACHE_TAG", "") + t.Setenv("SIMPLYBS_CACHE_REPO", "owner/repo") + if _, _, err := requireCacheConfig(); err == nil { + t.Fatal("expected error when TAG missing") + } + t.Setenv("SIMPLYBS_CACHE_TAG", "v0-sbs-test") + t.Setenv("SIMPLYBS_CACHE_REPO", "") + if _, _, err := requireCacheConfig(); err == nil { + t.Fatal("expected error when REPO missing") + } + t.Setenv("SIMPLYBS_CACHE_REPO", "owner/repo") + tag, repo, err := requireCacheConfig() + if err != nil || tag != "v0-sbs-test" || repo != "owner/repo" { + t.Fatalf("got tag=%q repo=%q err=%v", tag, repo, err) + } +} + +func TestBuiltRelPathsNativeAndHost(t *testing.T) { + chdirRepoRoot(t) + t.Setenv("SIMPLYBS_DATA_DIR", t.TempDir()) + pkg, err := FindPackage("zlib") + if err != nil { + t.Fatal(err) + } + h := host.SupportedHosts["x86_64-linux-gnu"] + rels := pkg.BuiltRelPaths(h) + if len(rels) != 3 { + t.Fatalf("expected 3 paths, got %v", rels) + } + for _, rel := range rels { + if filepath.ToSlash(rel) != rel { + t.Fatalf("expected slash paths, got %q", rel) + } + if rel == filepath.Base(rel) { + t.Fatalf("host package should be under triplet dir, got %q", rel) + } + name := AssetNameForRel(rel) + if RelFromAssetName(name) != rel { + t.Fatalf("asset encoding broken for %q", rel) + } + } + + native, err := FindPackage("native/zlib") + if err != nil { + t.Fatal(err) + } + nrels := native.BuiltRelPaths(h) + for _, rel := range nrels { + if rel != filepath.Base(rel) { + t.Fatalf("native package should be flat under built/, got %q", rel) + } + } +} + +func TestNeededAssetNamesIsSelective(t *testing.T) { + chdirRepoRoot(t) + t.Setenv("SIMPLYBS_DATA_DIR", t.TempDir()) + pkg, err := FindPackage("zlib") + if err != nil { + t.Fatal(err) + } + h := host.SupportedHosts["x86_64-linux-gnu"] + names := neededAssetNames([]*Package{pkg}, h) + if len(names) < 3 { + t.Fatalf("expected at least root package assets, got %d", len(names)) + } + // Must include transitive deps, but remain far below a full-world dump. + all := GetAllPackages() + world := neededAssetNames(all, h) + if len(names) >= len(world) { + t.Fatalf("zlib tree (%d) should be smaller than world (%d)", len(names), len(world)) + } + if len(names)%3 != 0 { + t.Fatalf("asset count should be multiple of 3, got %d", len(names)) + } +} + +func TestCachePullDownloadsOnlyNeededAssets(t *testing.T) { + chdirRepoRoot(t) + dataDir := t.TempDir() + t.Setenv("SIMPLYBS_DATA_DIR", dataDir) + t.Setenv("SIMPLYBS_CACHE_TAG", "v0-sbs-test-linux-amd64") + t.Setenv("SIMPLYBS_CACHE_REPO", "owner/simplybs-cache") + + pkg, err := FindPackage("zlib") + if err != nil { + t.Fatal(err) + } + h := host.SupportedHosts["x86_64-linux-gnu"] + needed := neededAssetNames([]*Package{pkg}, h) + if len(needed) < 6 { + t.Fatalf("expected a non-trivial zlib tree, got %d assets", len(needed)) + } + + // Release contains needed assets plus a large pile of unrelated ones. + type asset struct { + Name string `json:"name"` + } + payload := struct { + Assets []asset `json:"assets"` + }{} + for _, name := range needed { + payload.Assets = append(payload.Assets, asset{Name: name}) + } + for i := 0; i < 1000; i++ { + payload.Assets = append(payload.Assets, asset{Name: fmt.Sprintf("unrelated-pkg-%d-deadbeef.tar.gz", i)}) + } + assetsPath := filepath.Join(t.TempDir(), "assets.json") + raw, err := json.Marshal(payload) + if err != nil { + t.Fatal(err) + } + if err := os.WriteFile(assetsPath, raw, 0644); err != nil { + t.Fatal(err) + } + + logPath := filepath.Join(t.TempDir(), "gh.log") + fakeGh := filepath.Join(t.TempDir(), "gh") + script := `#!/bin/bash +set -euo pipefail +echo "$*" >> "$FAKE_GH_LOG" +cmd=$1; shift +case "$cmd" in + -R) shift; cmd=$1; shift ;; +esac +case "$cmd" in + release) + sub=$1; shift + case "$sub" in + view) cat "$FAKE_GH_ASSETS" ;; + download) + pattern=""; dest="." + while [[ $# -gt 0 ]]; do + case "$1" in + -p) pattern=$2; shift 2 ;; + -D) dest=$2; shift 2 ;; + *) shift ;; + esac + done + echo "DOWNLOAD $pattern" >> "$FAKE_GH_LOG" + printf 'ok' > "$dest/$pattern" + ;; + *) echo "bad sub $sub" >&2; exit 1 ;; + esac + ;; + *) echo "bad $cmd" >&2; exit 1 ;; +esac +` + if err := os.WriteFile(fakeGh, []byte(script), 0755); err != nil { + t.Fatal(err) + } + t.Setenv("SIMPLYBS_GH", fakeGh) + t.Setenv("FAKE_GH_LOG", logPath) + t.Setenv("FAKE_GH_ASSETS", assetsPath) + + resetRemoteAssetsCache() + if err := CachePull([]*Package{pkg}, h); err != nil { + t.Fatal(err) + } + + logData, err := os.ReadFile(logPath) + if err != nil { + t.Fatal(err) + } + downloads := 0 + for _, line := range strings.Split(string(logData), "\n") { + if strings.HasPrefix(line, "DOWNLOAD ") { + downloads++ + name := strings.TrimPrefix(line, "DOWNLOAD ") + if strings.HasPrefix(name, "unrelated-pkg-") { + t.Fatalf("downloaded unrelated asset %q", name) + } + } + } + if downloads != len(needed) { + t.Fatalf("downloaded %d assets, want %d needed", downloads, len(needed)) + } + + builtRoot := filepath.Join(host.DataDir(), "built") + for _, name := range needed { + dest := filepath.Join(builtRoot, filepath.FromSlash(RelFromAssetName(name))) + if _, err := os.Stat(dest); err != nil { + t.Fatalf("missing local cache file for %s: %v", name, err) + } + } + + // Second pull should not hit release download again. + resetRemoteAssetsCache() + if err := os.WriteFile(logPath, nil, 0644); err != nil { + t.Fatal(err) + } + if err := CachePull([]*Package{pkg}, h); err != nil { + t.Fatal(err) + } + logData, err = os.ReadFile(logPath) + if err != nil { + t.Fatal(err) + } + for _, line := range strings.Split(string(logData), "\n") { + if strings.HasPrefix(line, "DOWNLOAD ") { + t.Fatalf("second pull re-downloaded %q", line) + } + } +} + +func TestTryPushPackageCacheUploadsOnlyMissing(t *testing.T) { + chdirRepoRoot(t) + dataDir := t.TempDir() + t.Setenv("SIMPLYBS_DATA_DIR", dataDir) + t.Setenv("SIMPLYBS_CACHE_TAG", "v0-sbs-test-linux-amd64") + t.Setenv("SIMPLYBS_CACHE_REPO", "owner/simplybs-cache") + + pkg, err := FindPackage("native/zlib") + if err != nil { + t.Fatal(err) + } + h := host.SupportedHosts["x86_64-linux-gnu"] + rels := pkg.BuiltRelPaths(h) + builtRoot := filepath.Join(host.DataDir(), "built") + for _, rel := range rels { + path := filepath.Join(builtRoot, filepath.FromSlash(rel)) + if err := os.MkdirAll(filepath.Dir(path), 0755); err != nil { + t.Fatal(err) + } + if err := os.WriteFile(path, []byte("payload-"+rel), 0644); err != nil { + t.Fatal(err) + } + } + + // Remote already has the .info.txt; the two archives should upload. + already := AssetNameForRel(rels[0]) + assetsPath := filepath.Join(t.TempDir(), "assets.json") + if err := os.WriteFile(assetsPath, []byte(`{"assets":[{"name":"`+already+`"}]}`), 0644); err != nil { + t.Fatal(err) + } + logPath := filepath.Join(t.TempDir(), "gh.log") + fakeGh := filepath.Join(t.TempDir(), "gh") + script := `#!/bin/bash +set -euo pipefail +echo "$*" >> "$FAKE_GH_LOG" +cmd=$1; shift +case "$cmd" in + -R) shift; cmd=$1; shift ;; +esac +case "$cmd" in + release) + sub=$1; shift + case "$sub" in + view) cat "$FAKE_GH_ASSETS" ;; + create) echo CREATE >> "$FAKE_GH_LOG" ;; + upload) + echo "UPLOAD $*" >> "$FAKE_GH_LOG" + ;; + *) echo "bad sub $sub" >&2; exit 1 ;; + esac + ;; + *) echo "bad $cmd" >&2; exit 1 ;; +esac +` + if err := os.WriteFile(fakeGh, []byte(script), 0755); err != nil { + t.Fatal(err) + } + t.Setenv("SIMPLYBS_GH", fakeGh) + t.Setenv("FAKE_GH_LOG", logPath) + t.Setenv("FAKE_GH_ASSETS", assetsPath) + + resetRemoteAssetsCache() + TryPushPackageCache(pkg, h) + + logData, err := os.ReadFile(logPath) + if err != nil { + t.Fatal(err) + } + logStr := string(logData) + if !strings.Contains(logStr, "UPLOAD ") { + t.Fatalf("expected upload, log=%s", logStr) + } + if strings.Contains(logStr, already) { + t.Fatalf("should not re-upload existing asset %s; log=%s", already, logStr) + } + wantTar := AssetNameForRel(rels[1]) + wantNative := AssetNameForRel(rels[2]) + if !strings.Contains(logStr, wantTar) || !strings.Contains(logStr, wantNative) { + t.Fatalf("expected upload of %s and %s; log=%s", wantTar, wantNative, logStr) + } + + // Second push should upload nothing. + if err := os.WriteFile(logPath, nil, 0644); err != nil { + t.Fatal(err) + } + TryPushPackageCache(pkg, h) + logData, err = os.ReadFile(logPath) + if err != nil { + t.Fatal(err) + } + if strings.Contains(string(logData), "UPLOAD ") { + t.Fatalf("second push should be a no-op, log=%s", logData) + } +} + +func TestTryPushDisabledWithoutCacheEnv(t *testing.T) { + t.Setenv("SIMPLYBS_CACHE_TAG", "") + t.Setenv("SIMPLYBS_CACHE_REPO", "") + // Must not panic / call gh when disabled. + TryPushPackageCache(&Package{Package: "zlib", Version: "1.0"}, host.SupportedHosts["x86_64-linux-gnu"]) +} + +func TestCollectNeededPackagesIncludesDeps(t *testing.T) { + chdirRepoRoot(t) + pkg, err := FindPackage("zlib") + if err != nil { + t.Fatal(err) + } + h := host.SupportedHosts["x86_64-linux-gnu"] + needed := CollectNeededPackages([]*Package{pkg}, h) + found := map[string]bool{} + for _, p := range needed { + found[p.Package] = true + } + if !found["zlib"] { + t.Fatal("missing zlib") + } + if !found["native/make"] { + t.Fatal("expected transitive native/make dependency") + } +} diff --git a/pack/export_env.go b/pack/export_env.go new file mode 100644 index 0000000..06b28df --- /dev/null +++ b/pack/export_env.go @@ -0,0 +1,112 @@ +package pack + +import ( + "log" + "strings" + + "github.com/mrcyjanek/simplybs/builder" + "github.com/mrcyjanek/simplybs/host" + "github.com/mrcyjanek/simplybs/utils" + "github.com/mrcyjanek/simplybs/utils/ifstring" +) + +type EnvKV struct { + K string + V string +} + +type exportEnvContext struct { + memo map[string][]EnvKV + visiting map[string]bool +} + +func newExportEnvContext() *exportEnvContext { + return &exportEnvContext{ + memo: make(map[string][]EnvKV), + visiting: make(map[string]bool), + } +} + +func copyEnv(m map[string]string) map[string]string { + out := make(map[string]string, len(m)) + for k, v := range m { + out[k] = v + } + return out +} + +func envKeyFromLine(line string) string { + idx := strings.Index(line, "=") + if idx == -1 { + return "" + } + return line[:idx] +} + +func (ctx *exportEnvContext) resolvedExportEnv(p *Package, h *host.Host) []EnvKV { + key := p.Package + "\x00" + h.Triplet + if ctx.visiting[key] { + log.Fatalf("export-env cycle involving package %s", p.Package) + } + if cached, ok := ctx.memo[key]; ok { + return cached + } + ctx.visiting[key] = true + defer delete(ctx.visiting, key) + + filtered := ifstring.FilterContent(p.ExportEnv, h.Triplet, builder.GetName()) + ownKeys := make(map[string]bool, len(filtered)) + for _, line := range filtered { + ownKeys[envKeyFromLine(line)] = true + } + skipFromDeps := map[string]bool{} + for _, k := range []string{"CFLAGS", "CXXFLAGS", "CPPFLAGS", "LDFLAGS", "LIBRARY_PATH", "PKG_CONFIG_PATH"} { + if ownKeys[k] { + skipFromDeps[k] = true + } + } + + base := copyEnv(p.minimalEnvWithStaging(h, p.baseBuildPath(h, "staging"))) + // Export-env describes the toolchain for h.Triplet; HOST/TARGET must match the + // build target even when the exporting package is type "native". + base["HOST"] = h.Triplet + base["TARGET"] = h.Triplet + for _, dep := range filteredDependencyPackages(p.Dependencies, h) { + for _, e := range ctx.resolvedExportEnv(dep, h) { + if skipFromDeps[e.K] { + continue + } + base[e.K] = e.V + } + } + + after := utils.AppendEnv(copyEnv(base), p.ExportEnv, h) + + result := make([]EnvKV, 0, len(filtered)) + for _, line := range filtered { + k := envKeyFromLine(line) + if v, ok := after[k]; ok { + result = append(result, EnvKV{K: k, V: v}) + } + } + ctx.memo[key] = result + return result +} + +func (p *Package) GetExportEnv(h *host.Host) map[string]string { + ctx := newExportEnvContext() + kvs := ctx.resolvedExportEnv(p, h) + env := make(map[string]string, len(kvs)) + for _, e := range kvs { + env[e.K] = e.V + } + return env +} + +func mergeResolvedExportEnv(env map[string]string, ctx *exportEnvContext, deps []*Package, h *host.Host) { + for _, dep := range deps { + for _, e := range ctx.resolvedExportEnv(dep, h) { + env[e.K] = e.V + } + } +} diff --git a/pack/info.go b/pack/info.go index 1c5c10b..b65a286 100644 --- a/pack/info.go +++ b/pack/info.go @@ -15,24 +15,54 @@ import ( "github.com/mrcyjanek/simplybs/crash" "github.com/mrcyjanek/simplybs/host" "github.com/mrcyjanek/simplybs/utils" + "github.com/mrcyjanek/simplybs/utils/ifstring" ) +func (p *Package) prefixPath(h *host.Host) string { + if p.Type == "native" { + return h.GetNativeEnvPath() + } + return h.GetEnvPath() +} + +func (p *Package) homePath(h *host.Host) string { + return filepath.Join(p.prefixPath(h), "home", "user") +} + +func (p *Package) FilterForHost(h *host.Host) *Package { + filtered := &Package{ + Package: p.Package, + Version: p.Version, + Type: p.Type, + Download: p.Download, + Dependencies: []string{}, + } + builderName := builder.GetName() + filtered.Dependencies = ifstring.FilterContent(p.Dependencies, h.Triplet, builderName) + filtered.ExportEnv = ifstring.FilterContent(p.ExportEnv, h.Triplet, builderName) + filtered.Build.Env = ifstring.FilterContent(p.Build.Env, h.Triplet, builderName) + filtered.Build.Steps = ifstring.FilterContent(p.Build.Steps, h.Triplet, builderName) + + return filtered +} + func (p *Package) GeneratePackageInfo(h *host.Host) string { pkgs := map[string]interface{}{} - pkgs["_target"] = p + pkgs["_target"] = p.FilterForHost(h) for _, dep := range p.Dependencies { - if strings.Contains(dep, ":") { - dep = dep[strings.Index(dep, ":")+1:] - } + is := ifstring.ParseIfString(dep) + dep := is.Content pkg, err := FindPackage(dep) if err != nil { log.Fatalf("Package %s not found in info", dep) } - pkgs[dep] = pkg + pkgs[dep] = pkg.FilterForHost(h) } env := p.GetEnvForLogs(h) delete(env, "PATH") + delete(env, "PREFIX") pkgs["_env"] = env + pkgs["_prefix"] = p.prefixPath(h) info, err := json.MarshalIndent(pkgs, "", " ") crash.Handle(err) return string(info) @@ -53,17 +83,30 @@ func (p *Package) ShortName(h *host.Host) string { return p.Package + "-" + p.Version + "-" + p.GeneratePackageInfoShortHash(h) } +func (p *Package) GenerateSourceBuildPath(download *Download) string { + if download.Kind == "git" { + return utils.SourcePathForGitURL(download.URL) + } + return utils.SourcePathForFileURL(download.URL) +} + +func (p *Package) baseBuildPath(h *host.Host, kind string) string { + safeName := strings.ReplaceAll(p.Package+"-"+p.Version, "/", "_") + if p.Type == "native" { + return filepath.Join(host.DataDir(), kind, safeName) + } + return filepath.Join(host.DataDir(), kind, h.Triplet, safeName) +} + func (p *Package) GenerateBuildPath(h *host.Host, kind string) string { if kind == "source" { - var name string - if p.Download.Kind == "git" { - name = filepath.Base(p.Download.URL) + "-" + p.Download.Sha256[0:8] + ".git" - } else { - name = filepath.Base(p.Download.URL) - } - return filepath.Join(host.DataDir(), "..", kind, name) + log.Fatalf("Source build path is not supported") } - return filepath.Join(host.DataDir(), kind, h.Triplet, p.ShortName(h)) + safeName := strings.ReplaceAll(p.ShortName(h), "/", "_") + if p.Type == "native" { + return filepath.Join(host.DataDir(), kind, safeName) + } + return filepath.Join(host.DataDir(), kind, h.Triplet, safeName) } func getNumCores() int { @@ -74,50 +117,49 @@ func getNumCores() int { return cores } -func (p *Package) GetEnv(h *host.Host) map[string]string { +func (p *Package) minimalEnvWithStaging(h *host.Host, stagingPath string) map[string]string { getwd, err := os.Getwd() crash.Handle(err) - env := map[string]string{ - "PATH": h.GetEnvPath() + "/native/bin:" + utils.GetHostPath(), - "HOST": h.Triplet, - "PREFIX": h.GetEnvPath(), - "HOME": h.GetEnvPath() + "/home/user", - "HOST_PREFIX": h.GetEnvPath(), - "NUM_CORES": strconv.Itoa(runtime.NumCPU()), - "PATCH_DIR": filepath.Join(getwd, "patches"), - } - - env = utils.AppendEnv(env, builder.HostBuilder.GlobalEnv, h) + hostTriplet := h.Triplet + targetTriplet := h.Triplet if p.Type == "native" { - env = utils.AppendEnv(env, []string{ - "all:CFLAGS=$CFLAGS -I" + h.GetEnvPath() + "/native/include", - "all:LDFLAGS=$LDFLAGS -L" + h.GetEnvPath() + "/native/lib", - "all:LD_LIBRARY_PATH=$LD_LIBRARY_PATH:" + h.GetEnvPath() + "/native/lib", - "all:PKG_CONFIG_PATH=$PKG_CONFIG_PATH:" + h.GetEnvPath() + "/native/lib/pkgconfig", - "all:LIBRARY_PATH=$LIBRARY_PATH:" + h.GetEnvPath() + "/native/lib", - }, h) - } else { - env = utils.AppendEnv(env, []string{ - "all:CFLAGS=-I" + h.GetEnvPath() + "/include", - "all:LDFLAGS=-L" + h.GetEnvPath() + "/lib", - "all:LD_LIBRARY_PATH=" + h.GetEnvPath() + "/lib", - "all:PKG_CONFIG_PATH=" + h.GetEnvPath() + "/lib/pkgconfig", - "all:LIBRARY_PATH=" + h.GetEnvPath() + "/lib", - }, h) + hostTriplet = builder.NativeTriplet() + targetTriplet = builder.NativeTriplet() } - if p.Type != "native" { - env = utils.AppendEnv(env, h.Env, h) + return map[string]string{ + "PATH": utils.BuildStepPATH(h.GetNativeEnvPath(), h.GetEnvPath(), "", utils.GetHostPath()), + "HOST": hostTriplet, + "TARGET": targetTriplet, + "PREFIX": utils.ToShellPath(h.GetEnvPath()), + "NATIVEPREFIX": utils.ToShellPath(h.GetNativeEnvPath()), + "HOME": utils.ToShellPath(p.homePath(h)), + "HOST_PREFIX": utils.ToShellPath(h.GetEnvPath()), + "NUM_CORES": strconv.Itoa(getNumCores()), + "PATCH_DIR": utils.ToShellPath(filepath.Join(getwd, "patches")), + "STAGING_DIR": utils.ToShellPath(stagingPath), + "PKG_CONFIG_ALLOW_CROSS": "1", + "PKG_CONFIG_SYSROOT_DIR": utils.ToShellPath(h.GetEnvPath()), + "BUILDER_GOOS": runtime.GOOS, + "BUILDER_GOARCH": runtime.GOARCH, } +} + +func (p *Package) minimalEnv(h *host.Host) map[string]string { + return p.minimalEnvWithStaging(h, p.GenerateBuildPath(h, "staging")) +} + +func (p *Package) GetEnv(h *host.Host) map[string]string { + ctx := newExportEnvContext() + env := p.minimalEnv(h) + mergeResolvedExportEnv(env, ctx, filteredDependencyPackages(p.Dependencies, h), h) env = utils.AppendEnv(env, p.Build.Env, h) return env } func (p *Package) GetEnvForLogs(h *host.Host) map[string]string { + ctx := newExportEnvContext() env := map[string]string{} - env = utils.AppendEnv(env, builder.HostBuilder.GlobalEnv, h) + mergeResolvedExportEnv(env, ctx, filteredDependencyPackages(p.Dependencies, h), h) env = utils.AppendEnv(env, p.Build.Env, h) - if p.Type != "native" { - env = utils.AppendEnv(env, h.Env, h) - } return env } diff --git a/pack/main.go b/pack/main.go index 35f1f21..6e36914 100644 --- a/pack/main.go +++ b/pack/main.go @@ -3,6 +3,7 @@ package pack import ( "encoding/json" "fmt" + "maps" "os" "path/filepath" "runtime" @@ -11,28 +12,39 @@ import ( "github.com/mrcyjanek/simplybs/builder" "github.com/mrcyjanek/simplybs/crash" "github.com/mrcyjanek/simplybs/host" - "github.com/ryanuber/go-glob" + "github.com/mrcyjanek/simplybs/utils" + "github.com/mrcyjanek/simplybs/utils/ifstring" ) +type Download struct { + Kind string `json:"kind"` + URL string `json:"url"` + Sha256 string `json:"sha256"` + Path string `json:"path"` +} + +type StepProfile struct { + Unset []string `json:"unset,omitempty"` + Env []string `json:"env,omitempty"` +} + type Package struct { - Package string `json:"package"` - Version string `json:"version"` - Type string `json:"type"` - Download struct { - Kind string `json:"kind"` - URL string `json:"url"` - Sha256 string `json:"sha256"` - } `json:"download"` - Build struct { - Env []string `json:"env"` - Steps []string `json:"steps"` + Package string `json:"package"` + Version string `json:"version"` + Type string `json:"type"` + Download []*Download `json:"download"` + Build struct { + Env []string `json:"env"` + Profiles map[string]StepProfile `json:"profiles,omitempty"` + Steps []string `json:"steps"` } `json:"build"` Dependencies []string `json:"dependencies"` + ExportEnv []string `json:"export-env"` } type BuiltFile struct { Builder string `json:"builder"` // e.g. "darwin_arm64" - Target string `json:"target"` // e.g. "aarch64-apple-ios" + Target string `json:"target"` // e.g. "*:aarch64-apple-ios" ID string `json:"id"` // short hash InfoPath string `json:"info_path"` // relative path to .info.txt ArchPath string `json:"arch_path"` // relative path to .tar.gz @@ -45,11 +57,7 @@ type PackageWithBuilds struct { } var bootstrapPackages = []string{ - "native/bootstrap/perl", - "native/bootstrap/cpan/archive-cpio", - "native/bootstrap/cpan/archive-zip", - "native/bootstrap/cpan/sub-override", - "native/bootstrap/strip-nondeterminism", + // "*:*:native/bootstrap/strip-nondeterminism", } func FindPackage(name string) (*Package, error) { @@ -66,16 +74,15 @@ func FindPackage(name string) (*Package, error) { if !strings.Contains(pkg.Package, "/bootstrap/") { for _, pkgName := range bootstrapPackages { - pkg.Dependencies = append(pkg.Dependencies, "all:"+pkgName) + pkg.Dependencies = append(pkg.Dependencies, pkgName) } - pkg.Build.Steps = append(pkg.Build.Steps, "all:$PREFIX/native/bootstrap/bin/strip-nondeterminism-recursive --directory $STAGING_DIR") + // pkg.Build.Steps = append(pkg.Build.Steps, "*:$NATIVEPREFIX/bootstrap/bin/perl $NATIVEPREFIX/bootstrap/bin/strip-nondeterminism-recursive --directory $STAGING_DIR") } return &pkg, nil } func PrintPackage(pkgName string, host string) { depsByLevel := collectDependenciesByLevel(pkgName, host) - userPkg, err := FindPackage(pkgName) crash.Handle(err) fmt.Printf("0: %s (version: %s)\n", pkgName, userPkg.Version) @@ -86,7 +93,7 @@ func PrintPackage(pkgName string, host string) { continue } - for i := 0; i < len(deps); i++ { + for i := range deps { for j := i + 1; j < len(deps); j++ { if deps[i] > deps[j] { deps[i], deps[j] = deps[j], deps[i] @@ -116,7 +123,8 @@ func ScanBuiltFiles(packageName string, packageVersion string) []BuiltFile { for _, builder := range builder.Builders { for _, target := range targets { - buildOutputDir := filepath.Join(buildlibDir, builder, "built", target, packageName) + safePackageName := strings.ReplaceAll(packageName, "/", "_") + buildOutputDir := filepath.Join(buildlibDir, builder, "built", target, safePackageName) buildOutputDir = filepath.Dir(buildOutputDir) if _, err := os.Stat(buildOutputDir); os.IsNotExist(err) { @@ -179,6 +187,7 @@ func Cleanup() { packages := GetAllPackages() keepFiles := make(map[string]bool) + keepSources := make(map[string]bool) builders := []string{runtime.GOOS + "_" + runtime.GOARCH} targets := make([]string, 0, len(host.SupportedHosts)) @@ -192,16 +201,45 @@ func Cleanup() { currentBuildID := pkg.GeneratePackageInfoShortHash(host.SupportedHosts[target]) currentFileName := fmt.Sprintf("%s-%s-%s", pkg.Package, pkg.Version, currentBuildID) - archPath := filepath.Join(builder, "built", target, currentFileName+".tar.gz") - infoPath := filepath.Join(builder, "built", target, currentFileName+".info.txt") + currentFileName = strings.ReplaceAll(currentFileName, "/", "_") + + var archPath, archNativePath, infoPath string + if pkg.Type == "native" { + // Native archives live flat under built/ (no target triplet dir). + archPath = filepath.Join(builder, "built", currentFileName+".tar.gz") + archNativePath = filepath.Join(builder, "built", currentFileName+"_native.tar.gz") + infoPath = filepath.Join(builder, "built", currentFileName+".info.txt") + } else { + archPath = filepath.Join(builder, "built", target, currentFileName+".tar.gz") + archNativePath = filepath.Join(builder, "built", target, currentFileName+"_native.tar.gz") + infoPath = filepath.Join(builder, "built", target, currentFileName+".info.txt") + } + + // Walk uses ToSlash; keep keys must match on Windows (filepath.Join uses '\'). + keepFiles[filepath.ToSlash(archPath)] = true + keepFiles[filepath.ToSlash(archNativePath)] = true + keepFiles[filepath.ToSlash(infoPath)] = true + } + } - keepFiles[archPath] = true - keepFiles[infoPath] = true + var keepFilesCopy = make(map[string]bool) + maps.Copy(keepFilesCopy, keepFiles) + for k := range keepFilesCopy { + if strings.HasSuffix(k, ".tar.gz") && !strings.HasSuffix(k, "_native.tar.gz") { + keepFiles[strings.TrimSuffix(k, ".tar.gz")+"_native.tar.gz"] = true + } + } + + for _, download := range pkg.Download { + sourcePath := pkg.GenerateSourceBuildPath(download) + relPath, err := filepath.Rel(buildlibDir, sourcePath) + if err == nil { + keepSources[filepath.ToSlash(relPath)] = true } } } - fmt.Printf("Cleanup: Will keep %d current build files\n", len(keepFiles)) + fmt.Printf("Cleanup: Will keep %d current build files and %d source files\n", len(keepFiles), len(keepSources)) for _, builder := range builders { builderDir := filepath.Join(buildlibDir, builder) @@ -246,11 +284,51 @@ func Cleanup() { for _, dir := range []string{workDir, stagingDir, envDir} { if _, err := os.Stat(dir); !os.IsNotExist(err) { fmt.Printf("Removing directory: %s\n", filepath.Base(dir)) - os.RemoveAll(dir) + utils.RemoveAll(dir) } } } + sourceDir := filepath.Join(buildlibDir, "source") + if _, err := os.Stat(sourceDir); !os.IsNotExist(err) { + err := filepath.WalkDir(sourceDir, func(path string, d os.DirEntry, err error) error { + if err != nil { + return err + } + + if d.IsDir() { + return nil + } + + relPath, err := filepath.Rel(buildlibDir, path) + if err != nil { + return nil + } + + relPath = filepath.ToSlash(relPath) + + if !keepSources[relPath] { + fmt.Printf("Removing stale source file: %s\n", relPath) + os.Remove(path) + } + + return nil + }) + if err != nil { + fmt.Printf("Error walking source directory %s: %v\n", sourceDir, err) + } + + filepath.WalkDir(sourceDir, func(path string, d os.DirEntry, err error) error { + if err != nil { + return err + } + if d.IsDir() && path != sourceDir { + os.Remove(path) + } + return nil + }) + } + fmt.Println("Cleanup completed!") } @@ -261,10 +339,8 @@ func collectDependenciesByLevel(pkgName string, host string) [][]string { currentLevel := []string{pkgName} visited[pkgName] = true levels = append(levels, []string{}) - for len(currentLevel) > 0 { nextLevel := []string{} - for _, currentPkg := range currentLevel { pkg, err := FindPackage(currentPkg) if err != nil { @@ -272,20 +348,14 @@ func collectDependenciesByLevel(pkgName string, host string) [][]string { } for _, dep := range pkg.Dependencies { - var actualDep string - if strings.Contains(dep, ":") { - prefix := strings.Split(dep, ":")[0] - if !glob.Glob(prefix, host) && prefix != "all" { - continue - } - actualDep = dep[strings.Index(dep, ":")+1:] - } else { - actualDep = dep + is := ifstring.ParseIfString(dep) + if !is.Matches(host, builder.GetName()) { + continue } - if !visited[actualDep] { - visited[actualDep] = true - nextLevel = append(nextLevel, actualDep) + if !visited[is.Content] { + visited[is.Content] = true + nextLevel = append(nextLevel, is.Content) } } } diff --git a/pack/search.go b/pack/search.go index 7367e77..31a554d 100644 --- a/pack/search.go +++ b/pack/search.go @@ -19,7 +19,7 @@ func GetPackagesByList(list string) []*Package { for _, name := range packageNames { pkg, err := FindPackage(name) if err != nil { - log.Printf("Package %s not found in %s", name, host.GetPackagesDir()) + log.Printf("Package %s not found in %s, %s", name, host.GetPackagesDir(), err) continue } packages = append(packages, pkg) diff --git a/packages/boost.json b/packages/boost.json deleted file mode 100644 index c6e6ce2..0000000 --- a/packages/boost.json +++ /dev/null @@ -1,61 +0,0 @@ -{ - "package": "boost", - "version": "1_85_0", - "type": "host", - "download": { - "kind": "tar.bz2", - "sha256": "7009fe1faa1697476bdc7027703a2badb84e849b7b0baad5086b087b971f8617", - "url": "http://downloads.sourceforge.net/project/boost/boost/1.85.0/boost_1_85_0.tar.bz2" - }, - "dependencies": [ - "*-android*:native/android_ndk", - "*-linux-*:native/libtool", - "all:native/boost-b2", - "all:native/python@3.11.13", - "all:libiconv" - ], - "patches": [ - "fix_io_control_hpp.patch" - ], - "build": { - "env": [ - "all:config_opts=variant=release", - "*-apple-ios*:target_os=iphone", - "*-linux-android*:target_os=android", - "*-mingw32*:target_os=windows", - "*-linux-gnu*:target_os=linux", - "all:config_opts=$config_opts --layout=system --user-config=user-config.jam", - "all:config_opts=$config_opts threading=multi link=static -sNO_BZIP2=1 -sNO_ZLIB=1", - "*-linux-gnu*:config_opts=$config_opts threadapi=pthread runtime-link=static", - "*-android*:config_opts=$config_opts threadapi=pthread runtime-link=static target-os=$target_os binary-format=elf abi=aapcs", - "*64-linux-android*:config_opts=$config_opts address-model=64", - "armv7-linux-androideabi*:config_opts=$config_opts address-model=32", - "*-darwin*:config_opts=$config_opts --toolset=darwin runtime-link=static", - "*-ios*:config_opts=$config_opts --toolset=darwin-iphone runtime-link=static", - "*-ios-simulator*:config_opts=$config_opts --toolset=darwin-iphone runtime-link=static", - "*mingw32*:config_opts=$config_opts binary-format=pe target-os=$target_os threadapi=win32 runtime-link=static", - "*x86_64-*-mingw32*:config_opts=$config_opts address-model=64", - "*i686-*-mingw32*:config_opts=$config_opts address-model=32", - "*i686-linux-gnu*:config_opts=$config_opts address-model=32 architecture=x86", - "all:toolset=gcc", - "*-apple-*:archiver=$LIBTOOL", - "*-apple-*:toolset=darwin", - "*-android*:toolset=gcc", - "*mingw32*:toolset=gcc", - "*-ios*:toolset2=iphone", - "*-ios-simulator*:toolset2=~iphone", - "all:config_libraries=system,filesystem,thread,timer,date_time,chrono,regex,serialization,atomic,program_options,locale,log", - "all:CXXFLAGS=-fPIC", - "*-darwin*:LDFLAGS=-L$PREFIX/lib -L$SDK_PATH/usr/lib", - "*-ios*:LDFLAGS=-L$PREFIX/lib -L$SDK_PATH/usr/lib", - "*-ios-simulator*:LDFLAGS=-L$PREFIX/lib -L$SDK_PATH/usr/lib", - "*-apple-*:AR=libtool", - "*-linux-android*:ARFLAGS=rcs" - ], - "steps": [ - "all:echo \"using $toolset : $toolset2 : $CXX $CXXFLAGS : \"$CXXFLAGS\" \"$LDFLAGS\" \"$AR\" \"$ARFLAGS\" \"$STRIP\" \"$RANLIB\" \"$WINDRES\" \"$target_os\" : ;\" > user-config.jam", - "all:b2 -d2 -j$NUM_CORES --prefix=$STAGING_DIR$PREFIX $config_opts stage", - "all:b2 -d0 -j1 --prefix=$STAGING_DIR$PREFIX $config_opts install" - ] - } -} \ No newline at end of file diff --git a/packages/boost@1_83_0.json b/packages/boost@1_83_0.json new file mode 100644 index 0000000..11b0e85 --- /dev/null +++ b/packages/boost@1_83_0.json @@ -0,0 +1,70 @@ +{ + "package": "boost@1_83_0", + "version": "1_83_0", + "type": "host", + "download": [ + { + "kind": "tar.bz2", + "sha256": "6478edfe2f3305127cffe8caf73ea0176c53769f4bf1585be237eb30798c3b8e", + "url": "http://downloads.sourceforge.net/project/boost/boost/1.83.0/boost_1_83_0.tar.bz2" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/bash", + "*:*:native/boost-b2@1_83_0", + "*:*:native/cmake", + "*:*:native/coreutils", + "*:*:native/python@3.14", + "*:*:libiconv", + "*:*:openssl", + "*:*:xz", + "*:*:zstd" + ], + "patches": [ + "fix_io_control_hpp.patch" + ], + "build": { + "env": [ + "*:*-linux-gnu*:CXXFLAGS=$CXXFLAGS -fPIC", + "*:*-apple-ios*:target_os=iphone", + "*:*-linux-android*:target_os=android", + "*:*-mingw32*:target_os=windows", + "*:*-linux-gnu*:target_os=linux", + "*:*:config_opts=variant=release --layout=system --without-python --without-mpi --without-graph_parallel --user-config=user-config.jam", + "*:*:config_opts=$config_opts threading=multi link=static -sNO_BZIP2=1 -sNO_ZLIB=1 -sICONV_PATH=$PREFIX", + "*:aarch64-apple-darwin:config_opts=$config_opts address-model=64 threadapi=pthread architecture=arm --toolset=darwin runtime-link=shared", + "*:x86_64-linux-android:config_opts=$config_opts address-model=64 threadapi=pthread runtime-link=static target-os=$target_os binary-format=elf abi=aapcs", + "*:aarch64-linux-android:config_opts=$config_opts address-model=64 threadapi=pthread runtime-link=static target-os=$target_os binary-format=elf abi=aapcs", + "*:armv7a-linux-androideabi:config_opts=$config_opts address-model=32 architecture=arm threadapi=pthread runtime-link=static target-os=$target_os binary-format=elf abi=aapcs", + "*:x86_64-apple-darwin:config_opts=$config_opts address-model=64 architecture=x86", + "*:aarch64-apple-ios:config_opts=$config_opts address-model=64 architecture=arm --toolset=darwin-iphone link=static runtime-link=static", + "*:aarch64-apple-ios-simulator:config_opts=$config_opts address-model=64 architecture=arm --toolset=darwin-iphone link=static runtime-link=static", + "*:x86_64-w64-mingw32:config_opts=$config_opts target-os=$target_os binary-format=pe threadapi=win32 runtime-link=static address-model=64 architecture=x86", + "*:i686-w64-mingw32:config_opts=$config_opts target-os=$target_os binary-format=pe threadapi=win32 runtime-link=static address-model=32 architecture=x86", + "*:i686-linux-gnu:config_opts=$config_opts address-model=32 architecture=x86 threadapi=pthread runtime-link=static", + "*:x86_64-linux-gnu:config_opts=$config_opts address-model=64 architecture=x86 threadapi=pthread runtime-link=static", + "*:aarch64-linux-gnu:config_opts=$config_opts address-model=64 architecture=arm threadapi=pthread runtime-link=static", + "*:*:toolset=gcc", + "*:*-apple-*:archiver=$LIBTOOL", + "*:*-apple-*:toolset=darwin", + "*:*-android*:toolset=gcc", + "*:*mingw32*:toolset=gcc", + "*:*-ios*:toolset2=iphone", + "*:*-apple-*:AR=libtool", + "*:{*-linux-*,*-w64-*}:ARFLAGS=rcs", + "none:*-apple-darwin:config_opts=$config_opts define=BOOST_LOG_WITHOUT_SYSLOG", + "none:*-apple-darwin:config_opts=$config_opts define=BOOST_LOG_WITHOUT_IPC", + "*:*-apple-*:config_opts=$config_opts define=_DARWIN_C_SOURCE" + ], + "steps": [ + "*:*:echo \"using $toolset : $toolset2 : $CXX $CXXFLAGS : \"$CXXFLAGS\" \"$LDFLAGS\" \"$AR\" \"$ARFLAGS\" \"$STRIP\" \"$RANLIB\" \"$WINDRES\" \"$target_os\" : ;\" > user-config.jam", + "*:*:echo \"using lzma : : $PREFIX/include $PREFIX/lib ;\" >> user-config.jam", + "*:*:echo \"using zstd : : $PREFIX/include $PREFIX/lib ;\" >> user-config.jam", + "*:*:echo \"using openssl : : $PREFIX/include $PREFIX/lib ;\" >> user-config.jam", + "*:*:b2 -j$NUM_CORES --prefix=$STAGING_DIR$PREFIX $config_opts", + "*:*:b2 -j1 --prefix=$STAGING_DIR$PREFIX $config_opts stage", + "*:*:b2 -d0 -j1 --prefix=$STAGING_DIR$PREFIX $config_opts install" + ] + } +} \ No newline at end of file diff --git a/packages/boost@1_90_0.json b/packages/boost@1_90_0.json new file mode 100644 index 0000000..5ad941a --- /dev/null +++ b/packages/boost@1_90_0.json @@ -0,0 +1,70 @@ +{ + "package": "boost@1_90_0", + "version": "1_90_0", + "type": "host", + "download": [ + { + "kind": "tar.bz2", + "sha256": "49551aff3b22cbc5c5a9ed3dbc92f0e23ea50a0f7325b0d198b705e8ee3fc305", + "url": "http://downloads.sourceforge.net/project/boost/boost/1.90.0/boost_1_90_0.tar.bz2" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/bash", + "*:*:native/boost-b2@1_90_0", + "*:*:native/cmake", + "*:*:native/coreutils", + "*:*:native/python@3.14", + "*:*:libiconv", + "*:*:openssl", + "*:*:xz", + "*:*:zstd" + ], + "patches": [ + "fix_io_control_hpp.patch" + ], + "build": { + "env": [ + "*:*-linux-gnu*:CXXFLAGS=$CXXFLAGS -fPIC", + "*:*-apple-ios*:target_os=iphone", + "*:*-linux-android*:target_os=android", + "*:*-mingw32*:target_os=windows", + "*:*-linux-gnu*:target_os=linux", + "*:*:config_opts=variant=release --layout=system --without-python --without-mpi --without-graph_parallel --user-config=user-config.jam", + "*:*:config_opts=$config_opts threading=multi link=static -sNO_BZIP2=1 -sNO_ZLIB=1 -sICONV_PATH=$PREFIX", + "*:aarch64-apple-darwin:config_opts=$config_opts address-model=64 threadapi=pthread architecture=arm --toolset=darwin runtime-link=shared", + "*:x86_64-linux-android:config_opts=$config_opts address-model=64 threadapi=pthread runtime-link=static target-os=$target_os binary-format=elf abi=aapcs", + "*:aarch64-linux-android:config_opts=$config_opts address-model=64 threadapi=pthread runtime-link=static target-os=$target_os binary-format=elf abi=aapcs", + "*:armv7a-linux-androideabi:config_opts=$config_opts address-model=32 architecture=arm threadapi=pthread runtime-link=static target-os=$target_os binary-format=elf abi=aapcs", + "*:x86_64-apple-darwin:config_opts=$config_opts address-model=64 architecture=x86", + "*:aarch64-apple-ios:config_opts=$config_opts address-model=64 architecture=arm --toolset=darwin-iphone link=static runtime-link=static --without-process", + "*:aarch64-apple-ios-simulator:config_opts=$config_opts address-model=64 architecture=arm --toolset=darwin-iphone link=static runtime-link=static --without-process", + "*:x86_64-w64-mingw32:config_opts=$config_opts target-os=$target_os binary-format=pe threadapi=win32 runtime-link=static address-model=64 architecture=x86", + "*:i686-w64-mingw32:config_opts=$config_opts target-os=$target_os binary-format=pe threadapi=win32 runtime-link=static address-model=32 architecture=x86", + "*:i686-linux-gnu:config_opts=$config_opts address-model=32 architecture=x86 threadapi=pthread runtime-link=static", + "*:x86_64-linux-gnu:config_opts=$config_opts address-model=64 architecture=x86 threadapi=pthread runtime-link=static", + "*:aarch64-linux-gnu:config_opts=$config_opts address-model=64 architecture=arm threadapi=pthread runtime-link=static", + "*:*:toolset=gcc", + "*:*-apple-*:archiver=$LIBTOOL", + "*:*-apple-*:toolset=darwin", + "*:*-android*:toolset=gcc", + "*:*mingw32*:toolset=gcc", + "*:*-ios*:toolset2=iphone", + "*:*-apple-*:AR=libtool", + "*:{*-linux-*,*-w64-*}:ARFLAGS=rcs", + "none:*-apple-darwin:config_opts=$config_opts define=BOOST_LOG_WITHOUT_SYSLOG", + "none:*-apple-darwin:config_opts=$config_opts define=BOOST_LOG_WITHOUT_IPC", + "*:*-apple-*:config_opts=$config_opts define=_DARWIN_C_SOURCE" + ], + "steps": [ + "*:*:echo \"using $toolset : $toolset2 : $CXX $CXXFLAGS : \"$CXXFLAGS\" \"$LDFLAGS\" \"$AR\" \"$ARFLAGS\" \"$STRIP\" \"$RANLIB\" \"$WINDRES\" \"$target_os\" : ;\" > user-config.jam", + "*:*:echo \"using lzma : : $PREFIX/include $PREFIX/lib ;\" >> user-config.jam", + "*:*:echo \"using zstd : : $PREFIX/include $PREFIX/lib ;\" >> user-config.jam", + "*:*:echo \"using openssl : : $PREFIX/include $PREFIX/lib ;\" >> user-config.jam", + "*:*:b2 -j$NUM_CORES --prefix=$STAGING_DIR$PREFIX $config_opts", + "*:*:b2 -j1 --prefix=$STAGING_DIR$PREFIX $config_opts stage", + "*:*:b2 -d0 -j1 --prefix=$STAGING_DIR$PREFIX $config_opts install" + ] + } +} \ No newline at end of file diff --git a/packages/bzip2.json b/packages/bzip2.json new file mode 100644 index 0000000..1d5ea5b --- /dev/null +++ b/packages/bzip2.json @@ -0,0 +1,26 @@ +{ + "package": "bzip2", + "version": "1.0.8", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269", + "url": "https://sourceware.org/pub/bzip2/bzip2-1.0.8.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:openssl" + ], + "build": { + "steps": [ + "*:*:sed -i.bak 's|^CC=.*|CC ?= $CC|' Makefile", + "*:*:sed -i.bak 's|^AR=.*|AR ?= $AR|' Makefile", + "*:*:sed -i.bak 's|^RANLIB=.*|RANLIB ?= $RANLIB|' Makefile", + "*:*:sed -i.bak 's|^CFLAGS=.*|CFLAGS ?= $CFLAGS $BIGFILES|' Makefile", + "*:*:make libbz2.a bzip2 bzip2recover -j$NUM_CORES", + "*:*:make install PREFIX=$STAGING_DIR$PREFIX" + ] + } +} \ No newline at end of file diff --git a/packages/curl.json b/packages/curl.json new file mode 100644 index 0000000..e789e17 --- /dev/null +++ b/packages/curl.json @@ -0,0 +1,29 @@ +{ + "package": "curl", + "version": "8.15.0", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "d85cfc79dc505ff800cb1d321a320183035011fa08cb301356425d86be8fc53c", + "url": "https://curl.se/download/curl-8.15.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/make", + "*:*:native/pkgconf", + "*:*:openssl", + "*:*:zlib" + ], + "build": { + "env": [ + "*:*:config_opts=--with-openssl --with-zlib --without-libpsl --disable-shared --enable-static --enable-static --disable-ldap --host=$HOST --prefix=$PREFIX" + ], + "steps": [ + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/dbus@1_14_10.json b/packages/dbus@1_14_10.json new file mode 100644 index 0000000..8e8ff66 --- /dev/null +++ b/packages/dbus@1_14_10.json @@ -0,0 +1,41 @@ +{ + "package": "dbus@1_14_10", + "version": "1_14_10", + "type": "host", + "download": [ + { + "kind": "tar.xz", + "sha256": "ba1f21d2bd9d339da2d4aa8780c09df32fea87998b73da24f49ab9df1e36a50f", + "url": "https://dbus.freedesktop.org/releases/dbus/dbus-1.14.10.tar.xz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/patch", + "*:*-linux-gnu:expat", + "*:*-linux-gnu:native/sed" + ], + "patches": [ + "remove-DDBUS_STATIC_BUILD.patch" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-maintainer-mode --disable-xml-docs --disable-doxygen-docs --disable-ducktype-docs" + ], + "steps": [ + "*:*-linux-gnu:patch -p1 < $PATCH_DIR/dbus/remove-DDBUS_STATIC_BUILD.patch", + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -f $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/easyexif.json b/packages/easyexif.json new file mode 100644 index 0000000..e404d7d --- /dev/null +++ b/packages/easyexif.json @@ -0,0 +1,26 @@ +{ + "package": "easyexif", + "version": "cd994a3b6009", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "cd994a3b6009bc3c1f84062e96bd7f5ad16e85f6", + "url": "https://github.com/mayanklahiri/easyexif.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/coreutils", + "*:*:native/bash" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p $STAGING_DIR$PREFIX/include $STAGING_DIR$PREFIX/lib", + "*:*:cp exif.h $STAGING_DIR$PREFIX/include/easyexif.h", + "*:*:$CXX $CXXFLAGS -fPIC -I. -c exif.cpp -o easyexif.o", + "*:*:$AR rcs $STAGING_DIR$PREFIX/lib/libeasyexif.a easyexif.o" + ] + } +} \ No newline at end of file diff --git a/packages/eudev.json b/packages/eudev.json deleted file mode 100644 index aca9900..0000000 --- a/packages/eudev.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "package": "eudev", - "version": "v3.2.14", - "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "8da4319102f24abbf7fff5ce9c416af848df163b29590e666d334cc1927f006f", - "url": "http://github.com/eudev-project/eudev/releases/download/v3.2.14/eudev-3.2.14.tar.gz" - }, - "dependencies": [ - "*-linux-gnu:native/gperf", - "*-linux-gnu:native/make" - ], - "build": { - "env": [ - "all:config_opts=--host=$HOST --prefix=$PREFIX", - "all:config_opts=$config_opts --disable-gudev --disable-introspection --disable-hwdb --disable-manpages --disable-shared", - "all:config_opts=$config_opts AR_FLAGS=$ARFLAGS", - "all:SHOULD_BUILD=echo", - "*-linux-gnu:SHOULD_BUILD=" - ], - "steps": [ - "all:$SHOULD_BUILD ./configure $config_opts", - "all:$SHOULD_BUILD make -j$NUM_CORES", - "all:$SHOULD_BUILD make -j$NUM_CORES DESTDIR=$STAGING_DIR install" - ] - } -} \ No newline at end of file diff --git a/packages/expat.json b/packages/expat.json index 72cd0be..12943cd 100644 --- a/packages/expat.json +++ b/packages/expat.json @@ -2,29 +2,33 @@ "package": "expat", "version": "2.6.0", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "a13447b9aa67d7c860783fdf6820f33ebdea996900d6d8bbc50a628f55f099f7", - "url": "http://github.com/libexpat/libexpat/releases/download/R_2_6_0/expat-2.6.0.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "a13447b9aa67d7c860783fdf6820f33ebdea996900d6d8bbc50a628f55f099f7", + "url": "http://github.com/libexpat/libexpat/releases/download/R_2_6_0/expat-2.6.0.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/autoconf", - "all:native/make", - "all:native/perl", - "all:libiconv" + "*:*:native/_", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/findutils", + "*:*:native/gawk", + "*:*:native/grep", + "*:*:native/make", + "*:*:native/sed", + "*:*:native/diffutils", + "*:*:libiconv" ], "build": { "env": [ - "all:CFLAGS=$CFLAGS -fPIC", - "all:LDFLAGS=$LDFLAGS -fPIC", - "all:BUILD_HOST=$HOST", - "aarch64-apple-ios-simulator:BUILD_HOST=aarch64-apple-ios" + "*:aarch64-apple-ios-simulator:HOST=aarch64-apple-ios" ], "steps": [ - "all:./configure --host=$BUILD_HOST --prefix=$PREFIX --disable-shared --without-docbook --without-tests --without-examples --enable-option-checking --without-xmlwf --with-pic", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure --host=$HOST --prefix=$PREFIX --disable-shared --without-docbook --without-tests --without-examples --enable-option-checking --without-xmlwf --with-pic", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/ffmpeg.json b/packages/ffmpeg.json new file mode 100644 index 0000000..3fd2308 --- /dev/null +++ b/packages/ffmpeg.json @@ -0,0 +1,54 @@ +{ + "package": "ffmpeg", + "version": "n9.0", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "d32b387f2b0a484599d4587d651891f0c63c4238", + "url": "https://github.com/FFmpeg/FFmpeg.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/_", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/grep", + "*:*:native/make", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:ffmpeg_os=linux", + "*:*-linux-android*:ffmpeg_os=android", + "*:*-apple-*:ffmpeg_os=darwin", + "*:*-w64-mingw32:ffmpeg_os=mingw32", + "*:armv7a-*:ffmpeg_arch=arm", + "*:aarch64-*:ffmpeg_arch=aarch64", + "*:x86_64-*:ffmpeg_arch=x86_64", + "*:*:config_opts=--prefix=$PREFIX", + "*:*:config_opts=$config_opts --enable-cross-compile", + "*:*:config_opts=$config_opts --arch=$ffmpeg_arch", + "*:*:config_opts=$config_opts --target-os=$ffmpeg_os", + "*:*:config_opts=$config_opts --host-cc=$NATIVEPREFIX/_/bin/clang", + "*:*:config_opts=$config_opts --enable-static", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --disable-doc", + "*:*:config_opts=$config_opts --disable-autodetect", + "*:*:config_opts=$config_opts --disable-asm", + "*:*:config_opts=$config_opts --disable-programs", + "*:*-linux-gnu:config_opts=$config_opts --sysroot=$PREFIX/sysroot", + "*:*-w64-mingw32:config_opts=$config_opts --sysroot=$PREFIX/sysroot", + "*:*-apple-*:config_opts=$config_opts --sysroot=$SDK_PATH" + ], + "steps": [ + "*:*:bash ./configure $config_opts --cc=\"$CC\" --ar=\"$AR\" --ranlib=\"$RANLIB\" --strip=\"$STRIP\" --nm=\"$NM\" --extra-cflags=\"$CFLAGS\" --extra-ldflags=\"$LDFLAGS\"", + "*:*:grep -E '#define CONFIG_GPL 0' config.h", + "*:*:grep -E '#define CONFIG_NONFREE 0' config.h", + "*:*:grep -E '#define CONFIG_VERSION3 0' config.h", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/filament.json b/packages/filament.json new file mode 100644 index 0000000..0b351f2 --- /dev/null +++ b/packages/filament.json @@ -0,0 +1,72 @@ +{ + "package": "filament", + "version": "v1.75.0", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "0e58877c09afb1aacd09ff640f74d2adcd2a7e80", + "url": "https://github.com/google/filament.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/coreutils", + "*:*:native/filament-tools", + "*:*:native/findutils", + "*:*:native/ninja", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:x86_64-*:dist_arch=x86_64", + "*:aarch64-apple-*:dist_arch=arm64", + "*:aarch64-linux-*:dist_arch=aarch64", + "*:armv7a-*:dist_arch=arm", + "*:x86_64-linux-gnu:CXXFLAGS=$CXXFLAGS -Wno-error=shadow -Wno-shadow -Wno-error=undef", + "*:aarch64-linux-gnu:CXXFLAGS=$CXXFLAGS -Wno-error=shadow -Wno-shadow -Wno-error=undef -U__ARM_NEON", + "*:*-apple-*:RANLIB=$NATIVEPREFIX/bin/ranlib", + "*:*-apple-*:AR=$NATIVEPREFIX/bin/ar", + "*:*-apple-*:CXXFLAGS=$CXXFLAGS -Wno-deprecated -Wno-deprecated-declarations -Wno-error=deprecated -Wno-error=deprecated-declarations", + "*:*-apple-*:OBJCXXFLAGS=$CXXFLAGS -Wno-deprecated -Wno-deprecated-declarations -Wno-error=deprecated -Wno-error=deprecated-declarations", + "*:*-apple-ios*:config_opts_ios=-DIOS=1", + "*:*-apple-ios*:CFLAGS=$CFLAGS -DFILAMENT_IOS", + "*:*-apple-ios*:CXXFLAGS=$CXXFLAGS -DFILAMENT_IOS", + "*:*-apple-ios*:OBJCXXFLAGS=$OBJCXXFLAGS -DFILAMENT_IOS", + "*:*-apple-ios-simulator:CFLAGS=$CFLAGS -DFILAMENT_IOS_SIMULATOR -mios-version-min=13.0", + "*:*-apple-ios-simulator:CXXFLAGS=$CXXFLAGS -DFILAMENT_IOS_SIMULATOR -mios-version-min=13.0", + "*:*-apple-ios-simulator:OBJCXXFLAGS=$OBJCXXFLAGS -DFILAMENT_IOS_SIMULATOR -mios-version-min=13.0", + "*:*-apple-ios-simulator:LDFLAGS=$LDFLAGS -mios-version-min=13.0", + "*:*-apple-ios-simulator:config_opts_ios=$config_opts_ios -DCMAKE_OSX_DEPLOYMENT_TARGET=13.0", + "*:*:config_opts=-G Ninja", + "*:*:config_opts=$config_opts -DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", + "*:*:config_opts=$config_opts -DCMAKE_BUILD_TYPE=Release", + "*:*:config_opts=$config_opts -DDIST_ARCH=$dist_arch", + "*:*:config_opts=$config_opts -DFILAMENT_IMPORT_PREBUILT_EXECUTABLES_DIR=out", + "*:*:config_opts=$config_opts -DFILAMENT_SKIP_SAMPLES=ON", + "*:*:config_opts=$config_opts -DFILAMENT_SKIP_SDL2=ON", + "*:*:config_opts=$config_opts -DFILAMENT_BUILD_TESTING=OFF", + "*:*:config_opts=$config_opts -DFILAMENT_SUPPORTS_XCB=OFF", + "*:*:config_opts=$config_opts -DFILAMENT_SUPPORTS_XLIB=OFF", + "*:*:config_opts=$config_opts -DUSE_STATIC_LIBCXX=OFF", + "*:*-apple-ios*:config_opts=$config_opts $config_opts_ios", + "*:*-linux-gnu:config_opts=$config_opts -DFILAMENT_ENABLE_EXPERIMENTAL_GCC_SUPPORT=ON", + "*:*-linux-gnu:config_opts=$config_opts -DFILAMENT_SUPPORTS_OPENGL=OFF" + ], + "steps": [ + "*:*:mkdir -p out", + "*:*:printf '%s\\n' 'foreach(_filament_tool IN ITEMS matc cmgen filamesh mipgen resgen uberz glslminifier)' ' if(NOT TARGET ${_filament_tool})' ' add_executable(${_filament_tool} IMPORTED)' ' set_property(TARGET ${_filament_tool} APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)' ' set_target_properties(${_filament_tool} PROPERTIES IMPORTED_LOCATION_RELEASE \"'$NATIVEPREFIX'/bin/${_filament_tool}\")' ' endif()' 'endforeach()' > out/ImportExecutables-Prebuilt.cmake", + "*:*:sed -i '/add_subdirectory(\\${TOOLS}\\/cmgen)/i\\if (NOT FILAMENT_IMPORT_PREBUILT_EXECUTABLES)' CMakeLists.txt", + "*:*:sed -i '/add_subdirectory(\\${TOOLS}\\/specgen)/a\\endif()' CMakeLists.txt", + "*:*-linux-gnu:find . -name CMakeLists.txt -print0 | xargs -0 sed -i '/fstrict-vtable-pointers/d'", + "*:*:cmake -S . -B build $config_opts", + "*:*:cmake --build build -j$NUM_CORES", + "*:*:DESTDIR=$STAGING_DIR cmake --install build" + ] + } +} \ No newline at end of file diff --git a/packages/fontconfig@2_12_6.json b/packages/fontconfig@2_12_6.json new file mode 100644 index 0000000..4dc5bcc --- /dev/null +++ b/packages/fontconfig@2_12_6.json @@ -0,0 +1,41 @@ +{ + "package": "fontconfig@2_12_6", + "version": "2_12_6", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "064b9ebf060c9e77011733ac9dc0e2ce92870b574cca2405e11f5353a683c334", + "url": "https://www.freedesktop.org/software/fontconfig/release/fontconfig-2.12.6.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/patch", + "*:*-linux-gnu:native/sed", + "*:*-linux-gnu:freetype@2_14_1", + "*:*-linux-gnu:expat" + ], + "patches": [ + "gperf_header_regen.patch" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-docs --disable-libxml2 --disable-iconv --disable-dependency-tracking --enable-option-checking" + ], + "steps": [ + "*:*-linux-gnu:patch -p1 < $PATCH_DIR/fontconfig/gperf_header_regen.patch", + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/var $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/freetype@2_14_1.json b/packages/freetype@2_14_1.json new file mode 100644 index 0000000..b2a2031 --- /dev/null +++ b/packages/freetype@2_14_1.json @@ -0,0 +1,37 @@ +{ + "package": "freetype@2_14_1", + "version": "2_14_1", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "174d9e53402e1bf9ec7277e22ec199ba3e55a6be2c0740cb18c0ee9850fc8c34", + "url": "https://download.savannah.gnu.org/releases/freetype/freetype-2.14.1.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_/_", + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --without-zlib --without-png --without-harfbuzz --without-bzip2 --enable-option-checking --without-brotli --with-pic" + ], + "steps": [ + "*:*-linux-gnu:rm -rf docs", + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/share/man $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/gettext.json b/packages/gettext.json new file mode 100644 index 0000000..8476e6e --- /dev/null +++ b/packages/gettext.json @@ -0,0 +1,35 @@ +{ + "package": "gettext", + "version": "0.26", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "39acf4b0371e9b110b60005562aace5b3631fed9b1bb9ecccfc7f56e58bb1d7f", + "url": "http://ftpmirror.gnu.org/gnu/gettext/gettext-0.26.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/make", + "*:*:native/sed", + "*:*:libiconv", + "*:*:unistring" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$PREFIX", + "*:*:config_opts=$config_opts --host=$HOST", + "*:*:config_opts=$config_opts --with-libiconv-prefix=$PREFIX", + "*:*:config_opts=$config_opts --with-libunistring-prefix=$PREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static", + "*:*:LIBS=-lunistring" + ], + "steps": [ + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/glibc.json b/packages/glibc.json deleted file mode 100644 index a2963b5..0000000 --- a/packages/glibc.json +++ /dev/null @@ -1,40 +0,0 @@ -{ - "package": "glibc", - "version": "2.39", - "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "97f84f3b7588cd54093a6f6389b0c1a81e70d99708d74963a2e3eab7c7dc942d", - "url": "http://ftpmirror.gnu.org/gnu/libc/glibc-2.39.tar.gz" - }, - "dependencies": [ - "*-linux-gnu:native/binutils@2.42", - "*-linux-gnu:native/bison", - "*-linux-gnu:native/config", - "*-linux-gnu:native/gawk@5.2.2", - "*-linux-gnu:native/gcc@13.2@stage1", - "*-linux-gnu:native/linux-headers", - "*-linux-gnu:native/m4", - "*-linux-gnu:native/make", - "*-linux-gnu:native/perl", - "*-linux-gnu:native/python@3.11.13", - "*-linux-gnu:native/sed" - ], - "build": { - "env": [ - "*-linux-gnu:HOST_TARGET=x86_64-linux-gnu", - "*-linux-gnu:SYSROOT=$PREFIX/sysroots/$HOST_TARGET", - "*-linux-gnu:config_opts=--prefix=$PREFIX --host=$HOST_TARGET --with-headers=$PREFIX/include --disable-multilib", - "*-linux-gnu:config_opts=$config_opts --disable-werror", - "*-linux-gnu:CFLAGS=$CFLAGS -O2", - "*-linux-gnu:CFLAGS=$CFLAGS -Wno-error=attributes" - ], - "steps": [ - "*-linux-gnu:mkdir -p build", - "*-linux-gnu:sed -i.bak '/.eh_frame/d' sysdeps/unix/sysv/linux/x86_64/libc_sigaction.c", - "*-linux-gnu:cd build && ../configure $config_opts", - "*-linux-gnu:cd build && make -j1", - "*-linux-gnu:cd build && make -j1 install DESTDIR=$STAGING_DIR" - ] - } -} \ No newline at end of file diff --git a/packages/gtest.json b/packages/gtest.json index 47a22ff..f7c8bb0 100644 --- a/packages/gtest.json +++ b/packages/gtest.json @@ -2,34 +2,34 @@ "package": "gtest", "version": "1.17.0", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "65fab701d9829d38cb77c14acdc431d2108bfdbf8979e40eb8ae567edf10b27c", - "url": "http://github.com/google/googletest/releases/download/v1.17.0/googletest-1.17.0.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "65fab701d9829d38cb77c14acdc431d2108bfdbf8979e40eb8ae567edf10b27c", + "url": "http://github.com/google/googletest/releases/download/v1.17.0/googletest-1.17.0.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/cmake", - "all:native/cmake-toolchain", - "all:native/make" + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain" ], "build": { "env": [ - "all:CXXFLAGS=$CXXFLAGS -std=c++11", - "*-linux-gnu:CXXFLAGS=$CXXFLAGS -fPIC", - "all:config_opts=-DCMAKE_TOOLCHAIN_FILE=$PREFIX/native/toolchain.cmake", - "all:config_opts=$config_opts -DGOOGLETEST_VERSION=1.17.0", - "all:config_opts=$config_opts -DCMAKE_POLICY_VERSION_MINIMUM=3.5", - "all:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", - "all:config_opts=$config_opts -DCMAKE_CXX_FLAGS_DEBUG=ON" + "*:*:CXXFLAGS=$CXXFLAGS -std=c++11", + "*:*:config_opts=-DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DGOOGLETEST_VERSION=1.17.0", + "*:*:config_opts=$config_opts -DCMAKE_POLICY_VERSION_MINIMUM=3.5", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", + "*:*:config_opts=$config_opts -DCMAKE_CXX_FLAGS_DEBUG=ON" ], "steps": [ - "all:cd googletest && cmake $config_opts", - "all:cd googletest && make -j$NUM_CORES", - "all:mkdir $STAGING_DIR$PREFIX/lib $STAGING_DIR$PREFIX/include", - "all:cp googletest/lib/libgtest.a $STAGING_DIR$PREFIX/lib", - "all:cp googletest/lib/libgtest_main.a $STAGING_DIR$PREFIX/lib", - "all:cp -a googletest/include/* $STAGING_DIR$PREFIX/include/" + "*:*:cd googletest && cmake $config_opts", + "*:*:cd googletest && make -j$NUM_CORES", + "*:*:mkdir $STAGING_DIR$PREFIX/lib $STAGING_DIR$PREFIX/include", + "*:*:cp googletest/lib/libgtest.a $STAGING_DIR$PREFIX/lib", + "*:*:cp googletest/lib/libgtest_main.a $STAGING_DIR$PREFIX/lib", + "*:*:cp -a googletest/include/* $STAGING_DIR$PREFIX/include/" ] } } \ No newline at end of file diff --git a/packages/hidapi.json b/packages/hidapi.json deleted file mode 100644 index 5207d9d..0000000 --- a/packages/hidapi.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "package": "hidapi", - "version": "0.13.1", - "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "476a2c9a4dc7d1fc97dd223b84338dbea3809a84caea2dcd887d9778725490e3", - "url": "http://github.com/libusb/hidapi/archive/refs/tags/hidapi-0.13.1.tar.gz" - }, - "dependencies": [ - "*-android*:native/android_ndk", - "all:native/autoconf", - "all:native/automake", - "all:native/libtool", - "all:native/m4", - "all:native/make", - "all:native/patch", - "all:native/perl", - "all:eudev", - "all:libusb" - ], - "patches": [ - "missing_win_include.patch" - ], - "build": { - "env": [ - "all:config_opts=--prefix=$PREFIX --host=$HOST --enable-static --disable-shared", - "*-linux-gnu:config_opts=$config_opts libudev_CFLAGS=-I$PREFIX/include", - "*-linux-gnu:config_opts=$config_opts libusb_CFLAGS=-I$PREFIX/include/libusb-1.0", - "*-linux-gnu:config_opts=$config_opts --with-pic", - "all:SHOULD_BUILD=echo", - "*-linux-gnu:SHOULD_BUILD=", - "*-w64-mingw32:SHOULD_BUILD=", - "*-apple-darwin:SHOULD_BUILD=" - ], - "steps": [ - "all:$SHOULD_BUILD patch -p1 < $PATCH_DIR/hidapi/missing_win_include.patch", - "all:$SHOULD_BUILD ./bootstrap", - "all:$SHOULD_BUILD ./configure $config_opts libudev_LIBS=\"-L$PREFIX/lib -ludev\" libusb_LIBS=\"-L$PREFIX/lib -lusb-1.0\"", - "all:$SHOULD_BUILD make -j$NUM_CORES", - "all:$SHOULD_BUILD make -j$NUM_CORES DESTDIR=$STAGING_DIR install" - ] - } -} \ No newline at end of file diff --git a/packages/icu4c.json b/packages/icu4c.json deleted file mode 100644 index fbcd6d1..0000000 --- a/packages/icu4c.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "package": "icu4c", - "version": "55.2", - "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "eda2aa9f9c787748a2e2d310590720ca8bcc6252adf6b4cfb03b65bef9d66759", - "url": "http://github.com/unicode-org/icu/releases/download/release-55-2/icu4c-55_2-src.tgz" - }, - "patches": [ - "icu-001-dont-build-static-dynamic-twice.patch" - ], - "build": { - "env": [ - "*-w64-mingw32:CFLAGS=$CFLAGS -DU_USING_ICU_NAMESPACE=0 -DU_STATIC_IMPLEMENTATION -DU_COMBINED_IMPLEMENTATION -fPIC -DENABLE_STATIC=YES -DPGKDATA_MODE=static", - "*-w64-mingw32:TARGET=" - ], - "steps": [ - "*-w64-mingw32:patch -p1 < $PATCH_DIR/icu4c/icu-001-dont-build-static-dynamic-twice.patch", - "*-w64-mingw32:mkdir builda", - "*-w64-mingw32:mkdir buildb", - "*-w64-mingw32:cd builda && sh ../source/runConfigureICU Linux", - "*-w64-mingw32:cd builda && make -j$NUM_CORES", - "*-w64-mingw32:cd buildb && ../source/runConfigureICU MinGW --enable-static=yes --disable-shared --disable-layout --disable-layoutex --disable-tests --disable-samples --prefix=$PREFIX --with-cross-build=$(pwd)/../builda", - "*-w64-mingw32:cd buildb && make -j$NUM_CORES $build_opts", - "*-w64-mingw32:cd buildb && -j$NUM_CORES $build_opts DESTDIR=$STAGING_DIR install lib/*" - ] - } -} \ No newline at end of file diff --git a/packages/libXau@1_0_12.json b/packages/libXau@1_0_12.json new file mode 100644 index 0000000..6a88178 --- /dev/null +++ b/packages/libXau@1_0_12.json @@ -0,0 +1,40 @@ +{ + "package": "libXau@1_0_12", + "version": "1_0_12", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "2402dd938da4d0a332349ab3d3586606175e19cb32cb9fe013c19f1dc922dcee", + "url": "https://xorg.freedesktop.org/releases/individual/lib/libXau-1.0.12.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/meson", + "*:*-linux-gnu:native/ninja", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/python@3.11", + "*:*-linux-gnu:xorgproto@2025_1", + "*:*-linux-gnu:native/sed" + ], + "patches": [ + "toolchain.txt" + ], + "build": { + "env": [], + "steps": [ + "*:*-linux-gnu:cp $PATCH_DIR/libXau/toolchain.txt toolchain.txt", + "*:*-linux-gnu:sed -i -e \"s|@host_prefix@|$PREFIX|\" -e \"s|@cc@|$CC|\" -e \"s|@cxx@|$CXX|\" -e \"s|@ar@|$AR|\" -e \"s|@strip@|$STRIP|\" -e \"s|@arch@|$ARCH|\" toolchain.txt", + "*:*-linux-gnu:$NATIVEPREFIX/bin/meson setup --cross-file toolchain.txt build", + "*:*-linux-gnu:ninja -C build", + "*:*-linux-gnu:DESTDIR=$STAGING_DIR ninja -C build install", + "*:*-linux-gnu:sed -i 's/Requires: xproto//g' $STAGING_DIR$PREFIX/lib/pkgconfig/xau.pc" + ] + } +} \ No newline at end of file diff --git a/packages/libevent.json b/packages/libevent.json index 22bbc3e..01a24e3 100644 --- a/packages/libevent.json +++ b/packages/libevent.json @@ -2,42 +2,55 @@ "package": "libevent", "version": "2.1.12", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "92e6de1be9ec176428fd2367677e61ceffc2ee1cb119035037a27d346b0403bb", - "url": "http://github.com/libevent/libevent/releases/download/release-2.1.12-stable/libevent-2.1.12-stable.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "92e6de1be9ec176428fd2367677e61ceffc2ee1cb119035037a27d346b0403bb", + "url": "http://github.com/libevent/libevent/releases/download/release-2.1.12-stable/libevent-2.1.12-stable.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/autoconf", - "all:native/automake", - "all:native/libtool", - "all:native/m4", - "all:native/make", - "all:native/perl" + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/coreutils", + "*:*:native/gawk", + "*:*:native/grep", + "*:*:native/libtool", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/perl", + "*:*:native/sed" ], "build": { "env": [ - "all:HOSTOVERRIDE=$HOST", - "aarch64-apple-ios-simulator:HOSTOVERRIDE=aarch64-apple-ios", - "all:config_opts=--host=$HOSTOVERRIDE --prefix=$PREFIX ", - "all:config_opts=$config_opts --disable-shared", - "all:config_opts=$config_opts --disable-openssl", - "all:config_opts=$config_opts --disable-libevent-regress", - "all:config_opts=$config_opts --disable-doxygen-html", - "all:config_opts=$config_opts --disable-debug-mode", - "all:config_opts=$config_opts --enable-static", - "all:config_opts=$config_opts --enable-gcc-hardening", - "all:config_opts=$config_opts --with-pic", - "all:CFLAGS=$CFLAGS -fPIC", - "all:CXXFLAGS=$CXXFLAGS -fPIC" + "*:aarch64-apple-ios-simulator:HOST=aarch64-apple-ios", + "*:*:config_opts=--host=$HOST --prefix=$PREFIX ", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --disable-openssl", + "*:*:config_opts=$config_opts --disable-mbedtls", + "*:*:config_opts=$config_opts --disable-libevent-regress", + "*:*:config_opts=$config_opts --disable-doxygen-html", + "*:*:config_opts=$config_opts --disable-debug-mode", + "*:*:config_opts=$config_opts --enable-static", + "*:*:config_opts=$config_opts --with-pic", + "*:*:config_opts=$config_opts --disable-samples" ], "steps": [ - "all:./autogen.sh", - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install", - "all:rm $STAGING_DIR$PREFIX/lib/*.la" + "*:*-w64-mingw32:sed -i.bak 's|WIN32_WINNT 0x400|WIN32_WINNT 0x700|g' configure.ac", + "*:*:./autogen.sh", + "*:*-w64-mingw32:sed -i.bak 's|WIN32_WINNT 0x400|WIN32_WINNT 0x700|g' configure~", + "*:*-w64-mingw32:sed -i.bak 's|_WIN32_WINNT 0x0501|_WIN32_WINNT 0x700|g' evutil.c", + "*:*-w64-mingw32:rm *.bak", + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:rm $STAGING_DIR$PREFIX/lib/*.la" ] } } \ No newline at end of file diff --git a/packages/libffi.json b/packages/libffi.json new file mode 100644 index 0000000..e54e830 --- /dev/null +++ b/packages/libffi.json @@ -0,0 +1,28 @@ +{ + "package": "libffi", + "version": "v3.5.2", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "e2eda0cf72a0598b44278cc91860ea402273fa29", + "url": "https://github.com/libffi/libffi.git" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/autoconf", + "*:*-linux-gnu:native/automake", + "*:*-linux-gnu:native/libtool", + "*:*-linux-gnu:native/m4", + "*:*-linux-gnu:native/perl" + ], + "build": { + "steps": [ + "*:*-linux-gnu:./autogen.sh", + "*:*-linux-gnu:./configure --host=$HOST --prefix=$PREFIX --enable-static --disable-shared --disable-docs --with-pic", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make install DESTDIR=$STAGING_DIR" + ] + } +} \ No newline at end of file diff --git a/packages/libffi@3_5_2.json b/packages/libffi@3_5_2.json new file mode 100644 index 0000000..00d4af4 --- /dev/null +++ b/packages/libffi@3_5_2.json @@ -0,0 +1,30 @@ +{ + "package": "libffi@3_5_2", + "version": "3_5_2", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "f3a3082a23b37c293a4fcd1053147b371f2ff91fa7ea1b2a52e335676bac82dc", + "url": "https://github.com/libffi/libffi/releases/download/v3.5.2/libffi-3.5.2.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [], + "steps": [ + "*:*-linux-gnu:bash ./configure --host=$HOST --prefix=$PREFIX --enable-static --disable-shared --disable-docs --with-pic", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/libiconv.json b/packages/libiconv.json index 4061ccc..ef017e9 100644 --- a/packages/libiconv.json +++ b/packages/libiconv.json @@ -1,32 +1,46 @@ { "package": "libiconv", - "version": "1.17", + "version": "1.18", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "8f74213b56238c85a50a5329f77e06198771e70dd9a739779f4c02f65d971313", - "url": "http://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.17.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "3b08f5f4f9b4eb82f151a7040bfd6fe6c6fb922efe4b1659c66ea933276965e8", + "url": "http://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.18.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/config", - "all:native/make" + "*:*:native/_", + "*:*:native/bash", + "*:*:native/config", + "*:*:native/coreutils", + "*:*:native/findutils", + "*:*:native/gawk", + "*:*:native/grep", + "*:*:native/make", + "*:*:native/sed" ], "build": { "env": [ - "all:CFLAGS=$CFLAGS -fPIC", - "all:BUILD_HOST=$HOST", - "aarch64-apple-ios-simulator:BUILD_HOST=aarch64-apple-ios", - "all:config_opts=--host=$BUILD_HOST --prefix=$PREFIX --disable-nls --enable-static --disable-shared", - "all:config_opts=$config_opts", - "*linux:config_opts=$config_opts --with-pic" + "*:aarch64-apple-ios-simulator:HOST=aarch64-apple-ios", + "*:*:config_opts=--host=$HOST --prefix=$PREFIX --disable-nls --enable-static --disable-shared", + "*:*:config_opts=$config_opts --disable-malloca", + "*:*:config_opts=$config_opts", + "*:*linux:config_opts=$config_opts --with-pic", + "*:*:CC=$CC $CFLAGS", + "*:*:CXX=$CXX $CXXFLAGS", + "*:*:RC=$RC $RCFLAGS" ], "steps": [ - "all:cp -f $PREFIX/native/usr/share/config/config.guess build-aux/", - "all:cp -f $PREFIX/native/usr/share/config/config.sub build-aux/", - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess build-aux/", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub build-aux/", + "*:*:sed -i.bak 's|#include |#include \"stdckdint.in.h\"|' ./srclib/malloca.c", + "*:*:bash ./configure $config_opts", + "*:*-w64-mingw32:sed -i.bak -e '/cd srclib/d' -e '/cd src &&/d' Makefile", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:mkdir -p $STAGING_DIR$PREFIX/include", + "*:*:cp include/*.h $STAGING_DIR$PREFIX/include/" ] } } \ No newline at end of file diff --git a/packages/libmd.json b/packages/libmd.json new file mode 100644 index 0000000..d8143d1 --- /dev/null +++ b/packages/libmd.json @@ -0,0 +1,34 @@ +{ + "package": "libmd", + "version": "1.1.0", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "d5b8e853989a73f8fff9dc4e00dccd0b691b84f9", + "url": "https://github.com/guillemj/libmd.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/gettext", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [ + "*:*:config_opts=--host=$HOST --prefix=$PREFIX", + "*:*:config_opts=$config_opts --disable-shared" + ], + "steps": [ + "*:*:autoreconf --force --install", + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make install DESTDIR=$STAGING_DIR" + ] + } +} \ No newline at end of file diff --git a/packages/libpsl.json b/packages/libpsl.json new file mode 100644 index 0000000..c4622d8 --- /dev/null +++ b/packages/libpsl.json @@ -0,0 +1,27 @@ +{ + "package": "libpsl", + "version": "0.21.5", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "1dcc9ceae8b128f3c0b3f654decd0e1e891afc6ff81098f227ef260449dae208", + "url": "https://github.com/rockdaboot/libpsl/releases/download/0.21.5/libpsl-0.21.5.tar.gz" + } + ], + "dependencies": [ + "*:*:native/make", + "*:*:unistring" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$PREFIX", + "windows_*:*:config_opts=$config_opts --disable-builtin" + ], + "steps": [ + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/libtor.json b/packages/libtor.json deleted file mode 100644 index 4fe89ac..0000000 --- a/packages/libtor.json +++ /dev/null @@ -1,60 +0,0 @@ -{ - "package": "libtor", - "version": "tor-0.4.8.17", - "type": "host", - "download": { - "kind": "git", - "sha256": "e41649c9a34f39f1d543e064fd2b97de26d3e097", - "url": "http://gitlab.torproject.org/tpo/core/tor.git" - }, - "dependencies": [ - "*-android*:native/android_ndk", - "all:native/autoconf", - "all:native/automake", - "all:native/m4", - "all:native/make", - "all:native/perl", - "all:libevent", - "all:openssl", - "all:xz", - "all:zlib", - "all:zstd" - ], - "build": { - "env": [ - "all:HOSTOVERRIDE=$HOST", - "aarch64-apple-ios-simulator:HOSTOVERRIDE=aarch64-apple-ios", - "all:config_opts=--host=$HOSTOVERRIDE --prefix=$PREFIX", - "all:config_opts=$config_opts --disable-asciidoc", - "all:config_opts=$config_opts --disable-system-torrc", - "all:config_opts=$config_opts --disable-manpage", - "all:config_opts=$config_opts --disable-html-manual", - "all:config_opts=$config_opts --disable-tool-name-check", - "*-linux-android*:config_opts=$config_opts --enable-android", - "*-linux-android*:config_opts=$config_opts ac_cv_member_struct_tcp_info_tcpi_snd_mss=no", - "all:config_opts=$config_opts --enable-pic", - "all:config_opts=$config_opts --enable-static-openssl", - "all:config_opts=$config_opts --enable-static-libevent", - "all:config_opts=$config_opts --enable-static-zlib", - "all:config_opts=$config_opts --enable-static-tor", - "all:config_opts=$config_opts --disable-lzma", - "all:config_opts=$config_opts --disable-zstd", - "all:config_opts=$config_opts --with-openssl-dir=$PREFIX/lib", - "all:config_opts=$config_opts --with-libevent-dir=$PREFIX/lib", - "all:config_opts=$config_opts --with-zlib-dir=$PREFIX/lib", - "all:config_opts=$config_opts tor_cv_library_libevent_dir=$PREFIX" - ], - "steps": [ - "all:./autogen.sh", - "all:./configure $config_opts", - "all:make -j$NUM_CORES libtor.a", - "all:mkdir -p $STAGING_DIR$PREFIX/lib", - "all:cp libtor.a $STAGING_DIR$PREFIX/lib/libtor.a", - "all:mkdir -p $STAGING_DIR$PREFIX/usr/share/tor", - "all:cp src/config/geoip $STAGING_DIR$PREFIX/usr/share/tor", - "all:cp src/config/geoip6 $STAGING_DIR$PREFIX/usr/share/tor", - "all:mkdir -p $STAGING_DIR$PREFIX/include/tor", - "all:cd src && find . -name '*.h' -exec sh -c 'mkdir -p \"$STAGING_DIR$PREFIX/include/tor/$(dirname \"$1\")\" && cp \"$1\" \"$STAGING_DIR$PREFIX/include/tor/$1\"' _ {} \\;" - ] - } -} \ No newline at end of file diff --git a/packages/libusb.json b/packages/libusb.json index 3ea1275..3196f2d 100644 --- a/packages/libusb.json +++ b/packages/libusb.json @@ -2,34 +2,36 @@ "package": "libusb", "version": "1.0.26", "type": "host", - "download": { - "kind": "tar.bz2", - "sha256": "12ce7a61fc9854d1d2a1ffe095f7b5fac19ddba095c259e6067a46500381b5a5", - "url": "http://github.com/libusb/libusb/releases/download/v1.0.26/libusb-1.0.26.tar.bz2" - }, + "download": [ + { + "kind": "tar.bz2", + "sha256": "12ce7a61fc9854d1d2a1ffe095f7b5fac19ddba095c259e6067a46500381b5a5", + "url": "http://github.com/libusb/libusb/releases/download/v1.0.26/libusb-1.0.26.tar.bz2" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/config", - "all:native/make" + "*:*:native/_", + "*:*:native/config", + "*:*:native/make" ], "build": { "env": [ - "all:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared", - "*-linux-gnu:config_opts=$config_opts --with-pic --disable-udev", - "*-w64-mingw32:config_opts=$config_opts --disable-udev", - "*-apple-darwin:config_opts=$config_opts --disable-udev", - "all:SHOULD_BUILD=echo", - "*-linux-gnu:SHOULD_BUILD=", - "*-w64-mingw32:SHOULD_BUILD=", - "*-apple-darwin:SHOULD_BUILD=" + "*:*:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared", + "*:*-linux-gnu:config_opts=$config_opts --with-pic --disable-udev", + "*:*-w64-mingw32:config_opts=$config_opts --disable-udev", + "*:*-apple-darwin:config_opts=$config_opts --disable-udev", + "*:*:SHOULD_BUILD=echo", + "*:*-linux-gnu:SHOULD_BUILD=", + "*:*-w64-mingw32:SHOULD_BUILD=", + "*:*-apple-darwin:SHOULD_BUILD=" ], "steps": [ - "all:cp -f $PREFIX/native/usr/share/config/config.guess config.guess", - "all:cp -f $PREFIX/native/usr/share/config/config.sub config.sub", - "all:$SHOULD_BUILD ./configure $config_opts", - "all:$SHOULD_BUILD make -j$NUM_CORES", - "all:$SHOULD_BUILD make -j$NUM_CORES DESTDIR=$STAGING_DIR install", - "all:$SHOULD_BUILD cp -f $STAGING_DIR$PREFIX/lib/libusb-1.0.a $STAGING_DIR$PREFIX/lib/libusb.a" + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess config.guess", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub config.sub", + "*:*:$SHOULD_BUILD ./configure $config_opts", + "*:*:$SHOULD_BUILD make -j$NUM_CORES", + "*:*:$SHOULD_BUILD make -j$NUM_CORES DESTDIR=$STAGING_DIR install", + "*:*:$SHOULD_BUILD cp -f $STAGING_DIR$PREFIX/lib/libusb-1.0.a $STAGING_DIR$PREFIX/lib/libusb.a" ] } } \ No newline at end of file diff --git a/packages/libxcb@1_17_0.json b/packages/libxcb@1_17_0.json new file mode 100644 index 0000000..d17662c --- /dev/null +++ b/packages/libxcb@1_17_0.json @@ -0,0 +1,43 @@ +{ + "package": "libxcb@1_17_0", + "version": "1_17_0", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "2c69287424c9e2128cb47ffe92171e10417041ec2963bceafb65cb3fcf8f0b85", + "url": "https://xcb.freedesktop.org/dist/libxcb-1.17.0.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/patch", + "*:*-linux-gnu:native/python@3.11", + "*:*-linux-gnu:native/sed", + "*:*-linux-gnu:xcb_proto@1_17_0", + "*:*-linux-gnu:xorgproto@2025_1", + "*:*-linux-gnu:libXau@1_0_12" + ], + "patches": [ + "remove_pthread_stubs.patch" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-devel-docs --without-doxygen --without-launchd --disable-dependency-tracking --enable-option-checking --disable-composite --disable-damage --disable-dpms --disable-dri2 --disable-dri3 --disable-glx --disable-present --disable-record --disable-resource --disable-screensaver --disable-xevie --disable-xfree86-dri --disable-xinput --disable-xprint --disable-selinux --disable-xtest --disable-xv --disable-xvmc" + ], + "steps": [ + "*:*-linux-gnu:patch -p1 < $PATCH_DIR/libxcb/remove_pthread_stubs.patch", + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/share $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/libxcb_util@0_4_1.json b/packages/libxcb_util@0_4_1.json new file mode 100644 index 0000000..beb42a3 --- /dev/null +++ b/packages/libxcb_util@0_4_1.json @@ -0,0 +1,38 @@ +{ + "package": "libxcb_util@0_4_1", + "version": "0_4_1", + "type": "host", + "download": [ + { + "kind": "tar.xz", + "sha256": "5abe3bbbd8e54f0fa3ec945291b7e8fa8cfd3cccc43718f8758430f94126e512", + "url": "https://xcb.freedesktop.org/dist/xcb-util-0.4.1.tar.xz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:libxcb@1_17_0", + "*:*-linux-gnu:libXau@1_0_12", + "*:*-linux-gnu:xorgproto@2025_1", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-devel-docs --without-doxygen --disable-dependency-tracking --enable-option-checking" + ], + "steps": [ + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/share $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/libxcb_util_cursor@0_1_6.json b/packages/libxcb_util_cursor@0_1_6.json new file mode 100644 index 0000000..1d12e49 --- /dev/null +++ b/packages/libxcb_util_cursor@0_1_6.json @@ -0,0 +1,42 @@ +{ + "package": "libxcb_util_cursor@0_1_6", + "version": "0_1_6", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "eae38b2dfc5c529a886e507ef576b12d2a20aa1f149608e4853af760f31be60b", + "url": "https://xcb.freedesktop.org/dist/xcb-util-cursor-0.1.6.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/m4", + "*:*-linux-gnu:libxcb@1_17_0", + "*:*-linux-gnu:libXau@1_0_12", + "*:*-linux-gnu:xorgproto@2025_1", + "*:*-linux-gnu:libxcb_util@0_4_1", + "*:*-linux-gnu:libxcb_util_image@0_4_1", + "*:*-linux-gnu:libxcb_util_render@0_3_10", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-devel-docs --without-doxygen --disable-dependency-tracking --enable-option-checking" + ], + "steps": [ + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/share $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/libxcb_util_image@0_4_1.json b/packages/libxcb_util_image@0_4_1.json new file mode 100644 index 0000000..543cc3d --- /dev/null +++ b/packages/libxcb_util_image@0_4_1.json @@ -0,0 +1,39 @@ +{ + "package": "libxcb_util_image@0_4_1", + "version": "0_4_1", + "type": "host", + "download": [ + { + "kind": "tar.xz", + "sha256": "ccad8ee5dadb1271fd4727ad14d9bd77a64e505608766c4e98267d9aede40d3d", + "url": "https://xcb.freedesktop.org/dist/xcb-util-image-0.4.1.tar.xz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:libxcb@1_17_0", + "*:*-linux-gnu:libXau@1_0_12", + "*:*-linux-gnu:xorgproto@2025_1", + "*:*-linux-gnu:libxcb_util@0_4_1", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-devel-docs --without-doxygen --disable-dependency-tracking --enable-option-checking" + ], + "steps": [ + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES -C image", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR -C image install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/share $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/libxcb_util_keysyms@0_4_1.json b/packages/libxcb_util_keysyms@0_4_1.json new file mode 100644 index 0000000..d3adfd8 --- /dev/null +++ b/packages/libxcb_util_keysyms@0_4_1.json @@ -0,0 +1,38 @@ +{ + "package": "libxcb_util_keysyms@0_4_1", + "version": "0_4_1", + "type": "host", + "download": [ + { + "kind": "tar.xz", + "sha256": "7c260a5294412aed429df1da2f8afd3bd07b7cba3fec772fba15a613a6d5c638", + "url": "https://xcb.freedesktop.org/dist/xcb-util-keysyms-0.4.1.tar.xz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:libxcb@1_17_0", + "*:*-linux-gnu:libXau@1_0_12", + "*:*-linux-gnu:xorgproto@2025_1", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-devel-docs --without-doxygen --disable-dependency-tracking --enable-option-checking" + ], + "steps": [ + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/share $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/libxcb_util_render@0_3_10.json b/packages/libxcb_util_render@0_3_10.json new file mode 100644 index 0000000..aca18a2 --- /dev/null +++ b/packages/libxcb_util_render@0_3_10.json @@ -0,0 +1,38 @@ +{ + "package": "libxcb_util_render@0_3_10", + "version": "0_3_10", + "type": "host", + "download": [ + { + "kind": "tar.xz", + "sha256": "3e15d4f0e22d8ddbfbb9f5d77db43eacd7a304029bf25a6166cc63caa96d04ba", + "url": "https://xcb.freedesktop.org/dist/xcb-util-renderutil-0.3.10.tar.xz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:libxcb@1_17_0", + "*:*-linux-gnu:libXau@1_0_12", + "*:*-linux-gnu:xorgproto@2025_1", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-devel-docs --without-doxygen --disable-dependency-tracking --enable-option-checking" + ], + "steps": [ + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/share $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/libxcb_util_wm@0_4_2.json b/packages/libxcb_util_wm@0_4_2.json new file mode 100644 index 0000000..1f09853 --- /dev/null +++ b/packages/libxcb_util_wm@0_4_2.json @@ -0,0 +1,39 @@ +{ + "package": "libxcb_util_wm@0_4_2", + "version": "0_4_2", + "type": "host", + "download": [ + { + "kind": "tar.xz", + "sha256": "62c34e21d06264687faea7edbf63632c9f04d55e72114aa4a57bb95e4f888a0b", + "url": "https://xcb.freedesktop.org/dist/xcb-util-wm-0.4.2.tar.xz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/diffutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/m4", + "*:*-linux-gnu:libxcb@1_17_0", + "*:*-linux-gnu:libXau@1_0_12", + "*:*-linux-gnu:xorgproto@2025_1", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --disable-shared --enable-static --disable-devel-docs --without-doxygen --disable-dependency-tracking --enable-option-checking" + ], + "steps": [ + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/share $STAGING_DIR$PREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/libxcrypt.json b/packages/libxcrypt.json new file mode 100644 index 0000000..632cf5e --- /dev/null +++ b/packages/libxcrypt.json @@ -0,0 +1,33 @@ +{ + "package": "libxcrypt", + "version": "4.4.38", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "55ea777e8d567e5e86ffac917c28815ac54cc341", + "url": "https://github.com/besser82/libxcrypt" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [ + "*:*:config_opts=--host=$HOST --prefix=$PREFIX", + "*:*:config_opts=$config_opts --enable-static --disable-shared --with-pic" + ], + "steps": [ + "*:*:./autogen.sh", + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make install DESTDIR=$STAGING_DIR" + ] + } +} \ No newline at end of file diff --git a/packages/libxkbcommon@1_13_1.json b/packages/libxkbcommon@1_13_1.json new file mode 100644 index 0000000..54b9342 --- /dev/null +++ b/packages/libxkbcommon@1_13_1.json @@ -0,0 +1,45 @@ +{ + "package": "libxkbcommon@1_13_1", + "version": "1_13_1", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "aeb951964c2f7ecc08174cb5517962d157595e9e3f38fc4a130b91dc2f9fec18", + "url": "https://github.com/xkbcommon/libxkbcommon/archive/refs/tags/xkbcommon-1.13.1.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/bison", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/m4", + "*:*-linux-gnu:native/meson", + "*:*-linux-gnu:native/ninja", + "*:*-linux-gnu:native/patch", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/python@3.11", + "*:*-linux-gnu:libxcb@1_17_0", + "*:*-linux-gnu:libXau@1_0_12", + "*:*-linux-gnu:native/sed" + ], + "patches": [ + "no-test-x11.patch", + "toolchain.txt" + ], + "build": { + "env": [], + "steps": [ + "*:*-linux-gnu:patch -p1 < $PATCH_DIR/libxkbcommon/no-test-x11.patch", + "*:*-linux-gnu:cp $PATCH_DIR/libxkbcommon/toolchain.txt toolchain.txt", + "*:*-linux-gnu:sed -i -e \"s|@host_prefix@|$PREFIX|\" -e \"s|@cc@|$CC|\" -e \"s|@cxx@|$CXX|\" -e \"s|@ar@|$AR|\" -e \"s|@strip@|$STRIP|\" -e \"s|@arch@|$ARCH|\" toolchain.txt", + "*:*-linux-gnu:$NATIVEPREFIX/bin/meson setup --cross-file toolchain.txt build -Dxkb-config-root=/usr/share/X11/xkb -Dxkb-config-extra-path=/app/share/X11/xkb", + "*:*-linux-gnu:ninja -C build", + "*:*-linux-gnu:DESTDIR=$STAGING_DIR ninja -C build install" + ] + } +} \ No newline at end of file diff --git a/packages/lz4.json b/packages/lz4.json new file mode 100644 index 0000000..6c89c74 --- /dev/null +++ b/packages/lz4.json @@ -0,0 +1,33 @@ +{ + "package": "lz4", + "version": "v1.10.0", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "ebb370ca83af193212df4dcbadcc5d87bc0de2f0", + "url": "https://github.com/lz4/lz4.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/make" + ], + "patches": [ + "fix_declaration.patch" + ], + "build": { + "env": [ + "*:*:config_opts=-DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX" + ], + "steps": [ + "*:*:mkdir -p build/cmake/build", + "*:*:cd build/cmake/build && cmake .. $config_opts", + "*:*:cd build/cmake/build && make -j$NUM_CORES", + "*:*:cd build/cmake/build && make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/monero@fcmp-stage.json b/packages/monero@fcmp-stage.json new file mode 100644 index 0000000..bc97a84 --- /dev/null +++ b/packages/monero@fcmp-stage.json @@ -0,0 +1,108 @@ +{ + "package": "monero@fcmp-stage", + "version": "fcmp-stage", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "450c789fbe47e3c8847bf928fad9e7c5ccf39d16", + "url": "https://github.com/seraphis-migration/monero.git" + }, + { + "kind": "git", + "path": "external/gtest", + "sha256": "b514bdc898e2951020cbdca1304b75f5950d1f59", + "url": "https://github.com/google/googletest.git" + }, + { + "kind": "git", + "path": "external/mx25519", + "sha256": "e808a6406b254091f4ed83bf8ea35f032da7f0b7", + "url": "https://github.com/jeffro256/mx25519.git" + }, + { + "kind": "git", + "path": "external/miniupnp", + "sha256": "544e6fcc73c5ad9af48a8985c94f0f1d742ef2e0", + "url": "https://github.com/miniupnp/miniupnp.git" + }, + { + "kind": "git", + "path": "external/randomx", + "sha256": "102f8acf90a7649ada410de5499a7ec62e49e1da", + "url": "https://github.com/tevador/RandomX.git" + }, + { + "kind": "git", + "path": "external/rapidjson", + "sha256": "129d19ba7f496df5e33658527a7158c79b99c21c", + "url": "https://github.com/Tencent/rapidjson.git" + }, + { + "kind": "git", + "path": "external/supercop", + "sha256": "633500ad8c8759995049ccd022107d1fa8a1bbc9", + "url": "https://github.com/monero-project/supercop.git" + }, + { + "kind": "git", + "path": "external/rapidjson/thirdparty/gtest", + "sha256": "0a439623f75c029912728d80cb7f1b8b48739ca4", + "url": "https://github.com/google/googletest.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/curl", + "*:*:native/git", + "*:*:native/libpsl", + "*:*:native/libxml2", + "*:*:native/make", + "*:*:native/patch", + "*:*:native/pkgconf", + "*:*:native/protobuf", + "*:*:native/python@3.14", + "*:*:native/rust-toolchain", + "*:*:native/sed", + "*:*:boost@1_83_0", + "*:*:libiconv", + "*:*:openssl", + "*:*:protobuf", + "*:*:rust-std", + "*:*:sodium", + "*:*:unbound", + "*:*:zeromq", + "*:*:zlib" + ], + "patches": [ + "dummy_rt.patch", + "drop_translations.patch", + "remove_icu4c.patch", + "447.patch", + "fix-ios-depends-build.patch" + ], + "build": { + "env": [ + "*:*:config_opts=-DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", + "*:*:config_opts=$config_opts -DDEPENDS=ON", + "*:*:config_opts=$config_opts -DMANUAL_SUBMODULES=1", + "*:*:config_opts=$config_opts -DUSE_READLINE=OFF", + "*:*-android*:config_opts=$config_opts -DANDROID=ON" + ], + "steps": [ + "*:*:patch -p1 < $PATCH_DIR/monero@fcmp-stage/dummy_rt.patch", + "*:*:patch -p1 < $PATCH_DIR/monero@fcmp-stage/drop_translations.patch", + "*:*:patch -p1 < $PATCH_DIR/monero@fcmp-stage/remove_icu4c.patch", + "*:*:patch -p1 < $PATCH_DIR/monero@fcmp-stage/447.patch", + "*:*:patch -p1 < $PATCH_DIR/monero@fcmp-stage/fix-ios-depends-build.patch", + "*:*:mkdir -p build", + "*:*:cd build && cmake .. $config_opts", + "*:*:cd build && make -j$NUM_CORES", + "*:*:cd build && make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/7zip.json b/packages/native/7zip.json new file mode 100644 index 0000000..b590013 --- /dev/null +++ b/packages/native/7zip.json @@ -0,0 +1,36 @@ +{ + "package": "native/7zip", + "version": "26.01", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "8c63d71ff886bda90c86db28466287f977374237", + "url": "https://github.com/ip7z/7zip.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/diffutils", + "*:*:native/make", + "*:*:native/sed" + ], + "build": { + "env": [], + "steps": [ + "*:*:sed -i.bak 's/-Werror //g' CPP/7zip/7zip_gcc.mak", + "darwin_*:*:sed -i.bak 's/LIB2 = -lpthread -ldl/LIB2 = -lpthread -ldl -lc++ -lc++abi/' CPP/7zip/7zip_gcc.mak", + "darwin_arm64:*:cd CPP/7zip/Bundles/Format7zF && make -f ../../cmpl_mac_arm64.mak CC=\"$CC\" CXX=\"$CXX\" -j$NUM_CORES", + "darwin_amd64:*:cd CPP/7zip/Bundles/Format7zF && make -f ../../cmpl_mac_x64.mak CC=\"$CC\" CXX=\"$CXX\" -j$NUM_CORES", + "linux_*:*:cd CPP/7zip/Bundles/Format7zF && make -f ../../cmpl_clang.mak CC=\"$CC\" CXX=\"$CXX\" -j$NUM_CORES", + "darwin_arm64:*:cd CPP/7zip/Bundles/Alone2 && make -f ../../cmpl_mac_arm64.mak CC=\"$CC\" CXX=\"$CXX\" -j$NUM_CORES", + "darwin_amd64:*:cd CPP/7zip/Bundles/Alone2 && make -f ../../cmpl_mac_x64.mak CC=\"$CC\" CXX=\"$CXX\" -j$NUM_CORES", + "linux_*:*:cd CPP/7zip/Bundles/Alone2 && make -f ../../cmpl_clang.mak CC=\"$CC\" CXX=\"$CXX\" -j$NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/lib", + "*:*:cp ./CPP/7zip/Bundles/Alone2/b/*/7zz $STAGING_DIR$NATIVEPREFIX/bin/7zz", + "darwin_*:*:cp ./CPP/7zip/Bundles/Format7zF/b/*/7z.so $STAGING_DIR$NATIVEPREFIX/bin/7z.dylib", + "linux_:*:cp ./CPP/7zip/Bundles/Format7zF/b/*/7z.so $STAGING_DIR$NATIVEPREFIX/bin/7z.so" + ] + } +} \ No newline at end of file diff --git a/packages/native/README.md b/packages/native/README.md index 1d1324a..4c19a6a 100644 --- a/packages/native/README.md +++ b/packages/native/README.md @@ -1,3 +1,14 @@ # _native_ packages -These packages are intended to be ran on host when building. \ No newline at end of file +These packages are intended to be ran on host when building. + +## Windows (`windows_amd64`) + +Builder userspace ABI is **Cygwin** (`NativeTriplet` = `x86_64-pc-cygwin`). + +1. Provide a Cygwin+clang seed under `patches/native/_/windows_amd64_cygwin_clang/` (see README there). +2. `native/_/_` stages that seed into `$NATIVEPREFIX/_/`. +3. Rebuild `native/*` from source (make, bash, coreutils, …) with that compiler. +4. Build `native/crosstool-ng` then `native/ct-tools` from source for each `TOOL_TARGET`. + +Suggested climb order toward ct-tools: `native/make` → `native/bash` → coreutils/sed/grep/… → autotools → `native/xz` → `native/crosstool-ng` → `native/ct-tools`. diff --git a/packages/native/_.json b/packages/native/_.json new file mode 100644 index 0000000..045bd28 --- /dev/null +++ b/packages/native/_.json @@ -0,0 +1,227 @@ +{ + "package": "native/_", + "version": "0.0.0", + "type": "native", + "dependencies": [ + "*:*-android*:native/android_ndk", + "*:*-apple-*:native/cctools-port", + "*:*-apple-*:native/libc++", + "*:*-apple-*:native/libtapi", + "*:*-apple-*:native/libxml2", + "*:*-apple-*:native/osx-cross", + "*:*-apple-*:native/xar", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*-linux-gnu:native/ct-tools", + "*:*-linux-musl:native/ct-tools", + "*:*-w64-mingw32:native/ct-tools", + "*:*:native/_/_" + ], + "export-env": [ + "*:*:CC_FOR_BUILD=$CC", + "*:*:CXX_FOR_BUILD=$CXX", + "*:*:CFLAGS=$CFLAGS -I$PREFIX/include", + "*:*:CFLAGS=$CFLAGS -I$PREFIX/usr/include", + "*:*:CXXFLAGS=$CXXFLAGS -I$PREFIX/include", + "*:*:CXXFLAGS=$CXXFLAGS -I$PREFIX/usr/include", + "*:*:CPPFLAGS=$CPPFLAGS -I$PREFIX/include", + "*:*:CPPFLAGS=$CPPFLAGS -I$PREFIX/usr/include", + "*:*:CFLAGS=$CFLAGS -fPIC", + "*:*:CXXFLAGS=$CXXFLAGS -fPIC", + "*:*:LDFLAGS=$LDFLAGS -fPIC", + "none:*:LDFLAGS=$LDFLAGS -stdlib=libc++ -lc++ -lc++abi", + "*:*:LDFLAGS=$LDFLAGS -L$PREFIX/lib", + "*:*:LD_LIBRARY_PATH=$NATIVEPREFIX/lib", + "*:*:PKG_CONFIG_PATH=$NATIVEPREFIX/lib/pkgconfig:$PREFIX/lib/pkgconfig:$PREFIX/share/pkgconfig", + "*:*-linux-gnu:PKG_CONFIG_SYSROOT_DIR=$PREFIX", + "*:*-linux-gnu:PKG_CONFIG_LIBDIR=$NATIVEPREFIX/lib/pkgconfig:$PREFIX/lib/pkgconfig:$PREFIX/share/pkgconfig", + "*:*-apple-darwin:QT_MAC_SDK_NO_VERSION_CHECK=1", + "*:*-android*:ANDROID_NDK_ROOT=$NATIVEPREFIX", + "*:*:LIBRARY_PATH=$LIBRARY_PATH:$PREFIX/lib", + "*:aarch64-apple-darwin:RUST_TRIPLET=aarch64-apple-darwin", + "*:aarch64-apple-darwin:ARCH=aarch64", + "*:aarch64-apple-darwin:CMAKE_SYSTEM_NAME=Darwin", + "*:aarch64-apple-darwin:SDK_VERSION=26.1", + "*:aarch64-apple-darwin:SDK_PATH=$NATIVEPREFIX/SDK/MacOSX$SDK_VERSION.sdk", + "*:aarch64-apple-darwin:OSX_MIN_VERSION=13.0", + "*:aarch64-apple-darwin:LD64_VERSION=609", + "*:aarch64-apple-darwin:CC_target=arm64-apple-darwin", + "*:aarch64-apple-darwin:CC=$NATIVEPREFIX/bin/aarch64-apple-darwin-clang -mmacosx-version-min=$OSX_MIN_VERSION -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-darwin:CXX=$NATIVEPREFIX/bin/aarch64-apple-darwin-clang++ -mmacosx-version-min=$OSX_MIN_VERSION -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-darwin:CXXFLAGS=$CFLAGS -stdlib=libc++", + "*:aarch64-apple-darwin:RANLIB=$NATIVEPREFIX/bin/llvm-ranlib", + "*:aarch64-apple-darwin:STRIP=$NATIVEPREFIX/bin/strip", + "*:aarch64-apple-darwin:AR=$NATIVEPREFIX/bin/llvm-ar", + "*:aarch64-apple-darwin:NM=$NATIVEPREFIX/bin/llvm-nm", + "*:aarch64-apple-darwin:LIBTOOL=$NATIVEPREFIX/bin/llvm-libtool-darwin", + "*:aarch64-apple-darwin:LDFLAGS=-L$PREFIX/lib -lc++ -lc++abi", + "*:x86_64-apple-darwin:RUST_TRIPLET=x86_64-apple-darwin", + "*:x86_64-apple-darwin:ARCH=x86_64", + "*:x86_64-apple-darwin:CMAKE_SYSTEM_NAME=Darwin", + "*:x86_64-apple-darwin:SDK_VERSION=26.1", + "*:x86_64-apple-darwin:SDK_PATH=$NATIVEPREFIX/SDK/MacOSX$SDK_VERSION.sdk", + "*:x86_64-apple-darwin:OSX_MIN_VERSION=13.0", + "*:x86_64-apple-darwin:LD64_VERSION=609", + "*:x86_64-apple-darwin:CC_target=x86_64-apple-darwin", + "*:x86_64-apple-darwin:CC=$NATIVEPREFIX/bin/x86_64-apple-darwin-clang -mmacosx-version-min=$OSX_MIN_VERSION -isysroot $SDK_PATH -I$PREFIX/include", + "*:x86_64-apple-darwin:CXX=$NATIVEPREFIX/bin/x86_64-apple-darwin-clang++ -mmacosx-version-min=$OSX_MIN_VERSION -isysroot $SDK_PATH -I$PREFIX/include", + "*:x86_64-apple-darwin:CXXFLAGS=$CFLAGS -stdlib=libc++", + "*:x86_64-apple-darwin:RANLIB=$NATIVEPREFIX/bin/ranlib", + "*:x86_64-apple-darwin:AR=$NATIVEPREFIX/bin/ar", + "*:x86_64-apple-darwin:STRIP=$NATIVEPREFIX/bin/strip", + "*:x86_64-apple-darwin:NM=$NATIVEPREFIX/bin/nm", + "*:x86_64-apple-darwin:LIBTOOL=$NATIVEPREFIX/bin/llvm-libtool-darwin", + "*:x86_64-apple-darwin:LDFLAGS=-L$PREFIX/lib -lc++ -lc++abi", + "*:*-apple-*:RUST_LINK_CC=$NATIVEPREFIX/bin/$HOST-clang", + "*:aarch64-apple-ios:RUST_TRIPLET=aarch64-apple-ios", + "*:aarch64-apple-ios:ARCH=aarch64", + "*:aarch64-apple-ios:CMAKE_SYSTEM_NAME=iOS", + "*:aarch64-apple-ios:IOS_MIN_VERSION=12", + "*:aarch64-apple-ios:LD64_VERSION=609", + "*:aarch64-apple-ios:SDK_VERSION=26.1", + "*:aarch64-apple-ios:SDK_PATH=$NATIVEPREFIX/SDK/iPhoneOS$SDK_VERSION.sdk", + "*:aarch64-apple-ios:CC_target=aarch64-apple-ios", + "*:aarch64-apple-ios:CC=$NATIVEPREFIX/bin/aarch64-apple-ios-clang -target $CC_target -mios-version-min=$IOS_MIN_VERSION -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios:CXX=$NATIVEPREFIX/bin/aarch64-apple-ios-clang++ -target $CC_target -mios-version-min=$IOS_MIN_VERSION -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios:CXXFLAGS=$CFLAGS -stdlib=libc++", + "*:aarch64-apple-ios:RANLIB=$NATIVEPREFIX/bin/ranlib", + "*:aarch64-apple-ios:AR=$NATIVEPREFIX/bin/ar", + "*:aarch64-apple-ios:NM=$NATIVEPREFIX/bin/nm", + "*:aarch64-apple-ios:STRIP=$NATIVEPREFIX/bin/strip", + "*:aarch64-apple-ios:LIBTOOL=$NATIVEPREFIX/bin/libtool", + "*:aarch64-apple-ios:LDFLAGS=-lc++ -lc++abi", + "*:aarch64-apple-ios:LD=$NATIVEPREFIX/bin/lld", + "*:aarch64-apple-ios-simulator:RUST_TRIPLET=aarch64-apple-ios-sim", + "*:aarch64-apple-ios-simulator:ARCH=aarch64", + "*:aarch64-apple-ios-simulator:CMAKE_SYSTEM_NAME=iOS", + "*:aarch64-apple-ios-simulator:IOS_MIN_VERSION=12", + "*:aarch64-apple-ios-simulator:LD64_VERSION=609", + "*:aarch64-apple-ios-simulator:SDK_VERSION=26.1", + "*:aarch64-apple-ios-simulator:SDK_PATH=$NATIVEPREFIX/SDK/iPhoneSimulator$SDK_VERSION.sdk", + "*:aarch64-apple-ios-simulator:CC_target=aarch64-apple-ios-simulator", + "*:aarch64-apple-ios-simulator:CC=$NATIVEPREFIX/bin/aarch64-apple-ios-simulator-clang -target $CC_target -mios-version-min=$IOS_MIN_VERSION -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios-simulator:CXX=$NATIVEPREFIX/bin/aarch64-apple-ios-simulator-clang++ -target $CC_target -mios-version-min=$IOS_MIN_VERSION -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios-simulator:CXXFLAGS=$CFLAGS -stdlib=libc++", + "*:aarch64-apple-ios-simulator:RANLIB=$NATIVEPREFIX/bin/ranlib", + "*:aarch64-apple-ios-simulator:AR=$NATIVEPREFIX/bin/ar", + "*:aarch64-apple-ios-simulator:NM=$NATIVEPREFIX/bin/nm", + "*:aarch64-apple-ios-simulator:STRIP=$NATIVEPREFIX/bin/strip", + "*:aarch64-apple-ios-simulator:LIBTOOL=$NATIVEPREFIX/bin/libtool", + "*:aarch64-apple-ios-simulator:LDFLAGS=-lc++ -lc++abi", + "*:*-apple-*:INSTALL_NAME_TOOL=$NATIVEPREFIX/_/bin/install_name_tool", + "*:*-w64-mingw32:CMAKE_SYSTEM_NAME=Windows", + "*:*-w64-mingw32:CC_target=$HOST", + "*:*-w64-mingw32:RC=$NATIVEPREFIX/bin/$HOST-windres", + "*:*-w64-mingw32:RCFLAGS=-I$PREFIX/sysroot/usr/$HOST/include -I$PREFIX/include -I$PREFIX/usr/include", + "*:*-w64-mingw32:WINDRES=$RC $RCFLAGS", + "*:*-w64-mingw32:CC=$NATIVEPREFIX/bin/$HOST-gcc", + "*:*-w64-mingw32:CXX=$NATIVEPREFIX/bin/$HOST-g++", + "*:*-w64-mingw32:CFLAGS=--sysroot=$PREFIX/sysroot -I$PREFIX/sysroot/usr/$HOST/include -I$PREFIX/include -I$PREFIX/usr/include", + "*:*-w64-mingw32:CXXFLAGS=--sysroot=$PREFIX/sysroot -I$PREFIX/sysroot/usr/$HOST/include -I$PREFIX/include -I$PREFIX/include/c++/15.2.0 -I$PREFIX/include/c++/15.2.0/$HOST -I$PREFIX/usr/include", + "*:*-w64-mingw32:CPPFLAGS=-I$PREFIX/sysroot/usr/$HOST/include -I$PREFIX/include -I$PREFIX/usr/include", + "*:*-w64-mingw32:AR=$NATIVEPREFIX/bin/$HOST-ar", + "*:*-w64-mingw32:RANLIB=$NATIVEPREFIX/bin/$HOST-ranlib", + "*:*-w64-mingw32:AS=$NATIVEPREFIX/bin/$HOST-as", + "*:*-w64-mingw32:LIBTOOL=$NATIVEPREFIX/bin/$HOST-libtool", + "*:*-w64-mingw32:OBJCOPY=$NATIVEPREFIX/bin/$HOST-objcopy", + "*:*-w64-mingw32:OBJDUMP=$NATIVEPREFIX/bin/$HOST-objdump", + "*:*-w64-mingw32:STRIP=$NATIVEPREFIX/bin/$HOST-strip", + "*:*-w64-mingw32:READELF=$NATIVEPREFIX/bin/$HOST-readelf", + "*:*-w64-mingw32:LD=$NATIVEPREFIX/bin/$HOST-ld", + "*:*-w64-mingw32:NM=$NATIVEPREFIX/bin/$HOST-nm", + "*:x86_64-w64-mingw32:ARCH=x86_64", + "*:x86_64-w64-mingw32:RUST_TRIPLET=x86_64-pc-windows-gnu", + "*:*-linux-gnu:CMAKE_SYSTEM_NAME=Linux", + "*:*-linux-gnu:CC_target=$HOST", + "*:*-linux-gnu:CC=$NATIVEPREFIX/bin/$HOST-gcc", + "*:*-linux-gnu:CXX=$NATIVEPREFIX/bin/$HOST-g++", + "*:*-linux-gnu:CFLAGS=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/usr/include", + "*:*-linux-gnu:CXXFLAGS=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/include/c++/13.4.0 -I$PREFIX/include/c++/13.4.0/$HOST -I$PREFIX/usr/include", + "*:*-linux-gnu:CPPFLAGS=-I$PREFIX/include -I$PREFIX/usr/include", + "*:*-linux-gnu:LDFLAGS=--sysroot=$PREFIX/sysroot -L$PREFIX/lib -L$PREFIX/usr/lib", + "*:*-linux-gnu:AR=$NATIVEPREFIX/bin/$HOST-ar", + "*:*-linux-gnu:RANLIB=$NATIVEPREFIX/bin/$HOST-ranlib", + "*:*-linux-gnu:AS=$NATIVEPREFIX/bin/$HOST-as", + "*:*-linux-gnu:LIBTOOL=$NATIVEPREFIX/bin/$HOST-libtool", + "*:*-linux-gnu:OBJCOPY=$NATIVEPREFIX/bin/$HOST-objcopy", + "*:*-linux-gnu:OBJDUMP=$NATIVEPREFIX/bin/$HOST-objdump", + "*:*-linux-gnu:STRIP=$NATIVEPREFIX/bin/$HOST-strip", + "*:*-linux-gnu:READELF=$NATIVEPREFIX/bin/$HOST-readelf", + "*:*-linux-gnu:LD=$NATIVEPREFIX/bin/$HOST-ld", + "*:*-linux-gnu:NM=$NATIVEPREFIX/bin/$HOST-nm", + "*:x86_64-linux-gnu:ARCH=x86_64", + "*:aarch64-linux-gnu:ARCH=aarch64", + "*:*-linux-gnu:RUST_TRIPLET=$ARCH-unknown-linux-gnu", + "*:*-android*:CMAKE_SYSTEM_NAME=Android", + "*:*-android*:RANLIB=$NATIVEPREFIX/bin/llvm-ranlib", + "*:*-android*:AR=$NATIVEPREFIX/bin/llvm-ar", + "*:*-android*:STRIP=$NATIVEPREFIX/bin/llvm-strip", + "*:*-android*:NM=$NATIVEPREFIX/bin/llvm-nm", + "*:*-android*:AS=$NATIVEPREFIX/bin/llvm-as", + "*:*-android*:LIBTOOL=$NATIVEPREFIX/bin/libtool", + "*:*-android*:ANDROID_NDK_HOME=$NATIVEPREFIX/", + "*:*-android*:LDFLAGS=$LDFLAGS -lc -lc++abi -lm", + "*:*-android*:CXXFLAGS=$CXXFLAGS -stdlib=libc++", + "*:aarch64-linux-android:ARCH=aarch64", + "*:aarch64-linux-android:RUST_TRIPLET=aarch64-linux-android", + "*:aarch64-linux-android:CC=$NATIVEPREFIX/bin/aarch64-linux-android21-clang", + "*:aarch64-linux-android:CXX=$NATIVEPREFIX/bin/aarch64-linux-android21-clang++", + "*:x86_64-linux-android:ARCH=x86_64", + "*:x86_64-linux-android:RUST_TRIPLET=x86_64-linux-android", + "*:x86_64-linux-android:CC=$NATIVEPREFIX/bin/x86_64-linux-android21-clang", + "*:x86_64-linux-android:CXX=$NATIVEPREFIX/bin/x86_64-linux-android21-clang++", + "*:armv7a-linux-androideabi:ARCH=armv7a", + "*:armv7a-linux-androideabi:RUST_TRIPLET=armv7-linux-androideabi", + "*:armv7a-linux-androideabi:CC=$NATIVEPREFIX/bin/armv7a-linux-androideabi21-clang", + "*:armv7a-linux-androideabi:CXX=$NATIVEPREFIX/bin/armv7a-linux-androideabi21-clang++", + "*:armv7a-linux-androideabi:CXXFLAGS=$CXXFLAGS -DLIBC_NO_FSEEKO", + "*:*:CPP=$CC -E", + "*:*:CXXCPP=$CXX -E", + "*:x86_64-w64-mingw32:CPP=x86_64-w64-mingw32-cpp $CFLAGS", + "*:x86_64-w64-mingw32:CXXCPP=x86_64-w64-mingw32-cpp $CXXFLAGS", + "*:x86_64-linux-gnu:CPP=x86_64-linux-gnu-cpp $CFLAGS", + "*:x86_64-linux-gnu:CXXCPP=x86_64-linux-gnu-cpp $CXXFLAGS", + "*:aarch64-linux-gnu:CPP=aarch64-linux-gnu-cpp $CFLAGS", + "*:aarch64-linux-gnu:CXXCPP=aarch64-linux-gnu-cpp $CXXFLAGS", + "*:x86_64-linux-gnu:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$CC", + "*:x86_64-linux-gnu:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_RUSTFLAGS=-Clink-arg=--sysroot=$PREFIX/sysroot -Clink-arg=-L$PREFIX/lib -Clink-arg=-L$PREFIX/usr/lib", + "*:aarch64-linux-gnu:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$CC", + "*:aarch64-linux-gnu:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_RUSTFLAGS=-Clink-arg=--sysroot=$PREFIX/sysroot -Clink-arg=-L$PREFIX/lib -Clink-arg=-L$PREFIX/usr/lib", + "*:x86_64-w64-mingw32:CARGO_TARGET_X86_64_PC_WINDOWS_GNU_LINKER=$CC", + "*:x86_64-w64-mingw32:CARGO_TARGET_X86_64_PC_WINDOWS_GNU_RUSTFLAGS=-Clink-arg=--sysroot=$PREFIX/sysroot -Clink-arg=-L$PREFIX/lib -Clink-arg=-L$PREFIX/usr/lib", + "*:x86_64-apple-darwin:CARGO_TARGET_X86_64_APPLE_DARWIN_LINKER=$RUST_LINK_CC", + "*:x86_64-apple-darwin:CARGO_TARGET_X86_64_APPLE_DARWIN_RUSTFLAGS=-Clink-arg=-mmacosx-version-min=$OSX_MIN_VERSION -Clink-arg=-isysroot -Clink-arg=$SDK_PATH -Clink-arg=-L$PREFIX/lib -Clink-arg=-lc++ -Clink-arg=-lc++abi", + "*:aarch64-apple-darwin:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$RUST_LINK_CC", + "*:aarch64-apple-darwin:CARGO_TARGET_AARCH64_APPLE_DARWIN_RUSTFLAGS=-Clink-arg=-mmacosx-version-min=$OSX_MIN_VERSION -Clink-arg=-isysroot -Clink-arg=$SDK_PATH -Clink-arg=-L$PREFIX/lib -Clink-arg=-lc++ -Clink-arg=-lc++abi", + "*:aarch64-apple-ios:CARGO_TARGET_AARCH64_APPLE_IOS_LINKER=$RUST_LINK_CC", + "*:aarch64-apple-ios:CARGO_TARGET_AARCH64_APPLE_IOS_RUSTFLAGS=-Clink-arg=-mios-version-min=$IOS_MIN_VERSION -Clink-arg=-isysroot -Clink-arg=$SDK_PATH -Clink-arg=-L$PREFIX/lib -Clink-arg=-lc++ -Clink-arg=-lc++abi", + "*:aarch64-apple-ios-simulator:CARGO_TARGET_AARCH64_APPLE_IOS_SIM_LINKER=$RUST_LINK_CC", + "*:aarch64-apple-ios-simulator:CARGO_TARGET_AARCH64_APPLE_IOS_SIM_RUSTFLAGS=-Clink-arg=-mios-version-min=$IOS_MIN_VERSION -Clink-arg=-isysroot -Clink-arg=$SDK_PATH -Clink-arg=-L$PREFIX/lib -Clink-arg=-lc++ -Clink-arg=-lc++abi", + "*:aarch64-linux-android:CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER=$CC", + "*:aarch64-linux-android:CARGO_TARGET_AARCH64_LINUX_ANDROID_RUSTFLAGS=-Clink-arg=-L$PREFIX/lib -Clink-arg=-lc -Clink-arg=-lc++abi -Clink-arg=-lm", + "*:x86_64-linux-android:CARGO_TARGET_X86_64_LINUX_ANDROID_LINKER=$CC", + "*:x86_64-linux-android:CARGO_TARGET_X86_64_LINUX_ANDROID_RUSTFLAGS=-Clink-arg=-L$PREFIX/lib -Clink-arg=-lc -Clink-arg=-lc++abi -Clink-arg=-lm", + "*:armv7a-linux-androideabi:CARGO_TARGET_ARMV7_LINUX_ANDROIDEABI_LINKER=$CC", + "*:armv7a-linux-androideabi:CARGO_TARGET_ARMV7_LINUX_ANDROIDEABI_RUSTFLAGS=-Clink-arg=-L$PREFIX/lib -Clink-arg=-lc -Clink-arg=-lc++abi -Clink-arg=-lm" + ], + "build": { + "env": [ + "*:none:A_=This is a meta-package library that includes c and c++ compiler", + "*:none:B_=All packages included as dependencies (other than bootstrap packages) are copied over to staging dir" + ], + "steps": [ + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:rm -rf $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $NATIVEPREFIX $STAGING_DIR$NATIVEPREFIX", + "darwin_arm64:*:rm -rf $STAGING_DIR$NATIVEPREFIX/_", + "linux_amd64:*:rm -rf $STAGING_DIR$NATIVEPREFIX/_", + "linux_arm64:*:rm -rf $STAGING_DIR$NATIVEPREFIX/_", + "*:*:mkdir -p $STAGING_DIR$PREFIX", + "*:*:rm -rf $STAGING_DIR$PREFIX", + "*:*:cp -a $PREFIX $STAGING_DIR$PREFIX", + "*:*:rm -rf $STAGING_DIR$PREFIX/bootstrap", + "*:*:mkdir -p $STAGING_DIR$HOME", + "*:*:touch $STAGING_DIR$HOME/.zshrc" + ] + } +} \ No newline at end of file diff --git a/packages/native/_/_.json b/packages/native/_/_.json new file mode 100644 index 0000000..49eedf2 --- /dev/null +++ b/packages/native/_/_.json @@ -0,0 +1,78 @@ +{ + "package": "native/_/_", + "version": "0.0.0", + "type": "native", + "dependencies": [ + "darwin_arm64:*:native/_/darwin_arm64_clang21", + "linux_amd64:*:native/_/linux_amd64_clang21", + "linux_arm64:*:native/_/linux_arm64_clang21", + "windows_amd64:*:native/_/windows_amd64_cygwin_clang" + ], + "export-env": [ + "darwin_arm64:*:OSX_MIN_VERSION=13.0", + "darwin_arm64:*:CC=$NATIVEPREFIX/_/bin/clang", + "darwin_arm64:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "darwin_arm64:*:LDFLAGS=$LDFLAGS -stdlib=libc++ -lc++ -lc++abi", + "darwin_arm64:*:AR=$NATIVEPREFIX/_/bin/ar", + "darwin_arm64:*:RANLIB=$NATIVEPREFIX/_/bin/ranlib", + "darwin_arm64:*:STRIP=$NATIVEPREFIX/_/bin/strip", + "darwin_arm64:*:NM=$NATIVEPREFIX/_/bin/nm", + "darwin_arm64:*:OTOOL=$NATIVEPREFIX/_/bin/otool", + "darwin_arm64:*:INSTALL_NAME_TOOL=$NATIVEPREFIX/_/bin/install_name_tool", + "darwin_arm64:*:lt_cv_prog_gnu_ld=no", + "linux_amd64:*:CC=$NATIVEPREFIX/_/bin/clang", + "linux_amd64:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "linux_amd64:*:AR=$NATIVEPREFIX/_/bin/ar", + "linux_amd64:*:RANLIB=$NATIVEPREFIX/_/bin/ranlib", + "linux_amd64:*:STRIP=$NATIVEPREFIX/_/bin/strip", + "linux_amd64:*:NM=$NATIVEPREFIX/_/bin/nm", + "linux_arm64:*:CC=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "linux_arm64:*:AR=$NATIVEPREFIX/_/bin/ar", + "linux_arm64:*:RANLIB=$NATIVEPREFIX/_/bin/ranlib", + "linux_arm64:*:STRIP=$NATIVEPREFIX/_/bin/strip", + "linux_arm64:*:NM=$NATIVEPREFIX/_/bin/nm", + "windows_amd64:*:CC=$NATIVEPREFIX/_/bin/gcc", + "windows_amd64:*:CXX=$NATIVEPREFIX/_/bin/g++", + "windows_amd64:*:AR=$NATIVEPREFIX/_/bin/ar", + "windows_amd64:*:RANLIB=$NATIVEPREFIX/_/bin/ranlib", + "windows_amd64:*:STRIP=$NATIVEPREFIX/_/bin/strip", + "windows_amd64:*:NM=$NATIVEPREFIX/_/bin/nm", + "*:*:CFLAGS=$CFLAGS -I$NATIVEPREFIX/include", + "*:*:CXXFLAGS=$CXXFLAGS -I$NATIVEPREFIX/include", + "*:*:CPPFLAGS=$CPPFLAGS -I$NATIVEPREFIX/include", + "linux_*:*:CFLAGS=$CFLAGS -fPIC", + "linux_*:*:CXXFLAGS=$CXXFLAGS -fPIC", + "linux_*:*:LDFLAGS=$LDFLAGS -fPIC", + "darwin_*:*:CFLAGS=$CFLAGS -fPIC", + "darwin_*:*:CXXFLAGS=$CXXFLAGS -fPIC", + "darwin_*:*:LDFLAGS=$LDFLAGS -fPIC", + "*:*:CC_FOR_BUILD=$CC", + "*:*:CXX_FOR_BUILD=$CXX", + "*:*:HOST_CC=$CC", + "*:*:HOST_CXX=$CXX", + "darwin_arm64:*:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$CC", + "linux_amd64:*:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$CC", + "linux_arm64:*:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$CC", + "windows_amd64:*:CARGO_TARGET_X86_64_PC_WINDOWS_GNU_LINKER=$CC", + "*:*:LDFLAGS=$LDFLAGS -L$NATIVEPREFIX/lib", + "linux_*:*:LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$NATIVEPREFIX/lib", + "darwin_*:*:LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$NATIVEPREFIX/lib", + "*:*:LIBRARY_PATH=$LIBRARY_PATH:$NATIVEPREFIX/lib", + "*:*:CC_BUILD=$CC $CFLAGS", + "*:*:CXX_BUILD=$CXX $CXXFLAGS" + ], + "build": { + "env": [ + "*:none:A_=This is a meta-package library that includes c and c++ compiler", + "*:none:B_=All packages included as dependencies (other than bootstrap packages) are copied over to staging dir." + ], + "steps": [ + "*:*:$NATIVEPREFIX/_/bin/mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:$NATIVEPREFIX/_/bin/rm -rf $STAGING_DIR$NATIVEPREFIX", + "darwin_arm64:*:$NATIVEPREFIX/_/bin/cp -a $NATIVEPREFIX $STAGING_DIR$NATIVEPREFIX", + "linux_*:*:$NATIVEPREFIX/_/bin/cp -a $NATIVEPREFIX $STAGING_DIR$NATIVEPREFIX", + "windows_amd64:*:$NATIVEPREFIX/_/bin/cp -a $NATIVEPREFIX $STAGING_DIR$NATIVEPREFIX" + ] + } +} \ No newline at end of file diff --git a/packages/native/_/clang@19.json b/packages/native/_/clang@19.json new file mode 100644 index 0000000..504150c --- /dev/null +++ b/packages/native/_/clang@19.json @@ -0,0 +1,52 @@ +{ + "package": "native/_/clang@19", + "version": "19.1.7", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "82401fea7b79d0078043f7598b835284d6650a75b93e64b6f761ea7b63097501", + "url": "https://github.com/llvm/llvm-project/releases/download/llvmorg-19.1.7/llvm-project-19.1.7.src.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/libc++", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [ + "*:*:config_opts=-G Ninja -S llvm -B build", + "*:*:config_opts=$config_opts -DCMAKE_BUILD_TYPE=Release", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$NATIVEPREFIX/clang@19", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_PROJECTS='clang;lld'", + "*:*:config_opts=$config_opts -DLLVM_INCLUDE_TESTS=OFF", + "*:*:config_opts=$config_opts -DLLVM_INCLUDE_BENCHMARKS=OFF", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_TERMINFO=OFF", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_LIBCXX=ON", + "linux_amd64:*:config_opts=$config_opts -DLLVM_HOST_TRIPLE=x86_64-linux-gnu", + "linux_amd64:*:config_opts=$config_opts -DLLVM_TARGETS_TO_BUILD='X86;AArch64'", + "linux_arm64:*:config_opts=$config_opts -DLLVM_HOST_TRIPLE=aarch64-linux-gnu", + "linux_arm64:*:config_opts=$config_opts -DLLVM_TARGETS_TO_BUILD='AArch64;X86'", + "linux_*:*:CC=$NATIVEPREFIX/_/bin/clang", + "linux_*:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "linux_*:*:config_opts=$config_opts -DCMAKE_C_COMPILER=$NATIVEPREFIX/_/bin/clang", + "linux_*:*:config_opts=$config_opts -DCMAKE_CXX_COMPILER=$NATIVEPREFIX/_/bin/clang++", + "linux_*:*:CMAKE_CXX_FLAGS=-stdlib=libc++ -I$NATIVEPREFIX/include/c++/v1", + "linux_*:*:CMAKE_EXE_LINKER_FLAGS=-L$NATIVEPREFIX/lib -stdlib=libc++ -lc++ -lc++abi -lunwind -latomic -Wl,-rpath,$NATIVEPREFIX/lib", + "linux_*:*:CMAKE_SHARED_LINKER_FLAGS=-L$NATIVEPREFIX/lib -stdlib=libc++ -lc++ -lc++abi -lunwind -Wl,-rpath,$NATIVEPREFIX/lib" + ], + "steps": [ + "linux_*:*:cmake $config_opts -DCMAKE_CXX_FLAGS=\"$CMAKE_CXX_FLAGS\" -DCMAKE_EXE_LINKER_FLAGS=\"$CMAKE_EXE_LINKER_FLAGS\" -DCMAKE_SHARED_LINKER_FLAGS=\"$CMAKE_SHARED_LINKER_FLAGS\"", + "*:*:cmake --build build --target clang lld -j$NUM_CORES", + "*:*:DESTDIR=$STAGING_DIR cmake --install build --component clang", + "*:*:DESTDIR=$STAGING_DIR cmake --install build --component clang-resource-headers", + "*:*:DESTDIR=$STAGING_DIR cmake --install build --component lld" + ] + } +} \ No newline at end of file diff --git a/packages/native/_/darwin_arm64_clang21.json b/packages/native/_/darwin_arm64_clang21.json new file mode 100644 index 0000000..a269c07 --- /dev/null +++ b/packages/native/_/darwin_arm64_clang21.json @@ -0,0 +1,18 @@ +{ + "package": "native/_/darwin_arm64_clang21", + "version": "0.0.0", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "80e16711526b83f323a1014479a19a816e24f785f30dd712b5be297cc9b604e1", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r1/clang21-aarch64-apple-darwin.tar.xz" + } + ], + "build": { + "steps": [ + "*:*:./bin/mkdir -p $STAGING_DIR$NATIVEPREFIX/_/", + "*:*:./bin/cp -a * $STAGING_DIR$NATIVEPREFIX/_/" + ] + } +} \ No newline at end of file diff --git a/packages/native/_/gcc@15_2_0.json b/packages/native/_/gcc@15_2_0.json new file mode 100644 index 0000000..4b59888 --- /dev/null +++ b/packages/native/_/gcc@15_2_0.json @@ -0,0 +1,58 @@ +{ + "package": "native/_/gcc@15_2_0", + "version": "15.2.0", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "438fd996826b0c82485a29da03a72d71d6e3541a83ec702df4271f6fe025d24e", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-15.2.0/gcc-15.2.0.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/binutils@2.46.0", + "*:*:native/coreutils", + "*:*:native/diffutils", + "*:*:native/gawk", + "*:*:native/gmp_shared", + "*:*:native/grep", + "*:*:native/make", + "*:*:native/mpc", + "*:*:native/mpfr", + "*:*:native/sed", + "*:*:native/tar", + "*:*:native/zlib" + ], + "export-env": [ + "linux_amd64:*:CC=$NATIVEPREFIX/bin/gcc", + "linux_amd64:*:CXX=$NATIVEPREFIX/bin/g++", + "linux_amd64:*:AR=$NATIVEPREFIX/bin/ar", + "linux_amd64:*:RANLIB=$NATIVEPREFIX/bin/ranlib", + "linux_amd64:*:STRIP=$NATIVEPREFIX/bin/strip", + "linux_amd64:*:NM=$NATIVEPREFIX/bin/nm", + "linux_amd64:*:LDFLAGS=$LDFLAGS -L$NATIVEPREFIX/lib/gcc/x86_64-pc-linux-gnu/15.2.0", + "linux_arm64:*:CC=$NATIVEPREFIX/bin/gcc", + "linux_arm64:*:CXX=$NATIVEPREFIX/bin/g++", + "linux_arm64:*:AR=$NATIVEPREFIX/bin/ar", + "linux_arm64:*:RANLIB=$NATIVEPREFIX/bin/ranlib", + "linux_arm64:*:STRIP=$NATIVEPREFIX/bin/strip", + "linux_arm64:*:NM=$NATIVEPREFIX/bin/nm", + "linux_arm64:*:LDFLAGS=$LDFLAGS -L$NATIVEPREFIX/lib/gcc/aarch64-linux-gnu/15.2.0" + ], + "build": { + "env": [ + "linux_*:*:CC=$NATIVEPREFIX/_/bin/clang", + "linux_*:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "*:*:config_opts=--prefix=$NATIVEPREFIX --disable-multilib --enable-languages=c,c++ --disable-bootstrap --disable-libsanitizer --disable-libvtv --disable-libphobos --disable-libssp --disable-libquadmath --disable-libgomp --without-isl --with-system-zlib --with-gmp=$NATIVEPREFIX --with-mpfr=$NATIVEPREFIX --with-mpc=$NATIVEPREFIX --disable-nls" + ], + "steps": [ + "*:*:$NATIVEPREFIX/bin/mkdir -p build", + "*:*:cd build && env -u LIBRARY_PATH ../configure $config_opts CC=\"$CC\" CXX=\"$CXX\"", + "*:*:cd build && env -u LIBRARY_PATH make -j$NUM_CORES all-gcc all-target-libgcc all-target-libstdc++-v3 all-target-libatomic", + "*:*:cd build && env -u LIBRARY_PATH make DESTDIR=$STAGING_DIR install-gcc install-target-libgcc install-target-libstdc++-v3 install-target-libatomic", + "*:*:$NATIVEPREFIX/bin/ln -sf gcc $STAGING_DIR$NATIVEPREFIX/bin/cc" + ] + } +} \ No newline at end of file diff --git a/packages/native/_/linux_amd64_clang21.json b/packages/native/_/linux_amd64_clang21.json new file mode 100644 index 0000000..0df1f88 --- /dev/null +++ b/packages/native/_/linux_amd64_clang21.json @@ -0,0 +1,18 @@ +{ + "package": "native/_/linux_amd64_clang21", + "version": "0.0.0", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "9442ba966d3a1d3134e55ab21bf55ee3d4f281c0b850e3ef476a6314d373524d", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-x86_64-linux-gnu.tar.xz" + } + ], + "build": { + "steps": [ + "*:*:./bin/mkdir -p $STAGING_DIR$NATIVEPREFIX/_/", + "*:*:./bin/cp -a * $STAGING_DIR$NATIVEPREFIX/_/" + ] + } +} \ No newline at end of file diff --git a/packages/native/_/linux_arm64_clang21.json b/packages/native/_/linux_arm64_clang21.json new file mode 100644 index 0000000..87dbb72 --- /dev/null +++ b/packages/native/_/linux_arm64_clang21.json @@ -0,0 +1,18 @@ +{ + "package": "native/_/linux_arm64_clang21", + "version": "0.0.0", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "9962a2889f1782e904baa34a77e9e12d2fe7feecb845287f378999c7e442d001", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-aarch64-linux-gnu.tar.xz" + } + ], + "build": { + "steps": [ + "*:*:./bin/mkdir -p $STAGING_DIR$NATIVEPREFIX/_/", + "*:*:./bin/cp -a * $STAGING_DIR$NATIVEPREFIX/_/" + ] + } +} \ No newline at end of file diff --git a/packages/native/_/windows_amd64_cygwin_clang.json b/packages/native/_/windows_amd64_cygwin_clang.json new file mode 100644 index 0000000..c862441 --- /dev/null +++ b/packages/native/_/windows_amd64_cygwin_clang.json @@ -0,0 +1,18 @@ +{ + "package": "native/_/windows_amd64_cygwin_clang", + "version": "0.0.0", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "6b31052404b8c5eb9f66c48230aafa4e2947b9dc6a6048515aae67e9c33e87a6", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r2/clang20-x86_64-windows-cygwin.tar.xz" + } + ], + "build": { + "steps": [ + "*:*:./bin/mkdir -p $STAGING_DIR$NATIVEPREFIX/_/", + "*:*:./bin/cp -a bin etc include lib libexec sbin share tmp usr $STAGING_DIR$NATIVEPREFIX/_/ || true" + ] + } +} \ No newline at end of file diff --git a/packages/native/android_ndk.json b/packages/native/android_ndk.json index d6aec79..870e44a 100644 --- a/packages/native/android_ndk.json +++ b/packages/native/android_ndk.json @@ -2,42 +2,58 @@ "package": "native/android_ndk", "version": "r28c", "type": "native", - "download": { - "kind": "none" - }, + "download": [ + { + "kind": "blob", + "path": "android-ndk-r28c-darwin.zip", + "sha256": "0d4599e8bbf1a1668a0d51a541729b2246360f350018a2081d0b302dbb594f2a", + "url": "https://dl.google.com/android/repository/android-ndk-r28c-darwin.zip" + }, + { + "kind": "blob", + "path": "android-ndk-r28c-linux.zip", + "sha256": "dfb20d396df28ca02a8c708314b814a4d961dc9074f9a161932746f815aa552f", + "url": "https://dl.google.com/android/repository/android-ndk-r28c-linux.zip" + } + ], "dependencies": [ - "all:native/p7zip" + "*:*-android*:native/7zip", + "*:*-android*:native/_/_", + "*:*-android*:native/python@3.11" ], "build": { "env": [ - "aarch64-linux-android:config_opts=--arch arm", - "x86_64-linux-android:config_opts=--arch x86_64", - "armv7a-linux-androideabi:config_opts=--arch arm64", - "i686-linux-android:config_opts=--arch x86", - "aarch64-linux-android:BUILDLIB_HOST=aarch64-linux-android", - "x86_64-linux-android:BUILDLIB_HOST=x86_64-linux-android", - "armv7a-linux-androideabi:BUILDLIB_HOST=armv7a-linux-androideabi", - "i686-linux-android:BUILDLIB_HOST=i686-linux-android", - "*-android*:API_LEVEL=21" + "*:aarch64-linux-android:config_opts=--arch arm64", + "*:x86_64-linux-android:config_opts=--arch x86_64", + "*:armv7a-linux-androideabi:config_opts=--arch arm", + "*:i686-linux-android:config_opts=--arch x86", + "*:aarch64-linux-android:BUILDLIB_HOST=aarch64-linux-android", + "*:x86_64-linux-android:BUILDLIB_HOST=x86_64-linux-android", + "*:armv7a-linux-androideabi:BUILDLIB_HOST=armv7a-linux-androideabi", + "*:i686-linux-android:BUILDLIB_HOST=i686-linux-android", + "*:*-android*:API_LEVEL=21" ], "steps": [ - "*-android*:if [ $(uname) = 'Darwin' ]; then curl -o android-ndk-r28c-darwin.zip https://dl.google.com/android/repository/android-ndk-r28c-darwin.zip; else true; fi", - "*-android*:if [ $(uname) = 'Darwin' ]; then echo '0d4599e8bbf1a1668a0d51a541729b2246360f350018a2081d0b302dbb594f2a android-ndk-r28c-darwin.zip' | shasum -a 256 -c -; else true; fi", - "*-android*:if [ $(uname) = 'Linux' ]; then curl -o android-ndk-r28c-linux.zip https://dl.google.com/android/repository/android-ndk-r28c-linux.zip; else true; fi", - "*-android*:if [ $(uname) = 'Linux' ]; then echo 'dfb20d396df28ca02a8c708314b814a4d961dc9074f9a161932746f815aa552f android-ndk-r28c-linux.zip' | sha256sum -c -; else true; fi", - "*-android*:7z x $PWD/android-ndk-r28c-*.zip", - "*-android*:android-ndk-r28c/build/tools/make_standalone_toolchain.py --api $API_LEVEL --install-dir $PWD/toolchain --stl=libc++ $config_opts", - "*-android*:mkdir -p $STAGING_DIR$PREFIX/native", - "*-android*:mv $PWD/toolchain/* $STAGING_DIR$PREFIX/native", - "*-android*:cp $STAGING_DIR$PREFIX/native/bin/llvm-ar $STAGING_DIR$PREFIX/native/bin/$BUILDLIB_HOST-ar", - "*-android*:cp $STAGING_DIR$PREFIX/native/bin/$BUILDLIB_HOST$API_LEVEL-clang $STAGING_DIR$PREFIX/native/bin/$BUILDLIB_HOST-clang", - "*-android*:cp $STAGING_DIR$PREFIX/native/bin/$BUILDLIB_HOST$API_LEVEL-clang++ $STAGING_DIR$PREFIX/native/bin/$BUILDLIB_HOST-clang++", - "*-android*:cp $STAGING_DIR$PREFIX/native/bin/llvm-ranlib $STAGING_DIR$PREFIX/native/bin/$BUILDLIB_HOST-ranlib", - "*-android*:cp $STAGING_DIR$PREFIX/native/bin/llvm-ar $STAGING_DIR$PREFIX/native/bin/$BUILDLIB_HOST-ar", - "*-android*:mkdir -p $STAGING_DIR$PREFIX/usr/lib", - "aarch64-linux-android:cp $STAGING_DIR$PREFIX/native/sysroot/usr/lib/aarch64-linux-android/*.a $STAGING_DIR$PREFIX/usr/lib", - "x86_64-linux-android:cp $STAGING_DIR$PREFIX/native/sysroot/usr/lib/x86_64-linux-android/*.a $STAGING_DIR$PREFIX/usr/lib", - "armv7a-linux-androideabi:cp $STAGING_DIR$PREFIX/native/sysroot/usr/lib/arm-linux-androideabi/*.a $STAGING_DIR$PREFIX/usr/lib" + "darwin_*:*-android*:7zz x $PWD/android-ndk-r28c-darwin.zip -snld || true", + "linux_*:*-android*:7zz x $PWD/android-ndk-r28c-linux.zip -snld || true", + "*:*-android*:android-ndk-r28c/build/tools/make_standalone_toolchain.py --api $API_LEVEL --install-dir $PWD/toolchain --stl=libc++ $config_opts", + "*:*-android*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*-android*:mv $PWD/toolchain/* $STAGING_DIR$NATIVEPREFIX", + "*:*-android*:cp $STAGING_DIR$NATIVEPREFIX/bin/llvm-ar $STAGING_DIR$NATIVEPREFIX/bin/$BUILDLIB_HOST-ar", + "*:*-android*:cp $STAGING_DIR$NATIVEPREFIX/bin/$BUILDLIB_HOST$API_LEVEL-clang $STAGING_DIR$NATIVEPREFIX/bin/$BUILDLIB_HOST-clang", + "*:*-android*:cp $STAGING_DIR$NATIVEPREFIX/bin/$BUILDLIB_HOST$API_LEVEL-clang++ $STAGING_DIR$NATIVEPREFIX/bin/$BUILDLIB_HOST-clang++", + "*:*-android*:cp $STAGING_DIR$NATIVEPREFIX/bin/llvm-ranlib $STAGING_DIR$NATIVEPREFIX/bin/$BUILDLIB_HOST-ranlib", + "*:*-android*:cp $STAGING_DIR$NATIVEPREFIX/bin/llvm-ar $STAGING_DIR$NATIVEPREFIX/bin/$BUILDLIB_HOST-ar", + "*:*-android*:mkdir -p $STAGING_DIR$PREFIX/lib", + "*:aarch64-linux-android:cp $STAGING_DIR$NATIVEPREFIX/sysroot/usr/lib/aarch64-linux-android/*.a $STAGING_DIR$PREFIX/lib", + "*:x86_64-linux-android:cp $STAGING_DIR$NATIVEPREFIX/sysroot/usr/lib/x86_64-linux-android/*.a $STAGING_DIR$PREFIX/lib", + "*:armv7a-linux-androideabi:cp $STAGING_DIR$NATIVEPREFIX/sysroot/usr/lib/arm-linux-androideabi/*.a $STAGING_DIR$PREFIX/lib", + "*:aarch64-linux-android:cp $STAGING_DIR$NATIVEPREFIX/sysroot/usr/lib/aarch64-linux-android/$API_LEVEL/*.so $STAGING_DIR$PREFIX/lib", + "*:x86_64-linux-android:cp $STAGING_DIR$NATIVEPREFIX/sysroot/usr/lib/x86_64-linux-android/$API_LEVEL/*.so $STAGING_DIR$PREFIX/lib", + "*:armv7a-linux-androideabi:cp $STAGING_DIR$NATIVEPREFIX/sysroot/usr/lib/arm-linux-androideabi/$API_LEVEL/*.so $STAGING_DIR$PREFIX/lib", + "*:*-android:rm -rf $STAGING_DIR$NATIVEPREFIX/python3", + "*:*-android*:cd $STAGING_DIR$NATIVEPREFIX/bin && rm clang190++ && ln -s clang190 clang190++", + "*:*-android*:python3 $PATCH_DIR/android_ndk/symlink_same.py $STAGING_DIR$PREFIX" ] } } \ No newline at end of file diff --git a/packages/native/apple-sdk.json b/packages/native/apple-sdk.json new file mode 100644 index 0000000..6920e9e --- /dev/null +++ b/packages/native/apple-sdk.json @@ -0,0 +1,73 @@ +{ + "package": "native/apple-sdk", + "version": "master", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "ea17212e41970b9f602fb30898b5a4013a1fb7af", + "url": "https://github.com/MrCyjaneK/osxcross.git" + }, + { + "kind": "blob", + "path": "Xcode_26.1.xip", + "sha256": "434287e1e4c6ecbd6d5ea07e9f408fffcad2b82916b0a3fdfefa7fe60db4de93", + "url": "https://download.developer.apple.com/Developer_Tools/Xcode_26.1/XcodeXIP_26.1_Universal.xip" + } + ], + "dependencies": [ + "*:*-apple-*:native/_/_", + "*:*-apple-*:native/bash", + "*:*-apple-*:native/bzip2", + "*:*-apple-*:native/cctools-port", + "*:*-apple-*:native/cmake", + "*:*-apple-*:native/coreutils", + "*:*-apple-*:native/cpio", + "*:*-apple-*:native/gettext", + "*:*-apple-*:native/git", + "*:*-apple-*:native/libtapi", + "*:*-apple-*:native/libxml2", + "*:*-apple-*:native/make", + "*:*-apple-*:native/openssl", + "*:*-apple-*:native/patch", + "*:*-apple-*:native/pbzx", + "*:*-apple-*:native/perl", + "*:*-apple-*:native/pkgconf", + "*:*-apple-*:native/python@3.11", + "*:*-apple-*:native/xar", + "*:*-apple-*:native/xz", + "*:*:native/_/_" + ], + "build": { + "env": [ + "*:*-apple-*:SKIP_BUILD_XAR=yes", + "*:*-apple-*:SKIP_GIT=yes", + "*:*-apple-*:SKIP_BUILD_PBXZ=yes", + "*:*-apple-*:JOBS=$NUM_CORES", + "*:*-apple-*:PORTABLE=1", + "*:*-apple-*:TARGET_DIR=$NATIVEPREFIX/", + "*:aarch64-apple-*:ENABLE_ARCHS=arm64", + "*:x86_64-apple-*:ENABLE_ARCHS=x86_64", + "*:*-apple-*:UNATTENDED=1", + "*:*-apple-*:SDK_VERSION=26.1", + "*:*-apple-*:COMPRESSLEVEL=6", + "*:*-apple-darwin:SDKNAME=MacOSX", + "*:*-apple-ios:SDKNAME=iPhoneOS", + "*:*-apple-ios-simulator:SDKNAME=iPhoneSimulator", + "*:*-apple-watchos:SDKNAME=WatchOS", + "*:*-apple-watchos-simulator:SDKNAME=WatchSimulator", + "*:*-apple-tvos:SDKNAME=AppleTVOS", + "*:*-apple-tvos-simulator:SDKNAME=AppleTVSimulator", + "*:*-apple-xros:SDKNAME=XROS", + "*:*-apple-xros-simulator:SDKNAME=XRSimulator", + "*:*-apple-driverkit:SDKNAME=DriverKit" + ], + "steps": [ + "*:*-apple-*:sed -i.bak 's/$TARGET_DIR\\/bin\\///g' tools/gen_sdk_package_pbzx.sh", + "*:*-apple-*:sed -i.bak 's/$TARGET_DIR\\/SDK\\/tools\\/bin\\///g' tools/gen_sdk_package_pbzx.sh", + "*:*-apple-*:bash -x ./tools/gen_sdk_package_pbzx.sh ./Xcode_*.xip", + "*:*-apple-*:mkdir -p $STAGING_DIR$NATIVEPREFIX/share/xcode-sdk", + "*:*-apple-*:mv *.sdk.tar.xz $STAGING_DIR$NATIVEPREFIX/share/xcode-sdk" + ] + } +} \ No newline at end of file diff --git a/packages/native/autoconf.json b/packages/native/autoconf.json index 1ebd255..9821b43 100644 --- a/packages/native/autoconf.json +++ b/packages/native/autoconf.json @@ -2,22 +2,25 @@ "package": "native/autoconf", "version": "2.72", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "afb181a76e1ee72832f6581c0eddf8df032b83e2e0239ef79ebedc4467d92d6e", - "url": "http://ftpmirror.gnu.org/gnu/autoconf/autoconf-2.72.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "afb181a76e1ee72832f6581c0eddf8df032b83e2e0239ef79ebedc4467d92d6e", + "url": "http://ftpmirror.gnu.org/gnu/autoconf/autoconf-2.72.tar.gz" + } + ], "dependencies": [ - "all:native/m4", - "all:native/make", - "all:native/perl" + "*:*:native/_/_", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" ], "build": { "env": [], "steps": [ - "all:./configure --host=$HOST --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:./configure --host=$HOST --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/automake.json b/packages/native/automake.json index 13357c0..005e604 100644 --- a/packages/native/automake.json +++ b/packages/native/automake.json @@ -2,26 +2,29 @@ "package": "native/automake", "version": "1.18", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "af6043a5d4b3beef0c48161f4a6936259321cd101a34c1ab0768328515626c8a", - "url": "http://ftpmirror.gnu.org/gnu/automake/automake-1.18.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "af6043a5d4b3beef0c48161f4a6936259321cd101a34c1ab0768328515626c8a", + "url": "http://ftpmirror.gnu.org/gnu/automake/automake-1.18.tar.gz" + } + ], "dependencies": [ - "all:native/autoconf", - "all:native/m4", - "all:native/make", - "all:native/perl" + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" ], "build": { "env": [ - "all:MAKEINFO=true" + "*:*:MAKEINFO=true" ], "steps": [ - "all:./bootstrap", - "all:./configure --prefix=$PREFIX/native --disable-doc", - "all:make -j$NUM_CORES V=1", - "all:make install DESTDIR=$STAGING_DIR " + "*:*:./bootstrap", + "*:*:./configure --prefix=$NATIVEPREFIX --disable-doc", + "*:*:make -j$NUM_CORES V=1", + "*:*:make install DESTDIR=$STAGING_DIR " ] } } \ No newline at end of file diff --git a/packages/native/bash.json b/packages/native/bash.json index bfddd67..92cd1a7 100644 --- a/packages/native/bash.json +++ b/packages/native/bash.json @@ -2,20 +2,28 @@ "package": "native/bash", "version": "5.3", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "0d5cd86965f869a26cf64f4b71be7b96f90a3ba8b3d74e27e8e9d9d5550f31ba", - "url": "http://ftpmirror.gnu.org/bash/bash-5.3.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "0d5cd86965f869a26cf64f4b71be7b96f90a3ba8b3d74e27e8e9d9d5550f31ba", + "url": "https://ftp.gnu.org/gnu/bash/bash-5.3.tar.gz" + } + ], "dependencies": [ - "all:native/make" + "*:*:native/_/_", + "*:*:native/make" ], "build": { "env": [], "steps": [ - "all:./configure --prefix=$PREFIX/native", - "all:make -j$NUM_CORES V=1", - "all:make install DESTDIR=$STAGING_DIR" + "*:*:dash ./configure --prefix=$NATIVEPREFIX", + "darwin_arm64:*:make -j$NUM_CORES V=1", + "linux_*:*:make -j$NUM_CORES V=1", + "windows_amd64:*:make -j$NUM_CORES V=1 LDFLAGS=\"$LDFLAGS -Wl,--allow-multiple-definition\"", + "*:*:make install DESTDIR=$STAGING_DIR", + "darwin_arm64:*:ln -sf $NATIVEPREFIX/bin/bash $STAGING_DIR$NATIVEPREFIX/bin/sh", + "linux_*:*:ln -sf $NATIVEPREFIX/bin/bash $STAGING_DIR$NATIVEPREFIX/bin/sh", + "windows_amd64:*:test -f $STAGING_DIR$NATIVEPREFIX/bin/bash.exe && cp -f $STAGING_DIR$NATIVEPREFIX/bin/bash.exe $STAGING_DIR$NATIVEPREFIX/bin/sh.exe || true" ] } } \ No newline at end of file diff --git a/packages/native/binutils@2.42.json b/packages/native/binutils@2.42.json index 068d071..a6cbf01 100644 --- a/packages/native/binutils@2.42.json +++ b/packages/native/binutils@2.42.json @@ -2,55 +2,41 @@ "package": "native/binutils@2.42", "version": "2.42", "type": "native", - "download": { - "kind": "tar.bz2", - "sha256": "aa54850ebda5064c72cd4ec2d9b056c294252991486350d9a97ab2a6dfdfaf12", - "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.42.tar.bz2" - }, + "download": [ + { + "kind": "tar.bz2", + "sha256": "aa54850ebda5064c72cd4ec2d9b056c294252991486350d9a97ab2a6dfdfaf12", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.42.tar.bz2" + } + ], "dependencies": [ - "*-linux-gnu:native/bison", - "*-linux-gnu:native/libiconv", - "*-linux-gnu:native/make", - "*-linux-gnu:native/perl", - "*-linux-gnu:native/pkgconf", - "*-linux-gnu:native/texinfo", - "*-linux-gnu:native/zlib" + "*:*:native/_/_", + "*:*:native/bison", + "*:*:native/diffutils", + "*:*:native/grep", + "*:*:native/libiconv", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/pkgconf", + "*:*:native/texinfo", + "*:*:native/zlib" ], "build": { "env": [ - "x86_64-linux-gnu:TOOL_TARGET=x86_64-linux-gnu", - "*-linux-gnu:config_opts=--prefix=$PREFIX/native", - "*-linux-gnu:config_opts=$config_opts --disable-nls", - "*-linux-gnu:config_opts=$config_opts --disable-werror", - "*-linux-gnu:config_opts=$config_opts --with-system-zlib", - "*-linux-gnu:config_opts=$config_opts --enable-targets=$TOOL_TARGET", - "*-linux-gnu:config_opts=$config_opts --target=$TOOL_TARGET", - "*-linux-gnu:config_opts=$config_opts --libdir=$PREFIX/native/lib/$TOOL_TARGET", - "*-linux-gnu:config_opts=$config_opts --infodir=$PREFIX/native/share/info/$TOOL_TARGET", - "*-linux-gnu:CPPFLAGS=-I$PREFIX/native/include", - "*-linux-gnu:LDFLAGS=-L$PREFIX/native/lib" + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-nls", + "*:*:config_opts=$config_opts --disable-werror", + "*:*:config_opts=$config_opts --with-system-zlib", + "*:*:config_opts=$config_opts --enable-targets=all", + "*:*:config_opts=$config_opts --disable-gprofng", + "*:*:config_opts=$config_opts --libdir=$NATIVEPREFIX/lib", + "*:*:config_opts=$config_opts --infodir=$NATIVEPREFIX/share/info" ], "steps": [ - "*-linux-gnu:mkdir -p build", - "*-linux-gnu:cd build && ../configure $config_opts", - "*-linux-gnu:cd build && make -j$NUM_CORES", - "*-linux-gnu:cd build && make install DESTDIR=$STAGING_DIR", - "*-linux-gnu:ln -s $TOOL_TARGET-gprof $STAGING_DIR$PREFIX/native/bin/gprof", - "*-linux-gnu:ln -s $TOOL_TARGET-ranlib $STAGING_DIR$PREFIX/native/bin/ranlib", - "*-linux-gnu:ln -s $TOOL_TARGET-addr2line $STAGING_DIR$PREFIX/native/bin/addr2line", - "*-linux-gnu:ln -s $TOOL_TARGET-ld $STAGING_DIR$PREFIX/native/bin/ld", - "*-linux-gnu:ln -s $TOOL_TARGET-readelf $STAGING_DIR$PREFIX/native/bin/readelf", - "*-linux-gnu:ln -s $TOOL_TARGET-ar $STAGING_DIR$PREFIX/native/bin/ar", - "*-linux-gnu:ln -s $TOOL_TARGET-ld.bfd $STAGING_DIR$PREFIX/native/bin/ld.bfd", - "*-linux-gnu:ln -s $TOOL_TARGET-size $STAGING_DIR$PREFIX/native/bin/size", - "*-linux-gnu:ln -s $TOOL_TARGET-as $STAGING_DIR$PREFIX/native/bin/as", - "*-linux-gnu:ln -s $TOOL_TARGET-nm $STAGING_DIR$PREFIX/native/bin/nm", - "*-linux-gnu:ln -s $TOOL_TARGET-strings $STAGING_DIR$PREFIX/native/bin/strings", - "*-linux-gnu:ln -s $TOOL_TARGET-c++filt $STAGING_DIR$PREFIX/native/bin/c++filt", - "*-linux-gnu:ln -s $TOOL_TARGET-objcopy $STAGING_DIR$PREFIX/native/bin/objcopy", - "*-linux-gnu:ln -s $TOOL_TARGET-strip $STAGING_DIR$PREFIX/native/bin/strip", - "*-linux-gnu:ln -s $TOOL_TARGET-elfedit $STAGING_DIR$PREFIX/native/bin/elfedit", - "*-linux-gnu:ln -s $TOOL_TARGET-objdump $STAGING_DIR$PREFIX/native/bin/objdump" + "*:*:mkdir -p build", + "*:*:cd build && ../configure $config_opts", + "*:*:cd build && make -j$NUM_CORES", + "*:*:cd build && make install DESTDIR=$STAGING_DIR" ] } } \ No newline at end of file diff --git a/packages/native/binutils@2.46.0.json b/packages/native/binutils@2.46.0.json new file mode 100644 index 0000000..e3fbf1e --- /dev/null +++ b/packages/native/binutils@2.46.0.json @@ -0,0 +1,43 @@ +{ + "package": "native/binutils@2.46.0", + "version": "2.46.0", + "type": "native", + "download": [ + { + "kind": "tar.bz2", + "sha256": "0f3152632a2a9ce066f20963e9bb40af7cf85b9b6c409ed892fd0676e84ecd12", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.46.0.tar.bz2" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bison", + "*:*:native/diffutils", + "*:*:native/grep", + "*:*:native/libiconv", + "*:*:native/libtool", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/pkgconf", + "*:*:native/texinfo", + "*:*:native/zlib" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-nls", + "*:*:config_opts=$config_opts --disable-werror", + "*:*:config_opts=$config_opts --with-system-zlib", + "*:*:config_opts=$config_opts --enable-targets=all", + "*:*:config_opts=$config_opts --disable-gprofng", + "*:*:config_opts=$config_opts --libdir=$NATIVEPREFIX/lib", + "*:*:config_opts=$config_opts --infodir=$NATIVEPREFIX/share/info" + ], + "steps": [ + "*:*:mkdir -p build", + "*:*:cd build && ../configure $config_opts", + "*:*:cd build && make -j$NUM_CORES", + "*:*:cd build && make install DESTDIR=$STAGING_DIR" + ] + } +} \ No newline at end of file diff --git a/packages/native/bison.json b/packages/native/bison.json index c68ef68..7474a85 100644 --- a/packages/native/bison.json +++ b/packages/native/bison.json @@ -2,25 +2,29 @@ "package": "native/bison", "version": "3.8", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "d5d184d421aee15603939973a6b0f372f908edfb24c5bc740697497021ad9458", - "url": "http://ftpmirror.gnu.org/gnu/bison/bison-3.8.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "d5d184d421aee15603939973a6b0f372f908edfb24c5bc740697497021ad9458", + "url": "http://ftpmirror.gnu.org/gnu/bison/bison-3.8.tar.gz" + } + ], "dependencies": [ - "all:native/m4", - "all:native/make", - "all:native/texinfo" + "*:*:native/_/_", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/texinfo" ], "build": { "env": [ - "all:AUTOMAKE=true", - "all:ACLOCAL=true" + "*:*:AUTOMAKE=true", + "*:*:ACLOCAL=true" ], "steps": [ - "all:./configure --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:./configure --prefix=$NATIVEPREFIX gl_cv_have_weak=no", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/boost-b2.json b/packages/native/boost-b2.json deleted file mode 100644 index a754134..0000000 --- a/packages/native/boost-b2.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "package": "native/boost-b2", - "version": "1_85_0", - "type": "native", - "download": { - "kind": "tar.bz2", - "sha256": "7009fe1faa1697476bdc7027703a2badb84e849b7b0baad5086b087b971f8617", - "url": "http://downloads.sourceforge.net/project/boost/boost/1.85.0/boost_1_85_0.tar.bz2" - }, - "build": { - "steps": [ - "all:./bootstrap.sh", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp b2 $STAGING_DIR$PREFIX/native/bin/" - ] - } -} \ No newline at end of file diff --git a/packages/native/boost-b2@1_83_0.json b/packages/native/boost-b2@1_83_0.json new file mode 100644 index 0000000..cc38317 --- /dev/null +++ b/packages/native/boost-b2@1_83_0.json @@ -0,0 +1,27 @@ +{ + "package": "native/boost-b2@1_83_0", + "version": "1_83_0", + "type": "native", + "download": [ + { + "kind": "tar.bz2", + "sha256": "6478edfe2f3305127cffe8caf73ea0176c53769f4bf1585be237eb30798c3b8e", + "url": "http://downloads.sourceforge.net/project/boost/boost/1.83.0/boost_1_83_0.tar.bz2" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash" + ], + "build": { + "env": [ + "*:*:config_libraries=system,filesystem,thread,timer,date_time,chrono,regex,serialization,atomic,program_options,log", + "*:*-w64-*:config_libraries=system,filesystem,thread,timer,date_time,chrono,regex,serialization,atomic,program_options,locale,log" + ], + "steps": [ + "*:*:./tools/build/src/engine/build.sh --cxx=$CXX --cxxflags=\"$CXXFLAGS $LDFLAGS\"", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp tools/build/src/engine/b2 $STAGING_DIR$NATIVEPREFIX/bin/" + ] + } +} \ No newline at end of file diff --git a/packages/native/boost-b2@1_90_0.json b/packages/native/boost-b2@1_90_0.json new file mode 100644 index 0000000..2f65908 --- /dev/null +++ b/packages/native/boost-b2@1_90_0.json @@ -0,0 +1,27 @@ +{ + "package": "native/boost-b2@1_90_0", + "version": "1_90_0", + "type": "native", + "download": [ + { + "kind": "tar.bz2", + "sha256": "49551aff3b22cbc5c5a9ed3dbc92f0e23ea50a0f7325b0d198b705e8ee3fc305", + "url": "http://downloads.sourceforge.net/project/boost/boost/1.90.0/boost_1_90_0.tar.bz2" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash" + ], + "build": { + "env": [ + "*:*:config_libraries=system,filesystem,thread,timer,date_time,chrono,regex,serialization,atomic,program_options,log", + "*:*-w64-*:config_libraries=$config_libraries,locale" + ], + "steps": [ + "*:*:./tools/build/src/engine/build.sh --cxx=$CXX --cxxflags=\"$CXXFLAGS $LDFLAGS\"", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp tools/build/src/engine/b2 $STAGING_DIR$NATIVEPREFIX/bin/" + ] + } +} \ No newline at end of file diff --git a/packages/native/bootstrap/cpan/archive-cpio.json b/packages/native/bootstrap/cpan/archive-cpio.json deleted file mode 100644 index d1304c3..0000000 --- a/packages/native/bootstrap/cpan/archive-cpio.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "package": "native/bootstrap/cpan/archive-cpio", - "version": "0.10", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "246fb31669764e78336b2191134122e07c44f2d82dc4f37d552ab28f8668bed3", - "url": "https://cpan.metacpan.org/authors/id/P/PI/PIXEL/Archive-Cpio-0.10.tar.gz" - }, - "dependencies": [ - "all:native/bootstrap/make", - "all:native/bootstrap/perl" - ], - "build": { - "env": [ - "all:PATH=$PREFIX/native/bootstrap/bin:$PATH" - ], - "steps": [ - "all:$PREFIX/native/bootstrap/bin/perl Makefile.PL PREFIX=$PREFIX/native/bootstrap", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" - ] - } -} \ No newline at end of file diff --git a/packages/native/bootstrap/cpan/archive-zip.json b/packages/native/bootstrap/cpan/archive-zip.json deleted file mode 100644 index be9686e..0000000 --- a/packages/native/bootstrap/cpan/archive-zip.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "package": "native/bootstrap/cpan/archive-zip", - "version": "1.68", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "984e185d785baf6129c6e75f8eb44411745ac00bf6122fb1c8e822a3861ec650", - "url": "https://cpan.metacpan.org/authors/id/P/PH/PHRED/Archive-Zip-1.68.tar.gz" - }, - "dependencies": [ - "all:native/bootstrap/make", - "all:native/bootstrap/perl" - ], - "build": { - "env": [ - "all:PATH=$PREFIX/native/bootstrap/bin:$PATH" - ], - "steps": [ - "all:$PREFIX/native/bootstrap/bin/perl Makefile.PL PREFIX=$PREFIX/native/bootstrap", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" - ] - } -} \ No newline at end of file diff --git a/packages/native/bootstrap/cpan/sub-override.json b/packages/native/bootstrap/cpan/sub-override.json deleted file mode 100644 index 2a2dfc9..0000000 --- a/packages/native/bootstrap/cpan/sub-override.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "package": "native/bootstrap/cpan/sub-override", - "version": "0.09", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "939a67c1f729968e0cc81b74958db750e1bdb7c020bee1a263332f422c2e25b5", - "url": "https://cpan.metacpan.org/authors/id/O/OV/OVID/Sub-Override-0.09.tar.gz" - }, - "dependencies": [ - "all:native/bootstrap/make", - "all:native/bootstrap/perl" - ], - "build": { - "env": [ - "all:PATH=$PREFIX/native/bootstrap/bin:$PATH" - ], - "steps": [ - "all:$PREFIX/native/bootstrap/bin/perl Makefile.PL PREFIX=$PREFIX/native/bootstrap", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" - ] - } -} \ No newline at end of file diff --git a/packages/native/bootstrap/make.json b/packages/native/bootstrap/make.json deleted file mode 100644 index 442f2fd..0000000 --- a/packages/native/bootstrap/make.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "package": "native/bootstrap/make", - "version": "4.4", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "581f4d4e872da74b3941c874215898a7d35802f03732bdccee1d4a7979105d18", - "url": "http://ftpmirror.gnu.org/gnu/make/make-4.4.tar.gz" - }, - "build": { - "steps": [ - "all:./configure --disable-dependency-tracking", - "all:./build.sh", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bootstrap/bin", - "all:cp make $STAGING_DIR/$PREFIX/native/bootstrap/bin/make" - ] - } -} \ No newline at end of file diff --git a/packages/native/bootstrap/perl.json b/packages/native/bootstrap/perl.json deleted file mode 100644 index 5f545fa..0000000 --- a/packages/native/bootstrap/perl.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "package": "native/bootstrap/perl", - "version": "5.42.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "e093ef184d7f9a1b9797e2465296f55510adb6dab8842b0c3ed53329663096dc", - "url": "http://www.cpan.org/src/5.0/perl-5.42.0.tar.gz" - }, - "dependencies": [ - "all:native/bootstrap/make" - ], - "build": { - "env": [ - "all:PATH=$PREFIX/native/bootstrap/bin:$PATH" - ], - "steps": [ - "all:sed -i.bak '/^#ifndef PERL_BUILD_DATE$/,/^#endif$/{/^#ifndef PERL_BUILD_DATE$/!d; s/.*/\\#define PERL_BUILD_DATE \"Jan 1 1970 00:00:01\"/;}' perl.c", - "all:./Configure -des -Dprefix=$PREFIX/native/bootstrap -Duseithreads -Dall_static", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" - ] - } -} \ No newline at end of file diff --git a/packages/native/bootstrap/strip-nondeterminism.json b/packages/native/bootstrap/strip-nondeterminism.json deleted file mode 100644 index 4499093..0000000 --- a/packages/native/bootstrap/strip-nondeterminism.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "package": "native/bootstrap/strip-nondeterminism", - "version": "1.13.0", - "type": "native", - "download": { - "kind": "tar.bz2", - "sha256": "a70cdad5d728ea78b75d09880c4b51c7d887e89d0b610149b10cfb2abc70b4fc", - "url": "https://salsa.debian.org/reproducible-builds/reproducible-lfs/-/raw/master/releases/strip-nondeterminism/strip-nondeterminism_1.13.0.tar.bz2" - }, - "dependencies": [ - "all:native/bootstrap/cpan/archive-cpio", - "all:native/bootstrap/cpan/archive-zip", - "all:native/bootstrap/cpan/sub-override", - "all:native/bootstrap/make", - "all:native/bootstrap/perl" - ], - "build": { - "env": [ - "all:PATH=$PREFIX/native/bootstrap/bin:$PATH" - ], - "steps": [ - "all:$PREFIX/native/bootstrap/bin/perl Makefile.PL PREFIX=$PREFIX/native/bootstrap", - "all:make", - "all:make DESTDIR=$STAGING_DIR install", - "all:mkdir -p $STAGING_DIR/$PREFIX/native/bootstrap/bin/", - "all:cp $PATCH_DIR/strip-nondeterminism-recursive $STAGING_DIR/$PREFIX/native/bootstrap/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/bzip2.json b/packages/native/bzip2.json new file mode 100644 index 0000000..4a26d81 --- /dev/null +++ b/packages/native/bzip2.json @@ -0,0 +1,27 @@ +{ + "package": "native/bzip2", + "version": "1.0.8", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269", + "url": "https://sourceware.org/pub/bzip2/bzip2-1.0.8.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/diffutils", + "*:*:native/make", + "*:*:native/openssl", + "*:*:native/sed" + ], + "build": { + "env": [], + "steps": [ + "*:*:sed -i.bak 's/-Wall/-Wall -fPIC/' Makefile", + "*:*:make -j$NUM_CORES CC=\"$CC\"", + "*:*:make install PREFIX=$STAGING_DIR$NATIVEPREFIX" + ] + } +} \ No newline at end of file diff --git a/packages/native/cctools-port.json b/packages/native/cctools-port.json new file mode 100644 index 0000000..e88ca32 --- /dev/null +++ b/packages/native/cctools-port.json @@ -0,0 +1,41 @@ +{ + "package": "native/cctools-port", + "version": "986-ld64-711", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "6e31355ca5babc708681bd906eaaef86c3ac93be", + "url": "https://github.com/tpoechtrager/cctools-port.git" + } + ], + "dependencies": [ + "*:*-apple-*:native/bzip2", + "*:*-apple-*:native/libtapi", + "*:*-apple-*:native/make", + "*:*-apple-*:native/openssl", + "*:*-apple-*:native/xar", + "*:*-apple-*:native/xz", + "*:*-apple-*:native/zlib", + "*:*:native/_/_", + "linux_*:*-apple-*:native/libc++" + ], + "build": { + "env": [ + "*:*-apple-*:config_opts=--prefix=$NATIVEPREFIX", + "*:*-apple-*:config_opts=$config_opts --with-libtapi=$NATIVEPREFIX", + "*:*-apple-*:config_opts=$config_opts --with-libxar=$NATIVEPREFIX", + "*:*-apple-*:CC=clang", + "*:*-apple-*:CXX=clang++", + "linux_*:*-apple-*:CXXFLAGS=$CXXFLAGS -stdlib=libc++ -I$NATIVEPREFIX/include/c++/v1", + "linux_*:*-apple-*:LIBS=-L$NATIVEPREFIX/lib -lc++abi" + ], + "steps": [ + "*:*-apple-*:sed -i.bak '3182d' cctools/configure", + "*:*-apple-*:cd cctools && ./configure $config_opts", + "*:*-apple-*:cd cctools && make -j$NUM_CORES", + "*:*-apple-*:cd cctools && DESTDIR=$STAGING_DIR make -j$NUM_CORES install", + "*:*-apple-*:cd $STAGING_DIR$NATIVEPREFIX/bin; for f in *-*; do ln -s \"$f\" \"${f##*-}\"; done" + ] + } +} \ No newline at end of file diff --git a/packages/native/cmake-toolchain.json b/packages/native/cmake-toolchain.json index 4350ed2..a5b20c1 100644 --- a/packages/native/cmake-toolchain.json +++ b/packages/native/cmake-toolchain.json @@ -2,16 +2,24 @@ "package": "native/cmake-toolchain", "version": "0.0.0", "type": "native", - "download": { - "kind": "git", - "sha256": "c4e7b0e5f437121d1b9c05bc5c43dac75371d799", - "url": "https://github.com/MrCyjaneK/cmake-toolchain.git" - }, + "download": [ + { + "kind": "git", + "sha256": "c4e7b0e5f437121d1b9c05bc5c43dac75371d799", + "url": "https://github.com/MrCyjaneK/cmake-toolchain.git" + } + ], + "dependencies": [ + "*:*:native/_/_" + ], + "export-env": [ + "*:*:CMAKE_TOOLCHAIN_FILE=$NATIVEPREFIX/toolchain.cmake" + ], "build": { "env": [], "steps": [ - "all:mkdir -p $STAGING_DIR$PREFIX/native/", - "all:cp toolchain.cmake $STAGING_DIR$PREFIX/native/toolchain.cmake" + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp toolchain.cmake $STAGING_DIR$NATIVEPREFIX/toolchain.cmake" ] } } \ No newline at end of file diff --git a/packages/native/cmake.json b/packages/native/cmake.json index 22f0f16..1167fa8 100644 --- a/packages/native/cmake.json +++ b/packages/native/cmake.json @@ -2,24 +2,28 @@ "package": "native/cmake", "version": "4.0.3", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "8d3537b7b7732660ea247398f166be892fe6131d63cc291944b45b91279f3ffb", - "url": "http://github.com/Kitware/CMake/releases/download/v4.0.3/cmake-4.0.3.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "8d3537b7b7732660ea247398f166be892fe6131d63cc291944b45b91279f3ffb", + "url": "http://github.com/Kitware/CMake/releases/download/v4.0.3/cmake-4.0.3.tar.gz" + } + ], "dependencies": [ - "all:native/make", - "all:native/openssl" + "*:*:native/_/_", + "*:*:native/make", + "*:*:native/openssl", + "*:*:native/zlib" ], "build": { "env": [ - "all:OPENSSL_ROOT_DIR=$PREFIX/native" + "*:*:OPENSSL_ROOT_DIR=$NATIVEPREFIX", + "*:*:ZLIB_ROOT=$NATIVEPREFIX" ], "steps": [ - "all:./bootstrap --parallel=$NUM_CORES", - "all:./configure --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:./bootstrap --prefix=$NATIVEPREFIX --parallel=$NUM_CORES --no-system-curl -- -DZLIB_ROOT=$NATIVEPREFIX -DOPENSSL_ROOT_DIR=$NATIVEPREFIX -DCMAKE_USE_OPENSSL=ON -DUSE_LIBIDN2:BOOL=OFF -DCMAKE_DISABLE_FIND_PACKAGE_Libidn2=TRUE", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/config.json b/packages/native/config.json index f64d490..567e982 100644 --- a/packages/native/config.json +++ b/packages/native/config.json @@ -2,17 +2,22 @@ "package": "native/config", "version": "2025-07-10", "type": "native", - "download": { - "kind": "git", - "sha256": "a2287c3041a3f2a204eb942e09c015eab00dc7dd", - "url": "https://https.git.savannah.gnu.org/git/config.git" - }, + "download": [ + { + "kind": "git", + "sha256": "a2287c3041a3f2a204eb942e09c015eab00dc7dd", + "url": "https://https.git.savannah.gnu.org/git/config.git" + } + ], + "dependencies": [ + "*:*:native/_/_" + ], "build": { "env": [], "steps": [ - "all:mkdir -p $STAGING_DIR$PREFIX/native/usr/share/config", - "all:cp config.guess $STAGING_DIR$PREFIX/native/usr/share/config/config.guess", - "all:cp config.sub $STAGING_DIR$PREFIX/native/usr/share/config/config.sub" + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/share/config", + "*:*:cp config.guess $STAGING_DIR$NATIVEPREFIX/share/config/config.guess", + "*:*:cp config.sub $STAGING_DIR$NATIVEPREFIX/share/config/config.sub" ] } } \ No newline at end of file diff --git a/packages/native/coreutils.json b/packages/native/coreutils.json new file mode 100644 index 0000000..94006bd --- /dev/null +++ b/packages/native/coreutils.json @@ -0,0 +1,30 @@ +{ + "package": "native/coreutils", + "version": "9.9", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "19bcb6ca867183c57d77155eae946c5eced88183143b45ca51ad7d26c628ca75", + "url": "https://ftpmirror.gnu.org/gnu/coreutils/coreutils-9.9.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make" + ], + "patches": [ + "clang-pthread-once-atomic.patch" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:DESTDIR=$STAGING_DIR make install" + ] + } +} \ No newline at end of file diff --git a/packages/native/cpio.json b/packages/native/cpio.json new file mode 100644 index 0000000..db593c4 --- /dev/null +++ b/packages/native/cpio.json @@ -0,0 +1,24 @@ +{ + "package": "native/cpio", + "version": "2.15", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "efa50ef983137eefc0a02fdb51509d624b5e3295c980aa127ceee4183455499e", + "url": "http://ftpmirror.gnu.org/cpio/cpio-2.15.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/make" + ], + "build": { + "env": [], + "steps": [ + "*:*:./configure --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/crosstool-ng.json b/packages/native/crosstool-ng.json index 3a6ec25..d6a57e8 100644 --- a/packages/native/crosstool-ng.json +++ b/packages/native/crosstool-ng.json @@ -1,29 +1,60 @@ { "package": "native/crosstool-ng", - "version": "1.27.0", + "version": "1.28.0-dirty", "type": "native", - "download": { - "kind": "tar.xz", - "sha256": "0506ab98fa0ad6d263a555feeb2c7fff9bc24a434635d4b0cdff9137fe5b4477", - "url": "http://crosstool-ng.org/download/crosstool-ng/crosstool-ng-1.27.0.tar.xz" - }, + "download": [ + { + "kind": "git", + "sha256": "620b909cd0713f68084378b63cf61b5232757b90", + "url": "https://github.com/crosstool-ng/crosstool-ng" + } + ], "dependencies": [ - "*-linux-gnu:native/autoconf", - "*-linux-gnu:native/bash", - "*-linux-gnu:native/binutils@2.42", - "*-linux-gnu:native/make", - "*-linux-gnu:native/make", - "*-linux-gnu:native/sed" + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/binutils@2.46.0", + "*:*:native/bison", + "*:*:native/bzip2", + "*:*:native/file", + "*:*:native/flex", + "*:*:native/gawk", + "*:*:native/gettext", + "*:*:native/grep", + "*:*:native/help2man", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/ncurses", + "*:*:native/patch", + "*:*:native/perl", + "*:*:native/python@3.11", + "*:*:native/rsync", + "*:*:native/sed", + "*:*:native/texinfo", + "*:*:native/unzip", + "*:*:native/xz", + "*:*:native/zlib" ], "build": { "env": [ - "x86_64-linux-gnu:TOOL_TARGET=x86_64-linux-gnu" + "*:x86_64-linux-gnu:TOOL_TARGET=x86_64-linux-gnu", + "*:x86_64-w64-mingw32:TOOL_TARGET=x86_64-w64-mingw32", + "*:aarch64-linux-gnu:TOOL_TARGET=aarch64-linux-gnu", + "*:x86_64-linux-musl:TOOL_TARGET=x86_64-linux-musl" ], "steps": [ - "*-linux-gnu:./bootstrap", - "*-linux-gnu:./configure --prefix=$PREFIX/native", - "*-linux-gnu:make -j$NUM_CORES", - "*-linux-gnu:make install DESTDIR=$STAGING_DIR" + "*:*:test -e $NATIVEPREFIX/bin/makeinfo || cp -f $NATIVEPREFIX/bin/texi2any $NATIVEPREFIX/bin/makeinfo", + "*:*:test -e $NATIVEPREFIX/bin/which || printf '%s\\n' '#!/bin/sh' 'command -v \"$1\"' >$NATIVEPREFIX/bin/which && chmod +x $NATIVEPREFIX/bin/which", + "*:*:./bootstrap", + "*:*:./configure --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make install DESTDIR=$STAGING_DIR", + "*:*:rm -f $STAGING_DIR$NATIVEPREFIX/share/crosstool-ng/LICENSE && cp -f $STAGING_DIR$NATIVEPREFIX/share/crosstool-ng/COPYING $STAGING_DIR$NATIVEPREFIX/share/crosstool-ng/LICENSE", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:printf '%s\\n' '#!/bin/sh' 'command -v \"$1\"' >$STAGING_DIR$NATIVEPREFIX/bin/which && chmod +x $STAGING_DIR$NATIVEPREFIX/bin/which", + "*:*:test -e $STAGING_DIR$NATIVEPREFIX/bin/makeinfo || cp -f $STAGING_DIR$NATIVEPREFIX/bin/texi2any $STAGING_DIR$NATIVEPREFIX/bin/makeinfo 2>/dev/null || true" ] } } \ No newline at end of file diff --git a/packages/native/ct-tools.json b/packages/native/ct-tools.json new file mode 100644 index 0000000..591dd95 --- /dev/null +++ b/packages/native/ct-tools.json @@ -0,0 +1,216 @@ +{ + "package": "native/ct-tools", + "version": "1.0.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "50eb4f2cbf22872af991c1db5d11f32b6a398d6b", + "url": "https://github.com/MrCyjaneK/ct-ng-configs.git" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/binutils-2.45.tar.xz", + "sha256": "c50c0e7f9cb188980e2cc97e4537626b1672441815587f1eab69d2a1bfbef5d2", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.45.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/VERSION_2_5_21.tar.gz", + "sha256": "470aa72e7018f0beadb5fbe3c932a62ba1b0594c29158a744c614bfa42133e59", + "url": "https://github.com/johnsonjh/duma/archive/refs/tags/VERSION_2_5_21.tar.gz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/expat-2.7.1.tar.xz", + "sha256": "354552544b8f99012e5062f7d570ec77f14b412a3ff5c7d8d0dae62c0d217c30", + "url": "http://github.com/libexpat/libexpat/releases/download/R_2_7_1/expat-2.7.1.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/gcc-15.2.0.tar.xz", + "sha256": "438fd996826b0c82485a29da03a72d71d6e3541a83ec702df4271f6fe025d24e", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-15.2.0/gcc-15.2.0.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/gcc-13.4.0.tar.xz", + "sha256": "9c4ce6dbb040568fdc545588ac03c5cbc95a8dbf0c7aa490170843afb59ca8f5", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-13.4.0/gcc-13.4.0.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/gdb-16.3.tar.xz", + "sha256": "bcfcd095528a987917acf9fff3f1672181694926cc18d609c99d0042c00224c5", + "url": "http://ftpmirror.gnu.org/gnu/gdb/gdb-16.3.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/gettext-0.26.tar.xz", + "sha256": "d1fb86e260cfe7da6031f94d2e44c0da55903dbae0a2fa0fae78c91ae1b56f00", + "url": "http://ftpmirror.gnu.org/gnu/gettext/gettext-0.26.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/glibc-2.41.tar.xz", + "sha256": "a5a26b22f545d6b7d7b3dd828e11e428f24f4fac43c934fb071b6a7d0828e901", + "url": "http://ftpmirror.gnu.org/gnu/glibc/glibc-2.41.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/gmp-6.3.0.tar.xz", + "sha256": "a3c2b80201b89e68616f4ad30bc66aee4927c3ce50e33929ca819d5c43538898", + "url": "http://ftpmirror.gnu.org/gnu/gmp/gmp-6.3.0.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/isl-0.27.tar.xz", + "sha256": "6d8babb59e7b672e8cb7870e874f3f7b813b6e00e6af3f8b04f7579965643d5c", + "url": "https://libisl.sourceforge.io/isl-0.27.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/libiconv-1.18.tar.gz", + "sha256": "3b08f5f4f9b4eb82f151a7040bfd6fe6c6fb922efe4b1659c66ea933276965e8", + "url": "https://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.18.tar.gz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/linux-4.20.17.tar.xz", + "sha256": "d011245629b980d4c15febf080b54804aaf215167b514a3577feddb2495f8a3e", + "url": "https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.20.17.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/mingw-w64-v13.0.0.tar.bz2", + "sha256": "5afe822af5c4edbf67daaf45eec61d538f49eef6b19524de64897c6b95828caf", + "url": "https://downloads.sourceforge.net/project/mingw-w64/mingw-w64/mingw-w64-release/mingw-w64-v13.0.0.tar.bz2" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/musl-1.2.5.tar.gz", + "sha256": "a9a118bbe84d8764da0ea0d28b3ab3fae8477fc7e4085d90102b8596fc7c75e4", + "url": "https://sources.voidlinux.org/musl-1.2.5/musl-1.2.5.tar.gz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/mpc-1.3.1.tar.gz", + "sha256": "ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8", + "url": "http://ftpmirror.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/mpfr-4.2.2.tar.xz", + "sha256": "b67ba0383ef7e8a8563734e2e889ef5ec3c3b898a01d00fa0a6869ad81c6ce01", + "url": "http://ftpmirror.gnu.org/gnu/mpfr/mpfr-4.2.2.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/ncurses-6.5.tar.gz", + "sha256": "136d91bc269a9a5785e5f9e980bc76ab57428f604ce3e5a5a90cebc767971cc6", + "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.5.tar.gz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/zlib-1.3.1.tar.xz", + "sha256": "38ef96b8dfe510d42707d9c781877914792541133e1870841463bfa73f883e32", + "url": "https://github.com/madler/zlib/releases/download/v1.3.1/zlib-1.3.1.tar.xz" + }, + { + "kind": "blob", + "path": "work/.build/tarballs/zstd-1.5.7.tar.gz", + "sha256": "eb33e51f49a15e023950cd7825ca74a4a2b43db8354825ac24fc1b7ee09e6fa3", + "url": "https://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/autoconf", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/automake", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/bash", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/binutils@2.46.0", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/bison", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/bzip2", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/coreutils", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/crosstool-ng", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/file", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/findutils", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/flex", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/gawk", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/gettext", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/gzip", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/gmp_shared", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/tar", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/grep", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/help2man", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/libtool", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/llvm-objcopy", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/m4", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/make", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/patch", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/perl", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/python@3.11", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/rsync", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/sed", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/texinfo", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/xz", + "*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:native/zlib" + ], + "patches": [ + "clang-widl-winnt.h.patch" + ], + "build": { + "env": [ + "*:x86_64-linux-gnu:TOOL_TARGET=x86_64-linux-gnu", + "*:aarch64-linux-gnu:TOOL_TARGET=aarch64-linux-gnu", + "*:x86_64-linux-musl:TOOL_TARGET=x86_64-linux-musl", + "*:x86_64-w64-mingw32:TOOL_TARGET=x86_64-w64-mingw32" + ], + "steps": [ + "linux_*:*:ln -sf $NATIVEPREFIX/_/bin/clang $NATIVEPREFIX/_/bin/gcc", + "linux_*:*:ln -sf $NATIVEPREFIX/_/bin/clang++ $NATIVEPREFIX/_/bin/g++", + "windows_*:*:ln -sf $NATIVEPREFIX/_/bin/clang $NATIVEPREFIX/_/bin/gcc", + "windows_*:*:ln -sf $NATIVEPREFIX/_/bin/clang++ $NATIVEPREFIX/_/bin/g++", + "windows_*:*:test -e $NATIVEPREFIX/bin/which || printf '%s\\n' '#!/bin/sh' 'command -v \"$1\"' >$NATIVEPREFIX/bin/which && chmod +x $NATIVEPREFIX/bin/which", + "windows_*:*:test -e $NATIVEPREFIX/bin/makeinfo || cp -f $NATIVEPREFIX/bin/texi2any $NATIVEPREFIX/bin/makeinfo", + "windows_*:*:test -e $NATIVEPREFIX/share/crosstool-ng/LICENSE || cp -f $NATIVEPREFIX/share/crosstool-ng/COPYING $NATIVEPREFIX/share/crosstool-ng/LICENSE", + "windows_*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:sed -i.bak '/put_new_config CT_CC_LANG_CXX y/a\\ put_new_config CT_BINUTILS_PLUGINS n\\n put_new_config CT_CC_GCC_ENABLE_PLUGINS n\\n put_new_config CT_MINGW_TOOLS n' run.sh", + "darwin_*:*:mv $NATIVEPREFIX/_/bin/lld $NATIVEPREFIX/_/bin/lld-real", + "darwin_*:*:rm -f $NATIVEPREFIX/_/bin/ld $NATIVEPREFIX/_/bin/ld64.lld $NATIVEPREFIX/_/bin/ld.lld", + "darwin_*:*:sed \"s|@LD64_LLD@|$NATIVEPREFIX/_/bin/lld-real|g; s|@SDK_VERSION@|26.1|g\" $PATCH_DIR/native/ct-tools/host-ld-wrapper.sh > $NATIVEPREFIX/_/bin/ld && chmod +x $NATIVEPREFIX/_/bin/ld", + "darwin_*:*:ln -sf $NATIVEPREFIX/_/bin/ld $NATIVEPREFIX/_/bin/ld64.lld", + "darwin_*:*:ln -sf $NATIVEPREFIX/_/bin/lld-real $NATIVEPREFIX/_/bin/ld.lld", + "darwin_*:*:ln -sf $NATIVEPREFIX/_/bin/clang-21 $NATIVEPREFIX/_/bin/gcc", + "darwin_*:*:ln -sf $NATIVEPREFIX/_/bin/clang++-21 $NATIVEPREFIX/_/bin/g++", + "darwin_*:*:ln -sf $NATIVEPREFIX/_/bin/llvm-ar $NATIVEPREFIX/_/bin/ar", + "darwin_*:*:ln -sf $NATIVEPREFIX/_/bin/llvm-as $NATIVEPREFIX/_/bin/as", + "darwin_*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:sed -i.bak '/put_new_config CT_CC_LANG_CXX y/a\\ put_new_config CT_STRIP_HOST_TOOLCHAIN_EXECUTABLES n' run.sh", + "darwin_*:*-w64-mingw32:sed -i.bak '/put_new_config CT_MINGW_DEFAULT_MSVCRT_UCRT y/a\\ put_new_config CT_BINUTILS_PLUGINS n' run.sh", + "darwin_*:{*-linux-gnu,*-linux-musl}:sed -i.bak '/put_new_config CT_CC_LANG_CXX y/a\\ put_new_config CT_NCURSES_HOST_FALLBACKS \"\"' run.sh", + "linux_*:x86_64-w64-mingw32:mkdir -p patches/mingw-w64 && cp $PATCH_DIR/native/ct-tools/clang-widl-winnt.h.patch patches/mingw-w64/", + "linux_*:x86_64-w64-mingw32:sed -i '/put_new_config CT_MINGW_DEFAULT_MSVCRT_UCRT y/a\\ put_new_config CT_MINGW_W64_PATCH_LOCAL y\\n put_new_config CT_MINGW_W64_PATCH_ORDER \"local,bundled\"\\n put_new_config CT_PATCH_USE_LOCAL y\\n put_new_config CT_LOCAL_PATCH_DIR \"'\"$(pwd)/patches\"'\"' run.sh", + "windows_*:x86_64-w64-mingw32:mkdir -p patches/mingw-w64 && cp $PATCH_DIR/native/ct-tools/clang-widl-winnt.h.patch patches/mingw-w64/", + "windows_*:x86_64-w64-mingw32:sed -i '/put_new_config CT_MINGW_DEFAULT_MSVCRT_UCRT y/a\\ put_new_config CT_MINGW_W64_PATCH_LOCAL y\\n put_new_config CT_MINGW_W64_PATCH_ORDER \"local,bundled\"\\n put_new_config CT_PATCH_USE_LOCAL y\\n put_new_config CT_LOCAL_PATCH_DIR \"'\"$(pwd)/patches\"'\"' run.sh", + "*:*-linux-gnu:sed -i -e 's/^CT_GLIBC_V_2_42=y$/# CT_GLIBC_V_2_42 is not set/' -e 's/^# CT_GLIBC_V_2_41 is not set$/CT_GLIBC_V_2_41=y/' -e 's/^CT_GLIBC_VERSION=\"2.42\"$/CT_GLIBC_VERSION=\"2.41\"/' -e 's/^CT_GLIBC_2_42_or_later=y$/# CT_GLIBC_2_42_or_later is not set/' -e 's/^CT_GLIBC_2_42_or_older=y$/CT_GLIBC_2_41_or_older=y/' -e 's/^CT_GLIBC_later_than_2_41=y$/# CT_GLIBC_later_than_2_41 is not set/' platforms/$TOOL_TARGET/.config", + "*:*-linux-gnu:sed -i -e 's/^CT_GCC_V_15=y$/# CT_GCC_V_15 is not set/' -e 's/^# CT_GCC_V_13 is not set$/CT_GCC_V_13=y/' -e 's/^CT_GCC_VERSION=\"15.2.0\"$/CT_GCC_VERSION=\"13.4.0\"/' -e 's/^CT_GCC_later_than_15=y$/# CT_GCC_later_than_15 is not set/' -e 's/^CT_GCC_15_or_later=y$/# CT_GCC_15_or_later is not set/' -e 's/^CT_GCC_later_than_14=y$/# CT_GCC_later_than_14 is not set/' -e 's/^CT_GCC_14_or_later=y$/# CT_GCC_14_or_later is not set/' -e 's/^CT_GCC_later_than_13=y$/# CT_GCC_later_than_13 is not set/' platforms/$TOOL_TARGET/.config", + "*:{*-linux-gnu,*-w64-mingw32}:sed -i 's|install=\"./scripts/install-sh -c\"|install=\"'$NATIVEPREFIX'/bin/install -c\"|g' $NATIVEPREFIX/share/crosstool-ng/paths.sh", + "*:{*-linux-gnu,*-w64-mingw32}:mkdir -p $STAGING_DIR$PREFIX", + "linux_*:{*-linux-gnu,*-w64-mingw32}:env -i PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH LIBTOOL=$NATIVEPREFIX/bin/libtool AR=$NATIVEPREFIX/_/bin/llvm-ar RANLIB=$NATIVEPREFIX/_/bin/llvm-ranlib PREFIX=$(realpath $STAGING_DIR$PREFIX) ./run.sh $TOOL_TARGET", + "windows_*:{*-linux-gnu,*-linux-musl,*-w64-mingw32}:env -i SYSTEMROOT=\"$SYSTEMROOT\" TEMP=\"$TEMP\" TMP=\"$TMP\" PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH LIBTOOL=$NATIVEPREFIX/bin/libtool AR=$NATIVEPREFIX/_/bin/llvm-ar RANLIB=$NATIVEPREFIX/_/bin/llvm-ranlib PREFIX=$(realpath $STAGING_DIR$PREFIX) ./run.sh $TOOL_TARGET", + "darwin_*:{*-linux-gnu,*-w64-mingw32}:env -i SDKROOT=$NATIVEPREFIX/_/SDK/MacOSX26.1.sdk PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH LIBTOOL=$NATIVEPREFIX/bin/libtool AR=$NATIVEPREFIX/_/bin/llvm-ar RANLIB=$NATIVEPREFIX/_/bin/llvm-ranlib PREFIX=$(realpath $STAGING_DIR$PREFIX) ./run.sh $TOOL_TARGET", + "*:{*-linux-gnu,*-w64-mingw32}:mv $STAGING_DIR/$PREFIX/$TOOL_TARGET/$TOOL_TARGET/* $STAGING_DIR/$PREFIX", + "*:{*-linux-gnu,*-w64-mingw32}:rm -rf $STAGING_DIR/$PREFIX/$TOOL_TARGET/$TOOL_TARGET", + "*:{*-linux-gnu,*-w64-mingw32}:mkdir -p $STAGING_DIR/$NATIVEPREFIX", + "*:{*-linux-gnu,*-w64-mingw32}:mv $STAGING_DIR/$PREFIX/$TOOL_TARGET/* $STAGING_DIR/$NATIVEPREFIX", + "*:{*-linux-gnu,*-w64-mingw32}:mv $STAGING_DIR/$PREFIX/bin/* $STAGING_DIR/$NATIVEPREFIX/bin", + "*:x86_64-linux-gnu:cd $STAGING_DIR/$NATIVEPREFIX/bin && for f in x86_64-linux-gnu-*; do ln -sf $f ${f#x86_64-linux-gnu-}; done", + "*:aarch64-linux-gnu:cd $STAGING_DIR/$NATIVEPREFIX/bin && for f in aarch64-linux-gnu-*; do ln -sf $f ${f#aarch64-linux-gnu-}; done", + "*:x86_64-linux-musl:cd $STAGING_DIR/$NATIVEPREFIX/bin && for f in x86_64-linux-musl-*; do ln -sf $f ${f#x86_64-linux-musl-}; done", + "linux_*:x86_64-w64-mingw32:cd $STAGING_DIR/$NATIVEPREFIX/bin && for f in x86_64-w64-mingw32-*; do ln -sf $f ${f#x86_64-w64-mingw32-}; done", + "darwin_*:x86_64-w64-mingw32:cd $STAGING_DIR/$NATIVEPREFIX/bin && for f in x86_64-w64-mingw32-*; do ln -sf $f ${f#x86_64-w64-mingw32-}; done", + "windows_*:x86_64-w64-mingw32:find $STAGING_DIR/$PREFIX -type l -print0 | while IFS= read -r -d '' l; do t=$(readlink \"$l\"); case \"$t\" in ../../x86_64-w64-mingw32/sysroot/*) ln -sfn \"../sysroot/${t#../../x86_64-w64-mingw32/sysroot/}\" \"$l\";; ../../x86_64-w64-mingw32/lib32/*) ln -sfn \"../lib32/${t#../../x86_64-w64-mingw32/lib32/}\" \"$l\";; esac; done", + "windows_*:x86_64-w64-mingw32:cd $STAGING_DIR/$NATIVEPREFIX/bin && for f in x86_64-w64-mingw32-*; do cp -f \"$f\" \"${f#x86_64-w64-mingw32-}\"; done", + "windows_*:x86_64-w64-mingw32:find $STAGING_DIR/$PREFIX $STAGING_DIR/$NATIVEPREFIX -type l -print0 | sort -rz | while IFS= read -r -d '' l; do t=$(readlink -f \"$l\" 2>/dev/null || true); if [ -n \"$t\" ] && [ -e \"$t\" ]; then rm -f \"$l\"; cp -a \"$t\" \"$l\"; else rm -f \"$l\"; fi; done" + ] + } +} \ No newline at end of file diff --git a/packages/native/curl.json b/packages/native/curl.json new file mode 100644 index 0000000..cc44a2e --- /dev/null +++ b/packages/native/curl.json @@ -0,0 +1,30 @@ +{ + "package": "native/curl", + "version": "8.15.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "d85cfc79dc505ff800cb1d321a320183035011fa08cb301356425d86be8fc53c", + "url": "https://curl.se/download/curl-8.15.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/libpsl", + "*:*:native/make", + "*:*:native/openssl", + "*:*:native/perl" + ], + "build": { + "env": [ + "*:*:config_opts=--with-openssl --disable-docs --disable-ldap" + ], + "steps": [ + "*:*:bash ./configure $config_opts --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart-bin@3.4.0-247.0.dev.json b/packages/native/dart-bin@3.4.0-247.0.dev.json new file mode 100644 index 0000000..ab99290 --- /dev/null +++ b/packages/native/dart-bin@3.4.0-247.0.dev.json @@ -0,0 +1,40 @@ +{ + "package": "native/dart-bin@3.4.0-247.0.dev", + "version": "3.4.0-247.0.dev", + "type": "native", + "download": [ + { + "kind": "blob", + "path": "./dartsdk-darwin_arm64.zip", + "sha256": "95eec1e3dfa7c891d928c0ae3be9550675eefa95b240ea5dd414f9b4c2a90369", + "url": "https://storage.googleapis.com/dart-archive/channels/dev/release/3.4.0-247.0.dev/sdk/dartsdk-macos-arm64-release.zip" + }, + { + "kind": "blob", + "path": "./dartsdk-linux_amd64.zip", + "sha256": "3cff0b896fb2f665c8ab2cbf746882fcf42d2def7c3c64db7e2208ee092932da", + "url": "https://storage.googleapis.com/dart-archive/channels/dev/release/3.4.0-247.0.dev/sdk/dartsdk-linux-x64-release.zip" + }, + { + "kind": "blob", + "path": "./dartsdk-linux_arm64.zip", + "sha256": "98c0c8bd016ba6e1156d4630409f47ef42e16226efe331751e706711496208fc", + "url": "https://storage.googleapis.com/dart-archive/channels/dev/release/3.4.0-247.0.dev/sdk/dartsdk-linux-arm64-release.zip" + } + ], + "dependencies": [ + "*:*:native/7zip", + "*:*:native/_/_" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir build", + "*:*:cd build && 7zz x ../dartsdk-${BUILDER_GOOS}_${BUILDER_GOARCH}.zip", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:mv build/dart-sdk/lib $STAGING_DIR$NATIVEPREFIX", + "*:*:mv build/dart-sdk/include $STAGING_DIR$NATIVEPREFIX", + "*:*:mv build/dart-sdk/bin $STAGING_DIR$NATIVEPREFIX" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.5.0-278.0.dev.json b/packages/native/dart@3.5.0-278.0.dev.json new file mode 100644 index 0000000..e3f5ad4 --- /dev/null +++ b/packages/native/dart@3.5.0-278.0.dev.json @@ -0,0 +1,562 @@ +{ + "package": "native/dart@3.5.0-278.0.dev", + "version": "3.5.0-278.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "cf0d430bc6a507b3d54d4b5bfc91b308f0325178", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "831b22d5e496fe63a813ca1c1b64f533c2f9fa0c", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "d844d2e77b402d562ade8cf8fd96759b587bf09d", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "9c7294fd58261a79794f5afaa26598cf1442ad20", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "d24a38200fef19150eef00cad35b138936c08767", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "81d656878ec611cb0b42d52c82e9dae93920d9ba", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/args", + "sha256": "6a5a2e6b1f0020b873c7ffbdd36a784c4f9ee300", + "url": "https://dart.googlesource.com/args.git" + }, + { + "kind": "git", + "path": "third_party/pkg/async", + "sha256": "a00437017231ebb6c3e3e8ecdfc9dd03522ab828", + "url": "https://dart.googlesource.com/async.git" + }, + { + "kind": "git", + "path": "third_party/pkg/bazel_worker", + "sha256": "c76d7c86381a6ed594641ba03b55c65b84ee11a6", + "url": "https://dart.googlesource.com/bazel_worker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/benchmark_harness", + "sha256": "f6ef33dc88d7cbc9e4a8a087f1e652eb0d6cc254", + "url": "https://dart.googlesource.com/benchmark_harness.git" + }, + { + "kind": "git", + "path": "third_party/pkg/boolean_selector", + "sha256": "62f82f6a333b419b457e62cadc17b7a9c0545873", + "url": "https://dart.googlesource.com/boolean_selector.git" + }, + { + "kind": "git", + "path": "third_party/pkg/browser_launcher", + "sha256": "7348ceae6508e5350771979c2951a54313303416", + "url": "https://dart.googlesource.com/browser_launcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/cli_util", + "sha256": "c37d5e14f50e72a268c1ad86149cecfa4b58c494", + "url": "https://dart.googlesource.com/cli_util.git" + }, + { + "kind": "git", + "path": "third_party/pkg/clock", + "sha256": "7cbf08e36a92f14f22132d255846610c1b065324", + "url": "https://dart.googlesource.com/clock.git" + }, + { + "kind": "git", + "path": "third_party/pkg/collection", + "sha256": "9354f386de3c57f5486b01ab4dfa1a2f033307d9", + "url": "https://dart.googlesource.com/collection.git" + }, + { + "kind": "git", + "path": "third_party/pkg/convert", + "sha256": "0c9eab7d4656be97329c4970659afd53a78910e6", + "url": "https://dart.googlesource.com/convert.git" + }, + { + "kind": "git", + "path": "third_party/pkg/crypto", + "sha256": "813e35e913d12e16de67ac57523cd0ff4b07c012", + "url": "https://dart.googlesource.com/crypto.git" + }, + { + "kind": "git", + "path": "third_party/pkg/csslib", + "sha256": "23c314bb6b247a71348cfb0987ba0eb29574abb6", + "url": "https://dart.googlesource.com/csslib.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "a6ad7693555a9add6f98ad6fd94de80d35c89415", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "14d33d3a120ad3ce621bbcf0a545dc3adeccd7e7", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "8ada2ee303383cf62cace9b2a97e8a3cc983e5c1", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/file", + "sha256": "07cacaed6679a173e29176747e6ce0325742749f", + "url": "https://dart.googlesource.com/external/github.com/google/file.dart" + }, + { + "kind": "git", + "path": "third_party/pkg/fixnum", + "sha256": "a8157d87f17d5184e210403f2ed63d354b854132", + "url": "https://dart.googlesource.com/fixnum.git" + }, + { + "kind": "git", + "path": "third_party/pkg/glob", + "sha256": "eaec6a448576048b748475d80bfac2795ad5a267", + "url": "https://dart.googlesource.com/glob.git" + }, + { + "kind": "git", + "path": "third_party/pkg/html", + "sha256": "3bc803d7e655491b243418f19300ef0c6112bcea", + "url": "https://dart.googlesource.com/html.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "8c325b9ca33d878a86d69c5048a8e6e18379663c", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_multi_server", + "sha256": "25941e260658efb324de857e6022f418faf9bdd1", + "url": "https://dart.googlesource.com/http_multi_server.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_parser", + "sha256": "71b4c2c448b333397d5ff3235825d8cea773291c", + "url": "https://dart.googlesource.com/http_parser.git" + }, + { + "kind": "git", + "path": "third_party/pkg/intl", + "sha256": "5d65e3808ce40e6282e40881492607df4e35669f", + "url": "https://dart.googlesource.com/intl.git" + }, + { + "kind": "git", + "path": "third_party/pkg/json_rpc_2", + "sha256": "5b1cbd679756700d5f319bf10a217da53e98ea52", + "url": "https://dart.googlesource.com/json_rpc_2.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/lints", + "sha256": "baaaa5616370243c3c8c6a9f67fb83d26bdac552", + "url": "https://dart.googlesource.com/lints.git" + }, + { + "kind": "git", + "path": "third_party/pkg/logging", + "sha256": "dbd682919708316e9a6d1e2fa472c9ad9225c2b4", + "url": "https://dart.googlesource.com/logging.git" + }, + { + "kind": "git", + "path": "third_party/pkg/markdown", + "sha256": "3d8d7a8f14b74bb646bb6e4ae35e0bf2beb74154", + "url": "https://dart.googlesource.com/markdown.git" + }, + { + "kind": "git", + "path": "third_party/pkg/matcher", + "sha256": "0abd4054c47a923486a6c0c04b5c974ba13ad2da", + "url": "https://dart.googlesource.com/matcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/mime", + "sha256": "4ca2f5edaafe21f462922d34db99486a44bb08b8", + "url": "https://dart.googlesource.com/mime.git" + }, + { + "kind": "git", + "path": "third_party/pkg/mockito", + "sha256": "2302814df66e651b6710311366501523dbee2e11", + "url": "https://dart.googlesource.com/mockito.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "fef40aebc3cf34654919e8a5785b6c50b3ea445c", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/package_config", + "sha256": "903a0e528f91aef90821c8f5eaafbc1ae27198ab", + "url": "https://dart.googlesource.com/package_config.git" + }, + { + "kind": "git", + "path": "third_party/pkg/path", + "sha256": "04807b61c25f98f328b322ec511451f9f86f98bb", + "url": "https://dart.googlesource.com/path.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pool", + "sha256": "88e463600c636a0d8cdb5dc306524ebf04b06baf", + "url": "https://dart.googlesource.com/pool.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "ccf104dbc36929c0f8708285d5f3a8fae206343e", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "ddc1c2fd2e2a7cd94a0b92ea033961a25f4ad517", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub_semver", + "sha256": "a9025f3cc23ebb0f86c0af8759d95306b9133ce0", + "url": "https://dart.googlesource.com/pub_semver.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "4c54af6b6baa9404826d234385c1bf69575dfd47", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_map_stack_trace", + "sha256": "96a8213dacf7cd42aefb1311491a4169826f98d2", + "url": "https://dart.googlesource.com/source_map_stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_maps", + "sha256": "caa79c2011015759c6cf3299f299f5cccdf8bb61", + "url": "https://dart.googlesource.com/source_maps.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_span", + "sha256": "59a3903521dbf4c38c77df73669e73174a170327", + "url": "https://dart.googlesource.com/source_span.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sse", + "sha256": "7dcde164d5bfe707441f206379ef33e7509e2aac", + "url": "https://dart.googlesource.com/sse.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stack_trace", + "sha256": "ab09060b82c936c38c04eb49c1154b83f6648349", + "url": "https://dart.googlesource.com/stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stream_channel", + "sha256": "b41ff7a25395ace8b23e454e3d1a3459a71306ca", + "url": "https://dart.googlesource.com/stream_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/string_scanner", + "sha256": "7b37c1b3d1ca6b581792e6ba385f651573af4a45", + "url": "https://dart.googlesource.com/string_scanner.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "7622bdd07501f3f279212e355325b7c84a2b0a08", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "552a49d7595e444184d4f91e9afd533aa253a31d", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/term_glyph", + "sha256": "c86e8171ee7e9f6fc8e775e0be755a603dd0b72d", + "url": "https://dart.googlesource.com/term_glyph.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "329c6dff4dfcb178ba6c7009cf1c1b9215b317aa", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_descriptor", + "sha256": "b23d7ccb0f9882e161fb4dea75b2237bf428432b", + "url": "https://dart.googlesource.com/test_descriptor.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_process", + "sha256": "862eaf3b825f5e97b278d84a2afbe81b3e8a1683", + "url": "https://dart.googlesource.com/test_process.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_reflective_loader", + "sha256": "816942eaeeac30cc59d8699f1e94ad779cc53c06", + "url": "https://dart.googlesource.com/test_reflective_loader.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "4321aecf2cb618dceab5d90adf0cb2ef7207169c", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/typed_data", + "sha256": "d14f9654f7a5d6baa7dcc27691bd0fa56769fb67", + "url": "https://dart.googlesource.com/typed_data.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "e7b11a234638bd5d76a05bae99d20b937637dfe8", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/watcher", + "sha256": "c00fc2a6cd869cdebbc52e00af3d912d25745729", + "url": "https://dart.googlesource.com/watcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "2fe754fb396cb9b87010f0318cfbfc5408346c48", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web_socket_channel", + "sha256": "bf69990738f173c07e67cf6945551194bc8c2d92", + "url": "https://dart.googlesource.com/web_socket_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "eccc7d87982b23f666d5e3e09953dca59ca094e4", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "f85779edd7c9f66198d4391ed3631db1d97a5b11", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "5740cc91eaeb13a02007b77b128fccf4b056db6e", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml", + "sha256": "7873b3fb9f16ec83bc7778fed58615fa91f1f042", + "url": "https://dart.googlesource.com/yaml.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml_edit", + "sha256": "08a146ef8f2c7aba908d2017c9ec840b882c9e51", + "url": "https://dart.googlesource.com/yaml_edit.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "72369878105eccd563547afbad97407a2431b96bd4c04a1d6da75cb068437f50", + "url": "https://pub.dev/api/archives/devtools_shared-10.0.2.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart-bin@3.4.0-247.0.dev", + "*:*:native/git", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [ + "darwin_arm64:*:BUILDTARGET=mac-arm64", + "linux_arm64:*:BUILDTARGET=linux-arm64", + "linux_amd64:*:BUILDTARGET=linux-amd64" + ], + "steps": [ + "*:*:mkdir -p buildtools/$BUILDTARGET/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/'$BUILDTARGET'\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/$BUILDTARGET/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/$BUILDTARGET/clang/bin", + "*:*:mkdir -p buildtools/$BUILDTARGET/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/$BUILDTARGET/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/$BUILDTARGET/clang/bin/clang", + "*:*:ln -s $CXX buildtools/$BUILDTARGET/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/$BUILDTARGET/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/$BUILDTARGET/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/$BUILDTARGET/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/$BUILDTARGET/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.5.0-278.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk --verbose", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.5.0-307.0.dev.json b/packages/native/dart@3.5.0-307.0.dev.json new file mode 100644 index 0000000..e12fe20 --- /dev/null +++ b/packages/native/dart@3.5.0-307.0.dev.json @@ -0,0 +1,567 @@ +{ + "package": "native/dart@3.5.0-307.0.dev", + "version": "3.5.0-307.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "7d7fbb30e0ca19c76800b1ad388fa55d09037e66", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "buildtools/clang_format/script", + "sha256": "bb994c6f067340c1135eb43eed84f4b33cfa7397", + "url": "https://chromium.googlesource.com/chromium/llvm-project/cfe/tools/clang-format.git" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "3a1b6f75c771d62e7150f2dd69595a98fd6930f4", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "654ee6e2504f11fb0e982a2cf276bafa750f694b", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "9c7294fd58261a79794f5afaa26598cf1442ad20", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "d24a38200fef19150eef00cad35b138936c08767", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "81d656878ec611cb0b42d52c82e9dae93920d9ba", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/args", + "sha256": "6a5a2e6b1f0020b873c7ffbdd36a784c4f9ee300", + "url": "https://dart.googlesource.com/args.git" + }, + { + "kind": "git", + "path": "third_party/pkg/async", + "sha256": "d7c0cd5a458308ab5e5a0d0deebdce32c4391ec6", + "url": "https://dart.googlesource.com/async.git" + }, + { + "kind": "git", + "path": "third_party/pkg/bazel_worker", + "sha256": "c76d7c86381a6ed594641ba03b55c65b84ee11a6", + "url": "https://dart.googlesource.com/bazel_worker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/benchmark_harness", + "sha256": "f6ef33dc88d7cbc9e4a8a087f1e652eb0d6cc254", + "url": "https://dart.googlesource.com/benchmark_harness.git" + }, + { + "kind": "git", + "path": "third_party/pkg/boolean_selector", + "sha256": "62f82f6a333b419b457e62cadc17b7a9c0545873", + "url": "https://dart.googlesource.com/boolean_selector.git" + }, + { + "kind": "git", + "path": "third_party/pkg/browser_launcher", + "sha256": "7348ceae6508e5350771979c2951a54313303416", + "url": "https://dart.googlesource.com/browser_launcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/cli_util", + "sha256": "c37d5e14f50e72a268c1ad86149cecfa4b58c494", + "url": "https://dart.googlesource.com/cli_util.git" + }, + { + "kind": "git", + "path": "third_party/pkg/clock", + "sha256": "7cbf08e36a92f14f22132d255846610c1b065324", + "url": "https://dart.googlesource.com/clock.git" + }, + { + "kind": "git", + "path": "third_party/pkg/collection", + "sha256": "9354f386de3c57f5486b01ab4dfa1a2f033307d9", + "url": "https://dart.googlesource.com/collection.git" + }, + { + "kind": "git", + "path": "third_party/pkg/convert", + "sha256": "0c9eab7d4656be97329c4970659afd53a78910e6", + "url": "https://dart.googlesource.com/convert.git" + }, + { + "kind": "git", + "path": "third_party/pkg/crypto", + "sha256": "813e35e913d12e16de67ac57523cd0ff4b07c012", + "url": "https://dart.googlesource.com/crypto.git" + }, + { + "kind": "git", + "path": "third_party/pkg/csslib", + "sha256": "b70fef222c8a98abca39c3f729ec34632089697e", + "url": "https://dart.googlesource.com/csslib.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "a6ad7693555a9add6f98ad6fd94de80d35c89415", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "88df88c9278ec4ec31df818f3ae33d4f91c8cd64", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "31148cd81bdb3c248fc30cd345ef49a978ed454c", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/file", + "sha256": "07cacaed6679a173e29176747e6ce0325742749f", + "url": "https://dart.googlesource.com/external/github.com/google/file.dart" + }, + { + "kind": "git", + "path": "third_party/pkg/fixnum", + "sha256": "a8157d87f17d5184e210403f2ed63d354b854132", + "url": "https://dart.googlesource.com/fixnum.git" + }, + { + "kind": "git", + "path": "third_party/pkg/glob", + "sha256": "6d3ba5ec02817e62d17ace040590bb81a3e1242f", + "url": "https://dart.googlesource.com/glob.git" + }, + { + "kind": "git", + "path": "third_party/pkg/html", + "sha256": "3bc803d7e655491b243418f19300ef0c6112bcea", + "url": "https://dart.googlesource.com/html.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "4d8e7ef73d6135a8cc9b5e53db1beb43977d44b0", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_multi_server", + "sha256": "25941e260658efb324de857e6022f418faf9bdd1", + "url": "https://dart.googlesource.com/http_multi_server.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_parser", + "sha256": "9bf7bd981a39137da1e5d7fe64f4652b078c7aa9", + "url": "https://dart.googlesource.com/http_parser.git" + }, + { + "kind": "git", + "path": "third_party/pkg/intl", + "sha256": "5d65e3808ce40e6282e40881492607df4e35669f", + "url": "https://dart.googlesource.com/intl.git" + }, + { + "kind": "git", + "path": "third_party/pkg/json_rpc_2", + "sha256": "5b1cbd679756700d5f319bf10a217da53e98ea52", + "url": "https://dart.googlesource.com/json_rpc_2.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/lints", + "sha256": "baaaa5616370243c3c8c6a9f67fb83d26bdac552", + "url": "https://dart.googlesource.com/lints.git" + }, + { + "kind": "git", + "path": "third_party/pkg/logging", + "sha256": "240ec33e23720091e0e5a029d569a3770ddccf1c", + "url": "https://dart.googlesource.com/logging.git" + }, + { + "kind": "git", + "path": "third_party/pkg/markdown", + "sha256": "3d8d7a8f14b74bb646bb6e4ae35e0bf2beb74154", + "url": "https://dart.googlesource.com/markdown.git" + }, + { + "kind": "git", + "path": "third_party/pkg/matcher", + "sha256": "0abd4054c47a923486a6c0c04b5c974ba13ad2da", + "url": "https://dart.googlesource.com/matcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/mime", + "sha256": "4ca2f5edaafe21f462922d34db99486a44bb08b8", + "url": "https://dart.googlesource.com/mime.git" + }, + { + "kind": "git", + "path": "third_party/pkg/mockito", + "sha256": "2302814df66e651b6710311366501523dbee2e11", + "url": "https://dart.googlesource.com/mockito.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "fef40aebc3cf34654919e8a5785b6c50b3ea445c", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/package_config", + "sha256": "903a0e528f91aef90821c8f5eaafbc1ae27198ab", + "url": "https://dart.googlesource.com/package_config.git" + }, + { + "kind": "git", + "path": "third_party/pkg/path", + "sha256": "04807b61c25f98f328b322ec511451f9f86f98bb", + "url": "https://dart.googlesource.com/path.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pool", + "sha256": "832c5ab5eaee444354a8c796f7998bf744f169af", + "url": "https://dart.googlesource.com/pool.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "ccf104dbc36929c0f8708285d5f3a8fae206343e", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "ddc1c2fd2e2a7cd94a0b92ea033961a25f4ad517", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub_semver", + "sha256": "dfcad38866fb1e94e8ca91bff3dddd5189fb0794", + "url": "https://dart.googlesource.com/pub_semver.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "2536c15a562cb183dabbc628824a215663830325", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_map_stack_trace", + "sha256": "96a8213dacf7cd42aefb1311491a4169826f98d2", + "url": "https://dart.googlesource.com/source_map_stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_maps", + "sha256": "caa79c2011015759c6cf3299f299f5cccdf8bb61", + "url": "https://dart.googlesource.com/source_maps.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_span", + "sha256": "59a3903521dbf4c38c77df73669e73174a170327", + "url": "https://dart.googlesource.com/source_span.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sse", + "sha256": "7dcde164d5bfe707441f206379ef33e7509e2aac", + "url": "https://dart.googlesource.com/sse.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stack_trace", + "sha256": "ab09060b82c936c38c04eb49c1154b83f6648349", + "url": "https://dart.googlesource.com/stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stream_channel", + "sha256": "b41ff7a25395ace8b23e454e3d1a3459a71306ca", + "url": "https://dart.googlesource.com/stream_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/string_scanner", + "sha256": "e1cab8f0538b50f6d7180598752cf5a7e07e74db", + "url": "https://dart.googlesource.com/string_scanner.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "7622bdd07501f3f279212e355325b7c84a2b0a08", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "552a49d7595e444184d4f91e9afd533aa253a31d", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/term_glyph", + "sha256": "c86e8171ee7e9f6fc8e775e0be755a603dd0b72d", + "url": "https://dart.googlesource.com/term_glyph.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "329c6dff4dfcb178ba6c7009cf1c1b9215b317aa", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_descriptor", + "sha256": "2f19400259e6ec6801a79dcbf038b235545ab400", + "url": "https://dart.googlesource.com/test_descriptor.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_process", + "sha256": "a7ca20b73f28d220e6478254082ea2b52f46dc97", + "url": "https://dart.googlesource.com/test_process.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_reflective_loader", + "sha256": "816942eaeeac30cc59d8699f1e94ad779cc53c06", + "url": "https://dart.googlesource.com/test_reflective_loader.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "e660a68dce659311fb47735ab00365e26fca2fe3", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/typed_data", + "sha256": "85299290551297a28202b6e7a177bb787f790ffd", + "url": "https://dart.googlesource.com/typed_data.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "e7b11a234638bd5d76a05bae99d20b937637dfe8", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/watcher", + "sha256": "c00fc2a6cd869cdebbc52e00af3d912d25745729", + "url": "https://dart.googlesource.com/watcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "6b8a46561b82de9b20d77d9ac491844d303ca08f", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web_socket_channel", + "sha256": "bf69990738f173c07e67cf6945551194bc8c2d92", + "url": "https://dart.googlesource.com/web_socket_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "c56611255f3f02642da10750448a8c90a9fa7b47", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "f85779edd7c9f66198d4391ed3631db1d97a5b11", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "5740cc91eaeb13a02007b77b128fccf4b056db6e", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml", + "sha256": "4cf24ca3bbcb2cd8cbea32fdd355ee5d0a597247", + "url": "https://dart.googlesource.com/yaml.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml_edit", + "sha256": "08a146ef8f2c7aba908d2017c9ec840b882c9e51", + "url": "https://dart.googlesource.com/yaml_edit.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "72369878105eccd563547afbad97407a2431b96bd4c04a1d6da75cb068437f50", + "url": "https://pub.dev/api/archives/devtools_shared-10.0.2.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.5.0-278.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.5.0-307.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.6.0-2.0.dev.json b/packages/native/dart@3.6.0-2.0.dev.json new file mode 100644 index 0000000..3152fd9 --- /dev/null +++ b/packages/native/dart@3.6.0-2.0.dev.json @@ -0,0 +1,561 @@ +{ + "package": "native/dart@3.6.0-2.0.dev", + "version": "3.6.0-2.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "7e6469bd51d404916395a47b011d907d2c905121", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "7b457e8d8c10361424beb7b432347f668c974439", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "654ee6e2504f11fb0e982a2cf276bafa750f694b", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "9c7294fd58261a79794f5afaa26598cf1442ad20", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "d24a38200fef19150eef00cad35b138936c08767", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "81d656878ec611cb0b42d52c82e9dae93920d9ba", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/args", + "sha256": "6a5a2e6b1f0020b873c7ffbdd36a784c4f9ee300", + "url": "https://dart.googlesource.com/args.git" + }, + { + "kind": "git", + "path": "third_party/pkg/async", + "sha256": "c0d81f8699682d01d657a9bf827107d11904a247", + "url": "https://dart.googlesource.com/async.git" + }, + { + "kind": "git", + "path": "third_party/pkg/bazel_worker", + "sha256": "c76d7c86381a6ed594641ba03b55c65b84ee11a6", + "url": "https://dart.googlesource.com/bazel_worker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/benchmark_harness", + "sha256": "f6ef33dc88d7cbc9e4a8a087f1e652eb0d6cc254", + "url": "https://dart.googlesource.com/benchmark_harness.git" + }, + { + "kind": "git", + "path": "third_party/pkg/boolean_selector", + "sha256": "c5468f44fd9ca0ea3435e1a0a84ff9b6fac38261", + "url": "https://dart.googlesource.com/boolean_selector.git" + }, + { + "kind": "git", + "path": "third_party/pkg/browser_launcher", + "sha256": "60126904a26b761d29b4f2d76292ff3c089160de", + "url": "https://dart.googlesource.com/browser_launcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/cli_util", + "sha256": "64192706344d0598784bebe1abc4a9bfc2608de0", + "url": "https://dart.googlesource.com/cli_util.git" + }, + { + "kind": "git", + "path": "third_party/pkg/clock", + "sha256": "ad428ea8b75fa0d7ba629791552d40478745c54a", + "url": "https://dart.googlesource.com/clock.git" + }, + { + "kind": "git", + "path": "third_party/pkg/collection", + "sha256": "9354f386de3c57f5486b01ab4dfa1a2f033307d9", + "url": "https://dart.googlesource.com/collection.git" + }, + { + "kind": "git", + "path": "third_party/pkg/convert", + "sha256": "9035cafefc1da4315f26058734d0c2a19d5ab56a", + "url": "https://dart.googlesource.com/convert.git" + }, + { + "kind": "git", + "path": "third_party/pkg/crypto", + "sha256": "1216790ba704a0ab194f9cd0da2d65e1767f3342", + "url": "https://dart.googlesource.com/crypto.git" + }, + { + "kind": "git", + "path": "third_party/pkg/csslib", + "sha256": "192d720f121792ab05ca157ea280edc7e0410e9c", + "url": "https://dart.googlesource.com/csslib.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "a6ad7693555a9add6f98ad6fd94de80d35c89415", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "7e5da6090e6a48cebaee8789ca0fc396b34fd8a4", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "54ca01abe4b7b62419ee88814d3dc98df36ff8ff", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/file", + "sha256": "07cacaed6679a173e29176747e6ce0325742749f", + "url": "https://dart.googlesource.com/external/github.com/google/file.dart" + }, + { + "kind": "git", + "path": "third_party/pkg/fixnum", + "sha256": "6c19e60366ce3d5edfaed51a7c12c98e7977977e", + "url": "https://dart.googlesource.com/fixnum.git" + }, + { + "kind": "git", + "path": "third_party/pkg/glob", + "sha256": "6d3ba5ec02817e62d17ace040590bb81a3e1242f", + "url": "https://dart.googlesource.com/glob.git" + }, + { + "kind": "git", + "path": "third_party/pkg/html", + "sha256": "0da420ca1e196cda54ede476d0d8d3ecf55375ef", + "url": "https://dart.googlesource.com/html.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "8d893851904d8cd292a66e39812b59aca2cc4d96", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_multi_server", + "sha256": "25941e260658efb324de857e6022f418faf9bdd1", + "url": "https://dart.googlesource.com/http_multi_server.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_parser", + "sha256": "9bf7bd981a39137da1e5d7fe64f4652b078c7aa9", + "url": "https://dart.googlesource.com/http_parser.git" + }, + { + "kind": "git", + "path": "third_party/pkg/intl", + "sha256": "5d65e3808ce40e6282e40881492607df4e35669f", + "url": "https://dart.googlesource.com/intl.git" + }, + { + "kind": "git", + "path": "third_party/pkg/json_rpc_2", + "sha256": "616937f6d3837e38a2a287653ddaf722de260702", + "url": "https://dart.googlesource.com/json_rpc_2.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/lints", + "sha256": "f6b5d36485f6f067ac0f5a7193006ebe82ee6113", + "url": "https://dart.googlesource.com/lints.git" + }, + { + "kind": "git", + "path": "third_party/pkg/logging", + "sha256": "6c3fb37fecb2e30415072f327b834a3e95517fa9", + "url": "https://dart.googlesource.com/logging.git" + }, + { + "kind": "git", + "path": "third_party/pkg/markdown", + "sha256": "62424376d0b5fe35a2957b3caed4b75db010ba82", + "url": "https://dart.googlesource.com/markdown.git" + }, + { + "kind": "git", + "path": "third_party/pkg/matcher", + "sha256": "d6d573d0f8d65b36550ce62aad3ce6b5e987b642", + "url": "https://dart.googlesource.com/matcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/mime", + "sha256": "11fec7d6df509a4efd554051cc27e3bf82df9c96", + "url": "https://dart.googlesource.com/mime.git" + }, + { + "kind": "git", + "path": "third_party/pkg/mockito", + "sha256": "a7fdf7101fbd31132a59188a6057d21004345927", + "url": "https://dart.googlesource.com/mockito.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "fcc783c1d2777555616dfc850f131878ea5d88a9", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/package_config", + "sha256": "903a0e528f91aef90821c8f5eaafbc1ae27198ab", + "url": "https://dart.googlesource.com/package_config.git" + }, + { + "kind": "git", + "path": "third_party/pkg/path", + "sha256": "e969f42ed112dd702a9453beb9df6c12ae2d3805", + "url": "https://dart.googlesource.com/path.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pool", + "sha256": "924fb04353cec915d927f9f1aed88e2eda92b98a", + "url": "https://dart.googlesource.com/pool.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "ccf104dbc36929c0f8708285d5f3a8fae206343e", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "ea4a1c854690d3abceb92c8cc2c6454470f9d5a7", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub_semver", + "sha256": "d9e5ee68a350fbf4319bd4dfcb895fc016337d3a", + "url": "https://dart.googlesource.com/pub_semver.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "9f2dffecbe8f219146a077e401758602752d486a", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_map_stack_trace", + "sha256": "741b6ceb4b6cdb8ff620664337d7ecc63ca52cc1", + "url": "https://dart.googlesource.com/source_map_stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_maps", + "sha256": "caa79c2011015759c6cf3299f299f5cccdf8bb61", + "url": "https://dart.googlesource.com/source_maps.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_span", + "sha256": "89520f3009e332ce2b6675f71dca166521c36cc4", + "url": "https://dart.googlesource.com/source_span.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sse", + "sha256": "52d042ff9ab2d0e5bc26805d74a03077a67861e1", + "url": "https://dart.googlesource.com/sse.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stack_trace", + "sha256": "4fd3e2a2dc6611febf4cfb9197ebf9e60fc6a34d", + "url": "https://dart.googlesource.com/stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stream_channel", + "sha256": "28a65331aa2d66a5e953205aa462bcdb1e240a5b", + "url": "https://dart.googlesource.com/stream_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/string_scanner", + "sha256": "0de03b5279a04aa05052ce306f90fca473c6fd1a", + "url": "https://dart.googlesource.com/string_scanner.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "7622bdd07501f3f279212e355325b7c84a2b0a08", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "552a49d7595e444184d4f91e9afd533aa253a31d", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/term_glyph", + "sha256": "38a158f55006cf30942c928171ea601ee5e0308f", + "url": "https://dart.googlesource.com/term_glyph.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "3256c23cc753a184bb3bf27610a7c8410735e3ac", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_descriptor", + "sha256": "90743bc16bc00526a1b9a64f813614be9b2479d9", + "url": "https://dart.googlesource.com/test_descriptor.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_process", + "sha256": "6223572ca16d7585d5f08d9281de6a5734e45150", + "url": "https://dart.googlesource.com/test_process.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_reflective_loader", + "sha256": "6e648863b39aab8d0204e769d25805eea9db0ac4", + "url": "https://dart.googlesource.com/test_reflective_loader.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "43a8582a85d2220b5f1ca8383d97587792085b36", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/typed_data", + "sha256": "365468a74251c930a463daf5b8f13227e269111a", + "url": "https://dart.googlesource.com/typed_data.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "2cfbe2c115a57b368ccbc3c89ebd38a06764d3d1", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/watcher", + "sha256": "0484625589d8512b36a7ad898a6cc6351d24c556", + "url": "https://dart.googlesource.com/watcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "e4c4d8126466e28dc137890b8f999da59bdedddd", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web_socket_channel", + "sha256": "8e95ea75302180af075295f7dd7ffe922e26f789", + "url": "https://dart.googlesource.com/web_socket_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "75417c09181c97786d9539a662834bed9d2f1e77", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "718e4c37d004fceb9856de980782c46bf9576df5", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "32fffa53df3f54005c742ddf4f859fb585a6b254", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml", + "sha256": "30fd9e0cd49b2e04f74769f9b24a0300e400403e", + "url": "https://dart.googlesource.com/yaml.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml_edit", + "sha256": "57a28daea82a3f00f57a90d5ea6df6a458b2f781", + "url": "https://dart.googlesource.com/yaml_edit.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "72369878105eccd563547afbad97407a2431b96bd4c04a1d6da75cb068437f50", + "url": "https://pub.dev/api/archives/devtools_shared-10.0.2.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.5.0-307.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.6.0-2.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.7.0-224.0.dev.json b/packages/native/dart@3.7.0-224.0.dev.json new file mode 100644 index 0000000..5b949c6 --- /dev/null +++ b/packages/native/dart@3.7.0-224.0.dev.json @@ -0,0 +1,430 @@ +{ + "package": "native/dart@3.7.0-224.0.dev", + "version": "3.7.0-224.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "c7e47c6c5df6ffa16d92704d5291b3387f974648", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "buildtools/clang_format/script", + "sha256": "bb994c6f067340c1135eb43eed84f4b33cfa7397", + "url": "https://chromium.googlesource.com/chromium/llvm-project/cfe/tools/clang-format.git" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "d50a305d1b4455b4e72ba45a2cf2ab1c37004bc6", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "93883fde36ac158fd415dcd6dbd387dcfd928d3c", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "9c7294fd58261a79794f5afaa26598cf1442ad20", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "567289e4bb1958153f428bba52d953f3c080b4d7", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/core", + "sha256": "abcf992cf9fe1e896ed9dcff15523c0a6c00621d", + "url": "https://dart.googlesource.com/core.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "1de89eb3bd340315f9ff5f2afc319cc1d6131b8d", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "c7f11603effa88ddacabfd555993f322fca8b3fe", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "248b1801131ddc2e738c8181fc32d488e1312052", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/glob", + "sha256": "994191a107b99a1911a3ef52ca238cd9305c8d37", + "url": "https://dart.googlesource.com/glob.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "79470d014b467f01b0e7c5b63ab6c86b22dec8db", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_multi_server", + "sha256": "f6a748819139b8cbf513d5fc36b10676b0cb066f", + "url": "https://dart.googlesource.com/http_multi_server.git" + }, + { + "kind": "git", + "path": "third_party/pkg/intl", + "sha256": "5d65e3808ce40e6282e40881492607df4e35669f", + "url": "https://dart.googlesource.com/intl.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/lints", + "sha256": "e1d4794412aacd3bbb370956d44b9a10c3f892f3", + "url": "https://dart.googlesource.com/lints.git" + }, + { + "kind": "git", + "path": "third_party/pkg/markdown", + "sha256": "4d5dbc659955973902f2585c54e94d453532db70", + "url": "https://dart.googlesource.com/markdown.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "028f89d4a59448f9ecda5bd3d4519e2d7c742072", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/package_config", + "sha256": "76f2f6c245451da1fa24d7bbb00251b909e729a5", + "url": "https://dart.googlesource.com/package_config.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pool", + "sha256": "f85209d83cb0aa3c5612ed80de32df51ba580abd", + "url": "https://dart.googlesource.com/pool.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "da7279c56734cffed4deb1e3a6f93bdcefccf6b8", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "30bfc439fedba1ee3daadcf542f1483479bc4909", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub_semver", + "sha256": "8e9fcb9d3f89f06022387f906da4d380688f935c", + "url": "https://dart.googlesource.com/pub_semver.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "2b5b683e78f5cc84e479a43297fd7b5489d7db02", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_maps", + "sha256": "198d32bbde2f5736c04dfbab306a17096fd1648b", + "url": "https://dart.googlesource.com/source_maps.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_span", + "sha256": "22a243eb50d926935a8a1300a49af6d2988c3ae6", + "url": "https://dart.googlesource.com/source_span.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sse", + "sha256": "b97dc3ad9a58a454dc5ffe5b3ec814dadc389e32", + "url": "https://dart.googlesource.com/sse.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stack_trace", + "sha256": "b660cfa444d46bcceb3a0eacbd6a2a7829da11de", + "url": "https://dart.googlesource.com/stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stream_channel", + "sha256": "71fe6dd315e7f451466da80f7af2661cd28aaaea", + "url": "https://dart.googlesource.com/stream_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/string_scanner", + "sha256": "77de235c061a09264cae920e52939787325c8cae", + "url": "https://dart.googlesource.com/string_scanner.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "47e6b264a209d0d806cfe9cdad8b6c69ce231986", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/term_glyph", + "sha256": "9ed8ed96fdd84cb7b72ee1be3e86010969fa95d4", + "url": "https://dart.googlesource.com/term_glyph.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "20967732ea9dd30240a6429621ab2f82874bd9f0", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_descriptor", + "sha256": "408526a84e74d7af0f9c8c3fbb49ce9178927ee0", + "url": "https://dart.googlesource.com/test_descriptor.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_process", + "sha256": "5b0349ca18fe48cd527f74ac883db2964cbdba40", + "url": "https://dart.googlesource.com/test_process.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_reflective_loader", + "sha256": "faade6299d1823f0d062eb5e98f3b440ddcea7c6", + "url": "https://dart.googlesource.com/test_reflective_loader.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "1c5b8b949128d62182e162ef65a2e6f3feb19acf", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "433fb6c829b18719fd0db4a703b607a26b7d81f4", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/watcher", + "sha256": "bc44e6f6b85972e516c44b9ae6c042b4cbd7c72b", + "url": "https://dart.googlesource.com/watcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "bdf112ec64d28285cc29c6c78274ff3a827bb79b", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web_socket_channel", + "sha256": "7a2039fd7c4c656ab27850926f89103b5f188dab", + "url": "https://dart.googlesource.com/web_socket_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "5f30c560dc4e3df341356c43ec1a766ee6b74a7c", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "d83d6a3cbaab152ff9b99b29382d1f48b5d5ba23", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "effa75205516757795683d527c3dea9546eb0c32", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml", + "sha256": "2a3727288a9336b6f9b7c5236657414ce1ee5d8a", + "url": "https://dart.googlesource.com/yaml.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml_edit", + "sha256": "fbdc70acc164af187772e013a2e1364cd05b88dc", + "url": "https://dart.googlesource.com/yaml_edit.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.7.0-27.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.7.0-224.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:cd third_party/boringssl && python3 src/util/generate_build_files.py gn", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.7.0-232.0.dev.json b/packages/native/dart@3.7.0-232.0.dev.json new file mode 100644 index 0000000..d110b33 --- /dev/null +++ b/packages/native/dart@3.7.0-232.0.dev.json @@ -0,0 +1,406 @@ +{ + "package": "native/dart@3.7.0-232.0.dev", + "version": "3.7.0-232.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "a8bfb132c5f7b9555d13ea79eaf0eaa77825824d", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "2424cfed7eedf53a122f8bfdbb6319692f726ec8", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "87f9dac127b387715d8d96ac7ec8fd469d8c2dab", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "7322fc15cc065d8d2957fccce6b62a509dc4d641", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "822902749a5956bba09c7e9e451104e8a74f02c5", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/core", + "sha256": "7a71ad6b9170e09d5cbe39f3fccdee648659f1e7", + "url": "https://dart.googlesource.com/core.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "21de99ec0ff8ace4d946a746fb427fffd6afa535", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "c7f11603effa88ddacabfd555993f322fca8b3fe", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "efe4ee4af6ac2e4c90aa525fae213b65c97295a9", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/glob", + "sha256": "eee18d1a577d5f965f6afbbd251798e065dced43", + "url": "https://dart.googlesource.com/glob.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "6ecd13a88b82c2fdc8a555f218bafb0ad0370f51", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/intl", + "sha256": "5d65e3808ce40e6282e40881492607df4e35669f", + "url": "https://dart.googlesource.com/intl.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/markdown", + "sha256": "19aaded4300d24bedcbf52ade792b203ddf030b0", + "url": "https://dart.googlesource.com/markdown.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "14368a80bae9e3f381a2e59c91405338d82451ee", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/package_config", + "sha256": "07097d7ae60d40b34ce8daabdce318ecc168b7d1", + "url": "https://dart.googlesource.com/package_config.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pool", + "sha256": "bf27900420ba382b6e5c0484ab3c79daad703dcd", + "url": "https://dart.googlesource.com/pool.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "b7dd58cdbd879beee4c3fbf8ee80fce8e97bad26", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "58de642dc1d07601f6eb2b4ecd94555c0210106b", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub_semver", + "sha256": "960f91309e325ae037e5f1434acb77b83a12d91e", + "url": "https://dart.googlesource.com/pub_semver.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "2b5b683e78f5cc84e479a43297fd7b5489d7db02", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_maps", + "sha256": "e5e9d343302acf7df2145316ae4e56026c550989", + "url": "https://dart.googlesource.com/source_maps.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_span", + "sha256": "e6a34591b7f7880c7ca0fcb95b858ccf7f8be304", + "url": "https://dart.googlesource.com/source_span.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sse", + "sha256": "b573a1e9a61f5f3e2198becfa3f4f2e8decd1e90", + "url": "https://dart.googlesource.com/sse.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stack_trace", + "sha256": "5fe4cfea7f0d8e67b7d5738d2e1c64a18b5ba450", + "url": "https://dart.googlesource.com/stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stream_channel", + "sha256": "31a3aba8a78a78b266fbf7474f19cd4ba9ca562e", + "url": "https://dart.googlesource.com/stream_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/string_scanner", + "sha256": "69212690d491603a511904a7a84cd502f34bf7a9", + "url": "https://dart.googlesource.com/string_scanner.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "47e6b264a209d0d806cfe9cdad8b6c69ce231986", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/term_glyph", + "sha256": "52677db71a2c6b6d0018ebbe5ed7552dbae1248f", + "url": "https://dart.googlesource.com/term_glyph.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "f364fc8291d668d85c702a5b9f9a4f2e5c1ade0e", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_descriptor", + "sha256": "92fa0c551267b38e4b27c9f74976ae4cd96d8b1e", + "url": "https://dart.googlesource.com/test_descriptor.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_reflective_loader", + "sha256": "9e35c9e00b8b6299e9295c0f29617af39276717d", + "url": "https://dart.googlesource.com/test_reflective_loader.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "b412ba4550bb634caf3c1064b7ebb671cd5e9247", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "bd4b574b2a457a3955d223694f1a979a0c0f38c9", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/watcher", + "sha256": "7f3b3a3ea49ba7e21fff240ce8ee616d62d32956", + "url": "https://dart.googlesource.com/watcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "af5de5e8548060c0795713ee7129ba6d5ff9f1b2", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web_socket_channel", + "sha256": "a937243563e8ee75d11fb23610297d4f6e5cb2b9", + "url": "https://dart.googlesource.com/web_socket_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "e72f365a4408dce73bc023e624adc6a9a72dd7a2", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "d83d6a3cbaab152ff9b99b29382d1f48b5d5ba23", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "effa75205516757795683d527c3dea9546eb0c32", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml", + "sha256": "0406507fb719b0c8787896475734747fa35f2b78", + "url": "https://dart.googlesource.com/yaml.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml_edit", + "sha256": "fbdc70acc164af187772e013a2e1364cd05b88dc", + "url": "https://dart.googlesource.com/yaml_edit.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.7.0-224.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.7.0-232.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:cd third_party/boringssl && python3 src/util/generate_build_files.py gn", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.7.0-27.0.dev.json b/packages/native/dart@3.7.0-27.0.dev.json new file mode 100644 index 0000000..4b01f37 --- /dev/null +++ b/packages/native/dart@3.7.0-27.0.dev.json @@ -0,0 +1,550 @@ +{ + "package": "native/dart@3.7.0-27.0.dev", + "version": "3.7.0-27.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "7fce3544047c41018b8c00b4453c0262f463dd74", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "dd66678fea1d11bc6295a688ed5f8e726034f762", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "93883fde36ac158fd415dcd6dbd387dcfd928d3c", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "fef055e8d2749b82c79c8f043be1cbe5e8e4b40c", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "2db0eb3f96a5756298dcd7f9319e56a98585bd10", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/args", + "sha256": "09c0fca1785c9df39288a48f767994eed80bed40", + "url": "https://dart.googlesource.com/args.git" + }, + { + "kind": "git", + "path": "third_party/pkg/async", + "sha256": "5f70a996f673d625e3502597084653686c3e754c", + "url": "https://dart.googlesource.com/async.git" + }, + { + "kind": "git", + "path": "third_party/pkg/bazel_worker", + "sha256": "aa3cc9e826350b960e0c5a67e6065bcedba8b0ac", + "url": "https://dart.googlesource.com/bazel_worker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/benchmark_harness", + "sha256": "44f125ae1d045aa3de09fe88a8dd70cb7352d563", + "url": "https://dart.googlesource.com/benchmark_harness.git" + }, + { + "kind": "git", + "path": "third_party/pkg/boolean_selector", + "sha256": "d6c7c36ae1111f11cc24306d71d3ab2deea8fa68", + "url": "https://dart.googlesource.com/boolean_selector.git" + }, + { + "kind": "git", + "path": "third_party/pkg/browser_launcher", + "sha256": "e5fc5d488eb5038bfec2a6690c72ab8dd353e101", + "url": "https://dart.googlesource.com/browser_launcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/cli_util", + "sha256": "c36b3941e38092d6d6f87ac27d9e88f153d3ac38", + "url": "https://dart.googlesource.com/cli_util.git" + }, + { + "kind": "git", + "path": "third_party/pkg/clock", + "sha256": "7956d60042f4ea979c4554d43eeb57d087627869", + "url": "https://dart.googlesource.com/clock.git" + }, + { + "kind": "git", + "path": "third_party/pkg/collection", + "sha256": "887b826b50f48d6a9cd2c0684aa353e8e3a0fad0", + "url": "https://dart.googlesource.com/collection.git" + }, + { + "kind": "git", + "path": "third_party/pkg/convert", + "sha256": "d361833e117cb2438d2a2a6d0b0acb28ff0910fb", + "url": "https://dart.googlesource.com/convert.git" + }, + { + "kind": "git", + "path": "third_party/pkg/crypto", + "sha256": "3d26ef4cf22d4b218ba30e616544ad3cf52f64a1", + "url": "https://dart.googlesource.com/crypto.git" + }, + { + "kind": "git", + "path": "third_party/pkg/csslib", + "sha256": "a3700b05bbcc42782e8a7024790dbf019d89c249", + "url": "https://dart.googlesource.com/csslib.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "5d35f4d829ffb8532d345d95d3e9504ae6cd839e", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "80c6f18f34b387d4b9ce89ddd2e3049093335f9d", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "2d58550f9e3fd8ecbc3b2e4444095fcb204a66c6", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/file", + "sha256": "6842feaef1c4e06239bd30f8d3ef722838b1c97e", + "url": "https://dart.googlesource.com/external/github.com/google/file.dart" + }, + { + "kind": "git", + "path": "third_party/pkg/fixnum", + "sha256": "83293b8ed86ccd574a94fcf4a2da43f31c1b43e0", + "url": "https://dart.googlesource.com/fixnum.git" + }, + { + "kind": "git", + "path": "third_party/pkg/glob", + "sha256": "00a9c82d31c01ae88ec9ae4021d842e9b832aa52", + "url": "https://dart.googlesource.com/glob.git" + }, + { + "kind": "git", + "path": "third_party/pkg/html", + "sha256": "6d3bc86cf2ab530ef3fa5f84b5980dc318a02af4", + "url": "https://dart.googlesource.com/html.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "f59cd79e1322c6272481e4f2ccfa9afcb37a6525", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_multi_server", + "sha256": "e7515b5896b83d522189802a1e14e103e19426c0", + "url": "https://dart.googlesource.com/http_multi_server.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http_parser", + "sha256": "23d775898ee90be9daf3297e298a8869bc755d84", + "url": "https://dart.googlesource.com/http_parser.git" + }, + { + "kind": "git", + "path": "third_party/pkg/intl", + "sha256": "5d65e3808ce40e6282e40881492607df4e35669f", + "url": "https://dart.googlesource.com/intl.git" + }, + { + "kind": "git", + "path": "third_party/pkg/json_rpc_2", + "sha256": "c9b616bded8cdb5bfdc836ba7648afa6aba40062", + "url": "https://dart.googlesource.com/json_rpc_2.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/lints", + "sha256": "5016d63c889936b2100520f999591d0492d9afe3", + "url": "https://dart.googlesource.com/lints.git" + }, + { + "kind": "git", + "path": "third_party/pkg/logging", + "sha256": "6fa056098ceca03d399bff64592822b2ae5dee6e", + "url": "https://dart.googlesource.com/logging.git" + }, + { + "kind": "git", + "path": "third_party/pkg/markdown", + "sha256": "d53feae0760a4f0aae5ffdfb12d8e6acccf14b40", + "url": "https://dart.googlesource.com/markdown.git" + }, + { + "kind": "git", + "path": "third_party/pkg/matcher", + "sha256": "31f13583630e093731c8cf2b843c14196d748c5c", + "url": "https://dart.googlesource.com/matcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/mockito", + "sha256": "57d484f9b8e7f6a504966a901174358a42fa932a", + "url": "https://dart.googlesource.com/mockito.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "659511886501bcce638c3966590df04984909ef0", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/package_config", + "sha256": "bafff8e90be25e1985f7e3ee40ea1d22571a93e6", + "url": "https://dart.googlesource.com/package_config.git" + }, + { + "kind": "git", + "path": "third_party/pkg/path", + "sha256": "e969f42ed112dd702a9453beb9df6c12ae2d3805", + "url": "https://dart.googlesource.com/path.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pool", + "sha256": "7bfc71b39742753a88688e56e55a828a2f5dc0bf", + "url": "https://dart.googlesource.com/pool.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "ccf104dbc36929c0f8708285d5f3a8fae206343e", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "1efd3f5e274e153637d99698b0ee454f6f2550ab", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub_semver", + "sha256": "8cce9d00431b6653026cdfcf6cf8548078c56f02", + "url": "https://dart.googlesource.com/pub_semver.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "f5600534e3e49ebed02e1e14ec82553958d86f36", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_maps", + "sha256": "17695e81d9ad129d20effd3d5c4f1cfa03f5add8", + "url": "https://dart.googlesource.com/source_maps.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_span", + "sha256": "ec100b7f12e9d36d2cdb3c369fefde736de4a550", + "url": "https://dart.googlesource.com/source_span.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sse", + "sha256": "af2c5c572a8da6d2f7551b80d75121f2a38a4c79", + "url": "https://dart.googlesource.com/sse.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stack_trace", + "sha256": "115bcd9591d251dab7a5ad518655c2124a1cc525", + "url": "https://dart.googlesource.com/stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stream_channel", + "sha256": "f4407168b275fcde9187baefd7dbce76d0992825", + "url": "https://dart.googlesource.com/stream_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/string_scanner", + "sha256": "084b201c54b168aced178fff41fce71e3869ae42", + "url": "https://dart.googlesource.com/string_scanner.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "91c0dd5ef9a008f0277aadcfd83036f82e572d09", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/term_glyph", + "sha256": "19d8c08a4e81122639129c62049896021910c932", + "url": "https://dart.googlesource.com/term_glyph.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "8e8a83607d90a7a6813fa378b2d1962a2fc0d44b", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_descriptor", + "sha256": "a3db1efe3dc725dcae9ee61647d3bfc19b3231ac", + "url": "https://dart.googlesource.com/test_descriptor.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_process", + "sha256": "52ee3f5ab70ed965bb7122c1d499081fbccd0bde", + "url": "https://dart.googlesource.com/test_process.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_reflective_loader", + "sha256": "598af2f503955020af0eaa82558d574a03934078", + "url": "https://dart.googlesource.com/test_reflective_loader.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "f882de9ba86712003728d4663e1b73a620d352b1", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/typed_data", + "sha256": "6abfafdcf661cd8a814619d7e2a3e99edb3a3862", + "url": "https://dart.googlesource.com/typed_data.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "2cfbe2c115a57b368ccbc3c89ebd38a06764d3d1", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/watcher", + "sha256": "3b850778ad0b62db3aa2cfe48832870c2461db30", + "url": "https://dart.googlesource.com/watcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "8478cd27d574249eca3d41f9135458dfda2762c8", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web_socket_channel", + "sha256": "40aa29f1d2167467f5934d755891a8beb62a1239", + "url": "https://dart.googlesource.com/web_socket_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "5f30c560dc4e3df341356c43ec1a766ee6b74a7c", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "accfed557c005c87df56ffb626458f87da9f2125", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "b459c427b74bf5e0919a083a97a167fb74d8bff1", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml", + "sha256": "e773005ab84e1b4d24132b0a687be7f9a3bfda15", + "url": "https://dart.googlesource.com/yaml.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml_edit", + "sha256": "35f4248c7bbba289b3899fa55486e2f31ef1a8c5", + "url": "https://dart.googlesource.com/yaml_edit.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.6.0-2.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.7.0-27.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:cd third_party/boringssl && python3 src/util/generate_build_files.py gn", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.7.0.json b/packages/native/dart@3.7.0.json new file mode 100644 index 0000000..0a5f9b6 --- /dev/null +++ b/packages/native/dart@3.7.0.json @@ -0,0 +1,406 @@ +{ + "package": "native/dart@3.7.0", + "version": "3.7.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "a8bfb132c5f7b9555d13ea79eaf0eaa77825824d", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "2424cfed7eedf53a122f8bfdbb6319692f726ec8", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "87f9dac127b387715d8d96ac7ec8fd469d8c2dab", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "7322fc15cc065d8d2957fccce6b62a509dc4d641", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "822902749a5956bba09c7e9e451104e8a74f02c5", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/core", + "sha256": "7a71ad6b9170e09d5cbe39f3fccdee648659f1e7", + "url": "https://dart.googlesource.com/core.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "21de99ec0ff8ace4d946a746fb427fffd6afa535", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "c7f11603effa88ddacabfd555993f322fca8b3fe", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "efe4ee4af6ac2e4c90aa525fae213b65c97295a9", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/glob", + "sha256": "eee18d1a577d5f965f6afbbd251798e065dced43", + "url": "https://dart.googlesource.com/glob.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "6ecd13a88b82c2fdc8a555f218bafb0ad0370f51", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/intl", + "sha256": "5d65e3808ce40e6282e40881492607df4e35669f", + "url": "https://dart.googlesource.com/intl.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/markdown", + "sha256": "19aaded4300d24bedcbf52ade792b203ddf030b0", + "url": "https://dart.googlesource.com/markdown.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "14368a80bae9e3f381a2e59c91405338d82451ee", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/package_config", + "sha256": "07097d7ae60d40b34ce8daabdce318ecc168b7d1", + "url": "https://dart.googlesource.com/package_config.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pool", + "sha256": "bf27900420ba382b6e5c0484ab3c79daad703dcd", + "url": "https://dart.googlesource.com/pool.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "b7dd58cdbd879beee4c3fbf8ee80fce8e97bad26", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "58de642dc1d07601f6eb2b4ecd94555c0210106b", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub_semver", + "sha256": "960f91309e325ae037e5f1434acb77b83a12d91e", + "url": "https://dart.googlesource.com/pub_semver.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "2b5b683e78f5cc84e479a43297fd7b5489d7db02", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_maps", + "sha256": "e5e9d343302acf7df2145316ae4e56026c550989", + "url": "https://dart.googlesource.com/source_maps.git" + }, + { + "kind": "git", + "path": "third_party/pkg/source_span", + "sha256": "e6a34591b7f7880c7ca0fcb95b858ccf7f8be304", + "url": "https://dart.googlesource.com/source_span.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sse", + "sha256": "b573a1e9a61f5f3e2198becfa3f4f2e8decd1e90", + "url": "https://dart.googlesource.com/sse.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stack_trace", + "sha256": "5fe4cfea7f0d8e67b7d5738d2e1c64a18b5ba450", + "url": "https://dart.googlesource.com/stack_trace.git" + }, + { + "kind": "git", + "path": "third_party/pkg/stream_channel", + "sha256": "31a3aba8a78a78b266fbf7474f19cd4ba9ca562e", + "url": "https://dart.googlesource.com/stream_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/string_scanner", + "sha256": "69212690d491603a511904a7a84cd502f34bf7a9", + "url": "https://dart.googlesource.com/string_scanner.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "47e6b264a209d0d806cfe9cdad8b6c69ce231986", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/term_glyph", + "sha256": "52677db71a2c6b6d0018ebbe5ed7552dbae1248f", + "url": "https://dart.googlesource.com/term_glyph.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "f364fc8291d668d85c702a5b9f9a4f2e5c1ade0e", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_descriptor", + "sha256": "92fa0c551267b38e4b27c9f74976ae4cd96d8b1e", + "url": "https://dart.googlesource.com/test_descriptor.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test_reflective_loader", + "sha256": "9e35c9e00b8b6299e9295c0f29617af39276717d", + "url": "https://dart.googlesource.com/test_reflective_loader.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "b412ba4550bb634caf3c1064b7ebb671cd5e9247", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "bd4b574b2a457a3955d223694f1a979a0c0f38c9", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/watcher", + "sha256": "7f3b3a3ea49ba7e21fff240ce8ee616d62d32956", + "url": "https://dart.googlesource.com/watcher.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "af5de5e8548060c0795713ee7129ba6d5ff9f1b2", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web_socket_channel", + "sha256": "a937243563e8ee75d11fb23610297d4f6e5cb2b9", + "url": "https://dart.googlesource.com/web_socket_channel.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "e72f365a4408dce73bc023e624adc6a9a72dd7a2", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "d83d6a3cbaab152ff9b99b29382d1f48b5d5ba23", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "effa75205516757795683d527c3dea9546eb0c32", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml", + "sha256": "0406507fb719b0c8787896475734747fa35f2b78", + "url": "https://dart.googlesource.com/yaml.git" + }, + { + "kind": "git", + "path": "third_party/pkg/yaml_edit", + "sha256": "fbdc70acc164af187772e013a2e1364cd05b88dc", + "url": "https://dart.googlesource.com/yaml_edit.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.7.0-232.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.7.0 > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:cd third_party/boringssl && python3 src/util/generate_build_files.py gn", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.8.0-171.0.dev.json b/packages/native/dart@3.8.0-171.0.dev.json new file mode 100644 index 0000000..2e4f6ea --- /dev/null +++ b/packages/native/dart@3.8.0-171.0.dev.json @@ -0,0 +1,298 @@ +{ + "package": "native/dart@3.8.0-171.0.dev", + "version": "3.8.0-171.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "2d5dfe32cf2e6b3c3d6b396885502a5402b4fc72", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "d285ef839784162ca988a9d149522249d0c00c5c", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "3f6831c0bd147ae1ae0ab1d9187d37bce7cca38b", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "7322fc15cc065d8d2957fccce6b62a509dc4d641", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "5e73d0302c50cc38324686f937a75233d13ae4f0", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/core", + "sha256": "15c7fe9958b95998ba2f5a4ad1beab66b9d815fb", + "url": "https://dart.googlesource.com/core.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "21de99ec0ff8ace4d946a746fb427fffd6afa535", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "34561d6ebf5fa89ca1f93b981de96a75ff573562", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "06bbbffc1dae26164ee0a9603d0a30af620b84d0", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "900da9fe7d576caa4882053cf26d3a70bd3106e0", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/i18n", + "sha256": "06a664f7beaab1f8eaf82a60b722982c03c8657c", + "url": "https://dart.googlesource.com/i18n.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "f08677646f9e5e9a8a233fed1ec324a003609260", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "610943a3bed70c1c2079af5fca02462df10d223f", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "639536aa78f7382b4a948669bfdc283f830b2ae9", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "b39e61196ce555dc1d3a0c3da695228fa6bdebb8", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "47e6b264a209d0d806cfe9cdad8b6c69ce231986", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "a833663e56b6182f8372180f5c95d1c01b531150", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "b51f39d01f5a4af33428a0189cd62595c01e23de", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "533c513771d35312dcd0f69e662d729979882df1", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "c2d5f63e9ea4c1409d6e159fc7b92dbcf4dc0d4d", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "f4856867de3e7b6ea6778dbc47cff44b12f9eed2", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "b4fd8592fb9b1405fea3979cab88bcd857f2addb", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "effa75205516757795683d527c3dea9546eb0c32", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.7.0", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.8.0-171.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:cd third_party/boringssl && python3 src/util/generate_build_files.py gn", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.8.0-237.0.dev.json b/packages/native/dart@3.8.0-237.0.dev.json new file mode 100644 index 0000000..985e490 --- /dev/null +++ b/packages/native/dart@3.8.0-237.0.dev.json @@ -0,0 +1,298 @@ +{ + "package": "native/dart@3.8.0-237.0.dev", + "version": "3.8.0-237.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "4a4ff9fba9ca67e9406743a24a3c47ad64d9e9c2", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "7e4321a5cb2d8fcf9c3c818e62ef6d6f4fd87626", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "b4bdcc33115b31758c56b83bb9de4642c411a042", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "7322fc15cc065d8d2957fccce6b62a509dc4d641", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "02f0d8776ecd83a1c663db2eaba6283aa72cc5b8", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/core", + "sha256": "61e677100b06d56a1b3731ab1178ebf9102ecb1f", + "url": "https://dart.googlesource.com/core.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "21de99ec0ff8ace4d946a746fb427fffd6afa535", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "d40067626b8c419e451897447e4dae74d25bcc37", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "23172636e60c52384b40e6bd1240d12c8e860122", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "1b6e28d7e1c61f7b0f8561be7aee9c35b03de193", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/i18n", + "sha256": "d9cce0b6348b51872fb269e43ff8a43120fe191d", + "url": "https://dart.googlesource.com/i18n.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "f1fa5be4b0d7449fa8fe4077113ac0413d2b16bf", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "0bab78d9538e49d50023bab36159b15ff3c369eb", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "b2c03b448a47fdd52800609b9222cd737be3a934", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "2af8529640d10a247ebfa4e17e629a2ff5273656", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "dc54465f07d9652875deeade643256dafa2fbc6c", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "9e349d0e9f6c477584ea320f7ba2f49f761d84ac", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "62bc13bc086a66ce9a6a3e64865c82d17a1379b3", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "f08d7d2652e9ecf7d8f8605d9983335174511c95", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "5a39fdc396ae40344308975140343c23b6863261", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "302b6db6125901fd183390e339aff7490cdde3d0", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "f52afbf72895ae980bd4129d877305c2182d6cbc", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "effa75205516757795683d527c3dea9546eb0c32", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.8.0-171.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.8.0-237.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:cd third_party/boringssl && python3 src/util/generate_build_files.py gn", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.9.0-27.0.dev.json b/packages/native/dart@3.9.0-27.0.dev.json new file mode 100644 index 0000000..caf63b9 --- /dev/null +++ b/packages/native/dart@3.9.0-27.0.dev.json @@ -0,0 +1,304 @@ +{ + "package": "native/dart@3.9.0-27.0.dev", + "version": "3.9.0-27.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "4bb26ad346b166d759773e01ffc8247893b9681e", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "4ebc13c27af77129889a11fd1f95cff04dccd8f9", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "b4bdcc33115b31758c56b83bb9de4642c411a042", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "7322fc15cc065d8d2957fccce6b62a509dc4d641", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "ef839bf397fb4ecdb66ef2679a08ac7b3563c50b", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libc", + "sha256": "5af39a19a1ad51ce93972cdab206dcd3ff9b6afa", + "url": "https://llvm.googlesource.com/llvm-project/libc" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "bd557f6f764d1e40b62528a13b124ce740624f8f", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "a4dda1589d37a7e4b4f7a81ebad01b1083f2e726", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/core", + "sha256": "635dfa32c261ba078438b74de397f2207904ca78", + "url": "https://dart.googlesource.com/core.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "100db45075abdd66fd8788b205243e90ff0595df", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "62aefbb788baf5b73b2d704d66d9735a7ca56a69", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "815d4ba2e7d11f8695a26f6cbe1262e3b8ff8d0d", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "e4ddd3e3d3a3d0ba7c9e48506e9d2e8620af30a8", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/i18n", + "sha256": "de1943629469719bf34269bf90fcdbe9334a73f3", + "url": "https://dart.googlesource.com/i18n.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "49a8912734162e5dc6ad009fc080fe54e9985470", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "1aaa332af75c61ff32739821f7ec52186ff18d4c", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "b2c03b448a47fdd52800609b9222cd737be3a934", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "082d3ac2d13a98700d8148e8fad8f3e12a6fd0e1", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "dc54465f07d9652875deeade643256dafa2fbc6c", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "84eba115521b74e848f096572a2d3e4d3607e8fa", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "4a284152c263a5d3429d5ab6acfdb70eca2ebcfb", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "dc9d379674f50bb5559e99ee3a9f64729df9d3c8", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "5a39fdc396ae40344308975140343c23b6863261", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "5bf833d0c277a384ab8bbfc10e7d3d71b8022560", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "f52afbf72895ae980bd4129d877305c2182d6cbc", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "effa75205516757795683d527c3dea9546eb0c32", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.9.0-3.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.9.0-27.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:cd third_party/boringssl && python3 src/util/generate_build_files.py gn", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.9.0-3.0.dev.json b/packages/native/dart@3.9.0-3.0.dev.json new file mode 100644 index 0000000..bcadb8c --- /dev/null +++ b/packages/native/dart@3.9.0-3.0.dev.json @@ -0,0 +1,304 @@ +{ + "package": "native/dart@3.9.0-3.0.dev", + "version": "3.9.0-3.0.dev", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "5a8921e0042c662ea2adbac35ea051dec20a5341", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "2c7f9a6a379cfc49b3e9019d1f616d7ec9edd766", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "b4bdcc33115b31758c56b83bb9de4642c411a042", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl", + "sha256": "7322fc15cc065d8d2957fccce6b62a509dc4d641", + "url": "https://dart.googlesource.com/boringssl_gen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "d5440dd2c2c500ac2d3bba4afec47a054b4d99ae", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libc", + "sha256": "5af39a19a1ad51ce93972cdab206dcd3ff9b6afa", + "url": "https://llvm.googlesource.com/llvm-project/libc" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "bd557f6f764d1e40b62528a13b124ce740624f8f", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "a4dda1589d37a7e4b4f7a81ebad01b1083f2e726", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/core", + "sha256": "635dfa32c261ba078438b74de397f2207904ca78", + "url": "https://dart.googlesource.com/core.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "21de99ec0ff8ace4d946a746fb427fffd6afa535", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "62aefbb788baf5b73b2d704d66d9735a7ca56a69", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "7f6f1c1d53173307bde1aa4f4ee851d260cc7e69", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "e4ddd3e3d3a3d0ba7c9e48506e9d2e8620af30a8", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/i18n", + "sha256": "de1943629469719bf34269bf90fcdbe9334a73f3", + "url": "https://dart.googlesource.com/i18n.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "4e71c281e4e3c262b28b7ab5b3306e4029b78b1c", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "1aaa332af75c61ff32739821f7ec52186ff18d4c", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "b2c03b448a47fdd52800609b9222cd737be3a934", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "082d3ac2d13a98700d8148e8fad8f3e12a6fd0e1", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "dc54465f07d9652875deeade643256dafa2fbc6c", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "8643fbf375330cd1099cdc7434306532b4bcaaf1", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "d74f9e13dc02736f12ae57d5984c57024113cf5a", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "f08d7d2652e9ecf7d8f8605d9983335174511c95", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "5a39fdc396ae40344308975140343c23b6863261", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "c8b1cfa9d12c680b612eb1ed7a6b9f99fcce3ac3", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "f52afbf72895ae980bd4129d877305c2182d6cbc", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "effa75205516757795683d527c3dea9546eb0c32", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "108fa50cda23ed4a712a098d058dccbbfd248206", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.8.0-237.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.9.0-3.0.dev > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:cd third_party/boringssl && python3 src/util/generate_build_files.py gn", + "*:*:sed -i.bak 's/-std=c++14/-std=c++17/g' ./third_party/boringssl/BUILD.gn", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/dart@3.9.4.json b/packages/native/dart@3.9.4.json new file mode 100644 index 0000000..1872aeb --- /dev/null +++ b/packages/native/dart@3.9.4.json @@ -0,0 +1,302 @@ +{ + "package": "native/dart@3.9.4", + "version": "3.9.4", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "2f5a888a5e6a7316074416822a9584d54e3f5ab5", + "url": "https://dart.googlesource.com/sdk.git" + }, + { + "kind": "git", + "path": "build/secondary/third_party/protobuf", + "sha256": "ca669f79945418f6229e4fef89b666b2a88cbb10", + "url": "https://fuchsia.googlesource.com/protobuf-gn" + }, + { + "kind": "git", + "path": "tests/co19/src", + "sha256": "a5d7b62b78dd9278c30a44cb2d22b8870b360a0e", + "url": "https://dart.googlesource.com/co19" + }, + { + "kind": "git", + "path": "third_party/WebCore", + "sha256": "bcb10901266c884e7b3740abc597ab95373ab55c", + "url": "https://dart.googlesource.com/webcore.git" + }, + { + "kind": "git", + "path": "third_party/binaryen/src", + "sha256": "8470f1b1f157201d1bc62f3202e474e7043df0ba", + "url": "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git" + }, + { + "kind": "git", + "path": "third_party/boringssl/src", + "sha256": "be5be0a4f5ebf00da151a06860deb11a0ffb609f", + "url": "https://boringssl.googlesource.com/boringssl.git" + }, + { + "kind": "git", + "path": "third_party/cpu_features/src", + "sha256": "936b9ab5515dead115606559502e3864958f7f6e", + "url": "https://chromium.googlesource.com/external/github.com/google/cpu_features.git" + }, + { + "kind": "git", + "path": "third_party/emsdk", + "sha256": "e41b8c68a248da5f18ebd03bd0420953945d52ff", + "url": "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git" + }, + { + "kind": "git", + "path": "third_party/icu", + "sha256": "43953f57b037778a1b8005564afabe214834f7bd", + "url": "https://chromium.googlesource.com/chromium/deps/icu.git" + }, + { + "kind": "git", + "path": "third_party/jinja2", + "sha256": "2222b31554f03e62600cd7e383376a7c187967a1", + "url": "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git" + }, + { + "kind": "git", + "path": "third_party/libc", + "sha256": "5af39a19a1ad51ce93972cdab206dcd3ff9b6afa", + "url": "https://llvm.googlesource.com/llvm-project/libc" + }, + { + "kind": "git", + "path": "third_party/libcxx", + "sha256": "bd557f6f764d1e40b62528a13b124ce740624f8f", + "url": "https://llvm.googlesource.com/llvm-project/libcxx" + }, + { + "kind": "git", + "path": "third_party/libcxxabi", + "sha256": "a4dda1589d37a7e4b4f7a81ebad01b1083f2e726", + "url": "https://llvm.googlesource.com/llvm-project/libcxxabi" + }, + { + "kind": "git", + "path": "third_party/markupsafe", + "sha256": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783", + "url": "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git" + }, + { + "kind": "git", + "path": "third_party/mdn/browser-compat-data/src", + "sha256": "ac8cae697014da1ff7124fba33b0b4245cc6cd1b", + "url": "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data" + }, + { + "kind": "git", + "path": "third_party/perfetto", + "sha256": "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b", + "url": "https://android.googlesource.com/platform/external/perfetto" + }, + { + "kind": "git", + "path": "third_party/pkg/ai", + "sha256": "64dfa7f138aa4d9bcc06e807858136b7d4d296d3", + "url": "https://dart.googlesource.com/ai.git" + }, + { + "kind": "git", + "path": "third_party/pkg/core", + "sha256": "b59ecf4ceebe6153e1c0166b7c9a7fdd9458a89d", + "url": "https://dart.googlesource.com/core.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dart_style", + "sha256": "44e8cfe7ba5a873ef81b6b39c07d50171eccf021", + "url": "https://dart.googlesource.com/dart_style.git" + }, + { + "kind": "git", + "path": "third_party/pkg/dartdoc", + "sha256": "882aea9351262d618c955322f4c9aafe9540b848", + "url": "https://dart.googlesource.com/dartdoc.git" + }, + { + "kind": "git", + "path": "third_party/pkg/ecosystem", + "sha256": "d5233c6dd0767cffa5742e32c4bc7c230c9c4b12", + "url": "https://dart.googlesource.com/ecosystem.git" + }, + { + "kind": "git", + "path": "third_party/pkg/http", + "sha256": "7d2d87ebfba86035a9ca6b79160ccc2ac1253c0c", + "url": "https://dart.googlesource.com/http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/i18n", + "sha256": "c45e050426bdeaaa120e5ce856abb486863d0476", + "url": "https://dart.googlesource.com/i18n.git" + }, + { + "kind": "git", + "path": "third_party/pkg/leak_tracker", + "sha256": "f5620600a5ce1c44f65ddaa02001e200b096e14c", + "url": "https://dart.googlesource.com/leak_tracker.git" + }, + { + "kind": "git", + "path": "third_party/pkg/native", + "sha256": "723cd56a5edc89699db32bca1b5bf91aa0bcf0cf", + "url": "https://dart.googlesource.com/native.git" + }, + { + "kind": "git", + "path": "third_party/pkg/protobuf", + "sha256": "bce362dec347ae3cca085bd28db2aa2649f754e5", + "url": "https://dart.googlesource.com/protobuf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/pub", + "sha256": "52f512315bc886de487061091ef82056abf9dab8", + "url": "https://dart.googlesource.com/pub.git" + }, + { + "kind": "git", + "path": "third_party/pkg/shelf", + "sha256": "082d3ac2d13a98700d8148e8fad8f3e12a6fd0e1", + "url": "https://dart.googlesource.com/shelf.git" + }, + { + "kind": "git", + "path": "third_party/pkg/sync_http", + "sha256": "c07f96f89a7eec7e3daac641fa6c587224fcfbaa", + "url": "https://dart.googlesource.com/sync_http.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tar", + "sha256": "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a", + "url": "https://dart.googlesource.com/external/github.com/simolus3/tar.git" + }, + { + "kind": "git", + "path": "third_party/pkg/test", + "sha256": "2be5ca067bdf09e999be2ad760ab8efab854e789", + "url": "https://dart.googlesource.com/test.git" + }, + { + "kind": "git", + "path": "third_party/pkg/tools", + "sha256": "fd7cc89aaac774fb34502502803a3bcf62cb83cd", + "url": "https://dart.googlesource.com/tools.git" + }, + { + "kind": "git", + "path": "third_party/pkg/vector_math", + "sha256": "13f185f7e97d559e003f5ac79201da12f9a01049", + "url": "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/web", + "sha256": "354e22995859757223cea3fccbff0ad86c540d60", + "url": "https://dart.googlesource.com/web.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdev", + "sha256": "7f376d242709e933fff70610503d0c5c09b2e17e", + "url": "https://dart.googlesource.com/webdev.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webdriver", + "sha256": "cfab787b30fbfb5509f9fc45cfce51157fb9f369", + "url": "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git" + }, + { + "kind": "git", + "path": "third_party/pkg/webkit_inspection_protocol", + "sha256": "effa75205516757795683d527c3dea9546eb0c32", + "url": "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git" + }, + { + "kind": "git", + "path": "third_party/ply", + "sha256": "604b32590ffad5cbb82e4afef1d305512d06ae93", + "url": "https://chromium.googlesource.com/chromium/src/third_party/ply.git" + }, + { + "kind": "git", + "path": "third_party/protobuf", + "sha256": "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb", + "url": "https://fuchsia.googlesource.com/third_party/protobuf" + }, + { + "kind": "git", + "path": "third_party/zlib", + "sha256": "470d3a2ee4ef721688ce6961bc865a99fcb64070", + "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git" + }, + { + "kind": "tar.gz", + "path": "third_party/devtools/devtools_shared", + "sha256": "275e48a8a145fa09c7ae433a96fd433c01cc079d39b40acf5ba883236ae2c887", + "url": "https://pub.dev/api/archives/devtools_shared-12.0.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/dart@3.9.0-27.0.dev", + "*:*:native/gn", + "*:*:native/libc++", + "*:*:native/llvm-ar", + "*:*:native/llvm-nm", + "*:*:native/llvm-strip", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p buildtools/mac-x64/clang/.versions", + "*:*:mkdir -p buildtools/mac-arm64/clang/.versions", + "*:*:mkdir -p buildtools/linux-x64/clang/.versions", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-amd64\",\"instance_id\": \"AWO66yebzYxWzasSzjx1wmeozi-xq9r0RnNyEhKtwAIC\"}' > ./buildtools/mac-x64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/mac-arm64\",\"instance_id\": \"i41U-bFSUAOHPpKs_6lCF-EPqOLaa8LwT48ciXzHK3EC\"}' > ./buildtools/mac-arm64/clang/.versions/clang.cipd_version", + "*:*:echo '{\"package_name\": \"fuchsia/third_party/clang/linux-amd64\",\"instance_id\": \"-f7MR6VniTzxeWcp2k9ZkII4oK21j44tQvYuCBaHpqEC\"}' > ./buildtools/linux-x64/clang/.versions/clang.cipd_version", + "*:*:echo build_devtools_from_sources = false > build/config/gclient_args.gni", + "*:*:ln -s $(which gn) buildtools/gn", + "*:*:mkdir -p buildtools/ninja", + "*:*:ln -s $(which ninja) buildtools/ninja/ninja", + "*:*:mkdir -p buildtools/mac-arm64/clang/bin", + "*:*:mkdir -p buildtools/mac-arm64/clang/lib", + "*:*:ln -s $NATIVEPREFIX/lib/libc++.a buildtools/mac-arm64/clang/lib/libc++.a", + "*:*:ln -s $CC buildtools/mac-arm64/clang/bin/clang", + "*:*:ln -s $CXX buildtools/mac-arm64/clang/bin/clang++", + "*:*:ln -s $(which llvm-ar) buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:ln -s $(which llvm-nm) buildtools/mac-arm64/clang/bin/llvm-nm", + "*:*:ln -s $(which llvm-strip) buildtools/mac-arm64/clang/bin/llvm-strip", + "*:*:sed -i.bak 's/\"-Wno-dangling-reference\",/ /g' runtime/BUILD.gn", + "*:*:mkdir -p tools/sdks/dart-sdk/bin", + "*:*:ln -s $(which dart) tools/sdks/dart-sdk/bin/dart", + "*:*:chmod +x buildtools/mac-arm64/clang/bin/llvm-ar", + "*:*:python3 ./tools/generate_package_config.py # HOOK Generate the .dart_tool/package_confg.json file.", + "*:*:echo 3.9.4 > sdk/version", + "*:*:mkdir -p third_party/devtools/web", + "*:*:echo 'no devtools :(' > third_party/devtools/web/index.html", + "*:*:python3 ./tools/build.py --mode=product create_sdk", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/bin $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/include $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a $(find . -name dart-sdk | grep -v 'tools/sdks/dart-sdk')/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:$STAGING_DIR$NATIVEPREFIX/bin/dart --version" + ] + } +} \ No newline at end of file diff --git a/packages/native/diffutils.json b/packages/native/diffutils.json new file mode 100644 index 0000000..5f29420 --- /dev/null +++ b/packages/native/diffutils.json @@ -0,0 +1,33 @@ +{ + "package": "native/diffutils", + "version": "3.12", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "7c8b7f9fc8609141fdea9cece85249d308624391ff61dedaf528fcb337727dfd", + "url": "https://ftp.gnu.org/gnu/diffutils/diffutils-3.12.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/bash", + "*:*:native/libiconv", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:LIBS=-liconv", + "windows_*:*:config_opts=$config_opts gl_cv_have_weak=no" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "windows_*:*:bash $PATCH_DIR/native/_/drop-gnulib-wint-wrappers.sh", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/dpkg.json b/packages/native/dpkg.json new file mode 100644 index 0000000..3d884de --- /dev/null +++ b/packages/native/dpkg.json @@ -0,0 +1,39 @@ +{ + "package": "native/dpkg", + "version": "1.23.3", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "f3ad53337eaee92cbeb1a7c73e98d552c3a8186f", + "url": "https://git.dpkg.org/git/dpkg/dpkg.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/gettext", + "*:*:native/libmd", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/patch", + "*:*:native/perl", + "*:*:native/pkgconf", + "*:*:native/tar" + ], + "build": { + "env": [ + "*:*:config_opts=--host=$HOST --prefix=$NATIVEPREFIX", + "*:*:PERL_LIBDIR=$NATIVEPREFIX/lib/perl5/site_perl/5.42.0" + ], + "steps": [ + "*:*:git tag -a 1.23.3 -m 'Release 1.23.3'", + "*:*:./autogen", + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make install DESTDIR=$STAGING_DIR" + ] + } +} \ No newline at end of file diff --git a/packages/native/expat.json b/packages/native/expat.json new file mode 100644 index 0000000..88270c9 --- /dev/null +++ b/packages/native/expat.json @@ -0,0 +1,27 @@ +{ + "package": "native/expat", + "version": "2.6.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "a13447b9aa67d7c860783fdf6820f33ebdea996900d6d8bbc50a628f55f099f7", + "url": "http://github.com/libexpat/libexpat/releases/download/R_2_6_0/expat-2.6.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/libiconv", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [], + "steps": [ + "*:*:./configure --prefix=$NATIVEPREFIX --disable-shared --without-docbook --without-tests --without-examples --enable-option-checking --without-xmlwf --with-pic", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/filament-tools.json b/packages/native/filament-tools.json new file mode 100644 index 0000000..9bdc81e --- /dev/null +++ b/packages/native/filament-tools.json @@ -0,0 +1,41 @@ +{ + "package": "native/filament-tools", + "version": "v1.75.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "0e58877c09afb1aacd09ff640f74d2adcd2a7e80", + "url": "https://github.com/google/filament.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/coreutils", + "*:*:native/ninja", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:CXXFLAGS=$CXXFLAGS -Wno-error=shadow -Wno-shadow -Wno-error=undef -Wno-invalid-constexpr -Wno-error=thread-safety-attributes -Wno-thread-safety-attributes -Wno-error=thread-safety-analysis -Wno-thread-safety-analysis", + "*:*:config_opts=-G Ninja", + "*:*:config_opts=$config_opts -DCMAKE_BUILD_TYPE=Release", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$NATIVEPREFIX", + "*:*:config_opts=$config_opts -DFILAMENT_SKIP_SAMPLES=ON", + "*:*:config_opts=$config_opts -DFILAMENT_SKIP_SDL2=ON", + "*:*:config_opts=$config_opts -DFILAMENT_BUILD_TESTING=OFF", + "*:*:config_opts=$config_opts -DFILAMENT_SUPPORTS_XCB=OFF", + "*:*:config_opts=$config_opts -DFILAMENT_SUPPORTS_XLIB=OFF", + "*:*:config_opts=$config_opts -DFILAMENT_SUPPORTS_OPENGL=OFF", + "*:*:config_opts=$config_opts -DUSE_STATIC_LIBCXX=OFF" + ], + "steps": [ + "*:*:env -u CMAKE_TOOLCHAIN_FILE cmake -S . -B build $config_opts", + "*:*:cmake --build build -j$NUM_CORES --target matc resgen cmgen filamesh mipgen uberz glslminifier", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/tools/matc/matc build/tools/resgen/resgen build/tools/cmgen/cmgen build/tools/filamesh/filamesh build/tools/mipgen/mipgen build/tools/uberz/uberz build/tools/glslminifier/glslminifier $STAGING_DIR$NATIVEPREFIX/bin/" + ] + } +} \ No newline at end of file diff --git a/packages/native/file.json b/packages/native/file.json new file mode 100644 index 0000000..ab6624a --- /dev/null +++ b/packages/native/file.json @@ -0,0 +1,25 @@ +{ + "package": "native/file", + "version": "5.44", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "c9cc77c7c560c543135edc555af609d5619dbef011997e988ce40a3d75d86088", + "url": "https://astron.com/pub/file/file-5.46.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make" + ], + "build": { + "env": [], + "steps": [ + "*:*:bash ./configure --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/findutils.json b/packages/native/findutils.json new file mode 100644 index 0000000..d7d9da5 --- /dev/null +++ b/packages/native/findutils.json @@ -0,0 +1,31 @@ +{ + "package": "native/findutils", + "version": "4.10.0", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "1387e0b67ff247d2abde998f90dfbf70c1491391a59ddfecb8ae698789f0a4f5", + "url": "https://ftp.gnu.org/gnu/findutils/findutils-4.10.0.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/grep", + "*:*:native/make", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "windows_*:*:config_opts=$config_opts gl_cv_have_weak=no" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "windows_*:*:bash $PATCH_DIR/native/_/drop-gnulib-wint-wrappers.sh", + "*:*:make -j$NUM_CORES", + "*:*:DESTDIR=$STAGING_DIR make install" + ] + } +} \ No newline at end of file diff --git a/packages/native/flex.json b/packages/native/flex.json new file mode 100644 index 0000000..9ee046a --- /dev/null +++ b/packages/native/flex.json @@ -0,0 +1,34 @@ +{ + "package": "native/flex", + "version": "2.6.4", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "e87aae032bf07c26f85ac0ed3250998c37621d95f8bd748b31f15b33c45ee995", + "url": "https://github.com/westes/flex/releases/download/v2.6.4/flex-2.6.4.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/gettext", + "*:*:native/libiconv", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/unistring" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --with-pic", + "*:*:config_opts=$config_opts --enable-shared", + "*:*:config_opts=$config_opts --enable-static" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/gawk.json b/packages/native/gawk.json index d12f7c7..761b803 100644 --- a/packages/native/gawk.json +++ b/packages/native/gawk.json @@ -2,24 +2,38 @@ "package": "native/gawk", "version": "5.3.2", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "8639a1a88fb411a1be02663739d03e902a6d313b5c6fe024d0bfeb3341a19a11", - "url": "http://ftpmirror.gnu.org/gnu/gawk/gawk-5.3.2.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "8639a1a88fb411a1be02663739d03e902a6d313b5c6fe024d0bfeb3341a19a11", + "url": "http://ftpmirror.gnu.org/gnu/gawk/gawk-5.3.2.tar.gz" + } + ], "dependencies": [ - "all:native/make" + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/gettext", + "*:*:native/libtool", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/pkgconf" ], "build": { "env": [ - "all:AUTOMAKE=true", - "all:ACLOCAL=true", - "all:MAKEINFO=true" + "*:*:AUTOMAKE=true", + "*:*:ACLOCAL=true", + "*:*:MAKEINFO=true", + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "darwin_*:*:CFLAGS=$CFLAGS -include mach-o/dyld.h", + "windows_*:*:config_opts=$config_opts gl_cv_have_weak=no" ], "steps": [ - "all:./configure --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "windows_*:*:bash $PATCH_DIR/native/_/drop-gnulib-wint-wrappers.sh", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/gawk@5.2.2.json b/packages/native/gawk@5.2.2.json index 0a78a3c..d080247 100644 --- a/packages/native/gawk@5.2.2.json +++ b/packages/native/gawk@5.2.2.json @@ -2,24 +2,29 @@ "package": "native/gawk@5.2.2", "version": "5.2.2", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "945aef7ccff101f20b22a10802bc005e994ab2b8ea3e724cc1a197c62f41f650", - "url": "http://ftpmirror.gnu.org/gnu/gawk/gawk-5.2.2.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "945aef7ccff101f20b22a10802bc005e994ab2b8ea3e724cc1a197c62f41f650", + "url": "http://ftpmirror.gnu.org/gnu/gawk/gawk-5.2.2.tar.gz" + } + ], "dependencies": [ - "all:native/make" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make" ], "build": { "env": [ - "all:AUTOMAKE=true", - "all:ACLOCAL=true", - "all:MAKEINFO=true" + "*:*:AUTOMAKE=true", + "*:*:ACLOCAL=true", + "*:*:MAKEINFO=true", + "darwin_*:*:CFLAGS=$CFLAGS -include mach-o/dyld.h" ], "steps": [ - "all:./configure --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/gcc@13.2@stage1.json b/packages/native/gcc@13.2@stage1.json deleted file mode 100644 index 208ba96..0000000 --- a/packages/native/gcc@13.2@stage1.json +++ /dev/null @@ -1,76 +0,0 @@ -{ - "package": "native/gcc@13.2@stage1", - "version": "13.2", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "8cb4be3796651976f94b9356fa08d833524f62420d6292c5033a9a26af315078", - "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-13.2.0/gcc-13.2.0.tar.gz" - }, - "dependencies": [ - "*-linux-gnu:native/config", - "*-linux-gnu:native/gmp", - "*-linux-gnu:native/libiconv", - "*-linux-gnu:native/linux-headers", - "*-linux-gnu:native/make", - "*-linux-gnu:native/mpc", - "*-linux-gnu:native/mpfr", - "*-linux-gnu:native/zlib" - ], - "build": { - "env": [ - "*-linux-gnu:LIBRARY_PATH=", - "x86_64-linux-gnu:TOOL_TARGET=x86_64-linux-gnu", - "*-linux-gnu:SYSROOT=$PREFIX", - "*-linux-gnu:config_opts=--prefix=$PREFIX/native", - "*-linux-gnu:config_opts=$config_opts --target=$TOOL_TARGET", - "*-linux-gnu:config_opts=$config_opts --disable-nls", - "*-linux-gnu:config_opts=$config_opts --disable-multilib", - "*-linux-gnu:config_opts=$config_opts --enable-languages=c,c++", - "*-linux-gnu:config_opts=$config_opts --without-headers", - "*-linux-gnu:config_opts=$config_opts --with-newlib", - "*-linux-gnu:config_opts=$config_opts --disable-shared", - "*-linux-gnu:config_opts=$config_opts --disable-threads", - "*-linux-gnu:config_opts=$config_opts --disable-libssp", - "*-linux-gnu:config_opts=$config_opts --disable-libstdcxx", - "*-linux-gnu:config_opts=$config_opts --disable-libsanitizer", - "*-linux-gnu:config_opts=$config_opts --with-system-zlib" - ], - "steps": [ - "*-linux-gnu:sed -i.bak 's/^#undef isalpha/\\/\\/ #undef isalpha/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define isalpha/\\/\\/ #define isalpha/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef isalnum/\\/\\/ #undef isalnum/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define isalnum/\\/\\/ #define isalnum/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef iscntrl/\\/\\/ #undef iscntrl/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define iscntrl/\\/\\/ #define iscntrl/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef isdigit/\\/\\/ #undef isdigit/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define isdigit/\\/\\/ #define isdigit/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef isgraph/\\/\\/ #undef isgraph/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define isgraph/\\/\\/ #define isgraph/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef islower/\\/\\/ #undef islower/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define islower/\\/\\/ #define islower/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef isprint/\\/\\/ #undef isprint/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define isprint/\\/\\/ #define isprint/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef ispunct/\\/\\/ #undef ispunct/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define ispunct/\\/\\/ #define ispunct/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef isspace/\\/\\/ #undef isspace/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define isspace/\\/\\/ #define isspace/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef isupper/\\/\\/ #undef isupper/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define isupper/\\/\\/ #define isupper/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef isxdigit/\\/\\/ #undef isxdigit/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define isxdigit/\\/\\/ #define isxdigit/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef toupper/\\/\\/ #undef toupper/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define toupper/\\/\\/ #define toupper/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#undef tolower/\\/\\/ #undef tolower/' include/safe-ctype.h", - "*-linux-gnu:sed -i.bak 's/^#define tolower/\\/\\/ #define tolower/' include/safe-ctype.h", - "*-linux-gnu:mkdir -p build", - "*-linux-gnu:cd build && ../configure $config_opts", - "*-linux-gnu:cd build && make -j$NUM_CORES all-gcc", - "*-linux-gnu:cd build && make install-gcc DESTDIR=$STAGING_DIR", - "*-linux-gnu:cd build && make -j$NUM_CORES all-target-libgcc TARGET_CONFIGARGS='--disable-shared --enable-static --without-headers --with-newlib' CFLAGS_FOR_TARGET='-g -O2 -nostdlib -nostartfiles' CXXFLAGS_FOR_TARGET='-g -O2 -nostdlib -nostartfiles'", - "*-linux-gnu:cd build && make install-target-libgcc DESTDIR=$STAGING_DIR", - "*-linux-gnu:ln -s $TOOL_TARGET-gcc $STAGING_DIR$PREFIX/native/bin/gcc", - "*-linux-gnu:ln -s $TOOL_TARGET-g++ $STAGING_DIR$PREFIX/native/bin/g++" - ] - } -} \ No newline at end of file diff --git a/packages/native/gettext.json b/packages/native/gettext.json index 3a47cba..8491424 100644 --- a/packages/native/gettext.json +++ b/packages/native/gettext.json @@ -2,27 +2,34 @@ "package": "native/gettext", "version": "0.26", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "39acf4b0371e9b110b60005562aace5b3631fed9b1bb9ecccfc7f56e58bb1d7f", - "url": "http://ftpmirror.gnu.org/gnu/gettext/gettext-0.26.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "39acf4b0371e9b110b60005562aace5b3631fed9b1bb9ecccfc7f56e58bb1d7f", + "url": "http://ftpmirror.gnu.org/gnu/gettext/gettext-0.26.tar.gz" + } + ], "dependencies": [ - "all:native/bison", - "all:native/libiconv", - "all:native/make", - "all:native/sed", - "all:native/texinfo" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/libiconv", + "*:*:native/make", + "*:*:native/sed", + "*:*:native/unistring" ], "build": { "env": [ - "all:config_opts=--prefix=$PREFIX/native", - "all:config_opts=$config_opts --with-libiconv-prefix=$PREFIX/native" + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --with-libiconv-prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --with-libunistring-prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static", + "*:*:LIBS=-lunistring" ], "steps": [ - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/git.json b/packages/native/git.json new file mode 100644 index 0000000..d531d44 --- /dev/null +++ b/packages/native/git.json @@ -0,0 +1,42 @@ +{ + "package": "native/git", + "version": "2.51", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "3524fc5fd81f16f80e1696a8281bd8ad831048b67848015d7b7382bf365ae685", + "url": "https://github.com/git/git/archive/refs/tags/v2.51.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/coreutils", + "*:*:native/curl", + "*:*:native/diffutils", + "*:*:native/expat", + "*:*:native/gettext", + "*:*:native/libiconv", + "*:*:native/libpsl", + "*:*:native/make", + "*:*:native/openssl", + "*:*:native/python@3.14", + "*:*:native/zlib" + ], + "build": { + "env": [], + "steps": [ + "linux_*:*:make -j$NUM_CORES prefix=$NATIVEPREFIX LDFLAGS=\"$LDFLAGS\" EXTLIBS='-liconv -lz -lgettextpo' CC=$CC", + "windows_*:*:make -j$NUM_CORES prefix=$NATIVEPREFIX LDFLAGS=\"$LDFLAGS\" EXTLIBS='-liconv -lz -lgettextpo -lcurl -lpsl -lssl -lcrypto' CC=$CC", + "darwin_*:*:make -j$NUM_CORES prefix=$NATIVEPREFIX LDFLAGS=\"$LDFLAGS\" EXTLIBS='-liconv -lz -lgettextpo -lintl' CC=$CC", + "linux_*:*:make prefix=$NATIVEPREFIX DESTDIR=$STAGING_DIR LDFLAGS=\"$LDFLAGS\" EXTLIBS='-liconv -lz -lgettextpo' install CC=$CC", + "windows_*:*:make prefix=$NATIVEPREFIX DESTDIR=$STAGING_DIR LDFLAGS=\"$LDFLAGS\" EXTLIBS='-liconv -lz -lgettextpo -lcurl -lpsl -lssl -lcrypto' install CC=$CC", + "darwin_*:*:make prefix=$NATIVEPREFIX DESTDIR=$STAGING_DIR LDFLAGS=\"$LDFLAGS\" EXTLIBS='-liconv -lz -lgettextpo -lintl' install CC=$CC", + "*:*:mkdir -p $STAGING_DIR$HOME", + "*:*:echo '[user]' >> $STAGING_DIR$HOME/.gitconfig", + "*:*:echo '\tname = simplybs' >> $STAGING_DIR$HOME/.gitconfig", + "*:*:echo '\temail = simplybs@mrcyjanek.net' >> $STAGING_DIR$HOME/.gitconfig", + "*:*:python3.14 $PATCH_DIR/android_ndk/symlink_same.py $STAGING_DIR$NATIVEPREFIX" + ] + } +} \ No newline at end of file diff --git a/packages/native/glib2.json b/packages/native/glib2.json new file mode 100644 index 0000000..8b47853 --- /dev/null +++ b/packages/native/glib2.json @@ -0,0 +1,32 @@ +{ + "package": "native/glib2", + "version": "2.86", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "d4e2b5d791d5015ffd8c6971ad8e975a0a55c1a14926cdb25cf843ff00682260", + "url": "https://download.gnome.org/sources/glib/2.86/glib-2.86.4.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bison", + "*:*:native/flex", + "*:*:native/gettext", + "*:*:native/libiconv", + "*:*:native/meson", + "*:*:native/ninja", + "*:*:native/pcre2", + "*:*:native/pkgconf", + "*:*:native/python@3.14" + ], + "build": { + "env": [], + "steps": [ + "*:*:meson setup _build --prefix=$NATIVEPREFIX", + "*:*:meson compile -C _build", + "*:*:DESTDIR=$STAGING_DIR meson install -C _build" + ] + } +} \ No newline at end of file diff --git a/packages/native/gmp.json b/packages/native/gmp.json deleted file mode 100644 index 4e63f8c..0000000 --- a/packages/native/gmp.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "package": "native/gmp", - "version": "6.3.0", - "type": "native", - "download": { - "kind": "tar.xz", - "sha256": "a3c2b80201b89e68616f4ad30bc66aee4927c3ce50e33929ca819d5c43538898", - "url": "http://ftpmirror.gnu.org/gnu/gmp/gmp-6.3.0.tar.xz" - }, - "dependencies": [ - "all:native/m4", - "all:native/make", - "all:native/perl" - ], - "build": { - "env": [ - "all:config_opts=--prefix=$PREFIX/native", - "all:config_opts=$config_opts --disable-shared", - "all:config_opts=$config_opts --enable-static" - ], - "steps": [ - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make check", - "all:make DESTDIR=$STAGING_DIR install" - ] - } -} \ No newline at end of file diff --git a/packages/native/gmp_shared.json b/packages/native/gmp_shared.json new file mode 100644 index 0000000..a3aa2cc --- /dev/null +++ b/packages/native/gmp_shared.json @@ -0,0 +1,32 @@ +{ + "package": "native/gmp_shared", + "version": "6.3.0", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "a3c2b80201b89e68616f4ad30bc66aee4927c3ce50e33929ca819d5c43538898", + "url": "http://ftpmirror.gnu.org/gnu/gmp/gmp-6.3.0.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --enable-shared", + "*:*:config_opts=$config_opts --disable-static" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make check", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/gmp_static.json b/packages/native/gmp_static.json new file mode 100644 index 0000000..e7ba562 --- /dev/null +++ b/packages/native/gmp_static.json @@ -0,0 +1,32 @@ +{ + "package": "native/gmp_static", + "version": "6.3.0", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "a3c2b80201b89e68616f4ad30bc66aee4927c3ce50e33929ca819d5c43538898", + "url": "http://ftpmirror.gnu.org/gnu/gmp/gmp-6.3.0.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make check", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/gn.json b/packages/native/gn.json new file mode 100644 index 0000000..61d58a4 --- /dev/null +++ b/packages/native/gn.json @@ -0,0 +1,29 @@ +{ + "package": "native/gn", + "version": "0.0.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "07d3c6f4dc290fae5ca6152ebcb37d6815c411ab", + "url": "https://gn.googlesource.com/gn.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/git", + "*:*:native/ninja", + "*:*:native/pkgconf", + "*:*:native/python@3.11" + ], + "build": { + "env": [], + "steps": [ + "*:*:git tag -a initial-commit -m '0.0.0' 95374957437b818e9addc26c83340b27a1b38202", + "*:*:python3 build/gen.py", + "*:*:ninja -C out", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp out/gn $STAGING_DIR$NATIVEPREFIX/bin/gn" + ] + } +} \ No newline at end of file diff --git a/packages/native/go-bin@1.25.json b/packages/native/go-bin@1.25.json new file mode 100644 index 0000000..26344de --- /dev/null +++ b/packages/native/go-bin@1.25.json @@ -0,0 +1,45 @@ +{ + "package": "native/go-bin@1.25", + "version": "1.25", + "type": "native", + "download": [ + { + "kind": "blob", + "path": "./go-darwin_arm64.tar.gz", + "sha256": "544932844156d8172f7a28f77f2ac9c15a23046698b6243f633b0a0b00c0749c", + "url": "https://go.dev/dl/go1.25.0.darwin-arm64.tar.gz" + }, + { + "kind": "blob", + "path": "./go-linux_amd64.tar.gz", + "sha256": "2852af0cb20a13139b3448992e69b868e50ed0f8a1e5940ee1de9e19a123b613", + "url": "https://go.dev/dl/go1.25.0.linux-amd64.tar.gz" + }, + { + "kind": "blob", + "path": "./go-linux_arm64.tar.gz", + "sha256": "05de75d6994a2783699815ee553bd5a9327d8b79991de36e38b66862782f54ae", + "url": "https://go.dev/dl/go1.25.0.linux-arm64.tar.gz" + } + ], + "dependencies": [ + "*:*:native/7zip", + "*:*:native/_/_", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:GO_VERSION=1.25" + ], + "steps": [ + "*:*:7zz x ./go-${BUILDER_GOOS}_${BUILDER_GOARCH}.tar.gz", + "*:*:mkdir build", + "*:*:cd build && 7zz x ../go-${BUILDER_GOOS}_${BUILDER_GOARCH}.tar", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:mv build/go $STAGING_DIR$NATIVEPREFIX/go$GO_VERSION", + "*:*:cat $PATCH_DIR/go_wrapper.sh | sed \"s/@GO_VERSION@/$GO_VERSION/g\" > $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION", + "*:*:chmod +x $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION", + "*:*:cp $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION $STAGING_DIR$NATIVEPREFIX/bin/go" + ] + } +} \ No newline at end of file diff --git a/packages/native/go.json b/packages/native/go.json new file mode 100644 index 0000000..176f6c8 --- /dev/null +++ b/packages/native/go.json @@ -0,0 +1,33 @@ +{ + "package": "native/go", + "version": "1.25.5", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "22a5fd0a91efcd28a1b0537106b9959b2804b61f59c3758b51e8e5429c1a954f", + "url": "https://go.dev/dl/go1.25.5.src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/7zip", + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/go@1.25", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:GO_VERSION=1.25.5" + ], + "steps": [ + "*:*:cd src && bash ./make.bash", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/go$GO_VERSION", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:mv * $STAGING_DIR$NATIVEPREFIX/go$GO_VERSION", + "*:*:cat $PATCH_DIR/go_wrapper.sh | sed \"s/@GO_VERSION@/$GO_VERSION/g\" > $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION", + "*:*:chmod +x $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION", + "*:*:cp $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION $STAGING_DIR$NATIVEPREFIX/bin/go" + ] + } +} \ No newline at end of file diff --git a/packages/native/go@1.25.json b/packages/native/go@1.25.json new file mode 100644 index 0000000..5eead1a --- /dev/null +++ b/packages/native/go@1.25.json @@ -0,0 +1,33 @@ +{ + "package": "native/go@1.25", + "version": "1.25", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "4bd01e91297207bfa450ea40d4d5a93b1b531a5e438473b2a06e18e077227225", + "url": "https://go.dev/dl/go1.25.0.src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/7zip", + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/sed", + "darwin_arm64:*:native/go-bin@1.25" + ], + "build": { + "env": [ + "*:*:GO_VERSION=1.25" + ], + "steps": [ + "*:*:cd src && bash ./make.bash", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/go$GO_VERSION", + "*:*:mv * $STAGING_DIR$NATIVEPREFIX/go$GO_VERSION", + "*:*:cat $PATCH_DIR/go_wrapper.sh | sed \"s/@GO_VERSION@/$GO_VERSION/g\" > $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION", + "*:*:chmod +x $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION", + "*:*:cp $STAGING_DIR$NATIVEPREFIX/bin/go$GO_VERSION $STAGING_DIR$NATIVEPREFIX/bin/go" + ] + } +} \ No newline at end of file diff --git a/packages/native/gperf.json b/packages/native/gperf.json index 9e45c2a..9330d83 100644 --- a/packages/native/gperf.json +++ b/packages/native/gperf.json @@ -2,22 +2,26 @@ "package": "native/gperf", "version": "0.26", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "fd87e0aba7e43ae054837afd6cd4db03a3f2693deb3619085e6ed9d8d9604ad8", - "url": "http://ftpmirror.gnu.org/gnu/gperf/gperf-3.3.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "fd87e0aba7e43ae054837afd6cd4db03a3f2693deb3619085e6ed9d8d9604ad8", + "url": "http://ftpmirror.gnu.org/gnu/gperf/gperf-3.3.tar.gz" + } + ], "dependencies": [ - "all:native/make" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make" ], "build": { "env": [ - "all:config_opts=--prefix=$PREFIX/native" + "*:*:config_opts=--prefix=$NATIVEPREFIX" ], "steps": [ - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/grep.json b/packages/native/grep.json new file mode 100644 index 0000000..35c0c8a --- /dev/null +++ b/packages/native/grep.json @@ -0,0 +1,29 @@ +{ + "package": "native/grep", + "version": "3.12", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "2649b27c0e90e632eadcd757be06c6e9a4f48d941de51e7c0f83ff76408a07b9", + "url": "http://ftpmirror.gnu.org/gnu/grep/grep-3.12.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "windows_*:*:config_opts=$config_opts gl_cv_have_weak=no" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "windows_*:*:bash $PATCH_DIR/native/_/drop-gnulib-wint-wrappers.sh", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/gzip.json b/packages/native/gzip.json new file mode 100644 index 0000000..9426a46 --- /dev/null +++ b/packages/native/gzip.json @@ -0,0 +1,29 @@ +{ + "package": "native/gzip", + "version": "1.14", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "01a7b881bd220bfdf615f97b8718f80bdfd3f6add385b993dcf6efd14e8c0ac6", + "url": "http://ftpmirror.gnu.org/gnu/gzip/gzip-1.14.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "windows_*:*:config_opts=$config_opts gl_cv_have_weak=no" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "windows_*:*:bash $PATCH_DIR/native/_/drop-gnulib-wint-wrappers.sh", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/help2man.json b/packages/native/help2man.json new file mode 100644 index 0000000..84e9094 --- /dev/null +++ b/packages/native/help2man.json @@ -0,0 +1,30 @@ +{ + "package": "native/help2man", + "version": "1.49.3", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "4d7e4fdef2eca6afe07a2682151cea78781e0a4e8f9622142d9f70c083a2fd4f", + "url": "http://ftpmirror.gnu.org/gnu/help2man/help2man-1.49.3.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/icu4c.json b/packages/native/icu4c.json new file mode 100644 index 0000000..5d687b6 --- /dev/null +++ b/packages/native/icu4c.json @@ -0,0 +1,39 @@ +{ + "package": "native/icu4c", + "version": "55.2", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "eda2aa9f9c787748a2e2d310590720ca8bcc6252adf6b4cfb03b65bef9d66759", + "url": "http://github.com/unicode-org/icu/releases/download/release-55-2/icu4c-55_2-src.tgz" + } + ], + "dependencies": [ + "*:*-w64-mingw32:native/_/_", + "*:*-w64-mingw32:native/bash", + "*:*-w64-mingw32:native/make", + "*:*-w64-mingw32:native/patch" + ], + "patches": [ + "icu-001-dont-build-static-dynamic-twice.patch" + ], + "build": { + "env": [ + "linux_*:*:ICU_PLATFORM=Linux/gcc", + "darwin_*:*:ICU_PLATFORM=Darwin", + "windows_*:*:ICU_PLATFORM=Cygwin/gcc" + ], + "steps": [ + "*:*-w64-mingw32:patch -p1 < $PATCH_DIR/icu4c/icu-001-dont-build-static-dynamic-twice.patch", + "*:*-w64-mingw32:mkdir -p $NATIVEPREFIX/share/", + "*:*-w64-mingw32:cp -av . $NATIVEPREFIX/share/icu4c_55.2", + "linux_arm64:*-w64-mingw32:ln -sf $NATIVEPREFIX/_/bin/clang $NATIVEPREFIX/_/bin/gcc", + "linux_arm64:*-w64-mingw32:ln -sf $NATIVEPREFIX/_/bin/clang++ $NATIVEPREFIX/_/bin/g++", + "*:*-w64-mingw32:WD=$PWD && unset HOST TARGET && cd $NATIVEPREFIX/share/icu4c_55.2 && bash $WD/source/runConfigureICU $ICU_PLATFORM --prefix=$NATIVEPREFIX/share/icu4c_55.2", + "*:*-w64-mingw32:unset HOST TARGET && cd $NATIVEPREFIX/share/icu4c_55.2 && make -j$NUM_CORES", + "*:*-w64-mingw32:mkdir -p $STAGING_DIR$NATIVEPREFIX/share", + "*:*-w64-mingw32:cp -av $NATIVEPREFIX/share/icu4c_55.2 $STAGING_DIR$NATIVEPREFIX/share/" + ] + } +} \ No newline at end of file diff --git a/packages/native/libc++.json b/packages/native/libc++.json new file mode 100644 index 0000000..4d16224 --- /dev/null +++ b/packages/native/libc++.json @@ -0,0 +1,31 @@ +{ + "package": "native/libc++", + "version": "21.1.3", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "450f52eec88f728c89a9efd667dbeaf2dad93826", + "url": "https://github.com/llvm/llvm-project" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/cmake", + "*:*:native/coreutils", + "*:*:native/ninja" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir build && cd build", + "*:*:cd build && cmake -G Ninja ../runtimes -DLLVM_ENABLE_RUNTIMES='libunwind;libcxx;libcxxabi' -DCMAKE_BUILD_TYPE=Release -DLIBCXX_ENABLE_SHARED=OFF -DLIBCXX_ENABLE_STATIC=ON -DLIBCXX_INCLUDE_TESTS=OFF -DCMAKE_INSTALL_PREFIX=$NATIVEPREFIX", + "*:*:cd build && ninja unwind cxx cxxabi", + "*:*:cd build && DESTDIR=$STAGING_DIR ninja install-unwind", + "*:*:cd build && DESTDIR=$STAGING_DIR ninja install-cxx", + "*:*:cd build && DESTDIR=$STAGING_DIR ninja install-cxxabi" + ] + } +} \ No newline at end of file diff --git a/packages/native/libffi@3_5_2.json b/packages/native/libffi@3_5_2.json new file mode 100644 index 0000000..d2ba1c0 --- /dev/null +++ b/packages/native/libffi@3_5_2.json @@ -0,0 +1,24 @@ +{ + "package": "native/libffi@3_5_2", + "version": "3_5_2", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "f3a3082a23b37c293a4fcd1053147b371f2ff91fa7ea1b2a52e335676bac82dc", + "url": "https://github.com/libffi/libffi/releases/download/v3.5.2/libffi-3.5.2.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/make" + ], + "build": { + "env": [], + "steps": [ + "*:*:./configure --prefix=$NATIVEPREFIX --enable-static --disable-shared --disable-docs --with-pic", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/libiconv.json b/packages/native/libiconv.json index 38c24d7..a5d02f0 100644 --- a/packages/native/libiconv.json +++ b/packages/native/libiconv.json @@ -2,28 +2,30 @@ "package": "native/libiconv", "version": "1.17", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "8f74213b56238c85a50a5329f77e06198771e70dd9a739779f4c02f65d971313", - "url": "http://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.17.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "8f74213b56238c85a50a5329f77e06198771e70dd9a739779f4c02f65d971313", + "url": "http://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.17.tar.gz" + } + ], "dependencies": [ - "all:native/config", - "all:native/make" + "*:*:native/_/_", + "*:*:native/config", + "*:*:native/make" ], "build": { "env": [ - "all:CFLAGS=$CFLAGS -fPIC", - "all:config_opts=--prefix=$PREFIX/native --disable-nls --enable-static --disable-shared", - "all:config_opts=$config_opts", - "*linux:config_opts=$config_opts --with-pic" + "*:*:config_opts=--prefix=$NATIVEPREFIX --disable-nls --enable-static --disable-shared", + "*:*:config_opts=$config_opts", + "*:*linux:config_opts=$config_opts --with-pic" ], "steps": [ - "all:cp -f $PREFIX/native/usr/share/config/config.guess build-aux/", - "all:cp -f $PREFIX/native/usr/share/config/config.sub build-aux/", - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess build-aux/", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub build-aux/", + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/libmd.json b/packages/native/libmd.json new file mode 100644 index 0000000..30b828d --- /dev/null +++ b/packages/native/libmd.json @@ -0,0 +1,34 @@ +{ + "package": "native/libmd", + "version": "1.1.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "d5b8e853989a73f8fff9dc4e00dccd0b691b84f9", + "url": "https://github.com/guillemj/libmd.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/gettext", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [ + "*:*:config_opts=--host=$HOST --prefix=$NATIVEPREFIX" + ], + "steps": [ + "*:*:autoreconf --force --install", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make install DESTDIR=$STAGING_DIR" + ] + } +} \ No newline at end of file diff --git a/packages/native/libpsl.json b/packages/native/libpsl.json new file mode 100644 index 0000000..6b640b9 --- /dev/null +++ b/packages/native/libpsl.json @@ -0,0 +1,39 @@ +{ + "package": "native/libpsl", + "version": "0.21.5", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "1dcc9ceae8b128f3c0b3f654decd0e1e891afc6ff81098f227ef260449dae208", + "url": "https://github.com/rockdaboot/libpsl/releases/download/0.21.5/libpsl-0.21.5.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/python@3.11", + "*:*:native/unistring" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "windows_*:*:config_opts=$config_opts --disable-builtin" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "windows_*:*:sed -i.bak -e 's/^BUILT_SOURCES = suffixes_dafsa.h/BUILT_SOURCES =/' -e '/^suffixes_dafsa\\.h:/,/^$/d' src/Makefile", + "linux_*:*:make -j$NUM_CORES", + "linux_*:*:make DESTDIR=$STAGING_DIR install", + "darwin_*:*:make -j$NUM_CORES", + "darwin_*:*:make DESTDIR=$STAGING_DIR install", + "windows_*:*:make -j$NUM_CORES -C include", + "windows_*:*:make -j$NUM_CORES -C src", + "windows_*:*:make -j$NUM_CORES -C tools", + "windows_*:*:make DESTDIR=$STAGING_DIR -C include install", + "windows_*:*:make DESTDIR=$STAGING_DIR -C src install", + "windows_*:*:make DESTDIR=$STAGING_DIR -C tools install" + ] + } +} \ No newline at end of file diff --git a/packages/native/libtapi.json b/packages/native/libtapi.json new file mode 100644 index 0000000..5029d1b --- /dev/null +++ b/packages/native/libtapi.json @@ -0,0 +1,58 @@ +{ + "package": "native/libtapi", + "version": "1300.6.5", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "640b4623929c923c0468143ff2a363a48665fa54", + "url": "https://github.com/tpoechtrager/apple-libtapi.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/ninja", + "{linux_*,windows_*}:*:native/libc++" + ], + "build": { + "env": [ + "*:*:config_opts=-G Ninja -S src/llvm -B build", + "*:*:config_opts=$config_opts -DCMAKE_BUILD_TYPE=Release", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_PROJECTS='clang;tapi'", + "*:*:config_opts=$config_opts -DLLVM_INCLUDE_TESTS=OFF", + "*:*:config_opts=$config_opts -DLLVM_INCLUDE_BENCHMARKS=OFF", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_TERMINFO=OFF", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_WARNINGS=OFF", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$NATIVEPREFIX", + "*:*:config_opts=$config_opts -DTAPI_REPOSITORY_STRING=1300.6.5", + "*:*:config_opts=$config_opts -DTAPI_FULL_VERSION=1300.6.5", + "darwin_arm64:*:config_opts=$config_opts -DLLVM_HOST_TRIPLE=aarch64-apple-darwin", + "darwin_arm64:*:config_opts=$config_opts -DCMAKE_OSX_SYSROOT=$NATIVEPREFIX/_/SDK/MacOSX26.1.sdk", + "darwin_arm64:*:config_opts=$config_opts -DCMAKE_OSX_DEPLOYMENT_TARGET=$OSX_MIN_VERSION", + "darwin_arm64:*:config_opts=$config_opts -DCMAKE_INSTALL_NAME_DIR=$NATIVEPREFIX/lib", + "darwin_arm64:*:config_opts=$config_opts -DCMAKE_CXX_FLAGS=-stdlib=libc++", + "darwin_arm64:*:CMAKE_EXE_LINKER_FLAGS=-stdlib=libc++ -lc++ -lc++abi", + "darwin_arm64:*:CMAKE_SHARED_LINKER_FLAGS=-stdlib=libc++ -lc++ -lc++abi", + "{linux_*,windows_*}:*:CC=$NATIVEPREFIX/_/bin/clang", + "{linux_*,windows_*}:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "linux_arm64:*:config_opts=$config_opts -DLLVM_HOST_TRIPLE=aarch64-linux-gnu", + "linux_amd64:*:config_opts=$config_opts -DLLVM_HOST_TRIPLE=x86_64-linux-gnu", + "windows_amd64:*:config_opts=$config_opts -DLLVM_HOST_TRIPLE=x86_64-pc-cygwin", + "{linux_*,windows_*}:*:config_opts=$config_opts -DLLVM_ENABLE_LIBCXX=ON", + "{linux_*,windows_*}:*:config_opts=$config_opts -DCMAKE_C_COMPILER=$NATIVEPREFIX/_/bin/clang", + "{linux_*,windows_*}:*:config_opts=$config_opts -DCMAKE_CXX_COMPILER=$NATIVEPREFIX/_/bin/clang++", + "{linux_*,windows_*}:*:CMAKE_CXX_FLAGS=-stdlib=libc++ -I$NATIVEPREFIX/include/c++/v1", + "{linux_*,windows_*}:*:CMAKE_EXE_LINKER_FLAGS=-L$NATIVEPREFIX/lib -stdlib=libc++ -lc++ -lc++abi -lunwind -latomic", + "{linux_*,windows_*}:*:CMAKE_SHARED_LINKER_FLAGS=-L$NATIVEPREFIX/lib -stdlib=libc++ -lc++ -lc++abi -lunwind" + ], + "steps": [ + "*:*:sed -i.bak '/add_clang_subdirectory(IndexStore)/d; /add_clang_subdirectory(libclang)/d' src/clang/tools/CMakeLists.txt", + "darwin_arm64:*:cmake $config_opts -DCMAKE_EXE_LINKER_FLAGS=\"$CMAKE_EXE_LINKER_FLAGS\" -DCMAKE_SHARED_LINKER_FLAGS=\"$CMAKE_SHARED_LINKER_FLAGS\"", + "{linux_*,windows_*}:*:cmake $config_opts -DCMAKE_CXX_FLAGS=\"$CMAKE_CXX_FLAGS\" -DCMAKE_EXE_LINKER_FLAGS=\"$CMAKE_EXE_LINKER_FLAGS\" -DCMAKE_SHARED_LINKER_FLAGS=\"$CMAKE_SHARED_LINKER_FLAGS\"", + "*:*:cmake --build build --target clangBasic libtapi -j$NUM_CORES", + "*:*:DESTDIR=$STAGING_DIR ninja -C build install-libtapi install-tapi-headers" + ] + } +} \ No newline at end of file diff --git a/packages/native/libtool.json b/packages/native/libtool.json index 3933633..6629cc2 100644 --- a/packages/native/libtool.json +++ b/packages/native/libtool.json @@ -2,21 +2,28 @@ "package": "native/libtool", "version": "2.5.4", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "da8ebb2ce4dcf46b90098daf962cffa68f4b4f62ea60f798d0ef12929ede6adf", - "url": "http://ftpmirror.gnu.org/gnu/libtool/libtool-2.5.4.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "da8ebb2ce4dcf46b90098daf962cffa68f4b4f62ea60f798d0ef12929ede6adf", + "url": "http://ftpmirror.gnu.org/gnu/libtool/libtool-2.5.4.tar.gz" + } + ], "dependencies": [ - "all:native/m4", - "all:native/make" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/grep", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/sed" ], "build": { "env": [], "steps": [ - "all:./configure --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:ln -sf libtoolize $STAGING_DIR$NATIVEPREFIX/bin/glibtoolize" ] } } \ No newline at end of file diff --git a/packages/native/libxml2.json b/packages/native/libxml2.json new file mode 100644 index 0000000..b92d1f9 --- /dev/null +++ b/packages/native/libxml2.json @@ -0,0 +1,26 @@ +{ + "package": "native/libxml2", + "version": "2.14.5", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "03d006f3537616833c16c53addcdc32a0eb20e55443cba4038307e3fa7d8d44b", + "url": "https://download.gnome.org/sources/libxml2/2.14/libxml2-2.14.5.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/pkgconf" + ], + "build": { + "env": [], + "steps": [ + "*:*:bash ./configure --prefix=$NATIVEPREFIX --without-python", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/linux-headers.json b/packages/native/linux-headers.json deleted file mode 100644 index 75fc5f7..0000000 --- a/packages/native/linux-headers.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "package": "native/linux-headers", - "version": "6.15.9", - "type": "native", - "download": { - "kind": "tar.xz", - "sha256": "e94f3af85492302f7a819441458f80bca0ad9912e5a4c83c699ff3c63c52957d", - "url": "https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.15.9.tar.xz" - }, - "dependencies": [ - "*-linux-*:native/make", - "*-linux-*:native/rsync", - "*-linux-*:native/sed" - ], - "build": { - "env": [ - "x86_64*:ARCH=x86_64", - "arm*:ARCH=arm", - "aarch64*:ARCH=arm64" - ], - "steps": [ - "*-linux-*:sed -i.bak '/arch\\/x86\\/tools relocs/ s/.*/\\ttrue/' arch/x86/Makefile", - "*-linux-*:make ARCH=$ARCH INSTALL_HDR_PATH=$STAGING_DIR$PREFIX/usr headers_install" - ] - } -} \ No newline at end of file diff --git a/packages/native/llvm-ar.json b/packages/native/llvm-ar.json new file mode 100644 index 0000000..efe2997 --- /dev/null +++ b/packages/native/llvm-ar.json @@ -0,0 +1,29 @@ +{ + "package": "native/llvm-ar", + "version": "21.1.3", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "450f52eec88f728c89a9efd667dbeaf2dad93826", + "url": "https://github.com/llvm/llvm-project" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir build && cd build", + "*:*:cd build && cmake -G Ninja -DLLVM_ENABLE_PROJECTS='llvm' -DCMAKE_BUILD_TYPE=Release ../llvm", + "*:*:cd build && ninja llvm-ar", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin/", + "*:*:cp build/bin/llvm-ar $STAGING_DIR$NATIVEPREFIX/bin/llvm-ar" + ] + } +} \ No newline at end of file diff --git a/packages/native/llvm-nm.json b/packages/native/llvm-nm.json new file mode 100644 index 0000000..476a073 --- /dev/null +++ b/packages/native/llvm-nm.json @@ -0,0 +1,28 @@ +{ + "package": "native/llvm-nm", + "version": "21.1.3", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "450f52eec88f728c89a9efd667dbeaf2dad93826", + "url": "https://github.com/llvm/llvm-project" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja" + ], + "build": { + "steps": [ + "*:*:mkdir build && cd build", + "*:*:cd build && cmake -G Ninja -DLLVM_ENABLE_PROJECTS='llvm' -DCMAKE_BUILD_TYPE=Release ../llvm", + "*:*:cd build && ninja llvm-nm", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin/", + "*:*:cp build/bin/llvm-nm $STAGING_DIR$NATIVEPREFIX/bin/llvm-nm" + ] + } +} \ No newline at end of file diff --git a/packages/native/llvm-objcopy.json b/packages/native/llvm-objcopy.json new file mode 100644 index 0000000..54dbba2 --- /dev/null +++ b/packages/native/llvm-objcopy.json @@ -0,0 +1,28 @@ +{ + "package": "native/llvm-objcopy", + "version": "21.1.3", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "450f52eec88f728c89a9efd667dbeaf2dad93826", + "url": "https://github.com/llvm/llvm-project" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/python@3.11" + ], + "build": { + "steps": [ + "*:*:mkdir build && cd build", + "*:*:cd build && cmake -G \"Unix Makefiles\" -DLLVM_ENABLE_PROJECTS='llvm' -DCMAKE_BUILD_TYPE=Release -DLLVM_TARGETS_TO_BUILD=X86 -DLLVM_INCLUDE_TESTS=OFF -DPython3_EXECUTABLE=$NATIVEPREFIX/bin/python3.11 ../llvm", + "*:*:cd build && make -j$NUM_CORES llvm-objcopy", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin/", + "*:*:cp build/bin/llvm-objcopy $STAGING_DIR$NATIVEPREFIX/bin/llvm-objcopy" + ] + } +} \ No newline at end of file diff --git a/packages/native/llvm-profdata.json b/packages/native/llvm-profdata.json new file mode 100644 index 0000000..dd8e9f3 --- /dev/null +++ b/packages/native/llvm-profdata.json @@ -0,0 +1,28 @@ +{ + "package": "native/llvm-profdata", + "version": "21.1.3", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "450f52eec88f728c89a9efd667dbeaf2dad93826", + "url": "https://github.com/llvm/llvm-project" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja" + ], + "build": { + "steps": [ + "*:*:mkdir build && cd build", + "*:*:cd build && cmake -G Ninja -DLLVM_ENABLE_PROJECTS='llvm' -DCMAKE_BUILD_TYPE=Release ../llvm", + "*:*:cd build && ninja llvm-profdata", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin/", + "*:*:cp build/bin/llvm-profdata $STAGING_DIR$NATIVEPREFIX/bin/llvm-profdata" + ] + } +} \ No newline at end of file diff --git a/packages/native/llvm-strip.json b/packages/native/llvm-strip.json new file mode 100644 index 0000000..22c1895 --- /dev/null +++ b/packages/native/llvm-strip.json @@ -0,0 +1,29 @@ +{ + "package": "native/llvm-strip", + "version": "21.1.3", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "450f52eec88f728c89a9efd667dbeaf2dad93826", + "url": "https://github.com/llvm/llvm-project" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir build && cd build", + "*:*:cd build && cmake -G Ninja -DLLVM_ENABLE_PROJECTS='llvm' -DCMAKE_BUILD_TYPE=Release ../llvm", + "*:*:cd build && ninja llvm-strip", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin/", + "*:*:cp build/bin/llvm-strip $STAGING_DIR$NATIVEPREFIX/bin/llvm-strip" + ] + } +} \ No newline at end of file diff --git a/packages/native/llvm.json b/packages/native/llvm.json new file mode 100644 index 0000000..5dd7de4 --- /dev/null +++ b/packages/native/llvm.json @@ -0,0 +1,28 @@ +{ + "package": "native/llvm", + "version": "21.1.3", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "450f52eec88f728c89a9efd667dbeaf2dad93826", + "url": "https://github.com/llvm/llvm-project" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir build && cd build", + "*:*:cd build && cmake -G Ninja -DLLVM_ENABLE_PROJECTS='llvm' -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=$STAGING_DIR$NATIVEPREFIX ../llvm", + "*:*:cd build && ninja llvm-tools", + "*:*:cd build && cmake --install . --component llvm-tools" + ] + } +} \ No newline at end of file diff --git a/packages/native/llvm@google@18.0.0git.json b/packages/native/llvm@google@18.0.0git.json new file mode 100644 index 0000000..8c962be --- /dev/null +++ b/packages/native/llvm@google@18.0.0git.json @@ -0,0 +1,43 @@ +{ + "package": "native/llvm@google@18.0.0git", + "version": "18.0.0git", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "c58bc24fcf678c55b0bf522be89eff070507a005", + "url": "https://android.googlesource.com/toolchain/llvm-project" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/cmake", + "*:*:native/ninja", + "*:*:native/python@3.11", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:config_opts=-DCMAKE_BUILD_TYPE=Release", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_PROJECTS='clang;lld;libc;openmp;pstl'", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_RUNTIMES='compiler-rt'", + "*:*:config_opts=$config_opts -DLLVM_ENABLE_BINDINGS=OFF", + "*:*:config_opts=$config_opts -DCOMPILER_RT_BAREMETAL_BUILD=ON", + "*:*:config_opts=$config_opts -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON", + "*:*:config_opts=$config_opts -DCOMPILER_RT_BUILD_SANITIZERS=OFF", + "*:*:config_opts=$config_opts -DCOMPILER_RT_BUILD_XRAY=OFF", + "*:*:config_opts=$config_opts -DCOMPILER_RT_BUILD_LIBFUZZER=OFF", + "*:*:config_opts=$config_opts -DCOMPILER_RT_BUILD_PROFILE=OFF", + "*:*:config_opts=$config_opts -DCOMPILER_RT_BUILD_BUILTINS=ON", + "*:*:config_opts=$config_opts -DCLANG_ENABLE_BOOTSTRAP=ON" + ], + "steps": [ + "*:*:cmake -S llvm -B build -G Ninja $config_opts", + "*:*:sed -i.bak 's/(state->ControlWord)/(state->ControlWord \\& 0xFFFFFFFF)/g' ./libc/src/__support/FPUtil/aarch64/fenv_darwin_impl.h", + "*:*:sed -i.bak 's/(state->StatusWord)/(state->StatusWord \\& 0xFFFFFFFF)/g' ./libc/src/__support/FPUtil/aarch64/fenv_darwin_impl.h", + "*:*:cd build && ninja -j $NUM_CORES", + "*:*:cd build && DESTDIR=$STAGING_DIR ninja install" + ] + } +} \ No newline at end of file diff --git a/packages/native/llvm@google@19.0.1.json b/packages/native/llvm@google@19.0.1.json new file mode 100644 index 0000000..7148979 --- /dev/null +++ b/packages/native/llvm@google@19.0.1.json @@ -0,0 +1,60 @@ +{ + "package": "native/llvm@google@19.0.1", + "version": "19.0.1", + "type": "native", + "download": [ + { + "kind": "git", + "path": "llvm", + "sha256": "3b5e7c83a6e226d5bd7ed2e9b67449b64812074c", + "url": "https://android.googlesource.com/toolchain/llvm-project" + }, + { + "kind": "git", + "path": "llvm-android", + "sha256": "e727bfb014bd436f581a66a450c939a6983a1fc3", + "url": "https://android.googlesource.com/toolchain/llvm_android.git" + }, + { + "kind": "git", + "path": "toolchain-utils", + "sha256": "d71e320ab860721f764fe7403588641c8a7bc65d", + "url": "https://android.googlesource.com/platform/external/toolchain-utils" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/cmake", + "*:*:native/gawk", + "*:*:native/ninja", + "*:*:native/patch", + "*:*:native/python@3.11" + ], + "build": { + "env": [ + "*:*:config_opts=-DCMAKE_BUILD_TYPE=Release", + "*:*-android*:config_opts=$config_opts -DCMAKE_BUILD_TYPE=Release", + "*:*-android*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$NATIVEPREFIX/llvm@google@19.0.1", + "*:*-android*:config_opts=$config_opts -DLLVM_ENABLE_PROJECTS='clang;lld;libc;openmp;pstl'", + "*:*-android*:config_opts=$config_opts -DLLVM_ENABLE_BINDINGS=OFF", + "*:*-android*:config_opts=$config_opts -DCLANG_ENABLE_BOOTSTRAP=ON", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_BUILTINS=ON", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BAREMETAL_BUILD=ON", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_SANITIZERS=OFF", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_XRAY=OFF", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_LIBFUZZER=OFF", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_PROFILE=OFF", + "*:aarch64-linux-android:config_opts=$config_opts -DLLVM_TARGETS_TO_BUILD='AArch64' -DCLANG_DEFAULT_TARGET_TRIPLE='aarch64-linux-android' -DLLVM_DEFAULT_TARGET_TRIPLE='aarch64-linux-android' -DCOMPILER_RT_TARGET_TRIPLE='aarch64-linux-android'", + "*:x86_64-linux-android:config_opts=$config_opts -DLLVM_TARGETS_TO_BUILD='X86' -DCLANG_DEFAULT_TARGET_TRIPLE='x86_64-linux-android' -DLLVM_DEFAULT_TARGET_TRIPLE='x86_64-linux-android' -DCOMPILER_RT_TARGET_TRIPLE='x86_64-linux-android'", + "*:armv7a-linux-androideabi:config_opts=$config_opts -DLLVM_TARGETS_TO_BUILD='ARM' -DCLANG_DEFAULT_TARGET_TRIPLE='armv7a-linux-androideabi' -DLLVM_DEFAULT_TARGET_TRIPLE='armv7a-linux-androideabi' -DCOMPILER_RT_TARGET_TRIPLE='armv7a-linux-androideabi'", + "*:*:SVN_REVISION=530567" + ], + "steps": [ + "*:*-android*:cd llvm-android && python3 ../toolchain-utils/llvm_tools/patch_manager.py --patch_metadata_file=patches/PATCHES.json --src_path=../llvm --svn_version=$SVN_REVISION", + "*:*-android*:cd llvm && cmake -S llvm -B build -G Ninja $config_opts", + "*:*-android*:cd llvm && cd build && ninja -j $NUM_CORES", + "*:*-android*:cd llvm && cd build && DESTDIR=$STAGING_DIR ninja install" + ] + } +} \ No newline at end of file diff --git a/packages/native/llvm@google@r563880.json b/packages/native/llvm@google@r563880.json new file mode 100644 index 0000000..8833ef5 --- /dev/null +++ b/packages/native/llvm@google@r563880.json @@ -0,0 +1,43 @@ +{ + "package": "native/llvm@google@r563880", + "version": "r563880", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "5e96669f06077099aa41290cdb4c5e6fa0f59349", + "url": "https://android.googlesource.com/toolchain/llvm-project" + } + ], + "dependencies": [ + "*:*-android*:native/_/_", + "*:*-android*:native/cmake", + "*:*-android*:native/ninja", + "*:*-android*:native/python@3.11" + ], + "build": { + "env": [ + "*:*-android*:config_opts=-DCMAKE_BUILD_TYPE=Release", + "*:*-android*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", + "*:*-android*:config_opts=$config_opts -DLLVM_ENABLE_PROJECTS='clang;lld;libc;openmp;pstl'", + "*:*-android*:config_opts=$config_opts -DLLVM_ENABLE_RUNTIMES='compiler-rt'", + "*:aarch64-linux-android:config_opts=$config_opts -DLLVM_TARGETS_TO_BUILD='AArch64' -DLLVM_DEFAULT_TARGET_TRIPLE='aarch64-linux-android' -DCOMPILER_RT_TARGET_TRIPLE='aarch64-linux-android'", + "*:x86_64-linux-android:config_opts=$config_opts -DLLVM_TARGETS_TO_BUILD='X86' -DLLVM_DEFAULT_TARGET_TRIPLE='x86_64-linux-android' -DCOMPILER_RT_TARGET_TRIPLE='x86_64-linux-android'", + "*:armv7a-linux-androideabi:config_opts=$config_opts -DLLVM_TARGETS_TO_BUILD='ARM' -DLLVM_DEFAULT_TARGET_TRIPLE='armv7a-linux-androideabi' -DCOMPILER_RT_TARGET_TRIPLE='armv7a-linux-androideabi'", + "*:*-android*:config_opts=$config_opts -DLLVM_ENABLE_BINDINGS=OFF", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BAREMETAL_BUILD=ON", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_SANITIZERS=OFF", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_XRAY=OFF", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_LIBFUZZER=OFF", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_PROFILE=OFF", + "*:*-android*:config_opts=$config_opts -DCOMPILER_RT_BUILD_BUILTINS=ON", + "*:*-android*:config_opts=$config_opts -DCLANG_ENABLE_BOOTSTRAP=ON" + ], + "steps": [ + "*:*-android*:cmake -S llvm -B build -G Ninja $config_opts", + "*:*-android*:cd build && ninja -j $NUM_CORES", + "*:*-android*:cd build && DESTDIR=$STAGING_DIR ninja install" + ] + } +} \ No newline at end of file diff --git a/packages/native/m4.json b/packages/native/m4.json index 7de297f..6153650 100644 --- a/packages/native/m4.json +++ b/packages/native/m4.json @@ -2,21 +2,26 @@ "package": "native/m4", "version": "1.4.20", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "6ac4fc31ce440debe63987c2ebbf9d7b6634e67a7c3279257dc7361de8bdb3ef", - "url": "http://ftpmirror.gnu.org/gnu/m4/m4-1.4.20.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "6ac4fc31ce440debe63987c2ebbf9d7b6634e67a7c3279257dc7361de8bdb3ef", + "url": "http://ftpmirror.gnu.org/gnu/m4/m4-1.4.20.tar.gz" + } + ], "dependencies": [ - "all:native/make" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/sed" ], "build": { "env": [], "steps": [ - "all:./configure --prefix=$PREFIX/native --disable-nls", - "all:sed -i.bak 's/^run.*automake.*/exit 0/' build-aux/missing", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure --prefix=$NATIVEPREFIX --disable-nls", + "*:*:sed -i.bak 's/^run.*automake.*/exit 0/' build-aux/missing", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/make.json b/packages/native/make.json index e54a4af..d109ce8 100644 --- a/packages/native/make.json +++ b/packages/native/make.json @@ -2,20 +2,31 @@ "package": "native/make", "version": "4.4", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "581f4d4e872da74b3941c874215898a7d35802f03732bdccee1d4a7979105d18", - "url": "http://ftpmirror.gnu.org/gnu/make/make-4.4.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "581f4d4e872da74b3941c874215898a7d35802f03732bdccee1d4a7979105d18", + "url": "http://ftpmirror.gnu.org/gnu/make/make-4.4.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_" + ], "build": { "env": [], "steps": [ - "all:./configure --disable-dependency-tracking", - "all:./build.sh", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp make $STAGING_DIR/$PREFIX/native/bin/make", - "all:ln -s make $STAGING_DIR$PREFIX/native/bin/gmake", - "all:ln -s make $STAGING_DIR$PREFIX/native/bin/gnumake" + "*:*:echo $PATH", + "*:*:dash ./configure --disable-dependency-tracking", + "*:*:dash ./build.sh", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp make $STAGING_DIR$NATIVEPREFIX/bin/make", + "windows_amd64:*:test -f make.exe && cp -f make.exe $STAGING_DIR$NATIVEPREFIX/bin/make.exe || true", + "darwin_arm64:*:ln -s make $STAGING_DIR$NATIVEPREFIX/bin/gmake", + "darwin_arm64:*:ln -s make $STAGING_DIR$NATIVEPREFIX/bin/gnumake", + "linux_*:*:ln -s make $STAGING_DIR$NATIVEPREFIX/bin/gmake", + "linux_*:*:ln -s make $STAGING_DIR$NATIVEPREFIX/bin/gnumake", + "windows_amd64:*:cp -f $STAGING_DIR$NATIVEPREFIX/bin/make.exe $STAGING_DIR$NATIVEPREFIX/bin/gmake.exe", + "windows_amd64:*:cp -f $STAGING_DIR$NATIVEPREFIX/bin/make.exe $STAGING_DIR$NATIVEPREFIX/bin/gnumake.exe" ] } } \ No newline at end of file diff --git a/packages/native/meson.json b/packages/native/meson.json new file mode 100644 index 0000000..ba7c2cf --- /dev/null +++ b/packages/native/meson.json @@ -0,0 +1,24 @@ +{ + "package": "native/meson", + "version": "1.9.1", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "751b09390996163348612f0b106114256305ee40", + "url": "https://github.com/mesonbuild/meson.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/python@3.11" + ], + "build": { + "env": [], + "steps": [ + "*:*:python3 ./packaging/create_zipapp.py --outfile meson.pyz --interpreter \"$(which python3)\" .", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin/", + "*:*:mv meson.pyz $STAGING_DIR$NATIVEPREFIX/bin/meson" + ] + } +} \ No newline at end of file diff --git a/packages/native/mpc.json b/packages/native/mpc.json index 1b89487..ddd1403 100644 --- a/packages/native/mpc.json +++ b/packages/native/mpc.json @@ -2,26 +2,30 @@ "package": "native/mpc", "version": "1.3.1", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8", - "url": "http://ftpmirror.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8", + "url": "http://ftpmirror.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz" + } + ], "dependencies": [ - "all:native/gmp", - "all:native/make", - "all:native/mpfr" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/gmp_static", + "*:*:native/make", + "*:*:native/mpfr" ], "build": { "env": [ - "all:config_opts=--prefix=$PREFIX/native", - "all:config_opts=$config_opts --disable-shared", - "all:config_opts=$config_opts --enable-static" + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static" ], "steps": [ - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/mpfr.json b/packages/native/mpfr.json index 939abcc..57a62b8 100644 --- a/packages/native/mpfr.json +++ b/packages/native/mpfr.json @@ -2,25 +2,29 @@ "package": "native/mpfr", "version": "4.2.2", "type": "native", - "download": { - "kind": "tar.xz", - "sha256": "b67ba0383ef7e8a8563734e2e889ef5ec3c3b898a01d00fa0a6869ad81c6ce01", - "url": "http://www.mpfr.org/mpfr-current/mpfr-4.2.2.tar.xz" - }, + "download": [ + { + "kind": "tar.xz", + "sha256": "b67ba0383ef7e8a8563734e2e889ef5ec3c3b898a01d00fa0a6869ad81c6ce01", + "url": "http://www.mpfr.org/mpfr-current/mpfr-4.2.2.tar.xz" + } + ], "dependencies": [ - "all:native/gmp", - "all:native/make" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/gmp_static", + "*:*:native/make" ], "build": { "env": [ - "all:config_opts=--prefix=$PREFIX/native", - "all:config_opts=$config_opts --disable-shared", - "all:config_opts=$config_opts --enable-static" + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static" ], "steps": [ - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/ncurses.json b/packages/native/ncurses.json new file mode 100644 index 0000000..9d0b83d --- /dev/null +++ b/packages/native/ncurses.json @@ -0,0 +1,70 @@ +{ + "package": "native/ncurses", + "version": "6.5", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "136d91bc269a9a5785e5f9e980bc76ab57428f604ce3e5a5a90cebc767971cc6", + "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.5.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/diffutils", + "*:*:native/make", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:config_opts=--host=$HOST --prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --with-build-cc=gcc", + "*:*:config_opts=$config_opts --without-debug", + "*:*:config_opts=$config_opts --without-ada", + "*:*:config_opts=$config_opts --without-cxx-binding", + "*:*:config_opts=$config_opts --without-cxx", + "*:*:config_opts=$config_opts --without-ticlib", + "*:*:config_opts=$config_opts --without-tic", + "*:*:config_opts=$config_opts --without-progs", + "*:*:config_opts=$config_opts --without-tests", + "*:*:config_opts=$config_opts --without-tack", + "*:*:config_opts=$config_opts --without-manpages", + "*:*:config_opts=$config_opts --without-termlib", + "*:*:config_opts=$config_opts --disable-tic-depends", + "*:*:config_opts=$config_opts --disable-big-strings", + "*:*:config_opts=$config_opts --disable-ext-colors", + "*:*:config_opts=$config_opts --enable-pc-files", + "*:*:config_opts=$config_opts --without-shared", + "*:*:config_opts=$config_opts --without-pthread", + "*:*:config_opts=$config_opts --disable-rpath", + "*:*:config_opts=$config_opts --disable-colorfgbg", + "*:*:config_opts=$config_opts --disable-ext-mouse", + "*:*:config_opts=$config_opts --enable-symlinks", + "*:*:config_opts=$config_opts --enable-warnings", + "*:*:config_opts=$config_opts --enable-assertions", + "*:*:config_opts=$config_opts --with-default-terminfo-dir=/etc/_terminfo_", + "*:*:config_opts=$config_opts --with-terminfo-dirs=/etc/_terminfo_", + "*:*:config_opts=$config_opts --enable-database", + "*:*:config_opts=$config_opts --enable-sp-funcs", + "*:*:config_opts=$config_opts --disable-term-driver", + "*:*:config_opts=$config_opts --enable-interop", + "*:*:config_opts=$config_opts --enable-widec" + ], + "steps": [ + "*:*:cp $PATCH_DIR/ncurses/fallback.c ncurses", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES $build_opts", + "*:*:make install.libs install.includes DESTDIR=$STAGING_DIR", + "*:*:cp -f $STAGING_DIR$NATIVEPREFIX/include/ncursesw/panel.h $STAGING_DIR$NATIVEPREFIX/include/panel.h", + "*:*:cp -f $STAGING_DIR$NATIVEPREFIX/include/ncursesw/form.h $STAGING_DIR$NATIVEPREFIX/include/form.h", + "*:*:cp -f $STAGING_DIR$NATIVEPREFIX/include/ncursesw/curses.h $STAGING_DIR$NATIVEPREFIX/include/curses.h", + "*:*:cp -f $STAGING_DIR$NATIVEPREFIX/include/ncursesw/curses.h $STAGING_DIR$NATIVEPREFIX/include/ncurses.h", + "*:*:cp -f $STAGING_DIR$NATIVEPREFIX/lib/libncursesw.a $STAGING_DIR$NATIVEPREFIX/lib/libncurses.a", + "*:*:cp -f $STAGING_DIR$NATIVEPREFIX/lib/libpanelw.a $STAGING_DIR$NATIVEPREFIX/lib/libpanel.a", + "*:*:sed -i.bak '1i#define NCURSES_STATIC' $STAGING_DIR$NATIVEPREFIX/include/ncursesw/ncurses_dll.h" + ] + } +} \ No newline at end of file diff --git a/packages/native/ndk.json b/packages/native/ndk.json new file mode 100644 index 0000000..ba85712 --- /dev/null +++ b/packages/native/ndk.json @@ -0,0 +1,145 @@ +{ + "package": "native/ndk", + "version": "r29", + "type": "native", + "download": [ + { + "kind": "git", + "path": ".repo/manifests", + "sha256": "82eb8adcaafe02dce4e462db2379fad3ea0b54d8", + "url": "https://android.googlesource.com/platform/manifest" + }, + { + "kind": "git", + "path": ".repo/repo", + "sha256": "38d2fe11b9df521727fcca23c9dac086ce8378d3", + "url": "https://gerrit.googlesource.com/git-repo" + }, + { + "kind": "git", + "path": "bionic", + "sha256": "a63b21091ada240d92f8ceadb1cabbdedaaab81b", + "url": "https://android.googlesource.com/platform/bionic" + }, + { + "kind": "git", + "path": "development", + "sha256": "d84a5b9d746f241c3c77b16e8c6964b0f86f86e2", + "url": "https://android.googlesource.com/platform/development" + }, + { + "kind": "git", + "path": "external/effcee", + "sha256": "291037172dcb79318a7d0214a194e985c9ad0d7b", + "url": "https://android.googlesource.com/platform/external/effcee" + }, + { + "kind": "git", + "path": "external/googletest", + "sha256": "dc81c03b5db576f5ab8a468b6eebf584b016fa5b", + "url": "https://android.googlesource.com/platform/external/googletest" + }, + { + "kind": "git", + "path": "external/python/astroid", + "sha256": "062ae590ebac6acf05a5c7583be35870f0b563ba", + "url": "https://android.googlesource.com/platform/external/python/astroid" + }, + { + "kind": "git", + "path": "external/python/pylint", + "sha256": "6169a46fd0a78ed1f3c9fd2c41c1636eb0ed35c5", + "url": "https://android.googlesource.com/platform/external/python/pylint" + }, + { + "kind": "git", + "path": "external/regex-re2", + "sha256": "2e598de2ffcec7903d52742d4ecb80f11e7e1b92", + "url": "https://android.googlesource.com/platform/external/regex-re2" + }, + { + "kind": "git", + "path": "external/shaderc/glslang", + "sha256": "2222fa5818324771ceb99fd8802e54a50a2fb1a4", + "url": "https://android.googlesource.com/platform/external/shaderc/glslang" + }, + { + "kind": "git", + "path": "external/shaderc/shaderc", + "sha256": "8045a61b8c6b79c9fdaa86f36653a824880bab4d", + "url": "https://android.googlesource.com/platform/external/shaderc/shaderc" + }, + { + "kind": "git", + "path": "external/shaderc/spirv-headers", + "sha256": "907059dfed550925a45217e1ed9a7bc42ff8d770", + "url": "https://android.googlesource.com/platform/external/shaderc/spirv-headers" + }, + { + "kind": "git", + "path": "external/shaderc/spirv-tools", + "sha256": "12f5c853ee9e06ba6565006d8d36ee261a140d91", + "url": "https://android.googlesource.com/platform/external/shaderc/spirv-tools" + }, + { + "kind": "git", + "path": "external/vulkan-headers", + "sha256": "062f62b42a62e18a8eaccbce323d4f58548677be", + "url": "https://android.googlesource.com/platform/external/vulkan-headers" + }, + { + "kind": "git", + "path": "ndk", + "sha256": "196e0661200bad5361340700fea67be12e1f1684", + "url": "https://android.googlesource.com/platform/ndk" + }, + { + "kind": "git", + "path": "prebuilts/ndk", + "sha256": "c0815fea3a8081be6215440de330c63246e6551f", + "url": "https://android.googlesource.com/platform/prebuilts/ndk" + }, + { + "kind": "git", + "path": "prebuilts/simpleperf", + "sha256": "c04e1425e49ad7a106bdb5911e7ebbc5ff4afa20", + "url": "https://android.googlesource.com/platform/prebuilts/simpleperf" + }, + { + "kind": "git", + "path": "toolchain/make", + "sha256": "44fc4fe66a484b91844c302f03eaa8438e065d17", + "url": "https://android.googlesource.com/toolchain/make" + }, + { + "kind": "git", + "path": "toolchain/yasm", + "sha256": "7a28367b72cb1e1667b081d6404afbd063898e70", + "url": "https://android.googlesource.com/toolchain/yasm" + } + ], + "dependencies": [ + "*:*-android*:native/_/_", + "*:*-android*:native/cmake", + "*:*-android*:native/llvm@google@19.0.1", + "*:*-android*:native/make", + "*:*-android*:native/ninja", + "*:*-android*:native/python@3.11" + ], + "build": { + "steps": [ + "*:*-android*:mkdir -p prebuilts/clang/host/darwin-x86", + "*:*-android*:mkdir -p prebuilts/clang/host/linux-x86", + "*:*-android*:mkdir -p prebuilts/clang/host/windows-x86", + "*:*-android*:cp -a $NATIVEPREFIX/llvm@google@19.0.1 prebuilts/clang/host/darwin-x86/clang-r563880c", + "*:*-android*:cp -a $NATIVEPREFIX/llvm@google@19.0.1 prebuilts/clang/host/linux-x86/clang-r563880c", + "*:*-android*:cp -a $NATIVEPREFIX/llvm@google@19.0.1 prebuilts/clang/host/windows-x86/clang-r563880c", + "*:*-android*:touch prebuilts/clang/host/darwin-x86/clang-r563880c/NOTICE", + "*:*-android*:touch prebuilts/clang/host/linux-x86/clang-r563880c/NOTICE", + "*:*-android*:touch prebuilts/clang/host/windows-x86/clang-r563880c/NOTICE", + "*:*-android*:mkdir -p prebuilts/simpleperf", + "*:*-android*:touch prebuilts/simpleperf/NOTICE", + "*:*-android*:cd ndk && python3 checkbuild.py" + ] + } +} \ No newline at end of file diff --git a/packages/native/ninja.json b/packages/native/ninja.json index 1af0597..1e2251f 100644 --- a/packages/native/ninja.json +++ b/packages/native/ninja.json @@ -2,21 +2,25 @@ "package": "native/ninja", "version": "1.13.1", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "f0055ad0369bf2e372955ba55128d000cfcc21777057806015b45e4accbebf23", - "url": "https://github.com/ninja-build/ninja/archive/refs/tags/v1.13.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "f0055ad0369bf2e372955ba55128d000cfcc21777057806015b45e4accbebf23", + "url": "https://github.com/ninja-build/ninja/archive/refs/tags/v1.13.1.tar.gz" + } + ], "dependencies": [ - "all:native/python@3.11.13" + "*:*:native/_/_", + "*:*:native/coreutils", + "*:*:native/python@3.11" ], "build": { "env": [], "steps": [ - "all:python3 ./configure.py --bootstrap", - "all:./ninja all", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp ninja $STAGING_DIR$PREFIX/native/bin" + "*:*:python3 ./configure.py --bootstrap", + "*:*:./ninja all", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp ninja $STAGING_DIR$NATIVEPREFIX/bin" ] } } \ No newline at end of file diff --git a/packages/native/nproc.json b/packages/native/nproc.json index c1ff1ec..dabb7c6 100644 --- a/packages/native/nproc.json +++ b/packages/native/nproc.json @@ -2,17 +2,22 @@ "package": "native/nproc", "version": "0.0.1", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "353715a0799c3d965762b1207646b99503deb57603af779547b06c944ace4bad", - "url": "http://github.com/MrCyjaneK/nproc/archive/30acb0de0e18a2b16c277e6db840e5ce389d962d.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "353715a0799c3d965762b1207646b99503deb57603af779547b06c944ace4bad", + "url": "http://github.com/MrCyjaneK/nproc/archive/30acb0de0e18a2b16c277e6db840e5ce389d962d.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_" + ], "build": { "env": [], "steps": [ - "all:mkdir -p $STAGING_DIR$PREFIX/bin", - "all:cp nproc.sh $STAGING_DIR$PREFIX/bin/nproc", - "all:chmod +x $STAGING_DIR$PREFIX/bin/nproc" + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp nproc.sh $STAGING_DIR$NATIVEPREFIX/bin/nproc", + "*:*:chmod +x $STAGING_DIR$NATIVEPREFIX/bin/nproc" ] } } \ No newline at end of file diff --git a/packages/native/openssl.json b/packages/native/openssl.json index a699fcc..1bd05b9 100644 --- a/packages/native/openssl.json +++ b/packages/native/openssl.json @@ -2,29 +2,54 @@ "package": "native/openssl", "version": "3.5.1", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "529043b15cffa5f36077a4d0af83f3de399807181d607441d734196d889b641f", - "url": "http://www.openssl.org/source/openssl-3.5.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "529043b15cffa5f36077a4d0af83f3de399807181d607441d734196d889b641f", + "url": "http://www.openssl.org/source/openssl-3.5.1.tar.gz" + } + ], "dependencies": [ - "all:native/make", - "all:native/perl" + "*:*:native/_/_", + "*:*:native/make", + "*:*:native/perl" ], "build": { "env": [ - "all:config_opts=--prefix=$PREFIX/native --openssldir=$PREFIX/native/etc/openssl --libdir=$PREFIX/native/lib", - "all:config_opts=$config_opts no-ec_nistp_64_gcc_128", - "all:config_opts=$config_opts no-shared", - "all:config_opts=$config_opts no-tests", - "all:config_opts=$config_opts no-unit-test" + "*:*:config_opts=--prefix=$NATIVEPREFIX --openssldir=$NATIVEPREFIX/etc/openssl --libdir=lib", + "*:*:config_opts=$config_opts no-capieng", + "*:*:config_opts=$config_opts no-dso", + "*:*:config_opts=$config_opts no-dtls1", + "*:*:config_opts=$config_opts no-ec_nistp_64_gcc_128", + "*:*:config_opts=$config_opts no-gost", + "*:*:config_opts=$config_opts no-md2", + "*:*:config_opts=$config_opts no-rc5", + "*:*:config_opts=$config_opts no-rdrand", + "*:*:config_opts=$config_opts no-rfc3779", + "*:*:config_opts=$config_opts no-sctp", + "*:*:config_opts=$config_opts no-shared", + "*:*:config_opts=$config_opts no-ssl-trace", + "*:*:config_opts=$config_opts no-ssl3", + "*:*:config_opts=$config_opts no-tests", + "*:*:config_opts=$config_opts no-unit-test", + "*:*:config_opts=$config_opts no-weak-ssl-ciphers", + "*:*:config_opts=$config_opts no-zlib", + "*:*:config_opts=$config_opts no-zlib-dynamic", + "linux_*:*:config_opts=$config_opts -fPIC -Wa,--noexecstack", + "linux_amd64:*:config_opts=$config_opts linux-x86_64", + "linux_arm64:*:config_opts=$config_opts linux-generic64", + "darwin_arm64:*:config_opts=$config_opts darwin64-arm64-cc", + "darwin_amd64:*:config_opts=$config_opts darwin64-x86_64-cc", + "windows_amd64:*:config_opts=$config_opts -fPIC", + "windows_amd64:*:config_opts=$config_opts no-winstore", + "windows_amd64:*:config_opts=$config_opts Cygwin-x86_64" ], "steps": [ - "all:sed -i.bak 's/#define DATE \"built on: \\$date\"/#define DATE \"built on: Jan 1 1970 00:00:01\"/' util/mkbuildinf.pl", - "all:sed -i.bak 's|crypto ssl apps util tools fuzz providers doc|crypto ssl util tools providers|' build.info", - "all:./Configure $config_opts", - "all:make -j$NUM_CORES build_libs", - "all:make -j$NUM_CORES DESTDIR=$STAGING_DIR install_sw" + "*:*:sed -i.bak 's/#define DATE \"built on: \\$date\"/#define DATE \"built on: Jan 1 1970 00:00:01\"/' util/mkbuildinf.pl", + "*:*:sed -i.bak 's|crypto ssl apps util tools fuzz providers doc|crypto ssl util tools providers|' build.info", + "*:*:./Configure $config_opts", + "*:*:make -j$NUM_CORES build_libs", + "*:*:make -j$NUM_CORES DESTDIR=$STAGING_DIR install_sw" ] } } \ No newline at end of file diff --git a/packages/native/osx-cross.json b/packages/native/osx-cross.json new file mode 100644 index 0000000..1bfaf60 --- /dev/null +++ b/packages/native/osx-cross.json @@ -0,0 +1,91 @@ +{ + "package": "native/osx-cross", + "version": "master", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "ea17212e41970b9f602fb30898b5a4013a1fb7af", + "url": "https://github.com/MrCyjaneK/osxcross.git" + }, + { + "kind": "blob", + "path": "tarballs/llvmorg-20.1.8.zip", + "sha256": "b115ce6285dd9f3f401459912c12d28eb2e2d81e2387a71f6300aa11f7bc3288", + "url": "https://github.com/llvm/llvm-project/archive/refs/tags/llvmorg-20.1.8.zip" + }, + { + "kind": "blob", + "path": "tarballs/20250402.zip", + "sha256": "b8e87f026e19259e6eac347746661e11592e0ff8bcdb657e177800223d7438ce", + "url": "https://github.com/apple/llvm-project/archive/refs/heads/stable/20250402.zip" + } + ], + "dependencies": [ + "*:*-apple-*:native/7zip", + "*:*-apple-*:native/_/_", + "*:*-apple-*:native/apple-sdk", + "*:*-apple-*:native/bash", + "*:*-apple-*:native/bzip2", + "*:*-apple-*:native/cmake", + "*:*-apple-*:native/coreutils", + "*:*-apple-*:native/cpio", + "*:*-apple-*:native/curl", + "*:*-apple-*:native/gettext", + "*:*-apple-*:native/git", + "*:*-apple-*:native/libtapi", + "*:*-apple-*:native/libxml2", + "*:*-apple-*:native/make", + "*:*-apple-*:native/openssl", + "*:*-apple-*:native/patch", + "*:*-apple-*:native/pbzx", + "*:*-apple-*:native/perl", + "*:*-apple-*:native/pkgconf", + "*:*-apple-*:native/python@3.11", + "*:*-apple-*:native/sed", + "*:*-apple-*:native/unzip", + "*:*-apple-*:native/xar", + "*:*-apple-*:native/xz" + ], + "build": { + "env": [ + "*:*-apple-*:SKIP_BUILD_XAR=yes", + "*:*-apple-*:SKIP_BUILD_P7ZIP=yes", + "*:*-apple-*:SKIP_BUILD_PBXZ=yes", + "*:*-apple-*:SKIP_GIT=yes", + "*:*-apple-*:SKIP_DOWNLOAD=yes", + "*:*-apple-*:ENABLE_FULL_BOOTSTRAP=yes", + "*:*-apple-*:SKIP_TAPI_BUILD=yes", + "*:*-apple-*:SKIP_CCTOOLS_BUILD=yes", + "*:*-apple-*:JOBS=$NUM_CORES", + "*:*-apple-*:PORTABLE=1", + "*:*-apple-*:TARGET_DIR=$NATIVEPREFIX/", + "*:*-apple-*:UNATTENDED=1", + "*:*-apple-*:SDK_VERSION=26.1", + "*:*-apple-*:COMPRESSLEVEL=6", + "darwin_arm64:*-apple-*:LDFLAGS=-fuse-ld=$NATIVEPREFIX/_/bin/ld", + "{linux_*,windows_*}:*-apple-*:LDFLAGS=$LDFLAGS -fuse-ld=lld -L$NATIVEPREFIX/_/sysroot/lib", + "{linux_*,windows_*}:*-apple-*:CXXFLAGS=$CXXFLAGS -fuse-ld=lld" + ], + "steps": [ + "*:*-apple-*:mkdir -p wrapper/bin", + "*:*-apple-*:printf '#!/bin/sh\\ncase \"$1\" in\\n -productVersion) echo %s ;;\\n *) echo %s ;;\\nesac\\n' \"${SDK_VERSION}\" \"${SDK_VERSION}\" > wrapper/bin/sw_vers", + "*:*-apple-*:chmod +x wrapper/bin/sw_vers", + "darwin_arm64:*-apple-*:rm -f $NATIVEPREFIX/_/bin/ld $NATIVEPREFIX/_/bin/ld64.lld", + "darwin_arm64:*-apple-*:sed \"s|@LD64_LLD@|$NATIVEPREFIX/_/bin/lld|g; s|@SDK_VERSION@|$SDK_VERSION|g\" $PATCH_DIR/native/osx-cross/classic-ld-wrapper.sh > $NATIVEPREFIX/_/bin/ld && chmod +x $NATIVEPREFIX/_/bin/ld", + "darwin_arm64:*-apple-*:cp $NATIVEPREFIX/_/bin/ld $NATIVEPREFIX/_/bin/ld64.lld && chmod +x $NATIVEPREFIX/_/bin/ld64.lld", + "*:*-apple-*:sed -i.bak 's/--with-libtapi=$TARGET_DIR/--with-libtapi=$PREFIX\\/native/g' build.sh", + "*:*-apple-*:sed -i.bak 's/--with-libxar=$TARGET_DIR/--with-libxar=$PREFIX\\/native/g' build.sh", + "*:*-apple-*:mv $NATIVEPREFIX/share/xcode-sdk/*${SDK_VERSION}* tarballs", + "darwin_arm64:*-apple-*:sed -i.bak 's|-DLLVM_TEMPORARILY_ALLOW_OLD_TOOLCHAIN=1|-DLLVM_TEMPORARILY_ALLOW_OLD_TOOLCHAIN=1 -DCMAKE_OSX_SYSROOT=$NATIVEPREFIX/_/SDK/MacOSX${SDK_VERSION}.sdk -DCMAKE_OSX_DEPLOYMENT_TARGET=$OSX_MIN_VERSION -DHOST_LINK_VERSION=711 -DCMAKE_EXE_LINKER_FLAGS=-fuse-ld=$NATIVEPREFIX/_/bin/ld -DCMAKE_SHARED_LINKER_FLAGS=-fuse-ld=$NATIVEPREFIX/_/bin/ld|' build_clang.sh", + "{linux_*,windows_*}:*-apple-*:sed -i.bak 's|-DLLVM_TEMPORARILY_ALLOW_OLD_TOOLCHAIN=1|-DLLVM_TEMPORARILY_ALLOW_OLD_TOOLCHAIN=1 -DCMAKE_OSX_SYSROOT=$NATIVEPREFIX/_/SDK/MacOSX${SDK_VERSION}.sdk -DCMAKE_OSX_DEPLOYMENT_TARGET=$OSX_MIN_VERSION|' build_clang.sh", + "{linux_*,windows_*}:*-apple-*:sed -i.bak 's|export CFLAGS=\"\"|export CFLAGS=\"--gcc-toolchain=$NATIVEPREFIX/_/libexec/gcc-toolchain --sysroot=$NATIVEPREFIX/_/sysroot\"|' build_clang.sh", + "{linux_*,windows_*}:*-apple-*:sed -i.bak 's|export CXXFLAGS=\"\"|export CXXFLAGS=\"--gcc-toolchain=$NATIVEPREFIX/_/libexec/gcc-toolchain --sysroot=$NATIVEPREFIX/_/sysroot\"|' build_clang.sh", + "*:*-apple-*:export PATH=$PWD/wrapper/bin:$PATH && CC=$NATIVEPREFIX/_/bin/clang-21 CXX=$NATIVEPREFIX/_/bin/clang++-21 LDFLAGS=-fuse-ld=$NATIVEPREFIX/_/bin/ld yes | INSTALLPREFIX=$NATIVEPREFIX ./build_apple_clang.sh", + "*:*-apple-*:cd build/clang-21/build_stage3 && make -j$NUM_CORES install DESTDIR=$STAGING_DIR && make -j$NUM_CORES install", + "*:*-apple-*:sed -i.bak 's/## Compiler test ##/exit 0/g' build.sh", + "*:*-apple-*:export PATH=$PWD/wrapper/bin:$PATH && OCDEBUG=1 TARGET_DIR=$STAGING_DIR$NATIVEPREFIX bash -x ./build.sh", + "*:*-apple-*:rm $STAGING_DIR$NATIVEPREFIX/bin/*pkg-config" + ] + } +} \ No newline at end of file diff --git a/packages/native/p7zip.json b/packages/native/p7zip.json deleted file mode 100644 index 2dd53e3..0000000 --- a/packages/native/p7zip.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "package": "native/p7zip", - "version": "1_36_1", - "type": "native", - "download": { - "kind": "tar.bz2", - "sha256": "5eb20ac0e2944f6cb9c2d51dd6c4518941c185347d4089ea89087ffdd6e2341f", - "url": "http://downloads.sourceforge.net/project/p7zip/p7zip/16.02/p7zip_16.02_src_all.tar.bz2" - }, - "dependencies": [ - "all:native/make" - ], - "build": { - "env": [], - "steps": [ - "all:if [ $(uname) = 'Darwin' ]; then cp makefile.macosx_llvm_64bits makefile.machine; else true; fi", - "all:if [ $(uname) = 'Linux' ]; then cp makefile.linux_any_cpu makefile.machine; else true; fi", - "all:sed -i.bak 's/switch(errorCode)/switch(static_cast(errorCode))/' ./CPP/Windows/ErrorMsg.cpp", - "all:make -j$NUM_CORES 7za", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp bin/7za $STAGING_DIR$PREFIX/native/bin/7z" - ] - } -} \ No newline at end of file diff --git a/packages/native/patch.json b/packages/native/patch.json index 3112d5c..6daf2f2 100644 --- a/packages/native/patch.json +++ b/packages/native/patch.json @@ -2,22 +2,26 @@ "package": "native/patch", "version": "2.8", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "308a4983ff324521b9b21310bfc2398ca861798f02307c79eb99bb0e0d2bf980", - "url": "http://ftpmirror.gnu.org/gnu/patch/patch-2.8.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "308a4983ff324521b9b21310bfc2398ca861798f02307c79eb99bb0e0d2bf980", + "url": "http://ftpmirror.gnu.org/gnu/patch/patch-2.8.tar.gz" + } + ], "dependencies": [ - "all:native/make" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make" ], "build": { "env": [ - "all:config_opts=--prefix=$PREFIX/native" + "*:*:config_opts=--prefix=$NATIVEPREFIX" ], "steps": [ - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/pbzx.json b/packages/native/pbzx.json new file mode 100644 index 0000000..657ad67 --- /dev/null +++ b/packages/native/pbzx.json @@ -0,0 +1,25 @@ +{ + "package": "native/pbzx", + "version": "1.6.1-patch", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "a9b3e9f29d9f020f75e4edf203359fbed6c1b0d2085f386bf770feaf07ae1694", + "url": "https://github.com/tpoechtrager/pbzx/archive/2a4d7c3300c826d918def713a24d25c237c8ed53.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/make", + "*:*:native/xar", + "*:*:native/xz" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:$CC -O2 -Wall -I $NATIVEPREFIX/include -L $NATIVEPREFIX/lib pbzx.c -o $STAGING_DIR$NATIVEPREFIX/bin/pbzx -llzma -lxar -Wl,-rpath,$NATIVEPREFIX/lib" + ] + } +} \ No newline at end of file diff --git a/packages/native/pcre2.json b/packages/native/pcre2.json new file mode 100644 index 0000000..9c9336b --- /dev/null +++ b/packages/native/pcre2.json @@ -0,0 +1,32 @@ +{ + "package": "native/pcre2", + "version": "10.47", + "type": "native", + "download": [ + { + "kind": "tar.bz2", + "sha256": "47fe8c99461250d42f89e6e8fdaeba9da057855d06eb7fc08d9ca03fd08d7bc7", + "url": "https://github.com/PCRE2Project/pcre2/releases/download/pcre2-10.47/pcre2-10.47.tar.bz2" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/libtool", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/pkgconf" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/perl.json b/packages/native/perl.json index 0f90774..2bfa20a 100644 --- a/packages/native/perl.json +++ b/packages/native/perl.json @@ -1,22 +1,34 @@ { "package": "native/perl", - "version": "5.42.0", + "version": "5.42.1", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "e093ef184d7f9a1b9797e2465296f55510adb6dab8842b0c3ed53329663096dc", - "url": "http://www.cpan.org/src/5.0/perl-5.42.0.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "6f84e6dc8cce97181d1c6aeeb552c13775c91ded3c6c73743c9211af87b16bf8", + "url": "http://www.cpan.org/src/5.0/perl-5.42.1.tar.gz" + } + ], "dependencies": [ - "all:native/make" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/sed" ], "build": { "env": [], "steps": [ - "all:sed -i.bak '/^#ifndef PERL_BUILD_DATE$/,/^#endif$/{/^#ifndef PERL_BUILD_DATE$/!d; s/.*/\\#define PERL_BUILD_DATE \"Jan 1 1970 00:00:01\"/;}' perl.c", - "all:./Configure -des -Dprefix=$PREFIX/native -Duseithreads -Dall_static", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/lib $NATIVEPREFIX/lib", + "*:*:sed -i.bak '/^#ifndef PERL_BUILD_DATE$/,/^#endif$/{/^#ifndef PERL_BUILD_DATE$/!d; s/.*/\\#define PERL_BUILD_DATE \"Jan 1 1970 00:00:01\"/;}' perl.c", + "linux_*:*:bash ./Configure -des -Dprefix=$NATIVEPREFIX -Duseithreads -Dall_static -Dcc=$CC -Dlibs=\"-lpthread -ldl -lm -lutil -lc\"", + "darwin_*:*:bash ./Configure -des -Dprefix=$NATIVEPREFIX -Duseithreads -Dall_static -Dcc=$CC -Dlibs=\"-lpthread -ldl -lm -lutil -lc\"", + "windows_amd64:*:bash ./Configure -des -Dprefix=$NATIVEPREFIX -Duseithreads -Dcc=$CC -Dld=$CC -Dlibs=\"-lm\"", + "windows_amd64:*:sed -i.bak \"s|^PATH=.*|PATH='.:$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:/usr/bin/'|\" config.sh", + "windows_amd64:*:bash ./Configure -S", + "linux_*:*:make -j$NUM_CORES CC=$CC", + "darwin_*:*:make -j$NUM_CORES CC=$CC", + "windows_amd64:*:make -j1 CC=$CC", + "*:*:make DESTDIR=$STAGING_DIR install CC=$CC" ] } } \ No newline at end of file diff --git a/packages/native/pkgconf.json b/packages/native/pkgconf.json index 60ba8c0..1574a26 100644 --- a/packages/native/pkgconf.json +++ b/packages/native/pkgconf.json @@ -2,29 +2,31 @@ "package": "native/pkgconf", "version": "2.5.1", "type": "native", - "download": { - "kind": "git", - "sha256": "4fc570f91d9d8d843ab32d2198a5c064538d8ffd", - "url": "http://github.com/pkgconf/pkgconf.git" - }, + "download": [ + { + "kind": "git", + "sha256": "4fc570f91d9d8d843ab32d2198a5c064538d8ffd", + "url": "http://github.com/pkgconf/pkgconf.git" + } + ], "dependencies": [ - "all:native/autoconf", - "all:native/automake", - "all:native/libtool", - "all:native/m4", - "all:native/make", - "all:native/perl" + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" ], "build": { - "env": [ - "all:PKGCONFIG_DIR=$PREFIX/native/lib/pkgconfig:$PREFIX/lib/pkgconfig" - ], + "env": [], "steps": [ - "all:sh ./autogen.sh", - "all:./configure --prefix=$PREFIX/native --with-pkg-config-dir=$PKGCONFIG_DIR", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install", - "all:ln -s pkgconf $STAGING_DIR$PREFIX/native/bin/pkg-config" + "*:*:bash ./autogen.sh", + "*:*:bash ./configure --prefix=$NATIVEPREFIX --with-pkg-config-dir=$NATIVEPREFIX/lib/pkgconfig", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:ln -s pkgconf $STAGING_DIR$NATIVEPREFIX/bin/pkg-config" ] } } \ No newline at end of file diff --git a/packages/native/protobuf.json b/packages/native/protobuf.json index 967d56e..2478d36 100644 --- a/packages/native/protobuf.json +++ b/packages/native/protobuf.json @@ -2,41 +2,42 @@ "package": "native/protobuf", "version": "3.6.1", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "b3732e471a9bb7950f090fd0457ebd2536a9ba0891b7f3785919c654fe2a2529", - "url": "http://github.com/protocolbuffers/protobuf/releases/download/v3.6.1/protobuf-cpp-3.6.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "b3732e471a9bb7950f090fd0457ebd2536a9ba0891b7f3785919c654fe2a2529", + "url": "http://github.com/protocolbuffers/protobuf/releases/download/v3.6.1/protobuf-cpp-3.6.1.tar.gz" + } + ], "dependencies": [ - "all:native/autoconf", - "all:native/automake", - "all:native/config", - "all:native/m4", - "all:native/make", - "all:native/perl" + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/config", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" ], "build": { "env": [ - "all:config_opts=--host=$HOST --prefix=$PREFIX/native", - "all:config_opts=$config_opts --disable-shared", - "*-linux-gnu:config_opts=$config_opts --with-pic", - "*-linux-gnu:SHOULD_BUILD=", - "*-w64-mingw32:SHOULD_BUILD=", - "*-apple-darwin:SHOULD_BUILD=" + "*:*:config_opts=--host=$HOST --prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*-linux-gnu:config_opts=$config_opts --with-pic" ], "steps": [ - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.guess config.guess", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.sub config.sub", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.guess third_party/googletest/googletest/build-aux/config.guess", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.sub third_party/googletest/googletest/build-aux/config.sub", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.guess third_party/googletest/googlemock/build-aux/config.guess", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.sub third_party/googletest/googlemock/build-aux/config.sub", - "all:$SHOULD_BUILD aclocal", - "all:$SHOULD_BUILD automake --add-missing", - "all:$SHOULD_BUILD ./configure $config_opts", - "all:$SHOULD_BUILD make -j$NUM_CORES", - "all:$SHOULD_BUILD make -j$NUM_CORES DESTDIR=$STAGING_DIR install", - "all:$SHOULD_BUILD rm $STAGING_DIR$PREFIX/native/lib/libprotoc.a || true" + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess config.guess", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub config.sub", + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess third_party/googletest/googletest/build-aux/config.guess", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub third_party/googletest/googletest/build-aux/config.sub", + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess third_party/googletest/googlemock/build-aux/config.guess", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub third_party/googletest/googlemock/build-aux/config.sub", + "*:*:aclocal", + "*:*:automake --add-missing", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make -j$NUM_CORES DESTDIR=$STAGING_DIR install", + "*:*:rm $STAGING_DIR$NATIVEPREFIX/lib/libprotoc.a || true" ] } } \ No newline at end of file diff --git a/packages/native/protobuf@21.12.json b/packages/native/protobuf@21.12.json new file mode 100644 index 0000000..c5f0845 --- /dev/null +++ b/packages/native/protobuf@21.12.json @@ -0,0 +1,25 @@ +{ + "package": "native/protobuf@21.12", + "version": "21.12", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "22fdaf641b31655d4b2297f9981fa5203b2866f8332d3c6333f6b0107bb320de", + "url": "https://github.com/protocolbuffers/protobuf/archive/refs/tags/v21.12.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/cmake", + "*:*:native/make" + ], + "build": { + "env": [], + "steps": [ + "*:*:cmake -S . -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=$NATIVEPREFIX -Dprotobuf_BUILD_TESTS=OFF -Dprotobuf_BUILD_SHARED_LIBS=OFF -Dprotobuf_WITH_ZLIB=OFF", + "*:*:cmake --build build -j$NUM_CORES", + "*:*:DESTDIR=$STAGING_DIR cmake --install build" + ] + } +} \ No newline at end of file diff --git a/packages/native/python@3.11.13.json b/packages/native/python@3.11.13.json deleted file mode 100644 index e863421..0000000 --- a/packages/native/python@3.11.13.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "package": "native/python@3.11.13", - "version": "3.11.13", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "0f1a22f4dfd34595a29cf69ee7ea73b9eff8b1cc89d7ab29b3ab0ec04179dad8", - "url": "http://www.python.org/ftp/python/3.11.13/Python-3.11.13.tgz" - }, - "dependencies": [ - "all:native/make", - "all:native/patch", - "all:native/zlib" - ], - "build": { - "env": [], - "steps": [ - "all:sed -i.bak '/^#ifndef DATE/i\\\n\\/* Deterministic date and time. *\\/\\\n#define DATE \"Jan 1 1970\"\\\n#define TIME \"00:00:01\"' Modules/getbuildinfo.c", - "all:sed -i.bak 's/^#\\(zlib[[:space:]]\\+zlibmodule\\.c[[:space:]]\\+-lz\\)/\\1/' Modules/Setup", - "all:./configure --disable-test-modules --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install", - "none:mkdir -p $STAGING_DIR$PREFIX/native/python3.11.13", - "none:cp -r pybuild/* $STAGING_DIR$PREFIX/native/python3.11.13" - ] - } -} \ No newline at end of file diff --git a/packages/native/python@3.11.json b/packages/native/python@3.11.json new file mode 100644 index 0000000..067d685 --- /dev/null +++ b/packages/native/python@3.11.json @@ -0,0 +1,40 @@ +{ + "package": "native/python@3.11", + "version": "3.11.13", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "0f1a22f4dfd34595a29cf69ee7ea73b9eff8b1cc89d7ab29b3ab0ec04179dad8", + "url": "http://www.python.org/ftp/python/3.11.13/Python-3.11.13.tgz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/gettext", + "*:*:native/libiconv", + "*:*:native/make", + "*:*:native/patch", + "*:*:native/pkgconf", + "*:*:native/zlib" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-test-modules", + "*:*:config_opts=$config_opts --enable-static", + "*:*:config_opts=$config_opts --without-ensurepip", + "*:*:MACOSX_DEPLOYMENT_TARGET=13.0", + "darwin_*:*:LIBS=-lintl -liconv" + ], + "steps": [ + "*:*:sed -i.bak '/^#ifndef DATE/i\\\n\\/* Deterministic date and time. *\\/\\\n#define DATE \"Jan 1 1970\"\\\n#define TIME \"00:00:01\"\\\n' Modules/getbuildinfo.c", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:ln -sf python3.11 $STAGING_DIR$NATIVEPREFIX/bin/python3", + "*:*:ln -sf python3.11 $STAGING_DIR$NATIVEPREFIX/bin/python" + ] + } +} \ No newline at end of file diff --git a/packages/native/python@3.14.json b/packages/native/python@3.14.json new file mode 100644 index 0000000..1fa1acc --- /dev/null +++ b/packages/native/python@3.14.json @@ -0,0 +1,43 @@ +{ + "package": "native/python@3.14", + "version": "3.14.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "88d2da4eed42fa9a5f42ff58a8bc8988881bd6c547e297e46682c2687638a851", + "url": "http://www.python.org/ftp/python/3.14.0/Python-3.14.0.tgz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/gettext", + "*:*:native/libiconv", + "*:*:native/make", + "*:*:native/openssl", + "*:*:native/patch", + "*:*:native/pkgconf", + "*:*:native/zlib" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-test-modules", + "*:*:config_opts=$config_opts --enable-static", + "*:*:config_opts=$config_opts --with-openssl=$NATIVEPREFIX", + "*:*:MACOSX_DEPLOYMENT_TARGET=13.0", + "darwin_*:*:LIBS=-lintl -liconv" + ], + "steps": [ + "*:*:sed -i.bak '/^#ifndef DATE/i\\\n\\/* Deterministic date and time. *\\/\\\n#define DATE \"Jan 1 1970\"\\\n#define TIME \"00:00:01\"\\\n' Modules/getbuildinfo.c", + "windows_*:*:patch -p1 < $PATCH_DIR/native/python@3.14/cygwin-clockid-t.patch", + "windows_*:*:patch -p1 < $PATCH_DIR/native/python@3.14/cygwin-dynload-suffix.patch", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:ln -sf python3.14 $STAGING_DIR$NATIVEPREFIX/bin/python3", + "*:*:ln -sf python3.14 $STAGING_DIR$NATIVEPREFIX/bin/python" + ] + } +} \ No newline at end of file diff --git a/packages/native/python@3.14/flit-core.json b/packages/native/python@3.14/flit-core.json new file mode 100644 index 0000000..39c8391 --- /dev/null +++ b/packages/native/python@3.14/flit-core.json @@ -0,0 +1,21 @@ +{ + "package": "native/python@3.14/flit-core", + "version": "0.0.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "92c9486a543c4db266e3908bffc984060b8466af", + "url": "https://github.com/pypa/flit.git" + } + ], + "dependencies": [ + "*:*:native/python@3.14" + ], + "build": { + "env": [], + "steps": [ + "*:*:cd flit_core && pip3 install --root $STAGING_DIR --prefix $NATIVEPREFIX --no-deps --no-build-isolation --no-index --disable-pip-version-check ." + ] + } +} \ No newline at end of file diff --git a/packages/native/python@3.14/packaging.json b/packages/native/python@3.14/packaging.json new file mode 100644 index 0000000..6167b1d --- /dev/null +++ b/packages/native/python@3.14/packaging.json @@ -0,0 +1,22 @@ +{ + "package": "native/python@3.14/packaging", + "version": "26.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "3b77a26f5a27473ad3b08194d773f325d018a2d0", + "url": "https://github.com/pypa/packaging" + } + ], + "dependencies": [ + "*:*:native/python@3.14", + "*:*:native/python@3.14/flit-core" + ], + "build": { + "env": [], + "steps": [ + "*:*:pip3 install --root $STAGING_DIR --prefix $NATIVEPREFIX --no-deps --no-build-isolation --no-index --disable-pip-version-check ." + ] + } +} \ No newline at end of file diff --git a/packages/native/python@3.14/pyproject-hooks.json b/packages/native/python@3.14/pyproject-hooks.json new file mode 100644 index 0000000..73531da --- /dev/null +++ b/packages/native/python@3.14/pyproject-hooks.json @@ -0,0 +1,22 @@ +{ + "package": "native/python@3.14/pyproject-hooks", + "version": "1.2.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "4b7c6d113fb89b755d762a88712c8a6873cddd47", + "url": "https://github.com/pypa/pyproject-hooks" + } + ], + "dependencies": [ + "*:*:native/python@3.14", + "*:*:native/python@3.14/flit-core" + ], + "build": { + "env": [], + "steps": [ + "*:*:pip3 install --root $STAGING_DIR --prefix $NATIVEPREFIX --no-deps --no-build-isolation --no-index --disable-pip-version-check ." + ] + } +} \ No newline at end of file diff --git a/packages/native/python@3.14/tomli.json b/packages/native/python@3.14/tomli.json new file mode 100644 index 0000000..f21328a --- /dev/null +++ b/packages/native/python@3.14/tomli.json @@ -0,0 +1,24 @@ +{ + "package": "native/python@3.14/tomli", + "version": "2.4.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "a678e6fdeffa89bd28e4ecc148b926a4e1bbbc7b", + "url": "https://github.com/hukkin/tomli" + } + ], + "dependencies": [ + "*:*:native/make", + "*:*:native/python@3.14", + "*:*:native/python@3.14/flit-core", + "*:*:native/python@3.14/pyproject-hooks" + ], + "build": { + "env": [], + "steps": [ + "*:*:pip3 install --root $STAGING_DIR --prefix $NATIVEPREFIX --no-deps --no-build-isolation --no-index --disable-pip-version-check ." + ] + } +} \ No newline at end of file diff --git a/packages/native/qemu.json b/packages/native/qemu.json new file mode 100644 index 0000000..db6268c --- /dev/null +++ b/packages/native/qemu.json @@ -0,0 +1,36 @@ +{ + "package": "native/qemu", + "version": "10.2.1", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "a3717477d8e2c84d630bfffbc20f6cd3293eb45aa1e6dac6d0cc27689991c9e1", + "url": "https://download.qemu.org/qemu-10.2.1.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/glib2", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/pcre2", + "*:*:native/perl", + "*:*:native/pkgconf", + "*:*:native/python@3.14", + "*:*:native/python@3.14/tomli", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/qt@6_11_1.json b/packages/native/qt@6_11_1.json new file mode 100644 index 0000000..b8ccdc4 --- /dev/null +++ b/packages/native/qt@6_11_1.json @@ -0,0 +1,62 @@ +{ + "package": "native/qt@6_11_1", + "version": "6_11_1", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "path": "qtbase", + "sha256": "d9594a31228aa23ad6b531719a29b45f0f3989fe6c136d45767ea179f233c1ac", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtbase-everywhere-src-6.11.1.tar.xz" + }, + { + "kind": "tar.xz", + "path": "qttools", + "sha256": "8e61835a679c93fa9c6065b142353c2071ba68e297898937c32a03777fcaf50d", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qttools-everywhere-src-6.11.1.tar.xz" + }, + { + "kind": "tar.xz", + "path": "qtshadertools", + "sha256": "2075052f9b23bcf9de045bbd180037084942f82cce870aab14a1454902c982fc", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtshadertools-everywhere-src-6.11.1.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/cmake", + "*:*:native/ninja", + "*:*:native/patch", + "*:*:native/perl", + "*:*:native/pkgconf", + "*:*:native/sed", + "*:*-linux-*:native/wayland@1_25_0" + ], + "patches": [ + "root_CMakeLists.txt", + "rcc_hardcode_timestamp.patch", + "guix_cross_lib_path.patch", + "qtbase-moc-ignore-gcc-macro.patch" + ], + "export-env": [ + "*:*:QT_HOST_PATH=$NATIVEPREFIX/qt-host", + "*:*:PATH=$NATIVEPREFIX/qt-host/bin:$PATH" + ], + "build": { + "env": [ + "*:*:config_opts=-release -libexecdir $NATIVEPREFIX/qt-host/bin -c++std c++17 -confirm-license -opensource -pkg-config -prefix $NATIVEPREFIX/qt-host -static -platform linux-g++ -xplatform linux-g++", + "*:*-linux-*:config_opts=$config_opts -xplatform linux-clang-libc++", + "*:*:config_opts=$config_opts -no-cups -no-egl -no-eglfs -no-evdev -no-feature-colordialog -no-feature-dial -no-feature-fontcombobox -no-feature-fontconfig -no-feature-freetype -no-feature-harfbuzz -no-feature-image_heuristic_mask -no-feature-keysequenceedit -no-feature-lcdnumber -no-feature-networkdiskcache -no-feature-pdf -no-feature-printdialog -no-feature-printer -no-feature-printpreviewdialog -no-feature-printpreviewwidget -no-feature-qmake -no-feature-sessionmanager -no-feature-sql -no-feature-syntaxhighlighter -no-feature-testlib -no-feature-textmarkdownwriter -no-feature-textodfwriter -no-feature-topleveldomain -no-feature-undocommand -no-feature-undogroup -no-feature-undostack -no-feature-undoview -no-feature-vnc -no-feature-vulkan -no-feature-widgets -no-feature-xkbcommon -no-feature-xlib -no-gif -no-glib -no-ico -no-icu -no-kms -no-libjpeg -no-libudev -no-linuxfb -nomake examples -nomake tests -no-mtdev -no-opengl -no-openssl -no-openvg -no-pch -no-reduce-relocations -no-sbom -no-schannel -no-sctp -no-securetransport -no-system-proxies -no-use-gold-linker -no-xcb-xlib -no-zstd" + ], + "steps": [ + "*:*:for mod in qtbase qttools qtshadertools; do inner=$mod/$mod-everywhere-src-*; if [ -d $inner ]; then mv $inner/* $mod/ && rmdir $inner; fi; done", + "*:*:cp $PATCH_DIR/native_qt/root_CMakeLists.txt CMakeLists.txt", + "*:*:patch -p1 < $PATCH_DIR/native_qt/qtbase-moc-ignore-gcc-macro.patch", + "*:*:patch -p1 < $PATCH_DIR/native_qt/rcc_hardcode_timestamp.patch", + "*:*:patch -p1 < $PATCH_DIR/native_qt/guix_cross_lib_path.patch", + "*:*:cd qtbase && ./configure -top-level $config_opts", + "*:*:cmake --build . --parallel", + "*:*:DESTDIR=$STAGING_DIR cmake --install ." + ] + } +} \ No newline at end of file diff --git a/packages/native/rsync.json b/packages/native/rsync.json index b8841b5..5cd5681 100644 --- a/packages/native/rsync.json +++ b/packages/native/rsync.json @@ -2,27 +2,31 @@ "package": "native/rsync", "version": "3.4.1", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "2924bcb3a1ed8b551fc101f740b9f0fe0a202b115027647cf69850d65fd88c52", - "url": "https://github.com/RsyncProject/rsync/releases/download/v3.4.1/rsync-3.4.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "2924bcb3a1ed8b551fc101f740b9f0fe0a202b115027647cf69850d65fd88c52", + "url": "https://github.com/RsyncProject/rsync/releases/download/v3.4.1/rsync-3.4.1.tar.gz" + } + ], "dependencies": [ - "all:native/make", - "all:native/python@3.11.13" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/python@3.11" ], "build": { "env": [ - "all:config_opts=--prefix=$PREFIX/native", - "all:config_opts=$config_opts --disable-xxhash", - "all:config_opts=$config_opts --disable-openssl", - "all:config_opts=$config_opts --disable-zstd", - "all:config_opts=$config_opts --disable-lz4" + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-xxhash", + "*:*:config_opts=$config_opts --disable-openssl", + "*:*:config_opts=$config_opts --disable-zstd", + "*:*:config_opts=$config_opts --disable-lz4" ], "steps": [ - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/rust-toolchain.json b/packages/native/rust-toolchain.json new file mode 100644 index 0000000..d309781 --- /dev/null +++ b/packages/native/rust-toolchain.json @@ -0,0 +1,17 @@ +{ + "package": "native/rust-toolchain", + "version": "1.95.0", + "type": "native", + "dependencies": [ + "*:*:native/coreutils", + "*:*:native/rust" + ], + "build": { + "steps": [ + "*:*:$NATIVEPREFIX/bin/mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a $NATIVEPREFIX/bin/rustc $NATIVEPREFIX/bin/cargo $STAGING_DIR$NATIVEPREFIX/bin/", + "*:*:cp -a $NATIVEPREFIX/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:rm -rf $STAGING_DIR$NATIVEPREFIX/lib/rustlib" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust.json b/packages/native/rust.json new file mode 100644 index 0000000..4238ee5 --- /dev/null +++ b/packages/native/rust.json @@ -0,0 +1,51 @@ +{ + "package": "native/rust", + "version": "1.95.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "ea9b82a83e46967537c3569ce9d6fa16811c043a96e651376c349e70241ca515", + "url": "http://static.rust-lang.org/dist/rustc-1.95.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/openssl", + "*:*:native/pkgconf", + "*:*:native/python@3.11", + "*:*:native/rust@1_95_0" + ], + "build": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH", + "linux_amd64:*:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_amd64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "linux_arm64:*:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "darwin_arm64:*:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$NATIVEPREFIX/_/bin/clang", + "darwin_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib" + ], + "steps": [ + "*:*:echo '[build]' > config.toml", + "*:*:echo 'full-bootstrap = true' >> config.toml", + "*:*:echo 'vendor = true' >> config.toml", + "*:*:echo 'extended = true' >> config.toml", + "*:*:echo 'tools = [\"cargo\"]' >> config.toml", + "*:*:echo rustc = \\\"$NATIVEPREFIX/bin/rustc\\\" >> config.toml", + "*:*:echo cargo = \\\"$NATIVEPREFIX/bin/cargo\\\" >> config.toml", + "*:*:echo '[llvm]' >> config.toml", + "*:*:echo 'ninja = true' >> config.toml", + "*:*:echo 'download-ci-llvm = false' >> config.toml", + "*:*:env -u ARFLAGS python3 ./x.py build --stage 3 --verbose -j $NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a build/*/stage3/bin/rustc $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3-tools-bin/cargo $STAGING_DIR$NATIVEPREFIX/bin" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust@1_54_0.json b/packages/native/rust@1_54_0.json deleted file mode 100644 index e5fc4e6..0000000 --- a/packages/native/rust@1_54_0.json +++ /dev/null @@ -1,44 +0,0 @@ -{ - "package": "native/rust@1_54_0", - "version": "1.54.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "d3d3b84a100e71628afecf1125dbaa9bfc54ef9578c4fd81d75dca34c96f2565", - "url": "http://github.com/thepowersgang/mrustc/archive/06b87d1af49d2db3bd850fdee8888055dd540dd1.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/patch", - "all:native/perl", - "all:native/zlib" - ], - "patches": [ - "codegen_c.cpp.patch" - ], - "build": { - "env": [ - "all:PARLEVEL=$NUM_CORES" - ], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/codegen_c.cpp.patch", - "all:if [ $(uname) = 'Darwin' ] && [ $(uname -m) = 'arm64' ]; then sed -i.bak 's/STD_ENV_ARCH=[a-zA-Z0-9_]*/STD_ENV_ARCH=aarch64/' script-overrides/stable-1.54.0-macos/build_std.txt; else echo not patching for macos; fi", - "all:if [ $(uname) = 'Linux' ] && [ $(uname -m) = 'aarch64' ]; then sed -i.bak 's/STD_ENV_ARCH=[a-zA-Z0-9_]*/STD_ENV_ARCH=arm64/' script-overrides/stable-1.54.0-linux/build_std.txt; else echo not patching for linux; fi", - "all:sed -i.bak 's/^make$/make $@/' build-1.54.0.sh", - "all:if [ $(uname) = 'Darwin' ]; then sed -i.bak 's/^[[:space:]]*RUSTC_TARGET ?= x86_64-apple-darwin/RUSTC_TARGET ?= aarch64-apple-darwin/' run_rustc/Makefile; else true; fi", - "all:echo >> build-1.54.0.sh", - "all:echo make -C run_rustc >> build-1.54.0.sh", - "all:env -i CXXFLAGS_EXTRA=\"$CFLAGS\" LINKFLAGS_EXTRA=\"$LDFLAGS\" PATH=$PATH PARLEVEL=$NUM_CORES ./build-1.54.0.sh -j$NUM_CORES", - "none:# FIXME bad dylib paths embedded in the rustc binary, forcing install_name_tool dark magic", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:mkdir -p $STAGING_DIR$PREFIX/native/lib", - "all:cp -a run_rustc/output-1.54.0/prefix/bin/* $STAGING_DIR$PREFIX/native/bin", - "all:if [ $(uname) = 'Linux' ]; then cp -a run_rustc/output-1.54.0/prefix/lib/rustlib/*/lib/*.so $STAGING_DIR$PREFIX/native/lib; else true; fi", - "all:cp -a run_rustc/output-1.54.0/prefix/lib/* $STAGING_DIR$PREFIX/native/lib", - "all:if [ $(uname) = 'Darwin' ]; then install_name_tool -change $PWD/run_rustc/output-1.54.0/build-rustc/aarch64-apple-darwin/release/deps/librustc_driver.dylib @loader_path/../lib/rustlib/aarch64-apple-darwin/lib/librustc_driver.dylib $STAGING_DIR$PREFIX/native/bin/rustc_binary; else true; fi", - "all:if [ $(uname) = 'Darwin' ]; then install_name_tool -change $PWD/run_rustc/output-1.54.0/build-std2/aarch64-apple-darwin/release/deps/libstd.dylib @loader_path/../lib/rustlib/aarch64-apple-darwin/lib/libstd.dylib $STAGING_DIR$PREFIX/native/bin/rustc_binary; else true; fi", - "all:if [ $(uname) = 'Darwin' ]; then install_name_tool -change $PWD/run_rustc/output-1.54.0/build-std2/aarch64-apple-darwin/release/deps/libstd.dylib @loader_path/libstd.dylib $STAGING_DIR$PREFIX/native/lib/rustlib/aarch64-apple-darwin/lib/librustc_driver.dylib; else true; fi" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_55_0.json b/packages/native/rust@1_55_0.json deleted file mode 100644 index d850f65..0000000 --- a/packages/native/rust@1_55_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_55_0", - "version": "1.55.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "b2379ac710f5f876ee3c3e03122fe33098d6765d371cac6c31b1b6fc8e43821e", - "url": "http://static.rust-lang.org/dist/rustc-1.55.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_54_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_55_0/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_56_1.json b/packages/native/rust@1_56_1.json deleted file mode 100644 index 9967338..0000000 --- a/packages/native/rust@1_56_1.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_56_1", - "version": "1.56.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "c3898dfaadaa193dc88ddbc5345946a163211b58621df1cfff70186b4fc79511", - "url": "http://static.rust-lang.org/dist/rustc-1.56.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_55_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_57_0.json b/packages/native/rust@1_57_0.json deleted file mode 100644 index 782c185..0000000 --- a/packages/native/rust@1_57_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_57_0", - "version": "1.57.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "3546f9c3b91b1f8b8efd26c94d6b50312c08210397b4072ed2748e2bd4445c1a", - "url": "http://static.rust-lang.org/dist/rustc-1.57.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_56_1" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_58_1.json b/packages/native/rust@1_58_1.json deleted file mode 100644 index dad2003..0000000 --- a/packages/native/rust@1_58_1.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_58_1", - "version": "1.58.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "a839afdd3625d6f3f3c4c10b79813675d1775c460d14be1feaf33a6c829c07c7", - "url": "http://static.rust-lang.org/dist/rustc-1.58.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_57_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_59_0.json b/packages/native/rust@1_59_0.json deleted file mode 100644 index 84811b5..0000000 --- a/packages/native/rust@1_59_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_59_0", - "version": "1.59.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "a7c8eeaee85bfcef84c96b02b3171d1e6540d15179ff83dddd9eafba185f85f9", - "url": "http://static.rust-lang.org/dist/rustc-1.59.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_58_1" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_60_0.json b/packages/native/rust@1_60_0.json deleted file mode 100644 index 72142df..0000000 --- a/packages/native/rust@1_60_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_60_0", - "version": "1.60.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "20ca826d1cf674daf8e22c4f8c4b9743af07973211c839b85839742314c838b7", - "url": "http://static.rust-lang.org/dist/rustc-1.60.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_59_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_61_0.json b/packages/native/rust@1_61_0.json deleted file mode 100644 index d151f2b..0000000 --- a/packages/native/rust@1_61_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_61_0", - "version": "1.61.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "ad0b4351675aa9abdf4c7e066613bd274c4391c5506db152983426376101daed", - "url": "http://static.rust-lang.org/dist/rustc-1.61.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_60_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_62_0.json b/packages/native/rust@1_62_0.json deleted file mode 100644 index acbefa5..0000000 --- a/packages/native/rust@1_62_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_62_0", - "version": "1.62.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "7d0878809b64d206825acae3eb7f60afb2212d81e3de1adf4c11c6032b36c027", - "url": "http://static.rust-lang.org/dist/rustc-1.62.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_61_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_63_0.json b/packages/native/rust@1_63_0.json deleted file mode 100644 index 9cbbc26..0000000 --- a/packages/native/rust@1_63_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_63_0", - "version": "1.63.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "1f9580295642ef5da7e475a8da2397d65153d3f2cb92849dbd08ed0effca99d0", - "url": "http://static.rust-lang.org/dist/rustc-1.63.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_62_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_64_0.json b/packages/native/rust@1_64_0.json deleted file mode 100644 index 7f88988..0000000 --- a/packages/native/rust@1_64_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_64_0", - "version": "1.64.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "b3cd9f481e1a2901bf6f3808d30c69cc4ea80d93c4cc4e2ed52258b180381205", - "url": "http://static.rust-lang.org/dist/rustc-1.64.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_63_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_65_0.json b/packages/native/rust@1_65_0.json deleted file mode 100644 index 9a099fa..0000000 --- a/packages/native/rust@1_65_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_65_0", - "version": "1.65.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "5828bb67f677eabf8c384020582b0ce7af884e1c84389484f7f8d00dd82c0038", - "url": "http://static.rust-lang.org/dist/rustc-1.65.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_64_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_66_1.json b/packages/native/rust@1_66_1.json deleted file mode 100644 index 358fdf2..0000000 --- a/packages/native/rust@1_66_1.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_66_1", - "version": "1.66.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "5b3c933a94c72187705d4ee293198babfdd09442f5937fbd685db3a81f4959ba", - "url": "http://static.rust-lang.org/dist/rustc-1.66.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_65_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_67_1.json b/packages/native/rust@1_67_1.json deleted file mode 100644 index 6876b47..0000000 --- a/packages/native/rust@1_67_1.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_67_1", - "version": "1.67.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "46483d3e5de85a3bd46f8e7a3ae1837496391067dbe713a25d3cf051b3d9ff6e", - "url": "http://static.rust-lang.org/dist/rustc-1.67.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_66_1" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools/*/release/cargo $STAGING_DIR$PREFIX/native/bin/cargo" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_68_2.json b/packages/native/rust@1_68_2.json deleted file mode 100644 index 9848db4..0000000 --- a/packages/native/rust@1_68_2.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_68_2", - "version": "1.68.2", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "93339c23f7cd4d0c45db58e18b4c6e16d6070f4277aad9d2492d23294bf32e96", - "url": "http://static.rust-lang.org/dist/rustc-1.68.2-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_67_1" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_69_0.json b/packages/native/rust@1_69_0.json deleted file mode 100644 index b6f32dc..0000000 --- a/packages/native/rust@1_69_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_69_0", - "version": "1.69.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "fb05971867ad6ccabbd3720279f5a94b99f61024923187b56bb5c455fa3cf60f", - "url": "http://static.rust-lang.org/dist/rustc-1.69.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_68_2" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_70_0.json b/packages/native/rust@1_70_0.json deleted file mode 100644 index 3cbf985..0000000 --- a/packages/native/rust@1_70_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_70_0", - "version": "1.70.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "b2bfae000b7a5040e4ec4bbc50a09f21548190cb7570b0ed77358368413bd27c", - "url": "http://static.rust-lang.org/dist/rustc-1.70.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_69_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_71_1.json b/packages/native/rust@1_71_1.json deleted file mode 100644 index 99fce4a..0000000 --- a/packages/native/rust@1_71_1.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_71_1", - "version": "1.71.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "6fa90d50d1d529a75f6cc349784de57d7ec0ba2419b09bde7d335c25bd4e472e", - "url": "http://static.rust-lang.org/dist/rustc-1.71.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_70_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j$NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_72_1.json b/packages/native/rust@1_72_1.json deleted file mode 100644 index 1cb9020..0000000 --- a/packages/native/rust@1_72_1.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_72_1", - "version": "1.72.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "7f48845f6a52cdbb5d63fb0528fd5f520eb443275b55f98e328159f86568f895", - "url": "http://static.rust-lang.org/dist/rustc-1.72.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_71_1" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_73_0.json b/packages/native/rust@1_73_0.json deleted file mode 100644 index d394443..0000000 --- a/packages/native/rust@1_73_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_73_0", - "version": "1.73.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "96d62e6d1f2d21df7ac8acb3b9882411f9e7c7036173f7f2ede9e1f1f6b1bb3a", - "url": "http://static.rust-lang.org/dist/rustc-1.73.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_72_1" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_74_1.json b/packages/native/rust@1_74_1.json deleted file mode 100644 index b74c4ab..0000000 --- a/packages/native/rust@1_74_1.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_74_1", - "version": "1.74.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "67db3e22fc9921c885baae5953ba144fc474cde29ec69ab56d43ce764206231d", - "url": "http://static.rust-lang.org/dist/rustc-1.74.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_73_0" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_75_0.json b/packages/native/rust@1_75_0.json deleted file mode 100644 index 0f9d3ed..0000000 --- a/packages/native/rust@1_75_0.json +++ /dev/null @@ -1,45 +0,0 @@ -{ - "package": "native/rust@1_75_0", - "version": "1.75.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "5b739f45bc9d341e2d1c570d65d2375591e22c2d23ef5b8a37711a0386abc088", - "url": "http://static.rust-lang.org/dist/rustc-1.75.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_74_1" - ], - "patches": [ - "assembly.h.patch", - "Signals.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:patch -p1 < $PATCH_DIR/rust/1_56_1/assembly.h.patch", - "all:patch -p1 < $PATCH_DIR/rust/Signals.h.patch", - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_76_0.json b/packages/native/rust@1_76_0.json deleted file mode 100644 index 5b22383..0000000 --- a/packages/native/rust@1_76_0.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "package": "native/rust@1_76_0", - "version": "1.76.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "9e5cff033a7f0d2266818982ad90e4d3e4ef8f8ee1715776c6e25073a136c021", - "url": "http://static.rust-lang.org/dist/rustc-1.76.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_75_0" - ], - "patches": [ - "assembly.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_77_1.json b/packages/native/rust@1_77_1.json deleted file mode 100644 index 204639f..0000000 --- a/packages/native/rust@1_77_1.json +++ /dev/null @@ -1,42 +0,0 @@ -{ - "package": "native/rust@1_77_1", - "version": "1.77.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "ee106e4c569f52dba3b5b282b105820f86bd8f6b3d09c06b8dce82fb1bb3a4a1", - "url": "http://static.rust-lang.org/dist/rustc-1.77.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/patch", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_76_0" - ], - "patches": [ - "assembly.h.patch" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_78_0.json b/packages/native/rust@1_78_0.json deleted file mode 100644 index 7f47811..0000000 --- a/packages/native/rust@1_78_0.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_78_0", - "version": "1.78.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "ff544823a5cb27f2738128577f1e7e00ee8f4c83f2a348781ae4fc355e91d5a9", - "url": "http://static.rust-lang.org/dist/rustc-1.78.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_77_1" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_79_0.json b/packages/native/rust@1_79_0.json deleted file mode 100644 index 423464a..0000000 --- a/packages/native/rust@1_79_0.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_79_0", - "version": "1.79.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "172ecf3c7d1f9d9fb16cd2a628869782670416ded0129e524a86751f961448c0", - "url": "http://static.rust-lang.org/dist/rustc-1.79.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_78_0" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_80_1.json b/packages/native/rust@1_80_1.json deleted file mode 100644 index a52b8dc..0000000 --- a/packages/native/rust@1_80_1.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_80_1", - "version": "1.80.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "2c0b8f643942dcb810cbcc50f292564b1b6e44db5d5f45091153996df95d2dc4", - "url": "http://static.rust-lang.org/dist/rustc-1.80.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_79_0" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_81_0.json b/packages/native/rust@1_81_0.json deleted file mode 100644 index fa6cd17..0000000 --- a/packages/native/rust@1_81_0.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_81_0", - "version": "1.81.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "872448febdff32e50c3c90a7e15f9bb2db131d13c588fe9071b0ed88837ccfa7", - "url": "http://static.rust-lang.org/dist/rustc-1.81.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_80_1" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_82_0.json b/packages/native/rust@1_82_0.json deleted file mode 100644 index 80828f3..0000000 --- a/packages/native/rust@1_82_0.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_82_0", - "version": "1.82.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "7c53f4509eda184e174efa6ba7d5eeb586585686ce8edefc781a2b11a7cf512a", - "url": "http://static.rust-lang.org/dist/rustc-1.82.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_81_0" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_83_0.json b/packages/native/rust@1_83_0.json deleted file mode 100644 index 499cae0..0000000 --- a/packages/native/rust@1_83_0.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_83_0", - "version": "1.83.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "722d773bd4eab2d828d7dd35b59f0b017ddf9a97ee2b46c1b7f7fac5c8841c6e", - "url": "http://static.rust-lang.org/dist/rustc-1.83.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_82_0" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_84_1.json b/packages/native/rust@1_84_1.json deleted file mode 100644 index edafbda..0000000 --- a/packages/native/rust@1_84_1.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_84_1", - "version": "1.84.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "5e2fb5d49628a549f7671b2ccf9855ab379fd442831a7c2af16e0cdcc31bb375", - "url": "http://static.rust-lang.org/dist/rustc-1.84.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_83_0" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_85_1.json b/packages/native/rust@1_85_1.json deleted file mode 100644 index 5a2ae76..0000000 --- a/packages/native/rust@1_85_1.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_85_1", - "version": "1.85.1", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "0f2995ca083598757a8d9a293939e569b035799e070f419a686b0996fb94238a", - "url": "http://static.rust-lang.org/dist/rustc-1.85.1-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_84_1" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_86_0.json b/packages/native/rust@1_86_0.json deleted file mode 100644 index 71b89f0..0000000 --- a/packages/native/rust@1_86_0.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_86_0", - "version": "1.86.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "022a27286df67900a044d227d9db69d4732ec3d833e4ffc259c4425ed71eed80", - "url": "http://static.rust-lang.org/dist/rustc-1.86.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_85_1" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_87_0.json b/packages/native/rust@1_87_0.json deleted file mode 100644 index ec29e2d..0000000 --- a/packages/native/rust@1_87_0.json +++ /dev/null @@ -1,38 +0,0 @@ -{ - "package": "native/rust@1_87_0", - "version": "1.87.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "149bb9fd29be592da4e87900fc68f0629a37bf6850b46339dd44434c04fd8e76", - "url": "http://static.rust-lang.org/dist/rustc-1.87.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_86_0" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 1 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage0-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_88_0.json b/packages/native/rust@1_88_0.json deleted file mode 100644 index 01e3c6a..0000000 --- a/packages/native/rust@1_88_0.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "package": "native/rust@1_88_0", - "version": "1.88.0", - "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "3a97544434848ae3d193d1d6bc83d6f24cb85c261ad95f955fde47ec64cfcfbe", - "url": "http://static.rust-lang.org/dist/rustc-1.88.0-src.tar.gz" - }, - "dependencies": [ - "all:native/cmake", - "all:native/make", - "all:native/openssl", - "all:native/pkgconf", - "all:native/python@3.11.13", - "all:native/rust@1_87_0" - ], - "build": { - "env": [], - "steps": [ - "all:echo '[build]' > config.toml", - "aarch64-apple-darwin:echo 'target = [\"aarch64-apple-darwin\"]' >> config.toml", - "x86_64-apple-darwin:echo 'target = [\"x86_64-apple-darwin\"]' >> config.toml", - "aarch64-apple-ios:echo 'target = [\"aarch64-apple-ios\"]' >> config.toml", - "aarch64-apple-ios-simulator:echo 'target = [\"aarch64-apple-ios-sim\"]' >> config.toml", - "x86_64-linux-gnu:echo 'target = [\"x86_64-unknown-linux-gnu\"]' >> config.toml", - "aarch64-linux-gnu:echo 'target = [\"aarch64-unknown-linux-gnu\"]' >> config.toml", - "aarch64-linux-android:echo 'target = [\"aarch64-linux-android\"]' >> config.toml", - "x86_64-linux-android:echo 'target = [\"x86_64-linux-android\"]' >> config.toml", - "armv7a-linux-androideabi:echo 'target = [\"armv7-linux-androideabi\"]' >> config.toml", - "all:echo 'full-bootstrap = true' >> config.toml", - "all:echo 'vendor = true' >> config.toml", - "all:echo 'extended = true' >> config.toml", - "all:echo 'tools = [\"cargo\"]' >> config.toml", - "all:echo rustc = \\\"$PREFIX/native/bin/rustc\\\" >> config.toml", - "all:echo cargo = \\\"$PREFIX/native/bin/cargo\\\" >> config.toml", - "all:echo '[llvm]' >> config.toml", - "all:echo 'ninja = false' >> config.toml", - "all:echo 'download-ci-llvm = false' >> config.toml", - "all:env -u ARFLAGS python3 ./x.py build --stage 2 --verbose -j $NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1/lib $STAGING_DIR$PREFIX/native/", - "all:cp -a build/*/stage1/bin/rustc $STAGING_DIR$PREFIX/native/bin", - "all:cp -a build/*/stage1-tools-bin/cargo $STAGING_DIR$PREFIX/native/bin" - ] - } -} \ No newline at end of file diff --git a/packages/native/rust@1_90_0-bin.json b/packages/native/rust@1_90_0-bin.json new file mode 100644 index 0000000..b2575fc --- /dev/null +++ b/packages/native/rust@1_90_0-bin.json @@ -0,0 +1,44 @@ +{ + "package": "native/rust@1_90_0-bin", + "version": "1.90.0", + "type": "native", + "download": [ + { + "kind": "blob", + "path": "./rust-1.90.0-x86_64-unknown-linux-gnu.tar.gz", + "sha256": "e453bae1c68d02fe2eae065c5452d5731308164cd154154c6ee442d2fa590685", + "url": "https://static.rust-lang.org/dist/rust-1.90.0-x86_64-unknown-linux-gnu.tar.gz" + }, + { + "kind": "blob", + "path": "./rust-1.90.0-aarch64-unknown-linux-gnu.tar.gz", + "sha256": "293f412e3412c3aa3398c78ebbdf898fa08eacad80c85a7332ce1a455504c5fc", + "url": "https://static.rust-lang.org/dist/rust-1.90.0-aarch64-unknown-linux-gnu.tar.gz" + }, + { + "kind": "blob", + "path": "./rust-1.90.0-aarch64-apple-darwin.tar.gz", + "sha256": "a11b52e34f5e80cb25d49f7943ae60e0b069b431727a4c09b2c890ceebee3687", + "url": "https://static.rust-lang.org/dist/rust-1.90.0-aarch64-apple-darwin.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/gzip", + "*:*:native/tar" + ], + "build": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/_/bin:$PATH" + ], + "steps": [ + "linux_amd64:*:tar -xzf rust-1.90.0-x86_64-unknown-linux-gnu.tar.gz", + "linux_amd64:*:cd rust-1.90.0-x86_64-unknown-linux-gnu && ./install.sh --prefix=$STAGING_DIR$NATIVEPREFIX --disable-ldconfig", + "linux_arm64:*:tar -xzf rust-1.90.0-aarch64-unknown-linux-gnu.tar.gz", + "linux_arm64:*:cd rust-1.90.0-aarch64-unknown-linux-gnu && ./install.sh --prefix=$STAGING_DIR$NATIVEPREFIX --disable-ldconfig", + "darwin_arm64:*:tar -xzf rust-1.90.0-aarch64-apple-darwin.tar.gz", + "darwin_arm64:*:cd rust-1.90.0-aarch64-apple-darwin && ./install.sh --prefix=$STAGING_DIR$NATIVEPREFIX --disable-ldconfig" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust@1_90_0-mrustc.json b/packages/native/rust@1_90_0-mrustc.json new file mode 100644 index 0000000..ffd1c9c --- /dev/null +++ b/packages/native/rust@1_90_0-mrustc.json @@ -0,0 +1,68 @@ +{ + "package": "native/rust@1_90_0-mrustc", + "version": "1.90.0-mrustc", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "be69c7479a10bdce1b86cb886789d14a143ddf34", + "url": "http://github.com/thepowersgang/mrustc.git" + }, + { + "kind": "blob", + "path": "./rustc-1.90.0-src.tar.gz", + "sha256": "799a9f9cba4ed5351e071048bcf6b5560755d9009648def33a407dd4961f9b7e", + "url": "http://static.rust-lang.org/dist/rustc-1.90.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/binutils@2.46.0", + "*:*:native/cmake", + "*:*:native/coreutils", + "*:*:native/findutils", + "*:*:native/gawk", + "*:*:native/_/gcc@15_2_0", + "*:*:native/git", + "*:*:native/grep", + "*:*:native/gzip", + "*:*:native/make", + "*:*:native/openssl", + "*:*:native/patch", + "*:*:native/perl", + "*:*:native/pkgconf", + "*:*:native/sed", + "*:*:native/tar", + "*:*:native/zlib" + ], + "build": { + "env": [ + "*:*:SHELL=$NATIVEPREFIX/bin/bash", + "*:*:PARLEVEL=$NUM_CORES", + "*:*:OPENSSL_DIR=$NATIVEPREFIX", + "linux_arm64:*:RUSTC_TARGET=aarch64-unknown-linux-gnu" + ], + "steps": [ + "*:*:$NATIVEPREFIX/bin/sed -i.bak 's/^make$/make $@/' build-1.90.0.sh", + "linux_amd64:*:$NATIVEPREFIX/bin/sed -i.bak '/samples\\/no_core-1_90.rs/d' build-1.90.0.sh", + "darwin_arm64:*:$NATIVEPREFIX/bin/sed -i.bak 's/^[[:space:]]*RUSTC_TARGET ?= x86_64-apple-darwin/RUSTC_TARGET ?= aarch64-apple-darwin/' run_rustc/Makefile", + "linux_arm64:*:$NATIVEPREFIX/bin/sed -i.bak 's/^[[:space:]]*RUSTC_TARGET ?= x86_64-unknown-linux-gnu/RUSTC_TARGET ?= aarch64-unknown-linux-gnu/' run_rustc/Makefile", + "linux_arm64:*:$NATIVEPREFIX/bin/sed -i.bak 's/^[[:space:]]*RUSTC_TARGET ?= x86_64-unknown-linux-gnu/RUSTC_TARGET ?= aarch64-unknown-linux-gnu/' ./minicargo.mk", + "*:*:$NATIVEPREFIX/bin/sed -i.bak 's/LLVM_ENABLE_ZLIB=OFF/LLVM_ENABLE_ZLIB=OFF LLVM_ENABLE_ZSTD=OFF LLVM_ENABLE_LIBXML2=OFF/' minicargo.mk", + "linux_amd64:*:REP=$NATIVEPREFIX/lib && $NATIVEPREFIX/bin/sed -i.bak \"s|^RUSTC_ENV_VARS += LD_LIBRARY_PATH=|RUSTC_ENV_VARS += LD_LIBRARY_PATH=$REP:|\" minicargo.mk", + "*:*:echo >> build-1.90.0.sh", + "*:*:echo make -C run_rustc >> build-1.90.0.sh", + "*:*:env -u TARGET -u LIBRARY_PATH PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin CXXFLAGS_EXTRA=\"$CFLAGS\" LINKFLAGS_EXTRA=\"$LDFLAGS\" $NATIVEPREFIX/bin/bash ./build-1.90.0.sh -j$NUM_CORES", + "*:*:$NATIVEPREFIX/bin/mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:$NATIVEPREFIX/bin/mkdir -p $STAGING_DIR$NATIVEPREFIX/lib", + "*:*:$NATIVEPREFIX/bin/cp -a run_rustc/output-1.90.0/prefix/bin/* $STAGING_DIR$NATIVEPREFIX/bin", + "linux_*:*:$NATIVEPREFIX/bin/cp -a run_rustc/output-1.90.0/prefix/lib/rustlib/*/lib/*.so $STAGING_DIR$NATIVEPREFIX/lib", + "*:*:$NATIVEPREFIX/bin/cp -a run_rustc/output-1.90.0/prefix/lib/* $STAGING_DIR$NATIVEPREFIX/lib", + "*:none:# FIXME bad dylib paths embedded in the rustc binary, forcing install_name_tool dark magic", + "darwin_*:*:install_name_tool -change $PWD/run_rustc/output-1.90.0/build-rustc/aarch64-apple-darwin/release/deps/librustc_driver.dylib @loader_path/../lib/rustlib/aarch64-apple-darwin/lib/librustc_driver.dylib $STAGING_DIR$NATIVEPREFIX/bin/rustc_binary", + "darwin_*:*:install_name_tool -change $PWD/run_rustc/output-1.90.0/build-std2/aarch64-apple-darwin/release/deps/libstd.dylib @loader_path/../lib/rustlib/aarch64-apple-darwin/lib/libstd.dylib $STAGING_DIR$NATIVEPREFIX/bin/rustc_binary", + "darwin_*:*:install_name_tool -change $PWD/run_rustc/output-1.90.0/build-std2/aarch64-apple-darwin/release/deps/libstd.dylib @loader_path/libstd.dylib $STAGING_DIR$NATIVEPREFIX/lib/rustlib/aarch64-apple-darwin/lib/librustc_driver.dylib" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust@1_90_0.json b/packages/native/rust@1_90_0.json new file mode 100644 index 0000000..9f6c8b4 --- /dev/null +++ b/packages/native/rust@1_90_0.json @@ -0,0 +1,53 @@ +{ + "package": "native/rust@1_90_0", + "version": "1.90.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "799a9f9cba4ed5351e071048bcf6b5560755d9009648def33a407dd4961f9b7e", + "url": "http://static.rust-lang.org/dist/rustc-1.90.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/openssl", + "*:*:native/pkgconf", + "*:*:native/python@3.11", + "*_amd64:*:native/rust@1_90_0-mrustc", + "*_arm64:*:native/rust@1_90_0-bin" + ], + "build": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH", + "*:*:OPENSSL_DIR=$NATIVEPREFIX", + "linux_amd64:*:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_amd64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "linux_arm64:*:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "darwin_arm64:*:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$NATIVEPREFIX/_/bin/clang", + "darwin_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib" + ], + "steps": [ + "*:*:echo '[build]' > config.toml", + "*:*:echo 'full-bootstrap = true' >> config.toml", + "*:*:echo 'vendor = true' >> config.toml", + "*:*:echo 'extended = true' >> config.toml", + "*:*:echo 'tools = [\"cargo\"]' >> config.toml", + "*:*:echo rustc = \\\"$NATIVEPREFIX/bin/rustc\\\" >> config.toml", + "*:*:echo cargo = \\\"$NATIVEPREFIX/bin/cargo\\\" >> config.toml", + "*:*:echo '[llvm]' >> config.toml", + "*:*:echo 'ninja = true' >> config.toml", + "*:*:echo 'download-ci-llvm = false' >> config.toml", + "*:*:env -u ARFLAGS python3 ./x.py build --stage 3 --verbose -j $NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a build/*/stage3/bin/rustc $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage2-tools-bin/cargo $STAGING_DIR$NATIVEPREFIX/bin" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust@1_91_0.json b/packages/native/rust@1_91_0.json new file mode 100644 index 0000000..d4b9ef5 --- /dev/null +++ b/packages/native/rust@1_91_0.json @@ -0,0 +1,51 @@ +{ + "package": "native/rust@1_91_0", + "version": "1.91.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "327f528151753013f0a2b2c7f48955a033d718f269a4bc586314d675d0d43e8a", + "url": "http://static.rust-lang.org/dist/rustc-1.91.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/openssl", + "*:*:native/pkgconf", + "*:*:native/python@3.11", + "*:*:native/rust@1_90_0" + ], + "build": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH", + "linux_amd64:*:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_amd64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "linux_arm64:*:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "darwin_arm64:*:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$NATIVEPREFIX/_/bin/clang", + "darwin_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib" + ], + "steps": [ + "*:*:echo '[build]' > config.toml", + "*:*:echo 'full-bootstrap = true' >> config.toml", + "*:*:echo 'vendor = true' >> config.toml", + "*:*:echo 'extended = true' >> config.toml", + "*:*:echo 'tools = [\"cargo\"]' >> config.toml", + "*:*:echo rustc = \\\"$NATIVEPREFIX/bin/rustc\\\" >> config.toml", + "*:*:echo cargo = \\\"$NATIVEPREFIX/bin/cargo\\\" >> config.toml", + "*:*:echo '[llvm]' >> config.toml", + "*:*:echo 'ninja = true' >> config.toml", + "*:*:echo 'download-ci-llvm = false' >> config.toml", + "*:*:env -u ARFLAGS python3 ./x.py build --stage 3 --verbose -j $NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a build/*/stage3/bin/rustc $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3-tools-bin/cargo $STAGING_DIR$NATIVEPREFIX/bin" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust@1_92_0.json b/packages/native/rust@1_92_0.json new file mode 100644 index 0000000..8be5847 --- /dev/null +++ b/packages/native/rust@1_92_0.json @@ -0,0 +1,51 @@ +{ + "package": "native/rust@1_92_0", + "version": "1.92.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "9e0d2ca75c7e275fdc758255bf4b03afb3d65d1543602746907c933b6901c3b8", + "url": "http://static.rust-lang.org/dist/rustc-1.92.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/openssl", + "*:*:native/pkgconf", + "*:*:native/python@3.11", + "*:*:native/rust@1_91_0" + ], + "build": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH", + "linux_amd64:*:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_amd64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "linux_arm64:*:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "darwin_arm64:*:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$NATIVEPREFIX/_/bin/clang", + "darwin_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib" + ], + "steps": [ + "*:*:echo '[build]' > config.toml", + "*:*:echo 'full-bootstrap = true' >> config.toml", + "*:*:echo 'vendor = true' >> config.toml", + "*:*:echo 'extended = true' >> config.toml", + "*:*:echo 'tools = [\"cargo\"]' >> config.toml", + "*:*:echo rustc = \\\"$NATIVEPREFIX/bin/rustc\\\" >> config.toml", + "*:*:echo cargo = \\\"$NATIVEPREFIX/bin/cargo\\\" >> config.toml", + "*:*:echo '[llvm]' >> config.toml", + "*:*:echo 'ninja = true' >> config.toml", + "*:*:echo 'download-ci-llvm = false' >> config.toml", + "*:*:env -u ARFLAGS python3 ./x.py build --stage 3 --verbose -j $NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a build/*/stage3/bin/rustc $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3-tools-bin/cargo $STAGING_DIR$NATIVEPREFIX/bin" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust@1_93_0.json b/packages/native/rust@1_93_0.json new file mode 100644 index 0000000..20fd0fd --- /dev/null +++ b/packages/native/rust@1_93_0.json @@ -0,0 +1,51 @@ +{ + "package": "native/rust@1_93_0", + "version": "1.93.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "69112bd83c321943ffc390b7db2f59ef3febb95dac700f67c2156fbf6b50a705", + "url": "http://static.rust-lang.org/dist/rustc-1.93.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/openssl", + "*:*:native/pkgconf", + "*:*:native/python@3.11", + "*:*:native/rust@1_92_0" + ], + "build": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH", + "linux_amd64:*:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_amd64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "linux_arm64:*:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "darwin_arm64:*:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$NATIVEPREFIX/_/bin/clang", + "darwin_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib" + ], + "steps": [ + "*:*:echo '[build]' > config.toml", + "*:*:echo 'full-bootstrap = true' >> config.toml", + "*:*:echo 'vendor = true' >> config.toml", + "*:*:echo 'extended = true' >> config.toml", + "*:*:echo 'tools = [\"cargo\"]' >> config.toml", + "*:*:echo rustc = \\\"$NATIVEPREFIX/bin/rustc\\\" >> config.toml", + "*:*:echo cargo = \\\"$NATIVEPREFIX/bin/cargo\\\" >> config.toml", + "*:*:echo '[llvm]' >> config.toml", + "*:*:echo 'ninja = true' >> config.toml", + "*:*:echo 'download-ci-llvm = false' >> config.toml", + "*:*:env -u ARFLAGS python3 ./x.py build --stage 3 --verbose -j $NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a build/*/stage3/bin/rustc $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3-tools-bin/cargo $STAGING_DIR$NATIVEPREFIX/bin" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust@1_94_0.json b/packages/native/rust@1_94_0.json new file mode 100644 index 0000000..c57af63 --- /dev/null +++ b/packages/native/rust@1_94_0.json @@ -0,0 +1,51 @@ +{ + "package": "native/rust@1_94_0", + "version": "1.94.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "b83f921cd3f321ff614f9c06a8b870d89299fc02888b48a5549683a36823474c", + "url": "http://static.rust-lang.org/dist/rustc-1.94.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/cmake", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/openssl", + "*:*:native/pkgconf", + "*:*:native/python@3.11", + "*:*:native/rust@1_93_0" + ], + "build": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH", + "linux_amd64:*:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_amd64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "linux_arm64:*:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "darwin_arm64:*:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$NATIVEPREFIX/_/bin/clang", + "darwin_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib" + ], + "steps": [ + "*:*:echo '[build]' > config.toml", + "*:*:echo 'full-bootstrap = true' >> config.toml", + "*:*:echo 'vendor = true' >> config.toml", + "*:*:echo 'extended = true' >> config.toml", + "*:*:echo 'tools = [\"cargo\"]' >> config.toml", + "*:*:echo rustc = \\\"$NATIVEPREFIX/bin/rustc\\\" >> config.toml", + "*:*:echo cargo = \\\"$NATIVEPREFIX/bin/cargo\\\" >> config.toml", + "*:*:echo '[llvm]' >> config.toml", + "*:*:echo 'ninja = true' >> config.toml", + "*:*:echo 'download-ci-llvm = false' >> config.toml", + "*:*:env -u ARFLAGS python3 ./x.py build --stage 3 --verbose -j $NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a build/*/stage3/bin/rustc $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3-tools-bin/cargo $STAGING_DIR$NATIVEPREFIX/bin" + ] + } +} \ No newline at end of file diff --git a/packages/native/rust@1_95_0.json b/packages/native/rust@1_95_0.json new file mode 100644 index 0000000..74831c1 --- /dev/null +++ b/packages/native/rust@1_95_0.json @@ -0,0 +1,51 @@ +{ + "package": "native/rust@1_95_0", + "version": "1.95.0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "ea9b82a83e46967537c3569ce9d6fa16811c043a96e651376c349e70241ca515", + "url": "http://static.rust-lang.org/dist/rustc-1.95.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/cmake", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/openssl", + "*:*:native/pkgconf", + "*:*:native/python@3.11", + "*:*:native/rust@1_94_0" + ], + "build": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin:$PATH", + "linux_amd64:*:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_amd64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "linux_arm64:*:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib", + "darwin_arm64:*:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$NATIVEPREFIX/_/bin/clang", + "darwin_arm64:*:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang -Clink-arg=-L$NATIVEPREFIX/lib" + ], + "steps": [ + "*:*:echo '[build]' > config.toml", + "*:*:echo 'full-bootstrap = true' >> config.toml", + "*:*:echo 'vendor = true' >> config.toml", + "*:*:echo 'extended = true' >> config.toml", + "*:*:echo 'tools = [\"cargo\"]' >> config.toml", + "*:*:echo rustc = \\\"$NATIVEPREFIX/bin/rustc\\\" >> config.toml", + "*:*:echo cargo = \\\"$NATIVEPREFIX/bin/cargo\\\" >> config.toml", + "*:*:echo '[llvm]' >> config.toml", + "*:*:echo 'ninja = true' >> config.toml", + "*:*:echo 'download-ci-llvm = false' >> config.toml", + "*:*:env -u ARFLAGS python3 ./x.py build --stage 3 --verbose -j $NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3/lib $STAGING_DIR$NATIVEPREFIX/", + "*:*:cp -a build/*/stage3/bin/rustc $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:cp -a build/*/stage3-tools-bin/cargo $STAGING_DIR$NATIVEPREFIX/bin" + ] + } +} \ No newline at end of file diff --git a/packages/native/sed.json b/packages/native/sed.json index f37fca7..8574710 100644 --- a/packages/native/sed.json +++ b/packages/native/sed.json @@ -2,21 +2,24 @@ "package": "native/sed", "version": "4.9", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "d1478a18f033a73ac16822901f6533d30b6be561bcbce46ffd7abce93602282e", - "url": "http://ftpmirror.gnu.org/gnu/sed/sed-4.9.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "d1478a18f033a73ac16822901f6533d30b6be561bcbce46ffd7abce93602282e", + "url": "http://ftpmirror.gnu.org/gnu/sed/sed-4.9.tar.gz" + } + ], "dependencies": [ - "all:native/make", - "all:native/perl" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make" ], "build": { "env": [], "steps": [ - "all:./configure --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/native/tar.json b/packages/native/tar.json new file mode 100644 index 0000000..a298688 --- /dev/null +++ b/packages/native/tar.json @@ -0,0 +1,30 @@ +{ + "package": "native/tar", + "version": "1.35", + "type": "native", + "download": [ + { + "kind": "tar.xz", + "sha256": "4d62ff37342ec7aed748535323930c7cf94acf71c3591882b26a7ea50f3edc16", + "url": "http://ftpmirror.gnu.org/gnu/tar/tar-1.35.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/libiconv", + "*:*:native/make" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:LIBS=-liconv", + "windows_*:*:config_opts=$config_opts gl_cv_have_weak=no" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/texinfo.json b/packages/native/texinfo.json index ae84a3e..0f744cb 100644 --- a/packages/native/texinfo.json +++ b/packages/native/texinfo.json @@ -2,25 +2,31 @@ "package": "native/texinfo", "version": "7.2", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "e86de7dfef6b352aa1bf647de3a6213d1567c70129eccbf8977706d9c91919c8", - "url": "http://ftpmirror.gnu.org/gnu/texinfo/texinfo-7.2.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "e86de7dfef6b352aa1bf647de3a6213d1567c70129eccbf8977706d9c91919c8", + "url": "http://ftpmirror.gnu.org/gnu/texinfo/texinfo-7.2.tar.gz" + } + ], "dependencies": [ - "all:native/automake", - "all:native/gawk", - "all:native/make", - "all:native/perl" + "*:*:native/_/_", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/gawk", + "*:*:native/gettext", + "*:*:native/make", + "*:*:native/perl" ], "build": { "env": [ - "all:HELP2MAN=true" + "*:*:HELP2MAN=true" ], "steps": [ - "all:./configure --prefix=$PREFIX/native", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure --prefix=$NATIVEPREFIX", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:cd $STAGING_DIR$NATIVEPREFIX/bin && ln -sf texi2any makeinfo" ] } } \ No newline at end of file diff --git a/packages/native/triehash.json b/packages/native/triehash.json new file mode 100644 index 0000000..cccbe95 --- /dev/null +++ b/packages/native/triehash.json @@ -0,0 +1,24 @@ +{ + "package": "native/triehash", + "version": "1.6.1-patch", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "e0bd5e08395bcd5ae105ad279d8d3ba67e8b738b", + "url": "https://github.com/julian-klode/triehash.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/sed" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:sed -i.bak '1s|^#!/usr/bin/perl -w|#!'\"$PREFIX\"'/native/bin/perl|' triehash.pl", + "*:*:cp triehash.pl $STAGING_DIR$NATIVEPREFIX/bin/triehash" + ] + } +} \ No newline at end of file diff --git a/packages/native/unistring.json b/packages/native/unistring.json new file mode 100644 index 0000000..50b4031 --- /dev/null +++ b/packages/native/unistring.json @@ -0,0 +1,30 @@ +{ + "package": "native/unistring", + "version": "1.4.1", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "12542ad7619470efd95a623174dcd4b364f2483caf708c6bee837cb53a54cb9d", + "url": "http://ftpmirror.gnu.org/gnu/libunistring/libunistring-1.4.1.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/make", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static" + ], + "steps": [ + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/unzip.json b/packages/native/unzip.json new file mode 100644 index 0000000..9dea8b7 --- /dev/null +++ b/packages/native/unzip.json @@ -0,0 +1,24 @@ +{ + "package": "native/unzip", + "version": "1.0.0", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "f802bc7b20bf0626d765ff3fe0ef0adb3fd93b26", + "url": "https://github.com/MrCyjaneK/7zz_unzip.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bzip2", + "*:*:native/make", + "*:*:native/sed" + ], + "build": { + "steps": [ + "*:*:mkdir -p $STAGING_DIR$NATIVEPREFIX/bin", + "*:*:$CC main.c -o $STAGING_DIR$NATIVEPREFIX/bin/unzip" + ] + } +} \ No newline at end of file diff --git a/packages/native/wayland@1_25_0.json b/packages/native/wayland@1_25_0.json new file mode 100644 index 0000000..5c39385 --- /dev/null +++ b/packages/native/wayland@1_25_0.json @@ -0,0 +1,29 @@ +{ + "package": "native/wayland@1_25_0", + "version": "1_25_0", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "95413723f6cd0462770eda207a1c78d142d0a1bba9b0572a4ed1da6a9b27059c", + "url": "https://gitlab.freedesktop.org/wayland/wayland/-/archive/1.25.0/wayland-1.25.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/expat", + "*:*:native/libffi@3_5_2", + "*:*:native/meson", + "*:*:native/ninja", + "*:*:native/pkgconf", + "*:*:native/python@3.11" + ], + "build": { + "env": [], + "steps": [ + "*:*:$NATIVEPREFIX/bin/meson setup build --prefix=$NATIVEPREFIX -Ddtd_validation=false -Ddocumentation=false -Dtests=false", + "*:*:ninja -C build", + "*:*:DESTDIR=$STAGING_DIR ninja -C build install" + ] + } +} \ No newline at end of file diff --git a/packages/native/xar.json b/packages/native/xar.json new file mode 100644 index 0000000..2e84d62 --- /dev/null +++ b/packages/native/xar.json @@ -0,0 +1,35 @@ +{ + "package": "native/xar", + "version": "1.6.1-patch", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "5fa4675419cfec60ac19a9c7f7c2d0e7c831a497", + "url": "https://github.com/tpoechtrager/xar.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/bzip2", + "*:*:native/libxml2", + "*:*:native/make", + "*:*:native/openssl", + "*:*:native/xz", + "*:*:native/zlib" + ], + "build": { + "env": [ + "*:*:CFLAGS=$CFLAGS -w", + "*:*:config_opts=--with-bzip2", + "*:*:config_opts=$config_opts --with-lzma=$NATIVEPREFIX" + ], + "steps": [ + "*:*:cd xar && bash ./configure --prefix=$NATIVEPREFIX", + "*:*:cd xar && make V=1 -j$NUM_CORES", + "*:*:sed -i.bak 's|.././install-sh|./install-sh|g' xar/lib/Makefile.inc xar/src/Makefile.inc", + "*:*:cd xar && make V=1 DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/native/xmlto.json b/packages/native/xmlto.json new file mode 100644 index 0000000..3a67534 --- /dev/null +++ b/packages/native/xmlto.json @@ -0,0 +1,34 @@ +{ + "package": "native/xmlto", + "version": "0.0.29", + "type": "native", + "download": [ + { + "kind": "git", + "sha256": "13a831d76467c88f9e79f9804e2471137ec05331", + "url": "https://pagure.io/xmlto.git" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/flex", + "*:*:native/gawk", + "*:*:native/gettext", + "*:*:native/libxml2", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" + ], + "build": { + "env": [], + "steps": [ + "*:*:autoreconf -f -i", + "*:*:bash ./configure --prefix=$NATIVEPREFIX", + "*:*:make xmlto -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install-exec" + ] + } +} \ No newline at end of file diff --git a/packages/native/xz.json b/packages/native/xz.json new file mode 100644 index 0000000..bcc1cc8 --- /dev/null +++ b/packages/native/xz.json @@ -0,0 +1,43 @@ +{ + "package": "native/xz", + "version": "5.8.1", + "type": "native", + "download": [ + { + "kind": "tar.gz", + "sha256": "507825b599356c10dca1cd720c9d0d0c9d5400b9de300af00e4d1ea150795543", + "url": "http://github.com/tukaani-project/xz/releases/download/v5.8.1/xz-5.8.1.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/gettext", + "*:*:native/gzip", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl" + ], + "patches": [ + "fix_declaration.patch" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$NATIVEPREFIX --host=$HOST", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static", + "*:*:config_opts=$config_opts --disable-doc", + "*:*:config_opts=$config_opts --disable-scripts" + ], + "steps": [ + "*:*:bash ./autogen.sh --no-po4a", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:rm $STAGING_DIR$NATIVEPREFIX/lib/*.la" + ] + } +} \ No newline at end of file diff --git a/packages/native/zlib.json b/packages/native/zlib.json index 614d94f..f7f574a 100644 --- a/packages/native/zlib.json +++ b/packages/native/zlib.json @@ -2,26 +2,29 @@ "package": "native/zlib", "version": "1.3.1", "type": "native", - "download": { - "kind": "tar.gz", - "sha256": "9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23", - "url": "http://www.zlib.net/zlib-1.3.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23", + "url": "https://github.com/madler/zlib/releases/download/v1.3.1/zlib-1.3.1.tar.gz" + } + ], "dependencies": [ - "all:native/libtool", - "all:native/make" + "*:*:native/_/_", + "*:*:native/bash", + "*:*:native/libtool", + "*:*:native/make" ], "build": { "env": [ - "all:CFLAGS=$CFLAGS -fPIC", - "all:config_opts=--prefix=$PREFIX/native --static", - "all:LIBTOOL=$PREFIX/native/bin/libtool", - "all:CROSS_PREFIX=$HOST-" + "*:*:config_opts=--prefix=$NATIVEPREFIX --static", + "*:*:LIBTOOL=$NATIVEPREFIX/bin/libtool", + "*:*:CROSS_PREFIX=$HOST-" ], "steps": [ - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/ncurses.json b/packages/ncurses.json index 5c281fc..3525e35 100644 --- a/packages/ncurses.json +++ b/packages/ncurses.json @@ -2,63 +2,72 @@ "package": "ncurses", "version": "6.5", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "136d91bc269a9a5785e5f9e980bc76ab57428f604ce3e5a5a90cebc767971cc6", - "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.5.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "136d91bc269a9a5785e5f9e980bc76ab57428f604ce3e5a5a90cebc767971cc6", + "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.5.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk" + "*:*:native/_/_", + "*:*:native/_", + "*:*:native/sed", + "*:*:native/grep", + "*:*:native/make", + "*:*:native/gawk", + "*:*:native/bash" ], "patches": [ "fallback.c" ], "build": { "env": [ - "all:config_opts=--host=$HOST --prefix=$PREFIX", - "*-linux-gnu:cf_cv_ar_flags=", - "all:config_opts=$config_opts --disable-shared", - "all:config_opts=$config_opts --with-build-cc=gcc", - "all:config_opts=$config_opts --without-debug", - "all:config_opts=$config_opts --without-ada", - "all:config_opts=$config_opts --without-cxx-binding", - "all:config_opts=$config_opts --without-cxx", - "all:config_opts=$config_opts --without-ticlib", - "all:config_opts=$config_opts --without-tic", - "all:config_opts=$config_opts --without-progs", - "all:config_opts=$config_opts --without-tests", - "all:config_opts=$config_opts --without-tack", - "all:config_opts=$config_opts --without-manpages", - "all:config_opts=$config_opts --with-termlib", - "all:config_opts=$config_opts --disable-tic-depends", - "all:config_opts=$config_opts --disable-big-strings", - "all:config_opts=$config_opts --disable-ext-colors", - "all:config_opts=$config_opts --enable-pc-files", - "all:config_opts=$config_opts --without-shared", - "all:config_opts=$config_opts --without-pthread", - "all:config_opts=$config_opts --disable-rpath", - "all:config_opts=$config_opts --disable-colorfgbg", - "all:config_opts=$config_opts --disable-ext-mouse", - "all:config_opts=$config_opts --disable-symlinks", - "all:config_opts=$config_opts --enable-warnings", - "all:config_opts=$config_opts --enable-assertions", - "all:config_opts=$config_opts --with-default-terminfo-dir=/etc/_terminfo_", - "all:config_opts=$config_opts --with-terminfo-dirs=/etc/_terminfo_", - "all:config_opts=$config_opts --enable-database", - "all:config_opts=$config_opts --enable-sp-funcs", - "all:config_opts=$config_opts --disable-term-driver", - "all:config_opts=$config_opts --enable-interop", - "all:config_opts=$config_opts --enable-widec", - "all:SHOULD_BUILD=echo", - "*-linux-*:SHOULD_BUILD=", - "*-w64-mingw32:SHOULD_BUILD=", - "*-apple-darwin:SHOULD_BUILD=" + "*:*:config_opts=--host=$HOST --prefix=$PREFIX", + "*:*-linux-gnu:cf_cv_ar_flags=", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --with-build-cc=gcc", + "*:*:config_opts=$config_opts --without-debug", + "*:*:config_opts=$config_opts --without-ada", + "*:*:config_opts=$config_opts --without-cxx-binding", + "*:*:config_opts=$config_opts --without-cxx", + "*:*:config_opts=$config_opts --without-ticlib", + "*:*:config_opts=$config_opts --without-tic", + "*:*:config_opts=$config_opts --without-progs", + "*:*:config_opts=$config_opts --without-tests", + "*:*:config_opts=$config_opts --without-tack", + "*:*:config_opts=$config_opts --without-manpages", + "*:*:config_opts=$config_opts --with-termlib", + "*:*:config_opts=$config_opts --disable-tic-depends", + "*:*:config_opts=$config_opts --disable-big-strings", + "*:*:config_opts=$config_opts --disable-ext-colors", + "*:*:config_opts=$config_opts --enable-pc-files", + "*:*:config_opts=$config_opts --without-shared", + "*:*:config_opts=$config_opts --without-pthread", + "*:*:config_opts=$config_opts --disable-rpath", + "*:*:config_opts=$config_opts --disable-colorfgbg", + "*:*:config_opts=$config_opts --disable-ext-mouse", + "*:*:config_opts=$config_opts --disable-symlinks", + "*:*:config_opts=$config_opts --enable-warnings", + "*:*:config_opts=$config_opts --enable-assertions", + "*:*:config_opts=$config_opts --with-default-terminfo-dir=/etc/_terminfo_", + "*:*:config_opts=$config_opts --with-terminfo-dirs=/etc/_terminfo_", + "*:*:config_opts=$config_opts --enable-database", + "*:*:config_opts=$config_opts --enable-sp-funcs", + "*:*:config_opts=$config_opts --disable-term-driver", + "*:*:config_opts=$config_opts --enable-interop", + "*:*:config_opts=$config_opts --enable-widec", + "*:*:config_opts=$config_opts --with-build-cc=$CC_FOR_BUILD", + "*:*:SHOULD_BUILD=echo", + "*:*-linux-*:SHOULD_BUILD=", + "*:*-w64-mingw32:SHOULD_BUILD=", + "*:*-apple-darwin:SHOULD_BUILD=" ], "steps": [ - "all:$SHOULD_BUILD cp $PATCH_DIR/ncurses/fallback.c ncurses", - "all:$SHOULD_BUILD ./configure $config_opts", - "all:$SHOULD_BUILD make -j$NUM_CORES $build_opts", - "all:$SHOULD_BUILD make install.libs DESTDIR=$STAGING_DIR" + "*:*:$SHOULD_BUILD cp $PATCH_DIR/ncurses/fallback.c ncurses", + "*:*:$SHOULD_BUILD bash ./configure $config_opts", + "*:*:$SHOULD_BUILD make -j$NUM_CORES $build_opts", + "*:*:$SHOULD_BUILD make install.libs DESTDIR=$STAGING_DIR" ] } } \ No newline at end of file diff --git a/packages/nlohmann-json.json b/packages/nlohmann-json.json new file mode 100644 index 0000000..a275000 --- /dev/null +++ b/packages/nlohmann-json.json @@ -0,0 +1,23 @@ +{ + "package": "nlohmann-json", + "version": "3.11.3", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "0d8ef5af7f9794e3263480193c491549b2ba6cc74bb018906202ada498a79406", + "url": "https://github.com/nlohmann/json/archive/refs/tags/v3.11.3.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/coreutils" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p $STAGING_DIR$PREFIX/include", + "*:*:cp -a include/nlohmann $STAGING_DIR$PREFIX/include/" + ] + } +} \ No newline at end of file diff --git a/packages/node@25.json b/packages/node@25.json new file mode 100644 index 0000000..84edf28 --- /dev/null +++ b/packages/node@25.json @@ -0,0 +1,30 @@ +{ + "package": "node@25", + "version": "25.1.0", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "1da054d99bb16d35c54d759f36ccc125b90070bd", + "url": "https://github.com/nodejs/node.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/ninja", + "*:*:native/python@3.14" + ], + "patches": [ + "fallback.c" + ], + "build": { + "env": [ + "*:*:config_opts=--ninja", + "*:*:config_opts=$config_opts --prefix=$PREFIX" + ], + "steps": [ + "*:*:./configure $config_opts", + "*:*:ninja -j$NUM_CORES" + ] + } +} \ No newline at end of file diff --git a/packages/onnxruntime.json b/packages/onnxruntime.json new file mode 100644 index 0000000..54c45ef --- /dev/null +++ b/packages/onnxruntime.json @@ -0,0 +1,136 @@ +{ + "package": "onnxruntime", + "version": "1.20.1", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "d4c005506a2bbf88a838b14f8d1578406b8be2fb64abb50beeff908fb272529e", + "url": "https://github.com/microsoft/onnxruntime/archive/refs/tags/v1.20.1.tar.gz" + }, + { + "kind": "git", + "path": "deps/eigen", + "sha256": "e7248b26a1ed53fa030c5c459f7ea095dfd276ac", + "url": "https://gitlab.com/libeigen/eigen.git" + }, + { + "kind": "tar.gz", + "path": "deps/abseil_cpp", + "sha256": "f50e5ac311a81382da7fa75b97310e4b9006474f9560ac46f54a9967f07d4ae3", + "url": "https://github.com/abseil/abseil-cpp/archive/refs/tags/20240722.0.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/re2", + "sha256": "eb2df807c781601c14a260a507a5bb4509be1ee626024cb45acbd57cb9d4032b", + "url": "https://github.com/google/re2/archive/refs/tags/2024-07-02.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/google_nsync", + "sha256": "80fc1e605bb3cf5f272811ece39c4fb6761ffcb9b30563301845cc9ff381eb8b", + "url": "https://github.com/google/nsync/archive/refs/tags/1.26.0.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/utf8_range", + "sha256": "e008768a46ee0ee646b8e4ef02f55af3634b3ad38b750489eb793774331ca5bd", + "url": "https://github.com/protocolbuffers/utf8_range/archive/72c943dea2b9240cd09efde15191e144bc7c7d38.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/protobuf", + "sha256": "22fdaf641b31655d4b2297f9981fa5203b2866f8332d3c6333f6b0107bb320de", + "url": "https://github.com/protocolbuffers/protobuf/archive/refs/tags/v21.12.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/date", + "sha256": "7a390f200f0ccd207e8cff6757e04817c1a0aec3e327b006b7eb451c57ee3538", + "url": "https://github.com/HowardHinnant/date/archive/refs/tags/v3.0.1.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/mp11", + "sha256": "1705680b0849cac3258e528270c9071b440b95372e5be0b9197da89e84a794eb", + "url": "https://github.com/boostorg/mp11/archive/refs/tags/boost-1.82.0.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/nlohmann_json", + "sha256": "5daca6ca216495edf89d167f808d1d03c4a4d929cef7da5e10f135ae1540c7e4", + "url": "https://github.com/nlohmann/json/archive/refs/tags/v3.10.5.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/pytorch_cpuinfo", + "sha256": "c8f43b307fa7d911d88fec05448161eb1949c3fc0cb62f3a7a2c61928cdf2e9b", + "url": "https://github.com/pytorch/cpuinfo/archive/ca678952a9a8eaa6de112d154e8e104b22f9ab3f.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/GSL", + "sha256": "f0e32cb10654fea91ad56bde89170d78cfbf4363ee0b01d8f097de2ba49f6ce9", + "url": "https://github.com/microsoft/GSL/archive/refs/tags/v4.0.0.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/safeint", + "sha256": "d6b164bcea92a746e4d44132e505c7ab1816d1089ba99ebc674ccd4b70262ed5", + "url": "https://github.com/dcleblanc/SafeInt/archive/refs/tags/3.0.28.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/flatbuffers", + "sha256": "1cce06b17cddd896b6d73cc047e36a254fb8df4d7ea18a46acf16c4c0cd3f3f3", + "url": "https://github.com/google/flatbuffers/archive/refs/tags/v23.5.26.tar.gz" + }, + { + "kind": "tar.gz", + "path": "deps/onnx", + "sha256": "0e6aa2c0a59bb2d90858ad0040ea1807117cc2f05b97702170f18e6cd6b66fb3", + "url": "https://github.com/onnx/onnx/archive/refs/tags/v1.16.1.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/make", + "*:*:native/coreutils", + "*:*:native/bash", + "*:*:native/python@3.11", + "*:*:native/patch", + "*:*:native/protobuf@21.12", + "*:*-android*:libiconv" + ], + "build": { + "env": [ + "*:*:ort_extra=", + "*:*-linux-gnu:ort_extra=CMAKE_SHARED_LINKER_FLAGS=-static-libstdc++", + "*:*-android*:ort_extra=Iconv_INCLUDE_DIR=$PREFIX/include Iconv_LIBRARY=$PREFIX/lib/libiconv.a", + "*:aarch64-apple-darwin:ort_extra=CMAKE_OSX_ARCHITECTURES=arm64", + "*:x86_64-apple-darwin:ort_extra=CMAKE_OSX_ARCHITECTURES=x86_64", + "*:aarch64-apple-ios:ort_extra=CMAKE_OSX_ARCHITECTURES=arm64 CMAKE_OSX_DEPLOYMENT_TARGET=14.0", + "*:aarch64-apple-ios-simulator:ort_extra=CMAKE_OSX_ARCHITECTURES=arm64 CMAKE_OSX_DEPLOYMENT_TARGET=14.0", + "*:aarch64-apple-ios:CC=$NATIVEPREFIX/bin/aarch64-apple-ios-clang -target aarch64-apple-ios -mios-version-min=14.0 -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios:CXX=$NATIVEPREFIX/bin/aarch64-apple-ios-clang++ -target aarch64-apple-ios -mios-version-min=14.0 -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios-simulator:CC=$NATIVEPREFIX/bin/aarch64-apple-ios-simulator-clang -target aarch64-apple-ios-simulator -mios-version-min=14.0 -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios-simulator:CXX=$NATIVEPREFIX/bin/aarch64-apple-ios-simulator-clang++ -target aarch64-apple-ios-simulator -mios-version-min=14.0 -isysroot $SDK_PATH -I$PREFIX/include" + ], + "steps": [ + "*:*:patch -p1 < $PATCH_DIR/onnxruntime/cstdint-optimizer-api.patch", + "*:*-android*:patch -p1 < $PATCH_DIR/onnxruntime/android-log-and-sink.patch", + "*:*:patch -p1 -d deps/google_nsync < cmake/patches/nsync/nsync_1.26.0.patch", + "*:*:patch -p1 -d deps/protobuf < cmake/patches/protobuf/protobuf_cmake.patch", + "*:*:patch -p1 -d deps/flatbuffers < cmake/patches/flatbuffers/flatbuffers.patch", + "*:*:patch -p1 -d deps/onnx < cmake/patches/onnx/onnx.patch", + "*:*-android*:patch -p1 -d deps/pytorch_cpuinfo < $PATCH_DIR/onnxruntime/cpuinfo-android-properties.patch", + "*:*:./build.sh --config Release --build_shared_lib --parallel --skip_tests --allow_running_as_root --compile_no_warning_as_error --skip_submodule_sync --path_to_protoc_exe $NATIVEPREFIX/bin/protoc --cmake_extra_defines CMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE CMAKE_INSTALL_PREFIX=$PREFIX FETCHCONTENT_FULLY_DISCONNECTED=ON FETCHCONTENT_SOURCE_DIR_ABSEIL_CPP=$PWD/deps/abseil_cpp FETCHCONTENT_SOURCE_DIR_RE2=$PWD/deps/re2 FETCHCONTENT_SOURCE_DIR_GOOGLE_NSYNC=$PWD/deps/google_nsync FETCHCONTENT_SOURCE_DIR_UTF8_RANGE=$PWD/deps/utf8_range FETCHCONTENT_SOURCE_DIR_PROTOBUF=$PWD/deps/protobuf FETCHCONTENT_SOURCE_DIR_DATE=$PWD/deps/date FETCHCONTENT_SOURCE_DIR_MP11=$PWD/deps/mp11 FETCHCONTENT_SOURCE_DIR_NLOHMANN_JSON=$PWD/deps/nlohmann_json FETCHCONTENT_SOURCE_DIR_PYTORCH_CPUINFO=$PWD/deps/pytorch_cpuinfo FETCHCONTENT_SOURCE_DIR_PYTORCH_CLOG=$PWD/deps/pytorch_cpuinfo FETCHCONTENT_SOURCE_DIR_GSL=$PWD/deps/GSL FETCHCONTENT_SOURCE_DIR_SAFEINT=$PWD/deps/safeint FETCHCONTENT_SOURCE_DIR_FLATBUFFERS=$PWD/deps/flatbuffers FETCHCONTENT_SOURCE_DIR_ONNX=$PWD/deps/onnx onnxruntime_USE_PREINSTALLED_EIGEN=ON eigen_SOURCE_PATH=$PWD/deps/eigen CMAKE_POLICY_VERSION_MINIMUM=3.5 onnxruntime_BUILD_UNIT_TESTS=OFF FLATBUFFERS_BUILD_FLATC=OFF $ort_extra", + "linux_*:*:DESTDIR=$STAGING_DIR cmake --install build/Linux/Release --prefix \"$PREFIX\"", + "darwin_*:*:DESTDIR=$STAGING_DIR cmake --install build/MacOS/Release --prefix \"$PREFIX\"", + "*:*:cp -a $STAGING_DIR$PREFIX/include/onnxruntime/. $STAGING_DIR$PREFIX/include/" + ] + } +} \ No newline at end of file diff --git a/packages/openssl.json b/packages/openssl.json index af1b15b..66b5657 100644 --- a/packages/openssl.json +++ b/packages/openssl.json @@ -2,61 +2,59 @@ "package": "openssl", "version": "3.5.1", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "529043b15cffa5f36077a4d0af83f3de399807181d607441d734196d889b641f", - "url": "http://www.openssl.org/source/openssl-3.5.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "529043b15cffa5f36077a4d0af83f3de399807181d607441d734196d889b641f", + "url": "http://www.openssl.org/source/openssl-3.5.1.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/make", - "all:native/perl" + "*:*:native/_", + "*:*:native/coreutils", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/sed" + ], + "export-env": [ + "*:*-linux-gnu:OPENSSL_LIBS=-lssl -lcrypto -lpthread -ldl", + "*:*-apple-darwin:OPENSSL_LIBS=-lssl -lcrypto", + "*:*-w64-mingw32:OPENSSL_LIBS=-lssl -lcrypto -lws2_32" ], "build": { "env": [ - "*-android*:ANDROID_NDK_ROOT=$PREFIX/native", - "*-android*:CC=clang", - "*-android*:AR=ar", - "*-android*:RANLIB=ranlib", - "all:config_opts=--prefix=$PREFIX --openssldir=$PREFIX/etc/openssl --libdir=$PREFIX/lib", - "all:config_opts=$config_opts no-capieng", - "all:config_opts=$config_opts no-dso", - "all:config_opts=$config_opts no-dtls1", - "all:config_opts=$config_opts no-ec_nistp_64_gcc_128", - "all:config_opts=$config_opts no-gost", - "all:config_opts=$config_opts no-md2", - "all:config_opts=$config_opts no-rc5", - "all:config_opts=$config_opts no-rdrand", - "all:config_opts=$config_opts no-rfc3779", - "all:config_opts=$config_opts no-sctp", - "all:config_opts=$config_opts no-shared", - "all:config_opts=$config_opts no-ssl-trace", - "all:config_opts=$config_opts no-ssl3", - "all:config_opts=$config_opts no-tests", - "all:config_opts=$config_opts no-unit-test", - "all:config_opts=$config_opts no-weak-ssl-ciphers", - "all:config_opts=$config_opts no-zlib", - "all:config_opts=$config_opts no-zlib-dynamic", - "*linux*:config_opts=$config_opts -fPIC -Wa,--noexecstack", - "x86_64-linux*:config_opts=$config_opts linux-x86_64", - "i686-linux*:config_opts=$config_opts linux-generic32", - "arm-linux*:config_opts=$config_opts linux-generic32", - "aarch64-linux-gnu:config_opts=$config_opts linux-generic64", - "armv7a-linux-androideabi:config_opts=$config_opts --static android-arm", - "aarch64-linux-android:config_opts=$config_opts --static android-arm64", - "aarch64-apple-darwin:config_opts=$config_opts darwin64-arm64-cc", - "aarch64-apple-ios*:config_opts=$config_opts darwin64-arm64-cc", - "x86_64-apple-darwin:config_opts=$config_opts darwin64-x86_64-cc", - "x86_64-w64-mingw32:config_opts=$config_opts mingw64", - "i686-w64-mingw32:config_opts=$config_opts mingw" + "*:*-android*:CC=clang", + "*:*-android*:AR=ar", + "*:*-android*:RANLIB=ranlib", + "*:*:config_opts=--prefix=$PREFIX --openssldir=$PREFIX/etc/openssl --libdir=lib", + "*:*:config_opts=$config_opts no-ec_nistp_64_gcc_128", + "*:*:config_opts=$config_opts no-gost", + "*:*:config_opts=$config_opts no-md2", + "*:*:config_opts=$config_opts no-rc5", + "*:*:config_opts=$config_opts no-ssl-trace", + "*:*:config_opts=$config_opts no-tests", + "*:*:config_opts=$config_opts no-unit-test", + "*:*linux*:config_opts=$config_opts -fPIC -Wa,--noexecstack", + "*:x86_64-linux-gnu:config_opts=$config_opts linux-x86_64", + "*:i686-linux*:config_opts=$config_opts linux-generic32", + "*:arm-linux*:config_opts=$config_opts linux-generic32", + "*:aarch64-linux-gnu:config_opts=$config_opts linux-generic64", + "*:armv7a-linux-androideabi:config_opts=$config_opts android-arm", + "*:aarch64-linux-android:config_opts=$config_opts android-arm64", + "*:x86_64-linux-android:config_opts=$config_opts android-x86_64", + "*:aarch64-apple-darwin:config_opts=$config_opts darwin64-arm64-cc", + "*:aarch64-apple-ios*:config_opts=$config_opts darwin64-arm64-cc", + "*:x86_64-apple-darwin:config_opts=$config_opts darwin64-x86_64-cc", + "*:x86_64-w64-mingw32:config_opts=$config_opts mingw64", + "*:i686-w64-mingw32:config_opts=$config_opts mingw" ], "steps": [ - "all:sed -i.bak 's/#define DATE \"built on: \\$date\"/#define DATE \"built on: Jan 1 1970 00:00:01\"/' util/mkbuildinf.pl", - "all:sed -i.bak 's|crypto ssl apps util tools fuzz providers doc|crypto ssl util tools providers|' build.info", - "armv7a-linux-androideabi:sed -i.bak s/arm-linux-androideabi/armv7a-linux-androideabi/g ./Configurations/15-android.conf", - "all:./Configure $config_opts", - "all:make -j$NUM_CORES build_libs", - "all:make -j$NUM_CORES DESTDIR=$STAGING_DIR install_sw" + "*:*:sed -i.bak 's/#define DATE \"built on: \\$date\"/#define DATE \"built on: Jan 1 1970 00:00:01\"/' util/mkbuildinf.pl", + "*:*:sed -i.bak 's|crypto ssl apps util tools fuzz providers doc|crypto ssl util tools providers|' build.info", + "*:armv7a-linux-androideabi:sed -i.bak s/arm-linux-androideabi/armv7a-linux-androideabi/g ./Configurations/15-android.conf", + "*:*:./Configure $config_opts", + "*:*:make -j$NUM_CORES build_libs", + "*:*:make -j$NUM_CORES DESTDIR=$STAGING_DIR install_sw" ] } } \ No newline at end of file diff --git a/packages/pcre2.json b/packages/pcre2.json new file mode 100644 index 0000000..18b87cc --- /dev/null +++ b/packages/pcre2.json @@ -0,0 +1,22 @@ +{ + "package": "pcre2", + "version": "10.46", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "8d28d7f2c3b970c3a4bf3776bcbb5adfc923183ce74bc8df1ebaad8c1985bd07", + "url": "https://github.com/PCRE2Project/pcre2/releases/download/pcre2-10.46/pcre2-10.46.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_" + ], + "build": { + "steps": [ + "*:*-linux-gnu:./configure --host=$HOST --prefix=$PREFIX --enable-static --disable-shared --with-pic", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make install DESTDIR=$STAGING_DIR" + ] + } +} \ No newline at end of file diff --git a/packages/polyseed.json b/packages/polyseed.json index 65f8a20..d463293 100644 --- a/packages/polyseed.json +++ b/packages/polyseed.json @@ -2,21 +2,21 @@ "package": "polyseed", "version": "2.1.0-patch", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "28a86b0bc178076ac65dc7d8cc28a79eb546708473efc0e8dce688f1e237ccc2", - "url": "http://github.com/MrCyjaneK/polyseed/archive/refs/tags/v2.0.0-patch.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "28a86b0bc178076ac65dc7d8cc28a79eb546708473efc0e8dce688f1e237ccc2", + "url": "http://github.com/MrCyjaneK/polyseed/archive/refs/tags/v2.0.0-patch.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/cmake", - "all:native/cmake-toolchain" + "*:*:native/_" ], "build": { "env": [], "steps": [ - "all:cmake -DCMAKE_INSTALL_PREFIX=$PREFIX -DSTATIC=ON .", - "all:make -j$NUM_CORES DESTDIR=$STAGING_DIR install" + "*:*:cmake -DCMAKE_INSTALL_PREFIX=$PREFIX -DSTATIC=ON .", + "*:*:make -j$NUM_CORES DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/protobuf.json b/packages/protobuf.json index 6ea0253..200931f 100644 --- a/packages/protobuf.json +++ b/packages/protobuf.json @@ -2,45 +2,52 @@ "package": "protobuf", "version": "3.6.1", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "b3732e471a9bb7950f090fd0457ebd2536a9ba0891b7f3785919c654fe2a2529", - "url": "http://github.com/protocolbuffers/protobuf/releases/download/v3.6.1/protobuf-cpp-3.6.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "b3732e471a9bb7950f090fd0457ebd2536a9ba0891b7f3785919c654fe2a2529", + "url": "http://github.com/protocolbuffers/protobuf/releases/download/v3.6.1/protobuf-cpp-3.6.1.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/autoconf", - "all:native/automake", - "all:native/config", - "all:native/m4", - "all:native/perl" + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/config", + "*:*:native/coreutils", + "*:*:native/gawk", + "*:*:native/grep", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/protobuf", + "*:*:native/sed" ], "patches": [ "visibility.patch" ], "build": { "env": [ - "all:CXXFLAGS=$CXXFLAGS -std=c++11", - "all:config_opts=--host=$HOST --prefix=$PREFIX", - "all:config_opts=$config_opts --disable-shared --with-protoc=$PREFIX/native/bin/protoc", - "*-linux-gnu:$config_opts --with-pic", - "all:SHOULD_BUILD=echo", - "*-linux-gnu:SHOULD_BUILD=", - "*-w64-mingw32:SHOULD_BUILD=", - "*-apple-darwin:SHOULD_BUILD=" + "*:*:CPP_FOR_BUILD=$CPP", + "*:*:CXXCPP_FOR_BUILD=$CXXCPP", + "*:*:CXXFLAGS=$CXXFLAGS -std=c++11", + "*:*:config_opts=--host=$HOST --prefix=$PREFIX", + "*:*:config_opts=$config_opts --disable-shared --with-protoc=$NATIVEPREFIX/bin/protoc", + "*:*-linux-gnu:config_opts=$config_opts --with-pic" ], "steps": [ - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.guess config.guess", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.sub config.sub", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.guess third_party/googletest/googletest/build-aux/config.guess", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.sub third_party/googletest/googletest/build-aux/config.sub", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.guess third_party/googletest/googlemock/build-aux/config.guess", - "all:$SHOULD_BUILD cp -f $PREFIX/native/usr/share/config/config.sub third_party/googletest/googlemock/build-aux/config.sub", - "all:$SHOULD_BUILD patch -p0 < $PATCH_DIR/protobuf/visibility.patch", - "all:$SHOULD_BUILD ./configure $config_opts", - "all:$SHOULD_BUILD make -j$NUM_CORES -C src libprotobuf.la", - "all:$SHOULD_BUILD make -j$NUM_CORES -C src DESTDIR=$STAGING_DIR install-libLTLIBRARIES install-nobase_includeHEADERS", - "all:$SHOULD_BUILD make -j$NUM_CORES DESTDIR=$STAGING_DIR install-pkgconfigDATA" + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess config.guess", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub config.sub", + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess third_party/googletest/googletest/build-aux/config.guess", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub third_party/googletest/googletest/build-aux/config.sub", + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess third_party/googletest/googlemock/build-aux/config.guess", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub third_party/googletest/googlemock/build-aux/config.sub", + "*:*-w64-*:sed -i.bak -e 's| third_party/googletest||g' configure", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES -C src libprotobuf.la", + "*:*:make -j$NUM_CORES -C src DESTDIR=$STAGING_DIR install-libLTLIBRARIES install-nobase_includeHEADERS", + "*:*:make -j$NUM_CORES DESTDIR=$STAGING_DIR install-pkgconfigDATA" ] } } \ No newline at end of file diff --git a/packages/qt@6_11_1.json b/packages/qt@6_11_1.json new file mode 100644 index 0000000..b92af30 --- /dev/null +++ b/packages/qt@6_11_1.json @@ -0,0 +1,199 @@ +{ + "package": "qt@6_11_1", + "version": "6_11_1", + "type": "host", + "download": [ + { + "kind": "tar.xz", + "path": "qtbase", + "sha256": "d9594a31228aa23ad6b531719a29b45f0f3989fe6c136d45767ea179f233c1ac", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtbase-everywhere-src-6.11.1.tar.xz" + }, + { + "kind": "tar.xz", + "path": "qtsvg", + "sha256": "7f3cf02f4824bf03c2c5859ea6db173bf1482a1daf24e6cdf7bc78cfa26a8a94", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtsvg-everywhere-src-6.11.1.tar.xz" + }, + { + "kind": "tar.xz", + "path": "qtwebsockets", + "sha256": "243e3aa11924c8c5c1645e892f62d013caa3766c57512ca926d5b58146646fbf", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtwebsockets-everywhere-src-6.11.1.tar.xz" + }, + { + "kind": "tar.xz", + "path": "qtshadertools", + "sha256": "2075052f9b23bcf9de045bbd180037084942f82cce870aab14a1454902c982fc", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtshadertools-everywhere-src-6.11.1.tar.xz" + }, + { + "kind": "tar.xz", + "path": "qtmultimedia", + "sha256": "390f8e52ddee3aca5c4de7eead900c84c4fa61ff6d1f0ebea9c7543365c09b0a", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtmultimedia-everywhere-src-6.11.1.tar.xz" + }, + { + "kind": "tar.xz", + "path": "qtwayland", + "sha256": "95788aa502f75441d4edf65932b235f76523084e13dbbb7b9ee2d207b32bd9b3", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtwayland-everywhere-src-6.11.1.tar.xz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/ninja", + "*:*:native/patch", + "*:*:native/sed", + "*:*:native/qt@6_11_1", + "*:*:openssl", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/wayland@1_25_0", + "*:*-linux-gnu:freetype@2_14_1", + "*:*-linux-gnu:fontconfig@2_12_6", + "*:*-linux-gnu:libxcb@1_17_0", + "*:*-linux-gnu:libXau@1_0_12", + "*:*-linux-gnu:libxkbcommon@1_13_1", + "*:*-linux-gnu:libxcb_util@0_4_1", + "*:*-linux-gnu:libxcb_util_render@0_3_10", + "*:*-linux-gnu:libxcb_util_keysyms@0_4_1", + "*:*-linux-gnu:libxcb_util_image@0_4_1", + "*:*-linux-gnu:libxcb_util_wm@0_4_2", + "*:*-linux-gnu:libxcb_util_cursor@0_1_6", + "*:*-linux-gnu:dbus@1_14_10", + "*:*-linux-gnu:wayland@1_25_0" + ], + "export-env": [ + "*:*-apple-darwin:QT_QMAKE_DEVICE_OPTIONS=MAC_SDK_PATH=$SDK_PATH;MAC_SDK_VERSION=$SDK_VERSION;CROSS_COMPILE=$HOST-;MAC_TARGET=$HOST;XCODE_VERSION=$SDK_VERSION" + ], + "build": { + "env": [ + "*:*:config_opts=-G Ninja", + "*:*:config_opts=$config_opts -DQT_HOST_PATH=$QT_HOST_PATH", + "*:*:config_opts=$config_opts -DCMAKE_PREFIX_PATH=$QT_HOST_PATH/lib/cmake", + "*:*:config_opts=$config_opts -DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DBUILD_SHARED_LIBS=OFF", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", + "*:*:config_opts=$config_opts -DQT_BUILD_EXAMPLES=FALSE", + "*:*:config_opts=$config_opts -DQT_BUILD_TESTS=FALSE", + "*:*:config_opts=$config_opts -DQT_GENERATE_SBOM=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_cups=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_qmake=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_egl=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_egl_x11=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_xcb_egl_plugin=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_xcb_glx_plugin=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_eglfs=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_evdev=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_gif=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_glib=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_icu=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_ico=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_kms=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_linuxfb=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_libudev=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_mtdev=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_openssl=ON", + "*:*:config_opts=$config_opts -DQT_FEATURE_openssl_linked=ON", + "*:*:config_opts=$config_opts -DQT_FEATURE_openvg=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_permissions=ON", + "*:*:config_opts=$config_opts -DQT_FEATURE_reduce_relocations=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_schannel=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_sctp=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_securetransport=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_system_proxies=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_use_gold_linker_alias=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_zstd=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_system_png=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_system_pcre2=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_system_harfbuzz=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_system_zlib=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_colordialog=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_dial=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_fontcombobox=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_image_heuristic_mask=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_keysequenceedit=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_lcdnumber=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_networkdiskcache=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_pdf=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_printdialog=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_printer=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_printpreviewdialog=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_printpreviewwidget=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_printsupport=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_sessionmanager=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_spatialaudio=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_sql=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_syntaxhighlighter=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_tabletevent=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_textmarkdownwriter=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_textodfwriter=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_topleveldomain=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_undocommand=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_undogroup=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_undostack=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_undoview=OFF", + "*:*:config_opts=$config_opts -DQT_FEATURE_vnc=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_pkg_config=ON", + "*:*-linux-gnu:config_opts=$config_opts -DQT_QMAKE_TARGET_MKSPEC=linux-g++", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_xcb=ON", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_xcb_xlib=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_xlib=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_freetype=ON", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_system_freetype=ON", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_fontconfig=ON", + "*:*-linux-gnu:config_opts=$config_opts -DINPUT_opengl=no", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_opengl=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_opengles2=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_opengles3=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_opengles31=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_opengles32=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_opengl_desktop=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_vulkan=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_backtrace=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_dbus=ON", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_dbus_linked=ON", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland_client=ON", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland_server=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland_drm_egl_server_buffer=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland-shm-emulation-server-buffer=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland-client-fullscreen-shell-v1=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland-client-ivi-shell=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland-client-wl-shell=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland-client-xdg-shell-v5=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_wayland-client-xdg-shell-v6=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DBUILD_WITH_PCH=OFF", + "*:*-linux-gnu:config_opts=$config_opts -DQT_FEATURE_linux_v4l=OFF", + "*:*-apple-darwin:config_opts=$config_opts -DQT_QMAKE_TARGET_MKSPEC=macx-clang", + "*:*-apple-darwin:config_opts=$config_opts -DQT_FEATURE_accessibility=OFF", + "*:*-apple-darwin:config_opts=$config_opts -DQT_FEATURE_dbus=OFF", + "*:*-apple-darwin:config_opts=$config_opts -DQT_FEATURE_freetype=OFF", + "*:*-apple-darwin:config_opts=$config_opts -DQT_FEATURE_ffmpeg=OFF", + "*:*-apple-darwin:config_opts=$config_opts -DBUILD_WITH_PCH=OFF", + "*:*-apple-darwin:config_opts=$config_opts -DQT_NO_APPLE_SDK_AND_XCODE_CHECK=ON", + "*:*-apple-darwin:config_opts=$config_opts -DQT_FEATURE_appstore_compliant=ON", + "*:*-w64-mingw32:config_opts=$config_opts -DQT_QMAKE_TARGET_MKSPEC=win32-g++", + "*:*-w64-mingw32:config_opts=$config_opts -DINPUT_opengl=no", + "*:*-w64-mingw32:config_opts=$config_opts -DQT_FEATURE_dbus=OFF", + "*:*-w64-mingw32:config_opts=$config_opts -DQT_FEATURE_freetype=OFF", + "*:*-w64-mingw32:config_opts=$config_opts -DQT_FEATURE_ffmpeg=OFF", + "*:*-w64-mingw32:config_opts=$config_opts -DQT_FEATURE_wmf=ON", + "*:*-w64-mingw32:config_opts=$config_opts -DBUILD_WITH_PCH=ON" + ], + "steps": [ + "*:*:for mod in qtbase qtsvg qtwebsockets qtshadertools qtmultimedia qtwayland; do inner=$mod/$mod-everywhere-src-*; if [ -d $inner ]; then mv $inner/* $mod/ && rmdir $inner; fi; done", + "*:*:cp $PATCH_DIR/qt/root_CMakeLists.txt CMakeLists.txt", + "*:*:patch -p1 < $PATCH_DIR/qt/rcc_hardcode_timestamp.patch", + "*:*:patch -p1 < $PATCH_DIR/qt/windows_func_fix.patch", + "*:*-linux-gnu:cd qtbase && patch -p1 < $PATCH_DIR/qt/libxau-fix.patch", + "*:*-linux-gnu:cd qtmultimedia && patch -p1 < $PATCH_DIR/qt/v4l2.patch", + "*:*-apple-darwin:cd qtbase && patch -p1 < $PATCH_DIR/qt/fix_static_qt_darwin_camera_permissions.patch", + "*:*-{linux-gnu,w64-mingw32}:cmake . $config_opts", + "*:*-apple-darwin:cmake . $config_opts \"-DQT_QMAKE_DEVICE_OPTIONS=$QT_QMAKE_DEVICE_OPTIONS\"", + "*:*:env -u C_INCLUDE_PATH -u CPLUS_INCLUDE_PATH -u OBJC_INCLUDE_PATH -u OBJCPLUS_INCLUDE_PATH -u CPATH -u LIBRARY_PATH cmake --build . --parallel $NUM_CORES", + "*:*:DESTDIR=$STAGING_DIR cmake --install ." + ] + } +} \ No newline at end of file diff --git a/packages/readline.json b/packages/readline.json index 34a5723..275d626 100644 --- a/packages/readline.json +++ b/packages/readline.json @@ -2,29 +2,29 @@ "package": "readline", "version": "8.0", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "e339f51971478d369f8a053a330a190781acb9864cf4c541060f12078948e461", - "url": "http://ftpmirror.gnu.org/gnu/readline/readline-8.0.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "e339f51971478d369f8a053a330a190781acb9864cf4c541060f12078948e461", + "url": "http://ftpmirror.gnu.org/gnu/readline/readline-8.0.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/autoconf", - "all:native/perl", - "all:ncurses" + "*:*:native/_", + "*:*:ncurses" ], "build": { "env": [ - "all:config_opts=--host=$HOST --prefix=$PREFIX --exec-prefix=$PREFIX", - "all:config_opts=$config_opts --disable-shared --with-curses --disable-debug-mode", - "all:SHOULD_BUILD=echo", - "*-linux-*:SHOULD_BUILD=", - "*-apple-darwin:SHOULD_BUILD=" + "*:*:config_opts=--host=$HOST --prefix=$PREFIX --exec-prefix=$PREFIX", + "*:*:config_opts=$config_opts --disable-shared --with-curses --disable-debug-mode", + "*:*:SHOULD_BUILD=echo", + "*:*-linux-*:SHOULD_BUILD=", + "*:*-apple-darwin:SHOULD_BUILD=" ], "steps": [ - "all:$SHOULD_BUILD ./configure $config_opts", - "all:$SHOULD_BUILD make -j$NUM_CORES $build_opts", - "all:$SHOULD_BUILD make -j$NUM_CORES install DESTDIR=$STAGING_DIR prefix=$PREFIX exec-prefix=$PREFIX" + "*:*:$SHOULD_BUILD ./configure $config_opts", + "*:*:$SHOULD_BUILD make -j$NUM_CORES $build_opts", + "*:*:$SHOULD_BUILD make -j$NUM_CORES install DESTDIR=$STAGING_DIR prefix=$PREFIX exec-prefix=$PREFIX" ] } } \ No newline at end of file diff --git a/packages/rust-hello-world.json b/packages/rust-hello-world.json new file mode 100644 index 0000000..d59fa13 --- /dev/null +++ b/packages/rust-hello-world.json @@ -0,0 +1,29 @@ +{ + "package": "rust-hello-world", + "version": "0.0.0", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "e0fa23f1a3cb1eb1407165bd2fc36d2f6e6ad728", + "url": "https://github.com/meta-rust/rust-hello-world.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/coreutils", + "*:*:native/git", + "*:*:native/gzip", + "*:*:native/tar", + "*:*:native/rust-toolchain", + "*:*:rust-std" + ], + "build": { + "env": [], + "steps": [ + "*:*:cargo build --target $RUST_TRIPLET --release", + "*:*:$NATIVEPREFIX/bin/mkdir -p $STAGING_DIR$PREFIX/bin", + "*:*:$NATIVEPREFIX/bin/cp ./target/$RUST_TRIPLET/release/rust-hello-world.exe $STAGING_DIR$PREFIX/bin 2>/dev/null || $NATIVEPREFIX/bin/cp ./target/$RUST_TRIPLET/release/rust-hello-world $STAGING_DIR$PREFIX/bin" + ] + } +} \ No newline at end of file diff --git a/packages/rust-std.json b/packages/rust-std.json new file mode 100644 index 0000000..cfb80d1 --- /dev/null +++ b/packages/rust-std.json @@ -0,0 +1,433 @@ +{ + "package": "rust-std", + "version": "1.95.0", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "ea9b82a83e46967537c3569ce9d6fa16811c043a96e651376c349e70241ca515", + "url": "http://static.rust-lang.org/dist/rustc-1.95.0-src.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_/_", + "*:*:native/_", + "*:*:native/bash", + "*:*:native/cmake", + "*:*:native/coreutils", + "*:*:native/curl", + "*:*:native/sed", + "*:*:native/grep", + "*:*:native/make", + "*:*:native/ninja", + "*:*:native/openssl", + "*:*:native/pkgconf", + "*:*:native/python@3.11", + "*:*:native/rust", + "*:*:native/tar", + "*:*:native/zlib", + "*:*:native/libpsl" + ], + "export-env": [ + "linux_arm64:aarch64-linux-gnu:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/bin/cargo-linker-clang", + "linux_arm64:aarch64-linux-gnu:RUSTFLAGS=-Clinker=$NATIVEPREFIX/bin/cargo-linker-clang -Clink-arg=-L$NATIVEPREFIX/lib", + "linux_amd64:x86_64-linux-gnu:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/bin/cargo-linker-clang", + "linux_amd64:x86_64-linux-gnu:RUSTFLAGS=-Clinker=$NATIVEPREFIX/bin/cargo-linker-clang -Clink-arg=-L$NATIVEPREFIX/lib", + "darwin_arm64:aarch64-apple-darwin:CARGO_TARGET_AARCH64_APPLE_DARWIN_LINKER=$NATIVEPREFIX/bin/cargo-linker-clang", + "darwin_arm64:aarch64-apple-darwin:RUSTFLAGS=-Clinker=$NATIVEPREFIX/bin/cargo-linker-clang -Clink-arg=-L$NATIVEPREFIX/lib" + ], + "build": { + "env": [ + "*:*:OPENSSL_ROOT_DIR=$NATIVEPREFIX", + "*:*:ZLIB_ROOT=$NATIVEPREFIX", + "*:*:RUST_CC=$CC", + "*:*:RUST_CXX=$CXX", + "*:*:RUST_LINKER=$CC", + "*:*:RUST_AR=$AR", + "*:*:RUST_CFLAGS=$CFLAGS", + "*:*:RUST_CXXFLAGS=$CXXFLAGS", + "*:*:RUST_LDFLAGS=$LDFLAGS", + "*:*-apple-*:RUST_CC=$NATIVEPREFIX/bin/$HOST-clang", + "*:*-apple-*:RUST_CXX=$NATIVEPREFIX/bin/$HOST-clang++", + "*:*-apple-*:RUST_LINKER=$NATIVEPREFIX/bin/$HOST-clang", + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin", + "*:*:CC=$NATIVEPREFIX/_/bin/clang", + "*:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "*:*:CC_FOR_BUILD=$NATIVEPREFIX/_/bin/clang", + "*:*:CXX_FOR_BUILD=$NATIVEPREFIX/_/bin/clang++", + "*:*:AR=$NATIVEPREFIX/_/bin/ar", + "*:*:RANLIB=$NATIVEPREFIX/_/bin/ranlib", + "*:*:NM=$NATIVEPREFIX/_/bin/nm", + "*:*:OBJCOPY=$NATIVEPREFIX/_/bin/objcopy", + "linux_amd64:*-linux-gnu:STRIP=$NATIVEPREFIX/_/bin/llvm-strip", + "linux_*:*-linux-gnu:CMAKE_SYSTEM_NAME=Linux", + "darwin_arm64:*:CMAKE_SYSTEM_NAME=Darwin", + "linux_*:*-linux-gnu:CFLAGS=-fPIC -I$NATIVEPREFIX/include", + "linux_*:*-linux-gnu:CXXFLAGS=-fPIC -I$NATIVEPREFIX/include", + "linux_*:*-linux-gnu:LDFLAGS=-L$NATIVEPREFIX/lib", + "linux_amd64:*:BUILD_TRIPLET=x86_64-unknown-linux-gnu", + "linux_arm64:*:BUILD_TRIPLET=aarch64-unknown-linux-gnu", + "darwin_arm64:*:BUILD_TRIPLET=aarch64-apple-darwin", + "*:aarch64-linux-gnu:CFLAGS_aarch64_unknown_linux_gnu=$RUST_CFLAGS", + "*:aarch64-linux-gnu:CXXFLAGS_aarch64_unknown_linux_gnu=$RUST_CXXFLAGS", + "*:aarch64-linux-gnu:LDFLAGS_aarch64_unknown_linux_gnu=$RUST_LDFLAGS", + "*:aarch64-linux-gnu:AS_aarch64_unknown_linux_gnu=$AS", + "*:x86_64-linux-gnu:CFLAGS_x86_64_unknown_linux_gnu=$RUST_CFLAGS", + "*:x86_64-linux-gnu:CXXFLAGS_x86_64_unknown_linux_gnu=$RUST_CXXFLAGS", + "*:x86_64-linux-gnu:LDFLAGS_x86_64_unknown_linux_gnu=$RUST_LDFLAGS", + "*:x86_64-linux-gnu:AS_x86_64_unknown_linux_gnu=$AS", + "*:x86_64-w64-mingw32:CFLAGS_x86_64_pc_windows_gnu=$RUST_CFLAGS", + "*:x86_64-w64-mingw32:CXXFLAGS_x86_64_pc_windows_gnu=$RUST_CXXFLAGS", + "*:x86_64-w64-mingw32:LDFLAGS_x86_64_pc_windows_gnu=$RUST_LDFLAGS", + "*:aarch64-linux-android:CFLAGS_aarch64_linux_android=$RUST_CFLAGS", + "*:aarch64-linux-android:CXXFLAGS_aarch64_linux_android=$RUST_CXXFLAGS", + "*:aarch64-linux-android:LDFLAGS_aarch64_linux_android=$RUST_LDFLAGS", + "*:aarch64-linux-android:CC_aarch64_linux_android=$RUST_CC", + "*:aarch64-linux-android:CXX_aarch64_linux_android=$RUST_CXX", + "*:aarch64-linux-android:AR_aarch64_linux_android=$RUST_AR", + "*:x86_64-linux-android:CFLAGS_x86_64_linux_android=$RUST_CFLAGS", + "*:x86_64-linux-android:CXXFLAGS_x86_64_linux_android=$RUST_CXXFLAGS", + "*:x86_64-linux-android:LDFLAGS_x86_64_linux_android=$RUST_LDFLAGS", + "*:x86_64-linux-android:CC_x86_64_linux_android=$RUST_CC", + "*:x86_64-linux-android:CXX_x86_64_linux_android=$RUST_CXX", + "*:x86_64-linux-android:AR_x86_64_linux_android=$RUST_AR", + "*:armv7a-linux-androideabi:CFLAGS_armv7_linux_androideabi=$RUST_CFLAGS", + "*:armv7a-linux-androideabi:CXXFLAGS_armv7_linux_androideabi=$RUST_CXXFLAGS", + "*:armv7a-linux-androideabi:LDFLAGS_armv7_linux_androideabi=$RUST_LDFLAGS", + "*:armv7a-linux-androideabi:CC_armv7_linux_androideabi=$RUST_CC", + "*:armv7a-linux-androideabi:CXX_armv7_linux_androideabi=$RUST_CXX", + "*:armv7a-linux-androideabi:AR_armv7_linux_androideabi=$RUST_AR", + "*:*:RUST_STD_PROFILE=std", + "linux_amd64:x86_64-linux-gnu:RUST_STD_PROFILE=", + "linux_amd64:x86_64-linux-gnu:RUST_LLVM_PROFILE=", + "linux_arm64:aarch64-linux-gnu:RUST_STD_PROFILE=", + "linux_arm64:aarch64-linux-gnu:RUST_LLVM_PROFILE=", + "linux_amd64:aarch64-linux-gnu:RUST_STD_PROFILE=std-native", + "linux_arm64:x86_64-linux-gnu:RUST_STD_PROFILE=std-native", + "darwin_arm64:*:RUST_STD_PROFILE=std-native", + "*:*-apple-*:RUST_STD_PROFILE=std-apple", + "darwin_arm64:aarch64-apple-darwin:RUST_STD_PROFILE=", + "darwin_arm64:aarch64-apple-darwin:RUST_LLVM_PROFILE=", + "*:*-w64-mingw32:RUST_STD_PROFILE=std-mingw", + "*:*android*:RUST_STD_PROFILE=std-android", + "*:*android*:RUST_LLVM_PROFILE=llvm", + "*:*-linux-gnu:RUST_LLVM_PROFILE=llvm", + "*:*-w64-mingw32:RUST_LLVM_PROFILE=llvm" + ], + "profiles": { + "llvm": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/_/bin:$NATIVEPREFIX/bin", + "*:*:CC=$NATIVEPREFIX/_/bin/clang", + "*:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "*:*:CFLAGS=-fPIC -I$NATIVEPREFIX/include", + "*:*:CXXFLAGS=-fPIC -I$NATIVEPREFIX/include", + "linux_*:*:LDFLAGS=-L$NATIVEPREFIX/_/sysroot/lib", + "linux_amd64:aarch64-linux-gnu:HOST=x86_64-linux-gnu", + "linux_arm64:x86_64-linux-gnu:HOST=aarch64-linux-gnu", + "darwin_arm64:*:SDKROOT=$NATIVEPREFIX/_/SDK/MacOSX26.1.sdk", + "*:*:ARFLAGS=" + ], + "unset": [ + "LD", + "AS", + "NM", + "OBJCOPY", + "OBJDUMP", + "STRIP", + "READELF", + "MACOSX_DEPLOYMENT_TARGET", + "CMAKE_SYSTEM_NAME", + "CC", + "CXX", + "CFLAGS", + "CXXFLAGS", + "CPPFLAGS", + "LDFLAGS", + "RUST_LDFLAGS", + "LIBRARY_PATH", + "CC_x86_64_unknown_linux_gnu", + "CXX_x86_64_unknown_linux_gnu", + "CFLAGS_x86_64_unknown_linux_gnu", + "CXXFLAGS_x86_64_unknown_linux_gnu", + "LDFLAGS_x86_64_unknown_linux_gnu", + "CC_aarch64_unknown_linux_gnu", + "CXX_aarch64_unknown_linux_gnu", + "CFLAGS_aarch64_unknown_linux_gnu", + "CXXFLAGS_aarch64_unknown_linux_gnu", + "LDFLAGS_aarch64_unknown_linux_gnu", + "CC_x86_64_pc_windows_gnu", + "CXX_x86_64_pc_windows_gnu", + "CFLAGS_x86_64_pc_windows_gnu", + "CXXFLAGS_x86_64_pc_windows_gnu", + "LDFLAGS_x86_64_pc_windows_gnu", + "CC_aarch64_linux_android", + "CXX_aarch64_linux_android", + "CFLAGS_aarch64_linux_android", + "CXXFLAGS_aarch64_linux_android", + "LDFLAGS_aarch64_linux_android", + "CC_x86_64_linux_android", + "CXX_x86_64_linux_android", + "CFLAGS_x86_64_linux_android", + "CXXFLAGS_x86_64_linux_android", + "LDFLAGS_x86_64_linux_android", + "CC_armv7_linux_androideabi", + "CXX_armv7_linux_androideabi", + "CFLAGS_armv7_linux_androideabi", + "CXXFLAGS_armv7_linux_androideabi", + "LDFLAGS_armv7_linux_androideabi" + ] + }, + "std": { + "env": [ + "*:*:ARFLAGS=" + ], + "unset": [ + "LD", + "AS", + "NM", + "OBJCOPY", + "OBJDUMP", + "STRIP", + "READELF", + "MACOSX_DEPLOYMENT_TARGET", + "CMAKE_SYSTEM_NAME" + ] + }, + "std-android": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/_/bin:$NATIVEPREFIX/bin", + "*:*:CC=$NATIVEPREFIX/_/bin/clang", + "*:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "linux_arm64:*:CFLAGS_aarch64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_arm64:*:CXXFLAGS_aarch64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_amd64:*:CFLAGS_x86_64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_amd64:*:CXXFLAGS_x86_64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "*:*:ARFLAGS=" + ], + "unset": [ + "LD", + "AS", + "NM", + "OBJCOPY", + "OBJDUMP", + "STRIP", + "READELF", + "MACOSX_DEPLOYMENT_TARGET", + "CMAKE_SYSTEM_NAME", + "CFLAGS", + "CXXFLAGS", + "CPPFLAGS", + "LDFLAGS", + "CFLAGS_x86_64_unknown_linux_gnu", + "CXXFLAGS_x86_64_unknown_linux_gnu", + "CFLAGS_aarch64_unknown_linux_gnu", + "CXXFLAGS_aarch64_unknown_linux_gnu", + "CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER", + "CARGO_TARGET_AARCH64_LINUX_ANDROID_RUSTFLAGS", + "CARGO_TARGET_X86_64_LINUX_ANDROID_LINKER", + "CARGO_TARGET_X86_64_LINUX_ANDROID_RUSTFLAGS", + "CARGO_TARGET_ARMV7_LINUX_ANDROIDEABI_LINKER", + "CARGO_TARGET_ARMV7_LINUX_ANDROIDEABI_RUSTFLAGS" + ] + }, + "std-apple": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/bin:$NATIVEPREFIX/_/bin", + "*:*:CC=$NATIVEPREFIX/bin/clang", + "*:*:CXX=$NATIVEPREFIX/bin/clang++", + "*:*:MACOSX_DEPLOYMENT_TARGET=$OSX_MIN_VERSION", + "*:*:CFLAGS=-fPIC -I$NATIVEPREFIX/include", + "*:*:CXXFLAGS=-fPIC -I$NATIVEPREFIX/include", + "linux_arm64:*:CXXFLAGS_aarch64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_arm64:*:CFLAGS_aarch64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_amd64:*:CXXFLAGS_x86_64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_amd64:*:CFLAGS_x86_64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "*:*:ARFLAGS=" + ], + "unset": [ + "LD", + "AS", + "NM", + "OBJCOPY", + "OBJDUMP", + "STRIP", + "READELF", + "CMAKE_SYSTEM_NAME", + "CC", + "CXX", + "LDFLAGS", + "MACOSX_DEPLOYMENT_TARGET", + "CFLAGS", + "CXXFLAGS", + "CPPFLAGS", + "CFLAGS_x86_64_unknown_linux_gnu", + "CXXFLAGS_x86_64_unknown_linux_gnu", + "CFLAGS_aarch64_unknown_linux_gnu", + "CXXFLAGS_aarch64_unknown_linux_gnu", + "CFLAGS_x86_64_pc_windows_gnu", + "CXXFLAGS_x86_64_pc_windows_gnu" + ] + }, + "std-mingw": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/_/bin:$NATIVEPREFIX/bin", + "*:*:CC=$NATIVEPREFIX/_/bin/clang", + "*:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "*:*:CFLAGS=-fPIC -I$NATIVEPREFIX/include", + "*:*:CXXFLAGS=-fPIC -I$NATIVEPREFIX/include", + "linux_*:*:LDFLAGS=-L$NATIVEPREFIX/_/sysroot/lib", + "linux_arm64:*:CFLAGS_aarch64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_arm64:*:CXXFLAGS_aarch64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_amd64:*:CFLAGS_x86_64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "linux_amd64:*:CXXFLAGS_x86_64_unknown_linux_gnu=-fPIC -I$NATIVEPREFIX/include", + "*:*:ARFLAGS=" + ], + "unset": [ + "LD", + "AS", + "NM", + "OBJCOPY", + "OBJDUMP", + "STRIP", + "READELF", + "MACOSX_DEPLOYMENT_TARGET", + "CMAKE_SYSTEM_NAME", + "CC", + "CXX", + "CFLAGS", + "CXXFLAGS", + "CPPFLAGS", + "LDFLAGS", + "RUST_LDFLAGS", + "LIBRARY_PATH", + "CFLAGS_x86_64_unknown_linux_gnu", + "CXXFLAGS_x86_64_unknown_linux_gnu", + "CFLAGS_aarch64_unknown_linux_gnu", + "CXXFLAGS_aarch64_unknown_linux_gnu" + ] + }, + "std-native": { + "env": [ + "*:*:PATH=$NATIVEPREFIX/_/bin:$NATIVEPREFIX/bin", + "*:*:CC=$NATIVEPREFIX/_/bin/clang", + "*:*:CXX=$NATIVEPREFIX/_/bin/clang++", + "*:*:CFLAGS=-fPIC -I$NATIVEPREFIX/include", + "*:*:CXXFLAGS=-fPIC -I$NATIVEPREFIX/include", + "linux_amd64:aarch64-linux-gnu:HOST=x86_64-linux-gnu", + "linux_arm64:x86_64-linux-gnu:HOST=aarch64-linux-gnu", + "darwin_arm64:*:SDKROOT=$NATIVEPREFIX/_/SDK/MacOSX26.1.sdk", + "darwin_arm64:*:CXXFLAGS=-fPIC -stdlib=libc++", + "darwin_*:x86_64-linux-gnu:CFLAGS_x86_64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/usr/include", + "darwin_*:x86_64-linux-gnu:CXXFLAGS_x86_64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/include/c++/13.4.0 -I$PREFIX/include/c++/13.4.0/$HOST -I$PREFIX/usr/include", + "darwin_*:x86_64-linux-gnu:LDFLAGS_x86_64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -L$PREFIX/lib -L$PREFIX/usr/lib", + "darwin_*:aarch64-linux-gnu:CFLAGS_aarch64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/usr/include", + "darwin_*:aarch64-linux-gnu:CXXFLAGS_aarch64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/include/c++/13.4.0 -I$PREFIX/include/c++/13.4.0/$HOST -I$PREFIX/usr/include", + "darwin_*:aarch64-linux-gnu:LDFLAGS_aarch64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -L$PREFIX/lib -L$PREFIX/usr/lib", + "darwin_*:x86_64-linux-gnu:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/bin/$HOST-gcc", + "darwin_*:x86_64-linux-gnu:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_RUSTFLAGS=-Clink-arg=--sysroot=$PREFIX/sysroot -Clink-arg=-L$PREFIX/lib -Clink-arg=-L$PREFIX/usr/lib", + "darwin_*:aarch64-linux-gnu:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/bin/$HOST-gcc", + "darwin_*:aarch64-linux-gnu:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_RUSTFLAGS=-Clink-arg=--sysroot=$PREFIX/sysroot -Clink-arg=-L$PREFIX/lib -Clink-arg=-L$PREFIX/usr/lib", + "linux_amd64:aarch64-linux-gnu:CFLAGS_aarch64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/usr/include", + "linux_amd64:aarch64-linux-gnu:CXXFLAGS_aarch64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/include/c++/13.4.0 -I$PREFIX/include/c++/13.4.0/$HOST -I$PREFIX/usr/include", + "linux_amd64:aarch64-linux-gnu:LDFLAGS_aarch64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -L$PREFIX/lib -L$PREFIX/usr/lib", + "linux_amd64:aarch64-linux-gnu:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/bin/$HOST-gcc", + "linux_amd64:aarch64-linux-gnu:CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_RUSTFLAGS=-Clink-arg=--sysroot=$PREFIX/sysroot -Clink-arg=-L$PREFIX/lib -Clink-arg=-L$PREFIX/usr/lib", + "linux_arm64:x86_64-linux-gnu:CFLAGS_x86_64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/usr/include", + "linux_arm64:x86_64-linux-gnu:CXXFLAGS_x86_64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -I$PREFIX/include -I$PREFIX/include/c++/13.4.0 -I$PREFIX/include/c++/13.4.0/$HOST -I$PREFIX/usr/include", + "linux_arm64:x86_64-linux-gnu:LDFLAGS_x86_64_unknown_linux_gnu=--sysroot=$PREFIX/sysroot -L$PREFIX/lib -L$PREFIX/usr/lib", + "linux_arm64:x86_64-linux-gnu:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=$NATIVEPREFIX/bin/$HOST-gcc", + "linux_arm64:x86_64-linux-gnu:CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_RUSTFLAGS=-Clink-arg=--sysroot=$PREFIX/sysroot -Clink-arg=-L$PREFIX/lib -Clink-arg=-L$PREFIX/usr/lib", + "linux_amd64:x86_64-linux-gnu:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang", + "linux_arm64:aarch64-linux-gnu:RUSTFLAGS=-Clinker=$NATIVEPREFIX/_/bin/clang", + "*:*:ARFLAGS=" + ], + "unset": [ + "LD", + "AS", + "NM", + "OBJCOPY", + "OBJDUMP", + "STRIP", + "READELF", + "MACOSX_DEPLOYMENT_TARGET", + "CMAKE_SYSTEM_NAME", + "CC", + "CXX", + "CFLAGS", + "CXXFLAGS", + "CPPFLAGS", + "LDFLAGS", + "RUST_CFLAGS", + "RUST_CXXFLAGS", + "RUST_LDFLAGS", + "CFLAGS_aarch64_unknown_linux_gnu", + "CXXFLAGS_aarch64_unknown_linux_gnu", + "LDFLAGS_aarch64_unknown_linux_gnu", + "CFLAGS_x86_64_unknown_linux_gnu", + "CXXFLAGS_x86_64_unknown_linux_gnu", + "LDFLAGS_x86_64_unknown_linux_gnu", + "CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_LINKER", + "CARGO_TARGET_AARCH64_UNKNOWN_LINUX_GNU_RUSTFLAGS", + "CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER", + "CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_RUSTFLAGS" + ] + } + }, + "steps": [ + "*:*:ln -sf $NATIVEPREFIX/_/bin/clang $NATIVEPREFIX/bin/cc", + "*:*:ln -sf $NATIVEPREFIX/_/bin/clang++ $NATIVEPREFIX/bin/c++", + "linux_*:*-apple-*:ln -sf $NATIVEPREFIX/_/bin/llvm-strip $NATIVEPREFIX/bin/strip", + "*:*-apple-ios*:test -L $NATIVEPREFIX/bin/xcrun && mv $NATIVEPREFIX/bin/xcrun $NATIVEPREFIX/bin/xcrun.real || true", + "*:*-apple-ios*:cp -f $PATCH_DIR/rust-std/xcrun $NATIVEPREFIX/bin/xcrun", + "*:*-apple-ios*:chmod +x $NATIVEPREFIX/bin/xcrun", + "*:*:ln -sf $NATIVEPREFIX/bin/bash $NATIVEPREFIX/_/bin/sh", + "*:*:ln -sf $NATIVEPREFIX/bin/uname $NATIVEPREFIX/_/bin/uname", + "darwin_arm64:*:rm -f $NATIVEPREFIX/lib/libc++abi*.dylib $NATIVEPREFIX/lib/libunwind*.dylib", + "*:*:echo 'profile = \"library\"' > config.toml", + "*:*:echo '[build]' >> config.toml", + "*:*:echo 'vendor = true' >> config.toml", + "*:*:echo build = \\\"$BUILD_TRIPLET\\\" >> config.toml", + "*:*:echo \"target = [\\\"$RUST_TRIPLET\\\"]\" >> config.toml", + "*:*:echo rustc = \\\"$NATIVEPREFIX/bin/rustc\\\" >> config.toml", + "*:*:echo cargo = \\\"$NATIVEPREFIX/bin/cargo\\\" >> config.toml", + "*:*android*:echo android-ndk = \\\"$NATIVEPREFIX\\\" >> config.toml", + "*:*:printf '[target.%s]\\n' \"$BUILD_TRIPLET\" >> config.toml", + "*:*:echo cc = \\\"$NATIVEPREFIX/_/bin/clang\\\" >> config.toml", + "*:*:echo cxx = \\\"$NATIVEPREFIX/_/bin/clang++\\\" >> config.toml", + "*:*:echo linker = \\\"$NATIVEPREFIX/_/bin/clang\\\" >> config.toml", + "*:*:test \"$RUST_TRIPLET\" = \"$BUILD_TRIPLET\" || printf '[target.%s]\\n' \"$RUST_TRIPLET\" >> config.toml", + "*:*:test \"$RUST_TRIPLET\" = \"$BUILD_TRIPLET\" || echo cc = \\\"$RUST_CC\\\" >> config.toml", + "*:*:test \"$RUST_TRIPLET\" = \"$BUILD_TRIPLET\" || echo cxx = \\\"$RUST_CXX\\\" >> config.toml", + "*:*:test \"$RUST_TRIPLET\" = \"$BUILD_TRIPLET\" || echo linker = \\\"$RUST_LINKER\\\" >> config.toml", + "*:*:test \"$RUST_TRIPLET\" = \"$BUILD_TRIPLET\" || echo ar = \\\"$RUST_AR\\\" >> config.toml", + "*:*:echo '[llvm]' >> config.toml", + "*:*:echo 'ninja = true' >> config.toml", + "*:*:echo 'download-ci-llvm = false' >> config.toml", + "*:*:echo 'libzstd = false' >> config.toml", + "linux_arm64:aarch64-linux-gnu:sed -i 's/download-ci-llvm = false/download-ci-llvm = true/; s/libzstd = false/libzstd = true/' config.toml", + "*:*:@$RUST_LLVM_PROFILE python3 ./x.py build llvm -j$NUM_CORES", + "*:*:@$RUST_STD_PROFILE python3 ./x.py build library/std --stage 1 --target $RUST_TRIPLET -j$NUM_CORES", + "linux_*:*-apple-*:ln -sf $RUST_CC $NATIVEPREFIX/bin/cc", + "linux_*:*-apple-*:ln -sf $RUST_CXX $NATIVEPREFIX/bin/c++", + "linux_*:*-android*:ln -sf $RUST_CC $NATIVEPREFIX/bin/cc", + "linux_*:*-android*:ln -sf $RUST_CXX $NATIVEPREFIX/bin/c++", + "*:*:$NATIVEPREFIX/bin/mkdir -p $STAGING_DIR$NATIVEPREFIX/bin $STAGING_DIR$NATIVEPREFIX/lib/rustlib", + "*:*-apple-ios*:cp -f $PATCH_DIR/rust-std/xcrun $STAGING_DIR$NATIVEPREFIX/bin/xcrun", + "*:*-apple-ios*:chmod +x $STAGING_DIR$NATIVEPREFIX/bin/xcrun", + "*:*:touch $STAGING_DIR$NATIVEPREFIX/bin/.keep", + "linux_amd64:x86_64-linux-gnu:printf '#!/bin/sh\\nexec \"$NATIVEPREFIX/bin/x86_64-linux-gnu-gcc\" --sysroot=\"$PREFIX/sysroot\" \"$@\"\\n' > $STAGING_DIR$NATIVEPREFIX/bin/cargo-linker-clang", + "linux_amd64:x86_64-linux-gnu:chmod +x $STAGING_DIR$NATIVEPREFIX/bin/cargo-linker-clang", + "linux_amd64:x86_64-linux-gnu:cp -a $NATIVEPREFIX/lib/rustlib/$RUST_TRIPLET $STAGING_DIR$NATIVEPREFIX/lib/rustlib/", + "linux_arm64:aarch64-linux-gnu:printf '#!/bin/sh\\nexec \"$NATIVEPREFIX/bin/aarch64-linux-gnu-gcc\" --sysroot=\"$PREFIX/sysroot\" \"$@\"\\n' > $STAGING_DIR$NATIVEPREFIX/bin/cargo-linker-clang", + "linux_arm64:aarch64-linux-gnu:chmod +x $STAGING_DIR$NATIVEPREFIX/bin/cargo-linker-clang", + "linux_arm64:aarch64-linux-gnu:cp -a $NATIVEPREFIX/lib/rustlib/$RUST_TRIPLET $STAGING_DIR$NATIVEPREFIX/lib/rustlib/", + "darwin_arm64:aarch64-apple-darwin:printf '#!/bin/sh\\nexec \"$NATIVEPREFIX/bin/aarch64-apple-darwin-clang\" -mmacosx-version-min=13.0 -isysroot \"$NATIVEPREFIX/SDK/MacOSX26.1.sdk\" -L\"$PREFIX/lib\" -lc++ -lc++abi \"$@\"\\n' > $STAGING_DIR$NATIVEPREFIX/bin/cargo-linker-clang", + "darwin_arm64:aarch64-apple-darwin:chmod +x $STAGING_DIR$NATIVEPREFIX/bin/cargo-linker-clang", + "darwin_arm64:aarch64-apple-darwin:cp -a $NATIVEPREFIX/lib/rustlib/$RUST_TRIPLET $STAGING_DIR$NATIVEPREFIX/lib/rustlib/", + "*:*:@$RUST_STD_PROFILE $NATIVEPREFIX/bin/rm -rf $STAGING_DIR$NATIVEPREFIX/lib/rustlib/$RUST_TRIPLET", + "*:*:@$RUST_STD_PROFILE $NATIVEPREFIX/bin/cp -a build/*/stage1/lib/rustlib/$RUST_TRIPLET $STAGING_DIR$NATIVEPREFIX/lib/rustlib/", + "*:*:@$RUST_STD_PROFILE test \"$BUILD_TRIPLET\" = \"$RUST_TRIPLET\" || $NATIVEPREFIX/bin/cp -a $NATIVEPREFIX/lib/rustlib/$BUILD_TRIPLET $STAGING_DIR$NATIVEPREFIX/lib/rustlib/" + ] + } +} \ No newline at end of file diff --git a/packages/sodium.json b/packages/sodium.json index d112520..2c4ff65 100644 --- a/packages/sodium.json +++ b/packages/sodium.json @@ -1,37 +1,51 @@ { "package": "sodium", - "version": "1.0.18", + "version": "1.0.22", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "6f504490b342a4f8a4c4a02fc9b866cbef8622d5df4e5452b46be121e46636c1", - "url": "http://download.libsodium.org/libsodium/releases/libsodium-1.0.18.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "adbdd8f16149e81ac6078a03aca6fc03b592b89ef7b5ed83841c086191be3349", + "url": "http://download.libsodium.org/libsodium/releases/libsodium-1.0.22.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/config" + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/config", + "*:*:native/coreutils", + "*:*:native/findutils", + "*:*:native/gawk", + "*:*:native/grep", + "*:*:native/libtool", + "*:*:native/make", + "*:*:native/m4", + "*:*:native/patch", + "*:*:native/perl", + "*:*:native/sed" ], "patches": [ "disable-glibc-getrandom-getentropy.patch", + "disable-simd-without-asm.patch", "fix-whitespace.patch" ], "build": { "env": [ - "*-android*:ANDROID_NDK_ROOT=$PREFIX/native", - "*-android*:CC=clang", - "*-android*:AR=ar", - "*-android*:RANLIB=ranlib", - "all:config_opts=--host=$HOST --prefix=$PREFIX", - "all:config_opts=$config_opts --enable-static --disable-shared --with-pic" + "*:aarch64-apple-ios-simulator:HOST=aarch64-apple-ios", + "*:*:config_opts=--host=$HOST --prefix=$PREFIX", + "*:*:config_opts=$config_opts --enable-static --disable-shared --disable-asm --with-pic" ], "steps": [ - "all:cp -f $PREFIX/native/usr/share/config/config.guess build-aux/", - "all:cp -f $PREFIX/native/usr/share/config/config.sub build-aux/", - "all:patch -p1 < $PATCH_DIR/sodium/disable-glibc-getrandom-getentropy.patch", - "all:patch -p1 < $PATCH_DIR/sodium/fix-whitespace.patch", - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess build-aux/", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub build-aux/", + "*:*:patch -p1 < $PATCH_DIR/sodium/disable-glibc-getrandom-getentropy.patch", + "*:*:patch -p1 < $PATCH_DIR/sodium/disable-simd-without-asm.patch", + "*:*:autoreconf --force --install", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/sqlite3@3510100.json b/packages/sqlite3@3510100.json new file mode 100644 index 0000000..bea4117 --- /dev/null +++ b/packages/sqlite3@3510100.json @@ -0,0 +1,30 @@ +{ + "package": "sqlite3@3510100", + "version": "3510100", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "4f2445cd70479724d32ad015ec7fd37fbb6f6130013bd4bfbc80c32beb42b7e0", + "url": "https://www.sqlite.org/2025/sqlite-autoconf-3510100.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/make" + ], + "build": { + "env": [ + "*:*:CFLAGS=$CFLAGS -O2 -DSQLITE_ENABLE_COLUMN_METADATA -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_JSON1 -DSQLITE_ENABLE_RTREE -DSQLITE_THREADSAFE=1", + "*:*:CPPFLAGS=$CPPFLAGS -I$PREFIX/include", + "*:*:LDFLAGS=$LDFLAGS -L$PREFIX/lib", + "*:*:config_opts=--disable-shared --enable-static --enable-threadsafe --prefix=$PREFIX --host=$HOST", + "*:*android*:CXXFLAGS=$CXXFLAGS -D_GNU_SOURCE" + ], + "steps": [ + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES libsqlite3.a", + "*:*:make DESTDIR=$STAGING_DIR install-lib install-pc install-headers" + ] + } +} \ No newline at end of file diff --git a/packages/stb.json b/packages/stb.json new file mode 100644 index 0000000..994b023 --- /dev/null +++ b/packages/stb.json @@ -0,0 +1,23 @@ +{ + "package": "stb", + "version": "013ac3beddff", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "013ac3beddff3dbffafd5177e7972067cd2b5083", + "url": "https://github.com/nothings/stb.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/coreutils" + ], + "build": { + "env": [], + "steps": [ + "*:*:mkdir -p $STAGING_DIR$PREFIX/include", + "*:*:cp stb_image.h $STAGING_DIR$PREFIX/include/stb_image.h" + ] + } +} \ No newline at end of file diff --git a/packages/tor.json b/packages/tor.json new file mode 100644 index 0000000..623b59b --- /dev/null +++ b/packages/tor.json @@ -0,0 +1,68 @@ +{ + "package": "tor", + "version": "tor-0.4.9.8", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "e170cdcfebd45f6d098e3d811e2b1e1d120df184", + "url": "http://gitlab.torproject.org/tpo/core/tor.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/findutils", + "*:*:native/gawk", + "*:*:native/grep", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/sed", + "*:*:libevent", + "*:*:openssl", + "*:*:xz", + "*:*:zlib", + "*:*:zstd" + ], + "build": { + "env": [ + "*:aarch64-apple-ios-simulator:HOST=aarch64-apple-ios", + "*:*:config_opts=--host=$HOST --prefix=$PREFIX", + "*:*:config_opts=$config_opts --disable-asciidoc", + "*:*:config_opts=$config_opts --disable-system-torrc", + "*:*:config_opts=$config_opts --disable-manpage", + "*:*:config_opts=$config_opts --disable-html-manual", + "*:*:config_opts=$config_opts --disable-tool-name-check", + "*:*-linux-android*:config_opts=$config_opts --enable-android", + "*:*-linux-android*:config_opts=$config_opts ac_cv_member_struct_tcp_info_tcpi_snd_mss=no", + "*:*:config_opts=$config_opts --enable-pic", + "*:*:config_opts=$config_opts --enable-static-openssl", + "*:*:config_opts=$config_opts --enable-static-libevent", + "*:*:config_opts=$config_opts --enable-static-zlib", + "*:*:config_opts=$config_opts --enable-static-tor", + "*:*:config_opts=$config_opts --disable-lzma", + "*:*:config_opts=$config_opts --disable-zstd", + "*:*:config_opts=$config_opts --disable-systemd", + "*:*:config_opts=$config_opts --with-openssl-dir=$PREFIX/lib", + "*:*:config_opts=$config_opts --with-libevent-dir=$PREFIX/lib", + "*:*:config_opts=$config_opts --with-zlib-dir=$PREFIX/lib", + "*:*:config_opts=$config_opts tor_cv_library_libevent_dir=$PREFIX" + ], + "steps": [ + "*:*:./autogen.sh", + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES libtor.a", + "*:*:mkdir -p $STAGING_DIR$PREFIX/lib", + "*:*:cp libtor.a $STAGING_DIR$PREFIX/lib/libtor.a", + "*:*:mkdir -p $STAGING_DIR$PREFIX/share/tor", + "*:*:cp src/config/geoip $STAGING_DIR$PREFIX/share/tor", + "*:*:cp src/config/geoip6 $STAGING_DIR$PREFIX/share/tor", + "*:*:mkdir -p $STAGING_DIR$PREFIX/include/tor", + "*:*:cd src && find . -name '*.h' -exec bash -c 'mkdir -p \"$STAGING_DIR$PREFIX/include/tor/$(dirname \"$1\")\" && cp \"$1\" \"$STAGING_DIR$PREFIX/include/tor/$1\"' _ {} \\;" + ] + } +} \ No newline at end of file diff --git a/packages/torch.json b/packages/torch.json index 460b1e6..1653f25 100644 --- a/packages/torch.json +++ b/packages/torch.json @@ -2,34 +2,37 @@ "package": "torch", "version": "tor-0.4.8.17", "type": "host", - "download": { - "kind": "git", - "sha256": "b7a785a538a31ab0cf5baf62d936e3e41182e0b7", - "url": "https://github.com/MrCyjaneK/torch.git" - }, + "download": [ + { + "kind": "git", + "sha256": "b7a785a538a31ab0cf5baf62d936e3e41182e0b7", + "url": "https://github.com/MrCyjaneK/torch.git" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/cmake", - "all:native/cmake-toolchain", - "all:native/make", - "all:libevent", - "all:libtor", - "all:openssl", - "all:xz", - "all:zlib", - "all:zstd" + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/coreutils", + "*:*:native/make", + "*:*:libevent", + "*:*:openssl", + "*:*:tor", + "*:*:xz", + "*:*:zlib", + "*:*:zstd" ], "build": { "env": [ - "all:config_opts=-DCMAKE_TOOLCHAIN_FILE=$PREFIX/native/toolchain.cmake", - "all:config_opts=$config_opts -DTOR_BUILD_DIR=$PREFIX", - "all:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX" + "*:*:config_opts=-DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DTOR_BUILD_DIR=$PREFIX", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX" ], "steps": [ - "all:mkdir build", - "all:cd build && cmake .. $config_opts", - "all:cd build && make -j$NUM_CORES", - "all:cd build && make install DESTDIR=$STAGING_DIR" + "*:*:mkdir build", + "*:*:cd build && cmake .. $config_opts", + "*:*:cd build && make -j$NUM_CORES", + "*:*:cd build && make install DESTDIR=$STAGING_DIR" ] } } \ No newline at end of file diff --git a/packages/unbound.json b/packages/unbound.json index 04671eb..86a2b7a 100644 --- a/packages/unbound.json +++ b/packages/unbound.json @@ -2,43 +2,52 @@ "package": "unbound", "version": "1.23.0", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "959bd5f3875316d7b3f67ee237a56de5565f5b35fc9b5fc3cea6cfe735a03bb8", - "url": "http://www.nlnetlabs.nl/downloads/unbound/unbound-1.23.0.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "959bd5f3875316d7b3f67ee237a56de5565f5b35fc9b5fc3cea6cfe735a03bb8", + "url": "http://www.nlnetlabs.nl/downloads/unbound/unbound-1.23.0.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/autoconf", - "all:native/m4", - "all:native/perl", - "all:expat", - "all:openssl" + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/gawk", + "*:*:native/grep", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/patch", + "*:*:native/perl", + "*:*:native/sed", + "*:*:expat", + "*:*:openssl" ], "patches": [ "disable-glibc-reallocarray.patch" ], "build": { "env": [ - "all:BUILD_HOST=$HOST", - "aarch64-apple-ios-simulator:BUILD_HOST=aarch64-apple-ios", - "all:config_opts=--disable-shared --enable-static --without-pyunbound --prefix=$PREFIX --host=$BUILD_HOST", - "all:config_opts=$config_opts --with-libexpat=$PREFIX --with-ssl=$PREFIX --with-libevent=no", - "all:config_opts=$config_opts --without-pythonmodule --disable-flto --with-pthreads --with-libunbound-only", - "*-linux-*:config_opts=$config_opts --with-pic", - "*-w64-*:config_opts=$config_opts --enable-static-exe --sysconfdir=/etc --prefix=$PREFIX --target=$PREFIX", - "x86_64-apple-darwin:config_opts=$config_opts ac_cv_func_SHA384_Init=yes", - "*-linux-android*:config_opts=$config_opts ac_cv_type_pthread_spinlock_t=no", - "*-w64-mingw32:build_opts=$build_opts LDFLAGS=\"$LDFLAGS -lpthread\"", - "*-w64-mingw32:CFLAGS=$CFLAGS -D_WIN32_WINNT=0x600", - "all:config_opts=$config_opts ac_cv_func_getentropy=no" + "*:aarch64-apple-ios-simulator:HOST=aarch64-apple-ios", + "*:*:config_opts=--disable-shared --enable-static --without-pyunbound --prefix=$PREFIX --host=$HOST", + "*:*:config_opts=$config_opts --with-libexpat=$PREFIX --with-ssl=$PREFIX --with-libevent=no", + "*:*:config_opts=$config_opts --without-pythonmodule --disable-flto --with-pthreads --with-libunbound-only", + "*:*-linux-*:config_opts=$config_opts --with-pic", + "*:*-w64-*:config_opts=$config_opts --enable-static-exe --sysconfdir=/etc --prefix=$PREFIX --target=$PREFIX", + "*:*-w64-*:config_opts=$config_opts --with-conf-file=$PREFIX/etc/unbound/unbound.conf --with-run-dir=$PREFIX/var/lib/unbound --with-rootkey-file=$PREFIX/etc/unbound/root.key --with-rootcert-file=$PREFIX/etc/unbound/icannbundle.pem", + "*:x86_64-apple-darwin:config_opts=$config_opts ac_cv_func_SHA384_Init=yes", + "*:*-linux-android*:config_opts=$config_opts ac_cv_type_pthread_spinlock_t=no", + "*:*:config_opts=$config_opts ac_cv_func_getentropy=no" ], "steps": [ - "all:patch -p1 < $PATCH_DIR/unbound/disable-glibc-reallocarray.patch", - "all:autoconf", - "all:./configure $config_opts", - "all:make -j$NUM_CORES $build_opts", - "all:make -j$NUM_CORES DESTDIR=$STAGING_DIR install" + "*:*:patch -p1 < $PATCH_DIR/unbound/disable-glibc-reallocarray.patch", + "*:*:autoconf", + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES $build_opts V=1", + "*:*:make -j1 DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/unistring.json b/packages/unistring.json new file mode 100644 index 0000000..d0797f1 --- /dev/null +++ b/packages/unistring.json @@ -0,0 +1,30 @@ +{ + "package": "unistring", + "version": "1.4.1", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "12542ad7619470efd95a623174dcd4b364f2483caf708c6bee837cb53a54cb9d", + "url": "http://ftpmirror.gnu.org/gnu/libunistring/libunistring-1.4.1.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/make", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:config_opts=--prefix=$PREFIX", + "*:*:config_opts=$config_opts --host=$HOST", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static" + ], + "steps": [ + "*:*:./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/unwind.json b/packages/unwind.json index b22a0a5..1279f7e 100644 --- a/packages/unwind.json +++ b/packages/unwind.json @@ -2,32 +2,33 @@ "package": "unwind", "version": "1.5.0", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "90337653d92d4a13de590781371c604f9031cdb50520366aa1e3a91e1efb1017", - "url": "http://download.savannah.nongnu.org/releases/libunwind/libunwind-1.5.0.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "90337653d92d4a13de590781371c604f9031cdb50520366aa1e3a91e1efb1017", + "url": "http://download.savannah.nongnu.org/releases/libunwind/libunwind-1.5.0.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/config", - "all:native/gettext" + "*:*:native/_", + "*:*:native/config", + "*:*:native/gettext" ], "patches": [ "fix_obj_order.patch" ], "build": { "env": [ - "*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX", - "*-linux-gnu:config_opts=$config_opts --disable-shared --enable-static --disable-tests --disable-documentation", - "*-linux-gnu:AR_FLAGS=$ARFLAGS" + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX", + "*:*-linux-gnu:config_opts=$config_opts --disable-shared --enable-static --disable-tests --disable-documentation" ], "steps": [ - "all:cp -f $PREFIX/native/usr/share/config/config.guess config/config.guess", - "all:cp -f $PREFIX/native/usr/share/config/config.sub config/config.sub", - "*-linux-gnu:patch -p0 < $PATCH_DIR/unwind/fix_obj_order.patch", - "*-linux-gnu:./configure $config_opts", - "*-linux-gnu:make -j$NUM_CORES", - "*-linux-gnu:make -j$NUM_CORES DESTDIR=$STAGING_DIR install" + "*:*:cp -f $NATIVEPREFIX/share/config/config.guess config/config.guess", + "*:*:cp -f $NATIVEPREFIX/share/config/config.sub config/config.sub", + "*:*-linux-gnu:patch -p0 < $PATCH_DIR/unwind/fix_obj_order.patch", + "*:*-linux-gnu:./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make -j$NUM_CORES DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/wayland@1_25_0.json b/packages/wayland@1_25_0.json new file mode 100644 index 0000000..afc528d --- /dev/null +++ b/packages/wayland@1_25_0.json @@ -0,0 +1,41 @@ +{ + "package": "wayland@1_25_0", + "version": "1_25_0", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "95413723f6cd0462770eda207a1c78d142d0a1bba9b0572a4ed1da6a9b27059c", + "url": "https://gitlab.freedesktop.org/wayland/wayland/-/archive/1.25.0/wayland-1.25.0.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/meson", + "*:*-linux-gnu:native/ninja", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/python@3.11", + "*:*-linux-gnu:native/wayland@1_25_0", + "*:*-linux-gnu:expat", + "*:*-linux-gnu:libffi@3_5_2", + "*:*-linux-gnu:native/sed" + ], + "patches": [ + "toolchain.txt" + ], + "build": { + "env": [], + "steps": [ + "*:*-linux-gnu:cp $PATCH_DIR/wayland/toolchain.txt toolchain.txt", + "*:*-linux-gnu:sed -i -e \"s|@host_prefix@|$PREFIX|\" -e \"s|@cc@|$CC|\" -e \"s|@cxx@|$CXX|\" -e \"s|@ar@|$AR|\" -e \"s|@strip@|$STRIP|\" -e \"s|@arch@|$ARCH|\" toolchain.txt", + "*:*-linux-gnu:$NATIVEPREFIX/bin/meson setup --cross-file toolchain.txt build -Ddtd_validation=false -Ddocumentation=false -Dprefer_static=true -Ddefault_library=static -Dtests=false -Dscanner=false", + "*:*-linux-gnu:ninja -C build", + "*:*-linux-gnu:DESTDIR=$STAGING_DIR ninja -C build install" + ] + } +} \ No newline at end of file diff --git a/packages/whisper-cpp.json b/packages/whisper-cpp.json new file mode 100644 index 0000000..427f8b0 --- /dev/null +++ b/packages/whisper-cpp.json @@ -0,0 +1,55 @@ +{ + "package": "whisper-cpp", + "version": "v1.9.2", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "306c88f4d1286aec1bf96e544632897886af5501", + "url": "https://github.com/ggml-org/whisper.cpp.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/make", + "*:*:native/coreutils", + "*:*:native/bash", + "*:*:ffmpeg" + ], + "build": { + "env": [ + "*:*:config_opts=-DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", + "*:*:config_opts=$config_opts -DCMAKE_BUILD_TYPE=Release", + "*:*:config_opts=$config_opts -DBUILD_SHARED_LIBS=OFF", + "*:*:config_opts=$config_opts -DGGML_NATIVE=OFF", + "*:*:config_opts=$config_opts -DGGML_OPENMP=OFF", + "*:*:config_opts=$config_opts -DGGML_METAL=OFF", + "*:*:config_opts=$config_opts -DGGML_BLAS=OFF", + "*:*:config_opts=$config_opts -DGGML_ACCELERATE=OFF", + "*:*:config_opts=$config_opts -DGGML_CCACHE=OFF", + "*:*:config_opts=$config_opts -DWHISPER_BUILD_TESTS=OFF", + "*:*:config_opts=$config_opts -DWHISPER_BUILD_EXAMPLES=OFF", + "*:*:config_opts=$config_opts -DWHISPER_BUILD_SERVER=OFF", + "*:*:config_opts=$config_opts -DWHISPER_CURL=OFF", + "*:*:config_opts=$config_opts -DWHISPER_SDL2=OFF", + "*:*:config_opts=$config_opts -DWHISPER_COREML=OFF", + "*:*-apple-ios*:config_opts=$config_opts -DCMAKE_MACOSX_BUNDLE=OFF", + "*:*-apple-ios*:config_opts=$config_opts -DCMAKE_OSX_DEPLOYMENT_TARGET=14.0", + "*:*-apple-ios*:config_opts=$config_opts -DCMAKE_OSX_ARCHITECTURES=arm64", + "*:aarch64-apple-ios:IOS_MIN_VERSION=14.0", + "*:aarch64-apple-ios-simulator:IOS_MIN_VERSION=14.0", + "*:aarch64-apple-ios:CC=$NATIVEPREFIX/bin/aarch64-apple-ios-clang -target aarch64-apple-ios -mios-version-min=14.0 -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios:CXX=$NATIVEPREFIX/bin/aarch64-apple-ios-clang++ -target aarch64-apple-ios -mios-version-min=14.0 -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios-simulator:CC=$NATIVEPREFIX/bin/aarch64-apple-ios-simulator-clang -target aarch64-apple-ios-simulator -mios-version-min=14.0 -isysroot $SDK_PATH -I$PREFIX/include", + "*:aarch64-apple-ios-simulator:CXX=$NATIVEPREFIX/bin/aarch64-apple-ios-simulator-clang++ -target aarch64-apple-ios-simulator -mios-version-min=14.0 -isysroot $SDK_PATH -I$PREFIX/include" + ], + "steps": [ + "*:*:cmake -S . -B build $config_opts", + "*:*:cmake --build build -j$NUM_CORES", + "*:*:cd build && make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/xcb_proto@1_17_0.json b/packages/xcb_proto@1_17_0.json new file mode 100644 index 0000000..b27a0cb --- /dev/null +++ b/packages/xcb_proto@1_17_0.json @@ -0,0 +1,35 @@ +{ + "package": "xcb_proto@1_17_0", + "version": "1_17_0", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "392d3c9690f8c8202a68fdb89c16fd55159ab8d65000a6da213f4a1576e97a16", + "url": "https://xorg.freedesktop.org/archive/individual/proto/xcb-proto-1.17.0.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/python@3.14", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX" + ], + "steps": [ + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install", + "*:*-linux-gnu:rm -rf $STAGING_DIR$PREFIX/lib/python*/site-packages/xcbgen/__pycache__" + ] + } +} \ No newline at end of file diff --git a/packages/xorgproto@2025_1.json b/packages/xorgproto@2025_1.json new file mode 100644 index 0000000..e71d51c --- /dev/null +++ b/packages/xorgproto@2025_1.json @@ -0,0 +1,33 @@ +{ + "package": "xorgproto@2025_1", + "version": "2025_1", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "d6f89f65bafb8c9b735e0515882b8a1511e8e864dde5e9513e191629369f2256", + "url": "https://xorg.freedesktop.org/archive/individual/proto/xorgproto-2025.1.tar.gz" + } + ], + "dependencies": [ + "*:*-linux-gnu:native/_", + "*:*-linux-gnu:native/bash", + "*:*-linux-gnu:native/coreutils", + "*:*-linux-gnu:native/findutils", + "*:*-linux-gnu:native/gawk", + "*:*-linux-gnu:native/grep", + "*:*-linux-gnu:native/make", + "*:*-linux-gnu:native/pkgconf", + "*:*-linux-gnu:native/sed" + ], + "build": { + "env": [ + "*:*-linux-gnu:config_opts=--host=$HOST --prefix=$PREFIX --without-fop --without-xmlto --without-xsltproc --disable-specs --disable-dependency-tracking --enable-option-checking" + ], + "steps": [ + "*:*-linux-gnu:bash ./configure $config_opts", + "*:*-linux-gnu:make -j$NUM_CORES", + "*:*-linux-gnu:make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/xxhash.json b/packages/xxhash.json new file mode 100644 index 0000000..58a4413 --- /dev/null +++ b/packages/xxhash.json @@ -0,0 +1,29 @@ +{ + "package": "xxhash", + "version": "v0.8.3-dev", + "type": "host", + "download": [ + { + "kind": "git", + "sha256": "66979328cf3f15cecdc61ea58c9f81e6071f8983", + "url": "https://github.com/Cyan4973/xxHash.git" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/make" + ], + "build": { + "env": [ + "*:*:config_opts=-DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX" + ], + "steps": [ + "*:*:cmake -S build/cmake -B cmake_build $config_opts", + "*:*:cd cmake_build && make -j$NUM_CORES", + "*:*:cd cmake_build && make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/packages/xz.json b/packages/xz.json index fd6afe8..e2ad5a9 100644 --- a/packages/xz.json +++ b/packages/xz.json @@ -2,46 +2,50 @@ "package": "xz", "version": "5.8.1", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "507825b599356c10dca1cd720c9d0d0c9d5400b9de300af00e4d1ea150795543", - "url": "http://github.com/tukaani-project/xz/releases/download/v5.8.1/xz-5.8.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "507825b599356c10dca1cd720c9d0d0c9d5400b9de300af00e4d1ea150795543", + "url": "http://github.com/tukaani-project/xz/releases/download/v5.8.1/xz-5.8.1.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/autoconf", - "all:native/automake", - "all:native/gettext", - "all:native/libtool", - "all:native/m4", - "all:native/make", - "all:native/perl" + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/diffutils", + "*:*:native/findutils", + "*:*:native/gawk", + "*:*:native/gettext", + "*:*:native/grep", + "*:*:native/gzip", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/perl", + "*:*:native/sed", + "*:*:native/tar" ], "patches": [ "fix_declaration.patch" ], "build": { "env": [ - "all:HOSTOVERRIDE=$HOST", - "aarch64-apple-ios-simulator:HOSTOVERRIDE=aarch64-apple-ios", - "all:config_opts=--prefix=$PREFIX --host=$HOSTOVERRIDE", - "all:config_opts=$config_opts --disable-shared", - "all:config_opts=$config_opts --enable-static", - "all:config_opts=$config_opts --disable-doc", - "all:config_opts=$config_opts --disable-scripts", - "all:config_opts=$config_opts --disable-xz", - "all:config_opts=$config_opts --disable-xzdec", - "all:config_opts=$config_opts --disable-lzmadec", - "all:config_opts=$config_opts --disable-lzmainfo", - "all:config_opts=$config_opts --disable-lzma-links" + "*:aarch64-apple-ios-simulator:HOST=aarch64-apple-ios", + "*:*:config_opts=--prefix=$PREFIX --host=$HOST", + "*:*:config_opts=$config_opts --disable-shared", + "*:*:config_opts=$config_opts --enable-static", + "*:*:config_opts=$config_opts --disable-doc", + "*:*:SKIP_WERROR_CHECK=yes" ], "steps": [ - "all:pwd", - "all:./autogen.sh --no-po4a", - "all:./configure $config_opts", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install", - "all:rm $STAGING_DIR$PREFIX/lib/*.la" + "*:*:bash ./autogen.sh --no-po4a", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install", + "*:*:rm $STAGING_DIR$PREFIX/lib/*.la" ] } } \ No newline at end of file diff --git a/packages/zeromq.json b/packages/zeromq.json index c2df2aa..2910b03 100644 --- a/packages/zeromq.json +++ b/packages/zeromq.json @@ -2,31 +2,55 @@ "package": "zeromq", "version": "4.3.5", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "6653ef5910f17954861fe72332e68b03ca6e4d9c7160eb3a8de5a5a913bfab43", - "url": "http://github.com/zeromq/libzmq/releases/download/v4.3.5/zeromq-4.3.5.tar.gz" - }, + "download": [ + { + "kind": "git", + "sha256": "b946c18f676760387276cd095bbdd8c0e18c09bf", + "url": "http://github.com/zeromq/libzmq.git" + } + ], "dependencies": [ - "*-android*:native/android_ndk" + "*:*:native/_", + "*:*:native/autoconf", + "*:*:native/automake", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/gawk", + "*:*:native/gettext", + "*:*:native/grep", + "*:*:native/libtool", + "*:*:native/m4", + "*:*:native/make", + "*:*:native/patch", + "*:*:native/perl", + "*:*:native/pkgconf", + "*:*:native/sed" ], "patches": [ "fix_declaration.patch" ], "build": { "env": [ - "aarch64-apple-ios*:HOST=aarch64-apple-darwin", - "all:config_opts=--prefix=$PREFIX --host=$HOST --without-documentation --disable-shared --without-libsodium --disable-curve", - "*-linux-gnu:config_opts=$config_opts --with-pic", - "all:cxxflags=-std=c++11" + "*:aarch64-apple-ios*:HOST=aarch64-apple-darwin", + "*:*:config_opts=--prefix=$PREFIX --host=$HOST --without-documentation --disable-shared --without-libsodium --disable-curve --disable-libbsd", + "*:*-w64-mingw32:config_opts=$config_opts --disable-pedantic --disable-Werror", + "*:*-linux-gnu:config_opts=$config_opts --with-pic", + "*:*:cxxflags=$CXXFLAGS -std=c++17", + "*:*:SED=$NATIVEPREFIX/bin/sed", + "*:*:GREP=$NATIVEPREFIX/bin/grep", + "*:*:PKG_CONFIG=$NATIVEPREFIX/bin/pkgconf" ], "steps": [ - "all:patch -p1 < $PATCH_DIR/zeromq/fix_declaration.patch", - "all:./configure $config_opts", - "all:make -j$NUM_CORES src/libzmq.la", - "all:make -j$NUM_CORES DESTDIR=$STAGING_DIR install-pkgconfigDATA VERBOSE=1", - "all:make -j$NUM_CORES DESTDIR=$STAGING_DIR install-libLTLIBRARIES VERBOSE=1", - "all:make -j$NUM_CORES DESTDIR=$STAGING_DIR install-includeHEADERS VERBOSE=1" + "*:*:mkdir -p config", + "*:*:libtoolize --copy --force", + "*:*:test -f config/ltmain.sh || cp -f ltmain.sh config/ltmain.sh", + "*:*:bash ./autogen.sh", + "*:*:patch -p1 < $PATCH_DIR/zeromq/fix_declaration.patch", + "*:*:bash ./configure $config_opts", + "*:*:make -j$NUM_CORES src/libzmq.la", + "*:*:make -j1 DESTDIR=$STAGING_DIR install-pkgconfigDATA VERBOSE=1", + "*:*:make -j1 DESTDIR=$STAGING_DIR install-libLTLIBRARIES VERBOSE=1", + "*:*:make -j1 DESTDIR=$STAGING_DIR install-includeHEADERS VERBOSE=1" ] } } \ No newline at end of file diff --git a/packages/zlib.json b/packages/zlib.json index 2f67972..b218c4c 100644 --- a/packages/zlib.json +++ b/packages/zlib.json @@ -2,28 +2,38 @@ "package": "zlib", "version": "1.3.1", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23", - "url": "http://www.zlib.net/zlib-1.3.1.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23", + "url": "https://github.com/madler/zlib/releases/download/v1.3.1/zlib-1.3.1.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/libtool", - "all:native/make" + "*:*:native/_", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/grep", + "*:*:native/libtool", + "*:*:native/make", + "*:*:native/sed" ], "build": { "env": [ - "all:CFLAGS=$CFLAGS -fPIC", - "all:config_opts=--prefix=$PREFIX --static", - "all:CROSS_PREFIX=$HOST-" + "*:*:CFLAGS=$CFLAGS -fPIC", + "*:*:config_opts=--prefix=$PREFIX --static", + "*:*:CROSS_PREFIX=$HOST-" ], "steps": [ - "all:./configure $config_opts", - "*-android*:sed -i.bak s/^AR=.\\*$/AR=\"llvm-ar\"/ Makefile", - "*-android*:sed -i.bak s/^ARFLAGS=.\\*$/ARFLAGS=\"rcs\"/ Makefile", - "all:make -j$NUM_CORES", - "all:make DESTDIR=$STAGING_DIR install" + "*:*:bash ./configure $config_opts", + "*:*-android*:sed -i.bak s\\|^AR=.\\*$\\|AR=\"llvm-ar\"\\| Makefile", + "*:*-android*:sed -i.bak s\\|^ARFLAGS=.\\*$\\|ARFLAGS=\"rcs\"\\| Makefile", + "*:*-linux-gnu:sed -i.bak s\\|^AR=.\\*$\\|AR=\"$AR\"\\| Makefile", + "*:*-linux-gnu:sed -i.bak s\\|^ARFLAGS=.\\*$\\|ARFLAGS=\"rcs\"\\| Makefile", + "*:*-w64-*:sed -i.bak s\\|^AR=.\\*$\\|AR=\"$AR\"\\| Makefile", + "*:*-w64-*:sed -i.bak s\\|^ARFLAGS=.\\*$\\|ARFLAGS=\"rcs\"\\| Makefile", + "*:*:make -j$NUM_CORES", + "*:*:make DESTDIR=$STAGING_DIR install" ] } } \ No newline at end of file diff --git a/packages/zstd.json b/packages/zstd.json index bb19b29..62a08a9 100644 --- a/packages/zstd.json +++ b/packages/zstd.json @@ -2,25 +2,36 @@ "package": "zstd", "version": "1.5.7", "type": "host", - "download": { - "kind": "tar.gz", - "sha256": "eb33e51f49a15e023950cd7825ca74a4a2b43db8354825ac24fc1b7ee09e6fa3", - "url": "http://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz" - }, + "download": [ + { + "kind": "tar.gz", + "sha256": "eb33e51f49a15e023950cd7825ca74a4a2b43db8354825ac24fc1b7ee09e6fa3", + "url": "http://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz" + } + ], "dependencies": [ - "*-android*:native/android_ndk", - "all:native/make" + "*:*:native/_", + "*:*:native/bash", + "*:*:native/coreutils", + "*:*:native/grep", + "*:*:native/make", + "*:*:native/sed" ], "build": { "env": [ - "all:LIBTOOL=$PREFIX/native/bin/libtool", - "armv7a-linux-androideabi:CFLAGS=$CFLAGS -DLIBC_NO_FSEEKO", - "armv7a-linux-androideabi:CXXFLAGS=$CXXFLAGS -DLIBC_NO_FSEEKO" + "*:*:LIBTOOL=$NATIVEPREFIX/bin/libtool", + "*:armv7a-linux-androideabi:CFLAGS=$CFLAGS -DLIBC_NO_FSEEKO", + "*:armv7a-linux-androideabi:CXXFLAGS=$CXXFLAGS -DLIBC_NO_FSEEKO", + "*:*-linux-*:TARGET_SYSTEM=Linux", + "*:*-apple-*:TARGET_SYSTEM=Darwin", + "*:*-mingw32:TARGET_SYSTEM=Windows", + "*:*:UNAME_TARGET_SYSTEM=$TARGET_SYSTEM", + "*:*:OS=$TARGET_SYSTEM" ], "steps": [ - "all:make -j$NUM_CORES", - "all:mkdir -p $STAGING_DIR$PREFIX/lib", - "all:cp ./lib/libzstd.a $STAGING_DIR$PREFIX/lib/libzstd.a" + "*:*:make -j$NUM_CORES", + "*:*:mkdir -p $STAGING_DIR$PREFIX/lib", + "*:*:cp ./lib/libzstd.a $STAGING_DIR$PREFIX/lib/libzstd.a" ] } } \ No newline at end of file diff --git a/packages/zxing-cpp.json b/packages/zxing-cpp.json new file mode 100644 index 0000000..ea2e0e9 --- /dev/null +++ b/packages/zxing-cpp.json @@ -0,0 +1,41 @@ +{ + "package": "zxing-cpp", + "version": "2.3.0", + "type": "host", + "download": [ + { + "kind": "tar.gz", + "sha256": "64e4139103fdbc57752698ee15b5f0b0f7af9a0331ecbdc492047e0772c417ba", + "url": "https://github.com/zxing-cpp/zxing-cpp/archive/refs/tags/v2.3.0.tar.gz" + } + ], + "dependencies": [ + "*:*:native/_", + "*:*:native/cmake", + "*:*:native/cmake-toolchain", + "*:*:native/make", + "*:*:native/coreutils", + "*:*:native/sed" + ], + "build": { + "env": [ + "*:*:config_opts=-DCMAKE_TOOLCHAIN_FILE=$CMAKE_TOOLCHAIN_FILE", + "*:*:config_opts=$config_opts -DCMAKE_INSTALL_PREFIX=$PREFIX", + "*:*:config_opts=$config_opts -DCMAKE_BUILD_TYPE=Release", + "*:*:config_opts=$config_opts -DBUILD_SHARED_LIBS=OFF", + "*:*:config_opts=$config_opts -DZXING_EXAMPLES=OFF", + "*:*:config_opts=$config_opts -DZXING_C_API=OFF", + "*:*:config_opts=$config_opts -DZXING_WRITERS=OFF", + "*:*:config_opts=$config_opts -DZXING_READERS=ON", + "*:*:config_opts=$config_opts -DZXING_UNIT_TESTS=OFF", + "*:*:config_opts=$config_opts -DZXING_BLACKBOX_TESTS=OFF", + "*:*:config_opts=$config_opts -DZXING_DEPENDENCIES=LOCAL" + ], + "steps": [ + "*:*:sed -i 's/-Werror=undef/-Wno-error=undef/g' core/CMakeLists.txt", + "*:*:cmake -S . -B build $config_opts", + "*:*:cmake --build build -j$NUM_CORES", + "*:*:cd build && make DESTDIR=$STAGING_DIR install" + ] + } +} \ No newline at end of file diff --git a/patches/android_ndk/symlink_same.py b/patches/android_ndk/symlink_same.py new file mode 100644 index 0000000..2a7e822 --- /dev/null +++ b/patches/android_ndk/symlink_same.py @@ -0,0 +1,63 @@ +#!/usr/bin/env python3 +import os +import hashlib + +def sha256sum(path, blocksize=65536): + """Return SHA-256 checksum of a file.""" + h = hashlib.sha256() + with open(path, "rb") as f: + while True: + data = f.read(blocksize) + if not data: + break + h.update(data) + return h.hexdigest() + +def dedupe(root): + seen = {} + + for dirpath, dirnames, filenames in os.walk(root): + for name in filenames: + path = os.path.join(dirpath, name) + + if os.path.islink(path): + continue + + if not os.path.isfile(path): + continue + + try: + checksum = sha256sum(path) + except Exception as e: + print(f"Cannot read {path}: {e}") + continue + + if checksum not in seen: + seen[checksum] = path + print(f"[KEEP] {path}") + else: + original = seen[checksum] + print(f"[DUPLICATE] {path} → symlink to {original}") + + try: + os.remove(path) + except Exception as e: + print(f"Cannot delete {path}: {e}") + continue + + try: + os.symlink(os.path.relpath(original, os.path.dirname(path)), path) + except Exception as e: + print(f"Cannot create symlink at {path}: {e}") + +def main(): + import sys + if len(sys.argv) != 2: + print(f"Usage: {sys.argv[0]} ") + sys.exit(1) + + root = sys.argv[1] + dedupe(root) + +if __name__ == "__main__": + main() diff --git a/patches/dbus/remove-DDBUS_STATIC_BUILD.patch b/patches/dbus/remove-DDBUS_STATIC_BUILD.patch new file mode 100644 index 0000000..f873efd --- /dev/null +++ b/patches/dbus/remove-DDBUS_STATIC_BUILD.patch @@ -0,0 +1,10 @@ +diff --git a/dbus-1.pc.in b/dbus-1.pc.in +index 3581be6e..ef422589 100644 +--- a/dbus-1.pc.in ++++ b/dbus-1.pc.in +@@ -18,4 +18,4 @@ Description: Free desktop message bus + Version: @VERSION@ + Libs: -L${libdir} -ldbus-1 + Libs.private: @LIBDBUS_LIBS@ +-Cflags: -I${includedir}/dbus-1.0 -I${libdir}/dbus-1.0/include @DBUS_STATIC_BUILD_CPPFLAGS@ ++Cflags: -I${includedir}/dbus-1.0 -I${libdir}/dbus-1.0/include diff --git a/patches/fontconfig/gperf_header_regen.patch b/patches/fontconfig/gperf_header_regen.patch new file mode 100644 index 0000000..b1a70d5 --- /dev/null +++ b/patches/fontconfig/gperf_header_regen.patch @@ -0,0 +1,24 @@ +commit 7b6eb33ecd88768b28c67ce5d2d68a7eed5936b6 +Author: fanquake +Date: Tue Aug 25 14:34:53 2020 +0800 + + Remove rule that causes inadvertent header regeneration + + Otherwise the makefile will needlessly attempt to re-generate the + headers with gperf. This can be dropped once the upstream build is fixed. + + See #10851. + +diff --git a/src/Makefile.in b/src/Makefile.in +index f4626ad..4ae1b00 100644 +--- a/src/Makefile.in ++++ b/src/Makefile.in +@@ -912,7 +912,7 @@ + ' - > $@.tmp && \ + mv -f $@.tmp fcobjshash.gperf && touch $@ || ( $(RM) $@.tmp && false ) + +-fcobjshash.h: Makefile fcobjshash.gperf ++fcobjshash.h: + $(AM_V_GEN) $(GPERF) --pic -m 100 fcobjshash.gperf > $@.tmp && \ + mv -f $@.tmp $@ || ( $(RM) $@.tmp && false ) + diff --git a/patches/go_wrapper.sh b/patches/go_wrapper.sh new file mode 100644 index 0000000..a30b72c --- /dev/null +++ b/patches/go_wrapper.sh @@ -0,0 +1,12 @@ +#!/bin/bash +export GOCACHE=$HOME/.cache/go@GO_VERSION@-build +export GOMODCACHE=$HOME/go@GO_VERSION@/pkg/mod +export GOPATH=$HOME/go@GO_VERSION@ +export GOPROXY='https://proxy.golang.org,direct' +export GOROOT=$NATIVEPREFIX/go@GO_VERSION@ +export GOSUMDB='sum.golang.org' +export GOTELEMETRY='local' +export GOTELEMETRYDIR='/Users/user/Library/Application Support/go/telemetry' +export GOTOOLDIR=$GOROOT/pkg/tool/${BUILDER_GOOS}_${BUILDER_GOARCH} + +exec $NATIVEPREFIX/go@GO_VERSION@/bin/go $@ diff --git a/patches/libXau/toolchain.txt b/patches/libXau/toolchain.txt new file mode 100644 index 0000000..a01dc0d --- /dev/null +++ b/patches/libXau/toolchain.txt @@ -0,0 +1,17 @@ +[binaries] +c = '@cc@' +cpp = '@cxx@' +ar = '@ar@' +strip = '@strip@' +pkgconfig = 'pkg-config' + +[host_machine] +system = 'linux' +cpu_family = '@arch@' +cpu = '@arch@' +endian = 'little' + +[built-in options] +default_library = 'static' +prefer_static = true +prefix = '@host_prefix@' diff --git a/patches/libxcb/remove_pthread_stubs.patch b/patches/libxcb/remove_pthread_stubs.patch new file mode 100644 index 0000000..b948cdb --- /dev/null +++ b/patches/libxcb/remove_pthread_stubs.patch @@ -0,0 +1,14 @@ +Remove uneeded pthread-stubs dependency +diff --git a/configure b/configure +index 969e8ac..0ab13c7 100755 +--- a/configure ++++ b/configure +@@ -21483,7 +21483,7 @@ fi + NEEDED="xau >= 0.99.2" + case $host_os in + linux*|darwin*|solaris*|dragonfly*|freebsd*|netbsd*) ;; +- *) NEEDED="$NEEDED pthread-stubs" ;; ++ *) NEEDED="$NEEDED" ;; + esac + + pkg_failed=no diff --git a/patches/libxkbcommon/no-test-x11.patch b/patches/libxkbcommon/no-test-x11.patch new file mode 100644 index 0000000..8612ab0 --- /dev/null +++ b/patches/libxkbcommon/no-test-x11.patch @@ -0,0 +1,55 @@ +diff --git a/meson.build b/meson.build +index 92483c54..651f7a60 100644 +--- a/meson.build ++++ b/meson.build +@@ -1192,36 +1192,6 @@ test( + dependencies: test_dep), + env: test_env, + ) +-if get_option('enable-x11') +- has_xvfb = find_program('Xvfb', required: false) +- has_xkbcomp = find_program('xkbcomp', required: false) +- # We only warn because the build machine may not be the same +- # as the host/test machine. +- if not has_xvfb.found() +- warning('Xvfb program not found, but is required to run X11 tests.') +- endif +- if not has_xkbcomp.found() +- warning('xkbcomp program not found, but is required to run X11 tests.') +- endif +- test( +- 'x11', +- executable('test-x11', 'test/x11.c', dependencies: x11_xvfb_test_dep), +- env: test_env, +- is_parallel : false, +- ) +- test( +- 'x11comp', +- executable( +- 'test-x11comp', +- 'test/x11comp.c', +- 'test/utils-text.c', +- 'test/utils-text.h', +- dependencies: x11_xvfb_test_dep +- ), +- env: test_env, +- is_parallel : false, +- ) +-endif + if get_option('enable-xkbregistry') + test( + 'registry', +@@ -1365,13 +1335,6 @@ benchmark( + executable('bench-atom', 'bench/atom.c', dependencies: test_dep), + env: bench_env, + ) +-if get_option('enable-x11') +- benchmark( +- 'x11', +- executable('bench-x11', 'bench/x11.c', dependencies: x11_test_dep), +- env: bench_env, +- ) +-endif + + + # Documentation. diff --git a/patches/libxkbcommon/toolchain.txt b/patches/libxkbcommon/toolchain.txt new file mode 100644 index 0000000..e209e79 --- /dev/null +++ b/patches/libxkbcommon/toolchain.txt @@ -0,0 +1,21 @@ +[binaries] +c = '@cc@' +cpp = '@cxx@' +ar = '@ar@' +strip = '@strip@' +pkgconfig = 'pkg-config' + +[host_machine] +system = 'linux' +cpu_family = '@arch@' +cpu = '@arch@' +endian = 'little' + +[project options] +enable-xkbregistry = false +enable-docs = false +enable-tools = false + +[built-in options] +default_library = 'static' +prefix = '@host_prefix@' \ No newline at end of file diff --git a/patches/monero@fcmp-stage/447.patch b/patches/monero@fcmp-stage/447.patch new file mode 100644 index 0000000..b2bf9b5 --- /dev/null +++ b/patches/monero@fcmp-stage/447.patch @@ -0,0 +1,30 @@ +From 64178a58dc3f3cc4a6d686b37796231818d47a60 Mon Sep 17 00:00:00 2001 +From: Czarek Nakamoto +Date: Mon, 27 Jul 2026 14:15:44 +0200 +Subject: [PATCH] fix: use correct rust target for iOS and iOS simulator + +--- + src/fcmp_pp/fcmp_pp_rust/CMakeLists.txt | 10 +++++++++- + 1 file changed, 9 insertions(+), 1 deletion(-) + +diff --git a/src/fcmp_pp/fcmp_pp_rust/CMakeLists.txt b/src/fcmp_pp/fcmp_pp_rust/CMakeLists.txt +index 3e2229f07be..6479d631c4b 100644 +--- a/src/fcmp_pp/fcmp_pp_rust/CMakeLists.txt ++++ b/src/fcmp_pp/fcmp_pp_rust/CMakeLists.txt +@@ -44,7 +44,15 @@ if(MINGW) + set(RUST_PLATFORM "pc-windows") + set(RUST_TOOLCHAIN "-gnu") + elseif(APPLE) +- set(RUST_PLATFORM "apple-darwin") ++ if(CMAKE_SYSTEM_NAME STREQUAL "iOS") ++ if(CMAKE_OSX_SYSROOT MATCHES "i[pP]hone[sS]imulator") ++ set(RUST_PLATFORM "apple-ios-sim") ++ else() ++ set(RUST_PLATFORM "apple-ios") ++ endif() ++ else() ++ set(RUST_PLATFORM "apple-darwin") ++ endif() + set(RUST_TOOLCHAIN "") + elseif(FREEBSD) + set(RUST_PLATFORM "unknown-freebsd") diff --git a/patches/monero@fcmp-stage/drop_translations.patch b/patches/monero@fcmp-stage/drop_translations.patch new file mode 100644 index 0000000..fe9b5f3 --- /dev/null +++ b/patches/monero@fcmp-stage/drop_translations.patch @@ -0,0 +1,108 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -638,16 +638,11 @@ endfunction () + # Generate header for embedded translations + # Generate header for embedded translations, use target toolchain if depends, otherwise use the + # lrelease and lupdate binaries from the host +-include(ExternalProject) +-ExternalProject_Add(generate_translations_header +- SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/translations" +- BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/translations" +- STAMP_DIR ${LRELEASE_PATH} +- CMAKE_ARGS -DLRELEASE_PATH=${LRELEASE_PATH} +- INSTALL_COMMAND ${CMAKE_COMMAND} -E echo "") ++add_subdirectory(translations) + include_directories("${CMAKE_CURRENT_BINARY_DIR}/translations") + add_subdirectory(external) + ++ + # Final setup for libunbound + include_directories(${UNBOUND_INCLUDE_DIR}) + +diff --git a/translations/CMakeLists.txt b/translations/CMakeLists.txt +index 4bc579aaa..ad37b8ba7 100644 +--- a/translations/CMakeLists.txt ++++ b/translations/CMakeLists.txt +@@ -30,54 +30,31 @@ cmake_minimum_required(VERSION 3.10) + + project(translations) + +-# when crosscompiling import the executable targets from a file +-IF(CMAKE_CROSSCOMPILING) +- message(WARNING "CrossCompiling") +- SET(IMPORT_EXECUTABLES "${CMAKE_CURRENT_BINARY_DIR}/ImportExecutables.cmake" CACHE FILEPATH "Point it to the export file from a native build") +- INCLUDE(${IMPORT_EXECUTABLES}) +-ENDIF(CMAKE_CROSSCOMPILING) +- +-# only build the generator if not crosscompiling +-IF(NOT CMAKE_CROSSCOMPILING) +- add_executable(generate_translations_header generate_translations_header.c) +-ENDIF(NOT CMAKE_CROSSCOMPILING) +- +-if(LRELEASE_PATH STREQUAL "") +- find_program(LRELEASE lrelease) +-else() +- set(LRELEASE ${LRELEASE_PATH}/lrelease) +-endif() +- +-if(LRELEASE STREQUAL "LRELEASE-NOTFOUND") +- set(ts_files "") +- message(WARNING "lrelease program not found, translation files not built") +-else() +- execute_process(COMMAND ${LRELEASE} -version +- RESULT_VARIABLE lrelease_ret) +- if(NOT lrelease_ret EQUAL "0") +- set(ts_files "") +- message(WARNING "lrelease program not working, translation files not built") +- else() +- file(GLOB ts_files RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" *.ts) +- foreach(ts_file ${ts_files}) +- string(REPLACE ".ts" ".qm" qm_file "${ts_file}") +- add_custom_command(TARGET generate_translations_header +- PRE_BUILD +- COMMAND ${LRELEASE} "${CMAKE_CURRENT_SOURCE_DIR}/${ts_file}" -qm "${qm_file}" +- WORKING_DIRECTORY "${CMAKE_CURRENT_BIN_DIR}") +- endforeach() +- endif() +-endif() +- +-string(REPLACE ".ts" ".qm" qm_files "${ts_files}") +- +-add_custom_command(TARGET generate_translations_header +- POST_BUILD +- COMMAND $ ${qm_files} +- WORKING_DIRECTORY "${CMAKE_CURRENT_BIN_DIR}" +- COMMENT "Generating embedded translations header") +- +-# export the generator target to a file, so it can be imported (see above) by another build +-IF(NOT CMAKE_CROSSCOMPILING) +- EXPORT(TARGETS generate_translations_header FILE ${CMAKE_CURRENT_BINARY_DIR}/ImportExecutables.cmake ) +-ENDIF(NOT CMAKE_CROSSCOMPILING) ++add_custom_target(generate_translations_header) ++ ++file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/translation_files.h" ++"#ifndef TRANSLATION_FILES_H ++#define TRANSLATION_FILES_H ++ ++#include ++ ++static const struct embedded_file { ++ const std::string *name; ++ const std::string *data; ++} embedded_files[] = { ++ {NULL, NULL} ++}; ++ ++static bool find_embedded_file(const std::string &name, std::string &data) { ++ const struct embedded_file *p; ++ for (p = embedded_files; p->name != NULL; p++) { ++ if (*p->name == name) { ++ data = *p->data; ++ return true; ++ } ++ } ++ return false; ++} ++ ++#endif /* TRANSLATION_FILES_H */ ++") diff --git a/patches/monero@fcmp-stage/dummy_rt.patch b/patches/monero@fcmp-stage/dummy_rt.patch new file mode 100644 index 0000000..d41ff6f --- /dev/null +++ b/patches/monero@fcmp-stage/dummy_rt.patch @@ -0,0 +1,19 @@ +--- a/CMakeLists.txt 2026-07-30 00:43:00 ++++ b/CMakeLists.txt 2026-07-30 00:43:00 +@@ -1005,6 +1005,16 @@ + set(EXTRA_LIBRARIES socket nsl resolv) + elseif(NOT DEPENDS) + find_library(RT rt) ++ if(NOT RT) ++ set(DUMMY_RT_SRC "${CMAKE_CURRENT_BINARY_DIR}/dummy_rt.c") ++ file(WRITE "${DUMMY_RT_SRC}" "/* dummy librt for targets without librt */\n") ++ add_library(dummy_rt STATIC "${DUMMY_RT_SRC}") ++ set_target_properties(dummy_rt PROPERTIES ++ OUTPUT_NAME "rt" ++ ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}" ++ ) ++ set(RT dummy_rt) ++ endif() + find_library(Z z) + set(EXTRA_LIBRARIES ${RT} ${Z}) + endif() diff --git a/patches/monero@fcmp-stage/fix-ios-depends-build.patch b/patches/monero@fcmp-stage/fix-ios-depends-build.patch new file mode 100644 index 0000000..87ca87c --- /dev/null +++ b/patches/monero@fcmp-stage/fix-ios-depends-build.patch @@ -0,0 +1,69 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -52,10 +52,6 @@ if (POLICY CMP0179) + cmake_policy(SET CMP0179 NEW) + endif() + +-if (IOS) +- INCLUDE(CmakeLists_IOS.txt) +-endif() +- + project(monero) + + option (USE_COMPILER_CACHE "Use compiler cache if a usable instance is found (sccache/ccache)" ON) +diff --git a/src/cryptonote_basic/CMakeLists.txt b/src/cryptonote_basic/CMakeLists.txt +--- a/src/cryptonote_basic/CMakeLists.txt ++++ b/src/cryptonote_basic/CMakeLists.txt +@@ -28,7 +28,11 @@ + + if(APPLE) + if(DEPENDS) +- list(APPEND EXTRA_LIBRARIES "-framework Foundation -framework ApplicationServices -framework AppKit -framework IOKit") ++ if(${CMAKE_SYSTEM_NAME} STREQUAL "iOS") ++ list(APPEND EXTRA_LIBRARIES "-framework Foundation -framework IOKit") ++ else() ++ list(APPEND EXTRA_LIBRARIES "-framework Foundation -framework ApplicationServices -framework AppKit -framework IOKit") ++ endif() + else() + find_library(IOKIT_LIBRARY IOKit) + mark_as_advanced(IOKIT_LIBRARY) +diff --git a/src/cryptonote_basic/miner.cpp b/src/cryptonote_basic/miner.cpp +--- a/src/cryptonote_basic/miner.cpp ++++ b/src/cryptonote_basic/miner.cpp +@@ -46,7 +46,7 @@ + #include "boost/logic/tribool.hpp" + #include + +-#ifdef __APPLE__ ++#if defined(__APPLE__) && !defined(TARGET_OS_IPHONE) + #include + #include + #include +@@ -885,7 +885,7 @@ namespace cryptonote + + return true; + +- #elif defined(__APPLE__) ++ #elif defined(__APPLE__) && !defined(TARGET_OS_IPHONE) + + mach_msg_type_number_t count; + kern_return_t status; +@@ -951,7 +951,7 @@ namespace cryptonote + return true; + } + +- #elif (defined(__linux__) && defined(_SC_CLK_TCK)) || defined(__APPLE__) || defined(__FreeBSD__) ++ #elif (defined(__linux__) && defined(_SC_CLK_TCK)) || (defined(__APPLE__) && !defined(TARGET_OS_IPHONE)) || defined(__FreeBSD__) + + struct tms tms; + if ( times(&tms) != (clock_t)-1 ) +@@ -980,7 +980,7 @@ namespace cryptonote + return boost::logic::tribool(power_status.ACLineStatus != 1); + } + +- #elif defined(__APPLE__) ++ #elif defined(__APPLE__) && !defined(TARGET_OS_IPHONE) + + #if TARGET_OS_MAC && (!defined(MAC_OS_X_VERSION_MIN_REQUIRED) || MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7) + return boost::logic::tribool(IOPSGetTimeRemainingEstimate() != kIOPSTimeRemainingUnlimited); diff --git a/patches/monero@fcmp-stage/remove_icu4c.patch b/patches/monero@fcmp-stage/remove_icu4c.patch new file mode 100644 index 0000000..5b899e3 --- /dev/null +++ b/patches/monero@fcmp-stage/remove_icu4c.patch @@ -0,0 +1,28 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index ccb2c34dc..cbc67f9fd 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -974,19 +974,16 @@ include_directories(SYSTEM ${Boost_INCLUDE_DIRS}) + if(MINGW) + set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wa,-mbig-obj") + set(EXTRA_LIBRARIES mswsock;ws2_32;iphlpapi;crypt32;bcrypt) +- if(NOT DEPENDS) ++ if(DEPENDS) ++ set(ICU_LIBRARIES iconv) ++ else() + # This is an extremely ugly hack to get around Boost not being built with static ICU. + # We reported the issue, we are waiting for upstream to fix this issue: https://github.com/boostorg/boost/issues/1079#issue-3384962885 + # This hack links shared ICU libs to avoid linker errors we get in MSYS2 compilation (undefined symbols to ICU). + set(OLD_LIB_SUFFIXES ${CMAKE_FIND_LIBRARY_SUFFIXES}) + set(CMAKE_FIND_LIBRARY_SUFFIXES ".dll.a") +- find_library(ICUIO_LIBRARIES NAMES icuio REQUIRED) +- find_library(ICUIN_LIBRARIES NAMES icuin REQUIRED) +- find_library(ICUUC_LIBRARIES NAMES icuuc REQUIRED) +- find_library(ICUDT_LIBRARIES NAMES icudt REQUIRED) +- find_library(ICUTU_LIBRARIES NAMES icutu REQUIRED) + find_library(ICONV_LIBRARIES NAMES iconv REQUIRED) +- set(ICU_LIBRARIES ${ICUIO_LIBRARIES} ${ICUIN_LIBRARIES} ${ICUUC_LIBRARIES} ${ICUDT_LIBRARIES} ${ICUTU_LIBRARIES} ${ICONV_LIBRARIES}) ++ set(ICU_LIBRARIES ${ICUIO_LIBRARIES} ${ICONV_LIBRARIES}) + set(CMAKE_FIND_LIBRARY_SUFFIXES ${OLD_LIB_SUFFIXES}) + endif() + elseif(APPLE OR OPENBSD OR ANDROID) diff --git a/patches/native/_/drop-gnulib-wint-wrappers.sh b/patches/native/_/drop-gnulib-wint-wrappers.sh new file mode 100644 index 0000000..01ed368 --- /dev/null +++ b/patches/native/_/drop-gnulib-wint-wrappers.sh @@ -0,0 +1,41 @@ +#!/bin/sh +# Gnulib's stddef wrapper breaks Cygwin's __need_wint_t protocol (sys/_types.h +# sees an unknown wint_t). Replace stddef.h with #include_next, then restore +# gnulib's unreachable() helper that newer packages expect from stddef.h. +# Leave *.in.h present and older than the stub so make does not regenerate it. +set -e +stub_stddef() { + dir=$1 + f="$dir/stddef.h" + inh="$dir/stddef.in.h" + [ -f "$f" ] || [ -f "$inh" ] || return 0 + rm -f "$f" + cat >"$f" <<'EOF' +#include_next +#ifndef unreachable +# if defined __has_builtin +# if __has_builtin (__builtin_unreachable) +# define unreachable() __builtin_unreachable () +# endif +# endif +#endif +#ifndef unreachable +# if defined __GNUC__ || defined __clang__ +# define unreachable() __builtin_unreachable () +# else +# define unreachable() ((void) 0) +# endif +#endif +EOF + cp -f "$f" "$inh" + touch -t 197001010000.01 "$inh" 2>/dev/null || true + touch "$f" +} +for dir in lib libgrep libgzip gnulib-lib; do + [ -d "$dir" ] || continue + stub_stddef "$dir" +done +find . -type d \( -name lib -o -name gnulib-lib \) 2>/dev/null | +while read -r dir; do + stub_stddef "$dir" +done diff --git a/patches/native/_/fix-gnulib-pthread-once.sh b/patches/native/_/fix-gnulib-pthread-once.sh new file mode 100644 index 0000000..75a189e --- /dev/null +++ b/patches/native/_/fix-gnulib-pthread-once.sh @@ -0,0 +1,8 @@ +#!/bin/sh +# Clang rejects __sync_* on _Atomic* in gnulib's Cygwin pthread-once workaround. +# Safe no-op if the file or pattern is absent. +set -e +f=lib/pthread-once.c +if [ -f "$f" ] && grep -q '__sync_bool_compare_and_swap (&state_p->done, 1, 2)' "$f"; then + sed -i.bak 's/__sync_bool_compare_and_swap (&state_p->done, 1, 2)/__sync_bool_compare_and_swap ((unsigned short *) \&state_p->done, 1, 2)/' "$f" +fi diff --git a/patches/native/_/stage-seed-tools.sh b/patches/native/_/stage-seed-tools.sh new file mode 100644 index 0000000..4fb418b --- /dev/null +++ b/patches/native/_/stage-seed-tools.sh @@ -0,0 +1,34 @@ +#!/bin/sh +# On Windows/Cygwin, several gnulib packages fail with wint_t / uchar issues. +# Stage the matching tools already present in the Cygwin seed ($NATIVEPREFIX/_/bin). +set -e +bin="$NATIVEPREFIX/_/bin" +dest="$STAGING_DIR$NATIVEPREFIX/bin" +mkdir -p "$dest" +copy_one() { + name=$1 + if [ -f "$bin/$name.exe" ]; then + cp -f "$bin/$name.exe" "$dest/$name.exe" + return + fi + if [ -f "$bin/$name" ]; then + cp -f "$bin/$name" "$dest/$name" + return + fi + # Common aliases shipped as argv0 copies of another tool. + case "$name" in + egrep|fgrep) + cp -f "$bin/grep.exe" "$dest/$name.exe" + ;; + gunzip|zcat|gzcat) + cp -f "$bin/gzip.exe" "$dest/$name.exe" + ;; + *) + echo "seed tool missing: $bin/$name(.exe)" >&2 + exit 1 + ;; + esac +} +for name in "$@"; do + copy_one "$name" +done diff --git a/patches/native/coreutils/clang-pthread-once-atomic.patch b/patches/native/coreutils/clang-pthread-once-atomic.patch new file mode 100644 index 0000000..ce329a4 --- /dev/null +++ b/patches/native/coreutils/clang-pthread-once-atomic.patch @@ -0,0 +1,12 @@ +--- a/lib/pthread-once.c ++++ b/lib/pthread-once.c +@@ -92,7 +92,8 @@ pthread_once (pthread_once_t *once_control, void (*initfunction) (void)) + /* num_threads is now zero, and done is > 0. + No other thread will need to use the lock. + We can therefore destroy the lock, to free resources. */ +- if (__sync_bool_compare_and_swap (&state_p->done, 1, 2)) ++ /* Clang rejects __sync_* on _Atomic*; cast to the underlying type. */ ++ if (__sync_bool_compare_and_swap ((unsigned short *) &state_p->done, 1, 2)) + pthread_mutex_destroy (&once_control->mutex); + } + } diff --git a/patches/native/ct-tools/clang-widl-winnt.h.patch b/patches/native/ct-tools/clang-widl-winnt.h.patch new file mode 100644 index 0000000..51fc22a --- /dev/null +++ b/patches/native/ct-tools/clang-widl-winnt.h.patch @@ -0,0 +1,21 @@ +--- a/mingw-w64-tools/widl/include/winnt.h ++++ b/mingw-w64-tools/widl/include/winnt.h +@@ -2466,11 +2466,16 @@ static FORCEINLINE struct _TEB * WINAPI NtCurrentTeb(void) + { + return (struct _TEB *)__readfsdword( 0x18 ); + } +-#elif (defined(__aarch64__) || defined(__arm64ec__)) && defined(__GNUC__) ++#elif (defined(__aarch64__) || defined(__arm64ec__)) && defined(__GNUC__) && !defined(__clang__) + register struct _TEB *__wine_current_teb __asm__("x18"); + static FORCEINLINE struct _TEB * WINAPI NtCurrentTeb(void) + { + return __wine_current_teb; + } ++#elif (defined(__aarch64__) || defined(__arm64ec__)) && defined(__clang__) ++static FORCEINLINE struct _TEB * WINAPI NtCurrentTeb(void) ++{ ++ return (struct _TEB *)0; ++} + #elif (defined(__aarch64__) || defined(__arm64ec__)) && defined(_MSC_VER) + static FORCEINLINE struct _TEB * WINAPI NtCurrentTeb(void) + { diff --git a/patches/native/ct-tools/host-ld-wrapper.sh b/patches/native/ct-tools/host-ld-wrapper.sh new file mode 100644 index 0000000..d8b0453 --- /dev/null +++ b/patches/native/ct-tools/host-ld-wrapper.sh @@ -0,0 +1,122 @@ +#!/bin/bash +ld64=@LD64_LLD@ +sdk_max=@SDK_VERSION@ +tmps=() +cleanup() { + local f + for f in "${tmps[@]}"; do + rm -f "$f" + done +} +trap cleanup EXIT + +filter_response_file() { + local in=$1 out + out=$(mktemp) + tmps+=("$out") + python3 - "$in" "$out" "$sdk_max" <<'PY' +import shlex +import sys + +src, dst, sdk_max = sys.argv[1:4] +data = open(src, "r", encoding="utf-8", errors="replace").read() +args = shlex.split(data) +out = [] +i = 0 +while i < len(args): + arg = args[i] + if arg in ("-undefined-version", "--undefined-version"): + i += 1 + continue + if arg in ("-soname", "-Wl,-soname"): + i += 1 + if i < len(args): + out.extend(["-install_name", args[i]]) + continue + if arg.startswith("-Wl,-soname,"): + out.extend(["-install_name", arg.split(",", 2)[2]]) + i += 1 + continue + if arg in ("-retain-symbols-file", "-Wl,-retain-symbols-file", "-version-script", "-Wl,-version-script"): + i += 2 + continue + if arg.startswith("-Wl,-retain-symbols-file,") or arg.startswith("-Wl,-version-script,"): + i += 1 + continue + if arg == "-macosx_version_min": + if i + 1 < len(args): + out.extend(["-platform_version", "macos", args[i + 1], sdk_max]) + i += 2 + continue + if arg.startswith("-macosx_version_min="): + out.extend(["-platform_version", "macos", arg.split("=", 1)[1], sdk_max]) + i += 1 + continue + out.append(arg) + i += 1 + +with open(dst, "w", encoding="utf-8") as fh: + for arg in out: + if " " in arg or '"' in arg or "'" in arg: + fh.write('"' + arg.replace("\\", "\\\\").replace('"', '\\"') + '" ') + else: + fh.write(arg + " ") +PY + printf '@%s' "$out" +} + +if [ $# -eq 1 ]; then + case "$1" in + -v) + echo '@(#)PROGRAM:ld PROJECT:ld64-711' + exit 0 + ;; + --version) + exec -a ld64.lld "$ld64" --version + ;; + esac +fi + +args=() +while [ $# -gt 0 ]; do + case "$1" in + -soname|-Wl,-soname) + shift + [ $# -gt 0 ] || { echo "host-ld-wrapper: -soname requires an argument" >&2; exit 1; } + args+=(-install_name "$1") + ;; + -Wl,-soname,*) + args+=(-install_name "${1#-Wl,-soname,}") + ;; + -retain-symbols-file|-Wl,-retain-symbols-file|-version-script|-Wl,-version-script) + shift + [ $# -gt 0 ] && shift + continue + ;; + -Wl,-retain-symbols-file,*|-Wl,-version-script,*) + ;; + -macosx_version_min) + shift + args+=(-platform_version macos "$1" "$sdk_max") + shift + ;; + -macosx_version_min=*) + args+=(-platform_version macos "${1#-macosx_version_min=}" "$sdk_max") + ;; + -undefined-version|--undefined-version) + ;; + @*) + f="${1#@}" + if [ -f "$f" ]; then + args+=("$(filter_response_file "$f")") + else + args+=("$1") + fi + ;; + *) + args+=("$1") + ;; + esac + shift +done +exec -a ld64.lld "$ld64" "${args[@]}" diff --git a/patches/native/osx-cross/classic-ld-wrapper.sh b/patches/native/osx-cross/classic-ld-wrapper.sh new file mode 100644 index 0000000..b00d0a4 --- /dev/null +++ b/patches/native/osx-cross/classic-ld-wrapper.sh @@ -0,0 +1,95 @@ +#!/bin/bash +ld64=@LD64_LLD@ +sdk_max=@SDK_VERSION@ +tmps=() +cleanup() { + local f + for f in "${tmps[@]}"; do + rm -f "$f" + done +} +trap cleanup EXIT + +filter_response_file() { + local in=$1 out + out=$(mktemp) + tmps+=("$out") + python3 - "$in" "$out" "$sdk_max" <<'PY' +import shlex +import sys + +src, dst, sdk_max = sys.argv[1:4] +data = open(src, "r", encoding="utf-8", errors="replace").read() +args = shlex.split(data) +out = [] +i = 0 +while i < len(args): + arg = args[i] + if arg in ("-undefined-version", "--undefined-version"): + i += 1 + continue + if arg == "-macosx_version_min": + if i + 1 < len(args): + out.extend(["-platform_version", "macos", args[i + 1], sdk_max]) + i += 2 + continue + if arg.startswith("-macosx_version_min="): + out.extend(["-platform_version", "macos", arg.split("=", 1)[1], sdk_max]) + i += 1 + continue + out.append(arg) + i += 1 + +with open(dst, "w", encoding="utf-8") as fh: + for arg in out: + if " " in arg or '"' in arg or "'" in arg: + fh.write('"' + arg.replace("\\", "\\\\").replace('"', '\\"') + '" ') + else: + fh.write(arg + " ") +PY + printf '@%s' "$out" +} + +if [ $# -eq 1 ]; then + case "$1" in + -v) + echo '@(#)PROGRAM:ld PROJECT:ld64-711' + exit 0 + ;; + --version) + exec -a ld64.lld "$ld64" --version + ;; + esac +fi + +args=() +while [ $# -gt 0 ]; do + case "$1" in + -macosx_version_min) + shift + args+=(-platform_version macos "$1" "$sdk_max") + shift + ;; + -macosx_version_min=*) + args+=(-platform_version macos "${1#-macosx_version_min=}" "$sdk_max") + shift + ;; + -undefined-version|--undefined-version) + shift + ;; + @*) + f="${1#@}" + if [ -f "$f" ]; then + args+=("$(filter_response_file "$f")") + else + args+=("$1") + fi + shift + ;; + *) + args+=("$1") + shift + ;; + esac +done +exec -a ld64.lld "$ld64" "${args[@]}" diff --git a/patches/native/python@3.14/cygwin-clockid-t.patch b/patches/native/python@3.14/cygwin-clockid-t.patch new file mode 100644 index 0000000..4c90bd9 --- /dev/null +++ b/patches/native/python@3.14/cygwin-clockid-t.patch @@ -0,0 +1,10 @@ +--- a/Modules/timemodule.c ++++ b/Modules/timemodule.c +@@ -188,7 +188,7 @@ time_clockid_converter(PyObject *obj, clockid_t *p) + #ifdef _AIX + long long clk_id = PyLong_AsLongLong(obj); +-#elif defined(__DragonFly__) ++#elif defined(__DragonFly__) || defined(__CYGWIN__) + long clk_id = PyLong_AsLong(obj); + #else + int clk_id = PyLong_AsInt(obj); diff --git a/patches/native/python@3.14/cygwin-dynload-suffix.patch b/patches/native/python@3.14/cygwin-dynload-suffix.patch new file mode 100644 index 0000000..dd8aa90 --- /dev/null +++ b/patches/native/python@3.14/cygwin-dynload-suffix.patch @@ -0,0 +1,10 @@ +--- a/Python/dynload_shlib.c ++++ b/Python/dynload_shlib.c +@@ -38,6 +38,7 @@ + + const char *_PyImport_DynLoadFiletab[] = { + #ifdef __CYGWIN__ ++ "." SOABI ".dll", + ".dll", + #else /* !__CYGWIN__ */ + "." SOABI ".so", diff --git a/patches/native_python3/deterministic_build.patch b/patches/native_python3/deterministic_build.patch deleted file mode 100644 index 46a9a4b..0000000 --- a/patches/native_python3/deterministic_build.patch +++ /dev/null @@ -1,18 +0,0 @@ -Always provide the same date and time in 'Py_GetBuildInfo'. -This is the information shown at the REPL and in 'sys.version'. -We cannot pass it in CPPFLAGS due to whitespace in the DATE string. -https://codeberg.org/guix/guix/src/branch/master/gnu/packages/patches/python-3-deterministic-build-info.patch - ---- a/Modules/getbuildinfo.c -+++ b/Modules/getbuildinfo.c -@@ -4,6 +4,10 @@ - #include - #endif - -+/* Deterministic date and time. */ -+#define DATE "Jan 1 1970" -+#define TIME "00:00:01" -+ - #ifndef DATE - #ifdef __DATE__ - #define DATE __DATE__ \ No newline at end of file diff --git a/patches/native_qt/guix_cross_lib_path.patch b/patches/native_qt/guix_cross_lib_path.patch new file mode 100644 index 0000000..7911dc2 --- /dev/null +++ b/patches/native_qt/guix_cross_lib_path.patch @@ -0,0 +1,17 @@ +Facilitate guix building with CROSS_LIBRARY_PATH + +See discussion in https://github.com/bitcoin/bitcoin/pull/15277. + +--- a/qtbase/mkspecs/features/toolchain.prf ++++ b/qtbase/mkspecs/features/toolchain.prf +@@ -236,8 +236,8 @@ isEmpty($${target_prefix}.INCDIRS) { + add_libraries = false + for (line, output) { + line ~= s/^[ \\t]*// # remove leading spaces +- contains(line, "LIBRARY_PATH=.*") { +- line ~= s/^LIBRARY_PATH=// # remove leading LIBRARY_PATH= ++ contains(line, "(CROSS_)?LIBRARY_PATH=.*") { ++ line ~= s/^(CROSS_)?LIBRARY_PATH=// # remove leading (CROSS_)?LIBRARY_PATH= + equals(QMAKE_HOST.os, Windows): \ + paths = $$split(line, ;) + else: \ diff --git a/patches/native_qt/qtbase-moc-ignore-gcc-macro.patch b/patches/native_qt/qtbase-moc-ignore-gcc-macro.patch new file mode 100644 index 0000000..9b848cc --- /dev/null +++ b/patches/native_qt/qtbase-moc-ignore-gcc-macro.patch @@ -0,0 +1,17 @@ +The moc executable loops through headers on CPLUS_INCLUDE_PATH and stumbles +on the GCC internal _GLIBCXX_VISIBILITY macro. Tell it to ignore it as it is +not supposed to be looking there to begin with. + +Upstream report: https://bugreports.qt.io/browse/QTBUG-83160 + +diff --git a/qtbase/src/tools/moc/main.cpp b/qtbase/src/tools/moc/main.cpp +--- a/qtbase/src/tools/moc/main.cpp ++++ b/qtbase/src/tools/moc/main.cpp +@@ -197,6 +197,7 @@ int runMoc(int argc, char **argv) + dummyVariadicFunctionMacro.arguments += Symbol(0, PP_IDENTIFIER, "__VA_ARGS__"); + pp.macros["__attribute__"] = dummyVariadicFunctionMacro; + pp.macros["__declspec"] = dummyVariadicFunctionMacro; ++ pp.macros["_GLIBCXX_VISIBILITY"] = dummyVariadicFunctionMacro; + + QString filename; + QString output; diff --git a/patches/native_qt/rcc_hardcode_timestamp.patch b/patches/native_qt/rcc_hardcode_timestamp.patch new file mode 100644 index 0000000..591ecaa --- /dev/null +++ b/patches/native_qt/rcc_hardcode_timestamp.patch @@ -0,0 +1,25 @@ +Hardcode last modified timestamp in Qt RCC + +This change allows the already built qt package to be reused even with +the SOURCE_DATE_EPOCH variable set, e.g., for Guix builds. + +diff --git a/qtbase/src/tools/rcc/rcc.cpp b/qtbase/src/tools/rcc/rcc.cpp +index e461ab6294..256dc0ba29 100644 +--- a/qtbase/src/tools/rcc/rcc.cpp ++++ b/qtbase/src/tools/rcc/rcc.cpp +@@ -201,14 +201,7 @@ void RCCFileInfo::writeDataInfo(RCCResourceLibrary &lib) + + if (lib.formatVersion() >= 2) { + // last modified time stamp +- const QDateTime lastModified = m_fileInfo.lastModified(QTimeZone::UTC); +- quint64 lastmod = quint64(lastModified.isValid() ? lastModified.toMSecsSinceEpoch() : 0); +- static const quint64 sourceDate = 1000 * qgetenv("QT_RCC_SOURCE_DATE_OVERRIDE").toULongLong(); +- if (sourceDate != 0) +- lastmod = sourceDate; +- static const quint64 sourceDate2 = 1000 * qgetenv("SOURCE_DATE_EPOCH").toULongLong(); +- if (sourceDate2 != 0) +- lastmod = sourceDate2; ++ quint64 lastmod = quint64(1); + lib.writeNumber8(lastmod); + if (text || pass1) + lib.writeChar('\n'); diff --git a/patches/native_qt/root_CMakeLists.txt b/patches/native_qt/root_CMakeLists.txt new file mode 100644 index 0000000..8ad7584 --- /dev/null +++ b/patches/native_qt/root_CMakeLists.txt @@ -0,0 +1,51 @@ +# The real minimum version will be checked by the qtbase project. +# 3.16 is the absolute minimum though. +cmake_minimum_required(VERSION 3.16...3.20) + +# Include qtbase's .cmake.conf for access to QT_REPO_MODULE_VERSION +set(__qt6_qtbase_src_path "${CMAKE_CURRENT_SOURCE_DIR}/qtbase") +include("${__qt6_qtbase_src_path}/.cmake.conf") + +# Run platform auto-detection /before/ the first project() call and thus +# before the toolchain file is loaded. +include("${__qt6_qtbase_src_path}/cmake/QtAutoDetect.cmake") + +project(Qt + VERSION "${QT_REPO_MODULE_VERSION}" + DESCRIPTION "Qt Libraries" + HOMEPAGE_URL "https://qt.io/" + LANGUAGES CXX C ASM +) + +# Required so we can call ctest from the root build directory +enable_testing() + +set(qt_module_prop_prefix "__qt_prop_") + +list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") +list(APPEND CMAKE_MODULE_PATH "${__qt6_qtbase_src_path}/cmake") +list(APPEND CMAKE_MODULE_PATH + "${__qt6_qtbase_src_path}/cmake/3rdparty/extra-cmake-modules/find-modules") +list(APPEND CMAKE_MODULE_PATH "${__qt6_qtbase_src_path}/cmake/3rdparty/kwin") + +# Also make sure the CMake config files do not recreate the already-existing targets +set(QT_NO_CREATE_TARGETS TRUE) +set(QT_SUPERBUILD TRUE) + +set(QT_BUILD_SUBMODULES "qtbase;qttools;qtshadertools" CACHE STRING "Submodules to build") + +foreach(module IN LISTS QT_BUILD_SUBMODULES) + message(NOTICE "Configuring '${module}'") + add_subdirectory("${module}") + + if(module STREQUAL "qtbase") + list(APPEND CMAKE_PREFIX_PATH "${QtBase_BINARY_DIR}/lib/cmake") + list(APPEND CMAKE_FIND_ROOT_PATH "${QtBase_BINARY_DIR}") + endif() +endforeach() + +# Display a summary of everything +include(QtBuildInformation) +include(QtPlatformSupport) +qt_print_feature_summary() +qt_print_build_instructions() diff --git a/patches/onnxruntime/android-log-and-sink.patch b/patches/onnxruntime/android-log-and-sink.patch new file mode 100644 index 0000000..5f635a9 --- /dev/null +++ b/patches/onnxruntime/android-log-and-sink.patch @@ -0,0 +1,35 @@ +--- a/cmake/onnxruntime_common.cmake ++++ b/cmake/onnxruntime_common.cmake +@@ -47,7 +47,7 @@ + ) + endif() + +- if (CMAKE_SYSTEM_NAME STREQUAL "Android") ++ if (CMAKE_SYSTEM_NAME STREQUAL "Android" OR CMAKE_C_COMPILER MATCHES "android" OR "$ENV{HOST}" MATCHES "android") + list(APPEND onnxruntime_common_src_patterns + "${ONNXRUNTIME_ROOT}/core/platform/android/logging/*.h" + "${ONNXRUNTIME_ROOT}/core/platform/android/logging/*.cc" +--- a/cmake/CMakeLists.txt ++++ b/cmake/CMakeLists.txt +@@ -1676,7 +1676,7 @@ + list(APPEND onnxruntime_EXTERNAL_LIBRARIES ${ICONV_LIB} ${CMAKE_DL_LIBS} Threads::Threads) + endif() + +-if (CMAKE_SYSTEM_NAME STREQUAL "Android") ++if (CMAKE_SYSTEM_NAME STREQUAL "Android" OR CMAKE_C_COMPILER MATCHES "android" OR "$ENV{HOST}" MATCHES "android") + list(APPEND onnxruntime_EXTERNAL_LIBRARIES log) + endif() + +--- a/cmake/onnxruntime_mlas.cmake ++++ b/cmake/onnxruntime_mlas.cmake +@@ -745,8 +745,8 @@ + if(NOT WIN32) + target_link_libraries(onnxruntime_mlas_q4dq PRIVATE nsync::nsync_cpp ${CMAKE_DL_LIBS}) + endif() +- if (CMAKE_SYSTEM_NAME STREQUAL "Android") +- target_link_libraries(onnxruntime_mlas_q4dq PRIVATE ${android_shared_libs}) ++ if (CMAKE_SYSTEM_NAME STREQUAL "Android" OR CMAKE_C_COMPILER MATCHES "android" OR "$ENV{HOST}" MATCHES "android") ++ target_link_libraries(onnxruntime_mlas_q4dq PRIVATE log) + endif() + + if(WIN32) diff --git a/patches/onnxruntime/cpuinfo-android-properties.patch b/patches/onnxruntime/cpuinfo-android-properties.patch new file mode 100644 index 0000000..6b9cfee --- /dev/null +++ b/patches/onnxruntime/cpuinfo-android-properties.patch @@ -0,0 +1,11 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -211,7 +211,7 @@ + ELSEIF(IS_APPLE_OS AND CPUINFO_TARGET_PROCESSOR MATCHES "arm64.*") + LIST(APPEND CPUINFO_SRCS src/arm/mach/init.c) + ENDIF() +- IF(CMAKE_SYSTEM_NAME STREQUAL "Android") ++ IF(CMAKE_SYSTEM_NAME STREQUAL "Android" OR CMAKE_C_COMPILER MATCHES "android" OR "$ENV{HOST}" MATCHES "android") + LIST(APPEND CPUINFO_SRCS + src/arm/android/properties.c) + ENDIF() diff --git a/patches/onnxruntime/cstdint-optimizer-api.patch b/patches/onnxruntime/cstdint-optimizer-api.patch new file mode 100644 index 0000000..382b15f --- /dev/null +++ b/patches/onnxruntime/cstdint-optimizer-api.patch @@ -0,0 +1,10 @@ +--- a/onnxruntime/core/optimizer/transpose_optimization/optimizer_api.h ++++ b/onnxruntime/core/optimizer/transpose_optimization/optimizer_api.h +@@ -3,6 +3,7 @@ + + #pragma once + ++#include + #include + #include + #include diff --git a/patches/qt/fix_static_qt_darwin_camera_permissions.patch b/patches/qt/fix_static_qt_darwin_camera_permissions.patch new file mode 100644 index 0000000..f8b8391 --- /dev/null +++ b/patches/qt/fix_static_qt_darwin_camera_permissions.patch @@ -0,0 +1,27 @@ +diff --git a/src/corelib/platform/darwin/qdarwinpermissionplugin_camera.mm b/src/corelib/platform/darwin/qdarwinpermissionplugin_camera.mm +index 51c517d6f3..ed3135fba3 100644 +--- a/src/corelib/platform/darwin/qdarwinpermissionplugin_camera.mm ++++ b/src/corelib/platform/darwin/qdarwinpermissionplugin_camera.mm +@@ -7,8 +7,6 @@ + + QT_DEFINE_PERMISSION_STATUS_CONVERTER(AVAuthorizationStatus); + +-#ifndef BUILDING_PERMISSION_REQUEST +- + @implementation QDarwinCameraPermissionHandler + - (Qt::PermissionStatus)checkPermission:(QPermission)permission + { +@@ -25,8 +23,6 @@ QT_DEFINE_PERMISSION_STATUS_CONVERTER(AVAuthorizationStatus); + + #include "moc_qdarwinpermissionplugin_p_p.cpp" + +-#else // Building request +- + @implementation QDarwinCameraPermissionHandler (Request) + - (void)requestPermission:(QPermission)permission withCallback:(PermissionCallback)callback + { +@@ -39,4 +35,3 @@ QT_DEFINE_PERMISSION_STATUS_CONVERTER(AVAuthorizationStatus); + } + @end + +-#endif // BUILDING_PERMISSION_REQUEST diff --git a/patches/qt/libxau-fix.patch b/patches/qt/libxau-fix.patch new file mode 100644 index 0000000..b3e4c9e --- /dev/null +++ b/patches/qt/libxau-fix.patch @@ -0,0 +1,12 @@ +diff --git a/src/gui/configure.cmake b/src/gui/configure.cmake +index 1ff24eebaf..1ce02f058e 100644 +--- a/src/gui/configure.cmake ++++ b/src/gui/configure.cmake +@@ -499,6 +499,7 @@ qt_config_compile_test(xcb_syslibs + XCB::XFIXES + XCB::XKB + XCB::XCB ++ X11::Xau + CODE + "// xkb.h is using a variable called 'explicit', which is a reserved keyword in C++ + #define explicit dont_use_cxx_explicit diff --git a/patches/qt/rcc_hardcode_timestamp.patch b/patches/qt/rcc_hardcode_timestamp.patch new file mode 100644 index 0000000..591ecaa --- /dev/null +++ b/patches/qt/rcc_hardcode_timestamp.patch @@ -0,0 +1,25 @@ +Hardcode last modified timestamp in Qt RCC + +This change allows the already built qt package to be reused even with +the SOURCE_DATE_EPOCH variable set, e.g., for Guix builds. + +diff --git a/qtbase/src/tools/rcc/rcc.cpp b/qtbase/src/tools/rcc/rcc.cpp +index e461ab6294..256dc0ba29 100644 +--- a/qtbase/src/tools/rcc/rcc.cpp ++++ b/qtbase/src/tools/rcc/rcc.cpp +@@ -201,14 +201,7 @@ void RCCFileInfo::writeDataInfo(RCCResourceLibrary &lib) + + if (lib.formatVersion() >= 2) { + // last modified time stamp +- const QDateTime lastModified = m_fileInfo.lastModified(QTimeZone::UTC); +- quint64 lastmod = quint64(lastModified.isValid() ? lastModified.toMSecsSinceEpoch() : 0); +- static const quint64 sourceDate = 1000 * qgetenv("QT_RCC_SOURCE_DATE_OVERRIDE").toULongLong(); +- if (sourceDate != 0) +- lastmod = sourceDate; +- static const quint64 sourceDate2 = 1000 * qgetenv("SOURCE_DATE_EPOCH").toULongLong(); +- if (sourceDate2 != 0) +- lastmod = sourceDate2; ++ quint64 lastmod = quint64(1); + lib.writeNumber8(lastmod); + if (text || pass1) + lib.writeChar('\n'); diff --git a/patches/qt/root_CMakeLists.txt b/patches/qt/root_CMakeLists.txt new file mode 100644 index 0000000..6b7f6a7 --- /dev/null +++ b/patches/qt/root_CMakeLists.txt @@ -0,0 +1,51 @@ +# The real minimum version will be checked by the qtbase project. +# 3.16 is the absolute minimum though. +cmake_minimum_required(VERSION 3.16...3.20) + +# Include qtbase's .cmake.conf for access to QT_REPO_MODULE_VERSION +set(__qt6_qtbase_src_path "${CMAKE_CURRENT_SOURCE_DIR}/qtbase") +include("${__qt6_qtbase_src_path}/.cmake.conf") + +# Run platform auto-detection /before/ the first project() call and thus +# before the toolchain file is loaded. +include("${__qt6_qtbase_src_path}/cmake/QtAutoDetect.cmake") + +project(Qt + VERSION "${QT_REPO_MODULE_VERSION}" + DESCRIPTION "Qt Libraries" + HOMEPAGE_URL "https://qt.io/" + LANGUAGES CXX C ASM +) + +# Required so we can call ctest from the root build directory +enable_testing() + +set(qt_module_prop_prefix "__qt_prop_") + +list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") +list(APPEND CMAKE_MODULE_PATH "${__qt6_qtbase_src_path}/cmake") +list(APPEND CMAKE_MODULE_PATH + "${__qt6_qtbase_src_path}/cmake/3rdparty/extra-cmake-modules/find-modules") +list(APPEND CMAKE_MODULE_PATH "${__qt6_qtbase_src_path}/cmake/3rdparty/kwin") + +# Also make sure the CMake config files do not recreate the already-existing targets +set(QT_NO_CREATE_TARGETS TRUE) +set(QT_SUPERBUILD TRUE) + +set(QT_BUILD_SUBMODULES "qtbase;qtsvg;qtwebsockets;qtshadertools;qtmultimedia;qtwayland" CACHE STRING "Submodules to build") + +foreach(module IN LISTS QT_BUILD_SUBMODULES) + message(NOTICE "Configuring '${module}'") + add_subdirectory("${module}") + + if(module STREQUAL "qtbase") + list(APPEND CMAKE_PREFIX_PATH "${QtBase_BINARY_DIR}/lib/cmake") + list(APPEND CMAKE_FIND_ROOT_PATH "${QtBase_BINARY_DIR}") + endif() +endforeach() + +# Display a summary of everything +include(QtBuildInformation) +include(QtPlatformSupport) +qt_print_feature_summary() +qt_print_build_instructions() diff --git a/patches/qt/setup-toolchain.sh b/patches/qt/setup-toolchain.sh new file mode 100644 index 0000000..0348871 --- /dev/null +++ b/patches/qt/setup-toolchain.sh @@ -0,0 +1,54 @@ +#!/bin/sh +set -e + +case "$CMAKE_SYSTEM_NAME" in +Linux) + sed -i \ + -e "s|@cmake_system_name@|Linux|" \ + -e "s|@target@|$HOST|" \ + -e "s|@host_prefix@|$PREFIX|" \ + -e "s|@sdk_path@||" \ + -e "s|@cc@||" \ + -e "s|@cxx@||" \ + -e "s|@osx_min_version@||" \ + -e "s|@cmake_c_flags@||" \ + -e "s|@cmake_cxx_flags@||" \ + -e "s|@cmake_ld_flags@||" \ + -e "s|@wmf_libs@||" \ + toolchain.cmake + ;; +Darwin) + sed -i \ + -e "s|@cmake_system_name@|Darwin|" \ + -e "s|@target@|$HOST|" \ + -e "s|@host_prefix@|$PREFIX|" \ + -e "s|@sdk_path@|$SDK_PATH|" \ + -e "s|@cc@|$NATIVEPREFIX/bin/$HOST-clang|" \ + -e "s|@cxx@|$NATIVEPREFIX/bin/$HOST-clang++|" \ + -e "s|@osx_min_version@|$OSX_MIN_VERSION|" \ + -e "s|@cmake_c_flags@|-mmacosx-version-min=$OSX_MIN_VERSION -isysroot $SDK_PATH|" \ + -e "s|@cmake_cxx_flags@|-mmacosx-version-min=$OSX_MIN_VERSION -isysroot $SDK_PATH -stdlib=libc++|" \ + -e "s|@cmake_ld_flags@|$LDFLAGS|" \ + -e "s|@wmf_libs@||" \ + toolchain.cmake + ;; +Windows) + sed -i \ + -e "s|@cmake_system_name@|Windows|" \ + -e "s|@target@|$HOST|" \ + -e "s|@host_prefix@|$PREFIX|" \ + -e "s|@sdk_path@||" \ + -e "s|@cc@||" \ + -e "s|@cxx@||" \ + -e "s|@osx_min_version@||" \ + -e "s|@cmake_c_flags@|$CFLAGS|" \ + -e "s|@cmake_cxx_flags@|$CXXFLAGS|" \ + -e "s|@cmake_ld_flags@|$LDFLAGS|" \ + -e "s|@wmf_libs@||" \ + toolchain.cmake + ;; +*) + echo "qt setup-toolchain: unsupported CMAKE_SYSTEM_NAME=$CMAKE_SYSTEM_NAME" >&2 + exit 1 + ;; +esac diff --git a/patches/qt/toolchain.cmake b/patches/qt/toolchain.cmake new file mode 100644 index 0000000..2ee7921 --- /dev/null +++ b/patches/qt/toolchain.cmake @@ -0,0 +1,36 @@ +set(CMAKE_SYSTEM_NAME @cmake_system_name@) + +set(CMAKE_C_COMPILER @target@-gcc) +set(CMAKE_CXX_COMPILER @target@-g++) +set(CMAKE_FIND_ROOT_PATH @host_prefix@) + +set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) +set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) + +set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) + +set(CMAKE_FIND_ROOT_PATH @host_prefix@) + +if(CMAKE_SYSTEM_NAME STREQUAL "Windows") + set(CMAKE_FIND_ROOT_PATH @host_prefix@;@wmf_libs@) +endif() + +if(CMAKE_SYSTEM_NAME STREQUAL "Darwin") + set(TARGET_SYSROOT @sdk_path@) + set(CMAKE_SYSROOT ${TARGET_SYSROOT}) + set(CMAKE_OSX_SYSROOT ${TARGET_SYSROOT}) + + set(CMAKE_C_COMPILER @cc@) + set(CMAKE_CXX_COMPILER @cxx@) + + set(CMAKE_C_FLAGS "@cmake_c_flags@") + set(CMAKE_CXX_FLAGS "@cmake_cxx_flags@") + set(CMAKE_OBJC_FLAGS "@cmake_c_flags@") + set(CMAKE_OBJCXX_FLAGS "@cmake_cxx_flags@") + set(CMAKE_EXE_LINKER_FLAGS "@cmake_ld_flags@") + set(CMAKE_MODULE_LINKER_FLAGS "@cmake_ld_flags@") + set(CMAKE_SHARED_LINKER_FLAGS "@cmake_ld_flags@") + SET(CMAKE_OSX_DEPLOYMENT_TARGET "@osx_min_version@") + + set(CMAKE_INSTALL_NAME_TOOL @target@-install_name_tool) +endif() \ No newline at end of file diff --git a/patches/qt/v4l2.patch b/patches/qt/v4l2.patch new file mode 100644 index 0000000..92d4626 --- /dev/null +++ b/patches/qt/v4l2.patch @@ -0,0 +1,2602 @@ +diff --git a/src/multimedia/configure.cmake b/src/multimedia/configure.cmake +index 7bb46abc6..785fe5faa 100644 +--- a/src/multimedia/configure.cmake ++++ b/src/multimedia/configure.cmake +@@ -63,28 +63,6 @@ if(TARGET EGL::EGL) + endif() + qt_find_package(EGL PROVIDED_TARGETS EGL::EGL) + +-# If FFMPEG_DIR is specified, we require FFmpeg to be present. This makes +-# configuration problems easier to detect, and reduces risk of silent +-# fallback to native backends. +-if (DEFINED FFMPEG_DIR) +- set(ffmpeg_required REQUIRED) +-endif() +- +-qt_find_package(FFmpeg OPTIONAL_COMPONENTS AVCODEC AVFORMAT AVUTIL SWRESAMPLE SWSCALE PROVIDED_TARGETS FFmpeg::avcodec FFmpeg::avformat FFmpeg::avutil FFmpeg::swresample FFmpeg::swscale MODULE_NAME multimedia QMAKE_LIB ffmpeg ${ffmpeg_required}) +-qt_find_package_extend_sbom( +- TARGETS +- FFmpeg::avcodec +- FFmpeg::avformat +- FFmpeg::avutil +- FFmpeg::swresample +- FFmpeg::swscale +- USE_ATTRIBUTION_FILES +- ATTRIBUTION_FILE_DIR_PATHS +- # Need to pass an absolute path here, otherwise the file will be relative to the root of +- # the source tree, not the current dir, because system libraries are processed in the +- # source root directory. +- ${CMAKE_CURRENT_SOURCE_DIR}/../3rdparty/ffmpeg +-) + qt_find_package(PipeWire PROVIDED_TARGETS PipeWire::PipeWire MODULE_NAME multimedia QMAKE_LIB pipewire) + qt_find_package(VAAPI COMPONENTS VA DRM PROVIDED_TARGETS VAAPI::VAAPI MODULE_NAME multimedia QMAKE_LIB vaapi) + +@@ -236,9 +214,7 @@ qt_feature("ffmpeg" PRIVATE + LABEL "FFmpeg" + ENABLE INPUT_ffmpeg STREQUAL 'yes' + DISABLE INPUT_ffmpeg STREQUAL 'no' +- CONDITION FFmpeg_FOUND +- AND (APPLE OR WIN32 OR ANDROID OR QNX OR QT_FEATURE_pulseaudio OR QT_FEATURE_pipewire) +- AND QT_FEATURE_thread ++ CONDITION UNIX OR WIN32 + ) + + # Caveat: FEATURE_ffmpeg_stubs cannot really be used to disable stubbing, it is just used to inform +diff --git a/src/plugins/multimedia/CMakeLists.txt b/src/plugins/multimedia/CMakeLists.txt +index f42a84da5..2f529b508 100644 +--- a/src/plugins/multimedia/CMakeLists.txt ++++ b/src/plugins/multimedia/CMakeLists.txt +@@ -2,7 +2,7 @@ + # SPDX-License-Identifier: BSD-3-Clause + + if(QT_FEATURE_ffmpeg) +- add_subdirectory(ffmpeg) ++ add_subdirectory(v4l2) + endif() + if(QT_FEATURE_gstreamer) + add_subdirectory(gstreamer) +diff --git a/src/plugins/multimedia/v4l2/CMakeLists.txt b/src/plugins/multimedia/v4l2/CMakeLists.txt +new file mode 100644 +index 000000000..f20612c29 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/CMakeLists.txt +@@ -0,0 +1,24 @@ ++qt_internal_add_plugin(QFFmpegMediaPlugin ++ OUTPUT_NAME ffmpegmediaplugin ++ PLUGIN_TYPE multimedia ++ SOURCES ++ qffmpegmediametadata.cpp qffmpegmediametadata_p.h ++ qffmpegvideosink.cpp qffmpegvideosink_p.h ++ qffmpegmediaformatinfo.cpp qffmpegmediaformatinfo_p.h ++ qffmpegmediaintegration.cpp qffmpegmediaintegration_p.h ++ qffmpegimagecapture.cpp qffmpegimagecapture_p.h ++ qffmpegmediacapturesession.cpp qffmpegmediacapturesession_p.h ++ DEFINES ++ QT_COMPILING_FFMPEG ++ LIBRARIES ++ Qt::MultimediaPrivate ++ Qt::CorePrivate ++) ++ ++qt_internal_extend_target(QFFmpegMediaPlugin CONDITION QT_FEATURE_linux_v4l ++ SOURCES ++ qv4l2camera.cpp qv4l2camera_p.h ++ qv4l2filedescriptor.cpp qv4l2filedescriptor_p.h ++ qv4l2memorytransfer.cpp qv4l2memorytransfer_p.h ++ qv4l2cameradevices.cpp qv4l2cameradevices_p.h ++) +diff --git a/src/plugins/multimedia/v4l2/ffmpeg.json b/src/plugins/multimedia/v4l2/ffmpeg.json +new file mode 100644 +index 000000000..d8e7e4456 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/ffmpeg.json +@@ -0,0 +1,3 @@ ++{ ++ "Keys": [ "ffmpeg" ] ++} +diff --git a/src/plugins/multimedia/v4l2/qffmpegimagecapture.cpp b/src/plugins/multimedia/v4l2/qffmpegimagecapture.cpp +new file mode 100644 +index 000000000..9ee4e1db8 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegimagecapture.cpp +@@ -0,0 +1,269 @@ ++// Copyright (C) 2016 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include "qffmpegimagecapture_p.h" ++#include ++#include ++#include ++#include ++#include ++#include ++ ++#include ++#include ++#include ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++Q_LOGGING_CATEGORY(qLcImageCapture, "qt.multimedia.imageCapture") ++ ++QFFmpegImageCapture::QFFmpegImageCapture(QImageCapture *parent) ++ : QPlatformImageCapture(parent) ++{ ++} ++ ++QFFmpegImageCapture::~QFFmpegImageCapture() ++{ ++} ++ ++bool QFFmpegImageCapture::isReadyForCapture() const ++{ ++ return m_isReadyForCapture; ++} ++ ++static const char *extensionForFormat(QImageCapture::FileFormat format) ++{ ++ const char *fmt = "jpg"; ++ switch (format) { ++ case QImageCapture::UnspecifiedFormat: ++ case QImageCapture::JPEG: ++ fmt = "jpg"; ++ break; ++ case QImageCapture::PNG: ++ fmt = "png"; ++ break; ++ case QImageCapture::WebP: ++ fmt = "webp"; ++ break; ++ case QImageCapture::Tiff: ++ fmt = "tiff"; ++ break; ++ } ++ return fmt; ++} ++ ++int QFFmpegImageCapture::capture(const QString &fileName) ++{ ++ QString path = QMediaStorageLocation::generateFileName(fileName, QStandardPaths::PicturesLocation, QLatin1String(extensionForFormat(m_settings.format()))); ++ return doCapture(path); ++} ++ ++int QFFmpegImageCapture::captureToBuffer() ++{ ++ return doCapture(QString()); ++} ++ ++int QFFmpegImageCapture::doCapture(const QString &fileName) ++{ ++ qCDebug(qLcImageCapture) << "do capture"; ++ if (!m_session) { ++ //emit error in the next event loop, ++ //so application can associate it with returned request id. ++ QMetaObject::invokeMethod(this, "error", Qt::QueuedConnection, ++ Q_ARG(int, -1), ++ Q_ARG(int, QImageCapture::ResourceError), ++ Q_ARG(QString, QPlatformImageCapture::msgImageCaptureNotSet())); ++ ++ qCDebug(qLcImageCapture) << "error 1"; ++ return -1; ++ } ++ if (!m_camera) { ++ //emit error in the next event loop, ++ //so application can associate it with returned request id. ++ QMetaObject::invokeMethod(this, "error", Qt::QueuedConnection, ++ Q_ARG(int, -1), ++ Q_ARG(int, QImageCapture::ResourceError), ++ Q_ARG(QString,tr("No camera available."))); ++ ++ qCDebug(qLcImageCapture) << "error 2"; ++ return -1; ++ } ++ if (passImage) { ++ //emit error in the next event loop, ++ //so application can associate it with returned request id. ++ QMetaObject::invokeMethod(this, "error", Qt::QueuedConnection, ++ Q_ARG(int, -1), ++ Q_ARG(int, QImageCapture::NotReadyError), ++ Q_ARG(QString, QPlatformImageCapture::msgCameraNotReady())); ++ ++ qCDebug(qLcImageCapture) << "error 3"; ++ return -1; ++ } ++ m_lastId++; ++ ++ pendingImages.enqueue({m_lastId, fileName, QMediaMetaData{}}); ++ // let one image pass the pipeline ++ passImage = true; ++ ++ updateReadyForCapture(); ++ return m_lastId; ++} ++ ++void QFFmpegImageCapture::setCaptureSession(QPlatformMediaCaptureSession *session) ++{ ++ auto *captureSession = static_cast(session); ++ if (m_session == captureSession) ++ return; ++ ++ if (m_session) { ++ disconnect(m_session, nullptr, this, nullptr); ++ m_lastId = 0; ++ pendingImages.clear(); ++ passImage = false; ++ cameraActive = false; ++ } ++ ++ m_session = captureSession; ++ if (m_session) ++ connect(m_session, &QPlatformMediaCaptureSession::cameraChanged, this, &QFFmpegImageCapture::onCameraChanged); ++ ++ onCameraChanged(); ++ updateReadyForCapture(); ++} ++ ++void QFFmpegImageCapture::updateReadyForCapture() ++{ ++ bool ready = m_session && !passImage && cameraActive; ++ if (ready == m_isReadyForCapture) ++ return; ++ m_isReadyForCapture = ready; ++ emit readyForCaptureChanged(m_isReadyForCapture); ++} ++ ++void QFFmpegImageCapture::cameraActiveChanged(bool active) ++{ ++ qCDebug(qLcImageCapture) << "cameraActiveChanged" << cameraActive << active; ++ if (cameraActive == active) ++ return; ++ cameraActive = active; ++ qCDebug(qLcImageCapture) << "isReady" << isReadyForCapture(); ++ updateReadyForCapture(); ++} ++ ++void QFFmpegImageCapture::newVideoFrame(const QVideoFrame &frame) ++{ ++ if (!passImage) ++ return; ++ ++ passImage = false; ++ Q_ASSERT(!pendingImages.isEmpty()); ++ auto pending = pendingImages.dequeue(); ++ ++ emit imageExposed(pending.id); ++ // ### Add metadata from the AVFrame ++ emit imageMetadataAvailable(pending.id, pending.metaData); ++ emit imageAvailable(pending.id, frame); ++ QImage image = frame.toImage(); ++ if (m_settings.resolution().isValid() && m_settings.resolution() != image.size()) ++ image = image.scaled(m_settings.resolution()); ++ ++ emit imageCaptured(pending.id, image); ++ if (!pending.filename.isEmpty()) { ++ const char *fmt = nullptr; ++ switch (m_settings.format()) { ++ case QImageCapture::UnspecifiedFormat: ++ case QImageCapture::JPEG: ++ fmt = "jpeg"; ++ break; ++ case QImageCapture::PNG: ++ fmt = "png"; ++ break; ++ case QImageCapture::WebP: ++ fmt = "webp"; ++ break; ++ case QImageCapture::Tiff: ++ fmt = "tiff"; ++ break; ++ } ++ int quality = -1; ++ switch (m_settings.quality()) { ++ case QImageCapture::VeryLowQuality: ++ quality = 25; ++ break; ++ case QImageCapture::LowQuality: ++ quality = 50; ++ break; ++ case QImageCapture::NormalQuality: ++ break; ++ case QImageCapture::HighQuality: ++ quality = 75; ++ break; ++ case QImageCapture::VeryHighQuality: ++ quality = 99; ++ break; ++ } ++ ++ QImageWriter writer(pending.filename, fmt); ++ writer.setQuality(quality); ++ ++ if (writer.write(image)) { ++ emit imageSaved(pending.id, pending.filename); ++ } else { ++ QImageCapture::Error err = QImageCapture::ResourceError; ++ if (writer.error() == QImageWriter::UnsupportedFormatError) ++ err = QImageCapture::FormatError; ++ emit error(pending.id, err, writer.errorString()); ++ } ++ } ++ updateReadyForCapture(); ++} ++ ++void QFFmpegImageCapture::onCameraChanged() ++{ ++ auto *camera = m_session ? m_session->camera() : nullptr; ++ if (m_camera == camera) ++ return; ++ ++ if (m_camera) ++ disconnect(m_camera); ++ ++ m_camera = camera; ++ ++ if (camera) { ++ cameraActiveChanged(camera->isActive()); ++ connect(camera, &QPlatformCamera::activeChanged, this, &QFFmpegImageCapture::cameraActiveChanged); ++ connect(camera, &QPlatformCamera::newVideoFrame, this, &QFFmpegImageCapture::newVideoFrame); ++ } else { ++ cameraActiveChanged(false); ++ } ++} ++ ++QImageEncoderSettings QFFmpegImageCapture::imageSettings() const ++{ ++ return m_settings; ++} ++ ++void QFFmpegImageCapture::setImageSettings(const QImageEncoderSettings &settings) ++{ ++ auto s = settings; ++ const auto supportedFormats = QPlatformMediaIntegration::instance()->formatInfo()->imageFormats; ++ if (supportedFormats.isEmpty()) { ++ emit error(-1, QImageCapture::FormatError, "No image formats supported, can't capture."); ++ return; ++ } ++ if (s.format() == QImageCapture::UnspecifiedFormat) { ++ auto f = QImageCapture::JPEG; ++ if (!supportedFormats.contains(f)) ++ f = supportedFormats.first(); ++ s.setFormat(f); ++ } else if (!supportedFormats.contains(settings.format())) { ++ emit error(-1, QImageCapture::FormatError, "Image format not supported."); ++ return; ++ } ++ ++ m_settings = settings; ++} ++ ++QT_END_NAMESPACE +diff --git a/src/plugins/multimedia/v4l2/qffmpegimagecapture_p.h b/src/plugins/multimedia/v4l2/qffmpegimagecapture_p.h +new file mode 100644 +index 000000000..de54fe7cb +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegimagecapture_p.h +@@ -0,0 +1,72 @@ ++// Copyright (C) 2016 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++ ++#ifndef QFFMPEGIMAGECAPTURE_H ++#define QFFMPEGIMAGECAPTURE_H ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++#include ++#include "qffmpegmediacapturesession_p.h" ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++class QFFmpegImageCapture : public QPlatformImageCapture ++ ++{ ++ Q_OBJECT ++public: ++ QFFmpegImageCapture(QImageCapture *parent); ++ virtual ~QFFmpegImageCapture(); ++ ++ bool isReadyForCapture() const override; ++ int capture(const QString &fileName) override; ++ int captureToBuffer() override; ++ ++ QImageEncoderSettings imageSettings() const override; ++ void setImageSettings(const QImageEncoderSettings &settings) override; ++ ++ void setCaptureSession(QPlatformMediaCaptureSession *session); ++ ++ void updateReadyForCapture(); ++ ++public Q_SLOTS: ++ void cameraActiveChanged(bool active); ++ void newVideoFrame(const QVideoFrame &frame); ++ void onCameraChanged(); ++ ++private: ++ int doCapture(const QString &fileName); ++ ++ QFFmpegMediaCaptureSession *m_session = nullptr; ++ int m_lastId = 0; ++ QImageEncoderSettings m_settings; ++ QPlatformCamera *m_camera = nullptr; ++ ++ struct PendingImage { ++ int id; ++ QString filename; ++ QMediaMetaData metaData; ++ }; ++ ++ QQueue pendingImages; ++ bool passImage = false; ++ bool cameraActive = false; ++ bool m_isReadyForCapture = false; ++}; ++ ++QT_END_NAMESPACE ++ ++#endif // QGSTREAMERCAPTURECORNTROL_H +diff --git a/src/plugins/multimedia/v4l2/qffmpegmediacapturesession.cpp b/src/plugins/multimedia/v4l2/qffmpegmediacapturesession.cpp +new file mode 100644 +index 000000000..b6865761c +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegmediacapturesession.cpp +@@ -0,0 +1,114 @@ ++// Copyright (C) 2016 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include "qffmpegmediacapturesession_p.h" ++ ++#include "private/qplatformaudioinput_p.h" ++#include "private/qplatformaudiooutput_p.h" ++#include "qffmpegimagecapture_p.h" ++#include "private/qplatformcamera_p.h" ++#include "qvideosink.h" ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++Q_LOGGING_CATEGORY(qLcMediaCapture, "qt.multimedia.capture") ++ ++ ++ ++QFFmpegMediaCaptureSession::QFFmpegMediaCaptureSession() ++{ ++} ++ ++QFFmpegMediaCaptureSession::~QFFmpegMediaCaptureSession() ++{ ++} ++ ++QPlatformCamera *QFFmpegMediaCaptureSession::camera() ++{ ++ return m_camera; ++} ++ ++void QFFmpegMediaCaptureSession::setCamera(QPlatformCamera *camera) ++{ ++ if (m_camera == camera) ++ return; ++ if (m_camera) { ++ m_camera->disconnect(this); ++ m_camera->setCaptureSession(nullptr); ++ } ++ ++ m_camera = camera; ++ ++ if (m_camera) { ++ connect(m_camera, &QPlatformCamera::newVideoFrame, this, &QFFmpegMediaCaptureSession::newVideoFrame); ++ m_camera->setCaptureSession(this); ++ } ++ ++ emit cameraChanged(); ++} ++ ++QPlatformImageCapture *QFFmpegMediaCaptureSession::imageCapture() ++{ ++ return m_imageCapture; ++} ++ ++void QFFmpegMediaCaptureSession::setImageCapture(QPlatformImageCapture *imageCapture) ++{ ++ if (m_imageCapture == imageCapture) ++ return; ++ ++ if (m_imageCapture) ++ m_imageCapture->setCaptureSession(nullptr); ++ ++ m_imageCapture = static_cast(imageCapture); ++ ++ if (m_imageCapture) ++ m_imageCapture->setCaptureSession(this); ++ ++ emit imageCaptureChanged(); ++} ++ ++void QFFmpegMediaCaptureSession::setMediaRecorder(QPlatformMediaRecorder *recorder) ++{ ++ return; ++} ++ ++QPlatformMediaRecorder *QFFmpegMediaCaptureSession::mediaRecorder() ++{ ++ return nullptr; ++} ++ ++void QFFmpegMediaCaptureSession::setAudioInput(QPlatformAudioInput *input) ++{ ++ if (m_audioInput == input) ++ return; ++ ++ m_audioInput = input; ++} ++ ++void QFFmpegMediaCaptureSession::setVideoPreview(QVideoSink *sink) ++{ ++ if (m_videoSink == sink) ++ return; ++ ++ m_videoSink = sink; ++} ++ ++void QFFmpegMediaCaptureSession::setAudioOutput(QPlatformAudioOutput *output) ++{ ++ if (m_audioOutput == output) ++ return; ++ ++ m_audioOutput = output; ++} ++ ++void QFFmpegMediaCaptureSession::newVideoFrame(const QVideoFrame &frame) ++{ ++ if (m_videoSink) ++ m_videoSink->setVideoFrame(frame); ++} ++ ++ ++QT_END_NAMESPACE +diff --git a/src/plugins/multimedia/v4l2/qffmpegmediacapturesession_p.h b/src/plugins/multimedia/v4l2/qffmpegmediacapturesession_p.h +new file mode 100644 +index 000000000..858a537cc +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegmediacapturesession_p.h +@@ -0,0 +1,63 @@ ++// Copyright (C) 2016 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QFFMPEGMEDIACAPTURESESSION_H ++#define QFFMPEGMEDIACAPTURESESSION_H ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++#include ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++class QFFmpegMediaRecorder; ++class QFFmpegImageCapture; ++class QVideoFrame; ++ ++class QFFmpegMediaCaptureSession : public QPlatformMediaCaptureSession ++{ ++ Q_OBJECT ++ ++public: ++ QFFmpegMediaCaptureSession(); ++ virtual ~QFFmpegMediaCaptureSession(); ++ ++ QPlatformCamera *camera() override; ++ void setCamera(QPlatformCamera *camera) override; ++ ++ QPlatformImageCapture *imageCapture() override; ++ void setImageCapture(QPlatformImageCapture *imageCapture) override; ++ ++ QPlatformMediaRecorder *mediaRecorder() override; ++ void setMediaRecorder(QPlatformMediaRecorder *recorder) override; ++ ++ void setAudioInput(QPlatformAudioInput *input) override; ++ QPlatformAudioInput *audioInput() { return m_audioInput; } ++ ++ void setVideoPreview(QVideoSink *sink) override; ++ void setAudioOutput(QPlatformAudioOutput *output) override; ++ ++public Q_SLOTS: ++ void newVideoFrame(const QVideoFrame &frame); ++ ++private: ++ QPlatformCamera *m_camera = nullptr; ++ QPlatformAudioInput *m_audioInput = nullptr; ++ QFFmpegImageCapture *m_imageCapture = nullptr; ++ QPlatformAudioOutput *m_audioOutput = nullptr; ++ QVideoSink *m_videoSink = nullptr; ++}; ++ ++QT_END_NAMESPACE ++ ++#endif // QGSTREAMERCAPTURESERVICE_H +diff --git a/src/plugins/multimedia/v4l2/qffmpegmediaformatinfo.cpp b/src/plugins/multimedia/v4l2/qffmpegmediaformatinfo.cpp +new file mode 100644 +index 000000000..00b838d50 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegmediaformatinfo.cpp +@@ -0,0 +1,32 @@ ++// Copyright (C) 2021 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include "qffmpegmediaformatinfo_p.h" ++#include "qaudioformat.h" ++#include "qimagewriter.h" ++ ++QT_BEGIN_NAMESPACE ++ ++QFFmpegMediaFormatInfo::QFFmpegMediaFormatInfo() ++{ ++ // Add image formats we support. We currently simply use Qt's built-in image write ++ // to save images. That doesn't give us HDR support or support for larger bit depths, ++ // but most cameras can currently not generate those anyway. ++ const auto imgFormats = QImageWriter::supportedImageFormats(); ++ for (const auto &f : imgFormats) { ++ if (f == "png") ++ imageFormats.append(QImageCapture::PNG); ++ else if (f == "jpeg") ++ imageFormats.append(QImageCapture::JPEG); ++ else if (f == "tiff") ++ imageFormats.append(QImageCapture::Tiff); ++ else if (f == "webp") ++ imageFormats.append(QImageCapture::WebP); ++ } ++ ++} ++ ++QFFmpegMediaFormatInfo::~QFFmpegMediaFormatInfo() = default; ++ ++ ++QT_END_NAMESPACE +diff --git a/src/plugins/multimedia/v4l2/qffmpegmediaformatinfo_p.h b/src/plugins/multimedia/v4l2/qffmpegmediaformatinfo_p.h +new file mode 100644 +index 000000000..e34005bbf +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegmediaformatinfo_p.h +@@ -0,0 +1,34 @@ ++// Copyright (C) 2021 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QFFmpegMediaFormatInfo_H ++#define QFFmpegMediaFormatInfo_H ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++#include ++#include ++#include ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++class QFFmpegMediaFormatInfo : public QPlatformMediaFormatInfo ++{ ++public: ++ QFFmpegMediaFormatInfo(); ++ ~QFFmpegMediaFormatInfo(); ++}; ++ ++QT_END_NAMESPACE ++ ++#endif +diff --git a/src/plugins/multimedia/v4l2/qffmpegmediaintegration.cpp b/src/plugins/multimedia/v4l2/qffmpegmediaintegration.cpp +new file mode 100644 +index 000000000..90f338172 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegmediaintegration.cpp +@@ -0,0 +1,131 @@ ++// Copyright (C) 2021 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include ++#include ++#include "qffmpegmediaintegration_p.h" ++#include "qffmpegmediaformatinfo_p.h" ++#include "qffmpegvideosink_p.h" ++#include "qffmpegmediacapturesession_p.h" ++#include "qffmpegimagecapture_p.h" ++ ++#ifdef Q_OS_MACOS ++#include ++#endif ++ ++#ifdef Q_OS_DARWIN ++#include "qavfcamera_p.h" ++#elif defined(Q_OS_WINDOWS) ++#include "../windows/mediacapture/qwindowscamera_p.h" ++#include "../windows/qwindowsvideodevices_p.h" ++#endif ++ ++#if QT_CONFIG(linux_v4l) ++#include "qv4l2camera_p.h" ++#include "qv4l2cameradevices_p.h" ++#endif ++ ++QT_BEGIN_NAMESPACE ++ ++class QFFmpegMediaPlugin : public QPlatformMediaPlugin ++{ ++ Q_OBJECT ++ Q_PLUGIN_METADATA(IID QPlatformMediaPlugin_iid FILE "ffmpeg.json") ++ ++public: ++ QFFmpegMediaPlugin() ++ : QPlatformMediaPlugin() ++ {} ++ ++ QPlatformMediaIntegration* create(const QString &name) override ++ { ++ if (name == QLatin1String("ffmpeg")) ++ return new QFFmpegMediaIntegration; ++ return nullptr; ++ } ++}; ++ ++QFFmpegMediaIntegration::QFFmpegMediaIntegration() ++ : QPlatformMediaIntegration(QLatin1String("ffmpeg")) ++{ ++#ifndef QT_NO_DEBUG ++ qDebug() << "Available HW decoding frameworks:"; ++ AVHWDeviceType type = AV_HWDEVICE_TYPE_NONE; ++ while ((type = av_hwdevice_iterate_types(type)) != AV_HWDEVICE_TYPE_NONE) ++ qDebug() << " " << av_hwdevice_get_type_name(type); ++#endif ++} ++ ++QPlatformMediaFormatInfo *QFFmpegMediaIntegration::createFormatInfo() ++{ ++ return new QFFmpegMediaFormatInfo(); ++} ++ ++QPlatformVideoDevices *QFFmpegMediaIntegration::createVideoDevices() ++{ ++#if defined(Q_OS_ANDROID) ++ return new QAndroidVideoDevices(this); ++#elif QT_CONFIG(linux_v4l) ++ return new QV4L2CameraDevices(this); ++#elif defined Q_OS_DARWIN ++ return new QAVFVideoDevices(this); ++#elif defined(Q_OS_WINDOWS) ++ return new QWindowsVideoDevices(this); ++#else ++ return nullptr; ++#endif ++} ++ ++q23::expected QFFmpegMediaIntegration::createCaptureSession() ++{ ++ return new QFFmpegMediaCaptureSession(); ++} ++ ++q23::expected QFFmpegMediaIntegration::createCamera(QCamera *camera) ++{ ++#ifdef Q_OS_DARWIN ++ return new QAVFCamera(camera); ++#elif QT_CONFIG(linux_v4l) ++ return new QV4L2Camera(camera); ++#elif defined(Q_OS_WINDOWS) ++ return new QWindowsCamera(camera); ++#else ++ Q_UNUSED(camera); ++ return nullptr;//new QFFmpegCamera(camera); ++#endif ++} ++ ++q23::expected QFFmpegMediaIntegration::createImageCapture(QImageCapture *imageCapture) ++{ ++ return new QFFmpegImageCapture(imageCapture); ++} ++ ++q23::expected QFFmpegMediaIntegration::createVideoSink(QVideoSink *sink) ++{ ++ return new QFFmpegVideoSink(sink); ++} ++ ++#ifdef Q_OS_ANDROID ++Q_DECL_EXPORT jint JNICALL JNI_OnLoad(JavaVM *vm, void * /*reserved*/) ++{ ++ static bool initialized = false; ++ if (initialized) ++ return JNI_VERSION_1_6; ++ initialized = true; ++ ++ QT_USE_NAMESPACE ++ void *environment; ++ if (vm->GetEnv(&environment, JNI_VERSION_1_6)) ++ return JNI_ERR; ++ ++ // setting our javavm into ffmpeg. ++ if (av_jni_set_java_vm(vm, nullptr)) ++ return JNI_ERR; ++ ++ return JNI_VERSION_1_6; ++} ++#endif ++ ++QT_END_NAMESPACE ++ ++#include "qffmpegmediaintegration.moc" +diff --git a/src/plugins/multimedia/v4l2/qffmpegmediaintegration_p.h b/src/plugins/multimedia/v4l2/qffmpegmediaintegration_p.h +new file mode 100644 +index 000000000..70d525df2 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegmediaintegration_p.h +@@ -0,0 +1,47 @@ ++// Copyright (C) 2021 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QGSTREAMERINTEGRATION_H ++#define QGSTREAMERINTEGRATION_H ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++class QFFmpegMediaFormatInfo; ++ ++class QFFmpegMediaIntegration : public QPlatformMediaIntegration ++{ ++public: ++ QFFmpegMediaIntegration(); ++ ++ static QFFmpegMediaIntegration *instance() ++ { ++ return static_cast(QPlatformMediaIntegration::instance()); ++ } ++ ++ q23::expected createCaptureSession() override; ++ q23::expected createCamera(QCamera *) override; ++ q23::expected createImageCapture(QImageCapture *) override; ++ q23::expected createVideoSink(QVideoSink *sink) override; ++ ++protected: ++ QPlatformMediaFormatInfo *createFormatInfo() override; ++ ++ QPlatformVideoDevices *createVideoDevices() override; ++}; ++ ++QT_END_NAMESPACE ++ ++#endif +diff --git a/src/plugins/multimedia/v4l2/qffmpegmediametadata.cpp b/src/plugins/multimedia/v4l2/qffmpegmediametadata.cpp +new file mode 100644 +index 000000000..dda577d44 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegmediametadata.cpp +@@ -0,0 +1,72 @@ ++// Copyright (C) 2022 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include "qffmpegmediametadata_p.h" ++#include ++#include ++#include ++#include ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++namespace { ++ ++struct { ++ const char *tag; ++ QMediaMetaData::Key key; ++} ffmpegTagToMetaDataKey[] = { ++ { "title", QMediaMetaData::Title }, ++ { "comment", QMediaMetaData::Comment }, ++ { "description", QMediaMetaData::Description }, ++ { "genre", QMediaMetaData::Genre }, ++ { "date", QMediaMetaData::Date }, ++ { "year", QMediaMetaData::Date }, ++ { "creation_time", QMediaMetaData::Date }, ++ ++ { "language", QMediaMetaData::Language }, ++ ++ { "copyright", QMediaMetaData::Copyright }, ++ ++ // Music ++ { "album", QMediaMetaData::AlbumTitle }, ++ { "album_artist", QMediaMetaData::AlbumArtist }, ++ { "artist", QMediaMetaData::ContributingArtist }, ++ { "track", QMediaMetaData::TrackNumber }, ++ ++ // Movie ++ { "performer", QMediaMetaData::LeadPerformer }, ++ ++ { nullptr, QMediaMetaData::Title } ++}; ++ ++} ++ ++static QMediaMetaData::Key tagToKey(const char *tag) ++{ ++ auto *map = ffmpegTagToMetaDataKey; ++ while (map->tag) { ++ if (!strcmp(map->tag, tag)) ++ return map->key; ++ ++map; ++ } ++ return QMediaMetaData::Key(-1); ++} ++ ++static const char *keyToTag(QMediaMetaData::Key key) ++{ ++ auto *map = ffmpegTagToMetaDataKey; ++ while (map->tag) { ++ if (map->key == key) ++ return map->tag; ++ ++map; ++ } ++ return nullptr; ++} ++ ++QByteArray QFFmpegMetaData::value(const QMediaMetaData &metaData, QMediaMetaData::Key key) ++{ ++ return {}; ++} ++ ++QT_END_NAMESPACE +diff --git a/src/plugins/multimedia/v4l2/qffmpegmediametadata_p.h b/src/plugins/multimedia/v4l2/qffmpegmediametadata_p.h +new file mode 100644 +index 000000000..95b069b64 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegmediametadata_p.h +@@ -0,0 +1,30 @@ ++// Copyright (C) 2022 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QFFMPEGMEDIAMETADATA_H ++#define QFFMPEGMEDIAMETADATA_H ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++class QFFmpegMetaData : public QMediaMetaData ++{ ++public: ++ static QByteArray value(const QMediaMetaData &metaData, QMediaMetaData::Key key); ++}; ++ ++QT_END_NAMESPACE ++ ++#endif // QFFMPEGMEDIAMETADATA_H +diff --git a/src/plugins/multimedia/v4l2/qffmpegvideosink.cpp b/src/plugins/multimedia/v4l2/qffmpegvideosink.cpp +new file mode 100644 +index 000000000..128ce2f56 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegvideosink.cpp +@@ -0,0 +1,17 @@ ++// Copyright (C) 2021 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++QFFmpegVideoSink::QFFmpegVideoSink(QVideoSink *sink) ++ : QPlatformVideoSink(sink) ++{ ++} ++ ++void QFFmpegVideoSink::onVideoFrameChanged(const QVideoFrame &frame) ++{ ++ ++} ++ ++QT_END_NAMESPACE +diff --git a/src/plugins/multimedia/v4l2/qffmpegvideosink_p.h b/src/plugins/multimedia/v4l2/qffmpegvideosink_p.h +new file mode 100644 +index 000000000..9eac79129 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qffmpegvideosink_p.h +@@ -0,0 +1,40 @@ ++// Copyright (C) 2021 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QFFMPEGVIDEOSINK_H ++#define QFFMPEGVIDEOSINK_H ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++#include ++//#include ++ ++QT_BEGIN_NAMESPACE ++ ++// Required for QDoc workaround ++class QString; ++ ++class QFFmpegVideoSink : public QPlatformVideoSink ++{ ++ Q_OBJECT ++ ++public: ++ QFFmpegVideoSink(QVideoSink *sink); ++ ++protected: ++ void onVideoFrameChanged(const QVideoFrame &frame) override; ++}; ++ ++QT_END_NAMESPACE ++ ++ ++#endif +diff --git a/src/plugins/multimedia/v4l2/qv4l2camera.cpp b/src/plugins/multimedia/v4l2/qv4l2camera.cpp +new file mode 100644 +index 000000000..1ba05364d +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qv4l2camera.cpp +@@ -0,0 +1,707 @@ ++// Copyright (C) 2021 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include "qv4l2camera_p.h" ++#include "qv4l2filedescriptor_p.h" ++#include "qv4l2memorytransfer_p.h" ++ ++#include ++#include ++#include ++#include ++ ++#include ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++static Q_LOGGING_CATEGORY(qLcV4L2Camera, "qt.multimedia.ffmpeg.v4l2camera"); ++ ++static const struct { ++ QVideoFrameFormat::PixelFormat fmt; ++ uint32_t v4l2Format; ++} formatMap[] = { ++ // ### How do we handle V4L2_PIX_FMT_H264 and V4L2_PIX_FMT_MPEG4? ++ { QVideoFrameFormat::Format_YUV420P, V4L2_PIX_FMT_YUV420 }, ++ { QVideoFrameFormat::Format_YUV422P, V4L2_PIX_FMT_YUV422P }, ++ { QVideoFrameFormat::Format_YUYV, V4L2_PIX_FMT_YUYV }, ++ { QVideoFrameFormat::Format_UYVY, V4L2_PIX_FMT_UYVY }, ++ { QVideoFrameFormat::Format_XBGR8888, V4L2_PIX_FMT_XBGR32 }, ++ { QVideoFrameFormat::Format_XRGB8888, V4L2_PIX_FMT_XRGB32 }, ++ { QVideoFrameFormat::Format_ABGR8888, V4L2_PIX_FMT_ABGR32 }, ++ { QVideoFrameFormat::Format_ARGB8888, V4L2_PIX_FMT_ARGB32 }, ++ { QVideoFrameFormat::Format_BGRX8888, V4L2_PIX_FMT_BGR32 }, ++ { QVideoFrameFormat::Format_RGBX8888, V4L2_PIX_FMT_RGB32 }, ++ { QVideoFrameFormat::Format_BGRA8888, V4L2_PIX_FMT_BGRA32 }, ++ { QVideoFrameFormat::Format_RGBA8888, V4L2_PIX_FMT_RGBA32 }, ++ { QVideoFrameFormat::Format_Y8, V4L2_PIX_FMT_GREY }, ++ { QVideoFrameFormat::Format_Y16, V4L2_PIX_FMT_Y16 }, ++ { QVideoFrameFormat::Format_NV12, V4L2_PIX_FMT_NV12 }, ++ { QVideoFrameFormat::Format_NV21, V4L2_PIX_FMT_NV21 }, ++ { QVideoFrameFormat::Format_Jpeg, V4L2_PIX_FMT_MJPEG }, ++ { QVideoFrameFormat::Format_Jpeg, V4L2_PIX_FMT_JPEG }, ++ { QVideoFrameFormat::Format_Invalid, 0 }, ++}; ++ ++QVideoFrameFormat::PixelFormat formatForV4L2Format(uint32_t v4l2Format) ++{ ++ auto *f = formatMap; ++ while (f->v4l2Format) { ++ if (f->v4l2Format == v4l2Format) ++ return f->fmt; ++ ++f; ++ } ++ return QVideoFrameFormat::Format_Invalid; ++} ++ ++uint32_t v4l2FormatForPixelFormat(QVideoFrameFormat::PixelFormat format) ++{ ++ auto *f = formatMap; ++ while (f->v4l2Format) { ++ if (f->fmt == format) ++ return f->v4l2Format; ++ ++f; ++ } ++ return 0; ++} ++ ++QV4L2Camera::QV4L2Camera(QCamera *camera) ++ : QPlatformCamera(camera) ++{ ++} ++ ++QV4L2Camera::~QV4L2Camera() ++{ ++ stopCapturing(); ++ closeV4L2Fd(); ++} ++ ++bool QV4L2Camera::isActive() const ++{ ++ return m_active; ++} ++ ++void QV4L2Camera::setActive(bool active) ++{ ++ if (m_active == active) ++ return; ++ if (m_cameraDevice.isNull() && active) ++ return; ++ ++ if (m_cameraFormat.isNull()) ++ resolveCameraFormat({}); ++ ++ m_active = active; ++ if (m_active) ++ startCapturing(); ++ else ++ stopCapturing(); ++ ++ emit newVideoFrame({}); ++ ++ emit activeChanged(active); ++} ++ ++void QV4L2Camera::setCamera(const QCameraDevice &camera) ++{ ++ if (m_cameraDevice == camera) ++ return; ++ ++ stopCapturing(); ++ closeV4L2Fd(); ++ ++ m_cameraDevice = camera; ++ resolveCameraFormat({}); ++ ++ initV4L2Controls(); ++ ++ if (m_active) ++ startCapturing(); ++} ++ ++bool QV4L2Camera::setCameraFormat(const QCameraFormat &format) ++{ ++ if (!format.isNull() && !m_cameraDevice.videoFormats().contains(format)) ++ return false; ++ ++ if (!resolveCameraFormat(format)) ++ return true; ++ ++ if (m_active) { ++ stopCapturing(); ++ closeV4L2Fd(); ++ ++ initV4L2Controls(); ++ startCapturing(); ++ } ++ ++ return true; ++} ++ ++bool QV4L2Camera::resolveCameraFormat(const QCameraFormat &format) ++{ ++ auto fmt = format; ++ if (fmt.isNull()) ++ fmt = findBestCameraFormat(m_cameraDevice); ++ ++ if (fmt == m_cameraFormat) ++ return false; ++ ++ m_cameraFormat = fmt; ++ return true; ++} ++ ++void QV4L2Camera::setFocusMode(QCamera::FocusMode mode) ++{ ++ if (mode == focusMode()) ++ return; ++ ++ bool focusDist = supportedFeatures() & QCamera::Feature::FocusDistance; ++ if (!focusDist && !m_v4l2Info.rangedFocus) ++ return; ++ ++ switch (mode) { ++ default: ++ case QCamera::FocusModeAuto: ++ setV4L2Parameter(V4L2_CID_FOCUS_AUTO, 1); ++ if (m_v4l2Info.rangedFocus) ++ setV4L2Parameter(V4L2_CID_AUTO_FOCUS_RANGE, V4L2_AUTO_FOCUS_RANGE_AUTO); ++ break; ++ case QCamera::FocusModeAutoNear: ++ setV4L2Parameter(V4L2_CID_FOCUS_AUTO, 1); ++ if (m_v4l2Info.rangedFocus) ++ setV4L2Parameter(V4L2_CID_AUTO_FOCUS_RANGE, V4L2_AUTO_FOCUS_RANGE_MACRO); ++ else if (focusDist) ++ setV4L2Parameter(V4L2_CID_FOCUS_ABSOLUTE, m_v4l2Info.minFocus); ++ break; ++ case QCamera::FocusModeAutoFar: ++ setV4L2Parameter(V4L2_CID_FOCUS_AUTO, 1); ++ if (m_v4l2Info.rangedFocus) ++ setV4L2Parameter(V4L2_CID_AUTO_FOCUS_RANGE, V4L2_AUTO_FOCUS_RANGE_INFINITY); ++ break; ++ case QCamera::FocusModeInfinity: ++ setV4L2Parameter(V4L2_CID_FOCUS_AUTO, 0); ++ setV4L2Parameter(V4L2_CID_FOCUS_ABSOLUTE, m_v4l2Info.maxFocus); ++ break; ++ case QCamera::FocusModeManual: ++ setV4L2Parameter(V4L2_CID_FOCUS_AUTO, 0); ++ setFocusDistance(focusDistance()); ++ break; ++ } ++ focusModeChanged(mode); ++} ++ ++void QV4L2Camera::setFocusDistance(float d) ++{ ++ int distance = m_v4l2Info.minFocus + int((m_v4l2Info.maxFocus - m_v4l2Info.minFocus) * d); ++ setV4L2Parameter(V4L2_CID_FOCUS_ABSOLUTE, distance); ++ focusDistanceChanged(d); ++} ++ ++void QV4L2Camera::zoomTo(float factor, float) ++{ ++ if (m_v4l2Info.maxZoom == m_v4l2Info.minZoom) ++ return; ++ factor = qBound(1., factor, 2.); ++ int zoom = m_v4l2Info.minZoom + (factor - 1.) * (m_v4l2Info.maxZoom - m_v4l2Info.minZoom); ++ setV4L2Parameter(V4L2_CID_ZOOM_ABSOLUTE, zoom); ++ zoomFactorChanged(factor); ++} ++ ++bool QV4L2Camera::isFocusModeSupported(QCamera::FocusMode mode) const ++{ ++ if (supportedFeatures() & QCamera::Feature::FocusDistance && ++ (mode == QCamera::FocusModeManual || mode == QCamera::FocusModeAutoNear || mode == QCamera::FocusModeInfinity)) ++ return true; ++ ++ return mode == QCamera::FocusModeAuto; ++} ++ ++void QV4L2Camera::setFlashMode(QCamera::FlashMode mode) ++{ ++ if (!m_v4l2Info.flashSupported || mode == QCamera::FlashOn) ++ return; ++ setV4L2Parameter(V4L2_CID_FLASH_LED_MODE, mode == QCamera::FlashAuto ? V4L2_FLASH_LED_MODE_FLASH : V4L2_FLASH_LED_MODE_NONE); ++ flashModeChanged(mode); ++} ++ ++bool QV4L2Camera::isFlashModeSupported(QCamera::FlashMode mode) const ++{ ++ if (m_v4l2Info.flashSupported && mode == QCamera::FlashAuto) ++ return true; ++ return mode == QCamera::FlashOff; ++} ++ ++bool QV4L2Camera::isFlashReady() const ++{ ++ struct v4l2_queryctrl queryControl; ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_AUTO_WHITE_BALANCE; ++ ++ return m_v4l2FileDescriptor && m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl); ++} ++ ++void QV4L2Camera::setTorchMode(QCamera::TorchMode mode) ++{ ++ if (!m_v4l2Info.torchSupported || mode == QCamera::TorchOn) ++ return; ++ setV4L2Parameter(V4L2_CID_FLASH_LED_MODE, mode == QCamera::TorchOn ? V4L2_FLASH_LED_MODE_TORCH : V4L2_FLASH_LED_MODE_NONE); ++ torchModeChanged(mode); ++} ++ ++bool QV4L2Camera::isTorchModeSupported(QCamera::TorchMode mode) const ++{ ++ if (mode == QCamera::TorchOn) ++ return m_v4l2Info.torchSupported; ++ return mode == QCamera::TorchOff; ++} ++ ++void QV4L2Camera::setExposureMode(QCamera::ExposureMode mode) ++{ ++ if (m_v4l2Info.autoExposureSupported && m_v4l2Info.manualExposureSupported) { ++ if (mode != QCamera::ExposureAuto && mode != QCamera::ExposureManual) ++ return; ++ int value = QCamera::ExposureAuto ? V4L2_EXPOSURE_AUTO : V4L2_EXPOSURE_MANUAL; ++ setV4L2Parameter(V4L2_CID_EXPOSURE_AUTO, value); ++ exposureModeChanged(mode); ++ return; ++ } ++} ++ ++bool QV4L2Camera::isExposureModeSupported(QCamera::ExposureMode mode) const ++{ ++ if (mode == QCamera::ExposureAuto) ++ return true; ++ if (m_v4l2Info.manualExposureSupported && m_v4l2Info.autoExposureSupported) ++ return mode == QCamera::ExposureManual; ++ return false; ++} ++ ++void QV4L2Camera::setExposureCompensation(float compensation) ++{ ++ if ((m_v4l2Info.minExposureAdjustment != 0 || m_v4l2Info.maxExposureAdjustment != 0)) { ++ int value = qBound(m_v4l2Info.minExposureAdjustment, (int)(compensation * 1000), ++ m_v4l2Info.maxExposureAdjustment); ++ setV4L2Parameter(V4L2_CID_AUTO_EXPOSURE_BIAS, value); ++ exposureCompensationChanged(value/1000.); ++ return; ++ } ++} ++ ++void QV4L2Camera::setManualIsoSensitivity(int iso) ++{ ++ if (!(supportedFeatures() & QCamera::Feature::IsoSensitivity)) ++ return; ++ setV4L2Parameter(V4L2_CID_ISO_SENSITIVITY_AUTO, iso <= 0 ? V4L2_ISO_SENSITIVITY_AUTO : V4L2_ISO_SENSITIVITY_MANUAL); ++ if (iso > 0) { ++ iso = qBound(minIso(), iso, maxIso()); ++ setV4L2Parameter(V4L2_CID_ISO_SENSITIVITY, iso); ++ } ++ return; ++} ++ ++int QV4L2Camera::isoSensitivity() const ++{ ++ if (!(supportedFeatures() & QCamera::Feature::IsoSensitivity)) ++ return -1; ++ return getV4L2Parameter(V4L2_CID_ISO_SENSITIVITY); ++} ++ ++void QV4L2Camera::setManualExposureTime(float secs) ++{ ++ if (m_v4l2Info.manualExposureSupported && m_v4l2Info.autoExposureSupported) { ++ int exposure = ++ qBound(m_v4l2Info.minExposure, qRound(secs * 10000.), m_v4l2Info.maxExposure); ++ setV4L2Parameter(V4L2_CID_EXPOSURE_ABSOLUTE, exposure); ++ exposureTimeChanged(exposure/10000.); ++ return; ++ } ++} ++ ++float QV4L2Camera::exposureTime() const ++{ ++ return getV4L2Parameter(V4L2_CID_EXPOSURE_ABSOLUTE)/10000.; ++} ++ ++bool QV4L2Camera::isWhiteBalanceModeSupported(QCamera::WhiteBalanceMode mode) const ++{ ++ if (m_v4l2Info.autoWhiteBalanceSupported && m_v4l2Info.colorTemperatureSupported) ++ return true; ++ ++ return mode == QCamera::WhiteBalanceAuto; ++} ++ ++void QV4L2Camera::setWhiteBalanceMode(QCamera::WhiteBalanceMode mode) ++{ ++ Q_ASSERT(isWhiteBalanceModeSupported(mode)); ++ ++ int temperature = colorTemperatureForWhiteBalance(mode); ++ int t = setV4L2ColorTemperature(temperature); ++ if (t == 0) ++ mode = QCamera::WhiteBalanceAuto; ++ whiteBalanceModeChanged(mode); ++} ++ ++void QV4L2Camera::setColorTemperature(int temperature) ++{ ++ if (temperature == 0) { ++ setWhiteBalanceMode(QCamera::WhiteBalanceAuto); ++ return; ++ } ++ ++ Q_ASSERT(isWhiteBalanceModeSupported(QCamera::WhiteBalanceManual)); ++ ++ int t = setV4L2ColorTemperature(temperature); ++ if (t) ++ colorTemperatureChanged(t); ++} ++ ++void QV4L2Camera::readFrame() ++{ ++ Q_ASSERT(m_memoryTransfer); ++ ++ auto buffer = m_memoryTransfer->dequeueBuffer(); ++ if (!buffer) { ++ qCWarning(qLcV4L2Camera) << "Cannot take buffer"; ++ ++ if (errno == ENODEV) { ++ // camera got removed while being active ++ stopCapturing(); ++ closeV4L2Fd(); ++ } ++ ++ return; ++ } ++ ++ auto videoBuffer = new QMemoryVideoBuffer(buffer->data, m_bytesPerLine); ++ QVideoFrame frame(videoBuffer, frameFormat()); ++ ++ auto &v4l2Buffer = buffer->v4l2Buffer; ++ ++ if (m_firstFrameTime.tv_sec == -1) ++ m_firstFrameTime = v4l2Buffer.timestamp; ++ qint64 secs = v4l2Buffer.timestamp.tv_sec - m_firstFrameTime.tv_sec; ++ qint64 usecs = v4l2Buffer.timestamp.tv_usec - m_firstFrameTime.tv_usec; ++ frame.setStartTime(secs*1000000 + usecs); ++ frame.setEndTime(frame.startTime() + m_frameDuration); ++ ++ emit newVideoFrame(frame); ++ ++ if (!m_memoryTransfer->enqueueBuffer(v4l2Buffer.index)) ++ qCWarning(qLcV4L2Camera) << "Cannot add buffer"; ++} ++ ++void QV4L2Camera::setCameraBusy() ++{ ++ m_cameraBusy = true; ++ updateError(QCamera::CameraError, QLatin1String("Camera is in use")); ++} ++ ++void QV4L2Camera::initV4L2Controls() ++{ ++ m_v4l2Info = {}; ++ QCamera::Features features; ++ ++ const QByteArray deviceName = m_cameraDevice.id(); ++ Q_ASSERT(!deviceName.isEmpty()); ++ ++ closeV4L2Fd(); ++ ++ const int descriptor = qt_safe_open(deviceName.constData(), O_RDWR); ++ if (descriptor == -1) { ++ qCWarning(qLcV4L2Camera) << "Unable to open the camera" << deviceName ++ << "for read to query the parameter info:" ++ << qt_error_string(errno); ++ updateError(QCamera::CameraError, QLatin1String("Cannot open camera")); ++ return; ++ } ++ ++ m_v4l2FileDescriptor = std::make_shared(descriptor); ++ ++ qCDebug(qLcV4L2Camera) << "FD=" << descriptor; ++ ++ struct v4l2_queryctrl queryControl; ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_AUTO_WHITE_BALANCE; ++ ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.autoWhiteBalanceSupported = true; ++ setV4L2Parameter(V4L2_CID_AUTO_WHITE_BALANCE, true); ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_WHITE_BALANCE_TEMPERATURE; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.minColorTemp = queryControl.minimum; ++ m_v4l2Info.maxColorTemp = queryControl.maximum; ++ m_v4l2Info.colorTemperatureSupported = true; ++ features |= QCamera::Feature::ColorTemperature; ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_EXPOSURE_AUTO; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.autoExposureSupported = true; ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_EXPOSURE_ABSOLUTE; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.manualExposureSupported = true; ++ m_v4l2Info.minExposure = queryControl.minimum; ++ m_v4l2Info.maxExposure = queryControl.maximum; ++ features |= QCamera::Feature::ManualExposureTime; ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_AUTO_EXPOSURE_BIAS; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.minExposureAdjustment = queryControl.minimum; ++ m_v4l2Info.maxExposureAdjustment = queryControl.maximum; ++ features |= QCamera::Feature::ExposureCompensation; ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_ISO_SENSITIVITY_AUTO; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ queryControl.id = V4L2_CID_ISO_SENSITIVITY; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ features |= QCamera::Feature::IsoSensitivity; ++ minIsoChanged(queryControl.minimum); ++ maxIsoChanged(queryControl.minimum); ++ } ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_FOCUS_ABSOLUTE; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.minExposureAdjustment = queryControl.minimum; ++ m_v4l2Info.maxExposureAdjustment = queryControl.maximum; ++ features |= QCamera::Feature::FocusDistance; ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_AUTO_FOCUS_RANGE; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.rangedFocus = true; ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_FLASH_LED_MODE; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.flashSupported = queryControl.minimum <= V4L2_FLASH_LED_MODE_FLASH ++ && queryControl.maximum >= V4L2_FLASH_LED_MODE_FLASH; ++ m_v4l2Info.torchSupported = queryControl.minimum <= V4L2_FLASH_LED_MODE_TORCH ++ && queryControl.maximum >= V4L2_FLASH_LED_MODE_TORCH; ++ } ++ ++ ::memset(&queryControl, 0, sizeof(queryControl)); ++ queryControl.id = V4L2_CID_ZOOM_ABSOLUTE; ++ if (m_v4l2FileDescriptor->call(VIDIOC_QUERYCTRL, &queryControl)) { ++ m_v4l2Info.minZoom = queryControl.minimum; ++ m_v4l2Info.maxZoom = queryControl.maximum; ++ } ++ // zoom factors are in arbitrary units, so we simply normalize them to go from 1 to 2 ++ // if they are different ++ minimumZoomFactorChanged(1); ++ maximumZoomFactorChanged(m_v4l2Info.minZoom != m_v4l2Info.maxZoom ? 2 : 1); ++ ++ supportedFeaturesChanged(features); ++} ++ ++void QV4L2Camera::closeV4L2Fd() ++{ ++ Q_ASSERT(!m_memoryTransfer); ++ ++ m_v4l2Info = {}; ++ m_cameraBusy = false; ++ m_v4l2FileDescriptor = nullptr; ++} ++ ++int QV4L2Camera::setV4L2ColorTemperature(int temperature) ++{ ++ struct v4l2_control control; ++ ::memset(&control, 0, sizeof(control)); ++ ++ if (m_v4l2Info.autoWhiteBalanceSupported) { ++ setV4L2Parameter(V4L2_CID_AUTO_WHITE_BALANCE, temperature == 0 ? true : false); ++ } else if (temperature == 0) { ++ temperature = 5600; ++ } ++ ++ if (temperature != 0 && m_v4l2Info.colorTemperatureSupported) { ++ temperature = qBound(m_v4l2Info.minColorTemp, temperature, m_v4l2Info.maxColorTemp); ++ if (!setV4L2Parameter( ++ V4L2_CID_WHITE_BALANCE_TEMPERATURE, ++ qBound(m_v4l2Info.minColorTemp, temperature, m_v4l2Info.maxColorTemp))) ++ temperature = 0; ++ } else { ++ temperature = 0; ++ } ++ ++ return temperature; ++} ++ ++bool QV4L2Camera::setV4L2Parameter(quint32 id, qint32 value) ++{ ++ v4l2_control control{ id, value }; ++ if (!m_v4l2FileDescriptor->call(VIDIOC_S_CTRL, &control)) { ++ qWarning() << "Unable to set the V4L2 Parameter" << Qt::hex << id << "to" << value << qt_error_string(errno); ++ return false; ++ } ++ return true; ++} ++ ++int QV4L2Camera::getV4L2Parameter(quint32 id) const ++{ ++ struct v4l2_control control{id, 0}; ++ if (!m_v4l2FileDescriptor->call(VIDIOC_G_CTRL, &control)) { ++ qWarning() << "Unable to get the V4L2 Parameter" << Qt::hex << id << qt_error_string(errno); ++ return 0; ++ } ++ return control.value; ++} ++ ++void QV4L2Camera::setV4L2CameraFormat() ++{ ++ if (m_v4l2Info.formatInitialized || !m_v4l2FileDescriptor) ++ return; ++ ++ Q_ASSERT(!m_cameraFormat.isNull()); ++ qCDebug(qLcV4L2Camera) << "XXXXX" << this << m_cameraDevice.id() << m_cameraFormat.pixelFormat() ++ << m_cameraFormat.resolution(); ++ ++ v4l2_format fmt = {}; ++ fmt.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ ++ auto size = m_cameraFormat.resolution(); ++ fmt.fmt.pix.width = size.width(); ++ fmt.fmt.pix.height = size.height(); ++ fmt.fmt.pix.pixelformat = v4l2FormatForPixelFormat(m_cameraFormat.pixelFormat()); ++ fmt.fmt.pix.field = V4L2_FIELD_ANY; ++ ++ qCDebug(qLcV4L2Camera) << "setting camera format to" << size << fmt.fmt.pix.pixelformat; ++ ++ if (!m_v4l2FileDescriptor->call(VIDIOC_S_FMT, &fmt)) { ++ if (errno == EBUSY) { ++ setCameraBusy(); ++ return; ++ } ++ qWarning() << "Couldn't set video format on v4l2 camera" << strerror(errno); ++ } ++ ++ m_v4l2Info.formatInitialized = true; ++ m_cameraBusy = false; ++ ++ m_bytesPerLine = fmt.fmt.pix.bytesperline; ++ m_imageSize = std::max(fmt.fmt.pix.sizeimage, m_bytesPerLine * fmt.fmt.pix.height); ++ ++ switch (v4l2_colorspace(fmt.fmt.pix.colorspace)) { ++ default: ++ case V4L2_COLORSPACE_DCI_P3: ++ m_colorSpace = QVideoFrameFormat::ColorSpace_Undefined; ++ break; ++ case V4L2_COLORSPACE_REC709: ++ m_colorSpace = QVideoFrameFormat::ColorSpace_BT709; ++ break; ++ case V4L2_COLORSPACE_JPEG: ++ m_colorSpace = QVideoFrameFormat::ColorSpace_AdobeRgb; ++ break; ++ case V4L2_COLORSPACE_SRGB: ++ // ##### is this correct??? ++ m_colorSpace = QVideoFrameFormat::ColorSpace_BT601; ++ break; ++ case V4L2_COLORSPACE_BT2020: ++ m_colorSpace = QVideoFrameFormat::ColorSpace_BT2020; ++ break; ++ } ++ ++ v4l2_streamparm streamParam = {}; ++ streamParam.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ ++ streamParam.parm.capture.capability = V4L2_CAP_TIMEPERFRAME; ++ auto [num, den] = qRealToFraction(1./m_cameraFormat.maxFrameRate()); ++ streamParam.parm.capture.timeperframe = { (uint)num, (uint)den }; ++ m_v4l2FileDescriptor->call(VIDIOC_S_PARM, &streamParam); ++ ++ m_frameDuration = 1000000 * streamParam.parm.capture.timeperframe.numerator ++ / streamParam.parm.capture.timeperframe.denominator; ++} ++ ++void QV4L2Camera::initV4L2MemoryTransfer() ++{ ++ if (m_cameraBusy) ++ return; ++ ++ Q_ASSERT(!m_memoryTransfer); ++ ++ m_memoryTransfer = makeUserPtrMemoryTransfer(m_v4l2FileDescriptor, m_imageSize); ++ ++ if (m_memoryTransfer) ++ return; ++ ++ if (errno == EBUSY) { ++ setCameraBusy(); ++ return; ++ } ++ ++ qCDebug(qLcV4L2Camera) << "Cannot init V4L2_MEMORY_USERPTR; trying V4L2_MEMORY_MMAP"; ++ ++ m_memoryTransfer = makeMMapMemoryTransfer(m_v4l2FileDescriptor); ++ ++ if (!m_memoryTransfer) { ++ qCWarning(qLcV4L2Camera) << "Cannot init v4l2 memory transfer," << qt_error_string(errno); ++ updateError(QCamera::CameraError, QLatin1String("Cannot init V4L2 memory transfer")); ++ } ++} ++ ++void QV4L2Camera::stopCapturing() ++{ ++ if (!m_memoryTransfer || !m_v4l2FileDescriptor) ++ return; ++ ++ m_notifier = nullptr; ++ ++ if (!m_v4l2FileDescriptor->stopStream()) { ++ // TODO: handle the case carefully to avoid possible memory corruption ++ if (errno != ENODEV) ++ qWarning() << "failed to stop capture"; ++ } ++ ++ m_memoryTransfer = nullptr; ++ m_cameraBusy = false; ++} ++ ++void QV4L2Camera::startCapturing() ++{ ++ if (!m_v4l2FileDescriptor) ++ return; ++ ++ setV4L2CameraFormat(); ++ initV4L2MemoryTransfer(); ++ ++ if (m_cameraBusy || !m_memoryTransfer) ++ return; ++ ++ if (!m_v4l2FileDescriptor->startStream()) { ++ qWarning() << "Couldn't start v4l2 camera stream"; ++ return; ++ } ++ ++ m_notifier = ++ std::make_unique(m_v4l2FileDescriptor->get(), QSocketNotifier::Read); ++ connect(m_notifier.get(), &QSocketNotifier::activated, this, &QV4L2Camera::readFrame); ++ ++ m_firstFrameTime = { -1, -1 }; ++} ++ ++QVideoFrameFormat QV4L2Camera::frameFormat() const ++{ ++ auto result = QPlatformCamera::frameFormat(); ++ result.setColorSpace(m_colorSpace); ++ return result; ++} ++ ++QT_END_NAMESPACE ++ ++#include "moc_qv4l2camera_p.cpp" +diff --git a/src/plugins/multimedia/v4l2/qv4l2camera_p.h b/src/plugins/multimedia/v4l2/qv4l2camera_p.h +new file mode 100644 +index 000000000..79cc3cfa9 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qv4l2camera_p.h +@@ -0,0 +1,133 @@ ++// Copyright (C) 2021 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QV4L2CAMERA_H ++#define QV4L2CAMERA_H ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++#include ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++class QV4L2FileDescriptor; ++class QV4L2MemoryTransfer; ++class QSocketNotifier; ++ ++struct V4L2CameraInfo ++{ ++ bool formatInitialized = false; ++ ++ bool autoWhiteBalanceSupported = false; ++ bool colorTemperatureSupported = false; ++ bool autoExposureSupported = false; ++ bool manualExposureSupported = false; ++ bool flashSupported = false; ++ bool torchSupported = false; ++ qint32 minColorTemp = 5600; // Daylight... ++ qint32 maxColorTemp = 5600; ++ qint32 minExposure = 0; ++ qint32 maxExposure = 0; ++ qint32 minExposureAdjustment = 0; ++ qint32 maxExposureAdjustment = 0; ++ qint32 minFocus = 0; ++ qint32 maxFocus = 0; ++ qint32 rangedFocus = false; ++ ++ int minZoom = 0; ++ int maxZoom = 0; ++}; ++ ++QVideoFrameFormat::PixelFormat formatForV4L2Format(uint32_t v4l2Format); ++uint32_t v4l2FormatForPixelFormat(QVideoFrameFormat::PixelFormat format); ++ ++class Q_MULTIMEDIA_EXPORT QV4L2Camera : public QPlatformCamera ++{ ++ Q_OBJECT ++ ++public: ++ explicit QV4L2Camera(QCamera *parent); ++ ~QV4L2Camera(); ++ ++ bool isActive() const override; ++ void setActive(bool active) override; ++ ++ void setCamera(const QCameraDevice &camera) override; ++ bool setCameraFormat(const QCameraFormat &format) override; ++ bool resolveCameraFormat(const QCameraFormat &format); ++ ++ bool isFocusModeSupported(QCamera::FocusMode mode) const override; ++ void setFocusMode(QCamera::FocusMode /*mode*/) override; ++ ++// void setCustomFocusPoint(const QPointF &/*point*/) override; ++ void setFocusDistance(float) override; ++ void zoomTo(float /*newZoomFactor*/, float /*rate*/ = -1.) override; ++ ++ void setFlashMode(QCamera::FlashMode /*mode*/) override; ++ bool isFlashModeSupported(QCamera::FlashMode mode) const override; ++ bool isFlashReady() const override; ++ ++ void setTorchMode(QCamera::TorchMode /*mode*/) override; ++ bool isTorchModeSupported(QCamera::TorchMode mode) const override; ++ ++ void setExposureMode(QCamera::ExposureMode) override; ++ bool isExposureModeSupported(QCamera::ExposureMode mode) const override; ++ void setExposureCompensation(float) override; ++ int isoSensitivity() const override; ++ void setManualIsoSensitivity(int) override; ++ void setManualExposureTime(float) override; ++ float exposureTime() const override; ++ ++ bool isWhiteBalanceModeSupported(QCamera::WhiteBalanceMode mode) const override; ++ void setWhiteBalanceMode(QCamera::WhiteBalanceMode /*mode*/) override; ++ void setColorTemperature(int /*temperature*/) override; ++ ++ QVideoFrameFormat frameFormat() const override; ++ ++private Q_SLOTS: ++ void readFrame(); ++ ++private: ++ void setCameraBusy(); ++ void initV4L2Controls(); ++ void closeV4L2Fd(); ++ int setV4L2ColorTemperature(int temperature); ++ bool setV4L2Parameter(quint32 id, qint32 value); ++ int getV4L2Parameter(quint32 id) const; ++ ++ void setV4L2CameraFormat(); ++ void initV4L2MemoryTransfer(); ++ void startCapturing(); ++ void stopCapturing(); ++ ++private: ++ bool m_active = false; ++ QCameraDevice m_cameraDevice; ++ ++ std::unique_ptr m_notifier; ++ std::unique_ptr m_memoryTransfer; ++ std::shared_ptr m_v4l2FileDescriptor; ++ ++ V4L2CameraInfo m_v4l2Info; ++ ++ timeval m_firstFrameTime = { -1, -1 }; ++ quint32 m_bytesPerLine = 0; ++ quint32 m_imageSize = 0; ++ QVideoFrameFormat::ColorSpace m_colorSpace = QVideoFrameFormat::ColorSpace_Undefined; ++ qint64 m_frameDuration = -1; ++ bool m_cameraBusy = false; ++}; ++ ++QT_END_NAMESPACE ++ ++#endif // QV4L2CAMERA_H +diff --git a/src/plugins/multimedia/v4l2/qv4l2cameradevices.cpp b/src/plugins/multimedia/v4l2/qv4l2cameradevices.cpp +new file mode 100644 +index 000000000..c89ff69c6 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qv4l2cameradevices.cpp +@@ -0,0 +1,168 @@ ++// Copyright (C) 2023 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include "qv4l2cameradevices_p.h" ++#include "qv4l2filedescriptor_p.h" ++#include "qv4l2camera_p.h" ++ ++#include ++#include ++ ++#include ++#include ++#include ++#include ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++static Q_LOGGING_CATEGORY(qLcV4L2CameraDevices, "qt.multimedia.ffmpeg.v4l2cameradevices"); ++ ++static bool areCamerasEqual(QList a, QList b) ++{ ++ auto areCamerasDataEqual = [](const QCameraDevice &a, const QCameraDevice &b) { ++ Q_ASSERT(QCameraDevicePrivate::handle(a)); ++ Q_ASSERT(QCameraDevicePrivate::handle(b)); ++ return *QCameraDevicePrivate::handle(a) == *QCameraDevicePrivate::handle(b); ++ }; ++ ++ return std::equal(a.cbegin(), a.cend(), b.cbegin(), b.cend(), areCamerasDataEqual); ++} ++ ++QV4L2CameraDevices::QV4L2CameraDevices(QPlatformMediaIntegration *integration) ++ : QPlatformVideoDevices(integration) ++{ ++ m_deviceWatcher.addPath(QLatin1String("/dev")); ++ connect(&m_deviceWatcher, &QFileSystemWatcher::directoryChanged, this, ++ &QV4L2CameraDevices::checkCameras); ++ doCheckCameras(); ++} ++ ++QList QV4L2CameraDevices::findVideoInputs() const ++{ ++ return m_cameras; ++} ++ ++void QV4L2CameraDevices::checkCameras() ++{ ++ if (doCheckCameras()) ++ onVideoInputsChanged(); ++} ++ ++bool QV4L2CameraDevices::doCheckCameras() ++{ ++ QList newCameras; ++ ++ QDir dir(QLatin1String("/dev")); ++ const auto devices = dir.entryList(QDir::System); ++ ++ bool first = true; ++ ++ for (auto device : devices) { ++ // qCDebug(qLcV4L2Camera) << "device:" << device; ++ if (!device.startsWith(QLatin1String("video"))) ++ continue; ++ ++ QByteArray file = QFile::encodeName(dir.filePath(device)); ++ const int fd = open(file.constData(), O_RDONLY); ++ if (fd < 0) ++ continue; ++ ++ auto fileCloseGuard = qScopeGuard([fd]() { close(fd); }); ++ ++ v4l2_fmtdesc formatDesc = {}; ++ ++ struct v4l2_capability cap; ++ if (xioctl(fd, VIDIOC_QUERYCAP, &cap) < 0) ++ continue; ++ ++ if (cap.device_caps & V4L2_CAP_META_CAPTURE) ++ continue; ++ if (!(cap.capabilities & V4L2_CAP_VIDEO_CAPTURE)) ++ continue; ++ if (!(cap.capabilities & V4L2_CAP_STREAMING)) ++ continue; ++ ++ auto camera = std::make_unique(); ++ ++ camera->id = file; ++ camera->description = QString::fromUtf8((const char *)cap.card); ++ qCDebug(qLcV4L2CameraDevices) << "found camera" << camera->id << camera->description; ++ ++ formatDesc.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ ++ while (!xioctl(fd, VIDIOC_ENUM_FMT, &formatDesc)) { ++ auto pixelFmt = formatForV4L2Format(formatDesc.pixelformat); ++ qCDebug(qLcV4L2CameraDevices) << " " << pixelFmt; ++ ++ if (pixelFmt == QVideoFrameFormat::Format_Invalid) { ++ ++formatDesc.index; ++ continue; ++ } ++ ++ qCDebug(qLcV4L2CameraDevices) << "frame sizes:"; ++ v4l2_frmsizeenum frameSize = {}; ++ frameSize.pixel_format = formatDesc.pixelformat; ++ ++ while (!xioctl(fd, VIDIOC_ENUM_FRAMESIZES, &frameSize)) { ++ ++frameSize.index; ++ if (frameSize.type != V4L2_FRMSIZE_TYPE_DISCRETE) ++ continue; ++ ++ QSize resolution(frameSize.discrete.width, frameSize.discrete.height); ++ float min = 1e10; ++ float max = 0; ++ ++ v4l2_frmivalenum frameInterval = {}; ++ frameInterval.pixel_format = formatDesc.pixelformat; ++ frameInterval.width = frameSize.discrete.width; ++ frameInterval.height = frameSize.discrete.height; ++ ++ while (!xioctl(fd, VIDIOC_ENUM_FRAMEINTERVALS, &frameInterval)) { ++ ++frameInterval.index; ++ if (frameInterval.type != V4L2_FRMIVAL_TYPE_DISCRETE) ++ continue; ++ float rate = float(frameInterval.discrete.denominator) ++ / float(frameInterval.discrete.numerator); ++ if (rate > max) ++ max = rate; ++ if (rate < min) ++ min = rate; ++ } ++ ++ qCDebug(qLcV4L2CameraDevices) << " " << resolution << min << max; ++ ++ if (min <= max) { ++ auto fmt = std::make_unique(); ++ fmt->pixelFormat = pixelFmt; ++ fmt->resolution = resolution; ++ fmt->minFrameRate = min; ++ fmt->maxFrameRate = max; ++ camera->videoFormats.append(fmt.release()->create()); ++ camera->photoResolutions.append(resolution); ++ } ++ } ++ ++ ++formatDesc.index; ++ } ++ ++ if (camera->videoFormats.empty()) ++ continue; ++ ++ // first camera is default ++ camera->isDefault = std::exchange(first, false); ++ ++ newCameras.append(camera.release()->create()); ++ } ++ ++ if (areCamerasEqual(m_cameras, newCameras)) ++ return false; ++ ++ m_cameras = std::move(newCameras); ++ return true; ++} ++ ++QT_END_NAMESPACE ++ ++#include "moc_qv4l2cameradevices_p.cpp" +diff --git a/src/plugins/multimedia/v4l2/qv4l2cameradevices_p.h b/src/plugins/multimedia/v4l2/qv4l2cameradevices_p.h +new file mode 100644 +index 000000000..22ac44027 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qv4l2cameradevices_p.h +@@ -0,0 +1,47 @@ ++// Copyright (C) 2023 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QV4L2CAMERADEVICES_P_H ++#define QV4L2CAMERADEVICES_P_H ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++#include ++#include ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++class QV4L2CameraDevices : public QPlatformVideoDevices ++{ ++ Q_OBJECT ++public: ++ QV4L2CameraDevices(QPlatformMediaIntegration *integration); ++ ++public Q_SLOTS: ++ void checkCameras(); ++ ++protected: ++ QList findVideoInputs() const override; ++ ++private: ++ bool doCheckCameras(); ++ ++private: ++ QList m_cameras; ++ QFileSystemWatcher m_deviceWatcher; ++}; ++ ++QT_END_NAMESPACE ++ ++#endif // QV4L2CAMERADEVICES_P_H +diff --git a/src/plugins/multimedia/v4l2/qv4l2filedescriptor.cpp b/src/plugins/multimedia/v4l2/qv4l2filedescriptor.cpp +new file mode 100644 +index 000000000..7f7b099c7 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qv4l2filedescriptor.cpp +@@ -0,0 +1,71 @@ ++// Copyright (C) 2023 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include "qv4l2filedescriptor_p.h" ++ ++#include ++#include ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++int xioctl(int fd, int request, void *arg) ++{ ++ int res; ++ ++ do { ++ res = ::ioctl(fd, request, arg); ++ } while (res == -1 && EINTR == errno); ++ ++ return res; ++} ++ ++QV4L2FileDescriptor::QV4L2FileDescriptor(int descriptor) : m_descriptor(descriptor) ++{ ++ Q_ASSERT(descriptor >= 0); ++} ++ ++QV4L2FileDescriptor::~QV4L2FileDescriptor() ++{ ++ qt_safe_close(m_descriptor); ++} ++ ++bool QV4L2FileDescriptor::call(int request, void *arg) const ++{ ++ return ::xioctl(m_descriptor, request, arg) >= 0; ++} ++ ++bool QV4L2FileDescriptor::requestBuffers(quint32 memoryType, quint32 &buffersCount) const ++{ ++ v4l2_requestbuffers req = {}; ++ req.count = buffersCount; ++ req.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ req.memory = memoryType; ++ ++ if (!call(VIDIOC_REQBUFS, &req)) ++ return false; ++ ++ buffersCount = req.count; ++ return true; ++} ++ ++bool QV4L2FileDescriptor::startStream() ++{ ++ int type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ if (!call(VIDIOC_STREAMON, &type)) ++ return false; ++ ++ m_streamStarted = true; ++ return true; ++} ++ ++bool QV4L2FileDescriptor::stopStream() ++{ ++ int type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ auto result = call(VIDIOC_STREAMOFF, &type); ++ m_streamStarted = false; ++ return result; ++} ++ ++QT_END_NAMESPACE +diff --git a/src/plugins/multimedia/v4l2/qv4l2filedescriptor_p.h b/src/plugins/multimedia/v4l2/qv4l2filedescriptor_p.h +new file mode 100644 +index 000000000..1058c7a82 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qv4l2filedescriptor_p.h +@@ -0,0 +1,50 @@ ++// Copyright (C) 2023 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QV4L2FILEDESCRIPTOR_P_H ++#define QV4L2FILEDESCRIPTOR_P_H ++ ++#include ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++QT_BEGIN_NAMESPACE ++ ++int xioctl(int fd, int request, void *arg); ++ ++class QV4L2FileDescriptor ++{ ++public: ++ QV4L2FileDescriptor(int descriptor); ++ ++ ~QV4L2FileDescriptor(); ++ ++ bool call(int request, void *arg) const; ++ ++ int get() const { return m_descriptor; } ++ ++ bool requestBuffers(quint32 memoryType, quint32 &buffersCount) const; ++ ++ bool startStream(); ++ ++ bool stopStream(); ++ ++ bool streamStarted() const { return m_streamStarted; } ++ ++private: ++ int m_descriptor; ++ bool m_streamStarted = false; ++}; ++ ++QT_END_NAMESPACE ++ ++#endif // QV4L2FILEDESCRIPTOR_P_H +diff --git a/src/plugins/multimedia/v4l2/qv4l2memorytransfer.cpp b/src/plugins/multimedia/v4l2/qv4l2memorytransfer.cpp +new file mode 100644 +index 000000000..32ee4f8f8 +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qv4l2memorytransfer.cpp +@@ -0,0 +1,223 @@ ++// Copyright (C) 2023 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#include "qv4l2memorytransfer_p.h" ++#include "qv4l2filedescriptor_p.h" ++ ++#include ++#include ++#include ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++static Q_LOGGING_CATEGORY(qLcV4L2MemoryTransfer, "qt.multimedia.ffmpeg.v4l2camera.memorytransfer"); ++ ++namespace { ++ ++v4l2_buffer makeV4l2Buffer(quint32 memoryType, quint32 index = 0) ++{ ++ v4l2_buffer buf = {}; ++ buf.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; ++ buf.memory = memoryType; ++ buf.index = index; ++ return buf; ++} ++ ++class UserPtrMemoryTransfer : public QV4L2MemoryTransfer ++{ ++public: ++ static QV4L2MemoryTransferUPtr create(QV4L2FileDescriptorPtr fileDescriptor, quint32 imageSize) ++ { ++ quint32 buffersCount = 2; ++ if (!fileDescriptor->requestBuffers(V4L2_MEMORY_USERPTR, buffersCount)) { ++ qCWarning(qLcV4L2MemoryTransfer) << "Cannot request V4L2_MEMORY_USERPTR buffers"; ++ return {}; ++ } ++ ++ std::unique_ptr result( ++ new UserPtrMemoryTransfer(std::move(fileDescriptor), buffersCount, imageSize)); ++ ++ return result->enqueueBuffers() ? std::move(result) : nullptr; ++ } ++ ++ std::optional dequeueBuffer() override ++ { ++ auto v4l2Buffer = makeV4l2Buffer(V4L2_MEMORY_USERPTR); ++ if (!fileDescriptor().call(VIDIOC_DQBUF, &v4l2Buffer)) ++ return {}; ++ ++ Q_ASSERT(v4l2Buffer.index < m_byteArrays.size()); ++ Q_ASSERT(!m_byteArrays[v4l2Buffer.index].isEmpty()); ++ ++ return Buffer{ v4l2Buffer, std::move(m_byteArrays[v4l2Buffer.index]) }; ++ } ++ ++ bool enqueueBuffer(quint32 index) override ++ { ++ Q_ASSERT(index < m_byteArrays.size()); ++ Q_ASSERT(m_byteArrays[index].isEmpty()); ++ ++ auto buf = makeV4l2Buffer(V4L2_MEMORY_USERPTR, index); ++ static_assert(sizeof(decltype(buf.m.userptr)) == sizeof(size_t), "Not compatible sizes"); ++ ++ m_byteArrays[index] = QByteArray(static_cast(m_imageSize), Qt::Uninitialized); ++ ++ buf.m.userptr = (decltype(buf.m.userptr))m_byteArrays[index].data(); ++ buf.length = m_byteArrays[index].size(); ++ ++ if (!fileDescriptor().call(VIDIOC_QBUF, &buf)) { ++ qWarning() << "Couldn't add V4L2 buffer" << errno << strerror(errno) << index; ++ return false; ++ } ++ ++ return true; ++ } ++ ++ quint32 buffersCount() const override { return static_cast(m_byteArrays.size()); } ++ ++private: ++ UserPtrMemoryTransfer(QV4L2FileDescriptorPtr fileDescriptor, quint32 buffersCount, ++ quint32 imageSize) ++ : QV4L2MemoryTransfer(std::move(fileDescriptor)), ++ m_imageSize(imageSize), ++ m_byteArrays(buffersCount) ++ { ++ } ++ ++private: ++ quint32 m_imageSize; ++ std::vector m_byteArrays; ++}; ++ ++class MMapMemoryTransfer : public QV4L2MemoryTransfer ++{ ++public: ++ struct MemorySpan ++ { ++ void *data = nullptr; ++ size_t size = 0; ++ bool inQueue = false; ++ }; ++ ++ static QV4L2MemoryTransferUPtr create(QV4L2FileDescriptorPtr fileDescriptor) ++ { ++ quint32 buffersCount = 2; ++ if (!fileDescriptor->requestBuffers(V4L2_MEMORY_MMAP, buffersCount)) { ++ qCWarning(qLcV4L2MemoryTransfer) << "Cannot request V4L2_MEMORY_MMAP buffers"; ++ return {}; ++ } ++ ++ std::unique_ptr result( ++ new MMapMemoryTransfer(std::move(fileDescriptor))); ++ ++ return result->init(buffersCount) ? std::move(result) : nullptr; ++ } ++ ++ bool init(quint32 buffersCount) ++ { ++ for (quint32 index = 0; index < buffersCount; ++index) { ++ auto buf = makeV4l2Buffer(V4L2_MEMORY_MMAP, index); ++ ++ if (!fileDescriptor().call(VIDIOC_QUERYBUF, &buf)) { ++ qWarning() << "Can't map buffer" << index; ++ return false; ++ } ++ ++ auto mappedData = mmap(nullptr, buf.length, PROT_READ | PROT_WRITE, MAP_SHARED, ++ fileDescriptor().get(), buf.m.offset); ++ ++ if (mappedData == MAP_FAILED) { ++ qWarning() << "mmap failed" << index << buf.length << buf.m.offset; ++ return false; ++ } ++ ++ m_spans.push_back(MemorySpan{ mappedData, buf.length, false }); ++ } ++ ++ m_spans.shrink_to_fit(); ++ ++ return enqueueBuffers(); ++ } ++ ++ ~MMapMemoryTransfer() override ++ { ++ for (const auto &span : m_spans) ++ munmap(span.data, span.size); ++ } ++ ++ std::optional dequeueBuffer() override ++ { ++ auto v4l2Buffer = makeV4l2Buffer(V4L2_MEMORY_MMAP); ++ if (!fileDescriptor().call(VIDIOC_DQBUF, &v4l2Buffer)) ++ return {}; ++ ++ const auto index = v4l2Buffer.index; ++ ++ Q_ASSERT(index < m_spans.size()); ++ ++ auto &span = m_spans[index]; ++ ++ Q_ASSERT(span.inQueue); ++ span.inQueue = false; ++ ++ return Buffer{ v4l2Buffer, ++ QByteArray(reinterpret_cast(span.data), span.size) }; ++ } ++ ++ bool enqueueBuffer(quint32 index) override ++ { ++ Q_ASSERT(index < m_spans.size()); ++ Q_ASSERT(!m_spans[index].inQueue); ++ ++ auto buf = makeV4l2Buffer(V4L2_MEMORY_MMAP, index); ++ if (!fileDescriptor().call(VIDIOC_QBUF, &buf)) ++ return false; ++ ++ m_spans[index].inQueue = true; ++ return true; ++ } ++ ++ quint32 buffersCount() const override { return static_cast(m_spans.size()); } ++ ++private: ++ using QV4L2MemoryTransfer::QV4L2MemoryTransfer; ++ ++private: ++ std::vector m_spans; ++}; ++} // namespace ++ ++QV4L2MemoryTransfer::QV4L2MemoryTransfer(QV4L2FileDescriptorPtr fileDescriptor) ++ : m_fileDescriptor(std::move(fileDescriptor)) ++{ ++ Q_ASSERT(m_fileDescriptor); ++ Q_ASSERT(!m_fileDescriptor->streamStarted()); ++} ++ ++QV4L2MemoryTransfer::~QV4L2MemoryTransfer() ++{ ++ Q_ASSERT(!m_fileDescriptor->streamStarted()); // to avoid possible corruptions ++} ++ ++bool QV4L2MemoryTransfer::enqueueBuffers() ++{ ++ for (quint32 i = 0; i < buffersCount(); ++i) ++ if (!enqueueBuffer(i)) ++ return false; ++ ++ return true; ++} ++ ++QV4L2MemoryTransferUPtr makeUserPtrMemoryTransfer(QV4L2FileDescriptorPtr fileDescriptor, ++ quint32 imageSize) ++{ ++ return UserPtrMemoryTransfer::create(std::move(fileDescriptor), imageSize); ++} ++ ++QV4L2MemoryTransferUPtr makeMMapMemoryTransfer(QV4L2FileDescriptorPtr fileDescriptor) ++{ ++ return MMapMemoryTransfer::create(std::move(fileDescriptor)); ++} ++ ++QT_END_NAMESPACE +diff --git a/src/plugins/multimedia/v4l2/qv4l2memorytransfer_p.h b/src/plugins/multimedia/v4l2/qv4l2memorytransfer_p.h +new file mode 100644 +index 000000000..6b5e3913f +--- /dev/null ++++ b/src/plugins/multimedia/v4l2/qv4l2memorytransfer_p.h +@@ -0,0 +1,66 @@ ++// Copyright (C) 2023 The Qt Company Ltd. ++// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only ++ ++#ifndef QV4L2MEMORYTRANSFER_P_H ++#define QV4L2MEMORYTRANSFER_P_H ++ ++#include ++#include ++#include ++ ++#include ++ ++QT_BEGIN_NAMESPACE ++ ++// ++// W A R N I N G ++// ------------- ++// ++// This file is not part of the Qt API. It exists purely as an ++// implementation detail. This header file may change from version to ++// version without notice, or even be removed. ++// ++// We mean it. ++// ++ ++class QV4L2FileDescriptor; ++using QV4L2FileDescriptorPtr = std::shared_ptr; ++ ++class QV4L2MemoryTransfer ++{ ++public: ++ struct Buffer ++ { ++ v4l2_buffer v4l2Buffer = {}; ++ QByteArray data; ++ }; ++ ++ QV4L2MemoryTransfer(QV4L2FileDescriptorPtr fileDescriptor); ++ ++ virtual ~QV4L2MemoryTransfer(); ++ ++ virtual std::optional dequeueBuffer() = 0; ++ ++ virtual bool enqueueBuffer(quint32 index) = 0; ++ ++ virtual quint32 buffersCount() const = 0; ++ ++protected: ++ bool enqueueBuffers(); ++ ++ const QV4L2FileDescriptor &fileDescriptor() const { return *m_fileDescriptor; } ++ ++private: ++ QV4L2FileDescriptorPtr m_fileDescriptor; ++}; ++ ++using QV4L2MemoryTransferUPtr = std::unique_ptr; ++ ++QV4L2MemoryTransferUPtr makeUserPtrMemoryTransfer(QV4L2FileDescriptorPtr fileDescriptor, ++ quint32 imageSize); ++ ++QV4L2MemoryTransferUPtr makeMMapMemoryTransfer(QV4L2FileDescriptorPtr fileDescriptor); ++ ++QT_END_NAMESPACE ++ ++#endif // QV4L2MEMORYTRANSFER_P_H diff --git a/patches/qt/windows_func_fix.patch b/patches/qt/windows_func_fix.patch new file mode 100644 index 0000000..1ea952a --- /dev/null +++ b/patches/qt/windows_func_fix.patch @@ -0,0 +1,48 @@ +From aaae4d700b339491d9c90d12f38ac26186980305 Mon Sep 17 00:00:00 2001 +From: tobtoht +Date: Tue, 15 Nov 2022 15:48:09 +0100 +Subject: [PATCH] Windows: don't use GetFileVersionInfoSize, + GetFileVersionInfo, VerQueryValue + +--- + src/corelib/kernel/qcoreapplication_win.cpp | 24 --------------------- + 1 file changed, 24 deletions(-) + +diff --git a/qtbase/src/corelib/kernel/qcoreapplication_win.cpp b/qtbase/src/corelib/kernel/qcoreapplication_win.cpp +index 0fe14af798..e46384a6a5 100644 +--- a/qtbase/src/corelib/kernel/qcoreapplication_win.cpp ++++ b/qtbase/src/corelib/kernel/qcoreapplication_win.cpp +@@ -60,30 +60,6 @@ QString QCoreApplicationPrivate::appName() const + QString QCoreApplicationPrivate::appVersion() const + { + QString applicationVersion; +-#ifndef QT_BOOTSTRAPPED +- const QString appFileName = qAppFileName(); +- QVarLengthArray buffer(appFileName.size() + 1); +- buffer[appFileName.toWCharArray(buffer.data())] = 0; +- +- DWORD versionInfoSize = GetFileVersionInfoSize(buffer.data(), nullptr); +- if (versionInfoSize) { +- QVarLengthArray info(static_cast(versionInfoSize)); +- if (GetFileVersionInfo(buffer.data(), 0, versionInfoSize, info.data())) { +- UINT size; +- DWORD *fi; +- +- if (VerQueryValue(info.data(), __TEXT("\\"), +- reinterpret_cast(&fi), &size) && size) { +- const VS_FIXEDFILEINFO *verInfo = reinterpret_cast(fi); +- applicationVersion = QStringLiteral("%1.%2.%3.%4") +- .arg(HIWORD(verInfo->dwProductVersionMS)) +- .arg(LOWORD(verInfo->dwProductVersionMS)) +- .arg(HIWORD(verInfo->dwProductVersionLS)) +- .arg(LOWORD(verInfo->dwProductVersionLS)); +- } +- } +- } +-#endif + return applicationVersion; + } + +-- +2.38.1 + diff --git a/patches/rust-std/xcrun b/patches/rust-std/xcrun new file mode 100755 index 0000000..fdaeb03 --- /dev/null +++ b/patches/rust-std/xcrun @@ -0,0 +1,18 @@ +#!/usr/bin/env bash +case "$*" in + *--show-sdk-path*) + if [ -n "$SDK_PATH" ]; then + echo "$SDK_PATH" + exit 0 + fi + ;; + *--version*) + echo "xcrun version 72." + exit 0 + ;; +esac +if [ -x "$NATIVEPREFIX/bin/xcrun.real" ]; then + exec -a xcrun "$NATIVEPREFIX/bin/xcrun.real" "$@" +fi +echo "xcrun: unsupported invocation: $*" >&2 +exit 1 diff --git a/patches/rust/1_55_0/assembly.h.patch b/patches/rust/1_55_0/assembly.h.patch deleted file mode 100644 index 8800633..0000000 --- a/patches/rust/1_55_0/assembly.h.patch +++ /dev/null @@ -1,14 +0,0 @@ ---- a/src/llvm-project/compiler-rt/lib/builtins/assembly.h 2021-07-12 08:53:30.000000000 +0200 -+++ b/src/llvm-project/compiler-rt/lib/builtins/assembly.h 2025-07-08 21:51:23.202034452 +0200 -@@ -249,9 +249,10 @@ - .globl name SEPARATOR \ - SYMBOL_IS_FUNC(name) SEPARATOR \ - DECLARE_SYMBOL_VISIBILITY(name) SEPARATOR \ -+ name: SEPARATOR \ - CFI_START SEPARATOR \ - DECLARE_FUNC_ENCODING \ -- name: SEPARATOR BTI_C -+ BTI_C - - #define DEFINE_COMPILERRT_FUNCTION_ALIAS(name, target) \ - .globl SYMBOL_NAME(name) SEPARATOR \ diff --git a/patches/rust/1_56_1/assembly.h.patch b/patches/rust/1_56_1/assembly.h.patch deleted file mode 100644 index 6a00857..0000000 --- a/patches/rust/1_56_1/assembly.h.patch +++ /dev/null @@ -1,14 +0,0 @@ ---- a/src/llvm-project/compiler-rt/lib/builtins/assembly.h 2025-07-10 12:41:44.469384349 +0200 -+++ b/src/llvm-project/compiler-rt/lib/builtins/assembly.h 2025-07-10 12:46:03.694440678 +0200 -@@ -254,9 +254,10 @@ - .globl name SEPARATOR \ - SYMBOL_IS_FUNC(name) SEPARATOR \ - DECLARE_SYMBOL_VISIBILITY_UNMANGLED(name) SEPARATOR \ -+ name: SEPARATOR \ - CFI_START SEPARATOR \ - DECLARE_FUNC_ENCODING \ -- name: SEPARATOR BTI_C -+ BTI_C - - #define DEFINE_COMPILERRT_FUNCTION_ALIAS(name, target) \ - .globl SYMBOL_NAME(name) SEPARATOR \ \ No newline at end of file diff --git a/patches/rust/Signals.h.patch b/patches/rust/Signals.h.patch deleted file mode 100644 index cde2801..0000000 --- a/patches/rust/Signals.h.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- a/src/llvm-project/llvm/include/llvm/Support/Signals.h 2025-07-31 16:36:28.290100587 +0200 -+++ b/src/llvm-project/llvm/include/llvm/Support/Signals.h 2025-07-31 16:38:14.680982092 +0200 -@@ -15,6 +15,7 @@ - #define LLVM_SUPPORT_SIGNALS_H - - #include -+#include - - namespace llvm { - class StringRef; \ No newline at end of file diff --git a/patches/rust/codegen_c.cpp.patch b/patches/rust/codegen_c.cpp.patch deleted file mode 100644 index b392636..0000000 --- a/patches/rust/codegen_c.cpp.patch +++ /dev/null @@ -1,17 +0,0 @@ ---- a/src/trans/codegen_c.cpp 2025-07-08 00:17:10.022769383 +0200 -+++ b/src/trans/codegen_c.cpp 2025-07-08 00:17:18.404645999 +0200 -@@ -1297,8 +1297,14 @@ - // HACK: Work around [https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117423] by disabling an optimisation stage - if( opt.opt_level > 0 ) - { -+ #ifndef __clang__ // clang doesn't have this option. - args.push_back("-fno-tree-sra"); -+ #endif - } -+ #ifdef __APPLE__ -+ args.push_back("-framework"); -+ args.push_back("Security"); -+ #endif - if( opt.emit_debug_info ) - { - args.push_back("-g"); \ No newline at end of file diff --git a/patches/sodium/disable-glibc-getrandom-getentropy.patch b/patches/sodium/disable-glibc-getrandom-getentropy.patch index 2f07c10..7c7e464 100644 --- a/patches/sodium/disable-glibc-getrandom-getentropy.patch +++ b/patches/sodium/disable-glibc-getrandom-getentropy.patch @@ -1,8 +1,8 @@ diff --git a/configure.ac b/configure.ac -index 9e2de27c..0fa85c2d 100644 +index 1111111..2222222 100644 --- a/configure.ac +++ b/configure.ac -@@ -807,6 +807,10 @@ AS_IF([test "x$EMSCRIPTEN" = "x"],[ +@@ -947,6 +947,10 @@ AS_IF([test "x$EMSCRIPTEN" = "x"],[ # include #endif ]], [[ @@ -11,15 +11,16 @@ index 9e2de27c..0fa85c2d 100644 +#endif + unsigned char buf; - (void) getrandom((void *) &buf, 1U, 0U); - ]])], -@@ -825,6 +829,9 @@ unsigned char buf; + if (&getrandom != NULL) { + (void) getrandom((void *) &buf, 1U, 0U); +@@ -971,6 +975,10 @@ AS_IF([test "x$EMSCRIPTEN" = "x"],[ # include #endif ]], [[ +#ifdef __linux__ +# error getentropy() is currently disabled on Linux to support glibc < 2.25 +#endif - #ifdef __APPLE__ - # error getentropy() is currently disabled on Apple operating systems - #endif ++ + unsigned char buf; + if (&getentropy != NULL) { + (void) getentropy((void *) &buf, 1U); diff --git a/patches/sodium/disable-simd-without-asm.patch b/patches/sodium/disable-simd-without-asm.patch new file mode 100644 index 0000000..4e2c7dc --- /dev/null +++ b/patches/sodium/disable-simd-without-asm.patch @@ -0,0 +1,20 @@ +diff --git a/configure.ac b/configure.ac +index 1111111..2222222 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -493,6 +493,7 @@ AC_LINK_IFELSE( + AS_IF([test "$have_armcrypto" = "yes"],[AC_DEFINE([HAVE_ARMCRYPTO], [1], [ARM crypto extensions are available])]) + ]) + ++ AS_IF([test "$enable_asm" != "no"], [ + oldcflags="$CFLAGS" + AX_CHECK_COMPILE_FLAG([-mmmx], [CFLAGS="$CFLAGS -mmmx"]) + AC_MSG_CHECKING(for MMX instructions set) +@@ -666,6 +667,7 @@ __m512i y = _mm512_permutexvar_epi64(_mm512_setr_epi64(0, 1, 4, 5, 2, 3, 6, 7 + ], + [AC_MSG_RESULT(no)]) + CFLAGS="$oldcflags" ++ ]) + + ]) + diff --git a/patches/strip-nondeterminism-recursive b/patches/strip-nondeterminism-recursive index 93728c3..ba3f7b6 100755 --- a/patches/strip-nondeterminism-recursive +++ b/patches/strip-nondeterminism-recursive @@ -1,4 +1,4 @@ -#!/usr/bin/env perl +#!$NATIVEPREFIX/bootstrap/bin/perl use strict; use warnings; use autodie; @@ -63,9 +63,9 @@ exit($error_count > 0 ? 1 : 0); sub process_file { my $file = $File::Find::name; - + return unless -f $file; - + my $has_archive_extension = 0; for my $ext (@ARCHIVE_EXTENSIONS) { if ($file =~ /\Q$ext\E$/i) { @@ -73,27 +73,27 @@ sub process_file { last; } } - + return unless $has_archive_extension; - + $processed_count++; - + if ($verbose) { print "Processing: $file\n"; } - + if ($dry_run) { print "DRY RUN: Would process $file\n"; $success_count++; return; } - + eval { process_archive_file($file); $success_count++; print "Successfully processed: $file\n" if $verbose; }; - + if ($@) { $error_count++; warn "Failed to process '$file': $@\n"; @@ -102,22 +102,22 @@ sub process_file { sub process_archive_file { my $file = shift; - + my $stat = stat($file) or die "Cannot stat file '$file': $!\n"; my $original_perms = $stat->mode; - + my $current_perms = $stat->mode; unless ($current_perms & 0200) { chmod($current_perms | 0200, $file) or die "Cannot make file writable '$file': $!\n"; } - + my $cmd = "$PERL_CMD $STRIP_NONDETERMINISM_CMD -T 1 --normalizers +all " . quotemeta($file); - + my $exit_code = system($cmd); my $strip_result = $exit_code >> 8; - + chmod($original_perms, $file) or warn "Warning: Could not restore permissions for '$file': $!\n"; - + if ($strip_result != 0) { die "strip-nondeterminism failed with exit code $strip_result"; } @@ -169,8 +169,8 @@ Specify the directory to search (default: current directory). The prefix path where strip-nondeterminism and perl are located. Expected paths: -- strip-nondeterminism: $PREFIX/native/bootstrap/bin/strip-nondeterminism -- perl: $PREFIX/native/bootstrap/bin/perl +- strip-nondeterminism: $NATIVEPREFIX/bootstrap/bin/strip-nondeterminism +- perl: $NATIVEPREFIX/bootstrap/bin/perl =back @@ -207,4 +207,4 @@ Czarek Nakamoto $VERSION -=cut \ No newline at end of file +=cut diff --git a/patches/wayland/toolchain.txt b/patches/wayland/toolchain.txt new file mode 100644 index 0000000..ab8da46 --- /dev/null +++ b/patches/wayland/toolchain.txt @@ -0,0 +1,15 @@ +[binaries] +c = '@cc@' +cpp = '@cxx@' +ar = '@ar@' +strip = '@strip@' +pkgconfig = 'pkg-config' + +[host_machine] +system = 'linux' +cpu_family = '@arch@' +cpu = '@arch@' +endian = 'little' + +[built-in options] +prefix = '@host_prefix@' diff --git a/sources.json b/sources.json new file mode 100644 index 0000000..290861c --- /dev/null +++ b/sources.json @@ -0,0 +1,2733 @@ +{ + "repositories": { + "http://github.com/pkgconf/pkgconf.git": { + "refs": [ + "4fc570f91d9d8d843ab32d2198a5c064538d8ffd" + ] + }, + "http://github.com/thepowersgang/mrustc.git": { + "refs": [ + "9f5ff518a49038d7ae51dadd1658231b61f7dced", + "be69c7479a10bdce1b86cb886789d14a143ddf34" + ] + }, + "http://github.com/zeromq/libzmq.git": { + "refs": [ + "b946c18f676760387276cd095bbdd8c0e18c09bf" + ] + }, + "http://gitlab.torproject.org/tpo/core/tor.git": { + "refs": [ + "106dcfa18c1a9539cb97337e57954ff89685840e", + "e170cdcfebd45f6d098e3d811e2b1e1d120df184", + "e41649c9a34f39f1d543e064fd2b97de26d3e097" + ] + }, + "https://android.googlesource.com/platform/bionic": { + "refs": [ + "a63b21091ada240d92f8ceadb1cabbdedaaab81b" + ] + }, + "https://android.googlesource.com/platform/development": { + "refs": [ + "d84a5b9d746f241c3c77b16e8c6964b0f86f86e2" + ] + }, + "https://android.googlesource.com/platform/external/effcee": { + "refs": [ + "291037172dcb79318a7d0214a194e985c9ad0d7b" + ] + }, + "https://android.googlesource.com/platform/external/googletest": { + "refs": [ + "dc81c03b5db576f5ab8a468b6eebf584b016fa5b" + ] + }, + "https://android.googlesource.com/platform/external/perfetto": { + "refs": [ + "13ce0c9e13b0940d2476cd0cff2301708a9a2e2b" + ] + }, + "https://android.googlesource.com/platform/external/python/astroid": { + "refs": [ + "062ae590ebac6acf05a5c7583be35870f0b563ba" + ] + }, + "https://android.googlesource.com/platform/external/python/pylint": { + "refs": [ + "6169a46fd0a78ed1f3c9fd2c41c1636eb0ed35c5" + ] + }, + "https://android.googlesource.com/platform/external/regex-re2": { + "refs": [ + "2e598de2ffcec7903d52742d4ecb80f11e7e1b92" + ] + }, + "https://android.googlesource.com/platform/external/shaderc/glslang": { + "refs": [ + "2222fa5818324771ceb99fd8802e54a50a2fb1a4" + ] + }, + "https://android.googlesource.com/platform/external/shaderc/shaderc": { + "refs": [ + "8045a61b8c6b79c9fdaa86f36653a824880bab4d" + ] + }, + "https://android.googlesource.com/platform/external/shaderc/spirv-headers": { + "refs": [ + "907059dfed550925a45217e1ed9a7bc42ff8d770" + ] + }, + "https://android.googlesource.com/platform/external/shaderc/spirv-tools": { + "refs": [ + "12f5c853ee9e06ba6565006d8d36ee261a140d91" + ] + }, + "https://android.googlesource.com/platform/external/toolchain-utils": { + "refs": [ + "d71e320ab860721f764fe7403588641c8a7bc65d" + ] + }, + "https://android.googlesource.com/platform/external/vulkan-headers": { + "refs": [ + "062f62b42a62e18a8eaccbce323d4f58548677be" + ] + }, + "https://android.googlesource.com/platform/manifest": { + "refs": [ + "82eb8adcaafe02dce4e462db2379fad3ea0b54d8" + ] + }, + "https://android.googlesource.com/platform/ndk": { + "refs": [ + "196e0661200bad5361340700fea67be12e1f1684" + ] + }, + "https://android.googlesource.com/platform/prebuilts/build-tools": { + "refs": [ + "434d914996ecc2abcda46a1841c82946241b1c35" + ] + }, + "https://android.googlesource.com/platform/prebuilts/clang/host/darwin-x86": { + "refs": [ + "2ede290b28d234595fcc23207c633961690c57ba" + ] + }, + "https://android.googlesource.com/platform/prebuilts/clang/host/linux-x86": { + "refs": [ + "568b941cf0c249b9c2a1f853e94a29f0e6291c59" + ] + }, + "https://android.googlesource.com/platform/prebuilts/clang/host/windows-x86": { + "refs": [ + "31edac0247a8e13bd12d2f7359fc290689c84ab8" + ] + }, + "https://android.googlesource.com/platform/prebuilts/cmake/darwin-x86": { + "refs": [ + "7aea7e9880110799088cd1de509886871078306f" + ] + }, + "https://android.googlesource.com/platform/prebuilts/cmake/linux-x86": { + "refs": [ + "e57c88d59d7d8408a32b16425158fd2aa64e2b3e" + ] + }, + "https://android.googlesource.com/platform/prebuilts/cmake/windows-x86": { + "refs": [ + "f6283abb0a655968016437be07d04370fd815e6c" + ] + }, + "https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/host/x86_64-linux-glibc2.17-4.8": { + "refs": [ + "49917e030f76c01f35d5a46b66a2b85b2976647c" + ] + }, + "https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/host/x86_64-w64-mingw32-4.8": { + "refs": [ + "d6b93efcc5c2d123cb44eee4f74d6fd35d5efd9f" + ] + }, + "https://android.googlesource.com/platform/prebuilts/ndk": { + "refs": [ + "c0815fea3a8081be6215440de330c63246e6551f" + ] + }, + "https://android.googlesource.com/platform/prebuilts/ninja/darwin-x86": { + "refs": [ + "f321e197944c19d273cec788b9a3e8ca94331248" + ] + }, + "https://android.googlesource.com/platform/prebuilts/ninja/linux-x86": { + "refs": [ + "8a10824f74fe0e22af9bf314a837f5b70e2bb67f" + ] + }, + "https://android.googlesource.com/platform/prebuilts/ninja/windows-x86": { + "refs": [ + "4d526002f0158a5d103bb6e54d43943c0e1c2778" + ] + }, + "https://android.googlesource.com/platform/prebuilts/python/darwin-x86": { + "refs": [ + "3400487f6a77cc05ee5d4799575372713ce63232" + ] + }, + "https://android.googlesource.com/platform/prebuilts/python/linux-x86": { + "refs": [ + "fce2346610379fdcce9dc7423c0e9a04e1a43cbf" + ] + }, + "https://android.googlesource.com/platform/prebuilts/python/windows-x86": { + "refs": [ + "6d619afe3f821388a57b7b2b473bee85debfdd7c" + ] + }, + "https://android.googlesource.com/platform/prebuilts/simpleperf": { + "refs": [ + "c04e1425e49ad7a106bdb5911e7ebbc5ff4afa20" + ] + }, + "https://android.googlesource.com/toolchain/llvm-project": { + "refs": [ + "3b5e7c83a6e226d5bd7ed2e9b67449b64812074c", + "5e96669f06077099aa41290cdb4c5e6fa0f59349", + "c58bc24fcf678c55b0bf522be89eff070507a005" + ] + }, + "https://android.googlesource.com/toolchain/llvm_android.git": { + "refs": [ + "e727bfb014bd436f581a66a450c939a6983a1fc3" + ] + }, + "https://android.googlesource.com/toolchain/make": { + "refs": [ + "44fc4fe66a484b91844c302f03eaa8438e065d17" + ] + }, + "https://android.googlesource.com/toolchain/yasm": { + "refs": [ + "7a28367b72cb1e1667b081d6404afbd063898e70" + ] + }, + "https://boringssl.googlesource.com/boringssl.git": { + "refs": [ + "02f0d8776ecd83a1c663db2eaba6283aa72cc5b8", + "2db0eb3f96a5756298dcd7f9319e56a98585bd10", + "567289e4bb1958153f428bba52d953f3c080b4d7", + "5e73d0302c50cc38324686f937a75233d13ae4f0", + "822902749a5956bba09c7e9e451104e8a74f02c5", + "be5be0a4f5ebf00da151a06860deb11a0ffb609f", + "d24a38200fef19150eef00cad35b138936c08767", + "d5440dd2c2c500ac2d3bba4afec47a054b4d99ae", + "ef839bf397fb4ecdb66ef2679a08ac7b3563c50b" + ] + }, + "https://chromium.googlesource.com/chromium/deps/icu.git": { + "refs": [ + "43953f57b037778a1b8005564afabe214834f7bd", + "81d656878ec611cb0b42d52c82e9dae93920d9ba" + ] + }, + "https://chromium.googlesource.com/chromium/llvm-project/cfe/tools/clang-format.git": { + "refs": [ + "bb994c6f067340c1135eb43eed84f4b33cfa7397" + ] + }, + "https://chromium.googlesource.com/chromium/src/third_party/jinja2.git": { + "refs": [ + "2222b31554f03e62600cd7e383376a7c187967a1" + ] + }, + "https://chromium.googlesource.com/chromium/src/third_party/markupsafe.git": { + "refs": [ + "8f45f5cfa0009d2a70589bcda0349b8cb2b72783" + ] + }, + "https://chromium.googlesource.com/chromium/src/third_party/ply.git": { + "refs": [ + "604b32590ffad5cbb82e4afef1d305512d06ae93" + ] + }, + "https://chromium.googlesource.com/chromium/src/third_party/zlib.git": { + "refs": [ + "108fa50cda23ed4a712a098d058dccbbfd248206", + "470d3a2ee4ef721688ce6961bc865a99fcb64070" + ] + }, + "https://chromium.googlesource.com/external/github.com/WebAssembly/binaryen.git": { + "refs": [ + "3f6831c0bd147ae1ae0ab1d9187d37bce7cca38b", + "654ee6e2504f11fb0e982a2cf276bafa750f694b", + "8470f1b1f157201d1bc62f3202e474e7043df0ba", + "87f9dac127b387715d8d96ac7ec8fd469d8c2dab", + "93883fde36ac158fd415dcd6dbd387dcfd928d3c", + "b4bdcc33115b31758c56b83bb9de4642c411a042", + "d844d2e77b402d562ade8cf8fd96759b587bf09d" + ] + }, + "https://chromium.googlesource.com/external/github.com/google/cpu_features.git": { + "refs": [ + "936b9ab5515dead115606559502e3864958f7f6e" + ] + }, + "https://chromium.googlesource.com/external/github.com/mdn/browser-compat-data": { + "refs": [ + "ac8cae697014da1ff7124fba33b0b4245cc6cd1b" + ] + }, + "https://dart.googlesource.com/ai.git": { + "refs": [ + "64dfa7f138aa4d9bcc06e807858136b7d4d296d3" + ] + }, + "https://dart.googlesource.com/args.git": { + "refs": [ + "09c0fca1785c9df39288a48f767994eed80bed40", + "6a5a2e6b1f0020b873c7ffbdd36a784c4f9ee300" + ] + }, + "https://dart.googlesource.com/async.git": { + "refs": [ + "5f70a996f673d625e3502597084653686c3e754c", + "a00437017231ebb6c3e3e8ecdfc9dd03522ab828", + "c0d81f8699682d01d657a9bf827107d11904a247", + "d7c0cd5a458308ab5e5a0d0deebdce32c4391ec6" + ] + }, + "https://dart.googlesource.com/bazel_worker.git": { + "refs": [ + "aa3cc9e826350b960e0c5a67e6065bcedba8b0ac", + "c76d7c86381a6ed594641ba03b55c65b84ee11a6" + ] + }, + "https://dart.googlesource.com/benchmark_harness.git": { + "refs": [ + "44f125ae1d045aa3de09fe88a8dd70cb7352d563", + "f6ef33dc88d7cbc9e4a8a087f1e652eb0d6cc254" + ] + }, + "https://dart.googlesource.com/boolean_selector.git": { + "refs": [ + "62f82f6a333b419b457e62cadc17b7a9c0545873", + "c5468f44fd9ca0ea3435e1a0a84ff9b6fac38261", + "d6c7c36ae1111f11cc24306d71d3ab2deea8fa68" + ] + }, + "https://dart.googlesource.com/boringssl_gen.git": { + "refs": [ + "7322fc15cc065d8d2957fccce6b62a509dc4d641", + "9c7294fd58261a79794f5afaa26598cf1442ad20", + "fef055e8d2749b82c79c8f043be1cbe5e8e4b40c" + ] + }, + "https://dart.googlesource.com/browser_launcher.git": { + "refs": [ + "60126904a26b761d29b4f2d76292ff3c089160de", + "7348ceae6508e5350771979c2951a54313303416", + "e5fc5d488eb5038bfec2a6690c72ab8dd353e101" + ] + }, + "https://dart.googlesource.com/cli_util.git": { + "refs": [ + "64192706344d0598784bebe1abc4a9bfc2608de0", + "c36b3941e38092d6d6f87ac27d9e88f153d3ac38", + "c37d5e14f50e72a268c1ad86149cecfa4b58c494" + ] + }, + "https://dart.googlesource.com/clock.git": { + "refs": [ + "7956d60042f4ea979c4554d43eeb57d087627869", + "7cbf08e36a92f14f22132d255846610c1b065324", + "ad428ea8b75fa0d7ba629791552d40478745c54a" + ] + }, + "https://dart.googlesource.com/co19": { + "refs": [ + "2424cfed7eedf53a122f8bfdbb6319692f726ec8", + "2c7f9a6a379cfc49b3e9019d1f616d7ec9edd766", + "3a1b6f75c771d62e7150f2dd69595a98fd6930f4", + "4ebc13c27af77129889a11fd1f95cff04dccd8f9", + "7b457e8d8c10361424beb7b432347f668c974439", + "7e4321a5cb2d8fcf9c3c818e62ef6d6f4fd87626", + "831b22d5e496fe63a813ca1c1b64f533c2f9fa0c", + "a5d7b62b78dd9278c30a44cb2d22b8870b360a0e", + "d285ef839784162ca988a9d149522249d0c00c5c", + "d50a305d1b4455b4e72ba45a2cf2ab1c37004bc6", + "dd66678fea1d11bc6295a688ed5f8e726034f762" + ] + }, + "https://dart.googlesource.com/collection.git": { + "refs": [ + "887b826b50f48d6a9cd2c0684aa353e8e3a0fad0", + "9354f386de3c57f5486b01ab4dfa1a2f033307d9" + ] + }, + "https://dart.googlesource.com/convert.git": { + "refs": [ + "0c9eab7d4656be97329c4970659afd53a78910e6", + "9035cafefc1da4315f26058734d0c2a19d5ab56a", + "d361833e117cb2438d2a2a6d0b0acb28ff0910fb" + ] + }, + "https://dart.googlesource.com/core.git": { + "refs": [ + "15c7fe9958b95998ba2f5a4ad1beab66b9d815fb", + "61e677100b06d56a1b3731ab1178ebf9102ecb1f", + "635dfa32c261ba078438b74de397f2207904ca78", + "7a71ad6b9170e09d5cbe39f3fccdee648659f1e7", + "abcf992cf9fe1e896ed9dcff15523c0a6c00621d", + "b59ecf4ceebe6153e1c0166b7c9a7fdd9458a89d" + ] + }, + "https://dart.googlesource.com/crypto.git": { + "refs": [ + "1216790ba704a0ab194f9cd0da2d65e1767f3342", + "3d26ef4cf22d4b218ba30e616544ad3cf52f64a1", + "813e35e913d12e16de67ac57523cd0ff4b07c012" + ] + }, + "https://dart.googlesource.com/csslib.git": { + "refs": [ + "192d720f121792ab05ca157ea280edc7e0410e9c", + "23c314bb6b247a71348cfb0987ba0eb29574abb6", + "a3700b05bbcc42782e8a7024790dbf019d89c249", + "b70fef222c8a98abca39c3f729ec34632089697e" + ] + }, + "https://dart.googlesource.com/dart_style.git": { + "refs": [ + "100db45075abdd66fd8788b205243e90ff0595df", + "1de89eb3bd340315f9ff5f2afc319cc1d6131b8d", + "21de99ec0ff8ace4d946a746fb427fffd6afa535", + "44e8cfe7ba5a873ef81b6b39c07d50171eccf021", + "5d35f4d829ffb8532d345d95d3e9504ae6cd839e", + "a6ad7693555a9add6f98ad6fd94de80d35c89415" + ] + }, + "https://dart.googlesource.com/dartdoc.git": { + "refs": [ + "14d33d3a120ad3ce621bbcf0a545dc3adeccd7e7", + "34561d6ebf5fa89ca1f93b981de96a75ff573562", + "62aefbb788baf5b73b2d704d66d9735a7ca56a69", + "7e5da6090e6a48cebaee8789ca0fc396b34fd8a4", + "80c6f18f34b387d4b9ce89ddd2e3049093335f9d", + "882aea9351262d618c955322f4c9aafe9540b848", + "88df88c9278ec4ec31df818f3ae33d4f91c8cd64", + "c7f11603effa88ddacabfd555993f322fca8b3fe", + "d40067626b8c419e451897447e4dae74d25bcc37" + ] + }, + "https://dart.googlesource.com/ecosystem.git": { + "refs": [ + "06bbbffc1dae26164ee0a9603d0a30af620b84d0", + "23172636e60c52384b40e6bd1240d12c8e860122", + "248b1801131ddc2e738c8181fc32d488e1312052", + "2d58550f9e3fd8ecbc3b2e4444095fcb204a66c6", + "31148cd81bdb3c248fc30cd345ef49a978ed454c", + "54ca01abe4b7b62419ee88814d3dc98df36ff8ff", + "7f6f1c1d53173307bde1aa4f4ee851d260cc7e69", + "815d4ba2e7d11f8695a26f6cbe1262e3b8ff8d0d", + "8ada2ee303383cf62cace9b2a97e8a3cc983e5c1", + "d5233c6dd0767cffa5742e32c4bc7c230c9c4b12", + "efe4ee4af6ac2e4c90aa525fae213b65c97295a9" + ] + }, + "https://dart.googlesource.com/external/github.com/emscripten-core/emsdk.git": { + "refs": [ + "e41b8c68a248da5f18ebd03bd0420953945d52ff" + ] + }, + "https://dart.googlesource.com/external/github.com/google/file.dart": { + "refs": [ + "07cacaed6679a173e29176747e6ce0325742749f", + "6842feaef1c4e06239bd30f8d3ef722838b1c97e" + ] + }, + "https://dart.googlesource.com/external/github.com/google/vector_math.dart.git": { + "refs": [ + "13f185f7e97d559e003f5ac79201da12f9a01049", + "2cfbe2c115a57b368ccbc3c89ebd38a06764d3d1", + "433fb6c829b18719fd0db4a703b607a26b7d81f4", + "533c513771d35312dcd0f69e662d729979882df1", + "bd4b574b2a457a3955d223694f1a979a0c0f38c9", + "dc9d379674f50bb5559e99ee3a9f64729df9d3c8", + "e7b11a234638bd5d76a05bae99d20b937637dfe8", + "f08d7d2652e9ecf7d8f8605d9983335174511c95" + ] + }, + "https://dart.googlesource.com/external/github.com/google/webdriver.dart.git": { + "refs": [ + "718e4c37d004fceb9856de980782c46bf9576df5", + "accfed557c005c87df56ffb626458f87da9f2125", + "b4fd8592fb9b1405fea3979cab88bcd857f2addb", + "cfab787b30fbfb5509f9fc45cfce51157fb9f369", + "d83d6a3cbaab152ff9b99b29382d1f48b5d5ba23", + "f52afbf72895ae980bd4129d877305c2182d6cbc", + "f85779edd7c9f66198d4391ed3631db1d97a5b11" + ] + }, + "https://dart.googlesource.com/external/github.com/google/webkit_inspection_protocol.dart.git": { + "refs": [ + "32fffa53df3f54005c742ddf4f859fb585a6b254", + "5740cc91eaeb13a02007b77b128fccf4b056db6e", + "b459c427b74bf5e0919a083a97a167fb74d8bff1", + "effa75205516757795683d527c3dea9546eb0c32" + ] + }, + "https://dart.googlesource.com/external/github.com/simolus3/tar.git": { + "refs": [ + "552a49d7595e444184d4f91e9afd533aa253a31d", + "5a1ea943e70cdf3fa5e1102cdbb9418bd9b4b81a" + ] + }, + "https://dart.googlesource.com/fixnum.git": { + "refs": [ + "6c19e60366ce3d5edfaed51a7c12c98e7977977e", + "83293b8ed86ccd574a94fcf4a2da43f31c1b43e0", + "a8157d87f17d5184e210403f2ed63d354b854132" + ] + }, + "https://dart.googlesource.com/glob.git": { + "refs": [ + "00a9c82d31c01ae88ec9ae4021d842e9b832aa52", + "6d3ba5ec02817e62d17ace040590bb81a3e1242f", + "994191a107b99a1911a3ef52ca238cd9305c8d37", + "eaec6a448576048b748475d80bfac2795ad5a267", + "eee18d1a577d5f965f6afbbd251798e065dced43" + ] + }, + "https://dart.googlesource.com/html.git": { + "refs": [ + "0da420ca1e196cda54ede476d0d8d3ecf55375ef", + "3bc803d7e655491b243418f19300ef0c6112bcea", + "6d3bc86cf2ab530ef3fa5f84b5980dc318a02af4" + ] + }, + "https://dart.googlesource.com/http.git": { + "refs": [ + "1b6e28d7e1c61f7b0f8561be7aee9c35b03de193", + "4d8e7ef73d6135a8cc9b5e53db1beb43977d44b0", + "6ecd13a88b82c2fdc8a555f218bafb0ad0370f51", + "79470d014b467f01b0e7c5b63ab6c86b22dec8db", + "7d2d87ebfba86035a9ca6b79160ccc2ac1253c0c", + "8c325b9ca33d878a86d69c5048a8e6e18379663c", + "8d893851904d8cd292a66e39812b59aca2cc4d96", + "900da9fe7d576caa4882053cf26d3a70bd3106e0", + "e4ddd3e3d3a3d0ba7c9e48506e9d2e8620af30a8", + "f59cd79e1322c6272481e4f2ccfa9afcb37a6525" + ] + }, + "https://dart.googlesource.com/http_multi_server.git": { + "refs": [ + "25941e260658efb324de857e6022f418faf9bdd1", + "e7515b5896b83d522189802a1e14e103e19426c0", + "f6a748819139b8cbf513d5fc36b10676b0cb066f" + ] + }, + "https://dart.googlesource.com/http_parser.git": { + "refs": [ + "23d775898ee90be9daf3297e298a8869bc755d84", + "71b4c2c448b333397d5ff3235825d8cea773291c", + "9bf7bd981a39137da1e5d7fe64f4652b078c7aa9" + ] + }, + "https://dart.googlesource.com/i18n.git": { + "refs": [ + "06a664f7beaab1f8eaf82a60b722982c03c8657c", + "c45e050426bdeaaa120e5ce856abb486863d0476", + "d9cce0b6348b51872fb269e43ff8a43120fe191d", + "de1943629469719bf34269bf90fcdbe9334a73f3" + ] + }, + "https://dart.googlesource.com/intl.git": { + "refs": [ + "5d65e3808ce40e6282e40881492607df4e35669f" + ] + }, + "https://dart.googlesource.com/json_rpc_2.git": { + "refs": [ + "5b1cbd679756700d5f319bf10a217da53e98ea52", + "616937f6d3837e38a2a287653ddaf722de260702", + "c9b616bded8cdb5bfdc836ba7648afa6aba40062" + ] + }, + "https://dart.googlesource.com/leak_tracker.git": { + "refs": [ + "f5620600a5ce1c44f65ddaa02001e200b096e14c" + ] + }, + "https://dart.googlesource.com/lints.git": { + "refs": [ + "5016d63c889936b2100520f999591d0492d9afe3", + "baaaa5616370243c3c8c6a9f67fb83d26bdac552", + "e1d4794412aacd3bbb370956d44b9a10c3f892f3", + "f6b5d36485f6f067ac0f5a7193006ebe82ee6113" + ] + }, + "https://dart.googlesource.com/logging.git": { + "refs": [ + "240ec33e23720091e0e5a029d569a3770ddccf1c", + "6c3fb37fecb2e30415072f327b834a3e95517fa9", + "6fa056098ceca03d399bff64592822b2ae5dee6e", + "dbd682919708316e9a6d1e2fa472c9ad9225c2b4" + ] + }, + "https://dart.googlesource.com/markdown.git": { + "refs": [ + "19aaded4300d24bedcbf52ade792b203ddf030b0", + "3d8d7a8f14b74bb646bb6e4ae35e0bf2beb74154", + "4d5dbc659955973902f2585c54e94d453532db70", + "62424376d0b5fe35a2957b3caed4b75db010ba82", + "d53feae0760a4f0aae5ffdfb12d8e6acccf14b40" + ] + }, + "https://dart.googlesource.com/matcher.git": { + "refs": [ + "0abd4054c47a923486a6c0c04b5c974ba13ad2da", + "31f13583630e093731c8cf2b843c14196d748c5c", + "d6d573d0f8d65b36550ce62aad3ce6b5e987b642" + ] + }, + "https://dart.googlesource.com/mime.git": { + "refs": [ + "11fec7d6df509a4efd554051cc27e3bf82df9c96", + "4ca2f5edaafe21f462922d34db99486a44bb08b8" + ] + }, + "https://dart.googlesource.com/mockito.git": { + "refs": [ + "2302814df66e651b6710311366501523dbee2e11", + "57d484f9b8e7f6a504966a901174358a42fa932a", + "a7fdf7101fbd31132a59188a6057d21004345927" + ] + }, + "https://dart.googlesource.com/native.git": { + "refs": [ + "028f89d4a59448f9ecda5bd3d4519e2d7c742072", + "14368a80bae9e3f381a2e59c91405338d82451ee", + "49a8912734162e5dc6ad009fc080fe54e9985470", + "4e71c281e4e3c262b28b7ab5b3306e4029b78b1c", + "659511886501bcce638c3966590df04984909ef0", + "723cd56a5edc89699db32bca1b5bf91aa0bcf0cf", + "f08677646f9e5e9a8a233fed1ec324a003609260", + "f1fa5be4b0d7449fa8fe4077113ac0413d2b16bf", + "fcc783c1d2777555616dfc850f131878ea5d88a9", + "fef40aebc3cf34654919e8a5785b6c50b3ea445c" + ] + }, + "https://dart.googlesource.com/package_config.git": { + "refs": [ + "07097d7ae60d40b34ce8daabdce318ecc168b7d1", + "76f2f6c245451da1fa24d7bbb00251b909e729a5", + "903a0e528f91aef90821c8f5eaafbc1ae27198ab", + "bafff8e90be25e1985f7e3ee40ea1d22571a93e6" + ] + }, + "https://dart.googlesource.com/path.git": { + "refs": [ + "04807b61c25f98f328b322ec511451f9f86f98bb", + "e969f42ed112dd702a9453beb9df6c12ae2d3805" + ] + }, + "https://dart.googlesource.com/pool.git": { + "refs": [ + "7bfc71b39742753a88688e56e55a828a2f5dc0bf", + "832c5ab5eaee444354a8c796f7998bf744f169af", + "88e463600c636a0d8cdb5dc306524ebf04b06baf", + "924fb04353cec915d927f9f1aed88e2eda92b98a", + "bf27900420ba382b6e5c0484ab3c79daad703dcd", + "f85209d83cb0aa3c5612ed80de32df51ba580abd" + ] + }, + "https://dart.googlesource.com/protobuf.git": { + "refs": [ + "0bab78d9538e49d50023bab36159b15ff3c369eb", + "1aaa332af75c61ff32739821f7ec52186ff18d4c", + "610943a3bed70c1c2079af5fca02462df10d223f", + "b7dd58cdbd879beee4c3fbf8ee80fce8e97bad26", + "bce362dec347ae3cca085bd28db2aa2649f754e5", + "ccf104dbc36929c0f8708285d5f3a8fae206343e", + "da7279c56734cffed4deb1e3a6f93bdcefccf6b8" + ] + }, + "https://dart.googlesource.com/pub.git": { + "refs": [ + "1efd3f5e274e153637d99698b0ee454f6f2550ab", + "30bfc439fedba1ee3daadcf542f1483479bc4909", + "52f512315bc886de487061091ef82056abf9dab8", + "58de642dc1d07601f6eb2b4ecd94555c0210106b", + "639536aa78f7382b4a948669bfdc283f830b2ae9", + "b2c03b448a47fdd52800609b9222cd737be3a934", + "ddc1c2fd2e2a7cd94a0b92ea033961a25f4ad517", + "ea4a1c854690d3abceb92c8cc2c6454470f9d5a7" + ] + }, + "https://dart.googlesource.com/pub_semver.git": { + "refs": [ + "8cce9d00431b6653026cdfcf6cf8548078c56f02", + "8e9fcb9d3f89f06022387f906da4d380688f935c", + "960f91309e325ae037e5f1434acb77b83a12d91e", + "a9025f3cc23ebb0f86c0af8759d95306b9133ce0", + "d9e5ee68a350fbf4319bd4dfcb895fc016337d3a", + "dfcad38866fb1e94e8ca91bff3dddd5189fb0794" + ] + }, + "https://dart.googlesource.com/sdk.git": { + "refs": [ + "2d5dfe32cf2e6b3c3d6b396885502a5402b4fc72", + "2f5a888a5e6a7316074416822a9584d54e3f5ab5", + "4a4ff9fba9ca67e9406743a24a3c47ad64d9e9c2", + "4bb26ad346b166d759773e01ffc8247893b9681e", + "5a8921e0042c662ea2adbac35ea051dec20a5341", + "7d7fbb30e0ca19c76800b1ad388fa55d09037e66", + "7e6469bd51d404916395a47b011d907d2c905121", + "7fce3544047c41018b8c00b4453c0262f463dd74", + "a8bfb132c5f7b9555d13ea79eaf0eaa77825824d", + "c7e47c6c5df6ffa16d92704d5291b3387f974648", + "cf0d430bc6a507b3d54d4b5bfc91b308f0325178" + ] + }, + "https://dart.googlesource.com/shelf.git": { + "refs": [ + "082d3ac2d13a98700d8148e8fad8f3e12a6fd0e1", + "2536c15a562cb183dabbc628824a215663830325", + "2af8529640d10a247ebfa4e17e629a2ff5273656", + "2b5b683e78f5cc84e479a43297fd7b5489d7db02", + "4c54af6b6baa9404826d234385c1bf69575dfd47", + "9f2dffecbe8f219146a077e401758602752d486a", + "b39e61196ce555dc1d3a0c3da695228fa6bdebb8", + "f5600534e3e49ebed02e1e14ec82553958d86f36" + ] + }, + "https://dart.googlesource.com/source_map_stack_trace.git": { + "refs": [ + "741b6ceb4b6cdb8ff620664337d7ecc63ca52cc1", + "96a8213dacf7cd42aefb1311491a4169826f98d2" + ] + }, + "https://dart.googlesource.com/source_maps.git": { + "refs": [ + "17695e81d9ad129d20effd3d5c4f1cfa03f5add8", + "198d32bbde2f5736c04dfbab306a17096fd1648b", + "caa79c2011015759c6cf3299f299f5cccdf8bb61", + "e5e9d343302acf7df2145316ae4e56026c550989" + ] + }, + "https://dart.googlesource.com/source_span.git": { + "refs": [ + "22a243eb50d926935a8a1300a49af6d2988c3ae6", + "59a3903521dbf4c38c77df73669e73174a170327", + "89520f3009e332ce2b6675f71dca166521c36cc4", + "e6a34591b7f7880c7ca0fcb95b858ccf7f8be304", + "ec100b7f12e9d36d2cdb3c369fefde736de4a550" + ] + }, + "https://dart.googlesource.com/sse.git": { + "refs": [ + "52d042ff9ab2d0e5bc26805d74a03077a67861e1", + "7dcde164d5bfe707441f206379ef33e7509e2aac", + "af2c5c572a8da6d2f7551b80d75121f2a38a4c79", + "b573a1e9a61f5f3e2198becfa3f4f2e8decd1e90", + "b97dc3ad9a58a454dc5ffe5b3ec814dadc389e32" + ] + }, + "https://dart.googlesource.com/stack_trace.git": { + "refs": [ + "115bcd9591d251dab7a5ad518655c2124a1cc525", + "4fd3e2a2dc6611febf4cfb9197ebf9e60fc6a34d", + "5fe4cfea7f0d8e67b7d5738d2e1c64a18b5ba450", + "ab09060b82c936c38c04eb49c1154b83f6648349", + "b660cfa444d46bcceb3a0eacbd6a2a7829da11de" + ] + }, + "https://dart.googlesource.com/stream_channel.git": { + "refs": [ + "28a65331aa2d66a5e953205aa462bcdb1e240a5b", + "31a3aba8a78a78b266fbf7474f19cd4ba9ca562e", + "71fe6dd315e7f451466da80f7af2661cd28aaaea", + "b41ff7a25395ace8b23e454e3d1a3459a71306ca", + "f4407168b275fcde9187baefd7dbce76d0992825" + ] + }, + "https://dart.googlesource.com/string_scanner.git": { + "refs": [ + "084b201c54b168aced178fff41fce71e3869ae42", + "0de03b5279a04aa05052ce306f90fca473c6fd1a", + "69212690d491603a511904a7a84cd502f34bf7a9", + "77de235c061a09264cae920e52939787325c8cae", + "7b37c1b3d1ca6b581792e6ba385f651573af4a45", + "e1cab8f0538b50f6d7180598752cf5a7e07e74db" + ] + }, + "https://dart.googlesource.com/sync_http.git": { + "refs": [ + "47e6b264a209d0d806cfe9cdad8b6c69ce231986", + "7622bdd07501f3f279212e355325b7c84a2b0a08", + "91c0dd5ef9a008f0277aadcfd83036f82e572d09", + "c07f96f89a7eec7e3daac641fa6c587224fcfbaa", + "dc54465f07d9652875deeade643256dafa2fbc6c" + ] + }, + "https://dart.googlesource.com/term_glyph.git": { + "refs": [ + "19d8c08a4e81122639129c62049896021910c932", + "38a158f55006cf30942c928171ea601ee5e0308f", + "52677db71a2c6b6d0018ebbe5ed7552dbae1248f", + "9ed8ed96fdd84cb7b72ee1be3e86010969fa95d4", + "c86e8171ee7e9f6fc8e775e0be755a603dd0b72d" + ] + }, + "https://dart.googlesource.com/test.git": { + "refs": [ + "20967732ea9dd30240a6429621ab2f82874bd9f0", + "2be5ca067bdf09e999be2ad760ab8efab854e789", + "3256c23cc753a184bb3bf27610a7c8410735e3ac", + "329c6dff4dfcb178ba6c7009cf1c1b9215b317aa", + "84eba115521b74e848f096572a2d3e4d3607e8fa", + "8643fbf375330cd1099cdc7434306532b4bcaaf1", + "8e8a83607d90a7a6813fa378b2d1962a2fc0d44b", + "9e349d0e9f6c477584ea320f7ba2f49f761d84ac", + "a833663e56b6182f8372180f5c95d1c01b531150", + "f364fc8291d668d85c702a5b9f9a4f2e5c1ade0e" + ] + }, + "https://dart.googlesource.com/test_descriptor.git": { + "refs": [ + "2f19400259e6ec6801a79dcbf038b235545ab400", + "408526a84e74d7af0f9c8c3fbb49ce9178927ee0", + "90743bc16bc00526a1b9a64f813614be9b2479d9", + "92fa0c551267b38e4b27c9f74976ae4cd96d8b1e", + "a3db1efe3dc725dcae9ee61647d3bfc19b3231ac", + "b23d7ccb0f9882e161fb4dea75b2237bf428432b" + ] + }, + "https://dart.googlesource.com/test_process.git": { + "refs": [ + "52ee3f5ab70ed965bb7122c1d499081fbccd0bde", + "5b0349ca18fe48cd527f74ac883db2964cbdba40", + "6223572ca16d7585d5f08d9281de6a5734e45150", + "862eaf3b825f5e97b278d84a2afbe81b3e8a1683", + "a7ca20b73f28d220e6478254082ea2b52f46dc97" + ] + }, + "https://dart.googlesource.com/test_reflective_loader.git": { + "refs": [ + "598af2f503955020af0eaa82558d574a03934078", + "6e648863b39aab8d0204e769d25805eea9db0ac4", + "816942eaeeac30cc59d8699f1e94ad779cc53c06", + "9e35c9e00b8b6299e9295c0f29617af39276717d", + "faade6299d1823f0d062eb5e98f3b440ddcea7c6" + ] + }, + "https://dart.googlesource.com/tools.git": { + "refs": [ + "1c5b8b949128d62182e162ef65a2e6f3feb19acf", + "4321aecf2cb618dceab5d90adf0cb2ef7207169c", + "43a8582a85d2220b5f1ca8383d97587792085b36", + "4a284152c263a5d3429d5ab6acfdb70eca2ebcfb", + "62bc13bc086a66ce9a6a3e64865c82d17a1379b3", + "b412ba4550bb634caf3c1064b7ebb671cd5e9247", + "b51f39d01f5a4af33428a0189cd62595c01e23de", + "d74f9e13dc02736f12ae57d5984c57024113cf5a", + "e660a68dce659311fb47735ab00365e26fca2fe3", + "f882de9ba86712003728d4663e1b73a620d352b1", + "fd7cc89aaac774fb34502502803a3bcf62cb83cd" + ] + }, + "https://dart.googlesource.com/typed_data.git": { + "refs": [ + "365468a74251c930a463daf5b8f13227e269111a", + "6abfafdcf661cd8a814619d7e2a3e99edb3a3862", + "85299290551297a28202b6e7a177bb787f790ffd", + "d14f9654f7a5d6baa7dcc27691bd0fa56769fb67" + ] + }, + "https://dart.googlesource.com/watcher.git": { + "refs": [ + "0484625589d8512b36a7ad898a6cc6351d24c556", + "3b850778ad0b62db3aa2cfe48832870c2461db30", + "7f3b3a3ea49ba7e21fff240ce8ee616d62d32956", + "bc44e6f6b85972e516c44b9ae6c042b4cbd7c72b", + "c00fc2a6cd869cdebbc52e00af3d912d25745729" + ] + }, + "https://dart.googlesource.com/web.git": { + "refs": [ + "2fe754fb396cb9b87010f0318cfbfc5408346c48", + "354e22995859757223cea3fccbff0ad86c540d60", + "5a39fdc396ae40344308975140343c23b6863261", + "6b8a46561b82de9b20d77d9ac491844d303ca08f", + "8478cd27d574249eca3d41f9135458dfda2762c8", + "af5de5e8548060c0795713ee7129ba6d5ff9f1b2", + "bdf112ec64d28285cc29c6c78274ff3a827bb79b", + "c2d5f63e9ea4c1409d6e159fc7b92dbcf4dc0d4d", + "e4c4d8126466e28dc137890b8f999da59bdedddd" + ] + }, + "https://dart.googlesource.com/web_socket_channel.git": { + "refs": [ + "40aa29f1d2167467f5934d755891a8beb62a1239", + "7a2039fd7c4c656ab27850926f89103b5f188dab", + "8e95ea75302180af075295f7dd7ffe922e26f789", + "a937243563e8ee75d11fb23610297d4f6e5cb2b9", + "bf69990738f173c07e67cf6945551194bc8c2d92" + ] + }, + "https://dart.googlesource.com/webcore.git": { + "refs": [ + "bcb10901266c884e7b3740abc597ab95373ab55c" + ] + }, + "https://dart.googlesource.com/webdev.git": { + "refs": [ + "302b6db6125901fd183390e339aff7490cdde3d0", + "5bf833d0c277a384ab8bbfc10e7d3d71b8022560", + "5f30c560dc4e3df341356c43ec1a766ee6b74a7c", + "75417c09181c97786d9539a662834bed9d2f1e77", + "7f376d242709e933fff70610503d0c5c09b2e17e", + "c56611255f3f02642da10750448a8c90a9fa7b47", + "c8b1cfa9d12c680b612eb1ed7a6b9f99fcce3ac3", + "e72f365a4408dce73bc023e624adc6a9a72dd7a2", + "eccc7d87982b23f666d5e3e09953dca59ca094e4", + "f4856867de3e7b6ea6778dbc47cff44b12f9eed2" + ] + }, + "https://dart.googlesource.com/yaml.git": { + "refs": [ + "0406507fb719b0c8787896475734747fa35f2b78", + "2a3727288a9336b6f9b7c5236657414ce1ee5d8a", + "30fd9e0cd49b2e04f74769f9b24a0300e400403e", + "4cf24ca3bbcb2cd8cbea32fdd355ee5d0a597247", + "7873b3fb9f16ec83bc7778fed58615fa91f1f042", + "e773005ab84e1b4d24132b0a687be7f9a3bfda15" + ] + }, + "https://dart.googlesource.com/yaml_edit.git": { + "refs": [ + "08a146ef8f2c7aba908d2017c9ec840b882c9e51", + "35f4248c7bbba289b3899fa55486e2f31ef1a8c5", + "57a28daea82a3f00f57a90d5ea6df6a458b2f781", + "fbdc70acc164af187772e013a2e1364cd05b88dc" + ] + }, + "https://fuchsia.googlesource.com/protobuf-gn": { + "refs": [ + "ca669f79945418f6229e4fef89b666b2a88cbb10" + ] + }, + "https://fuchsia.googlesource.com/third_party/protobuf": { + "refs": [ + "24487dd1045c7f3d64a21f38a3f0c06cc4cf2edb" + ] + }, + "https://gerrit.googlesource.com/git-repo": { + "refs": [ + "38d2fe11b9df521727fcca23c9dac086ce8378d3" + ] + }, + "https://git.dpkg.org/git/dpkg/dpkg.git": { + "refs": [ + "f3ad53337eaee92cbeb1a7c73e98d552c3a8186f" + ] + }, + "https://git.kernel.org/pub/scm/libs/libcap/libcap.git": { + "refs": [ + "413789501269f0f258a6716c6fa3edae178ba4a3" + ] + }, + "https://github.com/Cyan4973/xxHash.git": { + "refs": [ + "66979328cf3f15cecdc61ea58c9f81e6071f8983" + ] + }, + "https://github.com/FFmpeg/FFmpeg.git": { + "refs": [ + "d32b387f2b0a484599d4587d651891f0c63c4238" + ] + }, + "https://github.com/MrCyjaneK/7zz_unzip.git": { + "refs": [ + "f802bc7b20bf0626d765ff3fe0ef0adb3fd93b26" + ] + }, + "https://github.com/MrCyjaneK/cmake-toolchain.git": { + "refs": [ + "c4e7b0e5f437121d1b9c05bc5c43dac75371d799" + ] + }, + "https://github.com/MrCyjaneK/ct-ng-configs.git": { + "refs": [ + "2683c3d252b2337e7b045ba5add47c9d05436b98", + "50bad5461d320d2ed46f9d672d722b4e668822b4", + "50eb4f2cbf22872af991c1db5d11f32b6a398d6b", + "8e58852806fae75368c61b271c37b8564dbaa943", + "d6e741a7507f31c5e6e49218a6eb8ff7f2fe2077" + ] + }, + "https://github.com/MrCyjaneK/osxcross.git": { + "refs": [ + "0d1b14468187636f5a23d4adb4f3e5830570bd49", + "643bea6efcfd54769eaaa645dae5037dd7148c94", + "a3e46b026467f0e37ff3c79a015f6c9331190180", + "ea17212e41970b9f602fb30898b5a4013a1fb7af" + ] + }, + "https://github.com/MrCyjaneK/torch.git": { + "refs": [ + "b7a785a538a31ab0cf5baf62d936e3e41182e0b7" + ] + }, + "https://github.com/SELinuxProject/selinux": { + "refs": [ + "919e9e64cc4b20f5a1e4df1e38cce1bfe15aff09" + ] + }, + "https://github.com/Tencent/rapidjson.git": { + "refs": [ + "129d19ba7f496df5e33658527a7158c79b99c21c" + ] + }, + "https://github.com/besser82/libxcrypt": { + "refs": [ + "55ea777e8d567e5e86ffac917c28815ac54cc341" + ] + }, + "https://github.com/crosstool-ng/crosstool-ng": { + "refs": [ + "620b909cd0713f68084378b63cf61b5232757b90", + "a3fef85781d3cda0b27388916f3287826aeec177" + ] + }, + "https://github.com/ggml-org/whisper.cpp.git": { + "refs": [ + "306c88f4d1286aec1bf96e544632897886af5501" + ] + }, + "https://github.com/google/filament.git": { + "refs": [ + "0e58877c09afb1aacd09ff640f74d2adcd2a7e80" + ] + }, + "https://github.com/google/googletest.git": { + "refs": [ + "0a439623f75c029912728d80cb7f1b8b48739ca4", + "b514bdc898e2951020cbdca1304b75f5950d1f59" + ] + }, + "https://github.com/guillemj/libmd.git": { + "refs": [ + "d5b8e853989a73f8fff9dc4e00dccd0b691b84f9" + ] + }, + "https://github.com/hukkin/tomli": { + "refs": [ + "a678e6fdeffa89bd28e4ecc148b926a4e1bbbc7b" + ] + }, + "https://github.com/ip7z/7zip.git": { + "refs": [ + "5e96a8279489832924056b1fa82f29d5837c9469", + "8c63d71ff886bda90c86db28466287f977374237" + ] + }, + "https://github.com/jeffro256/mx25519.git": { + "refs": [ + "e808a6406b254091f4ed83bf8ea35f032da7f0b7" + ] + }, + "https://github.com/julian-klode/triehash.git": { + "refs": [ + "e0bd5e08395bcd5ae105ad279d8d3ba67e8b738b" + ] + }, + "https://github.com/justxd22/monero-ndk": { + "refs": [ + "f0894a6c06fc53542ab5505088f0a2feb5f14f4d" + ] + }, + "https://github.com/libffi/libffi.git": { + "refs": [ + "e2eda0cf72a0598b44278cc91860ea402273fa29" + ] + }, + "https://github.com/linux-audit/audit-userspace": { + "refs": [ + "4db9c700b0c8b24a8113bc00d98101228e7d0212" + ] + }, + "https://github.com/llvm/llvm-project": { + "refs": [ + "450f52eec88f728c89a9efd667dbeaf2dad93826" + ] + }, + "https://github.com/lz4/lz4.git": { + "refs": [ + "ebb370ca83af193212df4dcbadcc5d87bc0de2f0" + ] + }, + "https://github.com/mayanklahiri/easyexif.git": { + "refs": [ + "cd994a3b6009bc3c1f84062e96bd7f5ad16e85f6" + ] + }, + "https://github.com/mesonbuild/meson.git": { + "refs": [ + "751b09390996163348612f0b106114256305ee40" + ] + }, + "https://github.com/meta-rust/rust-hello-world.git": { + "refs": [ + "e0fa23f1a3cb1eb1407165bd2fc36d2f6e6ad728" + ] + }, + "https://github.com/miniupnp/miniupnp.git": { + "refs": [ + "544e6fcc73c5ad9af48a8985c94f0f1d742ef2e0" + ] + }, + "https://github.com/monero-project/supercop.git": { + "refs": [ + "633500ad8c8759995049ccd022107d1fa8a1bbc9" + ] + }, + "https://github.com/nodejs/node.git": { + "refs": [ + "1da054d99bb16d35c54d759f36ccc125b90070bd" + ] + }, + "https://github.com/nothings/stb.git": { + "refs": [ + "013ac3beddff3dbffafd5177e7972067cd2b5083" + ] + }, + "https://github.com/pypa/flit.git": { + "refs": [ + "92c9486a543c4db266e3908bffc984060b8466af" + ] + }, + "https://github.com/pypa/packaging": { + "refs": [ + "3b77a26f5a27473ad3b08194d773f325d018a2d0" + ] + }, + "https://github.com/pypa/pyproject-hooks": { + "refs": [ + "4b7c6d113fb89b755d762a88712c8a6873cddd47" + ] + }, + "https://github.com/seraphis-migration/monero.git": { + "refs": [ + "450c789fbe47e3c8847bf928fad9e7c5ccf39d16" + ] + }, + "https://github.com/tevador/RandomX.git": { + "refs": [ + "102f8acf90a7649ada410de5499a7ec62e49e1da" + ] + }, + "https://github.com/tpoechtrager/apple-libtapi.git": { + "refs": [ + "640b4623929c923c0468143ff2a363a48665fa54" + ] + }, + "https://github.com/tpoechtrager/cctools-port.git": { + "refs": [ + "6e31355ca5babc708681bd906eaaef86c3ac93be" + ] + }, + "https://github.com/tpoechtrager/xar.git": { + "refs": [ + "5fa4675419cfec60ac19a9c7f7c2d0e7c831a497" + ] + }, + "https://gitlab.com/libeigen/eigen.git": { + "refs": [ + "e7248b26a1ed53fa030c5c459f7ea095dfd276ac" + ] + }, + "https://gitlab.gnome.org/GNOME/glib.git": { + "refs": [ + "e33be08bda99f453e497064e9e021d6306bbeb7d" + ] + }, + "https://gitlab.gnome.org/GNOME/gvdb": { + "refs": [ + "2b42fc75f09dbe1cd1057580b5782b08f2dcb400" + ] + }, + "https://gitlab.gnome.org/GNOME/sysprof": { + "refs": [ + "02e50efa49885a5a20a84a8cd7feda10ae7e7e98" + ] + }, + "https://gn.googlesource.com/gn.git": { + "refs": [ + "07d3c6f4dc290fae5ca6152ebcb37d6815c411ab" + ] + }, + "https://https.git.savannah.gnu.org/git/config.git": { + "refs": [ + "a2287c3041a3f2a204eb942e09c015eab00dc7dd" + ] + }, + "https://llvm.googlesource.com/llvm-project/libc": { + "refs": [ + "5af39a19a1ad51ce93972cdab206dcd3ff9b6afa" + ] + }, + "https://llvm.googlesource.com/llvm-project/libcxx": { + "refs": [ + "44079a4cc04cdeffb9cfe8067bfb3c276fb2bab0", + "bd557f6f764d1e40b62528a13b124ce740624f8f" + ] + }, + "https://llvm.googlesource.com/llvm-project/libcxxabi": { + "refs": [ + "2ce528fb5e0f92e57c97ec3ff53b75359d33af12", + "a4dda1589d37a7e4b4f7a81ebad01b1083f2e726" + ] + }, + "https://pagure.io/xmlto.git": { + "refs": [ + "13a831d76467c88f9e79f9804e2471137ec05331" + ] + }, + "https://salsa.debian.org/apt-team/apt.git": { + "refs": [ + "6b128124271e94bdb0f4e7850d9286170d712b04" + ] + }, + "https://salsa.debian.org/sanvila/unzip.git": { + "refs": [ + "e811196e79092a387e6ff0b345780710acfab1c4" + ] + } + }, + "downloads": [ + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-13.4.0/gcc-13.4.0.tar.xz", + "sha256": "9c4ce6dbb040568fdc545588ac03c5cbc95a8dbf0c7aa490170843afb59ca8f5", + "path": "work/.build/tarballs/gcc-13.4.0.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-14.2.0/gcc-14.2.0.tar.xz", + "sha256": "a7b39bc69cbf9e25826c5a60ab26477001f7c08d85cec04bc0e29cabed6f3cc9", + "path": ".build/tarballs/gcc-14.2.0.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-15.2.0/gcc-15.2.0.tar.xz", + "sha256": "438fd996826b0c82485a29da03a72d71d6e3541a83ec702df4271f6fe025d24e", + "path": ".build/tarballs/gcc-15.2.0.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-15.2.0/gcc-15.2.0.tar.xz", + "sha256": "438fd996826b0c82485a29da03a72d71d6e3541a83ec702df4271f6fe025d24e", + "path": "work/.build/tarballs/gcc-15.2.0.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gdb/gdb-16.2.tar.xz", + "sha256": "4002cb7f23f45c37c790536a13a720942ce4be0402d929c9085e92f10d480119", + "path": ".build/tarballs/gdb-16.2.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gdb/gdb-16.3.tar.xz", + "sha256": "bcfcd095528a987917acf9fff3f1672181694926cc18d609c99d0042c00224c5", + "path": ".build/tarballs/gdb-16.3.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gdb/gdb-16.3.tar.xz", + "sha256": "bcfcd095528a987917acf9fff3f1672181694926cc18d609c99d0042c00224c5", + "path": "work/.build/tarballs/gdb-16.3.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gettext/gettext-0.23.1.tar.xz", + "sha256": "c1f97a72a7385b7e71dd07b5fea6cdaf12c9b88b564976b23bd8c11857af2970", + "path": ".build/tarballs/gettext-0.23.1.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gettext/gettext-0.26.tar.xz", + "sha256": "d1fb86e260cfe7da6031f94d2e44c0da55903dbae0a2fa0fae78c91ae1b56f00", + "path": ".build/tarballs/gettext-0.26.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gettext/gettext-0.26.tar.xz", + "sha256": "d1fb86e260cfe7da6031f94d2e44c0da55903dbae0a2fa0fae78c91ae1b56f00", + "path": "work/.build/tarballs/gettext-0.26.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/glibc/glibc-2.38.tar.xz", + "sha256": "d1775e32e4628e64ef930f435b67bb63af7599acb6be2b335b9f19f16509f17f", + "path": ".build/tarballs/glibc-2.38.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/glibc/glibc-2.38.tar.xz", + "sha256": "fb82998998b2b29965467bc1b69d152e9c307d2cf301c9eafb4555b770ef3fd2", + "path": ".build/tarballs/glibc-2.38.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/glibc/glibc-2.41.tar.xz", + "sha256": "a5a26b22f545d6b7d7b3dd828e11e428f24f4fac43c934fb071b6a7d0828e901", + "path": ".build/tarballs/glibc-2.41.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/glibc/glibc-2.41.tar.xz", + "sha256": "a5a26b22f545d6b7d7b3dd828e11e428f24f4fac43c934fb071b6a7d0828e901", + "path": "work/.build/tarballs/glibc-2.41.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/glibc/glibc-2.42.tar.xz", + "sha256": "d1775e32e4628e64ef930f435b67bb63af7599acb6be2b335b9f19f16509f17f", + "path": ".build/tarballs/glibc-2.42.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/glibc/glibc-2.42.tar.xz", + "sha256": "d1775e32e4628e64ef930f435b67bb63af7599acb6be2b335b9f19f16509f17f", + "path": "work/.build/tarballs/glibc-2.42.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/glibc/glibc-2.42.tar.xz", + "sha256": "fb82998998b2b29965467bc1b69d152e9c307d2cf301c9eafb4555b770ef3fd2", + "path": ".build/tarballs/glibc-2.42.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gmp/gmp-6.3.0.tar.xz", + "sha256": "a3c2b80201b89e68616f4ad30bc66aee4927c3ce50e33929ca819d5c43538898", + "path": ".build/tarballs/gmp-6.3.0.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/gmp/gmp-6.3.0.tar.xz", + "sha256": "a3c2b80201b89e68616f4ad30bc66aee4927c3ce50e33929ca819d5c43538898", + "path": "work/.build/tarballs/gmp-6.3.0.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz", + "sha256": "ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8", + "path": ".build/tarballs/mpc-1.3.1.tar.gz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz", + "sha256": "ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8", + "path": "work/.build/tarballs/mpc-1.3.1.tar.gz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/mpfr/mpfr-4.2.1.tar.xz", + "sha256": "277807353a6726978996945af13e52829e3abd7a9a5b7fb2793894e18f1fcbb2", + "path": ".build/tarballs/mpfr-4.2.1.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/mpfr/mpfr-4.2.2.tar.xz", + "sha256": "277807353a6726978996945af13e52829e3abd7a9a5b7fb2793894e18f1fcbb2", + "path": ".build/tarballs/mpfr-4.2.2.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/mpfr/mpfr-4.2.2.tar.xz", + "sha256": "b67ba0383ef7e8a8563734e2e889ef5ec3c3b898a01d00fa0a6869ad81c6ce01", + "path": ".build/tarballs/mpfr-4.2.2.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/mpfr/mpfr-4.2.2.tar.xz", + "sha256": "b67ba0383ef7e8a8563734e2e889ef5ec3c3b898a01d00fa0a6869ad81c6ce01", + "path": "work/.build/tarballs/mpfr-4.2.2.tar.xz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.4.tar.gz", + "sha256": "6931283d9ac87c5073f30b6290c4c75f21632bb4fc3603ac8100812bed248159", + "path": ".build/tarballs/ncurses-6.4.tar.gz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.5.tar.gz", + "sha256": "136d91bc269a9a5785e5f9e980bc76ab57428f604ce3e5a5a90cebc767971cc6", + "path": ".build/tarballs/ncurses-6.5.tar.gz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.5.tar.gz", + "sha256": "136d91bc269a9a5785e5f9e980bc76ab57428f604ce3e5a5a90cebc767971cc6", + "path": "work/.build/tarballs/ncurses-6.5.tar.gz" + }, + { + "kind": "blob", + "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.5.tar.gz", + "sha256": "6931283d9ac87c5073f30b6290c4c75f21632bb4fc3603ac8100812bed248159", + "path": ".build/tarballs/ncurses-6.5.tar.gz" + }, + { + "kind": "blob", + "url": "http://github.com/libexpat/libexpat/releases/download/R_2_5_0/expat-2.5.0.tar.xz", + "sha256": "ef2420f0232c087801abf705e89ae65f6257df6b7931d37846a193ef2e8cdcbe", + "path": ".build/tarballs/expat-2.5.0.tar.xz" + }, + { + "kind": "blob", + "url": "http://github.com/libexpat/libexpat/releases/download/R_2_7_1/expat-2.7.1.tar.xz", + "sha256": "354552544b8f99012e5062f7d570ec77f14b412a3ff5c7d8d0dae62c0d217c30", + "path": ".build/tarballs/expat-2.7.1.tar.xz" + }, + { + "kind": "blob", + "url": "http://github.com/libexpat/libexpat/releases/download/R_2_7_1/expat-2.7.1.tar.xz", + "sha256": "354552544b8f99012e5062f7d570ec77f14b412a3ff5c7d8d0dae62c0d217c30", + "path": "work/.build/tarballs/expat-2.7.1.tar.xz" + }, + { + "kind": "blob", + "url": "http://static.rust-lang.org/dist/rustc-1.54.0-src.tar.gz", + "sha256": "ac8511633e9b5a65ad030a1a2e5bdaa841fdfe3132f2baaa52cc04e71c6c6976", + "path": "./rustc-1.54.0-src.tar.gz" + }, + { + "kind": "blob", + "url": "http://static.rust-lang.org/dist/rustc-1.90.0-src.tar.gz", + "sha256": "799a9f9cba4ed5351e071048bcf6b5560755d9009648def33a407dd4961f9b7e", + "path": "./rustc-1.90.0-src.tar.gz" + }, + { + "kind": "blob", + "url": "http://www.zlib.net/zlib-1.3.1.tar.xz", + "sha256": "38ef96b8dfe510d42707d9c781877914792541133e1870841463bfa73f883e32", + "path": ".build/tarballs/zlib-1.3.1.tar.xz" + }, + { + "kind": "blob", + "url": "http://www.zlib.net/zlib-1.3.1.tar.xz", + "sha256": "38ef96b8dfe510d42707d9c781877914792541133e1870841463bfa73f883e32", + "path": "work/.build/tarballs/zlib-1.3.1.tar.xz" + }, + { + "kind": "blob", + "url": "https://developer.apple.com/services-account/download?path=/Developer_Tools/Xcode_26.0.1/Xcode_26.0.1_Universal.xip", + "sha256": "9881c457068c86ac91e94cca2d7116dfd01cb7179c22b0863b63c7f3bb7e7695", + "path": "Xcode_26.0.1.xip" + }, + { + "kind": "blob", + "url": "https://dl.google.com/android/repository/android-ndk-r28c-darwin.zip", + "sha256": "0d4599e8bbf1a1668a0d51a541729b2246360f350018a2081d0b302dbb594f2a", + "path": "android-ndk-r28c-darwin.zip" + }, + { + "kind": "blob", + "url": "https://dl.google.com/android/repository/android-ndk-r28c-linux.zip", + "sha256": "dfb20d396df28ca02a8c708314b814a4d961dc9074f9a161932746f815aa552f", + "path": "android-ndk-r28c-linux.zip" + }, + { + "kind": "blob", + "url": "https://download.developer.apple.com/Developer_Tools/Xcode_16.4/Xcode_16.4.xip", + "sha256": "2dbf65ba28fb85b34e72c14c529a42d5c3189ab0f11fb29fdebd5f4ee6c87900", + "path": "Xcode_16.4.xip" + }, + { + "kind": "blob", + "url": "https://download.developer.apple.com/Developer_Tools/Xcode_26.0.1/Xcode_26.0.1_Universal.xip", + "sha256": "9881c457068c86ac91e94cca2d7116dfd01cb7179c22b0863b63c7f3bb7e7695", + "path": "Xcode_26.0.1.xip" + }, + { + "kind": "blob", + "url": "https://download.developer.apple.com/Developer_Tools/Xcode_26.1/XcodeXIP_26.1_Universal.xip", + "sha256": "434287e1e4c6ecbd6d5ea07e9f408fffcad2b82916b0a3fdfefa7fe60db4de93", + "path": "Xcode_26.1.xip" + }, + { + "kind": "blob", + "url": "https://download.developer.apple.com/Developer_Tools/Xcode_26.1/XcodeXIP_26.1_Universal.xip", + "sha256": "9881c457068c86ac91e94cca2d7116dfd01cb7179c22b0863b63c7f3bb7e7695", + "path": "Xcode_26.1.xip" + }, + { + "kind": "blob", + "url": "https://downloads.sourceforge.net/project/mingw-w64/mingw-w64/mingw-w64-release/mingw-w64-v13.0.0.tar.bz2", + "sha256": "5afe822af5c4edbf67daaf45eec61d538f49eef6b19524de64897c6b95828caf", + "path": ".build/tarballs/mingw-w64-v13.0.0.tar.bz2" + }, + { + "kind": "blob", + "url": "https://downloads.sourceforge.net/project/mingw-w64/mingw-w64/mingw-w64-release/mingw-w64-v13.0.0.tar.bz2", + "sha256": "5afe822af5c4edbf67daaf45eec61d538f49eef6b19524de64897c6b95828caf", + "path": "work/.build/tarballs/mingw-w64-v13.0.0.tar.bz2" + }, + { + "kind": "blob", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.43.1.tar.xz", + "sha256": "13f74202a3c4c51118b797a39ea4200d3f6cfbe224da6d1d95bb938480132dfd", + "path": ".build/tarballs/binutils-2.43.1.tar.xz" + }, + { + "kind": "blob", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.45.tar.xz", + "sha256": "c50c0e7f9cb188980e2cc97e4537626b1672441815587f1eab69d2a1bfbef5d2", + "path": ".build/tarballs/binutils-2.45.tar.xz" + }, + { + "kind": "blob", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.45.tar.xz", + "sha256": "c50c0e7f9cb188980e2cc97e4537626b1672441815587f1eab69d2a1bfbef5d2", + "path": "work/.build/tarballs/binutils-2.45.tar.xz" + }, + { + "kind": "blob", + "url": "https://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.16.tar.gz", + "sha256": "e6a1b1b589654277ee790cce3734f07876ac4ccfaecbee8afa0b649cf529cc04", + "path": ".build/tarballs/libiconv-1.16.tar.gz" + }, + { + "kind": "blob", + "url": "https://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.18.tar.gz", + "sha256": "3b08f5f4f9b4eb82f151a7040bfd6fe6c6fb922efe4b1659c66ea933276965e8", + "path": ".build/tarballs/libiconv-1.18.tar.gz" + }, + { + "kind": "blob", + "url": "https://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.18.tar.gz", + "sha256": "3b08f5f4f9b4eb82f151a7040bfd6fe6c6fb922efe4b1659c66ea933276965e8", + "path": "work/.build/tarballs/libiconv-1.18.tar.gz" + }, + { + "kind": "blob", + "url": "https://github.com/apple/llvm-project/archive/refs/heads/stable/20250402.zip", + "sha256": "b8e87f026e19259e6eac347746661e11592e0ff8bcdb657e177800223d7438ce", + "path": "tarballs/20250402.zip" + }, + { + "kind": "blob", + "url": "https://github.com/facebook/zstd/releases/download/v1.5.6/zstd-1.5.6.tar.gz", + "sha256": "8c29e06cf42aacc1eafc4077ae2ec6c6fcb96a626157e0593d5e82a34fd403c1", + "path": ".build/tarballs/zstd-1.5.6.tar.gz" + }, + { + "kind": "blob", + "url": "https://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz", + "sha256": "eb33e51f49a15e023950cd7825ca74a4a2b43db8354825ac24fc1b7ee09e6fa3", + "path": ".build/tarballs/zstd-1.5.7.tar.gz" + }, + { + "kind": "blob", + "url": "https://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz", + "sha256": "eb33e51f49a15e023950cd7825ca74a4a2b43db8354825ac24fc1b7ee09e6fa3", + "path": "work/.build/tarballs/zstd-1.5.7.tar.gz" + }, + { + "kind": "blob", + "url": "https://github.com/johnsonjh/duma/archive/refs/tags/VERSION_2_5_21.tar.gz", + "sha256": "470aa72e7018f0beadb5fbe3c932a62ba1b0594c29158a744c614bfa42133e59", + "path": ".build/tarballs/VERSION_2_5_21.tar.gz" + }, + { + "kind": "blob", + "url": "https://github.com/johnsonjh/duma/archive/refs/tags/VERSION_2_5_21.tar.gz", + "sha256": "470aa72e7018f0beadb5fbe3c932a62ba1b0594c29158a744c614bfa42133e59", + "path": "work/.build/tarballs/VERSION_2_5_21.tar.gz" + }, + { + "kind": "blob", + "url": "https://github.com/llvm/llvm-project/archive/refs/tags/llvmorg-20.1.8.zip", + "sha256": "b115ce6285dd9f3f401459912c12d28eb2e2d81e2387a71f6300aa11f7bc3288", + "path": "tarballs/llvmorg-20.1.8.zip" + }, + { + "kind": "blob", + "url": "https://github.com/madler/zlib/releases/download/v1.3.1/zlib-1.3.1.tar.xz", + "sha256": "38ef96b8dfe510d42707d9c781877914792541133e1870841463bfa73f883e32", + "path": "work/.build/tarballs/zlib-1.3.1.tar.xz" + }, + { + "kind": "blob", + "url": "https://go.dev/dl/go1.25.0.darwin-arm64.tar.gz", + "sha256": "544932844156d8172f7a28f77f2ac9c15a23046698b6243f633b0a0b00c0749c", + "path": "./go-darwin_arm64.tar.gz" + }, + { + "kind": "blob", + "url": "https://go.dev/dl/go1.25.0.linux-amd64.tar.gz", + "sha256": "2852af0cb20a13139b3448992e69b868e50ed0f8a1e5940ee1de9e19a123b613", + "path": "./go-linux_amd64.tar.gz" + }, + { + "kind": "blob", + "url": "https://go.dev/dl/go1.25.0.linux-arm64.tar.gz", + "sha256": "05de75d6994a2783699815ee553bd5a9327d8b79991de36e38b66862782f54ae", + "path": "./go-linux_arm64.tar.gz" + }, + { + "kind": "blob", + "url": "https://libisl.sourceforge.io/isl-0.26.tar.xz", + "sha256": "a0b5cb06d24f9fa9e77b55fabbe9a3c94a336190345c2555f9915bb38e976504", + "path": ".build/tarballs/isl-0.26.tar.xz" + }, + { + "kind": "blob", + "url": "https://libisl.sourceforge.io/isl-0.27.tar.xz", + "sha256": "6d8babb59e7b672e8cb7870e874f3f7b813b6e00e6af3f8b04f7579965643d5c", + "path": ".build/tarballs/isl-0.27.tar.xz" + }, + { + "kind": "blob", + "url": "https://libisl.sourceforge.io/isl-0.27.tar.xz", + "sha256": "6d8babb59e7b672e8cb7870e874f3f7b813b6e00e6af3f8b04f7579965643d5c", + "path": "work/.build/tarballs/isl-0.27.tar.xz" + }, + { + "kind": "blob", + "url": "https://raw.githubusercontent.com/Homebrew/homebrew-core/1cf441a0/Patches/berkeley-db@4/clang.diff", + "sha256": "86111b0965762f2c2611b302e4a95ac8df46ad24925bbb95a1961542a1542e40", + "path": "patch/clang.diff" + }, + { + "kind": "blob", + "url": "https://raw.githubusercontent.com/Homebrew/homebrew-core/1cf441a0/Patches/libtool/configure-pre-0.4.2.418-big_sur.diff", + "sha256": "83af02f2aa2b746bb7225872cab29a253264be49db0ecebb12f841562d9a2923", + "path": "patch/configure-pre-0.4.2.418-big_sur.diff" + }, + { + "kind": "blob", + "url": "https://raw.githubusercontent.com/NetBSD/pkgsrc/6034096dc85159a02116524692545cf5752c8f33/databases/db5/patches/patch-src_dbinc_db.in", + "sha256": "302b78f3e1f131cfbf91b24e53a5c79e1d9234c143443ab936b9e5ad08dea5b6", + "path": "patch/patch-src_dbinc_db.in" + }, + { + "kind": "blob", + "url": "https://sources.voidlinux.org/musl-1.2.5/musl-1.2.5.tar.gz", + "sha256": "a9a118bbe84d8764da0ea0d28b3ab3fae8477fc7e4085d90102b8596fc7c75e4", + "path": "work/.build/tarballs/musl-1.2.5.tar.gz" + }, + { + "kind": "blob", + "url": "https://static.rust-lang.org/dist/rust-1.90.0-aarch64-apple-darwin.tar.gz", + "sha256": "a11b52e34f5e80cb25d49f7943ae60e0b069b431727a4c09b2c890ceebee3687", + "path": "./rust-1.90.0-aarch64-apple-darwin.tar.gz" + }, + { + "kind": "blob", + "url": "https://static.rust-lang.org/dist/rust-1.90.0-aarch64-unknown-linux-gnu.tar.gz", + "sha256": "293f412e3412c3aa3398c78ebbdf898fa08eacad80c85a7332ce1a455504c5fc", + "path": "./rust-1.90.0-aarch64-unknown-linux-gnu.tar.gz" + }, + { + "kind": "blob", + "url": "https://static.rust-lang.org/dist/rust-1.90.0-x86_64-unknown-linux-gnu.tar.gz", + "sha256": "e453bae1c68d02fe2eae065c5452d5731308164cd154154c6ee442d2fa590685", + "path": "./rust-1.90.0-x86_64-unknown-linux-gnu.tar.gz" + }, + { + "kind": "blob", + "url": "https://storage.googleapis.com/dart-archive/channels/beta/release/3.9.0-100.2.beta/sdk/dartsdk-linux-arm64-release.zip", + "sha256": "fd0871a012ccc9c49ee8e9b2e6ba0ea36336c7cc38af05646ca513c4ccb0b616", + "path": "./dartsdk-linux_arm64.zip" + }, + { + "kind": "blob", + "url": "https://storage.googleapis.com/dart-archive/channels/beta/release/3.9.0-100.2.beta/sdk/dartsdk-linux-x64-release.zip", + "sha256": "9b503e642c862f404b46490cb6ba652c71d276fb7eb415283abe172a8574806f", + "path": "./dartsdk-linux_amd64.zip" + }, + { + "kind": "blob", + "url": "https://storage.googleapis.com/dart-archive/channels/beta/release/3.9.0-100.2.beta/sdk/dartsdk-macos-arm64-release.zip", + "sha256": "73063836c198c6ebcf09d9d38737badfc86bfa8dd8316fe7bd85d144d8c9dec9", + "path": "./dartsdk-darwin_arm64.zip" + }, + { + "kind": "blob", + "url": "https://storage.googleapis.com/dart-archive/channels/dev/release/3.4.0-247.0.dev/sdk/dartsdk-linux-arm64-release.zip", + "sha256": "98c0c8bd016ba6e1156d4630409f47ef42e16226efe331751e706711496208fc", + "path": "./dartsdk-linux_arm64.zip" + }, + { + "kind": "blob", + "url": "https://storage.googleapis.com/dart-archive/channels/dev/release/3.4.0-247.0.dev/sdk/dartsdk-linux-x64-release.zip", + "sha256": "3cff0b896fb2f665c8ab2cbf746882fcf42d2def7c3c64db7e2208ee092932da", + "path": "./dartsdk-linux_amd64.zip" + }, + { + "kind": "blob", + "url": "https://storage.googleapis.com/dart-archive/channels/dev/release/3.4.0-247.0.dev/sdk/dartsdk-macos-arm64-release.zip", + "sha256": "95eec1e3dfa7c891d928c0ae3be9550675eefa95b240ea5dd414f9b4c2a90369", + "path": "./dartsdk-darwin_arm64.zip" + }, + { + "kind": "blob", + "url": "https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.20.17.tar.xz", + "sha256": "d011245629b980d4c15febf080b54804aaf215167b514a3577feddb2495f8a3e", + "path": "work/.build/tarballs/linux-4.20.17.tar.xz" + }, + { + "kind": "blob", + "url": "https://www.kernel.org/pub/linux/kernel/v6.x/linux-6.13.tar.xz", + "sha256": "e79dcc6eb86695c6babfb07c2861912b635d5075c6cd1cd0567d1ea155f80d6e", + "path": ".build/tarballs/linux-6.13.tar.xz" + }, + { + "kind": "blob", + "url": "https://www.kernel.org/pub/linux/kernel/v6.x/linux-6.16.tar.xz", + "sha256": "1a4be2fe6b5246aa4ac8987a8a4af34c42a8dd7d08b46ab48516bcc1befbcd83", + "path": ".build/tarballs/linux-6.16.tar.xz" + }, + { + "kind": "blob", + "url": "https://www.kernel.org/pub/linux/kernel/v6.x/linux-6.16.tar.xz", + "sha256": "1a4be2fe6b5246aa4ac8987a8a4af34c42a8dd7d08b46ab48516bcc1befbcd83", + "path": "work/.build/tarballs/linux-6.16.tar.xz" + }, + { + "kind": "blob", + "url": "https://www.musl-libc.org/releases/musl-1.2.5.tar.gz", + "sha256": "a9a118bbe84d8764da0ea0d28b3ab3fae8477fc7e4085d90102b8596fc7c75e4", + "path": ".build/tarballs/musl-1.2.5.tar.gz" + }, + { + "kind": "blob", + "url": "https://www.musl-libc.org/releases/musl-1.2.5.tar.gz", + "sha256": "a9a118bbe84d8764da0ea0d28b3ab3fae8477fc7e4085d90102b8596fc7c75e4", + "path": "work/.build/tarballs/musl-1.2.5.tar.gz" + }, + { + "kind": "tar.bz2", + "url": "http://downloads.sourceforge.net/project/boost/boost/1.83.0/boost_1_83_0.tar.bz2", + "sha256": "6478edfe2f3305127cffe8caf73ea0176c53769f4bf1585be237eb30798c3b8e" + }, + { + "kind": "tar.bz2", + "url": "http://downloads.sourceforge.net/project/boost/boost/1.85.0/boost_1_85_0.tar.bz2", + "sha256": "7009fe1faa1697476bdc7027703a2badb84e849b7b0baad5086b087b971f8617" + }, + { + "kind": "tar.bz2", + "url": "http://downloads.sourceforge.net/project/boost/boost/1.89.0/boost_1_89_0.tar.bz2", + "sha256": "85a33fa22621b4f314f8e85e1a5e2a9363d22e4f4992925d4bb3bc631b5a0c7a" + }, + { + "kind": "tar.bz2", + "url": "http://downloads.sourceforge.net/project/boost/boost/1.90.0/boost_1_90_0.tar.bz2", + "sha256": "49551aff3b22cbc5c5a9ed3dbc92f0e23ea50a0f7325b0d198b705e8ee3fc305" + }, + { + "kind": "tar.bz2", + "url": "http://downloads.sourceforge.net/project/p7zip/p7zip/16.02/p7zip_16.02_src_all.tar.bz2", + "sha256": "5eb20ac0e2944f6cb9c2d51dd6c4518941c185347d4089ea89087ffdd6e2341f" + }, + { + "kind": "tar.bz2", + "url": "http://github.com/libusb/libusb/releases/download/v1.0.26/libusb-1.0.26.tar.bz2", + "sha256": "12ce7a61fc9854d1d2a1ffe095f7b5fac19ddba095c259e6067a46500381b5a5" + }, + { + "kind": "tar.bz2", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.42.tar.bz2", + "sha256": "aa54850ebda5064c72cd4ec2d9b056c294252991486350d9a97ab2a6dfdfaf12" + }, + { + "kind": "tar.bz2", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.45.tar.bz2", + "sha256": "1393f90db70c2ebd785fb434d6127f8888c559d5eeb9c006c354b203bab3473e" + }, + { + "kind": "tar.bz2", + "url": "https://ftpmirror.gnu.org/gnu/binutils/binutils-2.46.0.tar.bz2", + "sha256": "0f3152632a2a9ce066f20963e9bb40af7cf85b9b6c409ed892fd0676e84ecd12" + }, + { + "kind": "tar.bz2", + "url": "https://github.com/PCRE2Project/pcre2/releases/download/pcre2-10.47/pcre2-10.47.tar.bz2", + "sha256": "47fe8c99461250d42f89e6e8fdaeba9da057855d06eb7fc08d9ca03fd08d7bc7" + }, + { + "kind": "tar.bz2", + "url": "https://salsa.debian.org/reproducible-builds/reproducible-lfs/-/raw/master/releases/strip-nondeterminism/strip-nondeterminism_1.13.0.tar.bz2", + "sha256": "a70cdad5d728ea78b75d09880c4b51c7d887e89d0b610149b10cfb2abc70b4fc" + }, + { + "kind": "tar.gz", + "url": "http://download.libsodium.org/libsodium/releases/libsodium-1.0.18.tar.gz", + "sha256": "6f504490b342a4f8a4c4a02fc9b866cbef8622d5df4e5452b46be121e46636c1" + }, + { + "kind": "tar.gz", + "url": "http://download.libsodium.org/libsodium/releases/libsodium-1.0.22.tar.gz", + "sha256": "adbdd8f16149e81ac6078a03aca6fc03b592b89ef7b5ed83841c086191be3349" + }, + { + "kind": "tar.gz", + "url": "http://download.savannah.nongnu.org/releases/libunwind/libunwind-1.5.0.tar.gz", + "sha256": "90337653d92d4a13de590781371c604f9031cdb50520366aa1e3a91e1efb1017" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/bash/bash-5.3.tar.gz", + "sha256": "0d5cd86965f869a26cf64f4b71be7b96f90a3ba8b3d74e27e8e9d9d5550f31ba" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/cpio/cpio-2.15.tar.gz", + "sha256": "efa50ef983137eefc0a02fdb51509d624b5e3295c980aa127ceee4183455499e" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/autoconf/autoconf-2.72.tar.gz", + "sha256": "afb181a76e1ee72832f6581c0eddf8df032b83e2e0239ef79ebedc4467d92d6e" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/automake/automake-1.18.tar.gz", + "sha256": "af6043a5d4b3beef0c48161f4a6936259321cd101a34c1ab0768328515626c8a" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/bison/bison-3.8.tar.gz", + "sha256": "d5d184d421aee15603939973a6b0f372f908edfb24c5bc740697497021ad9458" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/gawk/gawk-5.2.2.tar.gz", + "sha256": "945aef7ccff101f20b22a10802bc005e994ab2b8ea3e724cc1a197c62f41f650" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/gawk/gawk-5.3.2.tar.gz", + "sha256": "8639a1a88fb411a1be02663739d03e902a6d313b5c6fe024d0bfeb3341a19a11" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-13.2.0/gcc-13.2.0.tar.gz", + "sha256": "8cb4be3796651976f94b9356fa08d833524f62420d6292c5033a9a26af315078" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/gettext/gettext-0.26.tar.gz", + "sha256": "39acf4b0371e9b110b60005562aace5b3631fed9b1bb9ecccfc7f56e58bb1d7f" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/gperf/gperf-3.3.tar.gz", + "sha256": "fd87e0aba7e43ae054837afd6cd4db03a3f2693deb3619085e6ed9d8d9604ad8" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/libc/glibc-2.39.tar.gz", + "sha256": "97f84f3b7588cd54093a6f6389b0c1a81e70d99708d74963a2e3eab7c7dc942d" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.17.tar.gz", + "sha256": "8f74213b56238c85a50a5329f77e06198771e70dd9a739779f4c02f65d971313" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/libiconv/libiconv-1.18.tar.gz", + "sha256": "3b08f5f4f9b4eb82f151a7040bfd6fe6c6fb922efe4b1659c66ea933276965e8" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/libtool/libtool-2.5.4.tar.gz", + "sha256": "da8ebb2ce4dcf46b90098daf962cffa68f4b4f62ea60f798d0ef12929ede6adf" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/libunistring/libunistring-1.4.1.tar.gz", + "sha256": "12542ad7619470efd95a623174dcd4b364f2483caf708c6bee837cb53a54cb9d" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/m4/m4-1.4.20.tar.gz", + "sha256": "6ac4fc31ce440debe63987c2ebbf9d7b6634e67a7c3279257dc7361de8bdb3ef" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/make/make-4.4.tar.gz", + "sha256": "581f4d4e872da74b3941c874215898a7d35802f03732bdccee1d4a7979105d18" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz", + "sha256": "ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/ncurses/ncurses-6.5.tar.gz", + "sha256": "136d91bc269a9a5785e5f9e980bc76ab57428f604ce3e5a5a90cebc767971cc6" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/patch/patch-2.8.tar.gz", + "sha256": "308a4983ff324521b9b21310bfc2398ca861798f02307c79eb99bb0e0d2bf980" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/readline/readline-8.0.tar.gz", + "sha256": "e339f51971478d369f8a053a330a190781acb9864cf4c541060f12078948e461" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/sed/sed-4.9.tar.gz", + "sha256": "d1478a18f033a73ac16822901f6533d30b6be561bcbce46ffd7abce93602282e" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/texinfo/texinfo-7.2.tar.gz", + "sha256": "e86de7dfef6b352aa1bf647de3a6213d1567c70129eccbf8977706d9c91919c8" + }, + { + "kind": "tar.gz", + "url": "http://ftpmirror.gnu.org/gnu/texinfo/texinfo-7.2.tar.gz", + "sha256": "e86de7dfef6b352aa1bf647de3a621w3d1567c70129eccbf8977706d9c91919c8" + }, + { + "kind": "tar.gz", + "url": "http://github.com/Kitware/CMake/releases/download/v4.0.3/cmake-4.0.3.tar.gz", + "sha256": "8d3537b7b7732660ea247398f166be892fe6131d63cc291944b45b91279f3ffb" + }, + { + "kind": "tar.gz", + "url": "http://github.com/MrCyjaneK/nproc/archive/30acb0de0e18a2b16c277e6db840e5ce389d962d.tar.gz", + "sha256": "353715a0799c3d965762b1207646b99503deb57603af779547b06c944ace4bad" + }, + { + "kind": "tar.gz", + "url": "http://github.com/MrCyjaneK/polyseed/archive/refs/tags/v2.0.0-patch.tar.gz", + "sha256": "28a86b0bc178076ac65dc7d8cc28a79eb546708473efc0e8dce688f1e237ccc2" + }, + { + "kind": "tar.gz", + "url": "http://github.com/eudev-project/eudev/releases/download/v3.2.14/eudev-3.2.14.tar.gz", + "sha256": "8da4319102f24abbf7fff5ce9c416af848df163b29590e666d334cc1927f006f" + }, + { + "kind": "tar.gz", + "url": "http://github.com/facebook/zstd/releases/download/v1.5.7/zstd-1.5.7.tar.gz", + "sha256": "eb33e51f49a15e023950cd7825ca74a4a2b43db8354825ac24fc1b7ee09e6fa3" + }, + { + "kind": "tar.gz", + "url": "http://github.com/google/googletest/releases/download/v1.17.0/googletest-1.17.0.tar.gz", + "sha256": "65fab701d9829d38cb77c14acdc431d2108bfdbf8979e40eb8ae567edf10b27c" + }, + { + "kind": "tar.gz", + "url": "http://github.com/libevent/libevent/releases/download/release-2.1.12-stable/libevent-2.1.12-stable.tar.gz", + "sha256": "92e6de1be9ec176428fd2367677e61ceffc2ee1cb119035037a27d346b0403bb" + }, + { + "kind": "tar.gz", + "url": "http://github.com/libexpat/libexpat/releases/download/R_2_6_0/expat-2.6.0.tar.gz", + "sha256": "a13447b9aa67d7c860783fdf6820f33ebdea996900d6d8bbc50a628f55f099f7" + }, + { + "kind": "tar.gz", + "url": "http://github.com/libusb/hidapi/archive/refs/tags/hidapi-0.13.1.tar.gz", + "sha256": "476a2c9a4dc7d1fc97dd223b84338dbea3809a84caea2dcd887d9778725490e3" + }, + { + "kind": "tar.gz", + "url": "http://github.com/protocolbuffers/protobuf/releases/download/v3.6.1/protobuf-cpp-3.6.1.tar.gz", + "sha256": "b3732e471a9bb7950f090fd0457ebd2536a9ba0891b7f3785919c654fe2a2529" + }, + { + "kind": "tar.gz", + "url": "http://github.com/thepowersgang/mrustc/archive/06b87d1af49d2db3bd850fdee8888055dd540dd1.tar.gz", + "sha256": "d3d3b84a100e71628afecf1125dbaa9bfc54ef9578c4fd81d75dca34c96f2565" + }, + { + "kind": "tar.gz", + "url": "http://github.com/tukaani-project/xz/releases/download/v5.8.1/xz-5.8.1.tar.gz", + "sha256": "507825b599356c10dca1cd720c9d0d0c9d5400b9de300af00e4d1ea150795543" + }, + { + "kind": "tar.gz", + "url": "http://github.com/unicode-org/icu/releases/download/release-55-2/icu4c-55_2-src.tgz", + "sha256": "eda2aa9f9c787748a2e2d310590720ca8bcc6252adf6b4cfb03b65bef9d66759" + }, + { + "kind": "tar.gz", + "url": "http://github.com/zeromq/libzmq/releases/download/v4.3.5/zeromq-4.3.5.tar.gz", + "sha256": "6653ef5910f17954861fe72332e68b03ca6e4d9c7160eb3a8de5a5a913bfab43" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.55.0-src.tar.gz", + "sha256": "b2379ac710f5f876ee3c3e03122fe33098d6765d371cac6c31b1b6fc8e43821e" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.56.1-src.tar.gz", + "sha256": "c3898dfaadaa193dc88ddbc5345946a163211b58621df1cfff70186b4fc79511" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.57.0-src.tar.gz", + "sha256": "3546f9c3b91b1f8b8efd26c94d6b50312c08210397b4072ed2748e2bd4445c1a" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.58.1-src.tar.gz", + "sha256": "a839afdd3625d6f3f3c4c10b79813675d1775c460d14be1feaf33a6c829c07c7" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.59.0-src.tar.gz", + "sha256": "a7c8eeaee85bfcef84c96b02b3171d1e6540d15179ff83dddd9eafba185f85f9" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.60.0-src.tar.gz", + "sha256": "20ca826d1cf674daf8e22c4f8c4b9743af07973211c839b85839742314c838b7" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.61.0-src.tar.gz", + "sha256": "ad0b4351675aa9abdf4c7e066613bd274c4391c5506db152983426376101daed" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.62.0-src.tar.gz", + "sha256": "7d0878809b64d206825acae3eb7f60afb2212d81e3de1adf4c11c6032b36c027" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.62.1-src.tar.gz", + "sha256": "72acbe6ffcd94f598382a7430b0d85ee8f679e6d0b27f3f566ed1c16c978133f" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.63.0-src.tar.gz", + "sha256": "1f9580295642ef5da7e475a8da2397d65153d3f2cb92849dbd08ed0effca99d0" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.64.0-src.tar.gz", + "sha256": "b3cd9f481e1a2901bf6f3808d30c69cc4ea80d93c4cc4e2ed52258b180381205" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.65.0-src.tar.gz", + "sha256": "5828bb67f677eabf8c384020582b0ce7af884e1c84389484f7f8d00dd82c0038" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.66.1-src.tar.gz", + "sha256": "5b3c933a94c72187705d4ee293198babfdd09442f5937fbd685db3a81f4959ba" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.67.1-src.tar.gz", + "sha256": "46483d3e5de85a3bd46f8e7a3ae1837496391067dbe713a25d3cf051b3d9ff6e" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.68.2-src.tar.gz", + "sha256": "93339c23f7cd4d0c45db58e18b4c6e16d6070f4277aad9d2492d23294bf32e96" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.69.0-src.tar.gz", + "sha256": "fb05971867ad6ccabbd3720279f5a94b99f61024923187b56bb5c455fa3cf60f" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.70.0-src.tar.gz", + "sha256": "b2bfae000b7a5040e4ec4bbc50a09f21548190cb7570b0ed77358368413bd27c" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.71.1-src.tar.gz", + "sha256": "6fa90d50d1d529a75f6cc349784de57d7ec0ba2419b09bde7d335c25bd4e472e" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.72.1-src.tar.gz", + "sha256": "7f48845f6a52cdbb5d63fb0528fd5f520eb443275b55f98e328159f86568f895" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.73.0-src.tar.gz", + "sha256": "96d62e6d1f2d21df7ac8acb3b9882411f9e7c7036173f7f2ede9e1f1f6b1bb3a" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.74.1-src.tar.gz", + "sha256": "67db3e22fc9921c885baae5953ba144fc474cde29ec69ab56d43ce764206231d" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.75.0-src.tar.gz", + "sha256": "5b739f45bc9d341e2d1c570d65d2375591e22c2d23ef5b8a37711a0386abc088" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.76.0-src.tar.gz", + "sha256": "9e5cff033a7f0d2266818982ad90e4d3e4ef8f8ee1715776c6e25073a136c021" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.77.1-src.tar.gz", + "sha256": "ee106e4c569f52dba3b5b282b105820f86bd8f6b3d09c06b8dce82fb1bb3a4a1" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.78.0-src.tar.gz", + "sha256": "ff544823a5cb27f2738128577f1e7e00ee8f4c83f2a348781ae4fc355e91d5a9" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.79.0-src.tar.gz", + "sha256": "172ecf3c7d1f9d9fb16cd2a628869782670416ded0129e524a86751f961448c0" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.80.1-src.tar.gz", + "sha256": "2c0b8f643942dcb810cbcc50f292564b1b6e44db5d5f45091153996df95d2dc4" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.81.0-src.tar.gz", + "sha256": "872448febdff32e50c3c90a7e15f9bb2db131d13c588fe9071b0ed88837ccfa7" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.82.0-src.tar.gz", + "sha256": "7c53f4509eda184e174efa6ba7d5eeb586585686ce8edefc781a2b11a7cf512a" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.83.0-src.tar.gz", + "sha256": "722d773bd4eab2d828d7dd35b59f0b017ddf9a97ee2b46c1b7f7fac5c8841c6e" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.84.1-src.tar.gz", + "sha256": "5e2fb5d49628a549f7671b2ccf9855ab379fd442831a7c2af16e0cdcc31bb375" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.85.1-src.tar.gz", + "sha256": "0f2995ca083598757a8d9a293939e569b035799e070f419a686b0996fb94238a" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.86.0-src.tar.gz", + "sha256": "022a27286df67900a044d227d9db69d4732ec3d833e4ffc259c4425ed71eed80" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.87.0-src.tar.gz", + "sha256": "149bb9fd29be592da4e87900fc68f0629a37bf6850b46339dd44434c04fd8e76" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.88.0-src.tar.gz", + "sha256": "3a97544434848ae3d193d1d6bc83d6f24cb85c261ad95f955fde47ec64cfcfbe" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.89.0-src.tar.gz", + "sha256": "2576f9f440dd99b0151bd28f59aa0ac6102d5c4f3ed4ef8a810c8dd05057250d" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.90.0-src.tar.gz", + "sha256": "799a9f9cba4ed5351e071048bcf6b5560755d9009648def33a407dd4961f9b7e" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.91.0-src.tar.gz", + "sha256": "327f528151753013f0a2b2c7f48955a033d718f269a4bc586314d675d0d43e8a" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.92.0-src.tar.gz", + "sha256": "9e0d2ca75c7e275fdc758255bf4b03afb3d65d1543602746907c933b6901c3b8" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.93.0-src.tar.gz", + "sha256": "69112bd83c321943ffc390b7db2f59ef3febb95dac700f67c2156fbf6b50a705" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.94.0-src.tar.gz", + "sha256": "b83f921cd3f321ff614f9c06a8b870d89299fc02888b48a5549683a36823474c" + }, + { + "kind": "tar.gz", + "url": "http://static.rust-lang.org/dist/rustc-1.95.0-src.tar.gz", + "sha256": "ea9b82a83e46967537c3569ce9d6fa16811c043a96e651376c349e70241ca515" + }, + { + "kind": "tar.gz", + "url": "http://www.cpan.org/src/5.0/perl-5.42.0.tar.gz", + "sha256": "e093ef184d7f9a1b9797e2465296f55510adb6dab8842b0c3ed53329663096dc" + }, + { + "kind": "tar.gz", + "url": "http://www.cpan.org/src/5.0/perl-5.42.1.tar.gz", + "sha256": "6f84e6dc8cce97181d1c6aeeb552c13775c91ded3c6c73743c9211af87b16bf8" + }, + { + "kind": "tar.gz", + "url": "http://www.nlnetlabs.nl/downloads/unbound/unbound-1.23.0.tar.gz", + "sha256": "959bd5f3875316d7b3f67ee237a56de5565f5b35fc9b5fc3cea6cfe735a03bb8" + }, + { + "kind": "tar.gz", + "url": "http://www.openssl.org/source/openssl-3.5.1.tar.gz", + "sha256": "529043b15cffa5f36077a4d0af83f3de399807181d607441d734196d889b641f" + }, + { + "kind": "tar.gz", + "url": "http://www.python.org/ftp/python/3.11.13/Python-3.11.13.tgz", + "sha256": "0f1a22f4dfd34595a29cf69ee7ea73b9eff8b1cc89d7ab29b3ab0ec04179dad8" + }, + { + "kind": "tar.gz", + "url": "http://www.python.org/ftp/python/3.14.0/Python-3.14.0.tgz", + "sha256": "88d2da4eed42fa9a5f42ff58a8bc8988881bd6c547e297e46682c2687638a851" + }, + { + "kind": "tar.gz", + "url": "http://www.zlib.net/zlib-1.3.1.tar.gz", + "sha256": "9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23" + }, + { + "kind": "tar.gz", + "url": "https://astron.com/pub/file/file-5.46.tar.gz", + "sha256": "c9cc77c7c560c543135edc555af609d5619dbef011997e988ce40a3d75d86088" + }, + { + "kind": "tar.gz", + "url": "https://cpan.metacpan.org/authors/id/O/OV/OVID/Sub-Override-0.09.tar.gz", + "sha256": "939a67c1f729968e0cc81b74958db750e1bdb7c020bee1a263332f422c2e25b5" + }, + { + "kind": "tar.gz", + "url": "https://cpan.metacpan.org/authors/id/P/PH/PHRED/Archive-Zip-1.68.tar.gz", + "sha256": "984e185d785baf6129c6e75f8eb44411745ac00bf6122fb1c8e822a3861ec650" + }, + { + "kind": "tar.gz", + "url": "https://cpan.metacpan.org/authors/id/P/PI/PIXEL/Archive-Cpio-0.10.tar.gz", + "sha256": "246fb31669764e78336b2191134122e07c44f2d82dc4f37d552ab28f8668bed3" + }, + { + "kind": "tar.gz", + "url": "https://cpan.metacpan.org/authors/id/T/TO/TODDR/autodie-2.37.tar.gz", + "sha256": "4921d211b0cea63c2ca06dfc0c948a7203a3d48ad80a06f43b46104354f2c1c3" + }, + { + "kind": "tar.gz", + "url": "https://curl.se/download/curl-8.15.0.tar.gz", + "sha256": "d85cfc79dc505ff800cb1d321a320183035011fa08cb301356425d86be8fc53c" + }, + { + "kind": "tar.gz", + "url": "https://download.oracle.com/berkeley-db/db-5.3.28.tar.gz", + "sha256": "e0a992d740709892e81f9d93f06daf305cf73fb81b545afe72478043172c3628" + }, + { + "kind": "tar.gz", + "url": "https://download.savannah.gnu.org/releases/freetype/freetype-2.14.1.tar.gz", + "sha256": "174d9e53402e1bf9ec7277e22ec199ba3e55a6be2c0740cb18c0ee9850fc8c34" + }, + { + "kind": "tar.gz", + "url": "https://ftp.gnu.org/gnu/bash/bash-5.3.tar.gz", + "sha256": "0d5cd86965f869a26cf64f4b71be7b96f90a3ba8b3d74e27e8e9d9d5550f31ba" + }, + { + "kind": "tar.gz", + "url": "https://github.com/HowardHinnant/date/archive/refs/tags/v3.0.1.tar.gz", + "sha256": "7a390f200f0ccd207e8cff6757e04817c1a0aec3e327b006b7eb451c57ee3538", + "path": "deps/date" + }, + { + "kind": "tar.gz", + "url": "https://github.com/PCRE2Project/pcre2/releases/download/pcre2-10.46/pcre2-10.46.tar.gz", + "sha256": "8d28d7f2c3b970c3a4bf3776bcbb5adfc923183ce74bc8df1ebaad8c1985bd07" + }, + { + "kind": "tar.gz", + "url": "https://github.com/RsyncProject/rsync/releases/download/v3.4.1/rsync-3.4.1.tar.gz", + "sha256": "2924bcb3a1ed8b551fc101f740b9f0fe0a202b115027647cf69850d65fd88c52" + }, + { + "kind": "tar.gz", + "url": "https://github.com/abseil/abseil-cpp/archive/refs/tags/20240722.0.tar.gz", + "sha256": "f50e5ac311a81382da7fa75b97310e4b9006474f9560ac46f54a9967f07d4ae3", + "path": "deps/abseil_cpp" + }, + { + "kind": "tar.gz", + "url": "https://github.com/boostorg/mp11/archive/refs/tags/boost-1.82.0.tar.gz", + "sha256": "1705680b0849cac3258e528270c9071b440b95372e5be0b9197da89e84a794eb", + "path": "deps/mp11" + }, + { + "kind": "tar.gz", + "url": "https://github.com/dcleblanc/SafeInt/archive/refs/tags/3.0.28.tar.gz", + "sha256": "d6b164bcea92a746e4d44132e505c7ab1816d1089ba99ebc674ccd4b70262ed5", + "path": "deps/safeint" + }, + { + "kind": "tar.gz", + "url": "https://github.com/git/git/archive/refs/tags/v2.51.0.tar.gz", + "sha256": "3524fc5fd81f16f80e1696a8281bd8ad831048b67848015d7b7382bf365ae685" + }, + { + "kind": "tar.gz", + "url": "https://github.com/google/flatbuffers/archive/refs/tags/v23.5.26.tar.gz", + "sha256": "1cce06b17cddd896b6d73cc047e36a254fb8df4d7ea18a46acf16c4c0cd3f3f3", + "path": "deps/flatbuffers" + }, + { + "kind": "tar.gz", + "url": "https://github.com/google/nsync/archive/refs/tags/1.26.0.tar.gz", + "sha256": "80fc1e605bb3cf5f272811ece39c4fb6761ffcb9b30563301845cc9ff381eb8b", + "path": "deps/google_nsync" + }, + { + "kind": "tar.gz", + "url": "https://github.com/google/re2/archive/refs/tags/2024-07-02.tar.gz", + "sha256": "eb2df807c781601c14a260a507a5bb4509be1ee626024cb45acbd57cb9d4032b", + "path": "deps/re2" + }, + { + "kind": "tar.gz", + "url": "https://github.com/libffi/libffi/releases/download/v3.5.2/libffi-3.5.2.tar.gz", + "sha256": "f3a3082a23b37c293a4fcd1053147b371f2ff91fa7ea1b2a52e335676bac82dc" + }, + { + "kind": "tar.gz", + "url": "https://github.com/madler/zlib/releases/download/v1.3.1/zlib-1.3.1.tar.gz", + "sha256": "9a93b2b7dfdac77ceba5a558a580e74667dd6fede4585b91eefb60f03b72df23" + }, + { + "kind": "tar.gz", + "url": "https://github.com/microsoft/GSL/archive/refs/tags/v4.0.0.tar.gz", + "sha256": "f0e32cb10654fea91ad56bde89170d78cfbf4363ee0b01d8f097de2ba49f6ce9", + "path": "deps/GSL" + }, + { + "kind": "tar.gz", + "url": "https://github.com/microsoft/onnxruntime/archive/refs/tags/v1.20.1.tar.gz", + "sha256": "d4c005506a2bbf88a838b14f8d1578406b8be2fb64abb50beeff908fb272529e" + }, + { + "kind": "tar.gz", + "url": "https://github.com/ninja-build/ninja/archive/refs/tags/v1.13.1.tar.gz", + "sha256": "f0055ad0369bf2e372955ba55128d000cfcc21777057806015b45e4accbebf23" + }, + { + "kind": "tar.gz", + "url": "https://github.com/nlohmann/json/archive/refs/tags/v3.10.5.tar.gz", + "sha256": "5daca6ca216495edf89d167f808d1d03c4a4d929cef7da5e10f135ae1540c7e4", + "path": "deps/nlohmann_json" + }, + { + "kind": "tar.gz", + "url": "https://github.com/nlohmann/json/archive/refs/tags/v3.11.3.tar.gz", + "sha256": "0d8ef5af7f9794e3263480193c491549b2ba6cc74bb018906202ada498a79406" + }, + { + "kind": "tar.gz", + "url": "https://github.com/onnx/onnx/archive/refs/tags/v1.16.1.tar.gz", + "sha256": "0e6aa2c0a59bb2d90858ad0040ea1807117cc2f05b97702170f18e6cd6b66fb3", + "path": "deps/onnx" + }, + { + "kind": "tar.gz", + "url": "https://github.com/protocolbuffers/protobuf/archive/refs/tags/v21.12.tar.gz", + "sha256": "22fdaf641b31655d4b2297f9981fa5203b2866f8332d3c6333f6b0107bb320de" + }, + { + "kind": "tar.gz", + "url": "https://github.com/protocolbuffers/protobuf/archive/refs/tags/v21.12.tar.gz", + "sha256": "22fdaf641b31655d4b2297f9981fa5203b2866f8332d3c6333f6b0107bb320de", + "path": "deps/protobuf" + }, + { + "kind": "tar.gz", + "url": "https://github.com/protocolbuffers/utf8_range/archive/72c943dea2b9240cd09efde15191e144bc7c7d38.tar.gz", + "sha256": "e008768a46ee0ee646b8e4ef02f55af3634b3ad38b750489eb793774331ca5bd", + "path": "deps/utf8_range" + }, + { + "kind": "tar.gz", + "url": "https://github.com/pytorch/cpuinfo/archive/ca678952a9a8eaa6de112d154e8e104b22f9ab3f.tar.gz", + "sha256": "c8f43b307fa7d911d88fec05448161eb1949c3fc0cb62f3a7a2c61928cdf2e9b", + "path": "deps/pytorch_cpuinfo" + }, + { + "kind": "tar.gz", + "url": "https://github.com/rockdaboot/libpsl/releases/download/0.21.5/libpsl-0.21.5.tar.gz", + "sha256": "1dcc9ceae8b128f3c0b3f654decd0e1e891afc6ff81098f227ef260449dae208" + }, + { + "kind": "tar.gz", + "url": "https://github.com/tpoechtrager/apple-libtapi/archive/refs/heads/1300.6.5.tar.gz", + "sha256": "a00b170901cc484c7041bbae1288e88ff3169728b572febd37418c52c2036935", + "path": "build/apple-libtapi" + }, + { + "kind": "tar.gz", + "url": "https://github.com/tpoechtrager/cctools-port/archive/refs/heads/986-ld64-711.tar.gz", + "sha256": "1b69237d99047afa8e840975d97b1733dcaba1d9135e1116d07f2f81cc0b8b64", + "path": "build/cctools-port" + }, + { + "kind": "tar.gz", + "url": "https://github.com/tpoechtrager/osxcross/archive/f873f534c6cdb0776e457af8c7513da1e02abe59.tar.gz", + "sha256": "7ff7657a435e709dfc81e79965bf2d0544d71bea26432991db8837b797290c28" + }, + { + "kind": "tar.gz", + "url": "https://github.com/tpoechtrager/pbzx/archive/2a4d7c3300c826d918def713a24d25c237c8ed53.tar.gz", + "sha256": "a9b3e9f29d9f020f75e4edf203359fbed6c1b0d2085f386bf770feaf07ae1694" + }, + { + "kind": "tar.gz", + "url": "https://github.com/tpoechtrager/xar/archive/5fa4675419cfec60ac19a9c7f7c2d0e7c831a497.tar.gz", + "sha256": "0ef6618d4b841c16d16ff6c9b0f1cd908f5f785ba08bef50178b293a7d170ff4" + }, + { + "kind": "tar.gz", + "url": "https://github.com/westes/flex/releases/download/v2.6.4/flex-2.6.4.tar.gz", + "sha256": "e87aae032bf07c26f85ac0ed3250998c37621d95f8bd748b31f15b33c45ee995" + }, + { + "kind": "tar.gz", + "url": "https://github.com/xkbcommon/libxkbcommon/archive/refs/tags/xkbcommon-1.13.1.tar.gz", + "sha256": "aeb951964c2f7ecc08174cb5517962d157595e9e3f38fc4a130b91dc2f9fec18" + }, + { + "kind": "tar.gz", + "url": "https://github.com/zxing-cpp/zxing-cpp/archive/refs/tags/v2.3.0.tar.gz", + "sha256": "64e4139103fdbc57752698ee15b5f0b0f7af9a0331ecbdc492047e0772c417ba" + }, + { + "kind": "tar.gz", + "url": "https://gitlab.freedesktop.org/wayland/wayland/-/archive/1.25.0/wayland-1.25.0.tar.gz", + "sha256": "95413723f6cd0462770eda207a1c78d142d0a1bba9b0572a4ed1da6a9b27059c" + }, + { + "kind": "tar.gz", + "url": "https://go.dev/dl/go1.25.0.src.tar.gz", + "sha256": "4bd01e91297207bfa450ea40d4d5a93b1b531a5e438473b2a06e18e077227225" + }, + { + "kind": "tar.gz", + "url": "https://go.dev/dl/go1.25.5.src.tar.gz", + "sha256": "22a5fd0a91efcd28a1b0537106b9959b2804b61f59c3758b51e8e5429c1a954f" + }, + { + "kind": "tar.gz", + "url": "https://pub.dev/api/archives/devtools_shared-10.0.2.tar.gz", + "sha256": "72369878105eccd563547afbad97407a2431b96bd4c04a1d6da75cb068437f50", + "path": "third_party/devtools/devtools_shared" + }, + { + "kind": "tar.gz", + "url": "https://pub.dev/api/archives/devtools_shared-11.2.0.tar.gz", + "sha256": "fa71f07006dfdf3f226ec76db95a4bad156820c081452cc99d18a4f291001bee", + "path": "third_party/devtools/devtools_shared" + }, + { + "kind": "tar.gz", + "url": "https://pub.dev/api/archives/devtools_shared-12.0.0.tar.gz", + "sha256": "275e48a8a145fa09c7ae433a96fd433c01cc079d39b40acf5ba883236ae2c887", + "path": "third_party/devtools/devtools_shared" + }, + { + "kind": "tar.gz", + "url": "https://sourceware.org/pub/bzip2/bzip2-1.0.8.tar.gz", + "sha256": "ab5a03176ee106d3f0fa90e381da478ddae405918153cca248e682cd0c4a2269" + }, + { + "kind": "tar.gz", + "url": "https://www.freedesktop.org/software/fontconfig/release/fontconfig-2.12.6.tar.gz", + "sha256": "064b9ebf060c9e77011733ac9dc0e2ce92870b574cca2405e11f5353a683c334" + }, + { + "kind": "tar.gz", + "url": "https://www.sqlite.org/2021/sqlite-autoconf-3350500.tar.gz", + "sha256": "f52b72a5c319c3e516ed7a92e123139a6e87af08a2dc43d7757724f6132e6db0" + }, + { + "kind": "tar.gz", + "url": "https://www.sqlite.org/2025/sqlite-autoconf-3510100.tar.gz", + "sha256": "4f2445cd70479724d32ad015ec7fd37fbb6f6130013bd4bfbc80c32beb42b7e0" + }, + { + "kind": "tar.gz", + "url": "https://xcb.freedesktop.org/dist/libxcb-1.17.0.tar.gz", + "sha256": "2c69287424c9e2128cb47ffe92171e10417041ec2963bceafb65cb3fcf8f0b85" + }, + { + "kind": "tar.gz", + "url": "https://xcb.freedesktop.org/dist/xcb-util-cursor-0.1.6.tar.gz", + "sha256": "eae38b2dfc5c529a886e507ef576b12d2a20aa1f149608e4853af760f31be60b" + }, + { + "kind": "tar.gz", + "url": "https://xorg.freedesktop.org/archive/individual/proto/xcb-proto-1.17.0.tar.gz", + "sha256": "392d3c9690f8c8202a68fdb89c16fd55159ab8d65000a6da213f4a1576e97a16" + }, + { + "kind": "tar.gz", + "url": "https://xorg.freedesktop.org/archive/individual/proto/xorgproto-2025.1.tar.gz", + "sha256": "d6f89f65bafb8c9b735e0515882b8a1511e8e864dde5e9513e191629369f2256" + }, + { + "kind": "tar.gz", + "url": "https://xorg.freedesktop.org/releases/individual/lib/libXau-1.0.12.tar.gz", + "sha256": "2402dd938da4d0a332349ab3d3586606175e19cb32cb9fe013c19f1dc922dcee" + }, + { + "kind": "tar.xz", + "url": "http://crosstool-ng.org/download/crosstool-ng/crosstool-ng-1.27.0.tar.xz", + "sha256": "0506ab98fa0ad6d263a555feeb2c7fff9bc24a434635d4b0cdff9137fe5b4477" + }, + { + "kind": "tar.xz", + "url": "http://crosstool-ng.org/download/crosstool-ng/crosstool-ng-1.28.0.tar.xz", + "sha256": "5750e29a2bda5cd8d67900592576b1670a1987a4dcd5e4f6beae09138a1f5699" + }, + { + "kind": "tar.xz", + "url": "http://ftpmirror.gnu.org/gnu/gcc/gcc-15.2.0/gcc-15.2.0.tar.xz", + "sha256": "438fd996826b0c82485a29da03a72d71d6e3541a83ec702df4271f6fe025d24e" + }, + { + "kind": "tar.xz", + "url": "http://ftpmirror.gnu.org/gnu/gmp/gmp-6.3.0.tar.xz", + "sha256": "a3c2b80201b89e68616f4ad30bc66aee4927c3ce50e33929ca819d5c43538898" + }, + { + "kind": "tar.xz", + "url": "http://ftpmirror.gnu.org/gnu/grep/grep-3.12.tar.xz", + "sha256": "2649b27c0e90e632eadcd757be06c6e9a4f48d941de51e7c0f83ff76408a07b9" + }, + { + "kind": "tar.xz", + "url": "http://ftpmirror.gnu.org/gnu/gzip/gzip-1.14.tar.xz", + "sha256": "01a7b881bd220bfdf615f97b8718f80bdfd3f6add385b993dcf6efd14e8c0ac6" + }, + { + "kind": "tar.xz", + "url": "http://ftpmirror.gnu.org/gnu/help2man/help2man-1.49.3.tar.xz", + "sha256": "4d7e4fdef2eca6afe07a2682151cea78781e0a4e8f9622142d9f70c083a2fd4f" + }, + { + "kind": "tar.xz", + "url": "http://ftpmirror.gnu.org/gnu/tar/tar-1.35.tar.xz", + "sha256": "4d62ff37342ec7aed748535323930c7cf94acf71c3591882b26a7ea50f3edc16" + }, + { + "kind": "tar.xz", + "url": "http://www.mpfr.org/mpfr-current/mpfr-4.2.2.tar.xz", + "sha256": "b67ba0383ef7e8a8563734e2e889ef5ec3c3b898a01d00fa0a6869ad81c6ce01" + }, + { + "kind": "tar.xz", + "url": "https://cdn.kernel.org/pub/linux/kernel/v6.x/linux-6.15.9.tar.xz", + "sha256": "e94f3af85492302f7a819441458f80bca0ad9912e5a4c83c699ff3c63c52957d" + }, + { + "kind": "tar.xz", + "url": "https://dbus.freedesktop.org/releases/dbus/dbus-1.14.10.tar.xz", + "sha256": "ba1f21d2bd9d339da2d4aa8780c09df32fea87998b73da24f49ab9df1e36a50f" + }, + { + "kind": "tar.xz", + "url": "https://download.gnome.org/sources/glib/2.86/glib-2.86.4.tar.xz", + "sha256": "d4e2b5d791d5015ffd8c6971ad8e975a0a55c1a14926cdb25cf843ff00682260" + }, + { + "kind": "tar.xz", + "url": "https://download.gnome.org/sources/libxml2/2.14/libxml2-2.14.5.tar.xz", + "sha256": "03d006f3537616833c16c53addcdc32a0eb20e55443cba4038307e3fa7d8d44b" + }, + { + "kind": "tar.xz", + "url": "https://download.qemu.org/qemu-10.2.1.tar.xz", + "sha256": "a3717477d8e2c84d630bfffbc20f6cd3293eb45aa1e6dac6d0cc27689991c9e1" + }, + { + "kind": "tar.xz", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtbase-everywhere-src-6.11.1.tar.xz", + "sha256": "d9594a31228aa23ad6b531719a29b45f0f3989fe6c136d45767ea179f233c1ac", + "path": "qtbase" + }, + { + "kind": "tar.xz", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtmultimedia-everywhere-src-6.11.1.tar.xz", + "sha256": "390f8e52ddee3aca5c4de7eead900c84c4fa61ff6d1f0ebea9c7543365c09b0a", + "path": "qtmultimedia" + }, + { + "kind": "tar.xz", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtshadertools-everywhere-src-6.11.1.tar.xz", + "sha256": "2075052f9b23bcf9de045bbd180037084942f82cce870aab14a1454902c982fc", + "path": "qtshadertools" + }, + { + "kind": "tar.xz", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtsvg-everywhere-src-6.11.1.tar.xz", + "sha256": "7f3cf02f4824bf03c2c5859ea6db173bf1482a1daf24e6cdf7bc78cfa26a8a94", + "path": "qtsvg" + }, + { + "kind": "tar.xz", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qttools-everywhere-src-6.11.1.tar.xz", + "sha256": "8e61835a679c93fa9c6065b142353c2071ba68e297898937c32a03777fcaf50d", + "path": "qttools" + }, + { + "kind": "tar.xz", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtwayland-everywhere-src-6.11.1.tar.xz", + "sha256": "95788aa502f75441d4edf65932b235f76523084e13dbbb7b9ee2d207b32bd9b3", + "path": "qtwayland" + }, + { + "kind": "tar.xz", + "url": "https://download.qt.io/official_releases/qt/6.11/6.11.1/submodules/qtwebsockets-everywhere-src-6.11.1.tar.xz", + "sha256": "243e3aa11924c8c5c1645e892f62d013caa3766c57512ca926d5b58146646fbf", + "path": "qtwebsockets" + }, + { + "kind": "tar.xz", + "url": "https://ftp.gnu.org/gnu/diffutils/diffutils-3.12.tar.xz", + "sha256": "7c8b7f9fc8609141fdea9cece85249d308624391ff61dedaf528fcb337727dfd" + }, + { + "kind": "tar.xz", + "url": "https://ftp.gnu.org/gnu/findutils/findutils-4.10.0.tar.xz", + "sha256": "1387e0b67ff247d2abde998f90dfbf70c1491391a59ddfecb8ae698789f0a4f5" + }, + { + "kind": "tar.xz", + "url": "https://ftpmirror.gnu.org/gnu/coreutils/coreutils-9.9.tar.xz", + "sha256": "19bcb6ca867183c57d77155eae946c5eced88183143b45ca51ad7d26c628ca75" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-aarch64-apple-darwin.tar.xz", + "sha256": "125e86a1f93fb5572d07453e6ec2160066be94aed77a1625dfe5e5df12a58247" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-aarch64-apple-darwin.tar.xz", + "sha256": "af55cf7e7aaa6f387fd4b91ed9f994efb866a2c87897da562bb098b8540170d2" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-aarch64-apple-darwin.tar.xz", + "sha256": "f08445d419c7ac00e47e458618575cf3cb24db27d9c2e8636845288d8884b3c8" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-aarch64-apple-darwin.tar.xz", + "sha256": "fc16c4af5eb4af3a2a065404679a59db0f8ebeb4f22346ecf954b35bd05a49b0" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-aarch64-linux-gnu.tar.xz", + "sha256": "9962a2889f1782e904baa34a77e9e12d2fe7feecb845287f378999c7e442d001" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-aarch64-linux-gnu.tar.xz", + "sha256": "a32317df0c3985f5da430bd6f9a8b9b1b194810d9755a51faa9a46f7c7cec1c0" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-aarch64-linux-gnu.tar.xz", + "sha256": "b50f5b89157206e013f1e37f922c812d3fdc960e512dda6b5c69e692538ffd0c" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-x86_64-linux-gnu.tar.xz", + "sha256": "80b749abd76d6ef01b17c4dc0fd8eb0b7ae7a88bfacad559625fa94da0ae6477" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-x86_64-linux-gnu.tar.xz", + "sha256": "9442ba966d3a1d3134e55ab21bf55ee3d4f281c0b850e3ef476a6314d373524d" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r0/clang21-x86_64-linux-gnu.tar.xz", + "sha256": "bad39866fe2a91d1c399e09094c109c38ab911277f7c2367eb850cd423f7d78d" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r1/clang21-aarch64-apple-darwin.tar.xz", + "sha256": "80e16711526b83f323a1014479a19a816e24f785f30dd712b5be297cc9b604e1" + }, + { + "kind": "tar.xz", + "url": "https://github.com/MrCyjaneK/easybs/releases/download/r2/clang20-x86_64-windows-cygwin.tar.xz", + "sha256": "6b31052404b8c5eb9f66c48230aafa4e2947b9dc6a6048515aae67e9c33e87a6" + }, + { + "kind": "tar.xz", + "url": "https://github.com/llvm/llvm-project/releases/download/llvmorg-19.1.7/llvm-project-19.1.7.src.tar.xz", + "sha256": "82401fea7b79d0078043f7598b835284d6650a75b93e64b6f761ea7b63097501" + }, + { + "kind": "tar.xz", + "url": "https://static.mrcyjanek.net/bootstrap/clang21-aarch64-apple-darwin.tar.xz", + "sha256": "735e9433e8961ab960b9a7c68a1f4ded5d0a6eecf8de58cd7bad80550ae184f1" + }, + { + "kind": "tar.xz", + "url": "https://xcb.freedesktop.org/dist/xcb-util-0.4.1.tar.xz", + "sha256": "5abe3bbbd8e54f0fa3ec945291b7e8fa8cfd3cccc43718f8758430f94126e512" + }, + { + "kind": "tar.xz", + "url": "https://xcb.freedesktop.org/dist/xcb-util-image-0.4.1.tar.xz", + "sha256": "ccad8ee5dadb1271fd4727ad14d9bd77a64e505608766c4e98267d9aede40d3d" + }, + { + "kind": "tar.xz", + "url": "https://xcb.freedesktop.org/dist/xcb-util-keysyms-0.4.1.tar.xz", + "sha256": "7c260a5294412aed429df1da2f8afd3bd07b7cba3fec772fba15a613a6d5c638" + }, + { + "kind": "tar.xz", + "url": "https://xcb.freedesktop.org/dist/xcb-util-renderutil-0.3.10.tar.xz", + "sha256": "3e15d4f0e22d8ddbfbb9f5d77db43eacd7a304029bf25a6166cc63caa96d04ba" + }, + { + "kind": "tar.xz", + "url": "https://xcb.freedesktop.org/dist/xcb-util-wm-0.4.2.tar.xz", + "sha256": "62c34e21d06264687faea7edbf63632c9f04d55e72114aa4a57bb95e4f888a0b" + } + ] +} \ No newline at end of file diff --git a/utils/copy.go b/utils/copy.go new file mode 100644 index 0000000..9984ad7 --- /dev/null +++ b/utils/copy.go @@ -0,0 +1,13 @@ +package utils + +import ( + "os" +) + +func Copy(src string, dst string) error { + data, err := os.ReadFile(src) + if err != nil { + return err + } + return os.WriteFile(dst, data, 0644) +} diff --git a/utils/download.go b/utils/download.go deleted file mode 100644 index 7186cdb..0000000 --- a/utils/download.go +++ /dev/null @@ -1,137 +0,0 @@ -package utils - -import ( - "crypto/sha256" - "encoding/hex" - "fmt" - "io" - "log" - "net/http" - "os" - "path/filepath" - "strconv" - "strings" - "time" -) - -type ProgressWriter struct { - writer io.Writer - total int64 - written int64 - lastUpdate time.Time - filename string -} - -func NewProgressWriter(writer io.Writer, total int64, filename string) *ProgressWriter { - return &ProgressWriter{ - writer: writer, - total: total, - filename: filename, - lastUpdate: time.Now(), - } -} - -func (pw *ProgressWriter) Write(p []byte) (int, error) { - n, err := pw.writer.Write(p) - if err != nil { - return n, err - } - - pw.written += int64(n) - - if time.Since(pw.lastUpdate) > 100*time.Millisecond { - pw.displayProgress() - pw.lastUpdate = time.Now() - } - - return n, err -} - -func (pw *ProgressWriter) displayProgress() { - if pw.total <= 0 { - fmt.Printf("\r%s: Downloaded %s", pw.filename, formatBytes(pw.written)) - } else { - percentage := float64(pw.written) / float64(pw.total) * 100 - fmt.Printf("\r%s: %.1f%% (%s / %s)", pw.filename, percentage, formatBytes(pw.written), formatBytes(pw.total)) - } -} - -func (pw *ProgressWriter) finish() { - fmt.Printf("\r%s: Complete (%s)\n", pw.filename, formatBytes(pw.written)) -} - -func formatBytes(bytes int64) string { - const unit = 1024 - if bytes < unit { - return fmt.Sprintf("%d B", bytes) - } - div, exp := int64(unit), 0 - for n := bytes / unit; n >= unit; n /= unit { - div *= unit - exp++ - } - return fmt.Sprintf("%.1f %cB", float64(bytes)/float64(div), "KMGTPE"[exp%len("KMGTPE")]) -} - -func DownloadFile(packageName, path, url, expectedSha256 string, isMirror bool) error { - log.Printf("Downloading %s to %s", url, path) - - if !isMirror { - err := DownloadFile(packageName, path, "http://static.mrcyjanek.net/lfs/simplybs/source/"+filepath.Base(path), expectedSha256, true) - if err != nil { - log.Printf("Failed to download file from mirror: %v, trying original URL", err) - } else { - log.Printf("Downloaded file from mirror: %s", path) - return nil - } - } - - resp, err := http.Get(url) - if err != nil { - return fmt.Errorf("Failed to download file from %s: %v", url, err) - } - defer resp.Body.Close() - - if resp.StatusCode != http.StatusOK { - return fmt.Errorf("Failed to download file: HTTP %d %s", resp.StatusCode, resp.Status) - } - - var totalSize int64 - if contentLength := resp.Header.Get("Content-Length"); contentLength != "" { - if size, err := strconv.ParseInt(contentLength, 10, 64); err == nil { - totalSize = size - } - } - - out, err := os.Create(path) - if err != nil { - return fmt.Errorf("Failed to create file %s: %v", path, err) - } - defer out.Close() - - hasher := sha256.New() - - filename := path - if idx := strings.LastIndex(path, "/"); idx >= 0 { - filename = path[idx+1:] - } - - progressWriter := NewProgressWriter(out, totalSize, filename) - multiWriter := io.MultiWriter(progressWriter, hasher) - - _, err = io.Copy(multiWriter, resp.Body) - if err != nil { - return fmt.Errorf("Failed to write file %s: %v", path, err) - } - - progressWriter.finish() - - actualHash := hex.EncodeToString(hasher.Sum(nil)) - if actualHash != expectedSha256 { - os.Remove(path) - return fmt.Errorf("SHA256 hash mismatch for %s: expected %s, got %s", path, expectedSha256, actualHash) - } - - log.Printf("Successfully downloaded and verified %s", path) - return nil -} diff --git a/utils/download/download.go b/utils/download/download.go new file mode 100644 index 0000000..5ad6369 --- /dev/null +++ b/utils/download/download.go @@ -0,0 +1,438 @@ +package download + +import ( + "crypto/sha256" + "crypto/tls" + "encoding/hex" + "errors" + "fmt" + "io" + "log" + "net/http" + "net/url" + "os" + "path" + "path/filepath" + "strconv" + "strings" + "time" +) + +const maxDownloadRetries = 15 +const downloadRetryDelay = 5 * time.Second + +var ErrHashMismatch = errors.New("sha256 hash mismatch") + +var defaultHTTPClient = &http.Client{ + Transport: &http.Transport{ + // Avoid HTTP/2 stream errors on large mirror downloads. + TLSNextProto: make(map[string]func(string, *tls.Conn) http.RoundTripper), + }, +} + +func downloadTempPath(path string) string { + return path + ".download.tmp" +} + +func fileSizeAt(path string) int64 { + if info, err := os.Stat(path); err == nil { + return info.Size() + } + return 0 +} + +type ProgressWriter struct { + writer io.Writer + total int64 + offset int64 + written int64 + lastUpdate time.Time + filename string +} + +func NewProgressWriter(writer io.Writer, total, offset int64, filename string) *ProgressWriter { + return &ProgressWriter{ + writer: writer, + total: total, + offset: offset, + filename: filename, + lastUpdate: time.Now(), + } +} + +func (pw *ProgressWriter) downloaded() int64 { + return pw.offset + pw.written +} + +func (pw *ProgressWriter) Write(p []byte) (int, error) { + n, err := pw.writer.Write(p) + if err != nil { + return n, err + } + + pw.written += int64(n) + + if time.Since(pw.lastUpdate) > 100*time.Millisecond { + pw.displayProgress() + pw.lastUpdate = time.Now() + } + + return n, err +} + +func (pw *ProgressWriter) displayProgress() { + downloaded := pw.downloaded() + var line string + if pw.total <= 0 { + line = fmt.Sprintf("%s: Downloaded %s", pw.filename, formatBytes(downloaded)) + } else { + percentage := float64(downloaded) / float64(pw.total) * 100 + line = fmt.Sprintf("%s: %.1f%% (%s / %s)", pw.filename, percentage, formatBytes(downloaded), formatBytes(pw.total)) + } + // Pad to erase leftover characters from shorter previous lines. + fmt.Printf("\r%-80s", line) +} + +func (pw *ProgressWriter) finish() { + fmt.Printf("\r%s: Complete (%s)\n", pw.filename, formatBytes(pw.downloaded())) +} + +func copyWithProgress(dst io.Writer, src io.Reader, total, offset int64, filename string) (int64, error) { + pw := NewProgressWriter(dst, total, offset, filename) + n, err := io.Copy(pw, src) + if err != nil { + return n, err + } + pw.finish() + return n, nil +} + +func contentLengthTotal(resp *http.Response, existing int64) int64 { + if contentLength := resp.Header.Get("Content-Length"); contentLength != "" { + if size, err := strconv.ParseInt(contentLength, 10, 64); err == nil { + return existing + size + } + } + return 0 +} + +func downloadToFileWithResume(destPath, url string) (int64, error) { + var fileSize int64 + var out *os.File + var err error + + if info, err := os.Stat(destPath); err == nil { + fileSize = info.Size() + out, err = os.OpenFile(destPath, os.O_APPEND|os.O_WRONLY, 0644) + if err != nil { + return 0, fmt.Errorf("failed to open file for append: %v", err) + } + } else { + out, err = os.Create(destPath) + if err != nil { + return 0, fmt.Errorf("failed to create file: %v", err) + } + } + defer out.Close() + + req, err := http.NewRequest("GET", url, nil) + if err != nil { + return 0, fmt.Errorf("failed to create request: %v", err) + } + // req.Header.Set("User-Agent", "simplybs/1.0 (+https://github.com/mrcyjanek/simplybs)") + + if fileSize > 0 { + req.Header.Set("Range", fmt.Sprintf("bytes=%d-", fileSize)) + log.Printf("Resuming download from byte %d", fileSize) + } + + resp, err := defaultHTTPClient.Do(req) + if err != nil { + return 0, fmt.Errorf("failed to download file: %v", err) + } + defer resp.Body.Close() + + if resp.StatusCode != http.StatusOK && resp.StatusCode != http.StatusPartialContent { + return 0, fmt.Errorf("HTTP %d %s", resp.StatusCode, resp.Status) + } + + if resp.StatusCode == http.StatusOK && fileSize > 0 { + out.Close() + out, err = os.Create(destPath) + if err != nil { + return 0, fmt.Errorf("failed to recreate file: %v", err) + } + fileSize = 0 + log.Printf("Server doesn't support resume, starting from beginning") + } + + filename := filepath.Base(destPath) + if strings.HasSuffix(filename, ".download.tmp") { + filename = strings.TrimSuffix(filename, ".download.tmp") + } + bytesRead, err := copyWithProgress(out, resp.Body, contentLengthTotal(resp, fileSize), fileSize, filename) + if err != nil { + return fileSize + bytesRead, fmt.Errorf("failed to write file: %v", err) + } + + return fileSize + bytesRead, nil +} + +func shouldResetRetryCount(err error, partialPath string, startSize, bytesReceived int64) bool { + if bytesReceived <= startSize { + return false + } + if errors.Is(err, ErrHashMismatch) { + return false + } + return fileSizeAt(partialPath) > startSize +} + +// DownloadURLWithRetries downloads url to destPath with progress, resume, and retries. +func DownloadURLWithRetries(url, destPath string) error { + attempt := 0 + for attempt <= maxDownloadRetries { + if attempt > 0 { + log.Printf("Retry attempt %d/%d for %s", attempt, maxDownloadRetries, url) + time.Sleep(downloadRetryDelay) + } + + startSize := fileSizeAt(destPath) + bytesReceived, err := downloadToFileWithResume(destPath, url) + if err == nil { + return nil + } + + if bytesReceived == 0 && attempt == 0 { + return fmt.Errorf("no data received from server: %v", err) + } + + log.Printf("Download failed: %v", err) + + if shouldResetRetryCount(err, destPath, startSize, bytesReceived) { + log.Printf("Made progress (%s), resetting retry count", formatBytes(bytesReceived-startSize)) + attempt = 0 + continue + } + + attempt++ + if attempt > maxDownloadRetries { + return fmt.Errorf("failed after %d retries: %v", maxDownloadRetries, err) + } + } + return fmt.Errorf("download failed after all retries") +} + +func formatBytes(bytes int64) string { + const unit = 1024 + if bytes < unit { + return fmt.Sprintf("%d B", bytes) + } + div, exp := int64(unit), 0 + for n := bytes / unit; n >= unit; n /= unit { + div *= unit + exp++ + } + return fmt.Sprintf("%.1f %cB", float64(bytes)/float64(div), "KMGTPE"[exp%len("KMGTPE")]) +} + +func GetMirrors() []string { + mirrors := []string{ + "http://static.mrcyjanek.net/lfs/simplybs/source/", + } + if customMirror := os.Getenv("SIMPLYBS_MIRROR"); customMirror != "" { + mirrors = append([]string{customMirror}, mirrors...) + } + return mirrors +} + +func URLToPath(urlStr string) (string, error) { + parsedURL, err := url.Parse(urlStr) + if err != nil { + return "", fmt.Errorf("failed to parse URL: %v", err) + } + + // Always slash-separated: used as a mirror URL suffix and as a relative + // cache key. Callers that need a filesystem path must filepath.FromSlash. + rel := strings.TrimPrefix(parsedURL.Path, "/") + return path.Join(parsedURL.Host, rel), nil +} + +func DownloadFile(packageName, path, url, expectedSha256 string, isMirror bool) error { + log.Printf("Downloading %s to %s", url, path) + + if !isMirror { + urlPath, err := URLToPath(url) + if err != nil { + log.Printf("Failed to convert URL to path: %v", err) + } else { + mirrors := GetMirrors() + for _, mirror := range mirrors { + mirrorURL := mirror + urlPath + err := DownloadFile(packageName, path, mirrorURL, expectedSha256, true) + if err != nil { + log.Printf("Failed to download file from mirror %s: %v", mirror, err) + continue + } + log.Printf("Downloaded file from mirror: %s", path) + return nil + } + log.Printf("All mirrors failed, trying original URL") + } + } + + os.MkdirAll(filepath.Dir(path), 0755) + + candidates := []string{url} + if alt := gnuFtpFallbackURL(url); alt != "" && alt != url { + // Prefer mirrors.kernel.org when ftpmirror is flaky (502 / timeouts). + candidates = []string{alt, url} + } + + var lastErr error + for _, candidate := range candidates { + attempt := 0 + for attempt <= maxDownloadRetries { + if attempt > 0 { + log.Printf("Retry attempt %d/%d for %s", attempt, maxDownloadRetries, candidate) + time.Sleep(downloadRetryDelay) + } + + startSize := fileSizeAt(downloadTempPath(path)) + bytesReceived, err := downloadWithResume(path, candidate, expectedSha256) + if err == nil { + log.Printf("Successfully downloaded and verified %s", path) + return nil + } + lastErr = err + + if bytesReceived == 0 && attempt == 0 { + log.Printf("No data from %s: %v", candidate, err) + break + } + + log.Printf("Download failed: %v", err) + + if shouldResetRetryCount(err, downloadTempPath(path), startSize, bytesReceived) { + log.Printf("Made progress (%s), resetting retry count", formatBytes(bytesReceived-startSize)) + attempt = 0 + continue + } + + attempt++ + if attempt > maxDownloadRetries { + log.Printf("Failed after %d retries for %s: %v", maxDownloadRetries, candidate, err) + break + } + } + } + + if lastErr != nil { + return fmt.Errorf("download failed after all retries: %v", lastErr) + } + return fmt.Errorf("download failed after all retries") +} + +// gnuFtpFallbackURL maps flaky GNU FTP hosts to mirrors.kernel.org. +func gnuFtpFallbackURL(raw string) string { + u, err := url.Parse(raw) + if err != nil { + return "" + } + host := strings.ToLower(u.Host) + switch host { + case "ftpmirror.gnu.org", "www.ftpmirror.gnu.org", "ftp.gnu.org", "www.gnu.org": + default: + return "" + } + u.Scheme = "https" + u.Host = "mirrors.kernel.org" + // www.gnu.org paths are under /software/...; kernel mirror only has /gnu/. + if host == "www.gnu.org" { + return "" + } + return u.String() +} + +func downloadWithResume(path, url, expectedSha256 string) (int64, error) { + tempPath := downloadTempPath(path) + + bytesRead, err := downloadToFileWithResume(tempPath, url) + if err != nil { + return bytesRead, err + } + + file, err := os.Open(tempPath) + if err != nil { + return bytesRead, fmt.Errorf("failed to open file for verification: %v", err) + } + + hasher := sha256.New() + if _, err := io.Copy(hasher, file); err != nil { + file.Close() + return bytesRead, fmt.Errorf("failed to calculate hash: %v", err) + } + file.Close() + + actualHash := hex.EncodeToString(hasher.Sum(nil)) + if actualHash != expectedSha256 { + os.Remove(tempPath) + return bytesRead, fmt.Errorf("%w: expected %s, got %s", ErrHashMismatch, expectedSha256, actualHash) + } + + if err := os.Rename(tempPath, path); err != nil { + // Windows can refuse rename if AV still has a handle; fall back to copy. + if copyErr := copyFile(tempPath, path); copyErr != nil { + os.Remove(tempPath) + return bytesRead, fmt.Errorf("failed to move download into place: %v (copy fallback: %v)", err, copyErr) + } + os.Remove(tempPath) + } + + return bytesRead, nil +} + +func copyFile(src, dst string) error { + in, err := os.Open(src) + if err != nil { + return err + } + defer in.Close() + out, err := os.OpenFile(dst, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, 0644) + if err != nil { + return err + } + defer out.Close() + if _, err := io.Copy(out, in); err != nil { + return err + } + return out.Close() +} + +func FileSHA256(path string) (string, error) { + file, err := os.Open(path) + if err != nil { + return "", err + } + defer file.Close() + + hasher := sha256.New() + if _, err := io.Copy(hasher, file); err != nil { + return "", err + } + return hex.EncodeToString(hasher.Sum(nil)), nil +} + +func EnsureDownloadFile(packageName, path, url, expectedSha256 string) error { + if actualHash, err := FileSHA256(path); err == nil { + if actualHash == expectedSha256 { + log.Printf("File already exists with correct hash: %s", path) + return nil + } + log.Printf("File exists but hash mismatch (expected %s, got %s), re-downloading: %s", expectedSha256, actualHash, path) + os.Remove(path) + os.Remove(downloadTempPath(path)) + } + + return DownloadFile(packageName, path, url, expectedSha256, false) +} diff --git a/utils/download/download_test.go b/utils/download/download_test.go new file mode 100644 index 0000000..eee41f7 --- /dev/null +++ b/utils/download/download_test.go @@ -0,0 +1,66 @@ +package download + +import ( + "fmt" + "os" + "path/filepath" + "testing" +) + +func TestEnsureDownloadFileSkipsValidFile(t *testing.T) { + dir := t.TempDir() + path := filepath.Join(dir, "test.txt") + content := []byte("hello") + if err := os.WriteFile(path, content, 0644); err != nil { + t.Fatalf("write file: %v", err) + } + + expectedHash, err := FileSHA256(path) + if err != nil { + t.Fatalf("hash file: %v", err) + } + + if err := EnsureDownloadFile("test", path, "https://example.com/test.txt", expectedHash); err != nil { + t.Fatalf("expected skip, got error: %v", err) + } +} + +func TestEnsureDownloadFileRejectsInvalidHash(t *testing.T) { + dir := t.TempDir() + path := filepath.Join(dir, "test.txt") + if err := os.WriteFile(path, []byte("hello"), 0644); err != nil { + t.Fatalf("write file: %v", err) + } + + err := EnsureDownloadFile("test", path, "https://invalid.test/no-such-file", "0000000000000000000000000000000000000000000000000000000000000000") + if err == nil { + t.Fatal("expected download error for invalid hash and unreachable URL") + } + + if _, statErr := os.Stat(path); statErr == nil { + t.Fatal("expected stale file to be removed before re-download attempt") + } +} + +func TestShouldResetRetryCount(t *testing.T) { + dir := t.TempDir() + partial := filepath.Join(dir, "partial.bin") + + if shouldResetRetryCount(fmt.Errorf("network"), partial, 0, 0) { + t.Fatal("expected no reset without progress") + } + + if err := os.WriteFile(partial, make([]byte, 128), 0644); err != nil { + t.Fatalf("write partial: %v", err) + } + if !shouldResetRetryCount(fmt.Errorf("network"), partial, 0, 128) { + t.Fatal("expected reset when partial file remains") + } + + if err := os.Remove(partial); err != nil { + t.Fatalf("remove partial: %v", err) + } + if shouldResetRetryCount(fmt.Errorf("%w: expected x, got y", ErrHashMismatch), partial, 0, 128) { + t.Fatal("hash mismatch must not reset retry count") + } +} diff --git a/utils/env.go b/utils/env.go index bb5198a..5d69a6f 100644 --- a/utils/env.go +++ b/utils/env.go @@ -5,33 +5,34 @@ import ( "os" "strings" + "github.com/mrcyjanek/simplybs/builder" "github.com/mrcyjanek/simplybs/host" - "github.com/ryanuber/go-glob" + "github.com/mrcyjanek/simplybs/utils/ifstring" ) func ExpandEnvFromMap(s string, envMap map[string]string) string { - return os.Expand(s, func(key string) string { + ret := os.Expand(s, func(key string) string { if val, ok := envMap[key]; ok { return val } return "" }) + return ret } func AppendEnv(env map[string]string, newEnv []string, host *host.Host) map[string]string { for _, envVar := range newEnv { - exp := ExpandEnvFromMap(envVar, env) - colonIndex := strings.Index(exp, ":") - equalIndex := strings.Index(exp, "=") - if colonIndex == -1 || equalIndex == -1 { - log.Fatalf("Invalid env var: %s. Vars needs to be in the form of all:KEY=VALUE", exp) + is := ifstring.ParseIfString(envVar) + is.Content = ExpandEnvFromMap(is.Content, env) + equalIndex := strings.Index(is.Content, "=") + if equalIndex == -1 { + log.Fatalf("Invalid env var: %s. Vars needs to be in the form of *:KEY=VALUE", envVar) } - prefix := exp[0:colonIndex] - if !glob.Glob(prefix, host.Triplet) && prefix != "all" { + if !is.Matches(host.Triplet, builder.GetName()) { continue } - k := exp[colonIndex+1 : equalIndex] - v := exp[equalIndex+1:] + k := is.Content[:equalIndex] + v := is.Content[equalIndex+1:] env[k] = v } return env diff --git a/utils/extract.go b/utils/extract.go index 89fc509..f39fca2 100644 --- a/utils/extract.go +++ b/utils/extract.go @@ -52,6 +52,9 @@ func detectCommonPrefix(readerFactory readerFactory) (string, error) { if len(firstLevelDirs) == 1 && rootFiles == 0 { for dirName := range firstLevelDirs { + if (dirName == "native") { + return "", nil + } return dirName + "/", nil } } @@ -59,6 +62,32 @@ func detectCommonPrefix(readerFactory readerFactory) (string, error) { return "", nil } +func ensureParentDirsPermissions(target, destPath string) error { + parentDir := filepath.Dir(target) + + for { + if parentDir == destPath || parentDir == filepath.Dir(destPath) { + break + } + + if err := os.MkdirAll(parentDir, 0755); err != nil { + return err + } + + if err := os.Chmod(parentDir, 0755); err != nil { + return err + } + + nextParent := filepath.Dir(parentDir) + if nextParent == parentDir { + break + } + parentDir = nextParent + } + + return nil +} + func extractTar(tr *tar.Reader, destPath, commonPrefix string) error { for { header, err := tr.Next() @@ -85,17 +114,21 @@ func extractTar(tr *tar.Reader, destPath, commonPrefix string) error { continue } + // Ensure parent directories have rwx permissions up to destPath + if err := ensureParentDirsPermissions(target, destPath); err != nil { + log.Printf("Warning: Failed to set permissions for parent directories of %s: %v", target, err) + } + switch header.Typeflag { case tar.TypeDir: dirMode := os.FileMode(header.Mode) & 0777 if dirMode == 0 { dirMode = 0755 } - if dirMode&0111 == 0 { - dirMode |= 0755 - } + dirMode |= 0700 - if err := os.MkdirAll(target, dirMode); err != nil { + if err := os.MkdirAll(target, dirMode); err != nil && !os.IsExist(err) { + log.Fatalln(err) return err } @@ -103,7 +136,8 @@ func extractTar(tr *tar.Reader, destPath, commonPrefix string) error { log.Printf("Warning: Failed to set timestamps for directory %s: %v", target, err) } case tar.TypeReg: - if err := os.MkdirAll(filepath.Dir(target), 0755); err != nil { + if err := os.MkdirAll(filepath.Dir(target), 0755); err != nil && !os.IsExist(err) { + log.Fatalln(err) return err } @@ -113,6 +147,7 @@ func extractTar(tr *tar.Reader, destPath, commonPrefix string) error { } fileMode &^= (os.ModeSetuid | os.ModeSetgid | os.ModeSticky) + os.Chmod(target, 0777) os.Remove(target) outFile, err := os.OpenFile(target, os.O_CREATE|os.O_RDWR, fileMode) @@ -131,6 +166,7 @@ func extractTar(tr *tar.Reader, destPath, commonPrefix string) error { } case tar.TypeSymlink: if err := os.MkdirAll(filepath.Dir(target), 0755); err != nil { + panic(err) return err } @@ -140,7 +176,7 @@ func extractTar(tr *tar.Reader, destPath, commonPrefix string) error { log.Printf("Warning: Failed to create symbolic link %s -> %s: %v", target, header.Linkname, err) } else { if err := os.Chtimes(target, header.AccessTime, header.ModTime); err != nil { - log.Printf("Warning: Failed to set timestamps for symlink %s: %v", target, err) + // log.Printf("Warning: Failed to set timestamps for symlink %s: %v", target, err) } } } @@ -205,17 +241,13 @@ func createXzTarReader(archivePath string) (*tar.Reader, func(), error) { return tr, cleanup, nil } -func ExtractTarGz(archivePath, destPath string) error { +func extractTarArchive(archivePath, destPath, logLabel string, readerFactory func() (*tar.Reader, func(), error)) error { if _, err := os.Stat(archivePath); os.IsNotExist(err) { log.Printf("Archive not found: %s", archivePath) return err } - log.Printf("Extracting archive: %s into %s", archivePath, destPath) - - readerFactory := func() (*tar.Reader, func(), error) { - return createGzipTarReader(archivePath) - } + log.Printf("%s: %s into %s", logLabel, archivePath, destPath) commonPrefix, err := detectCommonPrefix(readerFactory) if err != nil { @@ -239,72 +271,22 @@ func ExtractTarGz(archivePath, destPath string) error { return nil } -func ExtractTarBz2(archivePath, destPath string) error { - if _, err := os.Stat(archivePath); os.IsNotExist(err) { - log.Printf("Archive not found: %s", archivePath) - return err - } - - log.Printf("Extracting bz2 archive: %s into %s", archivePath, destPath) +func ExtractTarGz(archivePath, destPath string) error { + return extractTarArchive(archivePath, destPath, "Extracting archive", func() (*tar.Reader, func(), error) { + return createGzipTarReader(archivePath) + }) +} - readerFactory := func() (*tar.Reader, func(), error) { +func ExtractTarBz2(archivePath, destPath string) error { + return extractTarArchive(archivePath, destPath, "Extracting bz2 archive", func() (*tar.Reader, func(), error) { return createBzip2TarReader(archivePath) - } - - commonPrefix, err := detectCommonPrefix(readerFactory) - if err != nil { - return err - } - - tr, cleanup, err := readerFactory() - if err != nil { - return err - } - defer cleanup() - - if err := extractTar(tr, destPath, commonPrefix); err != nil { - return err - } - - if commonPrefix != "" { - log.Printf("Stripped common directory prefix: %s", commonPrefix) - } - - return nil + }) } func ExtractTarXz(archivePath, destPath string) error { - if _, err := os.Stat(archivePath); os.IsNotExist(err) { - log.Printf("Archive not found: %s", archivePath) - return err - } - - log.Printf("Extracting xz archive: %s into %s", archivePath, destPath) - - readerFactory := func() (*tar.Reader, func(), error) { + return extractTarArchive(archivePath, destPath, "Extracting xz archive", func() (*tar.Reader, func(), error) { return createXzTarReader(archivePath) - } - - commonPrefix, err := detectCommonPrefix(readerFactory) - if err != nil { - return err - } - - tr, cleanup, err := readerFactory() - if err != nil { - return err - } - defer cleanup() - - if err := extractTar(tr, destPath, commonPrefix); err != nil { - return err - } - - if commonPrefix != "" { - log.Printf("Stripped common directory prefix: %s", commonPrefix) - } - - return nil + }) } func writeFileToTar(tw *tar.Writer, header *tar.Header, filePath string) error { @@ -374,6 +356,12 @@ func CreateTarGz(sourcePath, archivePath string) error { header, err := tar.FileInfoHeader(info, "") if err != nil { + // Windows reparse points / Cygwin native symlinks show up as + // ModeIrregular and cannot be archived by archive/tar. + if info.Mode()&os.ModeIrregular != 0 { + log.Printf("skipping irregular file (not archivable): %s", path) + continue + } return err } @@ -393,19 +381,8 @@ func CreateTarGz(sourcePath, archivePath string) error { } if info.Mode().IsRegular() { - var filePath string - var cleanup func() - - if strings.HasSuffix(strings.ToLower(relPath), ".a") { - // TODO: repack static libraries - filePath = path - cleanup = func() {} - } else { - filePath = path - cleanup = func() {} - } + var filePath = path - defer cleanup() if err := writeFileToTar(tw, header, filePath); err != nil { return err } diff --git a/utils/git.go b/utils/git.go index 6348d4c..578a3fc 100644 --- a/utils/git.go +++ b/utils/git.go @@ -1,116 +1,288 @@ package utils import ( + "encoding/json" + "fmt" "log" "os" + "os/exec" + "path" + "path/filepath" + "strings" - "github.com/go-git/go-git/v5" - "github.com/go-git/go-git/v5/plumbing" + "github.com/mrcyjanek/simplybs/utils/download" ) -func optimizeGitRepo(repoPath string) { - log.Printf("Optimizing repository at %s", repoPath) +func gitCommand(args ...string) *exec.Cmd { + return exec.Command(ResolveGit(), args...) +} - repo, err := git.PlainOpen(repoPath) - if err != nil { - log.Printf("Warning: Failed to open repository at %s: %v", repoPath, err) - return +func verifyBundleHasRef(bundlePath string, refs []string) bool { + tempVerifyDir := bundlePath + ".verify.tmp" + defer RemoveAll(tempVerifyDir) + + os.MkdirAll(tempVerifyDir, 0755) + + // Initialize a temporary git repo + initCmd := gitCommand("init") + initCmd.Dir = tempVerifyDir + if err := initCmd.Run(); err != nil { + return false } - remotes, err := repo.Remotes() - if err == nil { - for _, remote := range remotes { - err = repo.DeleteRemote(remote.Config().Name) - if err != nil { - log.Printf("Warning: Failed to remove remote %s in %s: %v", remote.Config().Name, repoPath, err) - } + for _, ref := range refs { + fetchCmd := gitCommand("fetch", bundlePath, ref) + fetchCmd.Dir = tempVerifyDir + if err := fetchCmd.Run(); err != nil { + log.Printf("Bundle does not contain ref %s", ref) + return false } + log.Printf("Bundle contains ref %s", ref) } - refs, err := repo.References() - if err == nil { - head, headErr := repo.Head() - if headErr == nil { - err = refs.ForEach(func(ref *plumbing.Reference) error { - if ref.Name().IsBranch() && ref.Hash() != head.Hash() { - return repo.Storer.RemoveReference(ref.Name()) - } - return nil - }) - if err != nil { - log.Printf("Warning: Failed to remove some branches in %s: %v", repoPath, err) - } + return true +} + +func downloadBundleFromMirrors(bundlePath, originalURL string, refs []string) error { + urlPath, err := download.URLToPath(originalURL) + if err != nil { + return fmt.Errorf("failed to convert URL to path: %w", err) + } + + bundleFilename := filepath.Base(bundlePath) + mirrorPath := path.Join(path.Dir(urlPath), bundleFilename) + + mirrors := download.GetMirrors() + tempFile := bundlePath + ".download.tmp" + defer os.Remove(tempFile) + + for _, mirror := range mirrors { + os.Remove(tempFile) + + mirrorURL := mirror + mirrorPath + log.Printf("Trying to download bundle from mirror: %s", mirrorURL) + + if err := download.DownloadURLWithRetries(mirrorURL, tempFile); err != nil { + log.Printf("Failed to download from mirror %s: %v", mirror, err) + continue + } + + if !verifyBundleHasRef(tempFile, refs) { + log.Printf("Mirror bundle does not contain all refs %v", refs) + os.Remove(tempFile) + continue } + + os.MkdirAll(filepath.Dir(bundlePath), 0755) + if err := os.Rename(tempFile, bundlePath); err != nil { + log.Printf("Failed to move bundle to final location: %v", err) + os.Remove(tempFile) + continue + } + + log.Printf("Successfully downloaded bundle from mirror %s", mirror) + return nil } - log.Printf("Repository optimization completed for %s", repoPath) + return fmt.Errorf("all mirrors failed") } -func resolveRef(repo *git.Repository, refStr string) (plumbing.Hash, error) { - if len(refStr) == 40 { - hash := plumbing.NewHash(refStr) - _, err := repo.CommitObject(hash) - if err == nil { - return hash, nil +func createBundleFromRepo(bundlePath, url string, refs []string) error { + log.Printf("Creating bundle from repository %s with %d refs", url, len(refs)) + + tempDir := bundlePath + ".clone.tmp" + defer RemoveAll(tempDir) + + log.Printf("Cloning repository from %s", url) + cloneCmd := gitCommand("clone", url, tempDir) + cloneCmd.Stdout = os.Stdout + cloneCmd.Stderr = os.Stderr + if err := cloneCmd.Run(); err != nil { + return fmt.Errorf("failed to clone repository: %w", err) + } + + log.Printf("Creating branches for refs: %v", refs) + os.MkdirAll(filepath.Dir(bundlePath), 0755) + + branchNames := []string{} + for i, ref := range refs { + branchName := fmt.Sprintf("bundle-ref-%d", i) + branchNames = append(branchNames, branchName) + + branchCmd := gitCommand("branch", branchName, ref) + branchCmd.Dir = tempDir + branchCmd.Stdout = os.Stdout + branchCmd.Stderr = os.Stderr + if err := branchCmd.Run(); err != nil { + log.Printf("Warning: failed to create branch %s for ref %s: %v", branchName, ref, err) + branchNames[len(branchNames)-1] = ref } } - tagRef, err := repo.Tag(refStr) - if err == nil { - return tagRef.Hash(), nil + bundleArgs := append([]string{"bundle", "create", bundlePath}, branchNames...) + bundleCmd := gitCommand(bundleArgs...) + bundleCmd.Dir = tempDir + bundleCmd.Stdout = os.Stdout + bundleCmd.Stderr = os.Stderr + if err := bundleCmd.Run(); err != nil { + return fmt.Errorf("failed to create bundle: %w", err) } - branchRef, err := repo.Reference(plumbing.ReferenceName("refs/heads/"+refStr), true) - if err == nil { - return branchRef.Hash(), nil + log.Printf("Successfully created bundle at %s with %d refs", bundlePath, len(refs)) + return nil +} + +func DownloadGit(packageName, bundlePath, url string) error { + log.Printf("Downloading %s to bundle %s", url, bundlePath) + return EnsureGitBundle(bundlePath, url) +} + +func EnsureGitBundle(bundlePath, url string) error { + sources, err := loadSourcesFile() + if err != nil { + return fmt.Errorf("failed to load sources.json: %w", err) } - remoteRef, err := repo.Reference(plumbing.ReferenceName("refs/remotes/origin/"+refStr), true) - if err == nil { - return remoteRef.Hash(), nil + repoInfo, exists := sources.Repositories[url] + if !exists { + return fmt.Errorf("repository %s not found in sources.json", url) } - ref, err := repo.Reference(plumbing.ReferenceName(refStr), true) - if err == nil { - return ref.Hash(), nil + if _, err := os.Stat(bundlePath); err == nil { + log.Printf("Bundle already exists, verifying it contains all refs %v", repoInfo.Refs) + if verifyBundleHasRef(bundlePath, repoInfo.Refs) { + log.Printf("Bundle is valid and contains all required refs") + return nil + } + log.Printf("Bundle does not contain all refs %v, removing and re-downloading", repoInfo.Refs) + os.Remove(bundlePath) } - return plumbing.ZeroHash, err + err = downloadBundleFromMirrors(bundlePath, url, repoInfo.Refs) + if err != nil { + log.Printf("Failed to download from mirrors: %v, creating bundle from original URL", err) + return createBundleFromRepo(bundlePath, url, repoInfo.Refs) + } + + return nil } -func DownloadGit(packageName, path, url, expectedSha256 string) error { - log.Printf("Downloading %s to %s", url, path) +type SourcesFile struct { + Repositories map[string]RepositoryInfo `json:"repositories"` + Downloads []DownloadEntry `json:"downloads,omitempty"` +} + +type RepositoryInfo struct { + Refs []string `json:"refs"` + Packages []string `json:"packages,omitempty"` +} + +type DownloadEntry struct { + Kind string `json:"kind"` + URL string `json:"url"` + Sha256 string `json:"sha256"` + Path string `json:"path,omitempty"` +} + +func LoadSourcesFile() (*SourcesFile, error) { + return loadSourcesFile() +} - repo, err := git.PlainClone(path, false, &git.CloneOptions{ - URL: url, - Progress: os.Stdout, - }) +func loadSourcesFile() (*SourcesFile, error) { + content, err := os.ReadFile("sources.json") if err != nil { - return err + return nil, err } - worktree, err := repo.Worktree() - if err != nil { - return err + var sources SourcesFile + if err := json.Unmarshal(content, &sources); err != nil { + return nil, err } - log.Printf("Checking out reference %s", expectedSha256) - targetHash, err := resolveRef(repo, expectedSha256) - if err != nil { - return err + return &sources, nil +} + +func ExtractGitCloneBundle(bundlePath, destPath, ref string) error { + log.Printf("Extracting git bundle from %s to %s", bundlePath, destPath) + + os.MkdirAll(destPath, 0755) + + steps := [][]string{ + {"init"}, + {"fetch", bundlePath, ref}, + {"checkout", "--force", ref}, } - err = worktree.Checkout(&git.CheckoutOptions{ - Hash: targetHash, - }) + for i, step := range steps { + cmd := gitCommand(step...) + cmd.Dir = destPath + cmd.Stdout = os.Stdout + cmd.Stderr = os.Stderr + if err := cmd.Run(); err != nil { + // If fetch failed, the bundle doesn't have this ref + // Try to get the repo URL from the bundle path and re-create it + if i == 1 { // fetch step failed + log.Printf("Bundle does not contain ref %s, attempting to re-create bundle with updated refs", ref) + RemoveAll(destPath) // Clean up failed extraction + + // Get the repository URL from sources.json by finding which repo this bundle belongs to + url, err := getRepoURLFromBundlePath(bundlePath) + if err != nil { + return fmt.Errorf("failed to find repository URL for bundle: %w", err) + } + + // Remove old bundle and re-create with all current refs + log.Printf("Removing old bundle: %s", bundlePath) + os.Remove(bundlePath) + + // Load sources and re-create bundle + sources, err := loadSourcesFile() + if err != nil { + return fmt.Errorf("failed to load sources.json: %w", err) + } + + repoInfo, exists := sources.Repositories[url] + if !exists { + return fmt.Errorf("repository %s not found in sources.json", url) + } + + log.Printf("Re-creating bundle with %d refs from sources.json", len(repoInfo.Refs)) + if err := createBundleFromRepo(bundlePath, url, repoInfo.Refs); err != nil { + return fmt.Errorf("failed to re-create bundle: %w", err) + } + + // Now retry the extraction + return ExtractGitCloneBundle(bundlePath, destPath, ref) + } + return fmt.Errorf("failed to run command: %w", err) + } + } + log.Printf("Successfully extracted bundle to %s", destPath) + return nil +} + +func getRepoURLFromBundlePath(bundlePath string) (string, error) { + sources, err := loadSourcesFile() if err != nil { - return err + return "", err } - log.Printf("Cleaning up and optimizing repository...") + // Extract the URL pattern from the bundle path + // Bundle path format: .buildlib/source/.bundle + bundleName := filepath.Base(bundlePath) + bundleName = strings.TrimSuffix(bundleName, ".bundle") - optimizeGitRepo(path) + // Try to match against known repositories + for url := range sources.Repositories { + urlPath, err := download.URLToPath(url) + if err != nil { + continue + } + urlPath = strings.TrimSuffix(urlPath, ".git") + if strings.HasSuffix(urlPath, bundleName) || strings.Contains(bundlePath, urlPath) { + return url, nil + } + } - log.Printf("Successfully downloaded and optimized %s", path) - return nil + return "", fmt.Errorf("could not find repository URL for bundle path: %s", bundlePath) } diff --git a/utils/historic_sources.go b/utils/historic_sources.go new file mode 100644 index 0000000..b96ce86 --- /dev/null +++ b/utils/historic_sources.go @@ -0,0 +1,68 @@ +package utils + +import ( + "fmt" + "log" + "os/exec" + "strings" +) + +func isGitRepo() bool { + cmd := exec.Command("git", "rev-parse", "--git-dir") + if err := cmd.Run(); err != nil { + return false + } + return true +} + +func gitOutput(args ...string) ([]byte, error) { + cmd := exec.Command("git", args...) + return cmd.Output() +} + +func CollectHistoricDownloads(s *SourcesFile) error { + if !isGitRepo() { + return fmt.Errorf("not inside a git repository") + } + + output, err := gitOutput("log", "--all", "--format=%H") + if err != nil { + return fmt.Errorf("git log failed: %w", err) + } + + commits := strings.Split(strings.TrimSpace(string(output)), "\n") + if len(commits) == 1 && commits[0] == "" { + return nil + } + + log.Printf("Scanning %d commits for historic download entries...", len(commits)) + + for i, commit := range commits { + if commit == "" { + continue + } + if (i+1)%10 == 0 || i == len(commits)-1 { + log.Printf(" Historic scan: commit %d/%d", i+1, len(commits)) + } + + treeOutput, err := gitOutput("ls-tree", "-r", "--name-only", commit) + if err != nil { + continue + } + + for _, filepath := range strings.Split(strings.TrimSpace(string(treeOutput)), "\n") { + if filepath == "" || !strings.HasSuffix(filepath, ".json") { + continue + } + + content, err := gitOutput("show", commit+":"+filepath) + if err != nil { + continue + } + + MergeDownloadsFromJSON(s, content) + } + } + + return nil +} diff --git a/utils/ifstring/ifstring.go b/utils/ifstring/ifstring.go new file mode 100644 index 0000000..b15cfe5 --- /dev/null +++ b/utils/ifstring/ifstring.go @@ -0,0 +1,49 @@ +package ifstring + +import ( + "log" + "strings" + + "github.com/gobwas/glob" +) + +type IfString struct { + Builder string + Host string + Content string +} + +func (is *IfString) BuilderGlob() glob.Glob { + return glob.MustCompile(is.Builder) +} +func (is *IfString) HostGlob() glob.Glob { + return glob.MustCompile(is.Host) +} + +func (is *IfString) Matches(hostTriplet, builderName string) bool { + return is.HostGlob().Match(hostTriplet) && is.BuilderGlob().Match(builderName) +} + +func FilterContent(items []string, hostTriplet, builderName string) []string { + filtered := make([]string, 0, len(items)) + for _, item := range items { + is := ParseIfString(item) + if !is.Matches(hostTriplet, builderName) { + continue + } + filtered = append(filtered, is.Content) + } + return filtered +} + +func ParseIfString(str string) *IfString { + is := &IfString{} + is.Builder = strings.Split(str, ":")[0] + is.Host = strings.Split(str, ":")[1] + offset := len(is.Builder) + len(is.Host) + 2 + if len(str) < offset { + log.Fatalln("failed to parse:", str) + } + is.Content = str[offset:] + return is +} diff --git a/utils/jsonutil.go b/utils/jsonutil.go new file mode 100644 index 0000000..8f136f8 --- /dev/null +++ b/utils/jsonutil.go @@ -0,0 +1,13 @@ +package utils + +import ( + "encoding/json" + "io" +) + +func NewIndentedEncoder(w io.Writer) *json.Encoder { + encoder := json.NewEncoder(w) + encoder.SetEscapeHTML(false) + encoder.SetIndent("", " ") + return encoder +} diff --git a/utils/path.go b/utils/path.go index c6d2a1f..7500f86 100644 --- a/utils/path.go +++ b/utils/path.go @@ -2,17 +2,247 @@ package utils import ( "log" + "os" + "os/exec" + "path/filepath" "runtime" + "strings" ) +// WindowsCygwinSeedRel is the repo-relative seed tree used before +// $NATIVEPREFIX/_ exists (PATCH_DIR / easybs-shaped Cygwin+clang). +const WindowsCygwinSeedRel = "patches/native/_/windows_amd64_cygwin_clang" + +func WindowsCygwinSeedBin() string { + wd, err := os.Getwd() + if err != nil { + return filepath.Join(WindowsCygwinSeedRel, "bin") + } + return filepath.Join(wd, WindowsCygwinSeedRel, "bin") +} + +func windowsGitBins() []string { + var out []string + roots := []string{ + os.Getenv("ProgramFiles"), + `C:\Program Files`, + } + if pf86 := os.Getenv("ProgramFiles(x86)"); pf86 != "" { + roots = append(roots, pf86) + } + for _, root := range roots { + if root == "" { + continue + } + out = append(out, + filepath.Join(root, "Git", "cmd"), + filepath.Join(root, "Git", "bin"), + filepath.Join(root, "Git", "mingw64", "bin"), + filepath.Join(root, "Git", "usr", "bin"), + ) + } + return out +} + +// ResolveGit returns an absolute path to git for host-side downloads. +// On Windows this finds Git-for-Windows without putting its MSYS usr/bin on +// the build-step PATH (which breaks autoconf/egrep). +func ResolveGit() string { + if p, err := exec.LookPath("git"); err == nil { + return p + } + if runtime.GOOS != "windows" { + return "git" + } + for _, dir := range windowsGitBins() { + cand := filepath.Join(dir, "git.exe") + if st, err := os.Stat(cand); err == nil && !st.IsDir() { + return cand + } + } + return "git" +} + +func guessNativePrefix() string { + if v := os.Getenv("SIMPLYBS_NATIVE_ENV_DIR"); v != "" { + return v + } + wd, err := os.Getwd() + if err != nil { + return filepath.Join(".buildlib", "env-native") + } + if v := os.Getenv("SIMPLYBS_DATA_DIR"); v != "" { + return filepath.Join(v, "env-native") + } + return filepath.Join(wd, ".buildlib", "env-native") +} + func GetHostPath() string { switch runtime.GOOS { case "darwin": - return "/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin" + return "" case "linux": - return "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin" + return "" + case "windows": + // Prefer the Cygwin seed only. Git-for-Windows on PATH makes + // autoconf pick MSYS grep/sed (paths with spaces) and break egrep. + return ToShellPath(WindowsCygwinSeedBin()) default: log.Fatalln("Unsupported OS: ", runtime.GOOS) return "" } } + +// ToShellPath converts a native path into the form used inside build-step +// shells. On Windows this project always uses Cygwin (/cygdrive/...), even +// when ResolveShell temporarily falls back to Git Bash after env-native is +// wiped between EnsureBuilt and ExtractEnv. Hashing PREFIX/NATIVEPREFIX via +// Git's /c/... form would look for a different archive than the one built +// under Cygwin. +func ToShellPath(p string) string { + if runtime.GOOS != "windows" { + return p + } + if p == "" { + return p + } + abs := p + if !filepath.IsAbs(abs) { + if a, err := filepath.Abs(abs); err == nil { + abs = a + } + } + vol := filepath.VolumeName(abs) + if len(vol) >= 2 && vol[1] == ':' { + letter := strings.ToLower(string(vol[0])) + rest := filepath.ToSlash(abs[len(vol):]) + if rest == "" { + rest = "/" + } + return "/cygdrive/" + letter + rest + } + return filepath.ToSlash(abs) +} + +// DestDirJoin mirrors Unix string concat of $STAGING_DIR$PREFIX for archives +// and Go file ops so the staged tree matches what the shell wrote. +func DestDirJoin(staging, prefix string) string { + if runtime.GOOS != "windows" { + rel := strings.TrimPrefix(filepath.ToSlash(prefix), "/") + return filepath.Join(staging, filepath.FromSlash(rel)) + } + shellPrefix := ToShellPath(prefix) + rel := strings.TrimPrefix(shellPrefix, "/") + return filepath.Join(staging, filepath.FromSlash(rel)) +} + +// ResolveShell returns the shell used for build steps. +// Prefer $NATIVEPREFIX/_/bin/sh (Cygwin seed) when present; otherwise Git. +// Do not use $NATIVEPREFIX/bin/sh — that would bypass PATH order and can pick +// the wrong shell relative to the bash we build into bin/. +func ResolveShell(nativePrefix string) string { + return ResolveShellForBuild(nativePrefix, "") +} + +// ResolveShellForBuild is ResolveShell, but when buildPath contains bin/sh +// (e.g. the extracted windows cygwin seed tarball), prefer that over Git. +// Cold bootstrap has no $NATIVEPREFIX/_ yet; Git Bash would mangle /cygdrive paths. +func ResolveShellForBuild(nativePrefix, buildPath string) string { + if runtime.GOOS != "windows" { + return "sh" + } + if nativePrefix == "" { + nativePrefix = guessNativePrefix() + } + candidates := []string{ + filepath.Join(nativePrefix, "_", "bin", "sh.exe"), + filepath.Join(nativePrefix, "_", "bin", "sh"), + } + if buildPath != "" { + candidates = append(candidates, + filepath.Join(buildPath, "bin", "sh.exe"), + filepath.Join(buildPath, "bin", "sh"), + ) + } + candidates = append(candidates, + filepath.Join(WindowsCygwinSeedBin(), "sh.exe"), + filepath.Join(WindowsCygwinSeedBin(), "sh"), + ) + for _, b := range windowsGitBins() { + candidates = append(candidates, filepath.Join(b, "sh.exe")) + } + for _, c := range candidates { + if st, err := os.Stat(c); err == nil && !st.IsDir() { + return c + } + } + if p, err := exec.LookPath("sh.exe"); err == nil { + return p + } + if p, err := exec.LookPath("sh"); err == nil { + return p + } + return "sh" +} + +// ProcessEnv builds an explicit process environment from overrides only. +// On Windows, SYSTEMROOT is copied from the host so Win32 APIs keep working; +// nothing else is inherited from the parent process. +func ProcessEnv(overrides map[string]string) []string { + out := make([]string, 0, len(overrides)+1) + if runtime.GOOS == "windows" { + if !hasEnvKey(overrides, "SYSTEMROOT") { + if v := os.Getenv("SYSTEMROOT"); v != "" { + out = append(out, "SYSTEMROOT="+v) + } + } + } + for k, v := range overrides { + out = append(out, k+"="+v) + } + return out +} + +func hasEnvKey(env map[string]string, key string) bool { + if _, ok := env[key]; ok { + return true + } + if runtime.GOOS != "windows" { + return false + } + want := strings.ToUpper(key) + for k := range env { + if strings.ToUpper(k) == want { + return true + } + } + return false +} + +// BuildStepPATH prefers the simplybs native toolchain, then bootstrap host +// bins (seed / Git), then prefix bins. Always colon-separated for POSIX sh. +// $NATIVEPREFIX/bin (bash, etc.) must precede $NATIVEPREFIX/_/bin (clang seed +// toybox sh) so Configure scripts pick up bash for SHELL. +func BuildStepPATH(nativePrefix, prefix, envPath, hostPath string) string { + parts := []string{ + ToShellPath(filepath.Join(nativePrefix, "bin")), + ToShellPath(filepath.Join(nativePrefix, "_", "bin")), + } + if envPath != "" { + parts = append(parts, envPath) + } + if hostPath != "" { + parts = append(parts, hostPath) + } + if prefix != "" { + parts = append(parts, ToShellPath(filepath.Join(prefix, "bin"))) + } + out := parts[0] + for _, p := range parts[1:] { + if p == "" { + continue + } + out += ":" + p + } + return out +} diff --git a/utils/path_test.go b/utils/path_test.go new file mode 100644 index 0000000..9244cce --- /dev/null +++ b/utils/path_test.go @@ -0,0 +1,32 @@ +package utils + +import ( + "path/filepath" + "runtime" + "strings" + "testing" +) + +func TestToShellPathWindows(t *testing.T) { + if runtime.GOOS != "windows" { + t.Skip("windows only") + } + got := ToShellPath(`C:\Users\user\work\simplybs\.buildlib\env-native`) + want := `/cygdrive/c/Users/user/work/simplybs/.buildlib/env-native` + if got != want { + t.Fatalf("ToShellPath: got %q, want %q", got, want) + } +} + +func TestDestDirJoinWindows(t *testing.T) { + if runtime.GOOS != "windows" { + t.Skip("windows only") + } + staging := `C:\Users\user\work\simplybs\.buildlib\windows_amd64\staging\pkg` + prefix := `C:\Users\user\work\simplybs\.buildlib\env-native` + got := DestDirJoin(staging, prefix) + shellAsWin := filepath.Join(staging, filepath.FromSlash(strings.TrimPrefix(ToShellPath(prefix), "/"))) + if got != shellAsWin { + t.Fatalf("DestDirJoin vs shell concat:\n join %q\n mapped %q\n shellPrefix %q", got, shellAsWin, ToShellPath(prefix)) + } +} diff --git a/utils/remove_all.go b/utils/remove_all.go new file mode 100644 index 0000000..a792815 --- /dev/null +++ b/utils/remove_all.go @@ -0,0 +1,32 @@ +package utils + +import ( + "log" + "os" + "path/filepath" +) + +func RemoveAll(path string) error { + if _, err := os.Stat(path); os.IsNotExist(err) { + return nil + } + + filepath.WalkDir(path, func(p string, d os.DirEntry, err error) error { + if err != nil { + return nil + } + os.Chmod(p, 0755) + return nil + }) + + if err := os.RemoveAll(path); err != nil { + log.Fatalf("removeAll %s: %v", path, err) + } + + if _, err := os.Stat(path); err == nil { + log.Fatalf("removeAll %s: still exists after removal", path) + } else if !os.IsNotExist(err) { + log.Fatalf("removeAll %s: %v", path, err) + } + return nil +} diff --git a/utils/run_live.go b/utils/run_live.go new file mode 100644 index 0000000..c4d60c4 --- /dev/null +++ b/utils/run_live.go @@ -0,0 +1,29 @@ +package utils + +import ( + "os" + "os/exec" + + "golang.org/x/term" +) + +// RunLive runs cmd with stdout/stderr streamed as they are produced. +// +// When our own stdout is not a terminal (piped, PowerShell 2>&1, CI capture), +// libc fully-buffers the child's stdout, so tools like configure look silent +// until a large flush. Merging both streams onto stderr avoids that in hosts +// that flush the error stream more eagerly (notably PowerShell). +// +// We intentionally do not allocate a PTY here: if the sink stops reading, +// a PTY writer can fill its buffer and deadlock the whole build step. +func RunLive(cmd *exec.Cmd) error { + if term.IsTerminal(int(os.Stdout.Fd())) { + cmd.Stdout = os.Stdout + cmd.Stderr = os.Stderr + return cmd.Run() + } + + cmd.Stdout = os.Stderr + cmd.Stderr = os.Stderr + return cmd.Run() +} diff --git a/utils/sourcepath.go b/utils/sourcepath.go new file mode 100644 index 0000000..08cb065 --- /dev/null +++ b/utils/sourcepath.go @@ -0,0 +1,26 @@ +package utils + +import ( + "path/filepath" + "strings" + + "github.com/mrcyjanek/simplybs/host" + "github.com/mrcyjanek/simplybs/utils/download" +) + +func SourcePathForGitURL(url string) string { + urlPath, err := download.URLToPath(url) + if err != nil { + return filepath.Join(host.DataDirRoot(), "source", filepath.Base(url)+".bundle") + } + urlPath = strings.TrimSuffix(urlPath, ".git") + return filepath.Join(host.DataDirRoot(), "source", urlPath+".bundle") +} + +func SourcePathForFileURL(url string) string { + urlPath, err := download.URLToPath(url) + if err != nil { + return filepath.Join(host.DataDirRoot(), "source", filepath.Base(url)) + } + return filepath.Join(host.DataDirRoot(), "source", urlPath) +} diff --git a/utils/sourcepath_test.go b/utils/sourcepath_test.go new file mode 100644 index 0000000..c101e9f --- /dev/null +++ b/utils/sourcepath_test.go @@ -0,0 +1,26 @@ +package utils + +import ( + "path/filepath" + "testing" +) + +func TestSourcePathForGitURL(t *testing.T) { + t.Setenv("SIMPLYBS_DATA_DIR", "/tmp/simplybs-test") + + path := SourcePathForGitURL("https://github.com/example/foo.git") + expected := filepath.Join("/tmp/simplybs-test", "source", "github.com", "example", "foo.bundle") + if path != expected { + t.Fatalf("expected %q, got %q", expected, path) + } +} + +func TestSourcePathForFileURL(t *testing.T) { + t.Setenv("SIMPLYBS_DATA_DIR", "/tmp/simplybs-test") + + path := SourcePathForFileURL("https://example.com/releases/foo.tar.gz") + expected := filepath.Join("/tmp/simplybs-test", "source", "example.com", "releases", "foo.tar.gz") + if path != expected { + t.Fatalf("expected %q, got %q", expected, path) + } +} diff --git a/utils/sources.go b/utils/sources.go new file mode 100644 index 0000000..7210034 --- /dev/null +++ b/utils/sources.go @@ -0,0 +1,275 @@ +package utils + +import ( + "bytes" + _ "embed" + "encoding/json" + "sort" + "strings" +) + +//go:embed sources_ignored_refs.txt +var sourcesIgnoredRefsFile string + +var sourcesIgnoredRefs map[string]struct{} + +func init() { + sourcesIgnoredRefs = make(map[string]struct{}) + for _, line := range strings.Split(sourcesIgnoredRefsFile, "\n") { + line = strings.TrimSpace(line) + if line == "" || strings.HasPrefix(line, "#") { + continue + } + sourcesIgnoredRefs[line] = struct{}{} + } +} + +func IsIgnoredGitRef(ref string) bool { + _, ignored := sourcesIgnoredRefs[ref] + return ignored +} + +func FilterIgnoredGitRefs(s *SourcesFile) { + for url, repoInfo := range s.Repositories { + filtered := make([]string, 0, len(repoInfo.Refs)) + for _, ref := range repoInfo.Refs { + if !IsIgnoredGitRef(ref) { + filtered = append(filtered, ref) + } + } + if len(filtered) == 0 { + delete(s.Repositories, url) + continue + } + repoInfo.Refs = filtered + s.Repositories[url] = repoInfo + } +} + +func NewSourcesFile() *SourcesFile { + return &SourcesFile{ + Repositories: make(map[string]RepositoryInfo), + } +} + +func AddGitRef(s *SourcesFile, url, ref string) bool { + if url == "" || ref == "" || IsIgnoredGitRef(ref) { + return false + } + repoInfo, exists := s.Repositories[url] + if exists { + for _, existing := range repoInfo.Refs { + if existing == ref { + return false + } + } + repoInfo.Refs = append(repoInfo.Refs, ref) + s.Repositories[url] = repoInfo + return true + } + s.Repositories[url] = RepositoryInfo{ + Refs: []string{ref}, + } + return true +} + +func downloadEntryKey(entry DownloadEntry) string { + data, err := json.Marshal(entry) + if err != nil { + return entry.Kind + "\x00" + entry.URL + "\x00" + entry.Sha256 + "\x00" + entry.Path + } + return string(data) +} + +func AddDownload(s *SourcesFile, entry DownloadEntry) bool { + if entry.Kind == "" || entry.URL == "" || entry.Sha256 == "" { + return false + } + key := downloadEntryKey(entry) + for _, existing := range s.Downloads { + if downloadEntryKey(existing) == key { + return false + } + } + s.Downloads = append(s.Downloads, entry) + return true +} + +func downloadMapFields(download map[string]interface{}) (kind, url, sha256 string, ok bool) { + kind, _ = download["kind"].(string) + if kind == "" || kind == "none" { + return "", "", "", false + } + url, _ = download["url"].(string) + sha256, _ = download["sha256"].(string) + return kind, url, sha256, true +} + +func MergeDownloadMap(s *SourcesFile, download map[string]interface{}) { + kind, url, sha256, ok := downloadMapFields(download) + if !ok { + return + } + + if kind == "git" { + AddGitRef(s, url, sha256) + return + } + + if url == "" || sha256 == "" { + return + } + + entry := DownloadEntry{ + Kind: kind, + URL: url, + Sha256: sha256, + } + if path, ok := download["path"].(string); ok && path != "" { + entry.Path = path + } + AddDownload(s, entry) +} + +func MergeDownloadsFromJSON(s *SourcesFile, content []byte) { + var data map[string]interface{} + if err := json.Unmarshal(content, &data); err != nil { + return + } + + downloads, ok := data["download"].([]interface{}) + if !ok { + return + } + + for _, downloadInterface := range downloads { + download, ok := downloadInterface.(map[string]interface{}) + if !ok { + continue + } + MergeDownloadMap(s, download) + } +} + +func SortSourcesFile(s *SourcesFile) { + for url, repoInfo := range s.Repositories { + sort.Strings(repoInfo.Refs) + s.Repositories[url] = repoInfo + } + + sort.Slice(s.Downloads, func(i, j int) bool { + a, b := s.Downloads[i], s.Downloads[j] + if a.Kind != b.Kind { + return a.Kind < b.Kind + } + if a.URL != b.URL { + return a.URL < b.URL + } + if a.Sha256 != b.Sha256 { + return a.Sha256 < b.Sha256 + } + return a.Path < b.Path + }) +} + +func MarshalSourcesFile(s *SourcesFile) ([]byte, error) { + FilterIgnoredGitRefs(s) + SortSourcesFile(s) + + var buf bytes.Buffer + if err := NewIndentedEncoder(&buf).Encode(s); err != nil { + return nil, err + } + return bytes.TrimSuffix(buf.Bytes(), []byte("\n")), nil +} + +func CountGitRefs(s *SourcesFile) int { + total := 0 + for _, repoInfo := range s.Repositories { + total += len(repoInfo.Refs) + } + return total +} + +func SourcesFileFromRepositoriesOnlyJSON(content []byte) (*SourcesFile, error) { + var sources SourcesFile + if err := json.Unmarshal(content, &sources); err != nil { + return nil, err + } + if sources.Repositories == nil { + sources.Repositories = make(map[string]RepositoryInfo) + } + return &sources, nil +} + +func AllGitRefPairs(s *SourcesFile) [][2]string { + pairs := make([][2]string, 0) + for url, repoInfo := range s.Repositories { + for _, ref := range repoInfo.Refs { + pairs = append(pairs, [2]string{url, ref}) + } + } + sort.Slice(pairs, func(i, j int) bool { + if pairs[i][0] != pairs[j][0] { + return pairs[i][0] < pairs[j][0] + } + return pairs[i][1] < pairs[j][1] + }) + return pairs +} + +func ContainsGitRef(s *SourcesFile, url, ref string) bool { + repoInfo, exists := s.Repositories[url] + if !exists { + return false + } + for _, existing := range repoInfo.Refs { + if existing == ref { + return true + } + } + return false +} + +func UniqueDownloads(entries []DownloadEntry) []DownloadEntry { + seen := make(map[string]bool) + unique := make([]DownloadEntry, 0, len(entries)) + + for _, entry := range entries { + key := entry.URL + "\x00" + entry.Sha256 + if seen[key] { + continue + } + seen[key] = true + unique = append(unique, entry) + } + + sort.Slice(unique, func(i, j int) bool { + a, b := unique[i], unique[j] + if a.URL != b.URL { + return a.URL < b.URL + } + return a.Sha256 < b.Sha256 + }) + + return unique +} + +func DownloadEntryFromMap(download map[string]interface{}) (DownloadEntry, bool) { + kind, url, sha256, ok := downloadMapFields(download) + if !ok || kind == "git" { + return DownloadEntry{}, false + } + if url == "" || sha256 == "" { + return DownloadEntry{}, false + } + entry := DownloadEntry{ + Kind: kind, + URL: url, + Sha256: sha256, + } + if path, ok := download["path"].(string); ok && strings.TrimSpace(path) != "" { + entry.Path = path + } + return entry, true +} diff --git a/utils/sources_ignored_refs.txt b/utils/sources_ignored_refs.txt new file mode 100644 index 0000000..7d660b9 --- /dev/null +++ b/utils/sources_ignored_refs.txt @@ -0,0 +1,3 @@ +# Git refs that are invalid or unavailable upstream; excluded from sources.json. +504e4711cee972ff751ab20ac8c259bbcaa22bb3 +c2b3d1e9ed841474b04671f06b0f005d03dede82 diff --git a/utils/sources_test.go b/utils/sources_test.go new file mode 100644 index 0000000..47859c0 --- /dev/null +++ b/utils/sources_test.go @@ -0,0 +1,224 @@ +package utils + +import ( + "encoding/json" + "os" + "path/filepath" + "reflect" + "strings" + "testing" +) + +func TestLoadSourcesFileBackwardCompat(t *testing.T) { + fixture := `{ + "repositories": { + "https://example.com/foo.git": { + "refs": ["abc123"] + } + } +}` + + sources, err := SourcesFileFromRepositoriesOnlyJSON([]byte(fixture)) + if err != nil { + t.Fatalf("unmarshal fixture: %v", err) + } + if len(sources.Repositories) != 1 { + t.Fatalf("expected 1 repository, got %d", len(sources.Repositories)) + } + if len(sources.Downloads) != 0 { + t.Fatalf("expected no downloads, got %d", len(sources.Downloads)) + } + + repoRoot := filepath.Join("..", "sources.json") + if _, err := os.Stat(repoRoot); err == nil { + content, err := os.ReadFile(repoRoot) + if err != nil { + t.Fatalf("read sources.json: %v", err) + } + loaded, err := SourcesFileFromRepositoriesOnlyJSON(content) + if err != nil { + t.Fatalf("unmarshal sources.json: %v", err) + } + if len(loaded.Repositories) == 0 { + t.Fatal("expected repositories in sources.json") + } + } +} + +func TestIgnoredGitRefs(t *testing.T) { + s := NewSourcesFile() + + if AddGitRef(s, "https://example.com/foo.git", "504e4711cee972ff751ab20ac8c259bbcaa22bb3") { + t.Fatal("expected ignored ref to be skipped") + } + if _, exists := s.Repositories["https://example.com/foo.git"]; exists { + t.Fatal("expected ignored ref not to create repository entry") + } + + s.Repositories["https://example.com/foo.git"] = RepositoryInfo{ + Refs: []string{ + "abc123", + "504e4711cee972ff751ab20ac8c259bbcaa22bb3", + "c2b3d1e9ed841474b04671f06b0f005d03dede82", + }, + } + encoded, err := MarshalSourcesFile(s) + if err != nil { + t.Fatalf("marshal: %v", err) + } + if strings.Contains(string(encoded), "504e4711cee972ff751ab20ac8c259bbcaa22bb3") { + t.Fatal("expected ignored ref to be filtered from marshaled output") + } + if strings.Contains(string(encoded), "c2b3d1e9ed841474b04671f06b0f005d03dede82") { + t.Fatal("expected ignored ref to be filtered from marshaled output") + } + if !strings.Contains(string(encoded), "abc123") { + t.Fatal("expected non-ignored ref to remain in marshaled output") + } +} + +func TestMergeGitRefDedup(t *testing.T) { + s := NewSourcesFile() + + if !AddGitRef(s, "https://example.com/foo.git", "abc123") { + t.Fatal("expected first ref to be added") + } + if AddGitRef(s, "https://example.com/foo.git", "abc123") { + t.Fatal("expected duplicate ref to be ignored") + } + if len(s.Repositories["https://example.com/foo.git"].Refs) != 1 { + t.Fatalf("expected 1 ref, got %d", len(s.Repositories["https://example.com/foo.git"].Refs)) + } +} + +func TestMergeDownloadDedup(t *testing.T) { + s := NewSourcesFile() + + entry := DownloadEntry{ + Kind: "tar.gz", + URL: "https://example.com/foo.tar.gz", + Sha256: "deadbeef", + } + if !AddDownload(s, entry) { + t.Fatal("expected first download to be added") + } + if AddDownload(s, entry) { + t.Fatal("expected duplicate download to be ignored") + } + + other := DownloadEntry{ + Kind: "tar.gz", + URL: "https://example.com/foo.tar.gz", + Sha256: "cafebabe", + } + if !AddDownload(s, other) { + t.Fatal("expected differing sha256 to be added") + } + if len(s.Downloads) != 2 { + t.Fatalf("expected 2 downloads, got %d", len(s.Downloads)) + } +} + +func TestSourcesFileRoundTrip(t *testing.T) { + original := &SourcesFile{ + Repositories: map[string]RepositoryInfo{ + "https://example.com/foo.git": { + Refs: []string{"abc123", "def456"}, + }, + }, + Downloads: []DownloadEntry{ + { + Kind: "tar.gz", + URL: "https://example.com/foo.tar.gz", + Sha256: "deadbeef", + }, + }, + } + + encoded, err := MarshalSourcesFile(original) + if err != nil { + t.Fatalf("marshal: %v", err) + } + + var decoded SourcesFile + if err := json.Unmarshal(encoded, &decoded); err != nil { + t.Fatalf("unmarshal: %v", err) + } + + if !reflect.DeepEqual(original.Repositories, decoded.Repositories) { + t.Fatalf("repositories mismatch:\noriginal: %#v\ndecoded: %#v", original.Repositories, decoded.Repositories) + } + if !reflect.DeepEqual(original.Downloads, decoded.Downloads) { + t.Fatalf("downloads mismatch:\noriginal: %#v\ndecoded: %#v", original.Downloads, decoded.Downloads) + } +} + +func TestUniqueDownloads(t *testing.T) { + entries := []DownloadEntry{ + {Kind: "blob", URL: "https://example.com/a.tar.xz", Sha256: "aaa", Path: ".build/a.tar.xz"}, + {Kind: "blob", URL: "https://example.com/a.tar.xz", Sha256: "aaa", Path: "work/a.tar.xz"}, + {Kind: "tar.gz", URL: "https://example.com/b.tar.gz", Sha256: "bbb"}, + } + + unique := UniqueDownloads(entries) + if len(unique) != 2 { + t.Fatalf("expected 2 unique downloads, got %d", len(unique)) + } + if unique[0].URL != "https://example.com/a.tar.xz" || unique[1].URL != "https://example.com/b.tar.gz" { + t.Fatalf("unexpected sort order: %#v", unique) + } +} + +func TestPackageGitRefsCollected(t *testing.T) { + merged := NewSourcesFile() + packagesDir := filepath.Join("..", "packages") + err := filepath.WalkDir(packagesDir, func(path string, d os.DirEntry, err error) error { + if err != nil { + return err + } + if d.IsDir() || !strings.HasSuffix(path, ".json") { + return nil + } + + pkgContent, err := os.ReadFile(path) + if err != nil { + return err + } + + var data map[string]interface{} + if err := json.Unmarshal(pkgContent, &data); err != nil { + return err + } + + downloads, ok := data["download"].([]interface{}) + if !ok { + return nil + } + + for _, downloadInterface := range downloads { + download, ok := downloadInterface.(map[string]interface{}) + if !ok { + continue + } + kind, _ := download["kind"].(string) + if kind != "git" { + continue + } + url, _ := download["url"].(string) + ref, _ := download["sha256"].(string) + if url == "" || ref == "" { + continue + } + + MergeDownloadMap(merged, download) + if !ContainsGitRef(merged, url, ref) { + t.Fatalf("missing ref %s for %s after merging %s", ref, url, path) + } + } + + return nil + }) + if err != nil { + t.Fatalf("walk packages dir: %v", err) + } +}