mirror of
https://github.com/dexoron/dcr.git
synced 2026-10-21 13:58:34 +00:00
Compare commits
20 Commits
47d88d13ff
...
19aee3e079
| Author | SHA1 | Date | |
|---|---|---|---|
| 19aee3e079 | |||
| 4b061dae37 | |||
| e294cc47e6 | |||
| 81ae976c15 | |||
| 587d6aeb80 | |||
| 0e7825ab77 | |||
| b9a53bbed1 | |||
| 12950b0c46 | |||
| 5ba6d07847 | |||
| cd33597a8a | |||
| 81ac949d6d | |||
| 9487b10e2d | |||
| 9cf6223fcf | |||
| ceddc3bb5c | |||
| 82de6e8c60 | |||
| 6badcb7465 | |||
| 60a14c7a4c | |||
| 72e7a4c7ad | |||
| a0216a8fb0 | |||
| 9c9a66d0fe |
@@ -8,8 +8,10 @@ sidebar_label: Introduction
|
|||||||
<summary>Quick reference</summary>
|
<summary>Quick reference</summary>
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Installation
|
# Installation (dcrup)
|
||||||
curl -fsSL https://dcr.dexoron.su/install.sh | sh
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- self-install
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
|
dcrup install stable
|
||||||
|
|
||||||
# Create a project
|
# Create a project
|
||||||
dcr new my-app
|
dcr new my-app
|
||||||
|
|||||||
@@ -4,6 +4,25 @@ sidebar_label: Changelog
|
|||||||
|
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 0.8.2 (2026-07-22)
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
* **Compile progress `[N/M]`** — live TTY status line (`compile pkg v0.1.0 [12/41]`) so long mono-package builds do not look hung.
|
||||||
|
* **DCR status style** — fixed-width verbs: `project`, `compile`, `dep`, `ready`, `pack`, `done`, `run`.
|
||||||
|
* **Cargo feature `archive`** — optional FAT packing via `fatfs` (`cargo build --features archive`). Release CI builds with the feature; without it `[archive]` fails with a clear message.
|
||||||
|
* **Tests** — `flat_bin_nasm_build`, package `build.target` without CLI `--target`, stricter workspace `clean --all`.
|
||||||
|
* **CI expansion** — unit + integration on Linux/macOS/Windows, archive feature job, rust-cache, clippy default + all-features (see `.github/workflows/ci.yml`).
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
* **No forced host triple from CLI** — without `--target`, package/member `build.target` is honored (bare-metal / ISO `post_steps` paths).
|
||||||
|
* **Relative include/lib flags** (`-I`, `-i`, `-isystem`, `-idirafter`, `-L`, `-T`) absolutized against the package root under workspace builds.
|
||||||
|
* **`dcr clean --all`** — no spam for members without a local `target/` (shared root `target/`).
|
||||||
|
* **`error` / `warn`** — red / yellow on stderr; CLI fully English (`Hint:`).
|
||||||
|
* **Help / man** — list `add`, `lint`, `setup`; unknown command exits with code 1.
|
||||||
|
* **Tool NotFound** — `linker not found: ld.lld …` / `{tool} not found …` instead of raw `os error 2`.
|
||||||
|
|
||||||
## 0.8.1 (2026-07-20)
|
## 0.8.1 (2026-07-20)
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
@@ -14,7 +33,7 @@ sidebar_label: Changelog
|
|||||||
* **GAS / MASM / LLC** — object → `objcopy -O binary` → `\<stem>.bin`
|
* **GAS / MASM / LLC** — object → `objcopy -O binary` → `\<stem>.bin`
|
||||||
* **C/C++** — objects → freestanding link → `objcopy -O binary` → `\<name>.bin`
|
* **C/C++** — objects → freestanding link → `objcopy -O binary` → `\<name>.bin`
|
||||||
* Requires `llvm-objcopy` / `objcopy` / `gobjcopy` except for NASM/FASM direct emit
|
* Requires `llvm-objcopy` / `objcopy` / `gobjcopy` except for NASM/FASM direct emit
|
||||||
* **`[archive]` section** — after a successful build, pack a FAT disk image (`fatfs`): `output`, `format` (`fat12`/`fat16`/`fat32`), optional `size` (default 1.44 MiB), `offset`, `label`, `bootsector`, and `layout` (`from` → `to`, supports globs). `{profile}` works in paths.
|
* **`[archive]` section** — FAT12/16/32 disk images after build (`output`, `format`, `size`, `offset`, `label`, `bootsector`, `layout`). From 0.8.2 requires feature `archive`.
|
||||||
* **Single-file `build.roots`** — a root may be a single source or header file, not only a directory.
|
* **Single-file `build.roots`** — a root may be a single source or header file, not only a directory.
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
@@ -22,10 +41,6 @@ sidebar_label: Changelog
|
|||||||
* **`--force`** also re-runs `build.steps` and `build.post_steps`.
|
* **`--force`** also re-runs `build.steps` and `build.post_steps`.
|
||||||
* **`dcr run` on workspace-only root** — if `[run].cmd` is set, run that after build; otherwise delegate to a workspace member.
|
* **`dcr run` on workspace-only root** — if `[run].cmd` is set, run that after build; otherwise delegate to a workspace member.
|
||||||
|
|
||||||
### Dependencies
|
|
||||||
|
|
||||||
* `fatfs = "0.3"` for FAT image packing.
|
|
||||||
|
|
||||||
## 0.8.0 (2026-07-18)
|
## 0.8.0 (2026-07-18)
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|||||||
@@ -42,10 +42,11 @@ cargo test --all-targets
|
|||||||
|
|
||||||
## CI
|
## CI
|
||||||
|
|
||||||
CI runs:
|
CI runs (see `.github/workflows/ci.yml`):
|
||||||
|
|
||||||
* `cargo fmt --check`
|
* `cargo fmt --check`
|
||||||
* `cargo clippy --all-targets -- -D warnings`
|
* `cargo clippy` (default + `--all-features`)
|
||||||
* `cargo check --all-targets --all-features`
|
* `cargo check --all-targets --all-features`
|
||||||
* Build on Linux, macOS, Windows
|
* Unit + integration tests on Linux, macOS, Windows
|
||||||
* Integration tests (compilation check)
|
* Extra Linux job with `--features archive` (FAT images)
|
||||||
|
* Tools on runners: clang, nasm, clang-format/tidy (Linux)
|
||||||
|
|||||||
@@ -4,28 +4,64 @@ sidebar_label: Installation
|
|||||||
|
|
||||||
# Installation
|
# Installation
|
||||||
|
|
||||||
## Linux (Dexoron Packages)
|
## dcrup (recommended)
|
||||||
|
|
||||||
Configure your package manager at https://pkg.dexoron.su and install:
|
Install and switch DCR versions (stable / dev / night, pin `0.8.2`, optional build from source).
|
||||||
|
|
||||||
**Arch Linux**
|
### Linux / macOS / BSD / Windows (bash)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo pacman -Sy dcr
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- self-install
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
|
dcrup install stable
|
||||||
```
|
```
|
||||||
|
|
||||||
**Debian/Ubuntu**
|
Non-interactive install of DCR in one shot:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo apt update && sudo apt install dcr
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- install stable
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
```
|
```
|
||||||
|
|
||||||
**Fedora/RHEL**
|
### Windows (PowerShell)
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
irm https://ps1.dcr-tool.ru | iex
|
||||||
|
# or download then run:
|
||||||
|
# irm https://ps1.dcr-tool.ru -OutFile dcrup.ps1
|
||||||
|
# powershell -File .\dcrup.ps1 self-install
|
||||||
|
# $env:Path += ";$env:USERPROFILE\.dcr\bin"
|
||||||
|
dcrup install stable
|
||||||
|
```
|
||||||
|
|
||||||
|
Optional cmd bootstrap (if you prefer `curl` of the cmd shim):
|
||||||
|
|
||||||
|
```bat
|
||||||
|
curl -fsSL -o dcrup.cmd https://cmd.dcr-tool.ru
|
||||||
|
```
|
||||||
|
|
||||||
|
After `self-install`, the command is **`dcrup`** (no `.sh` / `.ps1`): shims live in `~/.dcr/bin` (Unix) or `%USERPROFILE%\.dcr\bin` (Windows `dcrup.cmd`).
|
||||||
|
|
||||||
|
### Common dcrup commands
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo dnf install dcr
|
dcrup install stable # latest stable prebuilt
|
||||||
|
dcrup install 0.8.2 # pin → 0.8.2@stable
|
||||||
|
dcrup install 0.8.2@dev
|
||||||
|
dcrup install stable --libc musl # Linux: musl asset (default: gnu)
|
||||||
|
dcrup install stable --build # cargo build --features archive
|
||||||
|
dcrup install night # always build from branch dev HEAD
|
||||||
|
dcrup default 0.8.2
|
||||||
|
dcrup update
|
||||||
|
dcrup list
|
||||||
|
dcrup show
|
||||||
|
dcrup which
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Layout: `~/.dcr/toolchains/\<id>/dcr` and `~/.dcr/bin/dcr` → active version.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
## Arch Linux (AUR)
|
## Arch Linux (AUR)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
@@ -45,11 +81,12 @@ brew install dcr
|
|||||||
sudo snap install dcrup
|
sudo snap install dcrup
|
||||||
```
|
```
|
||||||
|
|
||||||
|
> If classic Snap Store publishing is unavailable, install the `.snap` from [GitHub Releases](https://github.com/dexoron/dcr/releases/latest) with `--dangerous`.
|
||||||
|
|
||||||
## Nix (flake)
|
## Nix (flake)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
nix run github:dexoron/dcr
|
nix run github:dexoron/dcr
|
||||||
# or install to profile:
|
|
||||||
nix profile install github:dexoron/dcr
|
nix profile install github:dexoron/dcr
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -59,48 +96,37 @@ nix profile install github:dexoron/dcr
|
|||||||
cargo install dcr
|
cargo install dcr
|
||||||
```
|
```
|
||||||
|
|
||||||
## Linux / macOS (script)
|
Note: crates.io builds may omit optional features. For FAT disk images (`[archive]`), prefer release binaries or:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
curl -fsSL https://dcr.dexoron.su/install.sh | sh
|
cargo install dcr --features archive
|
||||||
```
|
|
||||||
|
|
||||||
## BSD (script)
|
|
||||||
|
|
||||||
```sh
|
|
||||||
curl -fsSL https://dcr.dexoron.su/install_bsd.sh | sh
|
|
||||||
```
|
|
||||||
|
|
||||||
## Windows (PowerShell)
|
|
||||||
|
|
||||||
```powershell
|
|
||||||
irm https://dcr.dexoron.su/install.ps1 | iex
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## From source
|
## From source
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git clone https://github.com/dexoron/dcr.git
|
git clone https://github.com/dexoron/dcr.git
|
||||||
cd dcr && cargo build --release
|
cd dcr
|
||||||
|
cargo build --release --features archive
|
||||||
ln -sf "$PWD/target/release/dcr" ~/.local/bin/dcr
|
ln -sf "$PWD/target/release/dcr" ~/.local/bin/dcr
|
||||||
|
# or manage versions with dcrup install night / --build
|
||||||
```
|
```
|
||||||
|
|
||||||
## Post-install
|
## Post-install
|
||||||
|
|
||||||
Verify the installation:
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
dcr --version
|
dcr --version
|
||||||
|
dcrup show # if installed via dcrup
|
||||||
```
|
```
|
||||||
|
|
||||||
Man pages are available after installation:
|
Man pages (package installs / release assets):
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
man dcr
|
man dcr
|
||||||
man dcr-build
|
man dcr-build
|
||||||
```
|
```
|
||||||
|
|
||||||
To use the registry, create `~/.dcr/config.toml`:
|
Registry (optional) — `~/.dcr/config.toml`:
|
||||||
|
|
||||||
```toml
|
```toml
|
||||||
[registry.default]
|
[registry.default]
|
||||||
|
|||||||
@@ -185,6 +185,8 @@ See [workspaces](/docs/reference/workspaces).
|
|||||||
|
|
||||||
Optional post-build step: format a FAT volume and copy built artifacts into a disk image. Runs after a successful package build (and after workspace member builds that define `[archive]`).
|
Optional post-build step: format a FAT volume and copy built artifacts into a disk image. Runs after a successful package build (and after workspace member builds that define `[archive]`).
|
||||||
|
|
||||||
|
Requires DCR built with the `archive` Cargo feature (`cargo build --features archive`). Release binaries include this feature.
|
||||||
|
|
||||||
| Field | Required | Description |
|
| Field | Required | Description |
|
||||||
| ------------ | -------- | ------------------------------------------------------------------------------------------- |
|
| ------------ | -------- | ------------------------------------------------------------------------------------------- |
|
||||||
| `output` | yes | Image path relative to project root (`{profile}` allowed) |
|
| `output` | yes | Image path relative to project root (`{profile}` allowed) |
|
||||||
|
|||||||
@@ -8,8 +8,10 @@ sidebar_label: Introduction
|
|||||||
<summary>Quick reference</summary>
|
<summary>Quick reference</summary>
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Installation
|
# Installation (dcrup)
|
||||||
curl -fsSL https://dcr.dexoron.su/install.sh | sh
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- self-install
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
|
dcrup install stable
|
||||||
|
|
||||||
# Create a project
|
# Create a project
|
||||||
dcr new my-app
|
dcr new my-app
|
||||||
|
|||||||
@@ -4,6 +4,25 @@ sidebar_label: Changelog
|
|||||||
|
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 0.8.2 (2026-07-22)
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
* **Compile progress `[N/M]`** — live TTY status line (`compile pkg v0.1.0 [12/41]`) so long mono-package builds do not look hung.
|
||||||
|
* **DCR status style** — fixed-width verbs: `project`, `compile`, `dep`, `ready`, `pack`, `done`, `run`.
|
||||||
|
* **Cargo feature `archive`** — optional FAT packing via `fatfs` (`cargo build --features archive`). Release CI builds with the feature; without it `[archive]` fails with a clear message.
|
||||||
|
* **Tests** — `flat_bin_nasm_build`, package `build.target` without CLI `--target`, stricter workspace `clean --all`.
|
||||||
|
* **CI expansion** — unit + integration on Linux/macOS/Windows, archive feature job, rust-cache, clippy default + all-features (see `.github/workflows/ci.yml`).
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
* **No forced host triple from CLI** — without `--target`, package/member `build.target` is honored (bare-metal / ISO `post_steps` paths).
|
||||||
|
* **Relative include/lib flags** (`-I`, `-i`, `-isystem`, `-idirafter`, `-L`, `-T`) absolutized against the package root under workspace builds.
|
||||||
|
* **`dcr clean --all`** — no spam for members without a local `target/` (shared root `target/`).
|
||||||
|
* **`error` / `warn`** — red / yellow on stderr; CLI fully English (`Hint:`).
|
||||||
|
* **Help / man** — list `add`, `lint`, `setup`; unknown command exits with code 1.
|
||||||
|
* **Tool NotFound** — `linker not found: ld.lld …` / `{tool} not found …` instead of raw `os error 2`.
|
||||||
|
|
||||||
## 0.8.1 (2026-07-20)
|
## 0.8.1 (2026-07-20)
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
@@ -14,7 +33,7 @@ sidebar_label: Changelog
|
|||||||
* **GAS / MASM / LLC** — object → `objcopy -O binary` → `\<stem>.bin`
|
* **GAS / MASM / LLC** — object → `objcopy -O binary` → `\<stem>.bin`
|
||||||
* **C/C++** — objects → freestanding link → `objcopy -O binary` → `\<name>.bin`
|
* **C/C++** — objects → freestanding link → `objcopy -O binary` → `\<name>.bin`
|
||||||
* Requires `llvm-objcopy` / `objcopy` / `gobjcopy` except for NASM/FASM direct emit
|
* Requires `llvm-objcopy` / `objcopy` / `gobjcopy` except for NASM/FASM direct emit
|
||||||
* **`[archive]` section** — after a successful build, pack a FAT disk image (`fatfs`): `output`, `format` (`fat12`/`fat16`/`fat32`), optional `size` (default 1.44 MiB), `offset`, `label`, `bootsector`, and `layout` (`from` → `to`, supports globs). `{profile}` works in paths.
|
* **`[archive]` section** — FAT12/16/32 disk images after build (`output`, `format`, `size`, `offset`, `label`, `bootsector`, `layout`). From 0.8.2 requires feature `archive`.
|
||||||
* **Single-file `build.roots`** — a root may be a single source or header file, not only a directory.
|
* **Single-file `build.roots`** — a root may be a single source or header file, not only a directory.
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
@@ -22,10 +41,6 @@ sidebar_label: Changelog
|
|||||||
* **`--force`** also re-runs `build.steps` and `build.post_steps`.
|
* **`--force`** also re-runs `build.steps` and `build.post_steps`.
|
||||||
* **`dcr run` on workspace-only root** — if `[run].cmd` is set, run that after build; otherwise delegate to a workspace member.
|
* **`dcr run` on workspace-only root** — if `[run].cmd` is set, run that after build; otherwise delegate to a workspace member.
|
||||||
|
|
||||||
### Dependencies
|
|
||||||
|
|
||||||
* `fatfs = "0.3"` for FAT image packing.
|
|
||||||
|
|
||||||
## 0.8.0 (2026-07-18)
|
## 0.8.0 (2026-07-18)
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|||||||
@@ -42,10 +42,11 @@ cargo test --all-targets
|
|||||||
|
|
||||||
## CI
|
## CI
|
||||||
|
|
||||||
CI runs:
|
CI runs (see `.github/workflows/ci.yml`):
|
||||||
|
|
||||||
* `cargo fmt --check`
|
* `cargo fmt --check`
|
||||||
* `cargo clippy --all-targets -- -D warnings`
|
* `cargo clippy` (default + `--all-features`)
|
||||||
* `cargo check --all-targets --all-features`
|
* `cargo check --all-targets --all-features`
|
||||||
* Build on Linux, macOS, Windows
|
* Unit + integration tests on Linux, macOS, Windows
|
||||||
* Integration tests (compilation check)
|
* Extra Linux job with `--features archive` (FAT images)
|
||||||
|
* Tools on runners: clang, nasm, clang-format/tidy (Linux)
|
||||||
|
|||||||
@@ -4,28 +4,64 @@ sidebar_label: Installation
|
|||||||
|
|
||||||
# Installation
|
# Installation
|
||||||
|
|
||||||
## Linux (Dexoron Packages)
|
## dcrup (recommended)
|
||||||
|
|
||||||
Configure your package manager at https://pkg.dexoron.su and install:
|
Install and switch DCR versions (stable / dev / night, pin `0.8.2`, optional build from source).
|
||||||
|
|
||||||
**Arch Linux**
|
### Linux / macOS / BSD / Windows (bash)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo pacman -Sy dcr
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- self-install
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
|
dcrup install stable
|
||||||
```
|
```
|
||||||
|
|
||||||
**Debian/Ubuntu**
|
Non-interactive install of DCR in one shot:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo apt update && sudo apt install dcr
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- install stable
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
```
|
```
|
||||||
|
|
||||||
**Fedora/RHEL**
|
### Windows (PowerShell)
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
irm https://ps1.dcr-tool.ru | iex
|
||||||
|
# or download then run:
|
||||||
|
# irm https://ps1.dcr-tool.ru -OutFile dcrup.ps1
|
||||||
|
# powershell -File .\dcrup.ps1 self-install
|
||||||
|
# $env:Path += ";$env:USERPROFILE\.dcr\bin"
|
||||||
|
dcrup install stable
|
||||||
|
```
|
||||||
|
|
||||||
|
Optional cmd bootstrap (if you prefer `curl` of the cmd shim):
|
||||||
|
|
||||||
|
```bat
|
||||||
|
curl -fsSL -o dcrup.cmd https://cmd.dcr-tool.ru
|
||||||
|
```
|
||||||
|
|
||||||
|
After `self-install`, the command is **`dcrup`** (no `.sh` / `.ps1`): shims live in `~/.dcr/bin` (Unix) or `%USERPROFILE%\.dcr\bin` (Windows `dcrup.cmd`).
|
||||||
|
|
||||||
|
### Common dcrup commands
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo dnf install dcr
|
dcrup install stable # latest stable prebuilt
|
||||||
|
dcrup install 0.8.2 # pin → 0.8.2@stable
|
||||||
|
dcrup install 0.8.2@dev
|
||||||
|
dcrup install stable --libc musl # Linux: musl asset (default: gnu)
|
||||||
|
dcrup install stable --build # cargo build --features archive
|
||||||
|
dcrup install night # always build from branch dev HEAD
|
||||||
|
dcrup default 0.8.2
|
||||||
|
dcrup update
|
||||||
|
dcrup list
|
||||||
|
dcrup show
|
||||||
|
dcrup which
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Layout: `~/.dcr/toolchains/\<id>/dcr` and `~/.dcr/bin/dcr` → active version.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
## Arch Linux (AUR)
|
## Arch Linux (AUR)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
@@ -45,11 +81,12 @@ brew install dcr
|
|||||||
sudo snap install dcrup
|
sudo snap install dcrup
|
||||||
```
|
```
|
||||||
|
|
||||||
|
> If classic Snap Store publishing is unavailable, install the `.snap` from [GitHub Releases](https://github.com/dexoron/dcr/releases/latest) with `--dangerous`.
|
||||||
|
|
||||||
## Nix (flake)
|
## Nix (flake)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
nix run github:dexoron/dcr
|
nix run github:dexoron/dcr
|
||||||
# or install to profile:
|
|
||||||
nix profile install github:dexoron/dcr
|
nix profile install github:dexoron/dcr
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -59,48 +96,37 @@ nix profile install github:dexoron/dcr
|
|||||||
cargo install dcr
|
cargo install dcr
|
||||||
```
|
```
|
||||||
|
|
||||||
## Linux / macOS (script)
|
Note: crates.io builds may omit optional features. For FAT disk images (`[archive]`), prefer release binaries or:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
curl -fsSL https://dcr.dexoron.su/install.sh | sh
|
cargo install dcr --features archive
|
||||||
```
|
|
||||||
|
|
||||||
## BSD (script)
|
|
||||||
|
|
||||||
```sh
|
|
||||||
curl -fsSL https://dcr.dexoron.su/install_bsd.sh | sh
|
|
||||||
```
|
|
||||||
|
|
||||||
## Windows (PowerShell)
|
|
||||||
|
|
||||||
```powershell
|
|
||||||
irm https://dcr.dexoron.su/install.ps1 | iex
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## From source
|
## From source
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git clone https://github.com/dexoron/dcr.git
|
git clone https://github.com/dexoron/dcr.git
|
||||||
cd dcr && cargo build --release
|
cd dcr
|
||||||
|
cargo build --release --features archive
|
||||||
ln -sf "$PWD/target/release/dcr" ~/.local/bin/dcr
|
ln -sf "$PWD/target/release/dcr" ~/.local/bin/dcr
|
||||||
|
# or manage versions with dcrup install night / --build
|
||||||
```
|
```
|
||||||
|
|
||||||
## Post-install
|
## Post-install
|
||||||
|
|
||||||
Verify the installation:
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
dcr --version
|
dcr --version
|
||||||
|
dcrup show # if installed via dcrup
|
||||||
```
|
```
|
||||||
|
|
||||||
Man pages are available after installation:
|
Man pages (package installs / release assets):
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
man dcr
|
man dcr
|
||||||
man dcr-build
|
man dcr-build
|
||||||
```
|
```
|
||||||
|
|
||||||
To use the registry, create `~/.dcr/config.toml`:
|
Registry (optional) — `~/.dcr/config.toml`:
|
||||||
|
|
||||||
```toml
|
```toml
|
||||||
[registry.default]
|
[registry.default]
|
||||||
|
|||||||
@@ -185,6 +185,8 @@ See [workspaces](/docs/reference/workspaces).
|
|||||||
|
|
||||||
Optional post-build step: format a FAT volume and copy built artifacts into a disk image. Runs after a successful package build (and after workspace member builds that define `[archive]`).
|
Optional post-build step: format a FAT volume and copy built artifacts into a disk image. Runs after a successful package build (and after workspace member builds that define `[archive]`).
|
||||||
|
|
||||||
|
Requires DCR built with the `archive` Cargo feature (`cargo build --features archive`). Release binaries include this feature.
|
||||||
|
|
||||||
| Field | Required | Description |
|
| Field | Required | Description |
|
||||||
| ------------ | -------- | ------------------------------------------------------------------------------------------- |
|
| ------------ | -------- | ------------------------------------------------------------------------------------------- |
|
||||||
| `output` | yes | Image path relative to project root (`{profile}` allowed) |
|
| `output` | yes | Image path relative to project root (`{profile}` allowed) |
|
||||||
|
|||||||
@@ -8,15 +8,27 @@ sidebar_label: Введение
|
|||||||
<summary>Быстрая справка</summary>
|
<summary>Быстрая справка</summary>
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Установка(Linux/MacOS скрипт)
|
# Installation (dcrup)
|
||||||
curl -fsSL https://dcr.dexoron.su/install.sh | sh
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- self-install
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
|
dcrup install stable
|
||||||
|
|
||||||
# Создать проект
|
# Create a project
|
||||||
dcr new my-app
|
dcr new my-app
|
||||||
cd my-app
|
cd my-app
|
||||||
|
|
||||||
# Собрать и запустить
|
# Build and run
|
||||||
|
dcr build
|
||||||
dcr run
|
dcr run
|
||||||
|
|
||||||
|
# Run tests
|
||||||
|
dcr test
|
||||||
|
|
||||||
|
# Add a dependency
|
||||||
|
dcr add fmt
|
||||||
|
|
||||||
|
# Generate IDE files
|
||||||
|
dcr gen vscode
|
||||||
```
|
```
|
||||||
|
|
||||||
</details>
|
</details>
|
||||||
|
|||||||
@@ -4,31 +4,46 @@ sidebar_label: Список изменений
|
|||||||
|
|
||||||
# Список изменений
|
# Список изменений
|
||||||
|
|
||||||
## 0.8.1 (2026-07-20)
|
## 0.8.2 (2026-07-22)
|
||||||
|
|
||||||
### Добавлено:
|
### Добавлено:
|
||||||
|
|
||||||
|
* **Compile progress `[N/M]`** — live TTY status line (`compile pkg v0.1.0 [12/41]`) so long mono-package builds do not look hung.
|
||||||
|
* **DCR status style** — fixed-width verbs: `project`, `compile`, `dep`, `ready`, `pack`, `done`, `run`.
|
||||||
|
* **Cargo feature `archive`** — optional FAT packing via `fatfs` (`cargo build --features archive`). Release CI builds with the feature; without it `[archive]` fails with a clear message.
|
||||||
|
* **Tests** — `flat_bin_nasm_build`, package `build.target` without CLI `--target`, stricter workspace `clean --all`.
|
||||||
|
* **CI expansion** — unit + integration on Linux/macOS/Windows, archive feature job, rust-cache, clippy default + all-features (see `.github/workflows/ci.yml`).
|
||||||
|
|
||||||
|
### Изменено:
|
||||||
|
|
||||||
|
* **No forced host triple from CLI** — without `--target`, package/member `build.target` is honored (bare-metal / ISO `post_steps` paths).
|
||||||
|
* **Relative include/lib flags** (`-I`, `-i`, `-isystem`, `-idirafter`, `-L`, `-T`) absolutized against the package root under workspace builds.
|
||||||
|
* **`dcr clean --all`** — no spam for members without a local `target/` (shared root `target/`).
|
||||||
|
* **`error` / `warn`** — red / yellow on stderr; CLI fully English (`Hint:`).
|
||||||
|
* **Help / man** — list `add`, `lint`, `setup`; unknown command exits with code 1.
|
||||||
|
* **Tool NotFound** — `linker not found: ld.lld …` / `{tool} not found …` instead of raw `os error 2`.
|
||||||
|
|
||||||
|
## 0.8.1 (2026-07-20)
|
||||||
|
|
||||||
|
### Добавлено
|
||||||
|
|
||||||
* **`build.kind = "flat-bin"`** — raw binary (default `.bin`) for OS-dev payloads:
|
* **`build.kind = "flat-bin"`** — raw binary (default `.bin`) for OS-dev payloads:
|
||||||
* **NASM** — `-f bin` → `\<stem>.bin`
|
* **NASM** — `-f bin` → `\<stem>.bin`
|
||||||
* **FASM** — direct output (`format binary` in source)
|
* **FASM** — direct output (`format binary` in source)
|
||||||
* **GAS / MASM / LLC** — object → `objcopy -O binary` → `\<stem>.bin`
|
* **GAS / MASM / LLC** — object → `objcopy -O binary` → `\<stem>.bin`
|
||||||
* **C/C++** — objects → freestanding link → `objcopy -O binary` → `\<name>.bin`
|
* **C/C++** — objects → freestanding link → `objcopy -O binary` → `\<name>.bin`
|
||||||
* Requires `llvm-objcopy` / `objcopy` / `gobjcopy` except for NASM/FASM direct emit
|
* Requires `llvm-objcopy` / `objcopy` / `gobjcopy` except for NASM/FASM direct emit
|
||||||
* **`[archive]` section** — after a successful build, pack a FAT disk image (`fatfs`): `output`, `format` (`fat12`/`fat16`/`fat32`), optional `size` (default 1.44 MiB), `offset`, `label`, `bootsector`, and `layout` (`from` → `to`, supports globs). `{profile}` works in paths.
|
* **`[archive]` section** — FAT12/16/32 disk images after build (`output`, `format`, `size`, `offset`, `label`, `bootsector`, `layout`). From 0.8.2 requires feature `archive`.
|
||||||
* **Single-file `build.roots`** — a root may be a single source or header file, not only a directory.
|
* **Single-file `build.roots`** — a root may be a single source or header file, not only a directory.
|
||||||
|
|
||||||
### Изменено:
|
### Изменено
|
||||||
|
|
||||||
* **`--force`** also re-runs `build.steps` and `build.post_steps`.
|
* **`--force`** also re-runs `build.steps` and `build.post_steps`.
|
||||||
* **`dcr run` on workspace-only root** — if `[run].cmd` is set, run that after build; otherwise delegate to a workspace member.
|
* **`dcr run` on workspace-only root** — if `[run].cmd` is set, run that after build; otherwise delegate to a workspace member.
|
||||||
|
|
||||||
### Dependencies
|
|
||||||
|
|
||||||
* `fatfs = "0.3"` for FAT image packing.
|
|
||||||
|
|
||||||
## 0.8.0 (2026-07-18)
|
## 0.8.0 (2026-07-18)
|
||||||
|
|
||||||
### Добавлено
|
### Added
|
||||||
|
|
||||||
* **Dedicated Build Engine (`src/core/build/engine.rs`)** — decoupled the build orchestration logic completely from the CLI front-end wrapper in `src/cli/build.rs` to a reusable, decoupled core build engine.
|
* **Dedicated Build Engine (`src/core/build/engine.rs`)** — decoupled the build orchestration logic completely from the CLI front-end wrapper in `src/cli/build.rs` to a reusable, decoupled core build engine.
|
||||||
* **Polymorphic Language Model (`Language` trait)** — introduced the abstract `Language` trait (`src/core/build/language/mod.rs`). File scanning, compiler resolution, and flags handling are now encapsulated in dedicated language modules for C, C++ (including Qt code generation), LLVM IR, and ASM (GAS, NASM, FASM, MASM).
|
* **Polymorphic Language Model (`Language` trait)** — introduced the abstract `Language` trait (`src/core/build/language/mod.rs`). File scanning, compiler resolution, and flags handling are now encapsulated in dedicated language modules for C, C++ (including Qt code generation), LLVM IR, and ASM (GAS, NASM, FASM, MASM).
|
||||||
@@ -41,7 +56,7 @@ sidebar_label: Список изменений
|
|||||||
* **Path Dependencies Target Include Resolution** — local path dependencies configured via tables now correctly expose headers built and packaged into their `target/include` folder to consumer packages.
|
* **Path Dependencies Target Include Resolution** — local path dependencies configured via tables now correctly expose headers built and packaged into their `target/include` folder to consumer packages.
|
||||||
* **Modular Integration Test Suite** — refactored the monolith `tests/cli_basic.rs` file into clean, specialized integration tests: `cli_build.rs`, `cli_deps.rs`, `cli_lint.rs`, `cli_new.rs`, `cli_qt.rs`, `cli_test.rs`, `cli_workspace.rs`.
|
* **Modular Integration Test Suite** — refactored the monolith `tests/cli_basic.rs` file into clean, specialized integration tests: `cli_build.rs`, `cli_deps.rs`, `cli_lint.rs`, `cli_new.rs`, `cli_qt.rs`, `cli_test.rs`, `cli_workspace.rs`.
|
||||||
|
|
||||||
### Изменено
|
### Changed
|
||||||
|
|
||||||
* **Consolidated Linking and Archiving** — artifact generation (linking executables/shared libraries and archiving static libraries) consolidated into a single `src/core/build/builder/artifact.rs` module.
|
* **Consolidated Linking and Archiving** — artifact generation (linking executables/shared libraries and archiving static libraries) consolidated into a single `src/core/build/builder/artifact.rs` module.
|
||||||
* **Workspace-Aware member execution** — `dcr run` executed at the workspace root of a `workspace_only` project now triggers the member build inside the workspace context using the `--workspace` parameter, preventing standalone build issues.
|
* **Workspace-Aware member execution** — `dcr run` executed at the workspace root of a `workspace_only` project now triggers the member build inside the workspace context using the `--workspace` parameter, preventing standalone build issues.
|
||||||
|
|||||||
@@ -42,10 +42,11 @@ cargo clippy --all-targets -- -D warnings
|
|||||||
|
|
||||||
## CI
|
## CI
|
||||||
|
|
||||||
В CI запускаются:
|
CI runs (see `.github/workflows/ci.yml`):
|
||||||
|
|
||||||
* `cargo fmt --check`
|
* `cargo fmt --check`
|
||||||
* `cargo clippy --all-targets -- -D warnings`
|
* `cargo clippy` (default + `--all-features`)
|
||||||
* `cargo check --all-targets --all-features`
|
* `cargo check --all-targets --all-features`
|
||||||
* Сборка под Linux, macOS, Windows, FreeBSD, OpenBSD, NetBSD
|
* Unit + integration tests on Linux, macOS, Windows
|
||||||
* Integration tests (compilation check)
|
* Extra Linux job with `--features archive` (FAT images)
|
||||||
|
* Tools on runners: clang, nasm, clang-format/tidy (Linux)
|
||||||
|
|||||||
@@ -4,28 +4,64 @@ sidebar_label: Установка
|
|||||||
|
|
||||||
# Установка
|
# Установка
|
||||||
|
|
||||||
## Linux (Dexoron Packages)
|
## dcrup (recommended)
|
||||||
|
|
||||||
Настройте менеджер пакетов на https://pkg.dexoron.su и установите:
|
Install and switch DCR versions (stable / dev / night, pin `0.8.2`, optional build from source).
|
||||||
|
|
||||||
**Arch Linux**
|
### Linux / macOS / BSD / Windows (bash)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo pacman -Sy dcr
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- self-install
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
|
dcrup install stable
|
||||||
```
|
```
|
||||||
|
|
||||||
**Debian/Ubuntu**
|
Non-interactive install of DCR in one shot:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo apt update && sudo apt install dcr
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- install stable
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
```
|
```
|
||||||
|
|
||||||
**Fedora/RHEL**
|
### Windows (PowerShell)
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
irm https://ps1.dcr-tool.ru | iex
|
||||||
|
# or download then run:
|
||||||
|
# irm https://ps1.dcr-tool.ru -OutFile dcrup.ps1
|
||||||
|
# powershell -File .\dcrup.ps1 self-install
|
||||||
|
# $env:Path += ";$env:USERPROFILE\.dcr\bin"
|
||||||
|
dcrup install stable
|
||||||
|
```
|
||||||
|
|
||||||
|
Optional cmd bootstrap (if you prefer `curl` of the cmd shim):
|
||||||
|
|
||||||
|
```bat
|
||||||
|
curl -fsSL -o dcrup.cmd https://cmd.dcr-tool.ru
|
||||||
|
```
|
||||||
|
|
||||||
|
After `self-install`, the command is **`dcrup`** (no `.sh` / `.ps1`): shims live in `~/.dcr/bin` (Unix) or `%USERPROFILE%\.dcr\bin` (Windows `dcrup.cmd`).
|
||||||
|
|
||||||
|
### Common dcrup commands
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo dnf install dcr
|
dcrup install stable # latest stable prebuilt
|
||||||
|
dcrup install 0.8.2 # pin → 0.8.2@stable
|
||||||
|
dcrup install 0.8.2@dev
|
||||||
|
dcrup install stable --libc musl # Linux: musl asset (default: gnu)
|
||||||
|
dcrup install stable --build # cargo build --features archive
|
||||||
|
dcrup install night # always build from branch dev HEAD
|
||||||
|
dcrup default 0.8.2
|
||||||
|
dcrup update
|
||||||
|
dcrup list
|
||||||
|
dcrup show
|
||||||
|
dcrup which
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Layout: `~/.dcr/toolchains/\<id>/dcr` and `~/.dcr/bin/dcr` → active version.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
## Arch Linux (AUR)
|
## Arch Linux (AUR)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
@@ -45,11 +81,12 @@ brew install dcr
|
|||||||
sudo snap install dcrup
|
sudo snap install dcrup
|
||||||
```
|
```
|
||||||
|
|
||||||
|
> If classic Snap Store publishing is unavailable, install the `.snap` from [GitHub Releases](https://github.com/dexoron/dcr/releases/latest) with `--dangerous`.
|
||||||
|
|
||||||
## Nix (flake)
|
## Nix (flake)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
nix run github:dexoron/dcr
|
nix run github:dexoron/dcr
|
||||||
# или установить в профиль:
|
|
||||||
nix profile install github:dexoron/dcr
|
nix profile install github:dexoron/dcr
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -59,48 +96,37 @@ nix profile install github:dexoron/dcr
|
|||||||
cargo install dcr
|
cargo install dcr
|
||||||
```
|
```
|
||||||
|
|
||||||
## Linux / macOS (скрипт)
|
Note: crates.io builds may omit optional features. For FAT disk images (`[archive]`), prefer release binaries or:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
curl -fsSL https://dcr.dexoron.su/install_bsd.sh | bash
|
cargo install dcr --features archive
|
||||||
```
|
|
||||||
|
|
||||||
## BSD (скрипт)
|
|
||||||
|
|
||||||
```sh
|
|
||||||
curl -fsSL https://dcr.dexoron.su/install.sh | bash
|
|
||||||
```
|
|
||||||
|
|
||||||
## Windows (PowerShell)
|
|
||||||
|
|
||||||
```powershell
|
|
||||||
irm https://dcr.dexoron.su/install.ps1 | iex
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## Из источника
|
## Из источника
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git clone https://github.com/dexoron/dcr.git
|
git clone https://github.com/dexoron/dcr.git
|
||||||
cd dcr && cargo build --release
|
cd dcr
|
||||||
|
cargo build --release --features archive
|
||||||
ln -sf "$PWD/target/release/dcr" ~/.local/bin/dcr
|
ln -sf "$PWD/target/release/dcr" ~/.local/bin/dcr
|
||||||
|
# or manage versions with dcrup install night / --build
|
||||||
```
|
```
|
||||||
|
|
||||||
## После установки
|
## После установки
|
||||||
|
|
||||||
Проверьте установку:
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
dcr setup
|
dcr --version
|
||||||
|
dcrup show # if installed via dcrup
|
||||||
```
|
```
|
||||||
|
|
||||||
После установки становятся доступны man страницы:
|
Man pages (package installs / release assets):
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
man dcr
|
man dcr
|
||||||
man dcr-build
|
man dcr-build
|
||||||
```
|
```
|
||||||
|
|
||||||
Чтобы использовать реестр, создайте файл `~/.dcr/config.toml`:
|
Registry (optional) — `~/.dcr/config.toml`:
|
||||||
|
|
||||||
```toml
|
```toml
|
||||||
[registry.default]
|
[registry.default]
|
||||||
|
|||||||
@@ -185,6 +185,8 @@ cmd = "./target/{profile}/{name}"
|
|||||||
|
|
||||||
Optional post-build step: format a FAT volume and copy built artifacts into a disk image. Runs after a successful package build (and after workspace member builds that define `[archive]`).
|
Optional post-build step: format a FAT volume and copy built artifacts into a disk image. Runs after a successful package build (and after workspace member builds that define `[archive]`).
|
||||||
|
|
||||||
|
Requires DCR built with the `archive` Cargo feature (`cargo build --features archive`). Release binaries include this feature.
|
||||||
|
|
||||||
| Field | Required | Description |
|
| Field | Required | Description |
|
||||||
| ------------ | -------- | ------------------------------------------------------------------------------------------- |
|
| ------------ | -------- | ------------------------------------------------------------------------------------------- |
|
||||||
| `output` | yes | Image path relative to project root (`{profile}` allowed) |
|
| `output` | yes | Image path relative to project root (`{profile}` allowed) |
|
||||||
|
|||||||
@@ -8,8 +8,10 @@ sidebar_label: Introduction
|
|||||||
<summary>Quick reference</summary>
|
<summary>Quick reference</summary>
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Installation
|
# Installation (dcrup)
|
||||||
curl -fsSL https://dcr.dexoron.su/install.sh | sh
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- self-install
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
|
dcrup install stable
|
||||||
|
|
||||||
# Create a project
|
# Create a project
|
||||||
dcr new my-app
|
dcr new my-app
|
||||||
|
|||||||
@@ -4,6 +4,25 @@ sidebar_label: Changelog
|
|||||||
|
|
||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 0.8.2 (2026-07-22)
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
* **Compile progress `[N/M]`** — live TTY status line (`compile pkg v0.1.0 [12/41]`) so long mono-package builds do not look hung.
|
||||||
|
* **DCR status style** — fixed-width verbs: `project`, `compile`, `dep`, `ready`, `pack`, `done`, `run`.
|
||||||
|
* **Cargo feature `archive`** — optional FAT packing via `fatfs` (`cargo build --features archive`). Release CI builds with the feature; without it `[archive]` fails with a clear message.
|
||||||
|
* **Tests** — `flat_bin_nasm_build`, package `build.target` without CLI `--target`, stricter workspace `clean --all`.
|
||||||
|
* **CI expansion** — unit + integration on Linux/macOS/Windows, archive feature job, rust-cache, clippy default + all-features (see `.github/workflows/ci.yml`).
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
* **No forced host triple from CLI** — without `--target`, package/member `build.target` is honored (bare-metal / ISO `post_steps` paths).
|
||||||
|
* **Relative include/lib flags** (`-I`, `-i`, `-isystem`, `-idirafter`, `-L`, `-T`) absolutized against the package root under workspace builds.
|
||||||
|
* **`dcr clean --all`** — no spam for members without a local `target/` (shared root `target/`).
|
||||||
|
* **`error` / `warn`** — red / yellow on stderr; CLI fully English (`Hint:`).
|
||||||
|
* **Help / man** — list `add`, `lint`, `setup`; unknown command exits with code 1.
|
||||||
|
* **Tool NotFound** — `linker not found: ld.lld …` / `{tool} not found …` instead of raw `os error 2`.
|
||||||
|
|
||||||
## 0.8.1 (2026-07-20)
|
## 0.8.1 (2026-07-20)
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
@@ -14,7 +33,7 @@ sidebar_label: Changelog
|
|||||||
* **GAS / MASM / LLC** — object → `objcopy -O binary` → `\<stem>.bin`
|
* **GAS / MASM / LLC** — object → `objcopy -O binary` → `\<stem>.bin`
|
||||||
* **C/C++** — objects → freestanding link → `objcopy -O binary` → `\<name>.bin`
|
* **C/C++** — objects → freestanding link → `objcopy -O binary` → `\<name>.bin`
|
||||||
* Requires `llvm-objcopy` / `objcopy` / `gobjcopy` except for NASM/FASM direct emit
|
* Requires `llvm-objcopy` / `objcopy` / `gobjcopy` except for NASM/FASM direct emit
|
||||||
* **`[archive]` section** — after a successful build, pack a FAT disk image (`fatfs`): `output`, `format` (`fat12`/`fat16`/`fat32`), optional `size` (default 1.44 MiB), `offset`, `label`, `bootsector`, and `layout` (`from` → `to`, supports globs). `{profile}` works in paths.
|
* **`[archive]` section** — FAT12/16/32 disk images after build (`output`, `format`, `size`, `offset`, `label`, `bootsector`, `layout`). From 0.8.2 requires feature `archive`.
|
||||||
* **Single-file `build.roots`** — a root may be a single source or header file, not only a directory.
|
* **Single-file `build.roots`** — a root may be a single source or header file, not only a directory.
|
||||||
|
|
||||||
### Changed
|
### Changed
|
||||||
@@ -22,10 +41,6 @@ sidebar_label: Changelog
|
|||||||
* **`--force`** also re-runs `build.steps` and `build.post_steps`.
|
* **`--force`** also re-runs `build.steps` and `build.post_steps`.
|
||||||
* **`dcr run` on workspace-only root** — if `[run].cmd` is set, run that after build; otherwise delegate to a workspace member.
|
* **`dcr run` on workspace-only root** — if `[run].cmd` is set, run that after build; otherwise delegate to a workspace member.
|
||||||
|
|
||||||
### Dependencies
|
|
||||||
|
|
||||||
* `fatfs = "0.3"` for FAT image packing.
|
|
||||||
|
|
||||||
## 0.8.0 (2026-07-18)
|
## 0.8.0 (2026-07-18)
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|||||||
@@ -42,10 +42,11 @@ cargo test --all-targets
|
|||||||
|
|
||||||
## CI
|
## CI
|
||||||
|
|
||||||
CI runs:
|
CI runs (see `.github/workflows/ci.yml`):
|
||||||
|
|
||||||
* `cargo fmt --check`
|
* `cargo fmt --check`
|
||||||
* `cargo clippy --all-targets -- -D warnings`
|
* `cargo clippy` (default + `--all-features`)
|
||||||
* `cargo check --all-targets --all-features`
|
* `cargo check --all-targets --all-features`
|
||||||
* Build on Linux, macOS, Windows
|
* Unit + integration tests on Linux, macOS, Windows
|
||||||
* Integration tests (compilation check)
|
* Extra Linux job with `--features archive` (FAT images)
|
||||||
|
* Tools on runners: clang, nasm, clang-format/tidy (Linux)
|
||||||
|
|||||||
@@ -4,28 +4,64 @@ sidebar_label: Installation
|
|||||||
|
|
||||||
# Installation
|
# Installation
|
||||||
|
|
||||||
## Linux (Dexoron Packages)
|
## dcrup (recommended)
|
||||||
|
|
||||||
Configure your package manager at https://pkg.dexoron.su and install:
|
Install and switch DCR versions (stable / dev / night, pin `0.8.2`, optional build from source).
|
||||||
|
|
||||||
**Arch Linux**
|
### Linux / macOS / BSD / Windows (bash)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo pacman -Sy dcr
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- self-install
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
|
dcrup install stable
|
||||||
```
|
```
|
||||||
|
|
||||||
**Debian/Ubuntu**
|
Non-interactive install of DCR in one shot:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo apt update && sudo apt install dcr
|
curl -fsSL https://sh.dcr-tool.ru | sh -s -- install stable
|
||||||
|
export PATH="$HOME/.dcr/bin:$PATH"
|
||||||
```
|
```
|
||||||
|
|
||||||
**Fedora/RHEL**
|
### Windows (PowerShell)
|
||||||
|
|
||||||
|
```powershell
|
||||||
|
irm https://ps1.dcr-tool.ru | iex
|
||||||
|
# or download then run:
|
||||||
|
# irm https://ps1.dcr-tool.ru -OutFile dcrup.ps1
|
||||||
|
# powershell -File .\dcrup.ps1 self-install
|
||||||
|
# $env:Path += ";$env:USERPROFILE\.dcr\bin"
|
||||||
|
dcrup install stable
|
||||||
|
```
|
||||||
|
|
||||||
|
Optional cmd bootstrap (if you prefer `curl` of the cmd shim):
|
||||||
|
|
||||||
|
```bat
|
||||||
|
curl -fsSL -o dcrup.cmd https://cmd.dcr-tool.ru
|
||||||
|
```
|
||||||
|
|
||||||
|
After `self-install`, the command is **`dcrup`** (no `.sh` / `.ps1`): shims live in `~/.dcr/bin` (Unix) or `%USERPROFILE%\.dcr\bin` (Windows `dcrup.cmd`).
|
||||||
|
|
||||||
|
### Common dcrup commands
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
sudo dnf install dcr
|
dcrup install stable # latest stable prebuilt
|
||||||
|
dcrup install 0.8.2 # pin → 0.8.2@stable
|
||||||
|
dcrup install 0.8.2@dev
|
||||||
|
dcrup install stable --libc musl # Linux: musl asset (default: gnu)
|
||||||
|
dcrup install stable --build # cargo build --features archive
|
||||||
|
dcrup install night # always build from branch dev HEAD
|
||||||
|
dcrup default 0.8.2
|
||||||
|
dcrup update
|
||||||
|
dcrup list
|
||||||
|
dcrup show
|
||||||
|
dcrup which
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Layout: `~/.dcr/toolchains/\<id>/dcr` and `~/.dcr/bin/dcr` → active version.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
## Arch Linux (AUR)
|
## Arch Linux (AUR)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
@@ -45,11 +81,12 @@ brew install dcr
|
|||||||
sudo snap install dcrup
|
sudo snap install dcrup
|
||||||
```
|
```
|
||||||
|
|
||||||
|
> If classic Snap Store publishing is unavailable, install the `.snap` from [GitHub Releases](https://github.com/dexoron/dcr/releases/latest) with `--dangerous`.
|
||||||
|
|
||||||
## Nix (flake)
|
## Nix (flake)
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
nix run github:dexoron/dcr
|
nix run github:dexoron/dcr
|
||||||
# or install to profile:
|
|
||||||
nix profile install github:dexoron/dcr
|
nix profile install github:dexoron/dcr
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -59,48 +96,37 @@ nix profile install github:dexoron/dcr
|
|||||||
cargo install dcr
|
cargo install dcr
|
||||||
```
|
```
|
||||||
|
|
||||||
## Linux / macOS (script)
|
Note: crates.io builds may omit optional features. For FAT disk images (`[archive]`), prefer release binaries or:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
curl -fsSL https://dcr.dexoron.su/install.sh | sh
|
cargo install dcr --features archive
|
||||||
```
|
|
||||||
|
|
||||||
## BSD (script)
|
|
||||||
|
|
||||||
```sh
|
|
||||||
curl -fsSL https://dcr.dexoron.su/install_bsd.sh | sh
|
|
||||||
```
|
|
||||||
|
|
||||||
## Windows (PowerShell)
|
|
||||||
|
|
||||||
```powershell
|
|
||||||
irm https://dcr.dexoron.su/install.ps1 | iex
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## From source
|
## From source
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
git clone https://github.com/dexoron/dcr.git
|
git clone https://github.com/dexoron/dcr.git
|
||||||
cd dcr && cargo build --release
|
cd dcr
|
||||||
|
cargo build --release --features archive
|
||||||
ln -sf "$PWD/target/release/dcr" ~/.local/bin/dcr
|
ln -sf "$PWD/target/release/dcr" ~/.local/bin/dcr
|
||||||
|
# or manage versions with dcrup install night / --build
|
||||||
```
|
```
|
||||||
|
|
||||||
## Post-install
|
## Post-install
|
||||||
|
|
||||||
Verify the installation:
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
dcr --version
|
dcr --version
|
||||||
|
dcrup show # if installed via dcrup
|
||||||
```
|
```
|
||||||
|
|
||||||
Man pages are available after installation:
|
Man pages (package installs / release assets):
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
man dcr
|
man dcr
|
||||||
man dcr-build
|
man dcr-build
|
||||||
```
|
```
|
||||||
|
|
||||||
To use the registry, create `~/.dcr/config.toml`:
|
Registry (optional) — `~/.dcr/config.toml`:
|
||||||
|
|
||||||
```toml
|
```toml
|
||||||
[registry.default]
|
[registry.default]
|
||||||
|
|||||||
@@ -185,6 +185,8 @@ See [workspaces](/docs/reference/workspaces).
|
|||||||
|
|
||||||
Optional post-build step: format a FAT volume and copy built artifacts into a disk image. Runs after a successful package build (and after workspace member builds that define `[archive]`).
|
Optional post-build step: format a FAT volume and copy built artifacts into a disk image. Runs after a successful package build (and after workspace member builds that define `[archive]`).
|
||||||
|
|
||||||
|
Requires DCR built with the `archive` Cargo feature (`cargo build --features archive`). Release binaries include this feature.
|
||||||
|
|
||||||
| Field | Required | Description |
|
| Field | Required | Description |
|
||||||
| ------------ | -------- | ------------------------------------------------------------------------------------------- |
|
| ------------ | -------- | ------------------------------------------------------------------------------------------- |
|
||||||
| `output` | yes | Image path relative to project root (`{profile}` allowed) |
|
| `output` | yes | Image path relative to project root (`{profile}` allowed) |
|
||||||
|
|||||||
Reference in New Issue
Block a user