cmake: add Void Linux to recognized package flavors#1424
Open
AndreNijman wants to merge 1 commit into
Open
Conversation
`build.sh -release` aborts on Void Linux with "Unknown Linux package flavor: void" (CMake/pkg.cmake), because Void's /etc/os-release ID is `void` and is not matched by any branch. Void has no native deb/rpm in this packaging flow, so route it to the same TGZ generator already used for Arch (both are source-based distros) and make the comment/status message distro-neutral. This lets users on Void build and install the XRT amdxdna SHIM plugin (e.g. `-nokmod` against the in-tree amdxdna driver on kernel >= 6.14). Signed-off-by: Andre Nijman <andre.perth.2010@gmail.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
Updates Linux packaging logic to treat Void Linux similarly to Arch by generating a TGZ archive instead of DEB/RPM artifacts.
Changes:
- Expand the distro flavor match to include
voidin the TGZ packaging branch. - Update status messaging and comments to reflect Arch/Void behavior.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| set(CPACK_RPM_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/package/prerm") | ||
| endif() | ||
| elseif("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "arch") | ||
| elseif("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "arch|void") |
Comment on lines
+126
to
+128
| # Source-based distros (Arch, Void) have no native deb/rpm in this flow, so we | ||
| # generate a tarball that can be repackaged into a native package (e.g. the | ||
| # provided Arch PKGBUILD, whose install hooks handle post-install/pre-remove). |
Collaborator
|
ok to test |
Collaborator
|
retest this please |
1 similar comment
Collaborator
|
retest this please |
Collaborator
|
@AndreNijman , could you address Copilot review comments? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Add Void Linux to the recognized Linux package flavors in
CMake/pkg.cmake.On Void,
build.sh -releaseaborts at configure time:Void's
/etc/os-releaseIDisvoid(with emptyID_LIKE), so it matched no branch.Fix
Route
voidto the sameTGZgenerator already used for Arch — both aresource-based distros with no native
deb/rpmin this flow — and make thecomment/status message distro-neutral. The behavioral change is one line
(
MATCHES "arch"→MATCHES "arch|void").Validation
Tested on Void Linux (glibc 2.41, kernel 7.0.11, in-tree
amdxdnadriver).With this change
build.sh -release -nokmodconfigures cleanly and producesxrt_plugin.*-amdxdna.tar.gz. Installed alongside an XRT base built from thexrtsubmodule,xrt-smi examinethen enumerates the Phoenix NPU(
RyzenAI-npu1) and mlir-aie example kernels run on it — i.e. the SHIM-onlypath the README documents for kernel >= 6.14 (in-tree driver) now works on Void.
checkpatch.plis not applicable (CMake-only change).