Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion Dockerfile.ci
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ FROM debian:trixie-slim
# Align with Deckhouse module (debian-trixie) and libunwind+lzma static link expectations.
# LLVM 21 from apt.llvm.org (trixie toolchain).
# gcc-16/g++-16: not yet in Trixie; install from sid with apt pinning (default compiler).
# re2c is pinned because generated tokenizers are committed.
RUN set -eux; \
apt-get update; \
apt-get install -y --no-install-recommends \
Expand Down Expand Up @@ -30,7 +31,7 @@ RUN set -eux; \
echo "deb [signed-by=/usr/share/keyrings/debian-archive-keyring.pgp] http://deb.debian.org/debian sid main" > /etc/apt/sources.list.d/sid.list; \
printf 'Package: *\nPin: release a=sid\nPin-Priority: 100\n' > /etc/apt/preferences.d/sid; \
apt-get update; \
apt-get install -y --no-install-recommends clang-format-21 clang-tidy-21 libclang-21-dev; \
apt-get install -y --no-install-recommends clang-format-21 clang-tidy-21 libclang-21-dev re2c=4.5.1-1; \
apt-get install -y --no-install-recommends -t sid gcc-16 g++-16 libstdc++-16-dev; \
apt-get install -y binutils; \
update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-16 100; \
Expand Down
8 changes: 5 additions & 3 deletions pp/prometheus/textparse/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,21 @@ We use re2c as lexer generator for parse prometheus text metrics format.
## Installation

```bash
apt install re2c
apt install re2c=4.5.1-1
```

## Prometheus lexer code generation

```bash
re2c prometheus/textparse/prometheus/tokenizer.cxx -o prometheus/textparse/prometheus/tokenizer.cpp --no-debug-info --conditions --bit-vectors --no-generation-date --no-version
re2c prometheus/textparse/prometheus/tokenizer.cxx -o prometheus/textparse/prometheus/tokenizer.cpp --no-debug-info --conditions --bit-vectors --computed-gotos-relative --no-generation-date --no-version -Werror
clang-format -i prometheus/textparse/prometheus/tokenizer.cpp
```

## Open metrics Lexer code generation

```bash
re2c prometheus/textparse/open_metrics/tokenizer.cxx -o prometheus/textparse/open_metrics/tokenizer.cpp --no-debug-info --conditions --bit-vectors --no-generation-date --no-version
re2c prometheus/textparse/open_metrics/tokenizer.cxx -o prometheus/textparse/open_metrics/tokenizer.cpp --no-debug-info --conditions --bit-vectors --computed-gotos-relative --no-generation-date --no-version -Werror
clang-format -i prometheus/textparse/open_metrics/tokenizer.cpp
```

## Links
Expand Down
Loading
Loading