c9bed308e293665fc68a2aa522bb5887aa2a60e3
- Improved error handling and context messages in `checkout` function in `git.rs`. - Updated license field in package specification to use a vector in `hooks.rs`. - Enhanced `copy_manual_sources` function in `mod.rs` to support both local file and remote URL sources, including checksum verification. - Added new utility functions for path normalization and skipping installation of specific files in `staging/mod.rs`. - Implemented logic to handle existing files during installation, allowing for `.depotnew` suffix for kept files. - Added tests for manual source copying, installation behavior, and path validation. - Introduced a new LICENSE file with MIT License terms.
depot
Depot is a source-based package manager for Linux, designed for Linux. It focuses on reproducibility, atomic installations, and ease of cross-compilation.
Features
- Source-based: Downloads, extracts, and builds packages from source.
- Dependency Management: Automatically handles build-time and runtime dependencies.
- Atomic Installation: Uses a transactional approach to ensure system consistency.
- Multi-system Build Support: Built-in support for Autotools, CMake, Meson, Rust (Cargo), and custom build scripts.
- Cross-Compilation: Easily build packages for different architectures using cross-toolchains.
- Repository Management: Create and manage local package repositories.
Quick Start
Building Depot
cargo build --release
Installing a Package
To install a package from a spec file:
depot install packages/zlib.toml
To install from a pre-built package archive:
depot install zlib-1.2.11-1-x86_64.depot.pkg.tar.zst
Command Reference
install <SPEC_OR_ARCHIVE>: Build and install a package.remove <PACKAGE>: Remove an installed package.build <SPEC>: Build a package and create an archive without installing.info <PACKAGE_OR_SPEC>: Show information about a package.list: List all installed packages.repo create [DIR]: Create a repository database from a directory of packages.config: Show current configuration and overrides.
Package Specification
Packages are defined using TOML files. Here is a basic example:
[package]
name = "example"
version = "1.0.0"
description = "An example package"
homepage = "https://example.com"
license = "MIT"
[[source]]
url = "https://example.com/example-$version.tar.gz"
sha256 = "..."
extract_dir = "example-$version"
[build]
type = "autotools"
flags = { configure = ["--enable-feature"] }
[dependencies]
build = ["gcc", "make"]
runtime = ["libc"]
Configuration
Depot can be configured via /etc/depot.d/ (or relative to the rootfs).
/etc/depot.d/build.toml: System-wide build overrides and flag appends./etc/depot.d/package.toml: Package-specific overrides.
Languages
Rust
99.4%
Meson
0.4%
Shell
0.2%