<feed xmlns='http://www.w3.org/2005/Atom'>
<title>staging/stintel/tools/Makefile, branch master</title>
<subtitle>Staging tree of Stijn Tintel</subtitle>
<id>https://git.openwrt.org/openwrt/staging/stintel/atom?h=master</id>
<link rel='self' href='https://git.openwrt.org/openwrt/staging/stintel/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/'/>
<updated>2026-10-30T10:06:08Z</updated>
<entry>
<title>tools/sccache: add sccache Rust compiler cache</title>
<updated>2026-10-30T10:06:08Z</updated>
<author>
<name>Daniel Golle</name>
</author>
<published>2026-10-22T22:23:17Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=a1788e6156cf4541aaae31191b693d2008c79541'/>
<id>urn:sha1:a1788e6156cf4541aaae31191b693d2008c79541</id>
<content type='text'>
RUST_SCCACHE builds sccache 0.18.0 from a vendor tarball and makes it
the RUSTC_WRAPPER of the cargo builds of host tools, target packages
and libstd-rust. For target packages, scripts/rust-target-wrapper.sh
runs it in turn. The option sits next to CCACHE and is available with
any Rust toolchain of the build system. The packages feed defines
RUST_SCCACHE as well, without a dependency, and Kconfig merges both
definitions, so the tools and the cargo variables check for a Rust
toolchain once more.

sccache is built without default features: the local disk cache stays,
the remote storage backends and their HTTP and TLS stacks are left out,
so the build needs no host library. sccache needs rustc to build, so
the rustc build from source and the sccache build run unwrapped.

sccache keeps its cache and configuration in $(TOPDIR)/.sccache, or in
RUST_SCCACHE_DIR when set, and its server listens on a socket in
$(TMP_DIR), so that each tree has a server of its own. distclean
removes .sccache, and the SCCACHE_* variables of the environment are
unexported.

Signed-off-by: Daniel Golle &lt;daniel@makrotopia.org&gt;

</content>
</entry>
<entry>
<title>tools/corrosion: add corrosion-rs CMake-Cargo integration</title>
<updated>2026-10-30T10:06:08Z</updated>
<author>
<name>Daniel Golle</name>
</author>
<published>2026-10-08T10:21:09Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=05574936572fa17d104b0fa8d8378296a93dfe9e'/>
<id>urn:sha1:05574936572fa17d104b0fa8d8378296a93dfe9e</id>
<content type='text'>
Build corrosion-rs 0.5.1 from its GitHub release archive and install
its CMake modules into $(STAGING_DIR_HOST)/lib/cmake/Corrosion. CMake
projects use them through find_package(Corrosion) and
corrosion_import_crate(). USE_CORROSION is enabled by default with any
Rust toolchain.

With CMake 3.19 or later corrosion builds its generator only for
CORROSION_NATIVE_TOOLING, so the release archive is the whole source.

Signed-off-by: Daniel Golle &lt;daniel@makrotopia.org&gt;
</content>
</entry>
<entry>
<title>tools/cbindgen: add cbindgen host tool</title>
<updated>2026-10-30T10:06:08Z</updated>
<author>
<name>Daniel Golle</name>
</author>
<published>2026-10-08T10:21:09Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=0ced767f14bb7291bdd9f466ffb5969eab33cae2'/>
<id>urn:sha1:0ced767f14bb7291bdd9f466ffb5969eab33cae2</id>
<content type='text'>
Build cbindgen 0.28.0 from a vendor tarball. cbindgen generates C
headers from Rust code and is needed by Mesa for the NIL and NAK
components of the Nouveau driver. USE_CBINDGEN is enabled by default
with any Rust toolchain.

Signed-off-by: Daniel Golle &lt;daniel@makrotopia.org&gt;
</content>
</entry>
<entry>
<title>tools/bindgen: add bindgen-cli host tool</title>
<updated>2026-10-30T10:06:08Z</updated>
<author>
<name>Daniel Golle</name>
</author>
<published>2026-10-08T10:21:09Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=84e70f447eb0b8e70aaf1434b67a54c65a3f46a5'/>
<id>urn:sha1:84e70f447eb0b8e70aaf1434b67a54c65a3f46a5</id>
<content type='text'>
Build bindgen-cli 0.73.2 from a vendor tarball. bindgen loads libclang
from the BPF LLVM toolchain: the prebuilt one unpacked into the source
tree, the one built by tools/llvm-bpf or the host LLVM. Versions before
0.72.1 generate opaque structures together with libclang 22 or newer,
which tools/llvm-bpf provides.

BUILD_BINDGEN is enabled by default with any Rust toolchain and selects
the built LLVM when neither the host nor the prebuilt LLVM is in use.

Signed-off-by: Daniel Golle &lt;daniel@makrotopia.org&gt;
</content>
</entry>
<entry>
<title>tools/rust: add Rust host compiler</title>
<updated>2026-10-30T10:06:08Z</updated>
<author>
<name>Daniel Golle</name>
</author>
<published>2026-10-08T10:21:09Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=429ccec2644e602b68fe5ebf83d9821c6aed191c'/>
<id>urn:sha1:429ccec2644e602b68fe5ebf83d9821c6aed191c</id>
<content type='text'>
Provide rustc, cargo, the host rust-std, rust-src and llvm-tools in
$(STAGING_DIR_HOST) in one of three ways. RUST_TOOLCHAIN_BUILD builds
them from the rustc source tarball with x.py. RUST_TOOLCHAIN_PREBUILT
installs the pinned components from static.rust-lang.org. For
RUST_TOOLCHAIN_HOST the components come from a relocatable toolchain on
the build host, which has to match the Rust version and is checked after
installation. The pinned components cover Linux hosts with glibc or
musl and macOS hosts, on x86_64 and aarch64; other hosts get an error
that names the host.

The choice sits in a "Rust toolchain options" menu of the developer
options, next to the external toolchain options and independent of
them. EXPERIMENTAL defaults to the prebuilt toolchain. As a Kconfig
choice resolves to none while its menu is hidden, USE_RUST_PREBUILT
carries that default in this case.

The xz2 crate of bootstrap is linked statically so that the compiler
needs no host liblzma at run time.

host-build.mk empties MAKEFLAGS for the build; x.py gets the jobserver
of make in MAKEFLAGS, so that bootstrap leaves the job count of ninja
and cargo to it, and one job when make runs without a jobserver.

The LLVM of a Rust release sinks the leading fence of a weak cmpxchg
into the reservation. On the e500v2 of mpc85xx the sync there clears
the reservation, so compare_exchange_weak loops never end. tools/rust
carries the LLVM change of rust/host in the packages feed, and on
mpc85xx the source build is the only choice and the default.

All three ways install into a prefix in one build directory, whose
prepared stamp depends on the choice, and the prefix is copied to
$(STAGING_DIR_HOST). As all three enable the same tool, the stamp of
the tools stage depends on the choice too. The installed files are
recorded in $(STAGING_DIR_HOST)/stamp and removed on clean and before
the next installation. The rust-installer metadata is removed from the
prefix: its manifests name absolute paths, which its uninstall.sh and
a later install.sh into the same prefix delete, those of the build
host's toolchain included.

Cargo reads .cargo/config.toml in every parent directory of its working
directory, and cargo and rustc take settings from the environment. The
build stops when such a file exists in TOPDIR or a parent directory,
and the CARGO, CARGO_* and RUST* variables of the environment are
unexported.

rust-values.mk holds the Rust version, the host triple, the hashes of
the pinned components and the Cargo home. The Cargo home is
$(STAGING_DIR_HOSTPKG)/cargo, shared by all targets, so that $(DL_DIR)
holds downloads only.

The xz2 and LLVM patches, the Rust build recipe and rust-values.mk are
derived from lang/rust in the packages feed by Luca Barbato and Donald
Hoskins.

Suggested-by: Andre Heider &lt;a.heider@gmail.com&gt;
Co-developed-by: Brian Redbeard &lt;redbeard@dead-city.org&gt;
Signed-off-by: Brian Redbeard &lt;redbeard@dead-city.org&gt;
Co-developed-by: Aditya Nugraha &lt;vortexilation@gmail.com&gt;
Signed-off-by: Aditya Nugraha &lt;vortexilation@gmail.com&gt;
Signed-off-by: Daniel Golle &lt;daniel@makrotopia.org&gt;
</content>
</entry>
<entry>
<title>tools/util-linux: remove automake dep</title>
<updated>2025-11-07T20:18:55Z</updated>
<author>
<name>Rosen Penev</name>
</author>
<published>2025-11-07T19:43:37Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=b872421795737e2b8df404fd386b64d964fdd7f1'/>
<id>urn:sha1:b872421795737e2b8df404fd386b64d964fdd7f1</id>
<content type='text'>
In the conversion to meson, this was overlooked.

Fixes e15d5cf7522e: ("tools/util-linux: build with meson")

Signed-off-by: Rosen Penev &lt;rosenp@gmail.com&gt;
Link: https://github.com/openwrt/openwrt/pull/20688
Signed-off-by: Robert Marko &lt;robimarko@gmail.com&gt;
</content>
</entry>
<entry>
<title>tools/elfutils: add maintainer-clean to clean target</title>
<updated>2025-07-26T12:38:08Z</updated>
<author>
<name>Michael Pratt</name>
</author>
<published>2024-09-24T22:50:15Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=c83941d288408308126a6f6bda12eca06a43253c'/>
<id>urn:sha1:c83941d288408308126a6f6bda12eca06a43253c</id>
<content type='text'>
Use the clean recipe during build, so that files already
generated by the bootstrapping within the release are removed
before the bootstrap script is run again.

Automake with modified rules must be ran
in order to generate a Makefile that does delete itself or libtool.

In order to enable rules for building what is removed,
maintainer mode is required for configuring.

Building from tracked sources only with maintainer mode
requires a lexical analyzer, so add dependency for bison.

Override an automake variable "am__CONFIG_DISTCLEAN_FILES"
in order to prevent removing config.status and other configure files
so that configure stage does not need to be ran twice.

The function obstack_printf() is not present on macOS,
so use the available gnulib module and their dependencies.

Many more modules from gnulib are now needed,
and some replacements of some functions must be skipped
to prevent build errors at link time.

Tested-by: Georgi Valkov &lt;gvalkov@gmail.com&gt; # macOS
Signed-off-by: Michael Pratt &lt;mcpratt@pm.me&gt;
Link: https://github.com/openwrt/openwrt/pull/16522
Signed-off-by: Robert Marko &lt;robimarko@gmail.com&gt;
</content>
</entry>
<entry>
<title>tools: require coreutils to build util-linux</title>
<updated>2025-07-26T12:38:08Z</updated>
<author>
<name>Michael Pratt</name>
</author>
<published>2024-09-27T04:20:38Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=7a8fd735489e6d02ecccfe63ffdf7c3694ee8dbc'/>
<id>urn:sha1:7a8fd735489e6d02ecccfe63ffdf7c3694ee8dbc</id>
<content type='text'>
The install stage of util-linux uses the install utility
with GNU options which is provided to macOS by coreutils.

Before, Make coincidentally built them in the right order,
this makes the prerequisite explicit.

Tested-by: Georgi Valkov &lt;gvalkov@gmail.com&gt; # macOS
Signed-off-by: Michael Pratt &lt;mcpratt@pm.me&gt;
Link: https://github.com/openwrt/openwrt/pull/16522
Signed-off-by: Robert Marko &lt;robimarko@gmail.com&gt;
</content>
</entry>
<entry>
<title>tools: require coreutils to build findutils</title>
<updated>2025-07-26T12:38:08Z</updated>
<author>
<name>Michael Pratt</name>
</author>
<published>2024-09-27T05:18:03Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=405652469fc4d8bd589031c39693434be52d39e7'/>
<id>urn:sha1:405652469fc4d8bd589031c39693434be52d39e7</id>
<content type='text'>
The install stage of findutils uses the install utility
with GNU options which is provided to macOS by coreutils.

Before, Make coincidentally built them in the right order,
this makes the prerequisite explicit.

Tested-by: Georgi Valkov &lt;gvalkov@gmail.com&gt; # macOS
Signed-off-by: Michael Pratt &lt;mcpratt@pm.me&gt;
Link: https://github.com/openwrt/openwrt/pull/16522
Signed-off-by: Robert Marko &lt;robimarko@gmail.com&gt;
</content>
</entry>
<entry>
<title>tools: require coreutils to build elfutils</title>
<updated>2025-07-26T12:38:08Z</updated>
<author>
<name>Michael Pratt</name>
</author>
<published>2024-09-27T03:20:38Z</published>
<link rel='alternate' type='text/html' href='https://git.openwrt.org/openwrt/staging/stintel/commit/?id=e776c9fe4ef9823993e230f2795d4255876e5ca2'/>
<id>urn:sha1:e776c9fe4ef9823993e230f2795d4255876e5ca2</id>
<content type='text'>
The version of the rmdir utility in macOS is POSIX-only
while elfutils uses the GNU extended options while building.

Tested-by: Georgi Valkov &lt;gvalkov@gmail.com&gt; # macOS
Signed-off-by: Michael Pratt &lt;mcpratt@pm.me&gt;
Link: https://github.com/openwrt/openwrt/pull/16522
Signed-off-by: Robert Marko &lt;robimarko@gmail.com&gt;
</content>
</entry>
</feed>
