mirror of
https://github.com/dexoron/dcr.git
synced 2026-10-21 14:38:30 +00:00
Introduce `--mirror` and `DCRUP_MIRROR` so `dcrup` can fetch prebuilt binaries from multiple CDNs. Default `auto` tries cf → gh → sf → ya and uses the first successful download. - dcrup.sh / dcrup.ps1: mirror chain, CLI flag, env override - remove install.sh / install.ps1 / install_bsd.sh (superseded by dcrup) - GitHub Actions: upload releases to Cloudflare R2 next to Yandex S3 - docs: README, FAQ, changelog, installation, env vars, contributing
76 lines
1.4 KiB
Plaintext
76 lines
1.4 KiB
Plaintext
---
|
|
sidebar_label: FAQ
|
|
---
|
|
|
|
# FAQ
|
|
|
|
## Registry not found
|
|
|
|
```
|
|
error: registry not found
|
|
```
|
|
|
|
**Solution:** Make sure `~/.dcr/config.toml` exists:
|
|
|
|
```toml
|
|
[registry.default]
|
|
url = "https://index.dcr.pm"
|
|
priority = 1
|
|
```
|
|
|
|
And check `DCR_INDEX_PATH`:
|
|
|
|
```bash
|
|
echo $DCR_INDEX_PATH
|
|
```
|
|
|
|
## Compiler not found
|
|
|
|
```
|
|
error: compiler not found
|
|
```
|
|
|
|
**Solution:** Ensure a compiler is installed and available in PATH.
|
|
|
|
```bash
|
|
which gcc
|
|
which clang
|
|
```
|
|
|
|
Or specify explicitly via `[toolchain]` in `dcr.toml`.
|
|
|
|
## Ctrl+C during build
|
|
|
|
DCR handles SIGINT: interrupts the current compilation and exits with non-zero code.
|
|
|
|
## How to create a library?
|
|
|
|
See [Library Recipe](/docs/recipes/library-project).
|
|
|
|
## How to cross-compile to Windows?
|
|
|
|
See [Cross-Compile Recipe](/docs/recipes/cross-to-windows).
|
|
|
|
## How to create a multi-package project?
|
|
|
|
See [Workspace Recipe](/docs/recipes/multi-package-workspace).
|
|
|
|
## Bootloader / pure NASM OS image
|
|
|
|
Use `kind = "flat-bin"` (NASM `-f bin`) and optional `[archive]` for a FAT disk image.
|
|
|
|
See [OS-dev recipe](/docs/recipes/os-flat-bin-archive).
|
|
|
|
## How do I choose a download mirror?
|
|
|
|
`dcrup install` uses `--mirror auto` by default and tries **cf → gh → sf → ya**.
|
|
|
|
```bash
|
|
dcrup install stable --mirror cf
|
|
export DCRUP_MIRROR=ya
|
|
```
|
|
|
|
## Lock file
|
|
|
|
`dcr.lock` is created during builds (`dcr build`) when registry dependencies are present. To force an update — delete `dcr.lock` and run `dcr build`.
|