This document describes how to build spry packages for various operating systems using DALEC.
- Docker (version 20.10 or later)
- Docker Buildx (usually included with Docker Desktop)
- Make (optional, for convenience commands)
# Check Docker version
docker --version
# Check Buildx is available
docker buildx version
# Ensure BuildKit is enabled
export DOCKER_BUILDKIT=1make build-allThis will build spry packages for:
- Ubuntu 22.04 (Jammy) - DEB
- Debian 12 (Bookworm) - DEB
- Windows - ZIP (cross-compiled)
# Ubuntu Jammy
make build-jammy
# Debian Bookworm
make build-bookworm
# Windows
make build-windowsIf you prefer not to use Make, you can run Docker commands directly:
# Ubuntu Jammy
docker buildx build \
--target jammy \
--output type=local,dest=./output/jammy \
-f dalec-spry.yaml \
.
# Debian Bookworm
docker buildx build \
--target bookworm \
--output type=local,dest=./output/bookworm \
-f dalec-spry.yaml \
.docker buildx build \
--target windowscross \
--output type=local,dest=./output/windows \
-f dalec-spry.yaml \
.You can also use Docker Compose to build packages:
# Build for specific platform
docker-compose run build-jammy
docker-compose run build-bookworm
docker-compose run build-windowsFor development and testing, you can compile directly with Deno:
# Install Deno (if not already installed)
curl -fsSL https://deno.land/install.sh | sh
# Compile spry
make compile-local
# Or manually:
deno compile \
--allow-all \
--import-map=import_map.json \
--output=spry \
spry.tsBuilt packages will be in the output/ directory:
output/
├── jammy/
│ └── spry_0.1.0-1_amd64.deb
├── bookworm/
│ └── spry_0.1.0-1_amd64.deb
└── windows/
└── spry-windows.zip
If you see errors about BuildKit, ensure it's enabled:
export DOCKER_BUILDKIT=1Or add to your Docker daemon configuration (/etc/docker/daemon.json):
{
"features": {
"buildkit": true
}
}If you encounter permission issues with Docker:
# Add your user to the docker group
sudo usermod -aG docker $USER
# Log out and back in for changes to take effectTo start fresh:
make cleanThe GitHub Actions workflow (.github/workflows/build.yml) automatically builds packages for all platforms on:
- Push to main branch
- New tags (v*)
- Pull requests