Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save RaymondKroon/b45b5d3f25bc7ee1ccbf9d6bc3a5ca71 to your computer and use it in GitHub Desktop.

Select an option

Save RaymondKroon/b45b5d3f25bc7ee1ccbf9d6bc3a5ca71 to your computer and use it in GitHub Desktop.
Coding session with @RaymondKroon and Copilot CLI - https://github.com/features/copilot/cli

🤖 Copilot CLI Session

Note

  • Session ID: 135143ed-7465-4b1e-915a-3e1edba6673a
  • Started: 4/11/2026, 7:08:34 PM
  • Duration: 80m 13s
  • Exported: 4/11/2026, 8:28:47 PM

⏱️ 2m 9s

👤 User

I need a Fedora 43 (this system) build for https://github.com/amd/xdna-driver Build it with podman and a Dockerfile. The result should be some .rpm file, avaiable in this directory.


⏱️ 2m 14s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora.

/home/raymond/Development/amd/xdna-driver-fedora

6 lines
diff --git a/home/raymond/Development/amd/xdna-driver-fedora b/home/raymond/Development/amd/xdna-driver-fedora
create file mode 100644
index 0000000..0000000
--- a/dev/null
+++ b/home/raymond/Development/amd/xdna-driver-fedora
@@ -1,0 +1,0 @@

⏱️ 2m 14s

glob

/home/raymond/Development/amd/xdna-driver-fedora

"**/*" in /home/raymond/Development/amd/xdna-driver-fedora

No files matched the pattern.

⏱️ 2m 22s

💬 Copilot

I’m checking the upstream repo layout first so I can build it the way the project expects, then I’ll wire that into a Fedora 43 podman build here.


⏱️ 2m 23s

github-mcp-server-get_file_contents

/

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "/"
}
[{"type":"file","size":158,"name":".clangd","path":".clangd","sha":"d275678b52f126ebdf3157d23d28c61573277df0","url":"https://api.github.com/repos/amd/xdna-driver/contents/.clangd?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/blobs/d275678b52f126ebdf3157d23d28c61573277df0","html_url":"https://github.com/amd/xdna-driver/blob/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/.clangd","download_url":"https://raw.githubusercontent.com/amd/xdna-driver/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/.clangd"},{"type":"dir","size":0,"name":".github","path":".github","sha":"f57f1901f0cee3ee644d0e02fdfac15b7cca933f","url":"https://api.github.com/repos/amd/xdna-driver/contents/.github?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/f57f1901f0cee3ee644d0e02fdfac15b7cca933f","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/.github"},{"type":"file","size":95,"name":".gitignore","path":".gitignore","sha":"432ad232e29c476ff0ba4d27d5af721b70d48621","url":"https://api.github.com/repos/amd/xdna-driver/contents/.gitignore?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/blobs/432ad232e29c476ff0ba4d27d5af721b70d48621","html_url":"https://github.com/amd/xdna-driver/blob/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/.gitignore","download_url":"https://raw.githubusercontent.com/amd/xdna-driver/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/.gitignore"},{"type":"file","size":71,"name":".gitmodules","path":".gitmodules","sha":"9cf659f468cb29fc99388d6c54e013116725376e","url":"https://api.github.com/repos/amd/xdna-driver/contents/.gitmodules?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/blobs/9cf659f468cb29fc99388d6c54e013116725376e","html_url":"https://github.com/amd/xdna-driver/blob/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/.gitmodules","download_url":"https://raw.githubusercontent.com/amd/xdna-driver/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/.gitmodules"},{"type":"dir","size":0,"name":"CMake","path":"CMake","sha":"74d0d4c04ca646dd32a4bb3316f880a6e1e6faf6","url":"https://api.github.com/repos/amd/xdna-driver/contents/CMake?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/74d0d4c04ca646dd32a4bb3316f880a6e1e6faf6","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/CMake"},{"type":"file","size":1461,"name":"CMakeLists.txt","path":"CMakeLists.txt","sha":"bb635e8422cadddc6d80de9911cb7123c3402d3a","url":"https://api.github.com/repos/amd/xdna-driver/contents/CMakeLists.txt?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/blobs/bb635e8422cadddc6d80de9911cb7123c3402d3a","html_url":"https://github.com/amd/xdna-driver/blob/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/CMakeLists.txt","download_url":"https://raw.githubusercontent.com/amd/xdna-driver/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/CMakeLists.txt"},{"type":"file","size":1186,"name":"LICENSE.amdnpu","path":"LICENSE.amdnpu","sha":"77e86bde39c0bf75098a0ca6e42b89ac607a4044","url":"https://api.github.com/repos/amd/xdna-driver/contents/LICENSE.amdnpu?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/blobs/77e86bde39c0bf75098a0ca6e42b89ac607a4044","html_url":"https://github.com/amd/xdna-driver/blob/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/LICENSE.amdnpu","download_url":"https://raw.githubusercontent.com/amd/xdna-driver/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/LICENSE.amdnpu"},{"type":"file","size":9137,"name":"README.md","path":"README.md","sha":"bbb5ba6519e335a446376a9eb620a1dbf996bad7","url":"https://api.github.com/repos/amd/xdna-driver/contents/README.md?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/blobs/bbb5ba6519e335a446376a9eb620a1dbf996bad7","html_url":"https://github.com/amd/xdna-driver/blob/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/README.md","download_url":"https://raw.githubusercontent.com/amd/xdna-driver/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/README.md"},{"type":"dir","size":0,"name":"build","path":"build","sha":"a038a0af297226e64775ce03a7912bb780a67191","url":"https://api.github.com/repos/amd/xdna-driver/contents/build?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/a038a0af297226e64775ce03a7912bb780a67191","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/build"},{"type":"dir","size":0,"name":"drivers","path":"drivers","sha":"ee9b2b84912fa655c55211180832df9b033205c1","url":"https://api.github.com/repos/amd/xdna-driver/contents/drivers?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/ee9b2b84912fa655c55211180832df9b033205c1","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/drivers"},{"type":"dir","size":0,"name":"include","path":"include","sha":"cf7b01ee8e39b514745c2a99c8f28a4e4b35ed7e","url":"https://api.github.com/repos/amd/xdna-driver/contents/include?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/cf7b01ee8e39b514745c2a99c8f28a4e4b35ed7e","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/include"},{"type":"dir","size":0,"name":"src","path":"src","sha":"df0c9ae9a913d9634eae1dd72a16d9645097f3f2","url":"https://api.github.com/repos/amd/xdna-driver/contents/src?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/df0c9ae9a913d9634eae1dd72a16d9645097f3f2","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/src"},{"type":"dir","size":0,"name":"test","path":"test","sha":"06159f5bc18eaf7198fc210d86a95ad98eb12480","url":"https://api.github.com/repos/amd/xdna-driver/contents/test?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/06159f5bc18eaf7198fc210d86a95ad98eb12480","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/test"},{"type":"dir","size":0,"name":"tools","path":"tools","sha":"e8bc81731aba7965ba9a9ff7587574d42e3810d6","url":"https://api.github.com/repos/amd/xdna-driver/contents/tools?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/e8bc81731aba7965ba9a9ff7587574d42e3810d6","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/tools"},{"type":"file","size":0,"name":"xrt","path":"xrt","sha":"8bf6286179bc876d0942d5e96a18fe674f8fdd6b","url":"https://api.github.com/repos/amd/xdna-driver/contents/xrt?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/Xilinx/XRT/git/trees/8bf6286179bc876d0942d5e96a18fe674f8fdd6b","html_url":"https://github.com/Xilinx/XRT/tree/8bf6286179bc876d0942d5e96a18fe674f8fdd6b"}]

⏱️ 2m 23s

github-mcp-server-get_file_contents

README.md

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "README.md"
}
186 lines
successfully downloaded text file (SHA: bbb5ba6519e335a446376a9eb620a1dbf996bad7)# AMD XDNA™️ Driver for Linux®️
This repository is for the AMD XDNA™️ Driver (amdxdna.ko) for Linux®️ and XRT SHIM library development.

## Table of Contents
- [Introduction](#introduction)
- [System Requirements](#system-requirements)
- [Linux compilation and installation](#linux-compilation-and-installation)
- [Clone](#clone)
- [Build](#build)
- [Test](#test)
- [Q&A](#qa)
- [Contributor Guidelines](#contributor-guidelines)

## Introduction
This repository is for supporting XRT on AMD XDNA devices. From this repository, you can build a XRT plugin DEB package.
On a machine with XDNA device, with both XRT and XRT plugin packages installed, user can start using XDNA device on Linux.

## System Requirements
To run AI applications, your system needs
* Processor:
  - To run AI applications (test machine): RyzenAI processor
  - To build this repository (build machine): Any x86 processors, but recommend AMD processor :wink:
* Operating System:
  - Ubuntu >= 22.04
  - Arch Linux
* Linux Kernel: v6.10 or above. (See [Linux compilation and installation](#linux-compilation-and-installation))
  - Due to Linux API change, XDNA driver doesn't always keep supporting old version.
* Installed XRT base package (or you can install it along the
  following recipe)
  - To make sure the XRT base package works with the plug-in package, better build it from `xrt` submodule in this repo (`<root-of-source-tree>/xrt`)
  - Refer to https://github.com/Xilinx/XRT for more detailed information.

## Linux compilation and installation

### Ubuntu 25.04

Ubuntu 25.04 includes [Linux kernel 6.14](https://kernelnewbies.org/Linux_6.14) that incorporates the amdxdna driver for AMD NPUs :partying_face:. 

> The XRT SHIM library is still needed from this repository.

### Ubuntu 24.10

Ubuntu 24.10 includes Linux kernel 6.11 that meets the requirements for the xdna-driver. 

### Ubuntu 24.04

If you are using Ubuntu 24.04 you may need to update the Linux kernel. You can update to Linux 6.11 by installing the Hardware Enablement (HWE) stack:

  ```bash
  sudo apt update 
  sudo apt install --install-recommends linux-generic-hwe-24.04
  sudo reboot
  ```

### Ubuntu 22.04

Since Linux v6.10 offically supports AMD IOMMU SVA, we can work with upstream Linux kernel source.
If your system has Linux v6.10 or above installed, check if `CONFIG_AMD_IOMMU` and `CONFIG_DRM_ACCEL` are set. If not, the system is not good for XDNA driver.

If you want to manually build Linux kernel, follow below steps.
```  bash
# Assuming you have knowledge of kernel compilation,
# this is just refreshing up a few key points.

# Clone Linux source code from your favorite repository, for example
git clone --depth=1 --branch v6.10 git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git

# Usually, when people compile kernel from source code, they use current config
cp /boot/config-`uname -r` <your_build_dir>/.config   # (Option step, if you know how to do it better)
# Open <your_build_dir>/.config and add "CONFIG_DRM_ACCEL=y" #Required by XDNA Driver
# Or run instead
scripts/config --file .config --enable DRM_ACCEL
scripts/config --file .config --enable AMD_IOMMU # Option step, if you know this is not set

# Use below command to build kernel packages. Once build is done, DEB packages are at the parent directory of <your_build_dir>
make -j `nproc` bindeb-pkg
# The exact names will depend on your configuration
sudo apt reinstall ../linux-headers-6.10.0_6.10.0-1_amd64.deb ../linux-image-6.10.0_6.10.0-1_amd64.deb ../linux-libc-dev_6.10.0-1_amd64.deb
```

## Clone

```
git clone git@github.com:amd/xdna-driver.git
cd <root-of-source-tree>
# get code for submodules
git submodule update --init --recursive
```

## Build

### Prerequisite

* If this is your first time building this module,
  follow below steps to resolve the dependencies (or at least look at
  the file content if you're not on a distro with apt-get)
``` bash
#requires root permissions to run the script
sudo su
cd <root-of-source-tree>
./tools/amdxdna_deps.sh
# exit from root
exit
```

### Steps to create release build DEB package (Ubuntu/Debian):

``` bash
cd <root-of-source-tree>/build

# If you do not have XRT installed yet:
cd xrt/build
./build.sh -npu -opt
# To adapt according to your OS & version
sudo apt reinstall ./Release/xrt_202510.2.19.0_22.04-amd64-base.deb
cd ../../build

# Start XDNA driver release build and create release DEB package
./build.sh -release

# To adapt according to your OS & version
sudo apt reinstall ./Release/xrt_plugin.2.19.0_ubuntu22.04-x86_64-amdxdna.deb
```

### Steps to create release build packages (Arch Linux):

``` bash
cd <root-of-source-tree>

# Install dependencies (requires sudo)
sudo ./tools/amdxdna_deps.sh

# Get submodules
git submodule update --init --recursive

# Build XRT
cd xrt/build
./build.sh -npu -opt

# Build and install XRT packages using pacman
# PKGBUILDs are in xrt/build/arch/
cd arch
makepkg -p PKGBUILD-xrt-base
sudo pacman -U xrt-base-*.pkg.tar.zst

makepkg -p PKGBUILD-xrt-npu
sudo pacman -U xrt-npu-*.pkg.tar.zst

# Build XDNA driver
cd ../../../build
./build.sh -release

# Build and install XDNA plugin package
cd arch
makepkg -p PKGBUILD-xrt-plugin
sudo pacman -U xrt-plugin-amdxdna-*.pkg.tar.zst

# Configure memory limits (required for NPU access)
# Using limits.d drop-in file (survives package upgrades)
sudo mkdir -p /etc/security/limits.d
sudo tee /etc/security/limits.d/99-amdxdna.conf > /dev/null << 'EOF'
* soft memlock unlimited
* hard memlock unlimited
EOF

# Log out and log back in (or reboot) for memory limit changes to take effect
```

**Note for Arch Linux users**: The build system generates `.tar.gz` packages which are repackaged into proper Arch packages (`.pkg.tar.zst`) using the provided PKGBUILDs:
- XRT packages: `xrt/build/arch/` (PKGBUILD-xrt-base, PKGBUILD-xrt-npu)
- XDNA driver: `build/arch/` directory (PKGBUILD-xrt-plugin)

This ensures proper integration with pacman for installation, upgrades, and removal.

You will find `xrt_plugin.<version>_<distro-version>-<arch>-amdxdna.deb` (Ubuntu/Debian) or `xrt_plugin.<version>_-<arch>-amdxdna.tar.gz` (Arch Linux) in the `Release/` folder. This package includes:
* The `.so` library files, which will be installed into `/opt/xilinx/xrt/lib` folder
* The XDNA driver and DKMS script, which build, install and load
  `amdxdna.ko` driver when installing the .DEB package on target machine
* The firmware binary files, which will be installed to `/usr/lib/firmware/amdnpu` folder

## Test

If you haven't read [System Requirements](#system-requirements), double check it.

``` bash
source /opt/xilinx/xrt/setup.sh
xrt-smi validate
```

## Q&A

### Q: I want to debug my application, how to build library with `-g`?

A: We have debug version of library, which is compiled with `-g` option. You can run `./build.sh -debug` or `./build.sh` which should also create debug DEB package.

### Q: I'm developing amdxdna.ko driver module. How to enable XDNA_DBG() print?

A: XDNA_DBG() relies on Linux's CONFIG_DYNAMIC_DEBUG framework, see Linux's [dynamic debug howto page](https://www.kernel.org/doc/html/v6.8/admin-guide/dynamic-debug-howto.html) for details.
TL;DR, run `sudo insmod amdxdna.ko dyndbg=+pf` to enable XDNA_DBG() globally, where +pf means enable debug printing and print the function name.

### Q: When install XRT plugin DEB package, apt-get/dpkg tool failed. What to do next?

A: Create a debug DEB package, see above question. Then install debug DEB package in your environment. This time, you will have more verbose log. Share this log with us.

### Q: Can I use NPU for accelerate ML training?

A: You can use NPU to accelerate ML inference. But NPU is not designed for ML training.

### Q: How to allocate huge size BO?

A: There is no limit for BO size from the XRT and NPU device.
An application can fail to allocate a huge BO, once it hits the Linux resource limit.
In our test, the "max locked memory" is the key. You can follow below steps to check and change configure.
``` bash
ulimit -l # The result is in kbytes

# Create a drop-in file in /etc/security/limits.d/ (survives package upgrades)
sudo mkdir -p /etc/security/limits.d
sudo tee /etc/security/limits.d/99-amdxdna.conf > /dev/null << 'EOF'
* soft memlock <max-size-in-kbytes>
* hard memlock <max-size-in-kbytes>
EOF
# Use "unlimited" instead of a numeric value if unsure

# Log out and log back in (or reboot), then check if the limit changed
ulimit -l
```

## Contributor Guidelines
1. Read [Getting Started](#getting-started)
2. Read [System Requirements](#system-requirements)
3. Run Linux checkpatch.pl before commit and create pull request, see [Checkpatch](#checkpatch)

### Checkpatch
* There is a pre-commit script to run checkpatch.pl automatically.
``` bash
# How to setup the auto pre-commit check
cd <workspace of this repo>/
cp tools/pre-commit .git/hooks/
```
`git commit` will reject the commit if error/warning is found, until you make `checkpatch.pl` happy.

* There is shell script that scan all the source code in a folder
``` bash
cd <workspace of this repo>/
./tools/codingsty_check.sh <DIR>
```

⏱️ 2m 33s

💬 Copilot

I found the project’s Debian/Arch build flow, but not RPM instructions yet. I’m looking at the upstream build scripts now to see whether Fedora/RPM support already exists or needs a thin packaging layer.


⏱️ 2m 34s

github-mcp-server-get_file_contents

build/build.sh

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "build/build.sh"
}
298 lines
successfully downloaded text file (SHA: e5457ac0c60d48f26fa867095df33cbf22cf5395)#! /bin/bash -

# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2024-2025 AMD, Inc. All rights reserved.

set -euo pipefail

usage()
{
  cat << USAGE_END
Usage: build.sh [options]
Options:
  -help                    Display this help
  -clean                   Clean build directory
  -debug                   Debug build and generate .deb package
  -release                 Release build and generate .deb package
  -j <n>                   Compile parallel (default: num of CPUs)
  -nocmake                 Do not regenerate cmake files
  -install_prefix <path>   Set CMAKE_INSTALL_PREFIX to path
  -verbose                 Enable verbose build
  -hello_umq               Hello UMQ Memory Test
  -dir                     Download directory if apply
  -nokmod                  Don't build or install the kernel module
  -novxdna                 Don't build vxdna library
  -vxdna_test              Build and run vxdna unit tests (-novxdna disable this option)
  -package_legacy_driver   Build package with legacy driver source code (default)
  -package_upstream_driver Build package with upstream driver source code
USAGE_END
}

usage_and_exit()
{
  usage
  exit 1
}

is_not_option_or_empty()
{
  arg=$1

  if [[ "$arg" == "" || "$arg" == -* ]]; then
    return 1
  fi

  return 0
}

build_targets()
{
  BUILD_TYPE=$1
  mkdir -p $BUILD_TYPE
  cd  $BUILD_TYPE
  if [[ $nocmake == 0 ]]; then
    # Some git submodule dir's ownershipt may not be right, fix it
    # so that cmake generation can be done properly
    git config --global --add safe.directory '*'
    time $CMAKE $cmake_extra_flags -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DUMQ_HELLO_TEST=$hello_umq $BUILD_DIR/../
  fi
  time make -j $njobs $verbose DESTDIR=$PWD install

  cd ..
}

package_targets()
{
  BUILD_TYPE=$1

  if [ ! -d $BUILD_TYPE ]; then
    echo "Nothing to be done for $BUILD_TYPE build"
    return
  fi

  cd  $BUILD_TYPE
  time make -j $njobs $verbose DESTDIR=$PWD package

  cd ..
}

download_npufws()
{
  local firmware_dir=${DOWNLOAD_BINS_DIR}/firmware

  jq -c '.firmwares[]' "$INFO_JSON" |
    while IFS= read -r line; do
      local device=$(echo $line | jq -r '.device')
      local pci_dev_id=$(echo $line | jq -r '.pci_device_id')
      local version=$(echo $line | jq -r '.version')
      local fw_name=$(echo $line | jq -r '.fw_name')
      local url=$(echo $line | jq -r '.url')
      local pci_rev_id=$(echo $line | jq -r '.pci_revision_id')

      if [[ -z "$url" ]]; then
        echo "Empty URL for $device NPUFW, SKIP."
        continue
      fi

      echo "Download $device NPUFW version $version:"
      if [ -f "${firmware_dir}/${pci_dev_id}_${pci_rev_id}/$fw_name" ]; then
        rm -r ${firmware_dir}/${pci_dev_id}_${pci_rev_id}
      fi
      mkdir -p ${firmware_dir}/${pci_dev_id}_${pci_rev_id}
      wget -O ${firmware_dir}/${pci_dev_id}_${pci_rev_id}/$fw_name $url

    done
}

download_vtd_archives()
{
  local vtd_dir=${DOWNLOAD_BINS_DIR}/vtd_archives

  jq -c '.vtd_archives[]' "$INFO_JSON" |
    while IFS= read -r line; do
      local device=$(echo $line | jq -r '.device')
      local filename=$(echo $line | jq -r '.filename')
      local url=$(echo $line | jq -r '.url')

      if [[ -z "$url" ]]; then
        echo "Empty URL for $device VTD archive, SKIP."
        continue
      fi

      echo "Download $device VTD archive:"
      if [ -f "${vtd_dir}/$filename" ]; then
        rm ${vtd_dir}/$filename
      fi
      mkdir -p ${vtd_dir}
      wget -O ${vtd_dir}/$filename $url

    done
}

run_vxdna_tests_func()
{
  BUILD_TYPE=$1

  if [[ $build_vxdna == 0 ]]; then
    echo "WARNING: -vxdna_test requires vxdna enabled. Skipping tests."
    return
  fi

  if [ ! -d $BUILD_TYPE ]; then
    echo "Build directory $BUILD_TYPE not found. Skipping tests."
    return
  fi

  echo ""
  echo "========================================"
  echo "Running vxdna unit tests ($BUILD_TYPE)"
  echo "========================================"
  echo ""

  TEST_BINARY="$BUILD_TYPE/src/vxdna/tests/vaccel_tests"

  if [ ! -f "$TEST_BINARY" ]; then
    echo "WARNING: Test binary not found at $TEST_BINARY"
    echo "Make sure BUILD_VXDNA_TESTING was enabled during CMake configuration"
    return 1
  fi

  # Run tests
  if "$TEST_BINARY"; then
    echo ""
    echo "========================================"
    echo "vxdna unit tests PASSED"
    echo "========================================"
    echo ""
    return 0
  else
    RESULT=$?
    echo ""
    echo "========================================"
    echo "vxdna unit tests FAILED"
    echo "========================================"
    echo ""
    return $RESULT
  fi
}

do_build()
{
  BUILD_TYPE=$1
  build_targets $BUILD_TYPE
  if [[ $nocmake == 0 ]]; then
    # No need to download firmware if driver build is skipped
    if [[ $skip_kmod == 0 ]]; then
      download_npufws
    fi
    # Download VTD archives
    download_vtd_archives
    # Prepare xbutil validate related files for packaging
    mkdir -p $XBUTIL_VALIDATE_BINS_DIR
    cp -r ../tools/bins/* $XBUTIL_VALIDATE_BINS_DIR
    package_targets $BUILD_TYPE
  fi

  # Run tests if requested
  if [[ $run_vxdna_tests == 1 ]]; then
    run_vxdna_tests_func $BUILD_TYPE
  fi
}

# Config variables
clean=0
distclean=0
debug=1
release=0
nocmake=0
verbose=
skip_kmod=0
build_vxdna=1
run_vxdna_tests=0
package_legacy_driver=1
njobs=`grep -c ^processor /proc/cpuinfo`
download_dir=
xrt_install_prefix="/opt/xilinx/xrt"
hello_umq=n

while [ $# -gt 0 ]; do
  case "$1" in
    -help | -h)
      usage
      exit 0
      ;;
    -clean | clean)
      clean=1
      ;;
    -distclean | distclean)
      clean=1
      distclean=1
      ;;
    -debug)
      debug=1
      release=0
      ;;
    -release)
      debug=0
      release=1
      ;;
    -j)
      if is_not_option_or_empty $2; then
        njobs=$2
        shift
      fi
      ;;
    -nocmake)
      nocmake=1
      ;;
    -hello_umq)
      hello_umq=y
      ;;
    -verbose)
      verbose=VERBOSE=1
      ;;
    -nokmod)
      skip_kmod=1
      ;;
    -novxdna)
      build_vxdna=0
      ;;
    -vxdna_test)
      run_vxdna_tests=1
      ;;
    -package_legacy_driver)
      package_legacy_driver=1
      ;;
    -package_upstream_driver)
      package_legacy_driver=0
      ;;
    -dir)
      download_dir=$2
      shift
      ;;
    -install_prefix)
      if is_not_option_or_empty $2; then
        xrt_install_prefix=$2
        shift
      fi
      ;;
    *)
      echo "unknown option"
      usage_and_exit
      ;;
  esac
  shift
done

OSDIST=`grep '^ID=' /etc/os-release | awk -F= '{print $2}' | tr -d '"'`
BUILD_DIR=$(readlink -f $(dirname ${BASH_SOURCE[0]}))
DEBUG_BUILD_TYPE=Debug
RELEASE_BUILD_TYPE=Release
CMAKE=cmake
CMAKE_MAJOR_VERSION=`cmake --version | head -n 1 | awk '{print $3}' |awk -F. '{print $1}'`
cmake_extra_flags=""
INFO_JSON=${BUILD_DIR}/../tools/info.json
DOWNLOAD_BINS_DIR=./amdxdna_bins
XBUTIL_VALIDATE_BINS_DIR=$DOWNLOAD_BINS_DIR/download_raw/xbutil_validate/bins

# Sanity check
if [[ $CMAKE_MAJOR_VERSION != 3 ]]; then
    if [[ $OSDIST == "centos" ]] || [[ $OSDIST == "amzn" ]] || [[ $OSDIST == "rhel" ]] || [[ $OSDIST == "fedora" ]]; then
        CMAKE=cmake3
        if [[ ! -x "$(command -v $CMAKE)" ]]; then
            echo "$CMAKE is not installed"
            exit 1
        fi
    fi
fi
# Sanity check end

cmake_extra_flags+=" -DCMAKE_INSTALL_PREFIX=$xrt_install_prefix"
cmake_extra_flags+=" -DSKIP_KMOD=$skip_kmod"
cmake_extra_flags+=" -DBUILD_VXDNA=$build_vxdna"
cmake_extra_flags+=" -DPACKAGE_LEGACY_DRIVER=$package_legacy_driver"
# Enable testing if -vxdna_test flag is provided
if [[ $run_vxdna_tests == 1 ]]; then
  cmake_extra_flags+=" -DBUILD_VXDNA_TESTING=ON"
fi

if [[ ! -z "$download_dir" ]]; then
  echo "Specified download directory is $download_dir"
  DOWNLOAD_BINS_DIR=$download_dir
fi

if [[ $clean == 1 ]]; then
  echo "Only clean the build directory, will not perform other options if apply"
  rm -rf $DEBUG_BUILD_TYPE $RELEASE_BUILD_TYPE
  if [[ $distclean == 1 ]]; then
    rm -rf ${DOWNLOAD_BINS_DIR}
  fi
  exit 0
fi

if [[ $release == 1 ]]; then
  do_build $RELEASE_BUILD_TYPE
fi

if [[ $debug == 1 ]]; then
  do_build $DEBUG_BUILD_TYPE
fi

⏱️ 2m 34s

github-mcp-server-get_file_contents

CMakeLists.txt

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "CMakeLists.txt"
}
34 lines
successfully downloaded text file (SHA: bb635e8422cadddc6d80de9911cb7123c3402d3a)# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2022-2025, Advanced Micro Devices, Inc. All rights reserved.

cmake_minimum_required(VERSION 3.19.0)
project("amd-xdna")
set(PROJECT_DESCRIPTION "AMD XDNA driver and SHIM for Linux")
option(SKIP_KMOD "Building and packaging SHIM without driver and firmware" 1)

set(CMAKE_EXPORT_COMPILE_COMMANDS ON)

if (DEFINED ENV{XRT_PLUGIN_VERSION_PATCH})
  SET(XRT_PLUGIN_VERSION_PATCH $ENV{XRT_PLUGIN_VERSION_PATCH})
else()
  SET(XRT_PLUGIN_VERSION_PATCH 0)
endif()

# Set install component that will be packaged
# Default install compoment will install to shim test area
set(XDNA_COMPONENT "amdxdna")

# Set destination paths in install command
# Relocatable by ${CMAKE_INSTALL_PREFIX}
include (GNUInstallDirs)
set(XDNA_PKG_DIR      .)
set(XDNA_PKG_LIB_DIR  ${XDNA_PKG_DIR}/${CMAKE_INSTALL_LIBDIR})
set(XDNA_PKG_DATA_DIR ${XDNA_PKG_DIR}/${CMAKE_INSTALL_DATADIR}/${XDNA_COMPONENT})
set(XDNA_PKG_INCLUDE_DIR ${XDNA_PKG_DIR}/${CMAKE_INSTALL_INCLUDEDIR})
# Non-relocatable by ${CMAKE_INSTALL_PREFIX}
set(XDNA_PKG_FW_DIR   /usr/lib/firmware/amdnpu)
set(XDNA_BIN_DIR      /bins) # For saving all built artifacts for quick testing
message("-- XDNA_PKG_LIB_DIR=${XDNA_PKG_LIB_DIR}")
message("-- XDNA_PKG_DATA_DIR=${XDNA_PKG_DATA_DIR}")
message("-- XDNA_PKG_FW_DIR=${XDNA_PKG_FW_DIR}")
message("-- XDNA_BIN_DIR=${XDNA_BIN_DIR}")

if (XRT_UPSTREAM)
  include(CMake/upstream.cmake)
else()
  include(CMake/native.cmake)
endif()

⏱️ 2m 35s

github-mcp-server-get_file_contents

build/CMakeLists.txt

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "build/CMakeLists.txt"
}
MCP server 'github-mcp-server': Failed to get file contents. The path does not point to a file or directory, or the file does not exist in the repository.

⏱️ 2m 35s

github-mcp-server-get_file_contents

tools/amdxdna_deps.sh

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "tools/amdxdna_deps.sh"
}
13 lines
successfully downloaded text file (SHA: 9560b8be1b4f9dfe1e14e643f63693b1f1e5b80f)#! /bin/bash -

# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2024-2025, Advanced Micro Devices, Inc.
#

SCRIPT_DIR=$(readlink -f $(dirname ${BASH_SOURCE[0]}))

if [ -x "$(command -v apt-get)" ]; then
    apt-get install -y jq
elif [ -x "$(command -v dnf)" ]; then
    dnf install -y jq
elif [ -x "$(command -v pacman)" ]; then
    pacman -S --needed --noconfirm jq
fi

$SCRIPT_DIR/../xrt/src/runtime_src/tools/scripts/xrtdeps.sh

⏱️ 2m 39s

github-mcp-server-search_code

repo:amd/xdna-driver CPack OR RPM OR DEB OR CPACK path:CMake path:build

Arguments
{
  "query": "repo:amd/xdna-driver CPack OR RPM OR DEB OR CPACK path:CMake path:build"
}
{"total_count":1,"incomplete_results":false,"items":[{"name":"pkg.cmake","path":"CMake/pkg.cmake","sha":"8503acff6edb04724c614e25bac63ce4b3a966cb","html_url":"https://github.com/amd/xdna-driver/blob/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/CMake/pkg.cmake","repository":{"id":747944367,"node_id":"R_kgDOLJS5rw","owner":{"login":"amd","id":430818,"node_id":"MDEyOk9yZ2FuaXphdGlvbjQzMDgxOA==","avatar_url":"https://avatars.githubusercontent.com/u/430818?v=4","html_url":"https://github.com/amd","gravatar_id":"","type":"Organization","site_admin":false,"url":"https://api.github.com/users/amd","events_url":"https://api.github.com/users/amd/events{/privacy}","following_url":"https://api.github.com/users/amd/following{/other_user}","followers_url":"https://api.github.com/users/amd/followers","gists_url":"https://api.github.com/users/amd/gists{/gist_id}","organizations_url":"https://api.github.com/users/amd/orgs","received_events_url":"https://api.github.com/users/amd/received_events","repos_url":"https://api.github.com/users/amd/repos","starred_url":"https://api.github.com/users/amd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amd/subscriptions"},"name":"xdna-driver","full_name":"amd/xdna-driver","html_url":"https://github.com/amd/xdna-driver","fork":false,"private":false,"url":"https://api.github.com/repos/amd/xdna-driver","archive_url":"https://api.github.com/repos/amd/xdna-driver/{archive_format}{/ref}","assignees_url":"https://api.github.com/repos/amd/xdna-driver/assignees{/user}","blobs_url":"https://api.github.com/repos/amd/xdna-driver/git/blobs{/sha}","branches_url":"https://api.github.com/repos/amd/xdna-driver/branches{/branch}","collaborators_url":"https://api.github.com/repos/amd/xdna-driver/collaborators{/collaborator}","comments_url":"https://api.github.com/repos/amd/xdna-driver/comments{/number}","commits_url":"https://api.github.com/repos/amd/xdna-driver/commits{/sha}","compare_url":"https://api.github.com/repos/amd/xdna-driver/compare/{base}...{head}","contents_url":"https://api.github.com/repos/amd/xdna-driver/contents/{+path}","contributors_url":"https://api.github.com/repos/amd/xdna-driver/contributors","deployments_url":"https://api.github.com/repos/amd/xdna-driver/deployments","downloads_url":"https://api.github.com/repos/amd/xdna-driver/downloads","events_url":"https://api.github.com/repos/amd/xdna-driver/events","forks_url":"https://api.github.com/repos/amd/xdna-driver/forks","git_commits_url":"https://api.github.com/repos/amd/xdna-driver/git/commits{/sha}","git_refs_url":"https://api.github.com/repos/amd/xdna-driver/git/refs{/sha}","git_tags_url":"https://api.github.com/repos/amd/xdna-driver/git/tags{/sha}","hooks_url":"https://api.github.com/repos/amd/xdna-driver/hooks","issue_comment_url":"https://api.github.com/repos/amd/xdna-driver/issues/comments{/number}","issue_events_url":"https://api.github.com/repos/amd/xdna-driver/issues/events{/number}","issues_url":"https://api.github.com/repos/amd/xdna-driver/issues{/number}","keys_url":"https://api.github.com/repos/amd/xdna-driver/keys{/key_id}","labels_url":"https://api.github.com/repos/amd/xdna-driver/labels{/name}","languages_url":"https://api.github.com/repos/amd/xdna-driver/languages","merges_url":"https://api.github.com/repos/amd/xdna-driver/merges","milestones_url":"https://api.github.com/repos/amd/xdna-driver/milestones{/number}","notifications_url":"https://api.github.com/repos/amd/xdna-driver/notifications{?since,all,participating}","pulls_url":"https://api.github.com/repos/amd/xdna-driver/pulls{/number}","releases_url":"https://api.github.com/repos/amd/xdna-driver/releases{/id}","stargazers_url":"https://api.github.com/repos/amd/xdna-driver/stargazers","statuses_url":"https://api.github.com/repos/amd/xdna-driver/statuses/{sha}","subscribers_url":"https://api.github.com/repos/amd/xdna-driver/subscribers","subscription_url":"https://api.github.com/repos/amd/xdna-driver/subscription","tags_url":"https://api.github.com/repos/amd/xdna-driver/tags","trees_url":"https://api.github.com/repos/amd/xdna-driver/git/trees{/sha}","teams_url":"https://api.github.com/repos/amd/xdna-driver/teams"}}]}

⏱️ 2m 40s

github-mcp-server-get_file_contents

CMake/native.cmake

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "CMake/native.cmake"
}
28 lines
successfully downloaded text file (SHA: 1a987440723a4926f68739a421d828286cb60322)# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2025, Advanced Micro Devices, Inc. All rights reserved.

# For native xdna-driver builds, XRT headers and link library
# comes from xdna-driver's XRT submodule.

# User can choose to package either legacy driver or upstream driver source
option(PACKAGE_LEGACY_DRIVER "Package legacy driver source" ON)

# By default, build/build.sh downloads binaries to build/amdxdna_bins/
# Absolute path, cannot be used in install command as destination.
set(AMDXDNA_BINS_DIR ${CMAKE_BINARY_DIR}/../amdxdna_bins)

if(XDNA_VE2)

include(${CMAKE_CURRENT_SOURCE_DIR}/CMake/xrt_ve2.cmake)
add_subdirectory(src)

else(XDNA_VE2)

# Bring in xrt git submodule before include any local directories
include(${CMAKE_CURRENT_SOURCE_DIR}/CMake/xrt.cmake)
set(XRT_SUBMOD_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/xrt)
set(XRT_SUBMOD_BINARY_DIR ${CMAKE_CURRENT_BINARY_DIR}/xrt)

# Upstreaming pkg will not have access to .git which is required for version.cmake
if(NOT SKIP_KMOD)
  include(${CMAKE_CURRENT_SOURCE_DIR}/CMake/version.cmake)
endif()

include(${CMAKE_CURRENT_SOURCE_DIR}/CMake/pkg.cmake)

add_subdirectory(src)

if(NOT SKIP_KMOD)
  add_subdirectory(drivers)
  add_subdirectory(test)
endif()

endif(XDNA_VE2)

⏱️ 2m 40s

github-mcp-server-get_file_contents

CMake/upstream.cmake

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "CMake/upstream.cmake"
}
10 lines
successfully downloaded text file (SHA: 4fa5dc2119bb679417afc79fd874cb338e7a31fd)# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2025, Advanced Micro Devices, Inc. All rights reserved.
if (POLICY CMP0177)
  cmake_policy(SET CMP0177 NEW)
endif()

# When building for upstream, only shim plugin library is built
# XRT is part of the upstreaming project and provides the headers
# and targets needed by xdna plugin
set(XRT_PLUGIN_VERSION_STRING ${XRT_VERSION_STRING})
add_subdirectory(src/shim)

⏱️ 2m 43s

github-mcp-server-get_file_contents

CMake/pkg.cmake

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "CMake/pkg.cmake"
}
129 lines
successfully downloaded text file (SHA: 8503acff6edb04724c614e25bac63ce4b3a966cb)# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2023-2026, Advanced Micro Devices, Inc. All rights reserved.

execute_process(
  COMMAND awk -F= "$1==\"ID\" {print $2}" /etc/os-release
  COMMAND tr -d "\""
  OUTPUT_VARIABLE XDNA_CPACK_LINUX_FLAVOR
  OUTPUT_STRIP_TRAILING_WHITESPACE
  )

if ("${XDNA_CPACK_LINUX_FLAVOR}" MATCHES "^(ubuntu)")
  execute_process(
    COMMAND dpkg --print-architecture
    OUTPUT_VARIABLE XDNA_CPACK_ARCH
    OUTPUT_STRIP_TRAILING_WHITESPACE
    )
else("${XDNA_CPACK_LINUX_FLAVOR}" MATCHES "^(ubuntu)")
  execute_process(
    COMMAND uname -m
    OUTPUT_VARIABLE XDNA_CPACK_ARCH
    OUTPUT_STRIP_TRAILING_WHITESPACE
    )
endif("${XDNA_CPACK_LINUX_FLAVOR}" MATCHES "^(ubuntu)")

execute_process(
  COMMAND awk -F= "$1==\"VERSION_ID\" {print $2}" /etc/os-release
  COMMAND tr -d "\""
  OUTPUT_VARIABLE XDNA_CPACK_LINUX_VERSION
  OUTPUT_STRIP_TRAILING_WHITESPACE
  )
if (EXISTS "/etc/arch-release")
  set(XDNA_CPACK_LINUX_PKG_FLAVOR "arch")
else()
  execute_process(
    COMMAND bash -c "source /etc/os-release && echo \"\$ID \$ID_LIKE\""
    OUTPUT_VARIABLE XDNA_CPACK_LINUX_PKG_FLAVOR
    OUTPUT_STRIP_TRAILING_WHITESPACE
    )
endif()
execute_process(
  COMMAND echo ${XRT_VERSION_STRING}
  COMMAND awk -F. "{print $1}"
  OUTPUT_VARIABLE CPACK_PACKAGE_VERSION_MAJOR
  OUTPUT_STRIP_TRAILING_WHITESPACE
  )
execute_process(
  COMMAND echo ${XRT_VERSION_STRING}
  COMMAND awk -F. "{print $2}"
  OUTPUT_VARIABLE CPACK_PACKAGE_VERSION_MINOR
  OUTPUT_STRIP_TRAILING_WHITESPACE
  )

set(XRT_PLUGIN_VERSION_STRING
  ${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${XRT_PLUGIN_VERSION_PATCH})
set(CPACK_SET_DESTDIR ON)
set(CPACK_COMPONENTS_ALL ${XDNA_COMPONENT})
set(CPACK_PACKAGE_VENDOR "AMD Inc")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "XDNA driver plugin for Xilinx RunTime")
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/xrt/LICENSE")
set(CPACK_PACKAGE_CONTACT "max.zhen@amd.com")
set(CPACK_PACKAGE_NAME "xrt_plugin")
set(CPACK_PACKAGE_FILE_NAME
  "${CPACK_PACKAGE_NAME}.${XRT_PLUGIN_VERSION_STRING}_${XDNA_CPACK_LINUX_VERSION}-${XDNA_CPACK_ARCH}")
math(EXPR next_minor "${CPACK_PACKAGE_VERSION_MINOR} + 1")
set(XDNA_CPACK_XRT_BASE_VERSION ${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR})
set(XDNA_CPACK_XRT_BASE_NEXT_VERSION ${CPACK_PACKAGE_VERSION_MAJOR}.${next_minor})

# VTD archives are downloaded by build script based on info.json configuration
set(VTD_ARCHIVES_DIR "${CMAKE_CURRENT_BINARY_DIR}/../amdxdna_bins/vtd_archives")
message(STATUS "Using VTD archives from ${VTD_ARCHIVES_DIR}")

install(DIRECTORY ${VTD_ARCHIVES_DIR}/
  DESTINATION ${XDNA_PKG_DATA_DIR}/bins
  COMPONENT ${XDNA_COMPONENT}
  FILES_MATCHING
  PATTERN "*.a"
  )

if(NOT SKIP_KMOD)

install(DIRECTORY ${AMDXDNA_BINS_DIR}/firmware/
  DESTINATION ${XDNA_PKG_FW_DIR}
  COMPONENT ${XDNA_COMPONENT}
  FILES_MATCHING
  PATTERN "*.sbin"
  PATTERN "download_raw" EXCLUDE
  )

if(XDNA_DRV_INT_SRC_DIR AND XDNA_DRV_INT_NAME)
  set(INT_RMMOD "rmmod ${XDNA_DRV_INT_NAME} > /dev/null 2>&1")
  set(INT_DBG_INSMOD "modprobe ${XDNA_DRV_INT_NAME} dyndbg=+pf")
  set(INT_INSMOD "modprobe ${XDNA_DRV_INT_NAME}")
endif()

configure_file(
  ${CMAKE_CURRENT_SOURCE_DIR}/CMake/config/postinst.in
  ${CMAKE_CURRENT_BINARY_DIR}/package/postinst
  @ONLY
  )
configure_file(
  ${CMAKE_CURRENT_SOURCE_DIR}/CMake/config/prerm.in
  ${CMAKE_CURRENT_BINARY_DIR}/package/prerm
  @ONLY
  )

endif(NOT SKIP_KMOD)

if("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "debian")
  set(CPACK_GENERATOR "DEB")
  set(CPACK_DEB_COMPONENT_INSTALL ON)
  set(CPACK_DEBIAN_PACKAGE_DEPENDS "xrt-base (>= ${XDNA_CPACK_XRT_BASE_VERSION}), xrt-base (<< ${XDNA_CPACK_XRT_BASE_NEXT_VERSION})")
  if(NOT SKIP_KMOD)
    set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_BINARY_DIR}/package/postinst"
      "${CMAKE_CURRENT_BINARY_DIR}/package/prerm")
  endif()
elseif("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "fedora")
  set(CPACK_GENERATOR "RPM")
  set(CPACK_RPM_COMPONENT_INSTALL ON)
  set(CPACK_RPM_PACKAGE_REQUIRES "xrt-base >= ${XDNA_CPACK_XRT_BASE_VERSION}, xrt-base < ${XDNA_CPACK_XRT_BASE_NEXT_VERSION}")
  if(NOT SKIP_KMOD)
    set(CPACK_RPM_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/package/postinst")
    set(CPACK_RPM_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/package/prerm")
  endif()
elseif("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "arch")
  set(CPACK_GENERATOR "TGZ")
  # For Arch Linux, we generate a tarball that can be repackaged into a proper
  # Arch package using the provided PKGBUILD. When using the PKGBUILD, install
  # hooks handle post-install/pre-remove automatically via pacman.
  set(CPACK_ARCHIVE_COMPONENT_INSTALL ON)
  message(STATUS "Arch Linux detected - generating TGZ package")
  if(NOT SKIP_KMOD)
    message(STATUS "Post-install script: ${CMAKE_CURRENT_BINARY_DIR}/package/postinst")
    message(STATUS "Pre-remove script: ${CMAKE_CURRENT_BINARY_DIR}/package/prerm")
    message(STATUS "Note: Use the provided PKGBUILD to create an Arch package with proper install hooks")
  endif()
else()
  message(FATAL_ERROR "Unknown Linux package flavor: ${XDNA_CPACK_LINUX_PKG_FLAVOR}. "
    "Supported distributions: Debian/Ubuntu (deb), Fedora/RHEL (rpm), Arch Linux (TGZ). "
    "To add support for your distribution, please open an issue at https://github.com/amd/xdna-driver/issues")
endif()

include(CPack)

⏱️ 2m 43s

github-mcp-server-search_code

repo:amd/xdna-driver path:CMake/pkg.cmake CPACK_RPM OR RPM OR CPack

Arguments
{
  "query": "repo:amd/xdna-driver path:CMake/pkg.cmake CPACK_RPM OR RPM OR CPack"
}
{"total_count":0,"incomplete_results":false}

⏱️ 2m 52s

💬 Copilot

I found native RPM packaging in the project’s CMake, so this should be a real Fedora build rather than a hand-rolled conversion. I’m setting up a short plan, then I’ll clone and build it in podman and copy the RPM back here.


⏱️ 2m 52s

apply_patch

Arguments
"*** Begin Patch\n*** Add File: /home/raymond/.copilot/session-state/135143ed-7465-4b1e-915a-3e1edba6673a/plan.md\n+Problem: Build the upstream amd/xdna-driver project on Fedora 43 using podman and a Dockerfile, and leave the resulting RPM artifact in the current working directory.\n+\n+Approach:\n+1. Clone the upstream repository with submodules into the working directory.\n+2. Add a Fedora 43 Dockerfile that installs the build dependencies and runs the project's native release packaging flow.\n+3. Build the container image with podman, extract the generated RPM artifact from the container, and place it in the current directory.\n+\n+Notes:\n+- The upstream project already supports Fedora RPM packaging through CPack in CMake/pkg.cmake.\n+- The build may need XRT submodule dependencies resolved through the repo's dependency scripts.\n+- Only build-related files should be added to this directory; the RPM artifact is the required deliverable.\n*** End Patch\n"
Added 1 file(s): /home/raymond/.copilot/session-state/135143ed-7465-4b1e-915a-3e1edba6673a/plan.md

⏱️ 2m 56s

sql

Insert build todos

Arguments
{
  "description": "Insert build todos",
  "query": "INSERT INTO todos (id, title, description, status) VALUES\n  ('clone-upstream-repo', 'Clone upstream repo', 'Clone amd/xdna-driver with submodules into the working directory so the native build scripts and XRT submodule are available.', 'pending'),\n  ('create-fedora-dockerfile', 'Create Fedora Dockerfile', 'Add a Fedora 43 Dockerfile that installs build dependencies and runs the project release packaging flow inside podman.', 'pending'),\n  ('build-and-extract-rpm', 'Build and extract RPM', 'Build the container image with podman, run or inspect it to obtain the generated RPM, and place that RPM in the current working directory.', 'pending');\nINSERT INTO todo_deps (todo_id, depends_on) VALUES\n  ('create-fedora-dockerfile', 'clone-upstream-repo'),\n  ('build-and-extract-rpm', 'create-fedora-dockerfile');"
}
5 lines
Executed 2 statement(s):

1. INSERT
   3 row(s) inserted. Last inserted row ID: 3.

2. INSERT
   2 row(s) inserted. Last inserted row ID: 2.

⏱️ 2m 59s

sql

Start clone todo

Arguments
{
  "description": "Start clone todo",
  "query": "UPDATE todos SET status = 'in_progress' WHERE id = 'clone-upstream-repo';"
}
1 row(s) updated.

⏱️ 3m 15s

bash

Check podman and clone repo

$ set -euo pipefail && podman --version && git --version && git clone --recurse-submodules https://github.com/amd/xdna-driver.git repo

9 lines
Output too large to read at once (197.8 KB). Saved to: /tmp/copilot-tool-output-1775927496426-ne4by2.txt
Consider using tools like grep (for searching), head/tail (for viewing start/end), view with view_range (for specific sections), or jq (for JSON) to examine portions of the output.

Preview (first 500 chars):
podman version 5.8.1
git version 2.53.0
Cloning into 'repo'...
remote: Enumerating objects: 10788, done.
remote: Counting objects:   0% (1/718)remote: Counting objects:   1% (8/718)remote: Counting objects:   2% (15/718)remote: Counting objects:   3% (22/718)remote: Counting objects:   4% (29/718)remote: Counting objects:   5% (36/718)remote: Counting objects:   6% (44/718)remote: Counting objects:   7% (51/718)remote: Counting objects:   8% (58/718)remote: Counting objects:   9% (65/718)remote:
<exited with exit code 0>

⏱️ 3m 23s

💬 Copilot

The repo is in place with submodules. I’m narrowing this to the minimal Fedora container recipe that matches the project’s own packaging flow, so the RPM comes from upstream CPack support.


⏱️ 3m 23s

sql

Finish clone todo

Arguments
{
  "description": "Finish clone todo",
  "query": "UPDATE todos SET status = 'done' WHERE id = 'clone-upstream-repo'; UPDATE todos SET status = 'in_progress' WHERE id = 'create-fedora-dockerfile';"
}
5 lines
Executed 2 statement(s):

1. UPDATE
   1 row(s) updated.

2. UPDATE
   1 row(s) updated.

⏱️ 3m 23s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo

Arguments
{
  "pattern": "xrtdeps|fedora|dnf|cmake3|CPACK_GENERATOR|RPM",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo",
  "output_mode": "content",
  "glob": "**/*.{sh,cmake,txt,spec}",
  "-n": true,
  "head_limit": 200
}
8 lines
Output too large to read at once (26.6 KB). Saved to: /tmp/copilot-tool-output-1775927517556-flt1qk.txt
Consider using tools like grep (for searching), head/tail (for viewing start/end), view with view_range (for specific sections), or jq (for JSON) to examine portions of the output.

Preview (first 500 chars):
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake:109:  set(CPACK_GENERATOR "DEB")
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake:116:elseif("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "fedora")
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake:117:  set(CPACK_GENERATOR "RPM")
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake:118:  set(CPACK_RPM_COMPONENT_INSTALL ON)
/home/raymond/Development/amd/xdna-driver-fedora/r

⏱️ 3m 23s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/tools/amdxdna_deps.sh.

/home/raymond/Development/amd/xdna-driver-fedora/repo/tools/amdxdna_deps.sh

18 lines
1. #! /bin/bash -
2. 
3. # SPDX-License-Identifier: Apache-2.0
4. # Copyright (C) 2024-2025, Advanced Micro Devices, Inc.
5. #
6. 
7. SCRIPT_DIR=$(readlink -f $(dirname ${BASH_SOURCE[0]}))
8. 
9. if [ -x "$(command -v apt-get)" ]; then
10.     apt-get install -y jq
11. elif [ -x "$(command -v dnf)" ]; then
12.     dnf install -y jq
13. elif [ -x "$(command -v pacman)" ]; then
14.     pacman -S --needed --noconfirm jq
15. fi
16. 
17. $SCRIPT_DIR/../xrt/src/runtime_src/tools/scripts/xrtdeps.sh
18.

⏱️ 3m 23s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh.

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh

File too large to read at once (21.4 KB). Consider using the grep tool to search within the file, or view with view_range to read specific sections.

⏱️ 3m 27s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh

Arguments
{
  "pattern": "fedora|rhel|dnf install|cmake3|gcc-c\\+\\+|rpm-build|dkms|libdrm|boost|python3",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh",
  "output_mode": "content",
  "-n": true,
  "-C": 3,
  "head_limit": 300
}
8 lines
Output too large to read at once (50.9 KB). Saved to: /tmp/copilot-tool-output-1775927521778-wq3j5m.txt
Consider using tools like grep (for searching), head/tail (for viewing start/end), view with view_range (for specific sections), or jq (for JSON) to examine portions of the output.

Preview (first 500 chars):
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh-57-rh_package_list()
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh-58-{
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh-59-    RH_LIST=(\
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:60:     boost-devel \
/home/raymond/Development/amd/xdna-dri

⏱️ 3m 27s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo

Arguments
{
  "pattern": "xrt-base|rpm|package|cpack",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo",
  "output_mode": "content",
  "glob": "**/*.{cmake,txt,sh,spec}",
  "-n": true,
  "head_limit": 200
}
7 lines
Output too large to read at once (82.2 KB). Saved to: /tmp/copilot-tool-output-1775927521778-i0pkjw.txt
Consider using tools like grep (for searching), head/tail (for viewing start/end), view with view_range (for specific sections), or jq (for JSON) to examine portions of the output.

Preview (first 500 chars):
/home/raymond/Development/amd/xdna-driver-fedora/repo/src/vxdna/tests/CMakeLists.txt:8:# Find GTest package
/home/raymond/Development/amd/xdna-driver-fedora/repo/src/vxdna/tests/CMakeLists.txt:9:find_package(GTest REQUIRED)
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMakeLists.txt:17:# Set install component that will be packaged
/home/raymond/Development/amd/xdna-driver-fedora/repo/drivers/accel/CMakeLists.txt:65:  # When legacy driver is packaged, we become the "legacy" ko for CI tes

⏱️ 3m 31s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh.

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh (lines 1-220)

220 lines
1. #!/bin/bash
2. 
3. # SPDX-License-Identifier: Apache-2.0
4. # Copyright (C) 2019-2021 Xilinx, Inc. All rights reserved.
5. #
6. 
7. FLAVOR=`grep '^ID=' /etc/os-release | awk -F= '{print $2}' | tr -d '"'`
8. VERSION=`grep '^VERSION_ID=' /etc/os-release | awk -F= '{print $2}' | tr -d '"'`
9. MAJOR=${VERSION%.*}
10. ARCH=`uname -m`
11. 
12. usage()
13. {
14.     echo "Usage: xrtdeps.sh [options]"
15.     echo
16.     echo "[-help]                    List this help"
17.     echo "[-validate]                Validate that required packages are installed"
18.     echo "[-docker]                  Indicate that script is run within a docker container, disables select packages"
19.     echo "[-sysroot]                 Indicate that script is run to prepare sysroot, disables select packages"
20. 
21.     exit 1
22. }
23. 
24. validate=0
25. docker=0
26. sysroot=0
27. ds9=0
28. 
29. while [ $# -gt 0 ]; do
30.     case "$1" in
31.         -help)
32.             usage
33.             ;;
34.         -validate)
35.             validate=1
36.             shift
37.             ;;
38.         -docker)
39.             docker=1
40.             shift
41.             ;;
42.         -sysroot)
43.             sysroot=1
44.             shift
45.             ;;
46.         -ds9)
47.             ds9=1
48.             shift
49.             ;;
50.         *)
51.             echo "unknown option"
52.             usage
53.             ;;
54.     esac
55. done
56. 
57. rh_package_list()
58. {
59.     RH_LIST=(\
60.      boost-devel \
61.      boost-filesystem \
62.      boost-program-options \
63.      boost-static \
64.      cmake \
65.      curl \
66.      dkms \
67.      elfutils-devel \
68.      elfutils-libs \
69.      gcc \
70.      gcc-c++ \
71.      gdb \
72.      git \
73.      glibc-static \
74.      gnutls-devel \
75.      gtest-devel \
76.      json-glib-devel \
77.      libcurl-devel \
78.      libdrm-devel \
79.      libffi-devel \
80.      libjpeg-turbo-devel \
81.      libstdc++-static \
82.      libtiff-devel \
83.      libuuid-devel \
84.      libyaml-devel \
85.      lm_sensors \
86.      make \
87.      ncurses-devel \
88.      ocl-icd \
89.      ocl-icd-devel \
90.      opencl-headers \
91.      openssl-devel \
92.      pciutils \
93.      perl \
94.      pkgconfig \
95.      protobuf-compiler \
96.      protobuf-devel \
97.      python3 \
98.      python3-pip \
99.      python3-devel \
100.      rapidjson-devel \
101.      rpm-build \
102.      strace \
103.      systemtap-sdt-devel \
104.      unzip \
105.      zlib-static \
106.     )
107. 
108.     if  [ "$MAJOR" -lt 10 ]; then
109.         RH_LIST+=(\
110. 	    cppcheck \
111. 	    gnuplot\
112.         )
113.     fi
114.     if [ $FLAVOR == "amzn" ]; then
115.         RH_LIST+=(\
116.         system-lsb-core \
117.         compat-libtiff3 \
118.         )
119.     elif [ $MAJOR -le 8 ]; then
120.         RH_LIST+=(\
121.         redhat-lsb \
122.         compat-libtiff3 \
123.         )
124.     fi
125. 
126.     if [ $MAJOR -ge 8 ]; then
127. 
128.         RH_LIST+=(\
129.           systemd-devel \
130.           libarchive \
131.           )
132. 
133.         if [ $FLAVOR == "rhel" ]; then
134.             RH_LIST+=(\
135.               opencv \
136.             )
137.         fi
138. 
139.     else
140. 
141.         RH_LIST+=(\
142.          libpng12-devel \
143.          libudev-devel \
144.          opencv \
145.          openssl-static \
146.          protobuf-static \
147.         )
148. 
149.     fi
150. 
151.     if [ $docker == 0 ]; then
152.         if [ $FLAVOR == "centos" ]; then
153.         # In CentOs kernel-devel and headers with $(uname -r) version
154.         # are not available always which causes xrtdeps to fail if we
155.         # include these packages with specific version.
156.             RH_LIST+=(\
157.               kernel-devel \
158.               kernel-headers \
159.             )
160.         else
161.             RH_LIST+=(\
162.               kernel-devel-$(uname -r) \
163.               kernel-headers-$(uname -r) \
164.             )
165.         fi
166.     fi
167. 
168.     #dmidecode is only applicable for x86_64
169.     if [ $ARCH == "x86_64" ]; then
170.         RH_LIST+=( dmidecode )
171.     fi
172. }
173. 
174. ub_package_list()
175. {
176.     UB_LIST=(\
177.      cmake \
178.      cppcheck \
179.      curl \
180.      dkms \
181.      file \
182.      g++ \
183.      gcc \
184.      gdb \
185.      git \
186.      gnuplot \
187.      graphviz \
188.      libboost-dev \
189.      libboost-filesystem-dev \
190.      libboost-program-options-dev \
191.      libcurl4-openssl-dev \
192.      libdrm-dev \
193.      libdw-dev \
194.      libelf-dev \
195.      libffi-dev \
196.      libgtest-dev \
197.      libjpeg-dev \
198.      libjson-glib-dev \
199.      libncurses5-dev \
200.      libopencv-core-dev \
201.      libpng-dev \
202.      libprotoc-dev \
203.      libssl-dev \
204.      libsystemd-dev \
205.      libtiff5-dev \
206.      libudev-dev \
207.      libyaml-dev \
208.      linux-libc-dev \
209.      lm-sensors \
210.      lsb-release \
211.      make \
212.      ocl-icd-dev \
213.      ocl-icd-libopencl1 \
214.      ocl-icd-opencl-dev \
215.      opencl-headers \
216.      pciutils \
217.      perl \
218.      rapidjson-dev \
219.      pkg-config \
220.      protobuf-compiler \

⏱️ 3m 31s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake.

/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake (lines 100-140)

41 lines
100. configure_file(
101.   ${CMAKE_CURRENT_SOURCE_DIR}/CMake/config/prerm.in
102.   ${CMAKE_CURRENT_BINARY_DIR}/package/prerm
103.   @ONLY
104.   )
105. 
106. endif(NOT SKIP_KMOD)
107. 
108. if("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "debian")
109.   set(CPACK_GENERATOR "DEB")
110.   set(CPACK_DEB_COMPONENT_INSTALL ON)
111.   set(CPACK_DEBIAN_PACKAGE_DEPENDS "xrt-base (>= ${XDNA_CPACK_XRT_BASE_VERSION}), xrt-base (<< ${XDNA_CPACK_XRT_BASE_NEXT_VERSION})")
112.   if(NOT SKIP_KMOD)
113.     set(CPACK_DEBIAN_PACKAGE_CONTROL_EXTRA "${CMAKE_CURRENT_BINARY_DIR}/package/postinst"
114.       "${CMAKE_CURRENT_BINARY_DIR}/package/prerm")
115.   endif()
116. elseif("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "fedora")
117.   set(CPACK_GENERATOR "RPM")
118.   set(CPACK_RPM_COMPONENT_INSTALL ON)
119.   set(CPACK_RPM_PACKAGE_REQUIRES "xrt-base >= ${XDNA_CPACK_XRT_BASE_VERSION}, xrt-base < ${XDNA_CPACK_XRT_BASE_NEXT_VERSION}")
120.   if(NOT SKIP_KMOD)
121.     set(CPACK_RPM_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/package/postinst")
122.     set(CPACK_RPM_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/package/prerm")
123.   endif()
124. elseif("${XDNA_CPACK_LINUX_PKG_FLAVOR}" MATCHES "arch")
125.   set(CPACK_GENERATOR "TGZ")
126.   # For Arch Linux, we generate a tarball that can be repackaged into a proper
127.   # Arch package using the provided PKGBUILD. When using the PKGBUILD, install
128.   # hooks handle post-install/pre-remove automatically via pacman.
129.   set(CPACK_ARCHIVE_COMPONENT_INSTALL ON)
130.   message(STATUS "Arch Linux detected - generating TGZ package")
131.   if(NOT SKIP_KMOD)
132.     message(STATUS "Post-install script: ${CMAKE_CURRENT_BINARY_DIR}/package/postinst")
133.     message(STATUS "Pre-remove script: ${CMAKE_CURRENT_BINARY_DIR}/package/prerm")
134.     message(STATUS "Note: Use the provided PKGBUILD to create an Arch package with proper install hooks")
135.   endif()
136. else()
137.   message(FATAL_ERROR "Unknown Linux package flavor: ${XDNA_CPACK_LINUX_PKG_FLAVOR}. "
138.     "Supported distributions: Debian/Ubuntu (deb), Fedora/RHEL (rpm), Arch Linux (TGZ). "
139.     "To add support for your distribution, please open an issue at https://github.com/amd/xdna-driver/issues")
140. endif()

⏱️ 3m 36s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/xrt.cmake.

/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/xrt.cmake (lines 1-260)

40 lines
1. # SPDX-License-Identifier: Apache-2.0
2. # Copyright (C) 2023-2025, Advanced Micro Devices, Inc. All rights reserved.
3. 
4. # Bring in XRT git submodule and exclude parts of XRT we don't need
5. set(XRT_EXCLUDE_SUB_DIRECTORY
6.   src/runtime_src/core/pcie/emulation
7.   src/runtime_src/core/pcie/windows
8.   src/runtime_src/core/pcie/driver
9.   src/runtime_src/core/pcie/tools
10.   src/runtime_src/core/pcie/noop
11. 
12.   src/runtime_src/core/tools
13.   src/runtime_src/core/edge
14. 
15.   src/runtime_src/tools
16.   src/runtime_src/xocl
17.   src/runtime_src/ert
18.   src/runtime_src/xrt
19. 
20.   tests/validate
21.   )
22. 
23. # Instruct XRT to build the npu component
24. set(XRT_NPU 1)
25. # To be removed when controlled by XDP with XRT_NPU
26. set(XDP_CLIENT_BUILD_CMAKE "yes")
27. 
28. set(XRT_EXCLUDE_INCLUDE_FILE
29.   src/CMake/nativeTests.cmake
30.   )
31. 
32. set(XDP_CLIENT_BUILD_CMAKE "yes")
33. 
34. set(XDNA_XRT_DIR xrt/src)
35. 
36. set(XRT_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/${XDNA_XRT_DIR}")
37. set(XRT_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}/${XDNA_XRT_DIR}")
38. 
39. add_subdirectory(${XDNA_XRT_DIR} EXCLUDE_FROM_ALL)
40.

⏱️ 3m 36s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo

Arguments
{
  "pattern": "xrt-base|xrt/build|add_subdirectory\\(xrt|ExternalProject|find_package\\(XRT|XRT_VERSION_STRING",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo",
  "output_mode": "content",
  "glob": "**/*.{cmake,sh,txt}",
  "-n": true,
  "head_limit": 200
}
7 lines
Output too large to read at once (20.2 KB). Saved to: /tmp/copilot-tool-output-1775927530912-2q5z7o.txt
Consider using tools like grep (for searching), head/tail (for viewing start/end), view with view_range (for specific sections), or jq (for JSON) to examine portions of the output.

Preview (first 500 chars):
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/upstream.cmake:10:set(XRT_PLUGIN_VERSION_STRING ${XRT_VERSION_STRING})
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake:41:  COMMAND echo ${XRT_VERSION_STRING}
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake:47:  COMMAND echo ${XRT_VERSION_STRING}
/home/raymond/Development/amd/xdna-driver-fedora/repo/CMake/pkg.cmake:111:  set(CPACK_DEBIAN_PACKAGE_DEPENDS "xrt-base (>= ${XDNA_CPACK_XRT_BASE_VERS

⏱️ 3m 50s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh.

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh (lines 220-420)

201 lines
220.      protobuf-compiler \
221.      python3 \
222.      libpython3-dev \
223.      python3-breathe \
224.      python3-pip \
225.      python3-sphinx \
226.      python3-sphinx-rtd-theme \
227.      sphinx-common \
228.      strace \
229.      systemtap-sdt-dev \
230.      unzip \
231.      uuid-dev \
232.     )
233. 
234.     if [ $docker == 0 ] && [ $sysroot == 0 ]; then
235.         UB_LIST+=(linux-headers-$(uname -r))
236.     fi
237. 
238.     #dmidecode is only applicable for x86_64
239.     if [ $ARCH == "x86_64" ]; then
240.         UB_LIST+=( dmidecode )
241.     fi
242. 
243.     # Use GCC8 on ARM64 Ubuntu as GCC7 randomly crashes with Internal Compiler Error on
244.     # Travis CI ARM64 platform
245.     if [ $ARCH == "aarch64" ]; then
246.         UB_LIST+=( gcc-8 )
247.         UB_LIST+=( g++-8 )
248.     fi
249. 
250. }
251. 
252. fd_package_list()
253. {
254.     FD_LIST=(\
255.      boost-devel \
256.      boost-filesystem \
257.      boost-program-options \
258.      boost-static \
259.      cmake \
260.      cppcheck \
261.      curl \
262.      dkms \
263.      dmidecode \
264.      elfutils-devel \
265.      elfutils-libs \
266.      gcc \
267.      gcc-c++ \
268.      gdb \
269.      git \
270.      glibc-static \
271.      gnuplot \
272.      gnutls-devel \
273.      gtest-devel \
274.      json-glib-devel \
275.      libcurl-devel \
276.      libdrm-devel \
277.      libffi-devel \
278.      libjpeg-turbo-devel \
279.      libpng12-devel \
280.      libstdc++-static \
281.      libtiff-devel \
282.      libudev-devel \
283.      libuuid-devel \
284.      libyaml-devel \
285.      lm_sensors \
286.      make \
287.      ncurses-devel \
288.      ocl-icd \
289.      ocl-icd-devel \
290.      opencl-headers \
291.      opencv \
292.      openssl-devel \
293.      pciutils \
294.      perl \
295.      pkgconf-pkg-config \
296.      protobuf-compiler \
297.      protobuf-devel \
298.      python3 \
299.      python3-devel \
300.      python3-pip \
301.      python3-sphinx \
302.      redhat-lsb \
303.      rapidjson-devel \
304.      rpm-build \
305.      strace \
306.      systemd-devel \
307.      systemtap-sdt-devel \
308.      unzip \
309.      zlib-static \
310.     )
311. 
312.     if [ $docker == 0 ]; then
313.         FD_LIST+=(\
314.           kernel-devel-$(uname -r) \
315.           kernel-headers \
316.         )
317.     fi
318. }
319. 
320. 
321. suse_package_list()
322. {
323.    SUSE_LIST=(\
324.      cmake \
325.      curl \
326.      dkms \
327.      dmidecode \
328.      gcc \
329.      gcc-c++ \
330.      gdb \
331.      git-core \
332.      glibc-devel-static \
333.      gnuplot \
334.      json-glib-devel \
335.      kernel-devel \
336.      kernel-devel \
337.      libboost_filesystem1_66_0-devel \
338.      libboost_program_options1_66_0-devel \
339.      libcurl-devel \
340.      libdrm-devel \
341.      libgnutls-devel \
342.      libjpeg8-devel \
343.      libopenssl-devel \
344.      libpng12-devel \
345.      libtiff-devel \
346.      libudev-devel \
347.      libuuid-devel \
348.      libxml2-devel \
349.      libyaml-devel \
350.      lsb-release \
351.      make \
352.      ncurses-devel \
353.      opencl-cpp-headers \
354.      pciutils \
355.      perl \
356.      pkg-config \
357.      protobuf-devel \
358.      python3-devel \
359.      python3-pip \
360.      rpm-build \
361.      strace \
362.      systemtap-sdt-devel \
363.      unzip \
364.      zlib-devel-static \
365.    )
366. }
367. 
368. mariner_package_list()
369. {
370.     MN_LIST=(\
371.      binutils \
372.      boost-devel \
373.      boost-static \
374.      cmake \
375.      cppcheck \
376.      curl \
377.      dkms \
378.      elfutils-devel \
379.      elfutils-libs \
380.      gcc \
381.      gcc-c++ \
382.      gdb \
383.      git \
384.      glibc-static \
385.      gmock-devel \
386.      gnuplot \
387.      gnutls-devel \
388.      gtest-devel \
389.      json-glib-devel \
390.      libcurl-devel \
391.      libdrm-devel \
392.      libffi-devel \
393.      libjpeg-turbo-devel \
394.      libpng12-devel \
395.      libstdc++-static \
396.      libtiff-devel \
397.      libudev-devel \
398.      libuuid-devel \
399.      libyaml-devel \
400.      lm_sensors \
401.      lsb-release \
402.      make \
403.      ncurses-devel \
404.      ocl-icd \
405.      ocl-icd-devel \
406.      opencl-headers \
407.      openssl-devel \
408.      openssl-static \
409.      pciutils \
410.      perl \
411.      pkgconfig \
412.      protobuf-compiler \
413.      protobuf-devel \
414.      protobuf-static \
415.      python3 \
416.      python3-pip \
417.      python3-devel \
418.      rapidjson-devel \
419.      rpm-build \
420.      strace \

⏱️ 3m 50s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh.

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh (lines 420-620)

201 lines
420.      strace \
421.      unzip \
422.      zlib-static \
423.     )
424. }
425. 
426. arch_package_list()
427. {
428.     ARCH_LIST=(\
429.      base-devel \
430.      boost \
431.      cmake \
432.      cppcheck \
433.      curl \
434.      dkms \
435.      elfutils \
436.      gcc \
437.      gdb \
438.      git \
439.      gnuplot \
440.      graphviz \
441.      gtest \
442.      json-glib \
443.      libdrm \
444.      libffi \
445.      libjpeg-turbo \
446.      libpng \
447.      libtiff \
448.      libyaml \
449.      lm_sensors \
450.      lsb-release \
451.      ncurses \
452.      ocl-icd \
453.      opencl-headers \
454.      openssl \
455.      pciutils \
456.      perl \
457.      pkgconf \
458.      protobuf \
459.      python \
460.      python-pip \
461.      python-sphinx \
462.      python-breathe \
463.      python-sphinx_rtd_theme \
464.      rapidjson \
465.      strace \
466.      systemtap \
467.      unzip \
468.      wget \
469.     )
470. 
471.     if [ $docker == 0 ] && [ $sysroot == 0 ]; then
472.         ARCH_LIST+=(linux-headers)
473.     fi
474. 
475.     #dmidecode is only applicable for x86_64
476.     if [ $ARCH == "x86_64" ]; then
477.         ARCH_LIST+=( dmidecode )
478.     fi
479. }
480. 
481. update_package_list()
482. {
483.     if [ $FLAVOR == "ubuntu" ] || [ $FLAVOR == "debian" ] || [ $FLAVOR == "linuxmint" ]; then
484.         ub_package_list
485.     elif [ $FLAVOR == "centos" ] || [ $FLAVOR == "rhel" ] || [ $FLAVOR == "amzn" ] || [ $FLAVOR == "almalinux" ] || [ $FLAVOR == "rocky" ]; then
486.         rh_package_list
487.     elif [ $FLAVOR == "fedora" ]; then
488.         fd_package_list
489.     elif [ $FLAVOR == "sles" ]; then
490.         suse_package_list
491.     elif [ $FLAVOR == "mariner" ]; then
492.         mariner_package_list
493.     elif [ $FLAVOR == "arch" ]; then
494.         arch_package_list
495.     else
496.         echo "unknown OS flavor $FLAVOR"
497.         exit 1
498.     fi
499. }
500. 
501. validate()
502. {
503.     if [ $FLAVOR == "ubuntu" ] || [ $FLAVOR == "debian" ] || [ $FLAVOR == "linuxmint" ]; then
504.         #apt-get -qq list "${UB_LIST[@]}"
505.         dpkg -l "${UB_LIST[@]}" > /dev/null
506.         if [ $? == 0 ] ; then
507.             # Validate we have OpenCL 2.X headers installed
508.             dpkg-query -s opencl-headers | grep '^Version: 2\.'
509.         fi
510.     fi
511. 
512.     if [ $FLAVOR == "centos" ] || [ $FLAVOR == "rhel" ] || [ $FLAVOR == "amzn" ] || [ $FLAVOR == "almalinux" ] || [ $FLAVOR == "rocky" ] ; then
513.         rpm -q "${RH_LIST[@]}"
514.         if [ $? == 0 ] ; then
515.             # Validate we have OpenCL 2.X headers installed
516.             rpm -q -i opencl-headers | grep '^Version' | grep ': 2\.'
517.         fi
518.     fi
519. 
520.     if [ $FLAVOR == "sles" ]; then
521.         rpm -q "${SUSE_LIST[@]}"
522.         if [ $? == 0 ] ; then
523.             # Validate we have OpenCL 2.X headers installed
524.             rpm -q -i opencl-headers | grep '^Version' | grep ': 2\.'
525.         fi
526.     fi
527. 
528.     if [ $FLAVOR == "mariner" ]; then
529.         rpm -q "${MN_LIST[@]}"
530.         if [ $? == 0 ] ; then
531.             # Validate we have OpenCL 2.X headers installed
532.             rpm -q -i opencl-headers | grep '^Version' | grep ': 2\.'
533.         fi
534.     fi
535. 
536. }
537. 
538. prep_ubuntu()
539. {
540.     echo "Preparing ubuntu ..."
541.     # Update the list of available packages
542.     apt-get update
543. }
544. 
545. prep_centos7()
546. {
547.     echo "Enabling EPEL repository..."
548.     rpm -q --quiet epel-release
549.     if [ $? != 0 ]; then
550.         yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
551.         yum check-update
552.     fi
553.     echo "Installing cmake3 from EPEL repository..."
554.     yum install -y cmake3
555.     if [ $docker == 0 ]; then
556.         echo "Enabling CentOS SCL repository..."
557.         yum --enablerepo=extras install -y centos-release-scl
558.     fi
559. }
560. 
561. prep_rhel7()
562. {
563.     echo "Enabling EPEL repository..."
564.     rpm -q --quiet epel-release
565.     if [ $? != 0 ]; then
566.         yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
567.         yum check-update
568.     fi
569. 
570.     echo "Enabling RHEL SCL repository..."
571.     yum-config-manager --enable rhel-server-rhscl-7-rpms
572. 
573.     echo "Enabling repository 'rhel-7-server-optional-rpms'"
574.     subscription-manager repos --enable "rhel-7-server-optional-rpms"
575. }
576. 
577. prep_rhel8()
578. {
579.     echo "Enabling EPEL repository..."
580.     rpm -q --quiet epel-release
581.     if [ $? != 0 ]; then
582.         yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
583.         yum check-update
584.     fi
585. 
586.     echo "Enabling CodeReady-Builder repository..."
587.     subscription-manager repos --enable "codeready-builder-for-rhel-8-x86_64-rpms"
588. }
589. 
590. prep_rhel9()
591. {
592.     echo "Enabling EPEL repository..."
593.     rpm -q --quiet epel-release
594.     if [ $? != 0 ]; then
595.         yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
596.         yum check-update
597.     fi
598. 
599.     echo "Enabling CodeReady-Builder repository..."
600.     subscription-manager repos --enable "codeready-builder-for-rhel-9-x86_64-rpms"
601. }
602. 
603. prep_rhel10()
604. {
605.     echo "Enabling EPEL repository..."
606.     rpm -q --quiet epel-release
607.     if [ $? != 0 ]; then
608.         yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-10.noarch.rpm
609.         yum check-update
610.     fi
611. 
612.     echo "Enabling CodeReady-Builder repository..."
613.     subscription-manager repos --enable "codeready-builder-for-rhel-10-x86_64-rpms"
614. }
615. 
616. prep_centos8()
617. {
618.     echo "Enabling EPEL repository..."
619.     rpm -q --quiet epel-release
620.     if [ $? != 0 ]; then

⏱️ 3m 52s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh

Arguments
{
  "pattern": "dnf install|yum install|apt-get install|pacman -S|zypper",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh",
  "output_mode": "content",
  "-n": true,
  "-C": 2,
  "head_limit": 120
}
7 lines
Output too large to read at once (21.8 KB). Saved to: /tmp/copilot-tool-output-1775927546878-r0lswl.txt
Consider using tools like grep (for searching), head/tail (for viewing start/end), view with view_range (for specific sections), or jq (for JSON) to examine portions of the output.

Preview (first 500 chars):
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh-548-    rpm -q --quiet epel-release
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh-549-    if [ $? != 0 ]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:550:        yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
/home/raymond/Development/amd/xdna-drive

⏱️ 3m 58s

glob

/home/raymond/Development/amd/xdna-driver-fedora

"repo/.github/workflows/*" in /home/raymond/Development/amd/xdna-driver-fedora

No files matched the pattern.

⏱️ 3m 58s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo/.github

Arguments
{
  "pattern": "fedora|rpm|container|podman|docker",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo/.github",
  "output_mode": "content",
  "-n": true,
  "head_limit": 200
}
No matches found.

⏱️ 4m 5s

apply_patch

Arguments
"*** Begin Patch\n*** Add File: /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile\n+FROM fedora:43\n+\n+ENV LANG=C.UTF-8\n+ENV LC_ALL=C.UTF-8\n+\n+WORKDIR /work/xdna-driver\n+\n+COPY repo/ /work/xdna-driver/\n+\n+RUN dnf install -y --setopt=install_weak_deps=False jq && \\\n+    ./xrt/src/runtime_src/tools/scripts/xrtdeps.sh -docker && \\\n+    dnf clean all\n+\n+RUN ./build/build.sh -release -j\"$(nproc)\" && \\\n+    mkdir -p /out && \\\n+    find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +\n*** End Patch\n"
Added 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile

⏱️ 4m 7s

apply_patch

Arguments
"*** Begin Patch\n*** Add File: /home/raymond/Development/amd/xdna-driver-fedora/.dockerignore\n+repo/.git\n+repo/build/Debug\n+repo/build/Release\n+repo/build/amdxdna_bins\n*** End Patch\n"
Added 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/.dockerignore

⏱️ 4m 11s

💬 Copilot

I’ve added the Fedora 43 container recipe. Next I’m running the real podman build and will iterate if Fedora 43 package names or toolchain expectations need adjustment.


⏱️ 6m 1s

bash

Build Fedora 43 podman image

$ set -euo pipefail && podman build --no-cache -t xdna-driver-fedora43-build .

14 lines
STEP 1/7: FROM fedora:43
STEP 2/7: ENV LANG=C.UTF-8
--> baa1c7ea0235
STEP 3/7: ENV LC_ALL=C.UTF-8
--> 4ff856d8a0e7
STEP 4/7: WORKDIR /work/xdna-driver
--> c1096d702de2
STEP 5/7: COPY repo/ /work/xdna-driver/
--> daddda69af33
STEP 6/7: RUN dnf install -y --setopt=install_weak_deps=False jq &&     ./xrt/src/runtime_src/tools/scripts/xrtdeps.sh -docker &&     dnf clean all
Updating and loading repositories:
 Fedora 43 openh264 (From Cisco) - x86_ 100% |   4.8 KiB/s |   5.8 KiB |  00m01s
 Fedora 43
<exited with exit code 1>

⏱️ 6m 6s

read_bash

Waiting up to 10 seconds for command output

Arguments
{
  "shellId": "xdna-build",
  "delay": 10
}
Invalid shell ID: xdna-build. Please supply a valid shell ID to read output from.

<no active shell sessions>

⏱️ 6m 10s

💬 Copilot

The first container build failed during dependency install, which is expected for a Fedora 43-first pass. I’m rerunning with full logging so I can trim the Dockerfile to the package set Fedora 43 actually provides.


⏱️ 7m 55s

bash

Capture podman build log

$ set -euo pipefail && podman build --no-cache -t xdna-driver-fedora43-build . > podman-build.log 2>&1 || true && tail -n 200 podman-build.log

197 lines
>>> Scriptlet output:                                                           
>>> Created symlink '/etc/systemd/system/dbus-org.freedesktop.resolve1.service' 
>>> Created symlink '/etc/systemd/system/sysinit.target.wants/systemd-resolved.s
>>> Created symlink '/etc/systemd/system/sockets.target.wants/systemd-resolved-v
>>> Created symlink '/etc/systemd/system/sockets.target.wants/systemd-resolved-m
>>>                                                                             
[911/963] Installing logrotate-0:3.22.0 100% |   7.8 MiB/s | 151.6 KiB |  00m00s
>>> Running %post scriptlet: logrotate-0:3.22.0-4.fc43.x86_64                   
>>> Finished %post scriptlet: logrotate-0:3.22.0-4.fc43.x86_64                  
>>> Scriptlet output:                                                           
>>> Created symlink '/etc/systemd/system/timers.target.wants/logrotate.timer' → 
>>>                                                                             
[912/963] Installing dconf-0:0.49.0-1.f 100% |  15.2 MiB/s | 312.1 KiB |  00m00s
[913/963] Installing redhat-lsb-0:5.0-0 100% |   5.0 MiB/s |  40.7 KiB |  00m00s
[914/963] Installing tinysparql-0:3.10. 100% | 115.9 MiB/s |   2.6 MiB |  00m00s
[915/963] Installing exiv2-0:0.28.6-2.f 100% | 765.4 MiB/s |  12.2 MiB |  00m00s
[916/963] Installing libcamera-ipa-0:0. 100% | 336.1 MiB/s | 688.4 KiB |  00m00s
[917/963] Installing gi-docgen-fonts-0: 100% |   0.0   B/s | 124.0   B |  00m00s
[918/963] Installing flexiblas-openblas 100% |   0.0   B/s |  40.1 KiB |  00m00s
[919/963] Installing glib-networking-0: 100% | 370.1 MiB/s | 757.9 KiB |  00m00s
[920/963] Installing libstdc++-static-0 100% | 820.9 MiB/s |  50.9 MiB |  00m00s
[921/963] Installing mesa-va-drivers-0: 100% |   0.0   B/s | 984.0   B |  00m00s
[922/963] Installing rpm-plugin-systemd 100% |   0.0   B/s |  13.1 KiB |  00m00s
[923/963] Installing open-sans-fonts-0: 100% | 695.6 MiB/s |   2.1 MiB |  00m00s
[924/963] Installing adwaita-mono-fonts 100% | 788.3 MiB/s |   5.5 MiB |  00m00s
[925/963] Installing adwaita-sans-fonts 100% | 573.2 MiB/s |   1.7 MiB |  00m00s
[926/963] Installing proj-data-ar-0:9.6 100% |   1.2 GiB/s |   6.1 MiB |  00m00s
[927/963] Installing proj-data-at-0:9.6 100% | 893.5 MiB/s |  15.2 MiB |  00m00s
[928/963] Installing proj-data-au-0:9.6 100% |   1.2 GiB/s | 117.9 MiB |  00m00s
[929/963] Installing proj-data-be-0:9.6 100% | 927.5 MiB/s | 949.7 KiB |  00m00s
[930/963] Installing proj-data-br-0:9.6 100% |   1.0 GiB/s |   1.0 MiB |  00m00s
[931/963] Installing proj-data-ca-0:9.6 100% | 927.0 MiB/s | 105.7 MiB |  00m00s
[932/963] Installing proj-data-ch-0:9.6 100% |   1.0 GiB/s |   2.1 MiB |  00m00s
[933/963] Installing proj-data-cz-0:9.6 100% |   0.0   B/s | 105.2 KiB |  00m00s
[934/963] Installing proj-data-de-0:9.6 100% |   1.1 GiB/s |  76.5 MiB |  00m00s
[935/963] Installing proj-data-dk-0:9.6 100% |   1.1 GiB/s |  61.5 MiB |  00m00s
[936/963] Installing proj-data-es-0:9.6 100% |   1.0 GiB/s |   1.0 MiB |  00m00s
[937/963] Installing proj-data-eur-0:9. 100% |   1.0 GiB/s |   1.0 MiB |  00m00s
[938/963] Installing proj-data-fi-0:9.6 100% | 716.1 MiB/s |   2.1 MiB |  00m00s
[939/963] Installing proj-data-fo-0:9.6 100% |   0.0   B/s |   1.7 KiB |  00m00s
[940/963] Installing proj-data-fr-0:9.6 100% | 634.1 MiB/s |   1.9 MiB |  00m00s
[941/963] Installing proj-data-hu-0:9.6 100% |   0.0   B/s | 133.0 KiB |  00m00s
[942/963] Installing proj-data-is-0:9.6 100% |   1.1 GiB/s |   5.5 MiB |  00m00s
[943/963] Installing proj-data-jp-0:9.6 100% |   1.2 GiB/s |   7.4 MiB |  00m00s
[944/963] Installing proj-data-lv-0:9.6 100% |   0.0   B/s |  57.0 KiB |  00m00s
[945/963] Installing proj-data-mx-0:9.6 100% |   0.0   B/s | 554.4 KiB |  00m00s
[946/963] Installing proj-data-nc-0:9.6 100% |   1.5 GiB/s |   1.5 MiB |  00m00s
[947/963] Installing proj-data-nl-0:9.6 100% |   1.1 GiB/s |   1.2 MiB |  00m00s
[948/963] Installing proj-data-no-0:9.6 100% | 915.8 MiB/s |   9.2 MiB |  00m00s
[949/963] Installing proj-data-nz-0:9.6 100% |   1.1 GiB/s |  13.7 MiB |  00m00s
[950/963] Installing proj-data-pl-0:9.6 100% | 761.8 MiB/s |   2.3 MiB |  00m00s
[951/963] Installing proj-data-pt-0:9.6 100% |   0.0   B/s | 512.5 KiB |  00m00s
[952/963] Installing proj-data-se-0:9.6 100% |   1.1 GiB/s |   2.2 MiB |  00m00s
[953/963] Installing proj-data-si-0:9.6 100% |   0.0   B/s | 143.2 KiB |  00m00s
[954/963] Installing proj-data-sk-0:9.6 100% |   1.2 GiB/s |   1.2 MiB |  00m00s
[955/963] Installing proj-data-uk-0:9.6 100% |   1.2 GiB/s |   4.8 MiB |  00m00s
[956/963] Installing proj-data-us-0:9.6 100% |   1.2 GiB/s | 318.9 MiB |  00m00s
[957/963] Installing proj-data-za-0:9.6 100% |   0.0   B/s | 296.1 KiB |  00m00s
[958/963] Installing low-memory-monitor 100% |   4.4 MiB/s |  67.7 KiB |  00m00s
[959/963] Installing qrencode-libs-0:4. 100% |  81.4 MiB/s | 166.6 KiB |  00m00s
[960/963] Installing qt6-qttranslations 100% |   1.4 GiB/s |  15.4 MiB |  00m00s
[961/963] Installing openssl-1:3.5.4-2. 100% | 156.3 MiB/s |   1.9 MiB |  00m00s
[962/963] Installing strace-0:6.19-1.fc 100% | 250.0 MiB/s |   2.8 MiB |  00m00s
[963/963] Installing systemd-rpm-macros 100% |  10.1 KiB/s |   8.9 KiB |  00m01s
>>> Running %posttrans scriptlet: wireplumber-0:0.5.14-1.fc43.x86_64            
>>> Finished %posttrans scriptlet: wireplumber-0:0.5.14-1.fc43.x86_64           
>>> Scriptlet output:                                                           
>>> Created symlink '/etc/systemd/user/pipewire-session-manager.service' → '/usr
>>> Created symlink '/etc/systemd/user/pipewire.service.wants/wireplumber.servic
>>>                                                                             
>>> Running %triggerin scriptlet: systemd-0:258.7-1.fc43.x86_64                 
>>> Finished %triggerin scriptlet: systemd-0:258.7-1.fc43.x86_64                
>>> Scriptlet output:                                                           
>>> Failed to connect to audit log, ignoring: Invalid argument                  
>>>                                                                             
Complete!
Installing pybind11...
Updating and loading repositories:
Repositories loaded.
Package           Arch   Version        Repository      Size
Installing:
 python3-pybind11 x86_64 2.13.6-10.fc43 fedora      63.9 KiB
Installing dependencies:
 pybind11-devel   x86_64 2.13.6-10.fc43 fedora     847.0 KiB

Transaction Summary:
 Installing:         2 packages

Total size of inbound packages is 224 KiB. Need to download 224 KiB.
After this operation, 911 KiB extra will be used (install 911 KiB, remove 0 B).
[1/2] python3-pybind11-0:2.13.6-10.fc43 100% | 773.9 KiB/s |  38.7 KiB |  00m00s
[2/2] pybind11-devel-0:2.13.6-10.fc43.x 100% |   1.8 MiB/s | 184.8 KiB |  00m00s
--------------------------------------------------------------------------------
[2/2] Total                             100% |   1.4 MiB/s | 223.5 KiB |  00m00s
Running transaction
[1/4] Verify package files              100% |   0.0   B/s |   2.0   B |  00m00s
[2/4] Prepare transaction               100% |  83.0   B/s |   2.0   B |  00m00s
[3/4] Installing pybind11-devel-0:2.13. 100% |  83.5 MiB/s | 855.2 KiB |  00m00s
[4/4] Installing python3-pybind11-0:2.1 100% |   1.7 MiB/s |  68.7 KiB |  00m00s
Complete!
package rocm-hip-devel is not installed
Updating and loading repositories:
Repositories loaded.
Total size of inbound packages is 385 MiB. Need to download 385 MiB.
After this operation, 2 GiB extra will be used (install 2 GiB, remove 0 B).
Package                   Arch   Version              Repository      Size
Installing:
 rocm-hip-devel           x86_64 6.4.2-2.fc43         fedora       2.8 MiB
Installing dependencies:
 hipcc                    x86_64 19-14.rocm6.4.2.fc43 fedora     652.9 KiB
 rocm-clang               x86_64 19-14.rocm6.4.2.fc43 fedora      70.2 MiB
 rocm-clang-devel         x86_64 19-14.rocm6.4.2.fc43 fedora      23.3 MiB
 rocm-clang-libs          x86_64 19-14.rocm6.4.2.fc43 fedora      98.4 MiB
 rocm-clang-runtime-devel x86_64 19-14.rocm6.4.2.fc43 fedora       7.8 MiB
 rocm-comgr               x86_64 19-14.rocm6.4.2.fc43 fedora     123.9 MiB
 rocm-comgr-devel         x86_64 19-14.rocm6.4.2.fc43 fedora      98.2 KiB
 rocm-device-libs         x86_64 19-14.rocm6.4.2.fc43 fedora       3.2 MiB
 rocm-hip                 x86_64 6.4.2-2.fc43         fedora      24.9 MiB
 rocm-libc++              x86_64 19-14.rocm6.4.2.fc43 fedora       1.2 MiB
 rocm-libc++-devel        x86_64 19-14.rocm6.4.2.fc43 fedora       7.5 MiB
 rocm-lld                 x86_64 19-14.rocm6.4.2.fc43 fedora       5.7 MiB
 rocm-llvm                x86_64 19-14.rocm6.4.2.fc43 fedora      48.5 MiB
 rocm-llvm-devel          x86_64 19-14.rocm6.4.2.fc43 fedora      25.3 MiB
 rocm-llvm-filesystem     x86_64 19-14.rocm6.4.2.fc43 fedora       0.0   B
 rocm-llvm-libs           x86_64 19-14.rocm6.4.2.fc43 fedora      84.8 MiB
 rocm-llvm-static         x86_64 19-14.rocm6.4.2.fc43 fedora       1.8 GiB
 rocm-runtime             x86_64 6.4.2-3.fc43         updates      3.1 MiB
 rocm-runtime-devel       x86_64 6.4.2-3.fc43         updates    571.4 KiB

Transaction Summary:
 Installing:        20 packages

[ 1/20] rocm-comgr-devel-0:19-14.rocm6. 100% |   1.0 MiB/s |  31.8 KiB |  00m00s
[ 2/20] rocm-hip-devel-0:6.4.2-2.fc43.x 100% |   5.9 MiB/s | 248.6 KiB |  00m00s
[ 3/20] rocm-device-libs-0:19-14.rocm6. 100% |   2.8 MiB/s | 503.6 KiB |  00m00s
[ 4/20] rocm-hip-0:6.4.2-2.fc43.x86_64  100% |  33.5 MiB/s |   9.5 MiB |  00m00s
[ 5/20] hipcc-0:19-14.rocm6.4.2.fc43.x8 100% | 934.6 KiB/s | 133.6 KiB |  00m00s
[ 6/20] rocm-comgr-0:19-14.rocm6.4.2.fc 100% |  27.9 MiB/s |  30.5 MiB |  00m01s
[ 7/20] rocm-clang-devel-0:19-14.rocm6. 100% |   2.9 MiB/s |   2.6 MiB |  00m01s
[ 8/20] rocm-lld-0:19-14.rocm6.4.2.fc43 100% |   1.8 MiB/s |   1.5 MiB |  00m01s
[ 9/20] rocm-llvm-static-0:19-14.rocm6. 100% |  29.3 MiB/s | 260.8 MiB |  00m09s
[10/20] rocm-clang-0:19-14.rocm6.4.2.fc 100% |   1.8 MiB/s |  16.0 MiB |  00m09s
[11/20] rocm-clang-libs-0:19-14.rocm6.4 100% |   2.4 MiB/s |  22.8 MiB |  00m09s
[12/20] rocm-llvm-libs-0:19-14.rocm6.4. 100% |  10.7 MiB/s |  20.2 MiB |  00m02s
[13/20] rocm-clang-runtime-devel-0:19-1 100% | 456.6 KiB/s | 631.1 KiB |  00m01s
[14/20] rocm-llvm-devel-0:19-14.rocm6.4 100% |   2.1 MiB/s |   4.1 MiB |  00m02s
[15/20] rocm-libc++-devel-0:19-14.rocm6 100% |   9.6 MiB/s |   1.1 MiB |  00m00s
[16/20] rocm-llvm-filesystem-0:19-14.ro 100% | 795.3 KiB/s |  24.7 KiB |  00m00s
[17/20] rocm-libc++-0:19-14.rocm6.4.2.f 100% |   5.8 MiB/s | 345.8 KiB |  00m00s
[18/20] rocm-runtime-devel-0:6.4.2-3.fc 100% |   6.1 MiB/s |  93.5 KiB |  00m00s
[19/20] rocm-runtime-0:6.4.2-3.fc43.x86 100% |  26.5 MiB/s | 650.6 KiB |  00m00s
[20/20] rocm-llvm-0:19-14.rocm6.4.2.fc4 100% |  25.4 MiB/s |  13.1 MiB |  00m01s
--------------------------------------------------------------------------------
[20/20] Total                           100% |  30.4 MiB/s | 384.7 MiB |  00m13s
Running transaction
[ 1/22] Verify package files            100% |  25.0   B/s |  20.0   B |  00m01s
[ 2/22] Prepare transaction             100% | 307.0   B/s |  20.0   B |  00m00s
[ 3/22] Installing rocm-runtime-0:6.4.2 100% | 615.1 MiB/s |   3.1 MiB |  00m00s
[ 4/22] Installing rocm-runtime-devel-0 100% | 561.5 MiB/s | 574.9 KiB |  00m00s
[ 5/22] Installing rocm-llvm-filesystem 100% |   4.7 MiB/s |  19.1 KiB |  00m00s
[ 6/22] Installing rocm-libc++-0:19-14. 100% |  39.7 MiB/s |   1.2 MiB |  00m00s
[ 7/22] Installing rocm-llvm-libs-0:19- 100% | 126.3 MiB/s |  84.8 MiB |  00m01s
[ 8/22] Installing rocm-clang-libs-0:19 100% | 130.3 MiB/s |  98.4 MiB |  00m01s
[ 9/22] Installing rocm-comgr-0:19-14.r 100% | 123.2 MiB/s | 123.9 MiB |  00m01s
[10/22] Installing rocm-lld-0:19-14.roc 100% | 115.9 MiB/s |   5.7 MiB |  00m00s
[11/22] Installing rocm-llvm-0:19-14.ro 100% | 116.9 MiB/s |  48.5 MiB |  00m00s
[12/22] Installing rocm-llvm-devel-0:19 100% | 124.1 MiB/s |  25.7 MiB |  00m00s
[13/22] Installing rocm-llvm-static-0:1 100% | 159.2 MiB/s |   1.8 GiB |  00m12s
[14/22] Installing rocm-libc++-devel-0: 100% | 107.8 MiB/s |   7.7 MiB |  00m00s
[15/22] Installing rocm-clang-runtime-d 100% | 187.1 MiB/s |   7.9 MiB |  00m00s
[16/22] Installing rocm-clang-0:19-14.r 100% | 117.1 MiB/s |  70.2 MiB |  00m01s
[17/22] Installing rocm-clang-devel-0:1 100% | 175.0 MiB/s |  23.5 MiB |  00m00s
[18/22] Installing rocm-device-libs-0:1 100% | 146.0 MiB/s |   3.2 MiB |  00m00s
[19/22] Installing rocm-comgr-devel-0:1 100% |  97.3 MiB/s |  99.6 KiB |  00m00s
[20/22] Installing hipcc-0:19-14.rocm6. 100% |  53.3 MiB/s | 654.3 KiB |  00m00s
[21/22] Installing rocm-hip-0:6.4.2-2.f 100% | 437.7 MiB/s |  24.9 MiB |  00m00s
[22/22] Installing rocm-hip-devel-0:6.4 100% |  31.5 MiB/s |   2.8 MiB |  00m00s
Complete!
Removed 18 files, 12 directories (total of 99 MiB). 0 errors occurred.
--> b35e0bbc358a
STEP 7/7: RUN ./build/build.sh -release -j"$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +
unknown option
Usage: build.sh [options]
Options:
  -help                    Display this help
  -clean                   Clean build directory
  -debug                   Debug build and generate .deb package
  -release                 Release build and generate .deb package
  -j <n>                   Compile parallel (default: num of CPUs)
  -nocmake                 Do not regenerate cmake files
  -install_prefix <path>   Set CMAKE_INSTALL_PREFIX to path
  -verbose                 Enable verbose build
  -hello_umq               Hello UMQ Memory Test
  -dir                     Download directory if apply
  -nokmod                  Don't build or install the kernel module
  -novxdna                 Don't build vxdna library
  -vxdna_test              Build and run vxdna unit tests (-novxdna disable this option)
  -package_legacy_driver   Build package with legacy driver source code (default)
  -package_upstream_driver Build package with upstream driver source code
Error: building at STEP "RUN ./build/build.sh -release -j"$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +": while running runtime: exit status 1
<exited with exit code 0>

⏱️ 8m 1s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile\n@@\n-RUN ./build/build.sh -release -j\"$(nproc)\" && \\\n+RUN ./build/build.sh -release -j \"$(nproc)\" && \\\n     mkdir -p /out && \\\n     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile

⏱️ 8m 5s

💬 Copilot

The dependency layer is fine; the failure was just the script’s -j argument format. I’ve fixed that and I’m rerunning the actual release build now.


⏱️ 8m 28s

bash

Build image and RPM

$ set -euo pipefail && podman build -t xdna-driver-fedora43-build .

13 lines
STEP 1/7: FROM fedora:43
STEP 2/7: ENV LANG=C.UTF-8
--> Using cache ad07e23c23fe5d81f1d72af139f441740d0585a0854e4ecfd7f9ae4cdf758177
--> ad07e23c23fe
STEP 3/7: ENV LC_ALL=C.UTF-8
--> Using cache 30eb64056fc8d1f4c11114d7520a04a78d71e8e2552a802526e82f4d70655493
--> 30eb64056fc8
STEP 4/7: WORKDIR /work/xdna-driver
--> Using cache 1c1e91277e174fc24aac9d82cf73b008a58aa8f0ade743bbe2e4d2b79d397235
--> 1c1e91277e17
STEP 5/7: COPY repo/ /work/xdna-driver/
--> Using cache 69c24bba6a868ab9e071355aa4a209ca4
<exited with exit code 2>

⏱️ 8m 54s

bash

Tail failed build log

$ set -euo pipefail && podman build -t xdna-driver-fedora43-build . > podman-build.log 2>&1 || true && tail -n 120 podman-build.log

120 lines
[ 17%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/native_profile.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/print.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_bo.cpp.o
[ 20%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/debug.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/pcie/linux/plugin/xdp/CMakeFiles/core_pcielinux_plugin_xdp_objects.dir/power_profile.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/device_linux.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/transaction.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/printa.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/pcie/linux/plugin/xdp/CMakeFiles/core_pcielinux_plugin_xdp_objects.dir/sc_profile.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_device.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/profile.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_elf.cpp.o
[ 25%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_error.cpp.o
[ 25%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_fence.cpp.o
[ 25%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/pcidev.cpp.o
[ 25%] Built target core_common_xdp_profile_objects
[ 25%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/packets.cpp.o
[ 25%] Building CXX object xrt/src/runtime_src/core/pcie/linux/plugin/xdp/CMakeFiles/core_pcielinux_plugin_xdp_objects.dir/vart_profile.cpp.o
[ 25%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/read_mem.cpp.o
[ 25%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/debug_ip.cpp.o
[ 25%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_hw_context.cpp.o
[ 25%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/pcidrv.cpp.o
[ 25%] Built target core_common_objects
[ 28%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/passmanager.cpp.o
[ 28%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/read_register.cpp.o
[ 28%] Built target core_pcielinux_plugin_xdp_objects
[ 28%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/device.cpp.o
[ 28%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/aie2p_passes.cpp.o
[ 28%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_ini.cpp.o
[ 28%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_ip.cpp.o
[ 28%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/error.cpp.o
[ 28%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_aie.cpp.o
[ 28%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/shim.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/timestamp.cpp.o
[ 31%] Linking CXX shared library libvxdna.so
[ 31%] Built target vxdna
[ 31%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/assembler/aiebu_assembler.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_aie2.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/smi_pcie.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/system_linux.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/assembler/assembler.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/aiebu_error.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/timestamp32.cpp.o
[ 40%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/writer.cpp.o
[ 40%] Built target core_pciecommon_objects
[ 40%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_kernel.cpp.o
[ 40%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_memory.cpp.o
[ 40%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/assembler_state.cpp.o
[ 40%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_platform.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_message.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/utils.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_telemetry.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/timestamps.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/file_utils.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_module.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/timestamps32.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/elf/elfwriter.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_vmr.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/memaccess.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/aie2/aie2_blob_preprocessor_input.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_profile.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_queue.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/message.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/write_mem.cpp.o
[ 48%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/write_register.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/aie2/aie2_asm_preprocessor_input.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/module_loader.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/query_requests.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/write_handshake.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/asm/asm_parser.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/sensor.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/read_handshake.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/host_timestamp.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/host_timestamps.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_system.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/ops/ops.cpp.o
[ 54%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/sleep.cpp.o
[ 54%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/disassembler/disassembler.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_version.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/system.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/thread.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/count.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_xclbin.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/time.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/trace.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/aie/xrt_graph.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/begin.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/transform_manager.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/linux/metrics.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/encoder/aie2ps/aie2ps_encoder.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/usage_metrics.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/encoder/aie2ps/report.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/utils.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/sysinfo.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/xclbin_parser.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/xclbin_swemu.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/end.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/jprobe.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/aie2ps/aie2ps_preprocessor_input.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/probe_control.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/profile.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/asm/pager.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/tracepoint.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/parser/parser.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/smi.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/pager/pager.cpp.o
[ 68%] Built target core_common_runner_objects
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/control/control.cpp.o
[ 71%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/dtrace.cpp.o
[ 71%] Built target core_common_api_library_objects
[ 71%] Built target aiebu_library_objects
[ 71%] Built target core_common_library_objects
[ 71%] Built target core_pcielinux_objects
[ 71%] Built target dtrace_library_objects
make: *** [Makefile:156: all] Error 2

real	0m17.635s
user	7m6.173s
sys	0m19.148s
Error: building at STEP "RUN ./build/build.sh -release -j "$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +": while running runtime: exit status 2
<exited with exit code 0>

⏱️ 8m 58s

rg

/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log

Arguments
{
  "pattern": "error:|Error |fatal error|undefined reference|No rule to make target|FAILED",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log",
  "output_mode": "content",
  "-n": true,
  "-C": 2,
  "head_limit": 200
}
16 lines
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-291-[ 17%] Building CXX object xrt/src/runtime_src/core/pcie/linux/plugin/xdp/CMakeFiles/core_pcielinux_plugin_xdp_objects.dir/plugin_loader.cpp.o
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-292-ERROR: Cannot find kernel headers under /lib/modules/6.19.11-200.fc43.x86_64/build or /lib/modules/6.19.11-200.fc43.x86_64/source
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:293:make[2]: *** [drivers/accel/CMakeFiles/driver.dir/build.make:79: drivers/accel/drivers/accel/amdxdna/config_kernel.h] Error 1
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:294:make[1]: *** [CMakeFiles/Makefile2:5064: drivers/accel/CMakeFiles/driver.dir/all] Error 2
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-295-make[1]: *** Waiting for unfinished jobs....
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-296-ERROR: Cannot find kernel headers under /lib/modules/6.19.11-200.fc43.x86_64/build or /lib/modules/6.19.11-200.fc43.x86_64/source
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:297:make[2]: *** [src/driver/CMakeFiles/legacy_driver.dir/build.make:79: src/driver/driver/amdxdna/config_kernel.h] Error 1
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:298:make[1]: *** [CMakeFiles/Makefile2:4935: src/driver/CMakeFiles/legacy_driver.dir/all] Error 2
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-299-[ 17%] Building CXX object src/vxdna/CMakeFiles/vxdna.dir/util/vxdna_debug.cpp.o
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-300-[ 17%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/native_profile.cpp.o
--
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-412-[ 71%] Built target core_pcielinux_objects
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-413-[ 71%] Built target dtrace_library_objects
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:414:make: *** [Makefile:156: all] Error 2
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-415-
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-416-real	0m17.635s

⏱️ 8m 58s

rg

/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log

Arguments
{
  "pattern": "Killed|terminated|collect2|ld:|g\\+\\+: fatal",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log",
  "output_mode": "content",
  "-n": true,
  "-C": 2,
  "head_limit": 100
}
No matches found.

⏱️ 9m 5s

💬 Copilot

The next blocker is real: the RPM build includes the kernel module, so the container needs Fedora kernel headers matching the host kernel it sees. I’m adding that explicitly and rerunning.


⏱️ 9m 5s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile\n@@\n RUN dnf install -y --setopt=install_weak_deps=False jq && \\\n     ./xrt/src/runtime_src/tools/scripts/xrtdeps.sh -docker && \\\n+    dnf install -y --setopt=install_weak_deps=False \"kernel-devel-$(uname -r)\" kernel-headers && \\\n     dnf clean all\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile

⏱️ 11m 7s

bash

Rebuild with kernel headers

$ set -euo pipefail && podman build -t xdna-driver-fedora43-build . > podman-build.log 2>&1 || true && tail -n 120 podman-build.log

<command with shellId: 3 is still running after 120 seconds. The command is still running but hasn't produced output yet. It may be waiting for input or still processing. Use read_bash to continue waiting, write_bash if you think it needs input, or stop_bash to stop it.>

⏱️ 11m 23s

read_bash

Waiting up to 60 seconds for command output

Arguments
{
  "shellId": "3",
  "delay": 60
}
120 lines
[ 14%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/native_profile.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/smi_pcie.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_bo.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/pcie/common/CMakeFiles/core_pciecommon_objects.dir/device_pcie.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/break.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/transaction.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/system_linux.cpp.o
[ 17%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/buffer_dumper.cpp.o
[ 20%] Building CXX object xrt/src/runtime_src/core/pcie/common/CMakeFiles/core_pciecommon_objects.dir/system_pcie.cpp.o
[ 20%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_device.cpp.o
[ 20%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/packets.cpp.o
[ 20%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/mask_write_register.cpp.o
[ 20%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/config_reader.cpp.o
[ 20%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_elf.cpp.o
[ 22%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/passmanager.cpp.o
[ 22%] Built target core_pcielinux_plugin_xdp_objects
[ 22%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/aie2p_passes.cpp.o
[ 22%] Built target core_common_xdp_profile_objects
[ 25%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/debug.cpp.o
[ 28%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/operation.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_error.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_fence.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/assembler/aiebu_assembler.cpp.o
[ 31%] Built target core_common_objects
[ 31%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/print.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/debug_ip.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_hw_context.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_ini.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_ip.cpp.o
[ 31%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_kernel.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_message.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_module.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/device.cpp.o
[ 34%] Linking CXX shared library libvxdna.so
[ 34%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/error.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/printa.cpp.o
[ 34%] Built target vxdna
[ 34%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_aie.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/profile.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/assembler/assembler.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/aiebu_error.cpp.o
[ 34%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_profile.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_aie2.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_memory.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_platform.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_queue.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/read_mem.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_telemetry.cpp.o
[ 37%] Built target core_pciecommon_objects
[ 37%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/info_vmr.cpp.o
[ 37%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_system.cpp.o
[ 40%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/writer.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_version.cpp.o
[ 42%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/assembler_state.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/memaccess.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/read_register.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/utils.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/xrt_xclbin.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/message.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/file_utils.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/module_loader.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/aie/xrt_graph.cpp.o
[ 45%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/query_requests.cpp.o
[ 48%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/timestamp.cpp.o
[ 48%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/elf/elfwriter.cpp.o
[ 48%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/sensor.cpp.o
[ 48%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/timestamp32.cpp.o
[ 48%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/timestamps.cpp.o
[ 48%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/aie2/aie2_blob_preprocessor_input.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/aie2/aie2_asm_preprocessor_input.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/timestamps32.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/write_mem.cpp.o
[ 51%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/asm/asm_parser.cpp.o
[ 54%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/write_register.cpp.o
[ 54%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/system.cpp.o
[ 54%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/ops/ops.cpp.o
[ 54%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/write_handshake.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/thread.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/read_handshake.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/disassembler/disassembler.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/host_timestamp.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/time.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/trace.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/usage_metrics.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/analyzer/transform_manager.cpp.o
[ 57%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/host_timestamps.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/common/linux/metrics.cpp.o
[ 60%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/utils.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/sleep.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/action/count.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/encoder/aie2ps/aie2ps_encoder.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/begin.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/end.cpp.o
[ 62%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/jprobe.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/sysinfo.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/probe_control.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/xclbin_parser.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/encoder/aie2ps/report.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/xclbin_swemu.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/smi.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/aie2ps/aie2ps_preprocessor_input.cpp.o
[ 65%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/CMakeFiles/aiebu_library_objects.dir/preprocessor/asm/pager.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/profile.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/probe/tracepoint.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/parser/parser.cpp.o
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/pager/pager.cpp.o
[ 68%] Built target core_common_runner_objects
[ 68%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/control/control.cpp.o
[ 71%] Building CXX object xrt/src/runtime_src/core/common/aiebu/src/cpp/dtrace/CMakeFiles/dtrace_library_objects.dir/dtrace.cpp.o
[ 71%] Built target core_common_api_library_objects
[ 71%] Built target aiebu_library_objects
[ 71%] Built target core_pcielinux_objects
[ 71%] Built target core_common_library_objects
[ 71%] Built target dtrace_library_objects
make: *** [Makefile:156: all] Error 2

real	0m18.786s
user	7m11.393s
sys	0m18.566s
Error: building at STEP "RUN ./build/build.sh -release -j "$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +": while running runtime: exit status 2
<command with id: 3 exited with exit code 0>

⏱️ 11m 23s

ℹ️ Notification

Shell "Rebuild with kernel headers" completed


⏱️ 11m 27s

rg

/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log

Arguments
{
  "pattern": "ERROR: Cannot find kernel headers|error:|Error |fatal error|undefined reference|No rule to make target|FAILED|build.make",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log",
  "output_mode": "content",
  "-n": true,
  "-C": 3,
  "head_limit": 200
}
29 lines
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-597- perl-English                            noarch 1.11-523.fc43                     updates                 6.2 KiB
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-598- perl-Env                                noarch 1.06-520.fc43                     fedora                 26.1 KiB
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-599- perl-Errno                              x86_64 1.38-523.fc43                     updates                 8.4 KiB
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:600: perl-Error                              noarch 1:0.17030-2.fc43                  fedora                 76.7 KiB
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-601- perl-Exporter                           noarch 5.79-520.fc43                     fedora                 54.3 KiB
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-602- perl-ExtUtils-CBuilder                  noarch 1:0.280242-520.fc43               fedora                 97.3 KiB
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-603- perl-ExtUtils-Command                   noarch 2:7.76-521.fc43                   fedora                  9.6 KiB
--
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3528-[ 11%] Configuring out of tree kernel compatibility header
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3529-[ 11%] Configuring kernel compatibility header
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3530-[ 11%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/elf_patcher.cpp.o
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3531:ERROR: Cannot find kernel headers under /lib/modules/6.19.11-200.fc43.x86_64/build or /lib/modules/6.19.11-200.fc43.x86_64/source
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3532:ERROR: Cannot find kernel headers under /lib/modules/6.19.11-200.fc43.x86_64/build or /lib/modules/6.19.11-200.fc43.x86_64/source
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3533:make[2]: *** [src/driver/CMakeFiles/legacy_driver.dir/build.make:79: src/driver/driver/amdxdna/config_kernel.h] Error 1
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3534:make[2]: *** [drivers/accel/CMakeFiles/driver.dir/build.make:79: drivers/accel/drivers/accel/amdxdna/config_kernel.h] Error 1
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3535:make[1]: *** [CMakeFiles/Makefile2:4935: src/driver/CMakeFiles/legacy_driver.dir/all] Error 2
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3536-make[1]: *** Waiting for unfinished jobs....
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3537:make[1]: *** [CMakeFiles/Makefile2:5064: drivers/accel/CMakeFiles/driver.dir/all] Error 2
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3538-[ 14%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/hw_queue.cpp.o
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3539-[ 14%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/native_profile.cpp.o
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3540-[ 17%] Building CXX object xrt/src/runtime_src/core/pcie/linux/CMakeFiles/core_pcielinux_objects.dir/smi_pcie.cpp.o
--
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3650-[ 71%] Built target core_pcielinux_objects
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3651-[ 71%] Built target core_common_library_objects
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3652-[ 71%] Built target dtrace_library_objects
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3653:make: *** [Makefile:156: all] Error 2
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3654-
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3655-real	0m18.786s
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3656-user	7m11.393s

⏱️ 11m 27s

rg

/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log

Arguments
{
  "pattern": "Killed|terminated|collect2|ld:|g\\+\\+: fatal|cc1plus:|ninja: build stopped|make\\[[0-9]+\\]: \\*\\*\\*",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log",
  "output_mode": "content",
  "-n": true,
  "-C": 2,
  "head_limit": 200
}
9 lines
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3531-ERROR: Cannot find kernel headers under /lib/modules/6.19.11-200.fc43.x86_64/build or /lib/modules/6.19.11-200.fc43.x86_64/source
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3532-ERROR: Cannot find kernel headers under /lib/modules/6.19.11-200.fc43.x86_64/build or /lib/modules/6.19.11-200.fc43.x86_64/source
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3533:make[2]: *** [src/driver/CMakeFiles/legacy_driver.dir/build.make:79: src/driver/driver/amdxdna/config_kernel.h] Error 1
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3534:make[2]: *** [drivers/accel/CMakeFiles/driver.dir/build.make:79: drivers/accel/drivers/accel/amdxdna/config_kernel.h] Error 1
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3535:make[1]: *** [CMakeFiles/Makefile2:4935: src/driver/CMakeFiles/legacy_driver.dir/all] Error 2
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3536:make[1]: *** Waiting for unfinished jobs....
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log:3537:make[1]: *** [CMakeFiles/Makefile2:5064: drivers/accel/CMakeFiles/driver.dir/all] Error 2
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3538-[ 14%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/hw_queue.cpp.o
/home/raymond/Development/amd/xdna-driver-fedora/podman-build.log-3539-[ 14%] Building CXX object xrt/src/runtime_src/core/common/api/CMakeFiles/core_common_api_library_objects.dir/native_profile.cpp.o

⏱️ 11m 34s

💬 Copilot

The headers package installs, but the driver build still can’t see the expected /lib/modules/.../build path. I’m checking the exact filesystem layout Fedora 43 creates for that host-kernel package and then I’ll bridge it in the container.


⏱️ 11m 54s

bash

Check Fedora kernel header paths

$ set -euo pipefail && podman run --rm fedora:43 bash -lc 'dnf install -y --setopt=install_weak_deps=False "kernel-devel-$(uname -r)" kernel-headers >/tmp/dnf.log && echo KERNEL=$(uname -r) && ls -ld /usr/src/kernels/$(uname -r) /lib/modules/$(uname -r) /lib/modules/$(uname -r)/build /lib/modules/$(uname -r)/source'

183 lines
Updating and loading repositories:
 Fedora 43 - x86_64 - Updates           100% |  25.0 MiB/s |  28.8 MiB |  00m01s
 Fedora 43 openh264 (From Cisco) - x86_ 100% |   4.8 KiB/s |   5.8 KiB |  00m01s
 Fedora 43 - x86_64                     100% |  20.9 MiB/s |  35.4 MiB |  00m02s
Repositories loaded.
Total size of inbound packages is 99 MiB. Need to download 99 MiB.
After this operation, 314 MiB extra will be used (install 314 MiB, remove 0 B).
[ 1/82] flex-0:2.6.4-20.fc43.x86_64     100% |   6.8 MiB/s | 299.0 KiB |  00m00s
[ 2/82] make-1:4.4.1-11.fc43.x86_64     100% |  44.0 MiB/s | 585.2 KiB |  00m00s
[ 3/82] bison-0:3.8.2-11.fc43.x86_64    100% |  11.2 MiB/s |   1.0 MiB |  00m00s
[ 4/82] m4-0:1.4.21-1.fc43.x86_64       100% | 337.5 KiB/s | 343.9 KiB |  00m01s
[ 5/82] kernel-devel-0:6.19.11-200.fc43 100% |  21.4 MiB/s |  24.1 MiB |  00m01s
[ 6/82] kernel-headers-0:6.19.6-200.fc4 100% |   1.6 MiB/s |   1.7 MiB |  00m01s
[ 7/82] elfutils-libelf-devel-0:0.194-1 100% |   2.9 MiB/s |  82.7 KiB |  00m00s
[ 8/82] libmpc-0:1.3.1-8.fc43.x86_64    100% |   7.6 MiB/s |  70.4 KiB |  00m00s
[ 9/82] cpp-0:15.2.1-7.fc43.x86_64      100% |  20.2 MiB/s |  12.9 MiB |  00m01s
[10/82] openssl-devel-1:3.5.4-2.fc43.x8 100% |   3.8 MiB/s |   3.0 MiB |  00m01s
[11/82] perl-libs-4:5.42.2-523.fc43.x86 100% |  13.4 MiB/s |   2.6 MiB |  00m00s
[12/82] gcc-0:15.2.1-7.fc43.x86_64      100% |  38.9 MiB/s |  39.7 MiB |  00m01s
[13/82] perl-interpreter-4:5.42.2-523.f 100% | 188.5 KiB/s |  72.0 KiB |  00m00s
[14/82] perl-Carp-0:1.54-520.fc43.noarc 100% | 926.1 KiB/s |  28.7 KiB |  00m00s
[15/82] perl-Exporter-0:5.79-520.fc43.n 100% |  10.0 MiB/s |  30.9 KiB |  00m00s
[16/82] perl-Errno-0:1.38-523.fc43.x86_ 100% |   2.8 MiB/s |  14.6 KiB |  00m00s
[17/82] perl-PathTools-0:3.94-520.fc43. 100% |  10.6 MiB/s |  87.2 KiB |  00m00s
[18/82] perl-Scalar-List-Utils-5:1.70-1 100% |  12.2 MiB/s |  75.0 KiB |  00m00s
[19/82] jansson-0:2.14-3.fc43.x86_64    100% |  14.7 MiB/s |  45.3 KiB |  00m00s
[20/82] perl-constant-0:1.33-521.fc43.n 100% |   2.2 MiB/s |  22.8 KiB |  00m00s
[21/82] binutils-0:2.45.1-4.fc43.x86_64 100% |  52.5 MiB/s |   5.9 MiB |  00m00s
[22/82] zlib-ng-compat-devel-0:2.3.3-2. 100% | 356.9 KiB/s |  37.8 KiB |  00m00s
[23/82] pkgconf-pkg-config-0:2.3.0-3.fc 100% |   3.1 MiB/s |   9.6 KiB |  00m00s
[24/82] libzstd-devel-0:1.5.7-2.fc43.x8 100% |  17.2 MiB/s |  52.9 KiB |  00m00s
[25/82] glibc-devel-0:2.42-10.fc43.x86_ 100% |   4.9 MiB/s | 569.0 KiB |  00m00s
[26/82] pkgconf-0:2.3.0-3.fc43.x86_64   100% |  14.5 MiB/s |  44.6 KiB |  00m00s
[27/82] pkgconf-m4-0:2.3.0-3.fc43.noarc 100% |   4.5 MiB/s |  13.9 KiB |  00m00s
[28/82] elfutils-debuginfod-client-0:0. 100% |   9.2 MiB/s |  46.9 KiB |  00m00s
[29/82] cmake-filesystem-0:3.31.11-1.fc 100% |   2.6 MiB/s |  13.4 KiB |  00m00s
[30/82] perl-DynaLoader-0:1.57-523.fc43 100% |   6.3 MiB/s |  25.6 KiB |  00m00s
[31/82] perl-Getopt-Long-1:2.58-520.fc4 100% |  10.4 MiB/s |  63.6 KiB |  00m00s
[32/82] libpkgconf-0:2.3.0-3.fc43.x86_6 100% |   1.8 MiB/s |  37.9 KiB |  00m00s
[33/82] perl-Encode-4:3.21-520.fc43.x86 100% |  65.7 MiB/s |   1.1 MiB |  00m00s
[34/82] perl-MIME-Base64-0:3.16-520.fc4 100% |   5.8 MiB/s |  29.7 KiB |  00m00s
[35/82] perl-Pod-Usage-4:2.05-520.fc43. 100% |  13.2 MiB/s |  40.5 KiB |  00m00s
[36/82] perl-parent-1:0.244-520.fc43.no 100% |   4.8 MiB/s |  14.8 KiB |  00m00s
[37/82] perl-Storable-1:3.37-521.fc43.x 100% |  16.0 MiB/s |  98.5 KiB |  00m00s
[38/82] perl-Text-ParseWords-0:3.31-520 100% |   5.3 MiB/s |  16.3 KiB |  00m00s
[39/82] perl-Pod-Perldoc-0:3.28.01-521. 100% |  20.6 MiB/s |  84.3 KiB |  00m00s
[40/82] perl-File-Temp-1:0.231.100-520. 100% |  19.2 MiB/s |  59.0 KiB |  00m00s
[41/82] perl-Pod-Simple-1:3.47-3.fc43.n 100% |   5.2 MiB/s | 219.9 KiB |  00m00s
[42/82] perl-Term-ANSIColor-0:5.01-521. 100% |  15.5 MiB/s |  47.6 KiB |  00m00s
[43/82] perl-Term-Cap-0:1.18-520.fc43.n 100% |   7.1 MiB/s |  21.9 KiB |  00m00s
[44/82] perl-File-Path-0:2.18-520.fc43. 100% |  11.4 MiB/s |  35.1 KiB |  00m00s
[45/82] perl-IO-Socket-SSL-0:2.095-2.fc 100% |   5.7 MiB/s | 231.5 KiB |  00m00s
[46/82] perl-HTTP-Tiny-0:0.090-521.fc43 100% | 574.8 KiB/s |  56.3 KiB |  00m00s
[47/82] perl-Socket-4:2.040-2.fc43.x86_ 100% |  17.9 MiB/s |  54.9 KiB |  00m00s
[48/82] perl-Time-Local-2:1.350-520.fc4 100% |  11.2 MiB/s |  34.4 KiB |  00m00s
[49/82] perl-Net-SSLeay-0:1.94-11.fc43. 100% |  33.3 MiB/s | 374.8 KiB |  00m00s
[50/82] perl-Pod-Escapes-1:1.07-520.fc4 100% |   9.7 MiB/s |  19.8 KiB |  00m00s
[51/82] perl-Text-Tabs+Wrap-0:2024.001- 100% |   7.0 MiB/s |  21.6 KiB |  00m00s
[52/82] perl-IO-Socket-IP-0:0.43-521.fc 100% |  13.7 MiB/s |  42.1 KiB |  00m00s
[53/82] ncurses-0:6.5-7.20250614.fc43.x 100% |  52.0 MiB/s | 426.2 KiB |  00m00s
[54/82] perl-vars-0:1.05-523.fc43.noarc 100% |   3.1 MiB/s |  12.6 KiB |  00m00s
[55/82] libxcrypt-devel-0:4.5.2-1.fc43. 100% |   7.3 MiB/s |  30.0 KiB |  00m00s
[56/82] perl-File-Basename-0:2.86-523.f 100% |   4.1 MiB/s |  16.8 KiB |  00m00s
[57/82] perl-Fcntl-0:1.20-523.fc43.x86_ 100% |   7.2 MiB/s |  29.4 KiB |  00m00s
[58/82] perl-POSIX-0:2.23-523.fc43.x86_ 100% |   7.3 MiB/s |  96.7 KiB |  00m00s
[59/82] perl-IO-0:1.55-523.fc43.x86_64  100% |   8.0 MiB/s |  81.7 KiB |  00m00s
[60/82] perl-Symbol-0:1.09-523.fc43.noa 100% |   3.4 MiB/s |  13.8 KiB |  00m00s
[61/82] perl-if-0:0.61.000-523.fc43.noa 100% |   3.3 MiB/s |  13.6 KiB |  00m00s
[62/82] perl-overload-0:1.40-523.fc43.n 100% |   8.8 MiB/s |  45.2 KiB |  00m00s
[63/82] perl-IPC-Open3-0:1.24-523.fc43. 100% |   5.7 MiB/s |  23.5 KiB |  00m00s
[64/82] groff-base-0:1.23.0-11.fc43.x86 100% |  44.0 MiB/s |   1.1 MiB |  00m00s
[65/82] perl-AutoLoader-0:5.74-523.fc43 100% |   1.0 MiB/s |  20.9 KiB |  00m00s
[66/82] perl-Data-Dumper-0:2.191-521.fc 100% |  18.3 MiB/s |  56.3 KiB |  00m00s
[67/82] perl-MIME-Base32-0:1.303-24.fc4 100% |   6.6 MiB/s |  20.4 KiB |  00m00s
[68/82] perl-URI-0:5.34-2.fc43.noarch   100% |  16.2 MiB/s | 149.3 KiB |  00m00s
[69/82] perl-libnet-0:3.15-521.fc43.noa 100% |  31.3 MiB/s | 128.3 KiB |  00m00s
[70/82] perl-Digest-0:1.20-520.fc43.noa 100% |   8.1 MiB/s |  24.8 KiB |  00m00s
[71/82] perl-Digest-MD5-0:2.59-520.fc43 100% |   5.8 MiB/s |  35.8 KiB |  00m00s
[72/82] perl-base-0:2.27-523.fc43.noarc 100% |   3.9 MiB/s |  15.8 KiB |  00m00s
[73/82] perl-Getopt-Std-0:1.14-523.fc43 100% |   3.7 MiB/s |  15.3 KiB |  00m00s
[74/82] perl-mro-0:1.29-523.fc43.x86_64 100% |   7.2 MiB/s |  29.5 KiB |  00m00s
[75/82] perl-B-0:1.89-523.fc43.x86_64   100% |  19.2 MiB/s | 177.3 KiB |  00m00s
[76/82] perl-overloading-0:0.02-523.fc4 100% |   3.1 MiB/s |  12.5 KiB |  00m00s
[77/82] perl-locale-0:1.13-523.fc43.noa 100% |   3.2 MiB/s |  13.1 KiB |  00m00s
[78/82] perl-File-stat-0:1.14-523.fc43. 100% |   4.1 MiB/s |  16.7 KiB |  00m00s
[79/82] perl-SelectSaver-0:1.02-523.fc4 100% |   2.8 MiB/s |  11.3 KiB |  00m00s
[80/82] perl-Class-Struct-0:0.68-523.fc 100% |   5.3 MiB/s |  21.7 KiB |  00m00s
[81/82] perl-FileHandle-0:2.05-523.fc43 100% |   3.7 MiB/s |  15.1 KiB |  00m00s
[82/82] perl-podlators-1:6.0.2-520.fc43 100% | 597.0 KiB/s | 128.3 KiB |  00m00s
--------------------------------------------------------------------------------
[82/82] Total                           100% |  39.2 MiB/s |  98.9 MiB |  00m03s
Running transaction
[ 1/84] Verify package files            100% | 392.0   B/s |  82.0   B |  00m00s
[ 2/84] Prepare transaction             100% | 656.0   B/s |  82.0   B |  00m00s
[ 3/84] Installing libmpc-0:1.3.1-8.fc4 100% | 158.3 MiB/s | 162.1 KiB |  00m00s
[ 4/84] Installing m4-0:1.4.21-1.fc43.x 100% | 107.9 MiB/s | 883.7 KiB |  00m00s
[ 5/84] Installing make-1:4.4.1-11.fc43 100% | 225.0 MiB/s |   1.8 MiB |  00m00s
[ 6/84] Installing bison-0:3.8.2-11.fc4 100% | 319.5 MiB/s |   3.5 MiB |  00m00s
[ 7/84] Installing flex-0:2.6.4-20.fc43 100% |  99.0 MiB/s | 811.3 KiB |  00m00s
[ 8/84] Installing cpp-0:15.2.1-7.fc43. 100% | 499.6 MiB/s |  38.0 MiB |  00m00s
[ 9/84] Installing groff-base-0:1.23.0- 100% | 137.3 MiB/s |   3.8 MiB |  00m00s
[10/84] Installing ncurses-0:6.5-7.2025 100% |  75.2 MiB/s | 616.4 KiB |  00m00s
[11/84] Installing perl-Digest-0:1.20-5 100% |   0.0   B/s |  37.1 KiB |  00m00s
[12/84] Installing perl-FileHandle-0:2. 100% |   0.0   B/s |   9.8 KiB |  00m00s
[13/84] Installing perl-B-0:1.89-523.fc 100% | 492.9 MiB/s | 504.7 KiB |  00m00s
[14/84] Installing perl-Digest-MD5-0:2. 100% |   0.0   B/s |  61.6 KiB |  00m00s
[15/84] Installing perl-libnet-0:3.15-5 100% | 287.8 MiB/s | 294.7 KiB |  00m00s
[16/84] Installing perl-Data-Dumper-0:2 100% |   0.0   B/s | 117.5 KiB |  00m00s
[17/84] Installing perl-MIME-Base32-0:1 100% |   0.0   B/s |  32.2 KiB |  00m00s
[18/84] Installing perl-URI-0:5.34-2.fc 100% | 137.6 MiB/s | 281.8 KiB |  00m00s
[19/84] Installing perl-IO-Socket-IP-0: 100% |   0.0   B/s | 102.2 KiB |  00m00s
[20/84] Installing perl-AutoLoader-0:5. 100% |   0.0   B/s |  21.0 KiB |  00m00s
[21/84] Installing perl-IO-Socket-SSL-0 100% | 701.7 MiB/s | 718.6 KiB |  00m00s
[22/84] Installing perl-locale-0:1.13-5 100% |   0.0   B/s |   6.5 KiB |  00m00s
[23/84] Installing perl-Net-SSLeay-0:1. 100% | 339.7 MiB/s |   1.4 MiB |  00m00s
[24/84] Installing perl-if-0:0.61.000-5 100% |   0.0   B/s |   6.2 KiB |  00m00s
[25/84] Installing perl-File-Path-0:2.1 100% |   0.0   B/s |  64.5 KiB |  00m00s
[26/84] Installing perl-Pod-Escapes-1:1 100% |   0.0   B/s |  25.9 KiB |  00m00s
[27/84] Installing perl-Text-Tabs+Wrap- 100% |   0.0   B/s |  23.9 KiB |  00m00s
[28/84] Installing perl-Time-Local-2:1. 100% |   0.0   B/s |  70.6 KiB |  00m00s
[29/84] Installing perl-Pod-Simple-1:3. 100% | 280.7 MiB/s | 574.9 KiB |  00m00s
[30/84] Installing perl-HTTP-Tiny-0:0.0 100% |   0.0   B/s | 156.4 KiB |  00m00s
[31/84] Installing perl-Class-Struct-0: 100% |   0.0   B/s |  25.9 KiB |  00m00s
[32/84] Installing perl-IPC-Open3-0:1.2 100% |   0.0   B/s |  28.5 KiB |  00m00s
[33/84] Installing perl-File-Temp-1:0.2 100% |   0.0   B/s | 164.1 KiB |  00m00s
[34/84] Installing perl-POSIX-0:2.23-52 100% | 225.4 MiB/s | 230.8 KiB |  00m00s
[35/84] Installing perl-Term-Cap-0:1.18 100% |   0.0   B/s |  30.6 KiB |  00m00s
[36/84] Installing perl-Term-ANSIColor- 100% |   0.0   B/s |  99.2 KiB |  00m00s
[37/84] Installing perl-podlators-1:6.0 100% |  39.2 MiB/s | 321.4 KiB |  00m00s
[38/84] Installing perl-Pod-Perldoc-0:3 100% |  23.6 MiB/s | 169.2 KiB |  00m00s
[39/84] Installing perl-File-stat-0:1.1 100% |   0.0   B/s |  13.1 KiB |  00m00s
[40/84] Installing perl-SelectSaver-0:1 100% |   0.0   B/s |   2.6 KiB |  00m00s
[41/84] Installing perl-Symbol-0:1.09-5 100% |   0.0   B/s |   7.3 KiB |  00m00s
[42/84] Installing perl-Socket-4:2.040- 100% | 119.4 MiB/s | 122.3 KiB |  00m00s
[43/84] Installing perl-Pod-Usage-4:2.0 100% |  14.3 MiB/s |  87.9 KiB |  00m00s
[44/84] Installing perl-IO-0:1.55-523.f 100% | 148.1 MiB/s | 151.7 KiB |  00m00s
[45/84] Installing perl-overloading-0:0 100% |   0.0   B/s |   5.6 KiB |  00m00s
[46/84] Installing perl-mro-0:1.29-523. 100% |   0.0   B/s |  42.7 KiB |  00m00s
[47/84] Installing perl-base-0:2.27-523 100% |   0.0   B/s |  13.0 KiB |  00m00s
[48/84] Installing perl-Fcntl-0:1.20-52 100% |   0.0   B/s |  49.9 KiB |  00m00s
[49/84] Installing perl-Text-ParseWords 100% |   0.0   B/s |  14.6 KiB |  00m00s
[50/84] Installing perl-Getopt-Long-1:2 100% |   0.0   B/s | 147.2 KiB |  00m00s
[51/84] Installing perl-Storable-1:3.37 100% | 227.4 MiB/s | 232.8 KiB |  00m00s
[52/84] Installing perl-overload-0:1.40 100% |   0.0   B/s |  72.0 KiB |  00m00s
[53/84] Installing perl-Getopt-Std-0:1. 100% |   0.0   B/s |  11.8 KiB |  00m00s
[54/84] Installing perl-File-Basename-0 100% |   0.0   B/s |  14.6 KiB |  00m00s
[55/84] Installing perl-vars-0:1.05-523 100% |   0.0   B/s |   4.3 KiB |  00m00s
[56/84] Installing perl-parent-1:0.244- 100% |   0.0   B/s |  11.0 KiB |  00m00s
[57/84] Installing perl-MIME-Base64-0:3 100% |   0.0   B/s |  44.3 KiB |  00m00s
[58/84] Installing perl-constant-0:1.33 100% |   0.0   B/s |  27.4 KiB |  00m00s
[59/84] Installing perl-Scalar-List-Uti 100% | 145.2 MiB/s | 148.7 KiB |  00m00s
[60/84] Installing perl-Errno-0:1.38-52 100% |   0.0   B/s |   8.8 KiB |  00m00s
[61/84] Installing perl-Encode-4:3.21-5 100% | 312.9 MiB/s |   4.7 MiB |  00m00s
[62/84] Installing perl-DynaLoader-0:1. 100% |   0.0   B/s |  32.5 KiB |  00m00s
[63/84] Installing perl-PathTools-0:3.9 100% | 180.2 MiB/s | 184.6 KiB |  00m00s
[64/84] Installing perl-Exporter-0:5.79 100% |   0.0   B/s |  55.6 KiB |  00m00s
[65/84] Installing perl-Carp-0:1.54-520 100% |  46.6 MiB/s |  47.7 KiB |  00m00s
[66/84] Installing perl-libs-4:5.42.2-5 100% | 323.6 MiB/s |  11.6 MiB |  00m00s
[67/84] Installing perl-interpreter-4:5 100% |  16.8 MiB/s | 120.5 KiB |  00m00s
[68/84] Installing cmake-filesystem-0:3 100% |   7.4 MiB/s |   7.6 KiB |  00m00s
[69/84] Installing elfutils-debuginfod- 100% |  12.0 MiB/s |  86.3 KiB |  00m00s
[70/84] Installing libpkgconf-0:2.3.0-3 100% |  77.4 MiB/s |  79.2 KiB |  00m00s
[71/84] Installing pkgconf-0:2.3.0-3.fc 100% |  12.7 MiB/s |  91.0 KiB |  00m00s
[72/84] Installing pkgconf-m4-0:2.3.0-3 100% |   0.0   B/s |  14.8 KiB |  00m00s
[73/84] Installing pkgconf-pkg-config-0 100% | 177.3 KiB/s |   1.8 KiB |  00m00s
[74/84] Installing openssl-devel-1:3.5. 100% | 310.9 MiB/s |   5.6 MiB |  00m00s
[75/84] Installing zlib-ng-compat-devel 100% |   0.0   B/s | 108.6 KiB |  00m00s
[76/84] Installing libzstd-devel-0:1.5. 100% |   0.0   B/s | 208.8 KiB |  00m00s
[77/84] Installing elfutils-libelf-deve 100% |   0.0   B/s |  85.7 KiB |  00m00s
[78/84] Installing jansson-0:2.14-3.fc4 100% |  88.3 MiB/s |  90.5 KiB |  00m00s
[79/84] Installing binutils-0:2.45.1-4. 100% | 595.2 MiB/s |  27.4 MiB |  00m00s
[80/84] Installing kernel-headers-0:6.1 100% | 195.2 MiB/s |   7.0 MiB |  00m00s
[81/84] Installing glibc-devel-0:2.42-1 100% | 147.1 MiB/s |   2.4 MiB |  00m00s
[82/84] Installing libxcrypt-devel-0:4. 100% |  32.6 MiB/s |  33.4 KiB |  00m00s
[83/84] Installing gcc-0:15.2.1-7.fc43. 100% | 629.5 MiB/s | 112.1 MiB |  00m00s
[84/84] Installing kernel-devel-0:6.19. 100% |   8.7 MiB/s |  91.9 MiB |  00m11s
Complete!
KERNEL=6.19.11-200.fc43.x86_64
ls: cannot access '/lib/modules/6.19.11-200.fc43.x86_64': No such file or directory
ls: cannot access '/lib/modules/6.19.11-200.fc43.x86_64/build': No such file or directory
ls: cannot access '/lib/modules/6.19.11-200.fc43.x86_64/source': No such file or directory
drwxr-xr-x. 1 root root 404 Apr 11 17:20 /usr/src/kernels/6.19.11-200.fc43.x86_64
<exited with exit code 2>

⏱️ 11m 59s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile\n@@\n RUN dnf install -y --setopt=install_weak_deps=False jq && \\\n     ./xrt/src/runtime_src/tools/scripts/xrtdeps.sh -docker && \\\n     dnf install -y --setopt=install_weak_deps=False \"kernel-devel-$(uname -r)\" kernel-headers && \\\n+    mkdir -p \"/lib/modules/$(uname -r)\" && \\\n+    ln -sf \"/usr/src/kernels/$(uname -r)\" \"/lib/modules/$(uname -r)/build\" && \\\n+    ln -sf \"/usr/src/kernels/$(uname -r)\" \"/lib/modules/$(uname -r)/source\" && \\\n     dnf clean all\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile

⏱️ 12m 5s

💬 Copilot

I’ve got the Fedora-specific fix now: the matching kernel-devel package exists, but Fedora doesn’t populate the /lib/modules/.../build symlink inside a plain container. I’ve added that bridge and am rerunning the package build.


⏱️ 14m 5s

bash

Build image after symlink fix

$ set -euo pipefail && podman build -t xdna-driver-fedora43-build . > podman-build.log 2>&1 || true && tail -n 120 podman-build.log

<command with shellId: rpm-build-fix is still running after 120 seconds. The command is still running but hasn't produced output yet. It may be waiting for input or still processing. Use read_bash to continue waiting, write_bash if you think it needs input, or stop_bash to stop it.>

⏱️ 14m 50s

read_bash

Waiting up to 60 seconds for command output

Arguments
{
  "shellId": "rpm-build-fix",
  "delay": 60
}
120 lines
>>>  + HAVE_iommu_paging_domain_alloc: yes
>>>  - HAVE_xen_phy_dma_ops: no
[ 71%] Built target core_common_library_objects
[ 71%] Built target aiebu_library_objects
[ 71%] Linking CXX static library libaiebu.a
[ 71%] Built target aiebu_static
>>>  - HAVE_xen_phy_dma_ops: no
[ 74%] Build out of tree amdxdna.ko
fatal: not a git repository (or any of the parent directories): .git
[INFO] BUILD Directory not exist or SRC Directory is newer
[INFO] Re-Generate BUILD_ROOT_DIR: /work/xdna-driver/Release/src/driver/amdxdna
fatal: not a git repository (or any of the parent directories): .git
>>>  - HAVE_7_0_kmalloc_ops: no
>>>  + HAVE_drm_gpu_sched_stat_reset: yes
[ 74%] Built target core_pcielinux_objects
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
>>>  + HAVE_6_17_drm_gpu_sched_stat_no_hang: yes
[ 74%] Built target legacy_driver
[ 74%] Tar amdxdna driver source code
[ 77%] Substitute amdxdna module version and re-tar
[ 77%] Built target driver_ver_tarball
>>>  + HAVE_6_13_drm_sched_start_errno: yes
[ 77%] Built target dtrace_library_objects
[ 77%] Linking CXX static library libcert_dtrace.a
[ 77%] Built target cert_dtrace_static
[ 77%] Linking CXX shared library libxrt_coreutil.so
[ 77%] Built target xrt_coreutil
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/cmd_fence.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/io.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/bo_import_export.cpp.o
[ 82%] Linking CXX shared library libxrt_core.so
[ 85%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/shim_test.cpp.o
[ 85%] Building CXX object test/xrt_test/CMakeFiles/xrt_test.elf.dir/xrt_test.cpp.o
[ 85%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/io_test.cpp.o
[ 85%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/dev_info.cpp.o
>>>  - HAVE_6_10_drm_sched_start_full_recovery: no
[ 85%] Built target xrt_core
[ 85%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/device.cpp.o
[ 85%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/buffer.cpp.o
[ 85%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/hwctx.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/platform.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/pcidev.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwctx.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/pcidrv_amdxdna.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/pcidev.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwctx.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/pcidev.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/fence.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/platform_host.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/tcp_server.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwq.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/pcidrv_virtgpu.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/platform_virtio.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/pcidrv.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/smi_xdna.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwq.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/hwq.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/dbg_hwq.cpp.o
>>>  + HAVE_6_16_bit_u64: yes
[100%] Linking CXX executable xrt_test.elf
[100%] Built target xrt_test.elf
>>>  - HAVE_7_0_amd_pmf_get_npu_data: no
>>>  + HAVE_6_14_drm_fdinfo_print_size: yes
[100%] Build amdxdna.ko
fatal: not a git repository (or any of the parent directories): .git
[INFO] BUILD Directory not exist or SRC Directory is newer
[INFO] Re-Generate BUILD_ROOT_DIR: /work/xdna-driver/Release/drivers/accel/amdxdna
fatal: not a git repository (or any of the parent directories): .git
[100%] Linking CXX executable shim_test.elf
[100%] Built target shim_test.elf
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[100%] Built target driver
[100%] Linking CXX shared library libxrt_driver_xdna.so
[100%] Built target xrt_driver_xdna
Install the project...
-- Install configuration: "Release"
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/version.json
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/amdxdna.tar.gz
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/dkms.conf
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/configure_kernel.sh
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/dkms_driver.sh
-- Installing: /work/xdna-driver/Release/bins/driver/amdxdna.ko
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./include/vaccel.h
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/pkgconfig/vxdna.pc
-- Installing: /work/xdna-driver/Release/bins/driver/amdxdna_legacy.ko
-- Installing: /work/xdna-driver/Release/bins/bin/shim_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/bin/shim_test.elf" to ""
-- Installing: /work/xdna-driver/Release/bins/bin/xrt_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/bin/xrt_test.elf" to ""
-- Installing: /work/xdna-driver/Release/bins/bin/xrt_test

real	0m26.215s
user	9m4.182s
sys	0m35.877s
Download npu1 NPUFW version 1.5.5.391:
./build/build.sh: line 102: wget: command not found
Error: building at STEP "RUN ./build/build.sh -release -j "$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +": while running runtime: exit status 127
<command with id: rpm-build-fix exited with exit code 0>

⏱️ 14m 51s

ℹ️ Notification

Shell "Build image after symlink fix" completed


⏱️ 14m 56s

💬 Copilot

The kernel-module build is working now. The next failure is smaller: the upstream packaging step downloads firmware and expects wget, so I’m adding that to the Fedora image and rerunning the final packaging pass.


⏱️ 14m 56s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile\n@@\n-RUN dnf install -y --setopt=install_weak_deps=False jq && \\\n+RUN dnf install -y --setopt=install_weak_deps=False jq wget && \\\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile

⏱️ 17m 0s

bash

Rebuild image with wget

$ set -euo pipefail && podman build -t xdna-driver-fedora43-build . > podman-build.log 2>&1 || true && tail -n 120 podman-build.log

<command with shellId: rpm-build-final is still running after 120 seconds. The command is still running but hasn't produced output yet. It may be waiting for input or still processing. Use read_bash to continue waiting, write_bash if you think it needs input, or stop_bash to stop it.>

⏱️ 17m 31s

read_bash

Waiting up to 60 seconds for command output

Arguments
{
  "shellId": "rpm-build-final",
  "delay": 60
}
120 lines
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/pcidev.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwctx.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/pcidev.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/pcidrv_amdxdna.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/pcidrv_virtgpu.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/platform_virtio.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/platform_host.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwq.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwq.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/dbg_hwq.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/platform.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/tcp_server.cpp.o
>>>  - HAVE_7_0_amd_pmf_get_npu_data: no
>>>  + HAVE_6_14_drm_fdinfo_print_size: yes
[ 97%] Build amdxdna.ko
fatal: not a git repository (or any of the parent directories): .git
[INFO] BUILD Directory not exist or SRC Directory is newer
[INFO] Re-Generate BUILD_ROOT_DIR: /work/xdna-driver/Release/drivers/accel/amdxdna
fatal: not a git repository (or any of the parent directories): .git
[100%] Linking CXX executable xrt_test.elf
[100%] Built target xrt_test.elf
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[100%] Built target driver
[100%] Linking CXX executable shim_test.elf
[100%] Built target shim_test.elf
[100%] Linking CXX shared library libxrt_driver_xdna.so
[100%] Built target xrt_driver_xdna
Install the project...
-- Install configuration: "Release"
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/version.json
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/amdxdna.tar.gz
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/dkms.conf
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/configure_kernel.sh
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/dkms_driver.sh
-- Installing: /work/xdna-driver/Release/bins/driver/amdxdna.ko
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./include/vaccel.h
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/pkgconfig/vxdna.pc
-- Installing: /work/xdna-driver/Release/bins/driver/amdxdna_legacy.ko
-- Installing: /work/xdna-driver/Release/bins/bin/shim_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/bin/shim_test.elf" to ""
-- Installing: /work/xdna-driver/Release/bins/bin/xrt_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/bin/xrt_test.elf" to ""
-- Installing: /work/xdna-driver/Release/bins/bin/xrt_test

real	0m25.682s
user	9m6.951s
sys	0m35.514s
Download npu1 NPUFW version 1.5.5.391:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/1502_00/npu.sbin.1.5.5.391' ...
Saving './amdxdna_bins/firmware/1502_00/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/1502_00/npu.sbin.1.5.5.391]
Download npu3 NPUFW version 1.1.0.206:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/npu.sbin.1.1.0.206' ...
Saving './amdxdna_bins/firmware/17f1_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/npu.sbin.1.1.0.206]
Download npu3 NPUFW version 1.0.0.28:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/cert.sbin.1.0.0.28' ...
Saving './amdxdna_bins/firmware/17f1_10/cert.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/cert.sbin.1.0.0.28]
Download npu3 NPUFW version 1.1.0.206:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/npu.sbin.1.1.0.206' ...
Saving './amdxdna_bins/firmware/17f2_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/npu.sbin.1.1.0.206]
Download npu3 NPUFW version 1.0.0.28:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/cert.sbin.1.0.0.28' ...
Saving './amdxdna_bins/firmware/17f2_10/cert.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/cert.sbin.1.0.0.28]
Download npu4 NPUFW version 1.1.2.64:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_10/1.7_npu.sbin.1.1.2.64' ...
Saving './amdxdna_bins/firmware/17f0_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_10/1.7_npu.sbin.1.1.2.64]
Download npu5 NPUFW version 1.1.2.65:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_11/1.7_npu.sbin.1.1.2.65' ...
Saving './amdxdna_bins/firmware/17f0_11/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_11/1.7_npu.sbin.1.1.2.65]
Download strx VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_strx.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a]
Download phx VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_phx.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a]
Download npu3 VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_npu3.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a]
cp: cannot stat '../tools/bins/*': No such file or directory
Error: building at STEP "RUN ./build/build.sh -release -j "$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +": while running runtime: exit status 1
<command with id: rpm-build-final exited with exit code 0>

⏱️ 17m 31s

ℹ️ Notification

Shell "Rebuild image with wget" completed


⏱️ 17m 36s

💬 Copilot

The build is almost there. The next upstream assumption is that tools/bins/* exists for packaging, but that directory isn’t present in this checkout, so I’m checking whether it should come from another source or if a harmless placeholder is enough for the RPM packaging step.


⏱️ 17m 36s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/tools.

/home/raymond/Development/amd/xdna-driver-fedora/repo/tools

amdxdna_deps.sh
bins
codingsty_check.sh
info.json
pre-commit

⏱️ 17m 36s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo

Arguments
{
  "pattern": "tools/bins|xbutil_validate|download_raw/xbutil_validate|cp -r ../tools/bins",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo",
  "output_mode": "content",
  "glob": "**/*.{sh,cmake,txt}",
  "-n": true,
  "-C": 2,
  "head_limit": 200
}
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/service_bundle.sh-88-	xrt-smi examine -d $DEVICE_BDF:0 > $1/xbutil_examine.txt
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/service_bundle.sh-89-	xrt-smi examine -d $DEVICE_BDF:0 -r all > $1/xbutil_examine_all.txt
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/service_bundle.sh:90:	xrt-smi validate -d $DEVICE_BDF:0 -r quick --verbose> $1/xbutil_validate.txt
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/service_bundle.sh-91-}
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/service_bundle.sh-92-

⏱️ 17m 39s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/tools/bins.

/home/raymond/Development/amd/xdna-driver-fedora/repo/tools/bins

configs

⏱️ 17m 39s

glob

/home/raymond/Development/amd/xdna-driver-fedora

"repo/tools/bins/**" in /home/raymond/Development/amd/xdna-driver-fedora

/home/raymond/Development/amd/xdna-driver-fedora/repo/tools/bins/configs/trace_events.json

⏱️ 17m 49s

bash

Inspect tools bins locally

$ set -euo pipefail && ls -la repo/tools/bins && ls -la repo/tools/bins/configs && file repo/tools/bins/configs/trace_events.json

10 lines
total 0
drwxr-xr-x. 1 raymond raymond  14 Apr 11 19:11 .
drwxr-xr-x. 1 raymond raymond 112 Apr 11 19:11 ..
drwxr-xr-x. 1 raymond raymond  34 Apr 11 19:11 configs
total 28
drwxr-xr-x. 1 raymond raymond    34 Apr 11 19:11 .
drwxr-xr-x. 1 raymond raymond    14 Apr 11 19:11 ..
-rw-r--r--. 1 raymond raymond 26108 Apr 11 19:11 trace_events.json
repo/tools/bins/configs/trace_events.json: JSON text data
<exited with exit code 0>

⏱️ 17m 49s

github-mcp-server-get_file_contents

tools/bins

Arguments
{
  "owner": "amd",
  "repo": "xdna-driver",
  "path": "tools/bins"
}
[{"type":"dir","size":0,"name":"configs","path":"tools/bins/configs","sha":"9869afc87b9ce13f1e340fea58a62432e46f899c","url":"https://api.github.com/repos/amd/xdna-driver/contents/tools/bins/configs?ref=464a4ba59ed927ec618c4be18e1fc3bb6104bed0","git_url":"https://api.github.com/repos/amd/xdna-driver/git/trees/9869afc87b9ce13f1e340fea58a62432e46f899c","html_url":"https://github.com/amd/xdna-driver/tree/464a4ba59ed927ec618c4be18e1fc3bb6104bed0/tools/bins/configs"}]

⏱️ 18m 25s

💬 Copilot

I’m making one small build-script fix in the local checkout: the packaging step is using a shell glob for tools/bins/*, and switching that to copy the directory contents directly is more robust for this container build.


⏱️ 18m 25s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/repo/build/build.sh\n@@\n-    cp -r ../tools/bins/* $XBUTIL_VALIDATE_BINS_DIR\n+    cp -r ../tools/bins/. $XBUTIL_VALIDATE_BINS_DIR\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/repo/build/build.sh

⏱️ 20m 31s

bash

Rebuild after copy fix

$ set -euo pipefail && podman build -t xdna-driver-fedora43-build . > podman-build.log 2>&1 || true && tail -n 160 podman-build.log

<command with shellId: rpm-build-package is still running after 120 seconds. The command is still running but hasn't produced output yet. It may be waiting for input or still processing. Use read_bash to continue waiting, write_bash if you think it needs input, or stop_bash to stop it.>

⏱️ 21m 2s

read_bash

Waiting up to 60 seconds for command output

Arguments
{
  "shellId": "rpm-build-package",
  "delay": 60
}
160 lines
>>>  - HAVE_xen_phy_dma_ops: no
[ 74%] Built target aiebu_library_objects
[ 74%] Linking CXX static library libaiebu.a
[ 74%] Built target aiebu_static
>>>  - HAVE_7_0_kmalloc_ops: no
>>>  + HAVE_drm_gpu_sched_stat_reset: yes
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[ 74%] Built target legacy_driver
[ 74%] Tar amdxdna driver source code
[ 77%] Substitute amdxdna module version and re-tar
[ 77%] Built target core_pcielinux_objects
[ 77%] Built target driver_ver_tarball
>>>  + HAVE_6_17_drm_gpu_sched_stat_no_hang: yes
[ 77%] Built target dtrace_library_objects
[ 77%] Linking CXX static library libcert_dtrace.a
[ 77%] Built target cert_dtrace_static
[ 77%] Linking CXX shared library libxrt_coreutil.so
[ 77%] Built target xrt_coreutil
[ 77%] Building CXX object test/xrt_test/CMakeFiles/xrt_test.elf.dir/xrt_test.cpp.o
[ 80%] Linking CXX shared library libxrt_core.so
[ 80%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/cmd_fence.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/io.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/bo_import_export.cpp.o
[ 85%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/shim_test.cpp.o
[ 85%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/io_test.cpp.o
[ 85%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/dev_info.cpp.o
[ 85%] Built target xrt_core
[ 85%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/device.cpp.o
[ 85%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/buffer.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/fence.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/hwctx.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/hwq.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/smi_xdna.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/pcidev.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/pcidrv.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/platform.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/dbg_hwq.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/pcidrv_amdxdna.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/tcp_server.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwctx.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/pcidev.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwq.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/platform_host.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/pcidev.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/platform_virtio.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/pcidrv_virtgpu.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwq.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwctx.cpp.o
>>>  + HAVE_6_13_drm_sched_start_errno: yes
>>>  - HAVE_6_10_drm_sched_start_full_recovery: no
[100%] Linking CXX executable xrt_test.elf
[100%] Built target xrt_test.elf
>>>  + HAVE_6_16_bit_u64: yes
>>>  - HAVE_7_0_amd_pmf_get_npu_data: no
>>>  + HAVE_6_14_drm_fdinfo_print_size: yes
[100%] Build amdxdna.ko
fatal: not a git repository (or any of the parent directories): .git
[INFO] BUILD Directory not exist or SRC Directory is newer
[INFO] Re-Generate BUILD_ROOT_DIR: /work/xdna-driver/Release/drivers/accel/amdxdna
fatal: not a git repository (or any of the parent directories): .git
[100%] Linking CXX executable shim_test.elf
[100%] Built target shim_test.elf
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[100%] Built target driver
[100%] Linking CXX shared library libxrt_driver_xdna.so
[100%] Built target xrt_driver_xdna
Install the project...
-- Install configuration: "Release"
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/version.json
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/amdxdna.tar.gz
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/dkms.conf
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/configure_kernel.sh
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./share/amdxdna/dkms_driver.sh
-- Installing: /work/xdna-driver/Release/bins/driver/amdxdna.ko
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_core.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_core.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_coreutil.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/Release/bins/./lib64/libxrt_driver_xdna.so
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./include/vaccel.h
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/Release/bins/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/Release/opt/xilinx/xrt/./lib64/pkgconfig/vxdna.pc
-- Installing: /work/xdna-driver/Release/bins/driver/amdxdna_legacy.ko
-- Installing: /work/xdna-driver/Release/bins/bin/shim_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/bin/shim_test.elf" to ""
-- Installing: /work/xdna-driver/Release/bins/bin/xrt_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/Release/bins/bin/xrt_test.elf" to ""
-- Installing: /work/xdna-driver/Release/bins/bin/xrt_test

real	0m25.693s
user	9m5.258s
sys	0m35.837s
Download npu1 NPUFW version 1.5.5.391:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/1502_00/npu.sbin.1.5.5.391' ...
Saving './amdxdna_bins/firmware/1502_00/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/1502_00/npu.sbin.1.5.5.391]
Download npu3 NPUFW version 1.1.0.206:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/npu.sbin.1.1.0.206' ...
Saving './amdxdna_bins/firmware/17f1_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/npu.sbin.1.1.0.206]
Download npu3 NPUFW version 1.0.0.28:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/cert.sbin.1.0.0.28' ...
Saving './amdxdna_bins/firmware/17f1_10/cert.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/cert.sbin.1.0.0.28]
Download npu3 NPUFW version 1.1.0.206:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/npu.sbin.1.1.0.206' ...
Saving './amdxdna_bins/firmware/17f2_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/npu.sbin.1.1.0.206]
Download npu3 NPUFW version 1.0.0.28:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/cert.sbin.1.0.0.28' ...
Saving './amdxdna_bins/firmware/17f2_10/cert.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/cert.sbin.1.0.0.28]
Download npu4 NPUFW version 1.1.2.64:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_10/1.7_npu.sbin.1.1.2.64' ...
Saving './amdxdna_bins/firmware/17f0_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_10/1.7_npu.sbin.1.1.2.64]
Download npu5 NPUFW version 1.1.2.65:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_11/1.7_npu.sbin.1.1.2.65' ...
Saving './amdxdna_bins/firmware/17f0_11/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_11/1.7_npu.sbin.1.1.2.65]
Download strx VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_strx.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a]
Download phx VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_phx.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a]
Download npu3 VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_npu3.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a]
cp: cannot stat '../tools/bins/.': No such file or directory
Error: building at STEP "RUN ./build/build.sh -release -j "$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +": while running runtime: exit status 1
<command with id: rpm-build-package exited with exit code 0>

⏱️ 21m 2s

ℹ️ Notification

Shell "Rebuild after copy fix" completed


⏱️ 21m 19s

💬 Copilot

I found the root cause: their script assumes it is started from build/, and I was invoking it from the repo root. I’m switching the Dockerfile to run from build/, which should unblock the final RPM packaging step.


⏱️ 21m 19s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile\n@@\n-RUN ./build/build.sh -release -j \"$(nproc)\" && \\\n+RUN cd build && ./build.sh -release -j \"$(nproc)\" && \\\n     mkdir -p /out && \\\n     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile

⏱️ 22m 4s

bash

Build final RPM image

$ set -euo pipefail && podman build -t xdna-driver-fedora43-build . > podman-build.log 2>&1 || true && tail -n 200 podman-build.log

199 lines
>>>  + HAVE_6_13_drm_sched_start_errno: yes
>>>  - HAVE_6_10_drm_sched_start_full_recovery: no
[ 77%] Built target core_common_library_objects
[ 77%] Built target dtrace_library_objects
[ 77%] Linking CXX static library libcert_dtrace.a
[ 77%] Built target cert_dtrace_static
[ 77%] Linking CXX shared library libxrt_coreutil.so
[ 77%] Built target xrt_coreutil
[ 80%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/bo_import_export.cpp.o
[ 80%] Building CXX object test/xrt_test/CMakeFiles/xrt_test.elf.dir/xrt_test.cpp.o
[ 80%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/dev_info.cpp.o
[ 80%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/io.cpp.o
[ 80%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/cmd_fence.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/shim_test.cpp.o
[ 85%] Linking CXX shared library libxrt_core.so
[ 85%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/io_test.cpp.o
>>>  + HAVE_6_16_bit_u64: yes
[ 85%] Built target xrt_core
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/fence.cpp.o
[ 85%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/hwq.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/pcidrv.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/hwctx.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/pcidev.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/buffer.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/smi_xdna.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/device.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwq.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/pcidev.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwctx.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/platform.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/dbg_hwq.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwq.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwctx.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/platform_virtio.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/pcidev.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/tcp_server.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/pcidrv_amdxdna.cpp.o
[ 94%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/pcidrv_virtgpu.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/platform_host.cpp.o
>>>  - HAVE_7_0_amd_pmf_get_npu_data: no
[100%] Linking CXX executable xrt_test.elf
[100%] Built target xrt_test.elf
>>>  + HAVE_6_14_drm_fdinfo_print_size: yes
[100%] Build amdxdna.ko
fatal: not a git repository (or any of the parent directories): .git
[INFO] BUILD Directory not exist or SRC Directory is newer
[INFO] Re-Generate BUILD_ROOT_DIR: /work/xdna-driver/build/Release/drivers/accel/amdxdna
fatal: not a git repository (or any of the parent directories): .git
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[100%] Built target driver
[100%] Linking CXX executable shim_test.elf
[100%] Built target shim_test.elf
[100%] Linking CXX shared library libxrt_driver_xdna.so
[100%] Built target xrt_driver_xdna
Install the project...
-- Install configuration: "Release"
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/version.json
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/amdxdna.tar.gz
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/dkms.conf
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/configure_kernel.sh
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/dkms_driver.sh
-- Installing: /work/xdna-driver/build/Release/bins/driver/amdxdna.ko
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_core.so.2.23.0
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_core.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/./lib64/libxrt_core.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_core.so
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_coreutil.so.2.23.0
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_coreutil.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/./lib64/libxrt_coreutil.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_coreutil.so
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_driver_xdna.so
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./include/vaccel.h
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/pkgconfig/vxdna.pc
-- Installing: /work/xdna-driver/build/Release/bins/driver/amdxdna_legacy.ko
-- Installing: /work/xdna-driver/build/Release/bins/bin/shim_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/bin/shim_test.elf" to ""
-- Installing: /work/xdna-driver/build/Release/bins/bin/xrt_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/bin/xrt_test.elf" to ""
-- Installing: /work/xdna-driver/build/Release/bins/bin/xrt_test

real	0m25.351s
user	8m59.130s
sys	0m36.600s
Download npu1 NPUFW version 1.5.5.391:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/1502_00/npu.sbin.1.5.5.391' ...
Saving './amdxdna_bins/firmware/1502_00/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/1502_00/npu.sbin.1.5.5.391]
Download npu3 NPUFW version 1.1.0.206:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/npu.sbin.1.1.0.206' ...
Saving './amdxdna_bins/firmware/17f1_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/npu.sbin.1.1.0.206]
Download npu3 NPUFW version 1.0.0.28:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/cert.sbin.1.0.0.28' ...
Saving './amdxdna_bins/firmware/17f1_10/cert.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/cert.sbin.1.0.0.28]
Download npu3 NPUFW version 1.1.0.206:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/npu.sbin.1.1.0.206' ...
Saving './amdxdna_bins/firmware/17f2_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/npu.sbin.1.1.0.206]
Download npu3 NPUFW version 1.0.0.28:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/cert.sbin.1.0.0.28' ...
Saving './amdxdna_bins/firmware/17f2_10/cert.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/cert.sbin.1.0.0.28]
Download npu4 NPUFW version 1.1.2.64:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_10/1.7_npu.sbin.1.1.2.64' ...
Saving './amdxdna_bins/firmware/17f0_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_10/1.7_npu.sbin.1.1.2.64]
Download npu5 NPUFW version 1.1.2.65:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_11/1.7_npu.sbin.1.1.2.65' ...
Saving './amdxdna_bins/firmware/17f0_11/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_11/1.7_npu.sbin.1.1.2.65]
Download strx VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_strx.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a]
Download phx VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_phx.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a]
Download npu3 VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_npu3.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a]
[  0%] Collect all out of tree driver source code
[  0%] Collect all driver source code
[  0%] Built target core_common_xdp_profile_objects
[  2%] Built target vxdna
[  5%] Built target core_common_runner_objects
[  5%] Built target core_common_objects
[  5%] Configuring kernel compatibility header
[  5%] Configuring out of tree kernel compatibility header
[  8%] Built target core_pciecommon_objects
[ 14%] Built target core_pcielinux_plugin_xdp_objects
>>> /work/xdna-driver/build/Release/drivers/accel/drivers/accel/amdxdna/config_kernel.h is up-to-date (kernel=6.19.11-200.fc43.x86_64)
>>> /work/xdna-driver/build/Release/src/driver/driver/amdxdna/config_kernel.h is up-to-date (kernel=6.19.11-200.fc43.x86_64)
[ 14%] Build amdxdna.ko
[ 17%] Build out of tree amdxdna.ko
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
[ 20%] Built target core_pcielinux_objects
[ 42%] Built target core_common_api_library_objects
[ 42%] Built target aiebu_library_objects
[ 42%] Built target aiebu_static
[ 57%] Built target core_common_library_objects
[ 74%] Built target dtrace_library_objects
[ 74%] Built target cert_dtrace_static
[ 74%] Built target xrt_coreutil
[ 77%] Built target xrt_core
[ 80%] Built target xrt_test.elf
[ 85%] Built target shim_test.elf
[ 97%] Built target xrt_driver_xdna
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[ 97%] Built target driver
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[ 97%] Built target legacy_driver
[100%] Built target driver_ver_tarball
Run CPack packaging tool...
CPack: Create package using RPM
CPack: Install projects
CPack: - Run preinstall target for: amd-xdna
CPack: - Install project: amd-xdna []
CPack: -   Install component: amdxdna
CPack: Create package
CPackRPM:Warning: CPACK_SET_DESTDIR is set (=ON) while requesting a relocatable package (CPACK_RPM_PACKAGE_RELOCATABLE is set): this is not supported, the package won't be relocatable.
CPackRPM: Will use GENERATED spec file: /work/xdna-driver/build/Release/_CPack_Packages/Linux/RPM/SPECS/xrt_plugin-amdxdna.spec
CPack: - package: /work/xdna-driver/build/Release/xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm generated.

real	0m6.716s
user	1m16.700s
sys	0m10.255s
COMMIT xdna-driver-fedora43-build
--> 7d664fa1b537
Successfully tagged localhost/xdna-driver-fedora43-build:latest
7d664fa1b537ab34d0eb7204028c68b6f48eeb39c5107e203eb3acd62c30073c
<exited with exit code 0>

⏱️ 22m 12s

💬 Copilot

The image build succeeded and the RPM is inside it. I’m copying the artifact into this directory now and then I’ll finish the task cleanly.


⏱️ 22m 12s

sql

Start extract todo

Arguments
{
  "description": "Start extract todo",
  "query": "UPDATE todos SET status = 'in_progress' WHERE id = 'build-and-extract-rpm';"
}
1 row(s) updated.

⏱️ 22m 13s

bash

Copy RPM out of image

$ set -euo pipefail && cid=$(podman create xdna-driver-fedora43-build) && trap 'podman rm -f "$cid" >/dev/null' EXIT && podman cp "$cid":/out/. . && ls -1 *.rpm

xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm
<exited with exit code 0>

⏱️ 22m 18s

sql

Finish build todos

Arguments
{
  "description": "Finish build todos",
  "query": "UPDATE todos SET status = 'done' WHERE id IN ('create-fedora-dockerfile', 'build-and-extract-rpm');"
}
2 row(s) updated.

⏱️ 22m 18s

bash

Show final artifact files

$ set -euo pipefail && rm -f podman-build.log && ls -lh *.rpm Dockerfile .dockerignore

-rw-r--r--. 1 raymond raymond  739 Apr 11 19:29 Dockerfile
-rw-r--r--. 1 raymond raymond   70 Apr 11 19:12 .dockerignore
-rw-r--r--. 1 raymond raymond 1.2M Apr 11 19:30 xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm
<exited with exit code 0>

⏱️ 22m 25s

task_complete

Built the Fedora 43 RPM and placed it in this directory a...

Arguments
{
  "summary": "Built the Fedora 43 RPM and placed it in this directory as **`xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm`**.\n\nI also added **`Dockerfile`** and **`.dockerignore`** here for the podman-based build, cloned the upstream repo into **`repo/`**, and made the local build invocation work on Fedora 43 by installing matching kernel headers in the container and running the upstream script from its expected `build/` directory."
}
Built the Fedora 43 RPM and placed it in this directory as **`xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm`**.

I also added **`Dockerfile`** and **`.dockerignore`** here for the podman-based build, cloned the upstream repo into **`repo/`**, and made the local build invocation work on Fedora 43 by installing matching kernel headers in the container and running the upstream script from its expected `build/` directory.

⏱️ 22m 25s

✓ Task Complete

Built the Fedora 43 RPM and placed it in this directory as xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm.

I also added Dockerfile and .dockerignore here for the podman-based build, cloned the upstream repo into repo/, and made the local build invocation work on Fedora 43 by installing matching kernel headers in the container and running the upstream script from its expected build/ directory.


⏱️ 29m 26s

👤 User

Create a script which executes the podman etcetera.

And we are missing packages:

❯ sudo dnf install ./xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm
[sudo] password for raymond:
Updating and loading repositories:
 Fedora 43 - x86_64 - Updates                                   100% |  26.9 KiB/s |  17.0 KiB |  00m01s
Repositories loaded.
Failed to resolve the transaction:
Problem: conflicting requests
  - nothing provides xrt-base \>= 2.23 needed by xrt_plugin-amdxdna-2.23-1.x86_64 from @commandline
  - nothing provides xrt-base \< 2.24 needed by xrt_plugin-amdxdna-2.23-1.x86_64 from @commandline
  - nothing provides libxrt_core.so.2()(64bit) needed by xrt_plugin-amdxdna-2.23-1.x86_64 from @commandline
  - nothing provides libxrt_coreutil.so.2()(64bit) needed by xrt_plugin-amdxdna-2.23-1.x86_64 from @commandline�[I

⏱️ 29m 38s

💬 Copilot

The plugin RPM is fine; the install failure is because it correctly depends on xrt-base and the XRT core libraries, which Fedora doesn’t already have on this machine. I’m wiring the build flow to produce the needed XRT RPM(s) too, and I’ll package that into a reusable script.


⏱️ 29m 38s

sql

Add followup todos

Arguments
{
  "description": "Add followup todos",
  "query": "INSERT INTO todos (id, title, description, status) VALUES\n  ('update-build-plan', 'Update build plan', 'Refresh the session plan to cover creating a reusable podman build script and producing any missing Fedora RPM dependencies needed to install the xdna plugin.', 'in_progress'),\n  ('inspect-xrt-rpms', 'Inspect XRT RPM build flow', 'Inspect the XRT submodule build scripts to determine which Fedora RPMs provide xrt-base and libxrt_core/libxrt_coreutil, and how to build them inside the container.', 'pending'),\n  ('create-build-script', 'Create podman build script', 'Add a script in the working directory that runs the podman build/extract flow and leaves the required RPM artifacts in the current directory.', 'pending'),\n  ('build-required-rpms', 'Build required RPMs', 'Use the containerized build flow to produce the missing Fedora RPMs, including xrt-base if needed, and place them in the current directory.', 'pending');\nINSERT INTO todo_deps (todo_id, depends_on) VALUES\n  ('inspect-xrt-rpms', 'update-build-plan'),\n  ('create-build-script', 'inspect-xrt-rpms'),\n  ('build-required-rpms', 'create-build-script');"
}
5 lines
Executed 2 statement(s):

1. INSERT
   4 row(s) inserted. Last inserted row ID: 7.

2. INSERT
   3 row(s) inserted. Last inserted row ID: 5.

⏱️ 29m 38s

view

view the file at /home/raymond/.copilot/session-state/135143ed-7465-4b1e-915a-3e1edba6673a/plan.md.

/home/raymond/.copilot/session-state/135143ed-7465-4b1e-915a-3e1edba6673a/plan.md

12 lines
1. Problem: Build the upstream amd/xdna-driver project on Fedora 43 using podman and a Dockerfile, and leave the resulting RPM artifact in the current working directory.
2. 
3. Approach:
4. 1. Clone the upstream repository with submodules into the working directory.
5. 2. Add a Fedora 43 Dockerfile that installs the build dependencies and runs the project's native release packaging flow.
6. 3. Build the container image with podman, extract the generated RPM artifact from the container, and place it in the current directory.
7. 
8. Notes:
9. - The upstream project already supports Fedora RPM packaging through CPack in CMake/pkg.cmake.
10. - The build may need XRT submodule dependencies resolved through the repo's dependency scripts.
11. - Only build-related files should be added to this directory; the RPM artifact is the required deliverable.
12.

⏱️ 29m 38s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt

Arguments
{
  "pattern": "xrt-base|libxrt_core|libxrt_coreutil|CPACK_GENERATOR|RPM|fedora",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt",
  "output_mode": "content",
  "glob": "**/*.{sh,cmake,spec,txt}",
  "-n": true,
  "head_limit": 250
}
120 lines
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/tests/build/build.sh:21:    if [[ $OSDIST == "centos" ]] || [[ $OSDIST == "amzn" ]] || [[ $OSDIST == "rhel" ]] || [[ $OSDIST == "fedora" ]] || [[ $OSDIST == "mariner" ]] || [[ $OSDIST == "almalinux" ]] || [[ $OSDIST == "rocky" ]]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build_yocto.sh:40:            RPM_ARCH_DIR="amd_cortexa78_mali_common"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build_yocto.sh:45:            RPM_ARCH_DIR="amd_cortexa72_common"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build_yocto.sh:183:    cp -rf "$yocto_path/build/tmp/deploy/rpm/$RPM_ARCH_DIR/zocl-"* "$yocto_path/rpms/"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build_yocto.sh:184:    cp -rf "$yocto_path/build/tmp/deploy/rpm/$RPM_ARCH_DIR/kernel-"* "$yocto_path/rpms/"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build_yocto.sh:200:    echo "RPMs copied to $yocto_path/rpms"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build_edge.sh:22:    echo "          -full, full                     Full Petalinux build which builds images along with XRT RPMs"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh:15:    if [[ $OSDIST == "centos" ]] || [[ $OSDIST == "amzn" ]] || [[ $OSDIST == "rhel" ]] || [[ $OSDIST == "fedora" ]] || [[ $OSDIST == "mariner" ]] || [[ $OSDIST == "almalinux" ]] || [[ $OSDIST == "rocky" ]]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/xocl_petalinux_compile/build.sh:44:if [[ $OSDIST == "centos" ]] || [[ $OSDIST == "amzn" ]] || [[ $OSDIST == "rhel" ]] || [[ $OSDIST == "fedora" ]]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/xocl_petalinux_compile/build.sh:48:        echo "sudo yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/cross_compile.sh:143:    echo "INFO: OS Flavor of SYSROOT cannot be determined, generating RPM packages of XRT"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackWin.cmake:9:SET(CPACK_GENERATOR WIX)
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/components.cmake:16:  elseif (${LINUX_FLAVOR} MATCHES "^(rhel|centos|fedora)")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/python/pybind11/CMakeLists.txt:43:  elseif (${LINUX_FLAVOR} MATCHES "^(rhel|centos|amzn|fedora|sles|almalinux|rocky)")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:20:SET(CPACK_RPM_COMPONENT_INSTALL ON)
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:54:# and uses python3 for the RPM package builds.
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:58:SET(CPACK_RPM_SPEC_MORE_DEFINE "%define __python python3")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:86:  SET(CPACK_GENERATOR "DEB;TGZ")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:149:    #   found for opt/xilinx/xrt/lib/libxrt_coreutil.so.2 (used by
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:152:    # does not realize that libxrt_coreutil.so is part of the same package but instead attempts
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:154:    # You can see this behavior by running dpkg-shlibdeps -v ./opt/xilinx/xrt/lib/libxrt_core.so inside
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:175:elseif (${LINUX_FLAVOR} MATCHES "^(rhel|centos|amzn|fedora|sles|mariner|almalinux|rocky)")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:184:    set(CPACK_RPM_PACKAGE_ARCHITECTURE "mips64el")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:187:  SET(CPACK_GENERATOR "RPM;TGZ")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:188:  SET(PACKAGE_KIND "RPM")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:191:  set(CPACK_RPM_XRT_PACKAGE_NAME "xrt")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:193:  SET(CPACK_RPM_XRT_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/postinst")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:194:  SET(CPACK_RPM_XRT_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/prerm")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:195:  SET(CPACK_RPM_ALVEO_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/postinst")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:196:  SET(CPACK_RPM_ALVEO_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/prerm")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:197:  SET(CPACK_RPM_AWS_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/aws/postinst")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:198:  SET(CPACK_RPM_AWS_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/aws/prerm")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:199:  SET(CPACK_RPM_AZURE_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/azure/postinst")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:200:  SET(CPACK_RPM_AZURE_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/azure/prerm")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:201:  SET(CPACK_RPM_CONTAINER_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/container/postinst")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:202:  SET(CPACK_RPM_CONTAINER_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/container/prerm")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:203:  SET(CPACK_RPM_EXCLUDE_FROM_AUTO_FILELIST_ADDITION "/usr/local" "/usr/src" "/opt" "/etc/OpenCL" "/etc/OpenCL/vendors" "/usr/lib" "/usr/lib/pkgconfig" "/usr/lib64/pkgconfig" "/lib" "/lib/firmware" "/usr/share/pkgconfig")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:205:  set(CPACK_RPM_BASE_PACKAGE_REQUIRES "ocl-icd >= 2.2, python3 >= 3.6")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:206:  set(CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES "ocl-icd-devel >= 2.2, libuuid-devel >= 2.23.2")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:207:  set(CPACK_RPM_NPU_PACKAGE_REQUIRES "xrt-base = ${CPACK_PACKAGE_VERSION}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:208:  set(CPACK_RPM_NPU-DEVEL_PACKAGE_REQUIRES "xrt-npu = ${CPACK_PACKAGE_VERSION}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:209:  set(CPACK_RPM_ALVEO_PACKAGE_REQUIRES "xrt-base = ${CPACK_PACKAGE_VERSION}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:210:  set(CPACK_RPM_ALVEO-DEVEL_PACKAGE_REQUIRES "xrt-alveo= ${CPACK_PACKAGE_VERSION}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:211:  set(CPACK_RPM_XRT-DEVEL_PACKAGE_REQUIRES "xrt = ${CPACK_PACKAGE_VERSION}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:213:  # If xrt-base-devel development component is built, then it depends
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:214:  # on xrt-base deployment.  For the cases where xrt-base-devel
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:215:  # is folded into deployment, we don't want xrt-base dependency.
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:217:    set(CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:218:      "${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}, \
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:219:      xrt-base = ${CPACK_PACKAGE_VERSION}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:225:    set(CPACK_RPM_BASE_PACKAGE_REQUIRES
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:226:      "${CPACK_RPM_BASE_PACKAGE_REQUIRES}, \
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:227:      ${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:232:    set(CPACK_RPM_NPU_PACKAGE_REQUIRES
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:233:      "${CPACK_RPM_BASE_PACKAGE_REQUIRES}, \
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:234:      ${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:239:    set(CPACK_RPM_ALVEO_PACKAGE_REQUIRES
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:240:      "${CPACK_RPM_BASE_PACKAGE_REQUIRES}, \
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:241:      ${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:247:    set(CPACK_RPM_XRT_PACKAGE_REQUIRES
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:248:      "${CPACK_RPM_BASE_PACKAGE_REQUIRES}, \
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:249:      ${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}, \
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:255:    set(CPACK_RPM_AWS_PACKAGE_REQUIRES "xrt-alveo = ${CPACK_PACKAGE_VERSION}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:260:    set(CPACK_RPM_AWS_PACKAGE_REQUIRES "xrt = ${CPACK_PACKAGE_VERSION}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:265:      SET(CPACK_RPM_PACKAGE_ARCHITECTURE "aarch64")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:268:      SET(CPACK_RPM_PACKAGE_ARCHITECTURE "armv7l")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:271:    SET(CPACK_RPM_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/postinst")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:272:    SET(CPACK_RPM_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/prerm")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:273:    SET(CPACK_RPM_PACKAGE_REQUIRES ${CPACK_RPM_XRT_PACKAGE_REQUIRES})
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake:277:  SET (CPACK_GENERATOR "TGZ")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/patch/CPackDeb.cmake:463:      # Check version of the dpkg-shlibdeps tool using CPackRPM method
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:487:    elif [ $FLAVOR == "fedora" ]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:550:        yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:566:        yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:582:        yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:595:        yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:608:        yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-10.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:621:        yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:708:    yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:718:    yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:728:    yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-10.noarch.rpm
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:751:    elif [ $FLAVOR == "fedora" ]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:784:    elif [ $FLAVOR == "fedora" ]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:787:            # see https://src.fedoraproject.org/rpms/rocclr/blob/f40/f/rocclr.spec#_104
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:798:            # https://packages.fedoraproject.org/pkgs/rocclr/rocm-hip-devel/
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/xrtdeps.sh:867:    if [ $FLAVOR == "fedora" ]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/sysroots_overlay.sh:7:# Usage : ./sysroots_overlay.sh -s <sysroot path which need to be overlaid> -r <file which contains RPM Paths>
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/sysroots_overlay.sh:28:	echo "		--rpms-file / -r 			File which contain Path of RPMS to be overlaid"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/sysroots_overlay.sh:52:RPMSPATH=""
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/sysroots_overlay.sh:63:			RPMSPATH=$1
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/sysroots_overlay.sh:77:if [ ! -f $RPMSPATH ]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/sysroots_overlay.sh:78:  error "$RPMSPATH does not exist"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/sysroots_overlay.sh:94:echo "[CMD] Extracting RPM"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/sysroots_overlay.sh:102:done < "$RPMSPATH"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgdsa.sh:814:    mkdir -p $opt_pkgdir/$dir/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgdsa.sh:877:    echo "* Locate x86_64 rpm for the dsa in: $opt_pkgdir/$dir/RPMS/x86_64"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgdsa.sh:878:    echo "* Locate noarch rpm for the dsa in: $opt_pkgdir/$dir/RPMS/noarch"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgdsa.sh:885:    mkdir -p $opt_pkgdir/$dir/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgdsa.sh:945:    echo "* Locate x86_64 rpm for the dsa in: $opt_pkgdir/$dir/RPMS/x86_64"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgdsa.sh:946:    echo "* Locate noarch rpm for the dsa in: $opt_pkgdir/$dir/RPMS/noarch"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgapu.sh:73:	mkdir -p $dir/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgapu.sh:109:	cp $dir/RPMS/noarch/*.rpm $PACKAGE_DIR
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgapp.sh:159:    mkdir -p $opt_pkgdir/$dir/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkgapp.sh:204:    echo "* Please locate rpm for dsa in: $opt_pkgdir/$dir/RPMS/x86_64"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkg_hw_platform.sh:789:    mkdir -p $opt_pkgdir/$dir/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkg_hw_platform.sh:852:    echo "* Locate x86_64 rpm for the xsa in: $opt_pkgdir/$dir/RPMS/x86_64"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkg_hw_platform.sh:853:    echo "* Locate noarch rpm for the xsa in: $opt_pkgdir/$dir/RPMS/noarch"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkg_hw_platform.sh:860:    mkdir -p $opt_pkgdir/$dir/{BUILD,RPMS,SOURCES,SPECS,SRPMS}
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkg_hw_platform.sh:920:    echo "* Locate x86_64 rpm for the xsa in: $opt_pkgdir/$dir/RPMS/x86_64"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/tools/scripts/pkg_hw_platform.sh:921:    echo "* Locate noarch rpm for the xsa in: $opt_pkgdir/$dir/RPMS/noarch"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/common/aiebu/cmake/cpack.cmake:4:set(CPACK_GENERATOR "TGZ")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/common/aiebu/cmake/components.cmake:6:  elseif (${LINUX_FLAVOR} MATCHES "^(rhel|centos|fedora)")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/common/aiebu/src/cpp/cxxopts/cmake/cxxopts.cmake:139:    set(CPACK_RPM_PACKAGE_NAME "${CPACK_PACKAGE_NAME}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/common/aiebu/src/cpp/cxxopts/cmake/cxxopts.cmake:150:    set(CPACK_RPM_PACKAGE_NAME "lib${PROJECT_NAME}-devel")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/common/aiebu/src/cpp/cxxopts/cmake/cxxopts.cmake:151:    set(CPACK_RPM_PACKAGE_SUGGESTS "${CPACK_DEBIAN_PACKAGE_SUGGESTS}")
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/common/aiebu/src/cpp/cxxopts/cmake/cxxopts.cmake:154:    set(CPACK_RPM_COMPONENT_INSTALL ON)
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/common/elf/CMakeLists.txt:138:    set(CPACK_GENERATOR ${_fmt})
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/common/aiebu/src/cpp/ELFIO/CMakeLists.txt:130:    set(CPACK_GENERATOR ${_fmt})
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/edge/skd/CMakeLists.txt:40:# dependencies for libxrt_core.  The link path is embedded correctly
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/core/edge/skd/CMakeLists.txt:41:# in libxrt_core.so but is for some reason ignored when cross

⏱️ 29m 45s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/.copilot/session-state/135143ed-7465-4b1e-915a-3e1edba6673a/plan.md\n@@\n-Problem: Build the upstream amd/xdna-driver project on Fedora 43 using podman and a Dockerfile, and leave the resulting RPM artifact in the current working directory.\n+Problem: Build the upstream amd/xdna-driver project on Fedora 43 using podman and a Dockerfile, leave the resulting RPM artifacts in the current working directory, and provide a reusable script to repeat the build.\n@@\n-2. Add a Fedora 43 Dockerfile that installs the build dependencies and runs the project's native release packaging flow.\n-3. Build the container image with podman, extract the generated RPM artifact from the container, and place it in the current directory.\n+2. Add a Fedora 43 Dockerfile that installs the build dependencies and runs the project's native release packaging flow.\n+3. Extend the containerized build to also produce the XRT RPMs required by the xdna plugin installation, especially xrt-base and the packages that own libxrt_core.so.2 and libxrt_coreutil.so.2.\n+4. Add a script in the working directory that runs the podman build and extracts the generated RPM artifacts into the current directory.\n+5. Rebuild and confirm the required RPM files are present in the current directory for local installation.\n@@\n-- Only build-related files should be added to this directory; the RPM artifact is the required deliverable.\n+- The first plugin RPM build succeeded, but installation showed that XRT runtime RPM dependencies are also required on Fedora 43.\n+- The upstream XRT submodule already has Fedora RPM packaging support, so the preferred fix is to build those RPMs rather than strip dependencies from the plugin package.\n*** End Patch\n"
Modified 1 file(s): /home/raymond/.copilot/session-state/135143ed-7465-4b1e-915a-3e1edba6673a/plan.md

⏱️ 29m 49s

sql

Advance todo statuses

Arguments
{
  "description": "Advance todo statuses",
  "query": "UPDATE todos SET status = 'done' WHERE id = 'update-build-plan'; UPDATE todos SET status = 'in_progress' WHERE id = 'inspect-xrt-rpms';"
}
5 lines
Executed 2 statement(s):

1. UPDATE
   1 row(s) updated.

2. UPDATE
   1 row(s) updated.

⏱️ 29m 49s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh.

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh (lines 1-260)

260 lines
1. #!/bin/bash
2. 
3. set -e
4. 
5. OSDIST=`grep '^ID=' /etc/os-release | awk -F= '{print $2}' | tr -d '"'`
6. VERSION=`grep '^VERSION_ID=' /etc/os-release | awk -F= '{print $2}' | tr -d '"'`
7. MAJOR=${VERSION%.*}
8. BUILDDIR=$(readlink -f $(dirname ${BASH_SOURCE[0]}))
9. CORE=`grep -c ^processor /proc/cpuinfo`
10. CMAKE=cmake
11. CMAKE_MAJOR_VERSION=`cmake --version | head -n 1 | awk '{print $3}' |awk -F. '{print $1}'`
12. CPU=`uname -m`
13. 
14. if [[ $CMAKE_MAJOR_VERSION != 3 ]]; then
15.     if [[ $OSDIST == "centos" ]] || [[ $OSDIST == "amzn" ]] || [[ $OSDIST == "rhel" ]] || [[ $OSDIST == "fedora" ]] || [[ $OSDIST == "mariner" ]] || [[ $OSDIST == "almalinux" ]] || [[ $OSDIST == "rocky" ]]; then
16.         CMAKE=cmake3
17.         if [[ ! -x "$(command -v $CMAKE)" ]]; then
18.             echo "$CMAKE is not installed, please run xrtdeps.sh"
19.             exit 1
20.         fi
21.     fi
22. fi
23. 
24. if [[ $CPU == "aarch64" ]] && [[ $OSDIST == "ubuntu" ]]; then
25.     # On ARM64 Ubuntu use GCC version 8+, GCC version 7 has
26.     # random Internal Compiler Issues compiling XRT C++14 code
27. 
28.     gcc_version=$(gcc --version 2> /dev/null | head -n1 | awk '{print $3}' | cut -d. -f1)
29.     gpp_version=$(g++ --version 2> /dev/null | head -n1 | awk '{print $3}' | cut -d. -f1)
30. 
31.     if [[ "$gcc_version" -ge 8 && "$gpp_version" -ge 8 ]]; then
32. 	export CC=gcc
33. 	export CXX=g++
34.     elif command -v gcc-8 >/dev/null 2>&1 && command -v g++-8 >/dev/null 2>&1; then
35. 	export CC=gcc-8
36. 	export CXX=g++-8
37.     else
38. 	echo "Installed gcc/g++ version is < 8 and gcc/g++ 8 is not available, please run xrt_deps.sh"
39. 	exit 1
40.     fi
41. fi
42. 
43. # Use GCC 9 on CentOS 8, RHEL 8, AlmaLinux 8 for std::filesystem
44. # The dependency is installed by xrtdeps.sh
45. if [[ $CPU == "x86_64" ]] && [[ $OSDIST == "centos" || $OSDIST == "rhel" || $OSDIST == "almalinux" || $OSDIST == "rocky" ]] && [[ $MAJOR == 8 ]]; then
46.     source /opt/rh/gcc-toolset-9/enable
47. fi
48. 
49. usage()
50. {
51.     echo "Usage: build.sh [options]"
52.     echo
53.     echo "[-help]                     List this help"
54.     echo "[clean|-clean]              Remove build directories"
55.     echo "[-ci]                       Build is initiated by CI"
56.     echo "[-dbg]                      Build debug library only (default)"
57.     echo "[-opt]                      Build optimized library only (default)"
58.     echo "[-edge]                     Build edge of x64.  Turns off opt and dbg"
59.     echo "[-hip]                      Enable hip bindings"
60.     echo "[-disable-werror]           Disable compilation with warnings as error"
61.     echo "[-nocmake]                  Skip CMake call"
62.     echo "[-cmake-flags <flags>]      Extra flags to pass to CMake"
63.     echo "[-noert]                    Do not treat missing ERT FW as a build error"
64.     echo "[-noinit]                   Do not initialize Git submodules"
65.     echo "[-noctest]                  Skip unit tests"
66.     echo "[-npu]                      Build for NPU only, implies -noert and disables bundling of Alveo Linux drivers"
67.     echo "[-with-static-boost <boost> Build binaries using static linking of boost from specified boost install"
68.     echo "[-clangtidy]                Run clang-tidy as part of build"
69.     echo "[-pskernel]                 Enable building of POC ps kernel"
70.     echo "[-cppstd]                   Cpp standard (default: 17)"
71.     echo "[-docs]                     Enable documentation generation with sphinx"
72.     echo "[-j <n>]                    Compile parallel (default: system cores)"
73.     echo "[-ccache]                   Build using RDI's compile cache"
74.     echo "[-toolchain <file>]         Extra toolchain file to configure CMake"
75.     echo "[-driver]                   Include building driver code"
76.     echo "[-xclbinutil]               Build xclbinutil only"
77.     echo "[-checkpatch]               Run checkpatch.pl on driver code"
78.     echo "[-verbose]                  Turn on verbosity when compiling"
79.     echo "[-install_prefix <path>]    set CMAKE_INSTALL_PREFIX to path"
80.     echo "[-ertbsp <dir>]             Path to directory with pre-downloaded BSP files for building ERT (default: download BSP files during build time)"
81.     echo "[-ertfw <dir>]              Path to directory with pre-built ert firmware (default: build the firmware)"
82.     echo ""
83.     echo "ERT firmware is built if and only if MicroBlaze gcc compiler can be located."
84.     echo "When compiler is not accesible, use -ertfw to specify path to directory with"
85.     echo "pre-built ert fw to include in XRT packages"
86.     echo ""
87.     echo "Compile caching is enabled with '-ccache' but requires access to internal network."
88.     echo
89.     echo "Linking of XRT with static boost, resolves all boost references in XRT binaries."
90.     echo "The specified install of boost must be compiled with -fPIC.  The script "
91.     echo "src/runtime_src/tools/script/boost.sh can be used to download and build boost"
92.     echo "for use with the '-with-static-boost' option."
93. 
94.     exit 1
95. }
96. 
97. clean=0
98. ci=0
99. docs=0
100. verbose=""
101. driver=0
102. checkpatch=0
103. jcore=$CORE
104. opt=1
105. dbg=1
106. edge=0
107. nocmake=0
108. init_submodule=1
109. nobuild=0
110. noctest=0
111. noert=0
112. static_boost=""
113. ertbsp=""
114. ertfw=""
115. werror=1
116. alveo_build=0
117. npu_build=0
118. base_build=0
119. xclbinutil=0
120. xrt_install_prefix="/opt/xilinx/xrt"
121. cmake_flags="-DCMAKE_EXPORT_COMPILE_COMMANDS=ON"
122. 
123. while [ $# -gt 0 ]; do
124.     case "$1" in
125.         -help)
126.             usage
127.             ;;
128.         clean|-clean)
129.             clean=1
130.             shift
131.             ;;
132.         -ci)
133.             ci=1
134.             shift
135.             ;;
136.         -noert)
137.             noert=1
138.             shift
139.             ;;
140.         -dbg)
141.             dbg=1
142.             opt=0
143.             shift
144.             ;;
145.         -ertbsp)
146.             shift
147.             ertbsp=$1
148.             shift
149.             ;;
150.         -ertfw)
151.             shift
152.             ertfw=$1
153.             shift
154.             ;;
155.         -edge)
156.             shift
157.             cmake_flags+=" -DXRT_EDGE=1"
158.             edge=1
159.             ;;
160.         -hip)
161.             shift
162.             cmake_flags+=" -DXRT_ENABLE_HIP=ON"
163.             ;;
164.         -base)
165.             shift
166.             base_build=1
167.             noert=1
168.             cmake_flags+=" -DXRT_BASE=1"
169.             ;;
170.         -alveo)
171.             shift
172.             alveo_build=1
173.             cmake_flags+=" -DXRT_ALVEO=1"
174.             ;;
175. 	-npu)
176.             shift
177. 	    npu_build=1
178. 	    noert=1
179. 	    cmake_flags+=" -DXRT_NPU=1"
180.             ;;
181.         -opt)
182.             dbg=0
183.             opt=1
184.             shift
185.             ;;
186.         -cmake-flags)
187.             shift
188.             cmake_flags+=" $1"
189.             shift
190.             ;;
191.         -nocmake)
192.             nocmake=1
193.             shift
194.             ;;
195.         -noinit)
196.             init_submodule=0
197.             shift
198.             ;;
199.         -noctest)
200.             noctest=1
201.             shift
202.             ;;
203.         -disable-werror|--disable-werror)
204.             werror=0
205.             shift
206.             ;;
207.         -j)
208.             shift
209.             jcore=$1
210.             shift
211.             ;;
212.         -ccache)
213.             export CCACHE_DIR=${CCACHE_DIR:-/scratch/ccache/$USER}
214.             mkdir -p $CCACHE_DIR
215.             cmake_flags+=" -DXRT_CCACHE=1"
216.             shift
217.             ;;
218.         -cppstd)
219.             shift
220.             cmake_flags+=" -DCMAKE_CXX_STANDARD=$1"
221.             shift
222.             ;;
223.         -toolchain)
224.             shift
225.             cmake_flags+=" -DCMAKE_TOOLCHAIN_FILE=$1"
226.             shift
227.             ;;
228.         -checkpatch)
229.             checkpatch=1
230.             shift
231.             ;;
232. 	docs|-docs)
233.             docs=1
234.             dbg=0
235.             nobuild=1
236.             shift
237.             ;;
238.         -driver)
239.             driver=1
240.             shift
241.             ;;
242.         -clangtidy)
243.             cmake_flags+=" -DXRT_CLANG_TIDY=ON"
244.             shift
245.             ;;
246.         -pskernel)
247.             cmake_flags+=" -DXRT_PSKERNEL_BUILD=ON"
248.             shift
249.             ;;
250.         -xclbinutil)
251.             xclbinutil=1
252.             shift
253.             ;;
254.         -verbose)
255.             verbose="VERBOSE=1"
256.             shift
257.             ;;
258.         -install_prefix)
259.             shift
260.             xrt_install_prefix=$1

⏱️ 29m 49s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake.

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/cpackLin.cmake (lines 175-260)

86 lines
175. elseif (${LINUX_FLAVOR} MATCHES "^(rhel|centos|amzn|fedora|sles|mariner|almalinux|rocky)")
176.   execute_process(
177.     COMMAND uname -m
178.     OUTPUT_VARIABLE CPACK_ARCH
179.     OUTPUT_STRIP_TRAILING_WHITESPACE
180.   )
181. 
182.   if (${CPACK_ARCH} MATCHES "^mips64")
183.     SET(CPACK_ARCH "mips64el")
184.     set(CPACK_RPM_PACKAGE_ARCHITECTURE "mips64el")
185.   endif()
186. 
187.   SET(CPACK_GENERATOR "RPM;TGZ")
188.   SET(PACKAGE_KIND "RPM")
189.   # Modify the package name for the xrt runtime and development component
190.   # Syntax is set(CPACK_<GENERATOR>_<COMPONENT>_PACKAGE_NAME "<name">)
191.   set(CPACK_RPM_XRT_PACKAGE_NAME "xrt")
192. 
193.   SET(CPACK_RPM_XRT_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/postinst")
194.   SET(CPACK_RPM_XRT_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/prerm")
195.   SET(CPACK_RPM_ALVEO_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/postinst")
196.   SET(CPACK_RPM_ALVEO_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/prerm")
197.   SET(CPACK_RPM_AWS_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/aws/postinst")
198.   SET(CPACK_RPM_AWS_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/aws/prerm")
199.   SET(CPACK_RPM_AZURE_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/azure/postinst")
200.   SET(CPACK_RPM_AZURE_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/azure/prerm")
201.   SET(CPACK_RPM_CONTAINER_POST_INSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/container/postinst")
202.   SET(CPACK_RPM_CONTAINER_PRE_UNINSTALL_SCRIPT_FILE "${CMAKE_CURRENT_BINARY_DIR}/container/prerm")
203.   SET(CPACK_RPM_EXCLUDE_FROM_AUTO_FILELIST_ADDITION "/usr/local" "/usr/src" "/opt" "/etc/OpenCL" "/etc/OpenCL/vendors" "/usr/lib" "/usr/lib/pkgconfig" "/usr/lib64/pkgconfig" "/lib" "/lib/firmware" "/usr/share/pkgconfig")
204. 
205.   set(CPACK_RPM_BASE_PACKAGE_REQUIRES "ocl-icd >= 2.2, python3 >= 3.6")
206.   set(CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES "ocl-icd-devel >= 2.2, libuuid-devel >= 2.23.2")
207.   set(CPACK_RPM_NPU_PACKAGE_REQUIRES "xrt-base = ${CPACK_PACKAGE_VERSION}")
208.   set(CPACK_RPM_NPU-DEVEL_PACKAGE_REQUIRES "xrt-npu = ${CPACK_PACKAGE_VERSION}")
209.   set(CPACK_RPM_ALVEO_PACKAGE_REQUIRES "xrt-base = ${CPACK_PACKAGE_VERSION}")
210.   set(CPACK_RPM_ALVEO-DEVEL_PACKAGE_REQUIRES "xrt-alveo= ${CPACK_PACKAGE_VERSION}")
211.   set(CPACK_RPM_XRT-DEVEL_PACKAGE_REQUIRES "xrt = ${CPACK_PACKAGE_VERSION}")
212. 
213.   # If xrt-base-devel development component is built, then it depends
214.   # on xrt-base deployment.  For the cases where xrt-base-devel
215.   # is folded into deployment, we don't want xrt-base dependency.
216.   if (${XRT_BASE_DEV_COMPONENT} STREQUAL "base-devel")
217.     set(CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES
218.       "${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}, \
219.       xrt-base = ${CPACK_PACKAGE_VERSION}")
220.   endif()
221.   
222.   # If base package combines deployment and development, then
223.   # include development dependencies
224.   if (${XRT_BASE_DEV_COMPONENT} STREQUAL "base")
225.     set(CPACK_RPM_BASE_PACKAGE_REQUIRES
226.       "${CPACK_RPM_BASE_PACKAGE_REQUIRES}, \
227.       ${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}")
228.   endif()
229.       
230.   # If base is included in npu, then include base dependencies
231.   if (${XRT_BASE_DEV_COMPONENT} STREQUAL "npu")
232.     set(CPACK_RPM_NPU_PACKAGE_REQUIRES
233.       "${CPACK_RPM_BASE_PACKAGE_REQUIRES}, \
234.       ${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}")
235.   endif()
236. 
237.   # If base is included in alveo, then include base dependencies
238.   if (${XRT_BASE_DEV_COMPONENT} STREQUAL "alveo")
239.     set(CPACK_RPM_ALVEO_PACKAGE_REQUIRES
240.       "${CPACK_RPM_BASE_PACKAGE_REQUIRES}, \
241.       ${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}")
242.   endif()
243. 
244.   # If base is included in xrt, then include base dependencies
245.   # along with dmks and udev.  This is true for XRT legacy
246.   if (${XRT_BASE_DEV_COMPONENT} STREQUAL "xrt")
247.     set(CPACK_RPM_XRT_PACKAGE_REQUIRES
248.       "${CPACK_RPM_BASE_PACKAGE_REQUIRES}, \
249.       ${CPACK_RPM_BASE-DEVEL_PACKAGE_REQUIRES}, \
250.       dkms")
251.   endif()
252. 
253.   # If base component is alveo, then aws has a dependency on alveo
254.   if (${XRT_BASE_COMPONENT} STREQUAL "alveo")
255.     set(CPACK_RPM_AWS_PACKAGE_REQUIRES "xrt-alveo = ${CPACK_PACKAGE_VERSION}")
256.   endif()
257. 
258.   # If base component is xrt, then aws has a dependency on xrt
259.   if (${XRT_BASE_COMPONENT} STREQUAL "xrt")
260.     set(CPACK_RPM_AWS_PACKAGE_REQUIRES "xrt = ${CPACK_PACKAGE_VERSION}")

⏱️ 29m 54s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh

Arguments
{
  "pattern": "cpack|package|xrt-base|xrt-npu|XRT_BASE_COMPONENT|XRT_BASE_DEV_COMPONENT",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh",
  "output_mode": "content",
  "-n": true,
  "-C": 3,
  "head_limit": 250
}
25 lines
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-82-    echo ""
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-83-    echo "ERT firmware is built if and only if MicroBlaze gcc compiler can be located."
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-84-    echo "When compiler is not accesible, use -ertfw to specify path to directory with"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh:85:    echo "pre-built ert fw to include in XRT packages"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-86-    echo ""
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-87-    echo "Compile caching is enabled with '-ccache' but requires access to internal network."
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-88-    echo
--
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-330-        echo "* MicroBlaze firmware will not be built.                       *"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-331-        echo "* To treat as a warning use -noert option.                     *"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-332-        echo "****************************************************************"
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh:333:        # The ERT FW is needed when platform packages are installed and
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-334-        # creates xsabin files. Without FW the XRT build cannot be used
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh:335:        # to install platform packages.
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-336-        if [[ $noert == 0 ]]; then
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-337-            exit 1
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-338-        fi
--
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-403-          time ctest --output-on-failure
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-404-      fi
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-405-
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh:406:      time make package
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-407-  fi
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-408-
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh-409-  if [[ $docs == 1 ]]; then

⏱️ 29m 54s

rg

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src

Arguments
{
  "pattern": "XRT_BASE_COMPONENT|XRT_BASE_DEV_COMPONENT",
  "path": "/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src",
  "output_mode": "content",
  "glob": "**/*.{cmake,txt}",
  "-n": true,
  "-C": 2,
  "head_limit": 200
}
7 lines
Output too large to read at once (53.2 KB). Saved to: /tmp/copilot-tool-output-1775929108687-j3x5h4.txt
Consider using tools like grep (for searching), head/tail (for viewing start/end), view with view_range (for specific sections), or jq (for JSON) to examine portions of the output.

Preview (first 500 chars):
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/xrt/xrt++/CMakeLists.txt-4-
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/xrt/xrt++/CMakeLists.txt-5-# Preserve legacy behavior in legacy XRT package. The component
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/xrt/xrt++/CMakeLists.txt:6:# setup will have defined XRT_BASE_DEV_COMPONENT to XRT
/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/runtime_src/xr

⏱️ 30m 0s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh.

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/build/build.sh (lines 280-430)

151 lines
280. debug_dir=${DEBUG_DIR:-Debug}
281. release_dir=${REL_DIR:-Release}
282. 
283. # By default compile with warnings as errors.
284. # Update every time CMake is generating makefiles.
285. # Disable with '-disable-werror' option.
286. cmake_flags+=" -DXRT_ENABLE_WERROR=$werror"
287. 
288. # set CMAKE_INSTALL_PREFIX
289. cmake_flags+=" -DCMAKE_INSTALL_PREFIX=$xrt_install_prefix"
290. 
291. here=$PWD
292. cd $BUILDDIR
293. 
294. if [[ $clean == 1 ]]; then
295.     echo $PWD
296.     echo "/bin/rm -rf $debug_dir $release_dir $edge_dir"
297.     /bin/rm -rf $debug_dir $release_dir $edge_dir
298.     exit 0
299. fi
300. 
301. if [[ ! -z $ertbsp ]]; then
302.     echo "export ERT_BSP_DIR=$ertbsp"
303.     export ERT_BSP_DIR=$ertbsp
304. fi
305. 
306. if [[ ! -z $ertfw ]]; then
307.     echo "export XRT_FIRMWARE_DIR=$ertfw"
308.     export XRT_FIRMWARE_DIR=$ertfw
309. fi
310. 
311. if [[ ! -z $static_boost ]]; then
312.     echo "export XRT_BOOST_INSTALL=$static_boost"
313.     export XRT_BOOST_INSTALL=$static_boost
314. fi
315. 
316. if [[ ! -z ${XRT_BOOST_INSTALL:+x} ]]; then
317.     if [[ ! -d ${XRT_BOOST_INSTALL}/include ]] || [[ ! -d ${XRT_BOOST_INSTALL}/lib ]]; then
318.         echo "Incomplete boost install specified, please use runtime_src/tools/script/boost.sh"
319.         exit 1
320.     fi
321.     echo "Linking XRT binaries with static boost libraries"
322. fi
323. 
324. # we pick microblaze toolchain from Vitis install
325. if [[ -z ${XILINX_VITIS:+x} ]] || [[ ! -d ${XILINX_VITIS} ]]; then
326.     export XILINX_VITIS=/proj/xbuilds/2023.1_released/installs/lin64/Vitis/2023.1
327.     if [[ ! -d ${XILINX_VITIS} ]]; then
328.         echo "****************************************************************"
329.         echo "* XILINX_VITIS is undefined or not accessible.                 *"
330.         echo "* MicroBlaze firmware will not be built.                       *"
331.         echo "* To treat as a warning use -noert option.                     *"
332.         echo "****************************************************************"
333.         # The ERT FW is needed when platform packages are installed and
334.         # creates xsabin files. Without FW the XRT build cannot be used
335.         # to install platform packages.
336.         if [[ $noert == 0 ]]; then
337.             exit 1
338.         fi
339.     fi
340. fi
341. 
342. #If git modules config file exist then try to clone them
343. GIT_MODULES=$BUILDDIR/../.gitmodules
344. if [[ -f "$GIT_MODULES" && $init_submodule == 1 ]]; then
345.     cd $BUILDDIR/../
346.     echo "Updating Git XRT submodule, use -noinit option to avoid updating"
347.     git submodule update --init --recursive
348.     cd $BUILDDIR
349. fi
350. 
351. if [[ $dbg == 1 ]]; then
352.   mkdir -p $debug_dir
353.   cd $debug_dir
354. 
355.   cmake_flags+=" -DCMAKE_BUILD_TYPE=Debug"
356. 
357.   if [[ $nocmake == 0 ]]; then
358.     if [[ $xclbinutil == 1 ]]; then
359.       # xclbinutil only build
360.       cmake_flags+=" -DXRT_SOURCE_DIR=$BUILDDIR/../src"
361.       echo "$CMAKE $cmake_flags ../../src/runtime_src/tools/xclbinutil"
362.       time $CMAKE $cmake_flags ../../src/runtime_src/tools/xclbinutil
363.     else
364.       # Full build
365.       echo "$CMAKE $cmake_flags ../../src"
366.       time $CMAKE $cmake_flags ../../src
367.     fi
368.   fi
369. 
370.   echo "make -j $jcore $verbose DESTDIR=$PWD install"
371.   time make -j $jcore $verbose DESTDIR=$PWD install
372. 
373.   if [[ $noctest == 0 ]]; then
374.       time ctest --output-on-failure
375.   fi
376.   cd $BUILDDIR
377. fi
378. 
379. if [[ $opt == 1 ]]; then
380.   mkdir -p $release_dir
381.   cd $release_dir
382. 
383.   cmake_flags+=" -DCMAKE_BUILD_TYPE=Release"
384. 
385.   if [[ $nocmake == 0 ]]; then
386.     if [[ $xclbinutil == 1 ]]; then
387.       # xclbinutil only build
388.       cmake_flags+=" -DXRT_SOURCE_DIR=$BUILDDIR/../src"
389.       echo "$CMAKE $cmake_flags ../../src/runtime_src/tools/xclbinutil"
390.       time $CMAKE $cmake_flags ../../src/runtime_src/tools/xclbinutil
391.     else
392.       # Full build
393.       echo "$CMAKE $cmake_flags ../../src"
394.       time $CMAKE $cmake_flags ../../src
395.     fi
396.   fi
397. 
398.   if [[ $nobuild == 0 ]]; then
399.       echo "make -j $jcore $verbose DESTDIR=$PWD install"
400.       time make -j $jcore $verbose DESTDIR=$PWD install
401. 
402.       if [[ $noctest == 0 ]]; then
403.           time ctest --output-on-failure
404.       fi
405. 
406.       time make package
407.   fi
408. 
409.   if [[ $docs == 1 ]]; then
410.       echo "make xrt_docs"
411.       make xrt_docs
412.   fi
413. 
414.   if [[ $driver == 1 ]]; then
415.     unset CC
416.     unset CXX
417.     echo "make -C usr/src/xrt-2.23.0/driver/xocl"
418.     make -C usr/src/xrt-2.23.0/driver/xocl
419.     if [[ $CPU == "aarch64" ]]; then
420. 	# I know this is dirty as it messes up the source directory with build artifacts but this is the
421. 	# quickest way to enable native zocl build in Travis CI environment for aarch64
422. 	ZOCL_SRC=`readlink -f ../../src/runtime_src/core/edge/drm/zocl`
423. 	make -C $ZOCL_SRC EXTRA_CFLAGS=-D__NONE_PETALINUX__
424.     fi
425.   fi
426.   cd $BUILDDIR
427. fi
428. 
429. if [[ $checkpatch == 1 ]]; then
430.     # check only driver released files

⏱️ 30m 0s

view

view the file at /home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/components.cmake.

/home/raymond/Development/amd/xdna-driver-fedora/repo/xrt/src/CMake/components.cmake (lines 1-220)

138 lines
1. # SPDX-License-Identifier: Apache-2.0
2. # Copyright (C) 2024-2025 Advanced Micro Devices, Inc. All rights reserved.
3. 
4. # Custom variables imported by this CMake stub which should be defined
5. # by parent CMake: LINUX_FLAVOR
6. 
7. # The default XRT build is legacy
8. if (NOT XRT_BASE AND NOT XRT_NPU AND NOT XRT_ALVEO AND NOT XRT_EDGE)
9.   message("-- Defaulting to legacy XRT build")
10.   set(XRT_XRT 1)
11. endif()
12. 
13. if (NOT WIN32)
14.   if (${LINUX_FLAVOR} MATCHES "^(ubuntu|debian)")
15.     set (XRT_DEV_COMPONENT_SUFFIX "-dev")
16.   elseif (${LINUX_FLAVOR} MATCHES "^(rhel|centos|fedora)")
17.     set (XRT_DEV_COMPONENT_SUFFIX "-devel")
18.   endif()
19. endif()
20. 
21. # NSIS packager cannot handle '-' in component names
22. if (WIN32)
23.   set (XRT_DEV_COMPONENT_SUFFIX "_dev")
24. endif()   
25. 
26. # Enable development package by specifying development component name
27. # If XRT_{PKG}_DEV_COMPONENT is same XRT_{PKG}_COMPONENT then only
28. # that package is created with both development and run-time content.
29. # XRT currently supports building four packages: base, npu, alveo, and
30. # legacy xrt. The package built by XRT is controlled through CMake
31. # variables:
32. # - XRT_BASE:
33. #    Builds the base package, which contains everything shared by
34. #    other packages.
35. # - XRT_NPU:
36. #    Builds the npu package with content specific to NPU.
37. # - XRT_ALVEO:
38. #    Builds the alveo package with content specific to Alveo.
39. # - XRT_XRT: (default when no other variables are set)
40. #    Builds the legacy XRT package.
41. #
42. # The packages are created by populating CMake components controlled
43. # through following symbolic variables, which are set to either
44. # base, npu, alveo, or xrt depending on which package is built.
45. # - XRT_BASE_COMPONENT:
46. #    Deployment component for XRT base content.  The base component
47. #    has content that is required by npu, alveo, and xrt packages.
48. # - XRT_BASE_DEV_COMPONENT:
49. #    Development component for XRT base content.
50. # - XRT_COMPONENT:
51. #    Deployment component for XRT npu, alveo, or legacy xrt packages.
52. #    This component is dependent on the base component.
53. # - XRT_DEV_COMPONENT:
54. #    Development compoment for XRT npu, alveo, or legacy xrt packages.
55. #
56. # The XRT_COMPONENT and XRT_DEV_COMPONENT are used to control content
57. # that is installed for multiple exclusive targets (npu or alveo) and
58. # used to indicate packaging for legacy XRT build (XRT_XRT).  These
59. # symbolic component names are explicitly named depending on the
60. # package being built.
61. 
62. # Additional CMake flags:
63. # - XRT_YOCTO:
64. #    Indicates a Yocto build environment where static libraries should be
65. #    excluded from xrt-targets export to avoid find_package(XRT) failures
66. #    when static libs are not present in the sysroot.
67. 
68. # BASE builds a deployment and development package of everything
69. # enabled by XRT_BASE.
70. if (XRT_BASE)
71.   # For the time being, dump everything into base that has not
72.   # been explicitly marked for base
73.   set (CMAKE_INSTALL_DEFAULT_COMPONENT_NAME "base")
74.   set (XRT_BASE_COMPONENT "base")
75.   set (XRT_BASE_DEV_COMPONENT "base${XRT_DEV_COMPONENT_SUFFIX}")
76. 
77.   # Tempoary fix for cpackLin conditionally adding dependencies for
78.   # legacy XRT when XRT_DEV_COMPONENT equals "xrt".  We don't want the
79.   # dependencies in case of base package.
80.   set (XRT_DEV_COMPONENT "dummy")
81. endif(XRT_BASE)  
82. 
83. # NPU builds one NPU package for both deployment and development
84. # for everything enabled by XRT_NPU and XRT_BASE
85. if (XRT_NPU)
86.   set (XRT_BASE 1)
87. 
88.   # For the time being, dump everything into npu that has not
89.   # been explicitly marked alveo or npu
90.   set (CMAKE_INSTALL_DEFAULT_COMPONENT_NAME "npu")
91.   set (XRT_COMPONENT "npu")
92.   set (XRT_DEV_COMPONENT "npu${XRT_DEV_COMPONENT_SUFFIX}")
93.   set (XRT_BASE_COMPONENT "base")
94.   set (XRT_BASE_DEV_COMPONENT "base${XRT_DEV_COMPONENT_SUFFIX}")
95. endif(XRT_NPU)
96. 
97. # Alveo builds one Alveo package for both deployment and development
98. # for everything enabled by XRT_ALVEO and XRT_BASE
99. if (XRT_ALVEO)
100.   set (XRT_BASE 1)
101. 
102.   # For the time being, dump everything into alveo that has not
103.   # been explicitly marked alveo or npu
104.   set (CMAKE_INSTALL_DEFAULT_COMPONENT_NAME "alveo")
105.   set (XRT_COMPONENT "alveo")
106.   set (XRT_DEV_COMPONENT "alveo")
107.   set (XRT_BASE_COMPONENT "base")
108.   set (XRT_BASE_DEV_COMPONENT "base${XRT_DEV_COMPONENT_SUFFIX}")
109. endif(XRT_ALVEO)
110. 
111. # Edge (embedded) builds, build base package and build
112. if (XRT_EDGE)
113.   set (XRT_BASE 1)
114. 
115.   set (CMAKE_INSTALL_DEFAULT_COMPONENT_NAME "xrt")
116.   set (XRT_COMPONENT "xrt")
117.   set (XRT_DEV_COMPONENT "xrt")
118.   set (XRT_BASE_COMPONENT "xrt")
119.   set (XRT_BASE_DEV_COMPONENT "xrt")
120. endif(XRT_EDGE)
121. 
122. # Legacy, build one XRT package for both deployment and development
123. # Include everything enabled by XRT_BASE and XRT_ALVEO
124. if (XRT_XRT)
125.   set (XRT_BASE 1)
126.   set (XRT_ALVEO 1)
127.   set (XRT_NPU 0)
128.   
129.   # The default install component is XRT
130.   # Combine XRT_DEV_COMPONENT with XRT_COMPONENT
131.   set (CMAKE_INSTALL_DEFAULT_COMPONENT_NAME "xrt")
132.   set (XRT_COMPONENT "xrt")
133.   set (XRT_DEV_COMPONENT "xrt")
134.   set (XRT_BASE_COMPONENT ${XRT_COMPONENT})
135.   set (XRT_BASE_DEV_COMPONENT ${XRT_DEV_COMPONENT})
136. endif(XRT_XRT)
137. 
138.

⏱️ 30m 24s

💬 Copilot

I’m updating the container recipe to build the XRT RPMs first, then the xdna plugin RPM, and I’m adding a single host-side script so you can rerun the whole podman flow with one command.


⏱️ 30m 24s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile\n@@\n-RUN cd build && ./build.sh -release -j \"$(nproc)\" && \\\n+RUN cd xrt/build && ./build.sh -npu -opt -j \"$(nproc)\" && \\\n+    cd /work/xdna-driver/build && ./build.sh -release -j \"$(nproc)\" && \\\n     mkdir -p /out && \\\n+    find /work/xdna-driver/xrt/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} + && \\\n     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile

⏱️ 30m 27s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/.dockerignore\n@@\n repo/.git\n+*.rpm\n repo/build/Debug\n repo/build/Release\n repo/build/amdxdna_bins\n+repo/xrt/build/Debug\n+repo/xrt/build/Release\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/.dockerignore

⏱️ 30m 35s

apply_patch

Arguments
"*** Begin Patch\n*** Add File: /home/raymond/Development/amd/xdna-driver-fedora/build-rpms.sh\n+#!/usr/bin/env bash\n+\n+set -euo pipefail\n+\n+IMAGE_NAME=\"${IMAGE_NAME:-xdna-driver-fedora43-build}\"\n+\n+if ! command -v podman >/dev/null 2>&1; then\n+  echo \"podman is required but was not found in PATH\" >&2\n+  exit 1\n+fi\n+\n+SCRIPT_DIR=\"$(cd -- \"$(dirname -- \"${BASH_SOURCE[0]}\")\" && pwd)\"\n+cd \"$SCRIPT_DIR\"\n+\n+podman build -t \"$IMAGE_NAME\" .\n+\n+container_id=\"$(podman create \"$IMAGE_NAME\")\"\n+cleanup() {\n+  podman rm -f \"$container_id\" >/dev/null 2>&1 || true\n+}\n+trap cleanup EXIT\n+\n+podman cp \"$container_id:/out/.\" \"$SCRIPT_DIR\"\n+\n+echo \"Extracted RPMs:\"\n+find \"$SCRIPT_DIR\" -maxdepth 1 -type f -name '*.rpm' -printf '%f\\n' | sort\n*** End Patch\n"
Added 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/build-rpms.sh

⏱️ 30m 41s

sql

Update active todos

Arguments
{
  "description": "Update active todos",
  "query": "UPDATE todos SET status = 'done' WHERE id = 'inspect-xrt-rpms'; UPDATE todos SET status = 'in_progress' WHERE id IN ('create-build-script', 'build-required-rpms');"
}
5 lines
Executed 2 statement(s):

1. UPDATE
   1 row(s) updated.

2. UPDATE
   2 row(s) updated.

⏱️ 30m 42s

bash

Run RPM build script

$ set -euo pipefail && chmod +x build-rpms.sh && ./build-rpms.sh > build-rpms.log 2>&1 || true && tail -n 200 build-rpms.log

26 lines
STEP 1/7: FROM fedora:43
STEP 2/7: ENV LANG=C.UTF-8
--> Using cache ad07e23c23fe5d81f1d72af139f441740d0585a0854e4ecfd7f9ae4cdf758177
--> ad07e23c23fe
STEP 3/7: ENV LC_ALL=C.UTF-8
--> Using cache 30eb64056fc8d1f4c11114d7520a04a78d71e8e2552a802526e82f4d70655493
--> 30eb64056fc8
STEP 4/7: WORKDIR /work/xdna-driver
--> Using cache 1c1e91277e174fc24aac9d82cf73b008a58aa8f0ade743bbe2e4d2b79d397235
--> 1c1e91277e17
STEP 5/7: COPY repo/ /work/xdna-driver/
--> Using cache 59b4a2d22e342cf89be8f96810d5473f7c0faa6d80f718fbc498495383798e09
--> 59b4a2d22e34
STEP 6/7: RUN dnf install -y --setopt=install_weak_deps=False jq wget &&     ./xrt/src/runtime_src/tools/scripts/xrtdeps.sh -docker &&     dnf install -y --setopt=install_weak_deps=False "kernel-devel-$(uname -r)" kernel-headers &&     mkdir -p "/lib/modules/$(uname -r)" &&     ln -sf "/usr/src/kernels/$(uname -r)" "/lib/modules/$(uname -r)/build" &&     ln -sf "/usr/src/kernels/$(uname -r)" "/lib/modules/$(uname -r)/source" &&     dnf clean all
--> Using cache 357de22e62cd29dcc8bff2b580977e1ba24cd890e48829b3bd36a331ff57883e
--> 357de22e62cd
STEP 7/7: RUN cd xrt/build && ./build.sh -npu -opt -j "$(nproc)" &&     cd /work/xdna-driver/build && ./build.sh -release -j "$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/xrt/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} + &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +
****************************************************************
* XILINX_VITIS is undefined or not accessible.                 *
* MicroBlaze firmware will not be built.                       *
* To treat as a warning use -noert option.                     *
****************************************************************
Updating Git XRT submodule, use -noinit option to avoid updating
fatal: not a git repository: /work/xdna-driver/xrt/../.git/modules/xrt
Error: building at STEP "RUN cd xrt/build && ./build.sh -npu -opt -j "$(nproc)" &&     cd /work/xdna-driver/build && ./build.sh -release -j "$(nproc)" &&     mkdir -p /out &&     find /work/xdna-driver/xrt/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} + &&     find /work/xdna-driver/build/Release -maxdepth 1 -type f -name '*.rpm' -exec cp -t /out {} +": while running runtime: exit status 128
<exited with exit code 0>

⏱️ 30m 48s

💬 Copilot

The XRT build itself is the right path. The failure is just its default git submodule update, which doesn’t work after COPY because the container only has the populated files, not the original git metadata. I’m switching that build to -noinit and rerunning.


⏱️ 30m 48s

apply_patch

Arguments
"*** Begin Patch\n*** Update File: /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile\n@@\n-RUN cd xrt/build && ./build.sh -npu -opt -j \"$(nproc)\" && \\\n+RUN cd xrt/build && ./build.sh -npu -opt -noinit -j \"$(nproc)\" && \\\n     cd /work/xdna-driver/build && ./build.sh -release -j \"$(nproc)\" && \\\n*** End Patch\n"
Modified 1 file(s): /home/raymond/Development/amd/xdna-driver-fedora/Dockerfile

⏱️ 32m 52s

bash

Re-run RPM build script

$ set -euo pipefail && ./build-rpms.sh > build-rpms.log 2>&1 || true && tail -n 240 build-rpms.log

<command with shellId: build-rpms-script-2 is still running after 120 seconds. The command is still running but hasn't produced output yet. It may be waiting for input or still processing. Use read_bash to continue waiting, write_bash if you think it needs input, or stop_bash to stop it.>

⏱️ 33m 33s

read_bash

Waiting up to 60 seconds for command output

Arguments
{
  "shellId": "build-rpms-script-2",
  "delay": 60
}
239 lines
[ 68%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/utils.cpp.o
[ 71%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/sysinfo.cpp.o
[ 71%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/xclbin_swemu.cpp.o
[ 71%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/xclbin_parser.cpp.o
[ 71%] Building CXX object xrt/src/runtime_src/core/common/CMakeFiles/core_common_library_objects.dir/smi.cpp.o
>>>  + HAVE_6_16_drm_gem_vmap_vunmap: yes
>>>  - HAVE_cache_sgt_mapping: no
>>>  - HAVE_cache_sgt_mapping: no
>>>  + HAVE_iommu_paging_domain_alloc_flags: yes
[ 71%] Built target aiebu_library_objects
[ 71%] Linking CXX static library libaiebu.a
[ 71%] Built target aiebu_static
>>>  + HAVE_iommu_paging_domain_alloc_flags: yes
>>>  + HAVE_iommu_paging_domain_alloc: yes
>>>  + HAVE_iommu_paging_domain_alloc: yes
>>>  - HAVE_xen_phy_dma_ops: no
[ 74%] Build out of tree amdxdna.ko
fatal: not a git repository (or any of the parent directories): .git
[INFO] BUILD Directory not exist or SRC Directory is newer
[INFO] Re-Generate BUILD_ROOT_DIR: /work/xdna-driver/build/Release/src/driver/amdxdna
fatal: not a git repository (or any of the parent directories): .git
>>>  - HAVE_xen_phy_dma_ops: no
>>>  - HAVE_7_0_kmalloc_ops: no
[ 74%] Built target core_common_api_library_objects
[ 74%] Built target core_pcielinux_objects
>>>  + HAVE_drm_gpu_sched_stat_reset: yes
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[ 74%] Built target legacy_driver
[ 74%] Tar amdxdna driver source code
[ 77%] Substitute amdxdna module version and re-tar
[ 77%] Built target driver_ver_tarball
[ 77%] Built target dtrace_library_objects
[ 77%] Linking CXX static library libcert_dtrace.a
>>>  + HAVE_6_17_drm_gpu_sched_stat_no_hang: yes
[ 77%] Built target cert_dtrace_static
>>>  + HAVE_6_13_drm_sched_start_errno: yes
>>>  - HAVE_6_10_drm_sched_start_full_recovery: no
[ 77%] Built target core_common_library_objects
[ 77%] Linking CXX shared library libxrt_coreutil.so
[ 77%] Built target xrt_coreutil
[ 77%] Building CXX object test/xrt_test/CMakeFiles/xrt_test.elf.dir/xrt_test.cpp.o
[ 80%] Linking CXX shared library libxrt_core.so
[ 80%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/cmd_fence.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/bo_import_export.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/dev_info.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/io_test.cpp.o
[ 82%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/io.cpp.o
[ 85%] Building CXX object test/shim_test/CMakeFiles/shim_test.elf.dir/shim_test.cpp.o
[ 85%] Built target xrt_core
[ 85%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/pcidrv.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/fence.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/hwctx.cpp.o
[ 85%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/buffer.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/device.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/hwq.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/pcidev.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/smi_xdna.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwq.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/pcidev.cpp.o
[ 88%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwq.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/hwctx.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/pcidrv_amdxdna.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/kmq/hwctx.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/platform.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/host/platform_host.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/tcp_server.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/pcidev.cpp.o
[ 91%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/platform_virtio.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/virtio/pcidrv_virtgpu.cpp.o
[ 97%] Building CXX object src/shim/CMakeFiles/xrt_driver_xdna.dir/umq/dbg_hwq.cpp.o
>>>  + HAVE_6_16_bit_u64: yes
>>>  - HAVE_7_0_amd_pmf_get_npu_data: no
[100%] Linking CXX executable xrt_test.elf
[100%] Built target xrt_test.elf
>>>  + HAVE_6_14_drm_fdinfo_print_size: yes
[100%] Build amdxdna.ko
fatal: not a git repository (or any of the parent directories): .git
[INFO] BUILD Directory not exist or SRC Directory is newer
[INFO] Re-Generate BUILD_ROOT_DIR: /work/xdna-driver/build/Release/drivers/accel/amdxdna
fatal: not a git repository (or any of the parent directories): .git
[100%] Linking CXX executable shim_test.elf
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[100%] Built target driver
[100%] Built target shim_test.elf
[100%] Linking CXX shared library libxrt_driver_xdna.so
[100%] Built target xrt_driver_xdna
Install the project...
-- Install configuration: "Release"
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/version.json
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/amdxdna.tar.gz
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/dkms.conf
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/configure_kernel.sh
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./share/amdxdna/dkms_driver.sh
-- Installing: /work/xdna-driver/build/Release/bins/driver/amdxdna.ko
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_core.so.2.23.0
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_core.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/./lib64/libxrt_core.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_core.so
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_coreutil.so.2.23.0
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_coreutil.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/./lib64/libxrt_coreutil.so.2.23.0" to "$ORIGIN/../lib64:$ORIGIN/../..:$ORIGIN/../../lib64"
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_coreutil.so
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_driver_xdna.so.2
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/./lib64/libxrt_driver_xdna.so.2.23.0" to ""
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libxrt_driver_xdna.so
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./include/vaccel.h
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libvxdna.so.1.0.0
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libvxdna.so.1
-- Installing: /work/xdna-driver/build/Release/bins/./lib64/libvxdna.so
-- Installing: /work/xdna-driver/build/Release/opt/xilinx/xrt/./lib64/pkgconfig/vxdna.pc
-- Installing: /work/xdna-driver/build/Release/bins/driver/amdxdna_legacy.ko
-- Installing: /work/xdna-driver/build/Release/bins/bin/shim_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/bin/shim_test.elf" to ""
-- Installing: /work/xdna-driver/build/Release/bins/bin/xrt_test.elf
-- Set non-toolchain portion of runtime path of "/work/xdna-driver/build/Release/bins/bin/xrt_test.elf" to ""
-- Installing: /work/xdna-driver/build/Release/bins/bin/xrt_test

real	0m26.065s
user	9m0.606s
sys	0m37.013s
Download npu1 NPUFW version 1.5.5.391:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/1502_00/npu.sbin.1.5.5.391' ...
Saving './amdxdna_bins/firmware/1502_00/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/1502_00/npu.sbin.1.5.5.391]
Download npu3 NPUFW version 1.1.0.206:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/npu.sbin.1.1.0.206' ...
Saving './amdxdna_bins/firmware/17f1_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/npu.sbin.1.1.0.206]
Download npu3 NPUFW version 1.0.0.28:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/cert.sbin.1.0.0.28' ...
Saving './amdxdna_bins/firmware/17f1_10/cert.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f1_10/cert.sbin.1.0.0.28]
Download npu3 NPUFW version 1.1.0.206:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/npu.sbin.1.1.0.206' ...
Saving './amdxdna_bins/firmware/17f2_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/npu.sbin.1.1.0.206]
Download npu3 NPUFW version 1.0.0.28:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/cert.sbin.1.0.0.28' ...
Saving './amdxdna_bins/firmware/17f2_10/cert.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f2_10/cert.sbin.1.0.0.28]
Download npu4 NPUFW version 1.1.2.64:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_10/1.7_npu.sbin.1.1.2.64' ...
Saving './amdxdna_bins/firmware/17f0_10/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_10/1.7_npu.sbin.1.1.2.64]
Download npu5 NPUFW version 1.1.2.65:
[0] Downloading 'https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_11/1.7_npu.sbin.1.1.2.65' ...
Saving './amdxdna_bins/firmware/17f0_11/npu.dev.sbin'
HTTP response 200  [https://gitlab.com/kernel-firmware/drm-firmware/-/raw/amd-ipu-staging/amdnpu/17f0_11/1.7_npu.sbin.1.1.2.65]
Download strx VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_strx.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/strx/xrt_smi_strx.a]
Download phx VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_phx.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/phx/xrt_smi_phx.a]
Download npu3 VTD archive:
[0] Downloading 'https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a' ...
HTTP response 302  [https://github.com/Xilinx/VTD/raw/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a]
Enqueue https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a
[0] Downloading 'https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a' ...
Saving './amdxdna_bins/vtd_archives/xrt_smi_npu3.a'
HTTP response 200  [https://raw.githubusercontent.com/Xilinx/VTD/0b65e6c61ca5505bac0b0b7d6c500806e53b0ad1/archive/npu3/xrt_smi_npu3.a]
[  0%] Collect all out of tree driver source code
[  0%] Collect all driver source code
[  0%] Built target core_common_xdp_profile_objects
[  2%] Built target vxdna
[  2%] Configuring kernel compatibility header
[  2%] Configuring out of tree kernel compatibility header
[  2%] Built target core_common_objects
[  5%] Built target core_common_runner_objects
>>> /work/xdna-driver/build/Release/src/driver/driver/amdxdna/config_kernel.h is up-to-date (kernel=6.19.11-200.fc43.x86_64)
>>> /work/xdna-driver/build/Release/drivers/accel/drivers/accel/amdxdna/config_kernel.h is up-to-date (kernel=6.19.11-200.fc43.x86_64)
[  8%] Build out of tree amdxdna.ko
[  8%] Build amdxdna.ko
[ 11%] Built target core_pciecommon_objects
[ 17%] Built target core_pcielinux_plugin_xdp_objects
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
fatal: not a git repository (or any of the parent directories): .git
[ 20%] Built target core_pcielinux_objects
[ 31%] Built target core_common_api_library_objects
[ 42%] Built target aiebu_library_objects
[ 45%] Built target aiebu_static
[ 57%] Built target core_common_library_objects
[ 74%] Built target dtrace_library_objects
[ 74%] Built target cert_dtrace_static
[ 74%] Built target xrt_coreutil
[ 77%] Built target xrt_core
[ 80%] Built target xrt_test.elf
[ 85%] Built target shim_test.elf
[ 97%] Built target xrt_driver_xdna
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[ 97%] Built target driver
Skipping BTF generation for amdxdna.ko due to unavailability of vmlinux
fatal: not a git repository (or any of the parent directories): .git
[ 97%] Built target legacy_driver
[100%] Built target driver_ver_tarball
Run CPack packaging tool...
CPack: Create package using RPM
CPack: Install projects
CPack: - Run preinstall target for: amd-xdna
CPack: - Install project: amd-xdna []
CPack: -   Install component: amdxdna
CPack: Create package
CPackRPM:Warning: CPACK_SET_DESTDIR is set (=ON) while requesting a relocatable package (CPACK_RPM_PACKAGE_RELOCATABLE is set): this is not supported, the package won't be relocatable.
CPackRPM: Will use GENERATED spec file: /work/xdna-driver/build/Release/_CPack_Packages/Linux/RPM/SPECS/xrt_plugin-amdxdna.spec
CPack: - package: /work/xdna-driver/build/Release/xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm generated.

real	0m6.806s
user	1m17.362s
sys	0m10.517s
COMMIT xdna-driver-fedora43-build
--> 771fb5fbbc22
Successfully tagged localhost/xdna-driver-fedora43-build:latest
771fb5fbbc22cdfaab4893d0e64c81ae6a0aa4d80026cab59e49c07bbef2df1a
Extracted RPMs:
xrt_202610.2.23.0_43-x86_64-aiebu-devel.rpm
xrt_202610.2.23.0_43-x86_64-aiebu.rpm
xrt_202610.2.23.0_43-x86_64-base-devel.rpm
xrt_202610.2.23.0_43-x86_64-base.rpm
xrt_202610.2.23.0_43-x86_64-npu.rpm
xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm
<command with id: build-rpms-script-2 exited with exit code 0>

⏱️ 33m 34s

ℹ️ Notification

Shell "Re-run RPM build script" completed


⏱️ 33m 44s

💬 Copilot

I’ve got the missing XRT RPMs now. I’m checking the package metadata and doing a clean install test in a Fedora 43 container so I can tell you exactly which local RPMs you need to install together.


⏱️ 33m 44s

bash

Inspect RPM provides and requires

$ set -euo pipefail && rpm -qp --provides xrt_202610.2.23.0_43-x86_64-base.rpm | grep -E 'xrt-base|libxrt_core|libxrt_coreutil' && echo '---' && rpm -qp --requires xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm

47 lines
libxrt_core.so.2()(64bit)
libxrt_coreutil.so.2()(64bit)
xrt-base = 2.23.0-1
xrt-base(x86-64) = 2.23.0-1
---
/bin/sh
/bin/sh
/usr/bin/bash
libc.so.6()(64bit)
libc.so.6(GLIBC_2.14)(64bit)
libc.so.6(GLIBC_2.17)(64bit)
libc.so.6(GLIBC_2.2.5)(64bit)
libc.so.6(GLIBC_2.3)(64bit)
libc.so.6(GLIBC_2.32)(64bit)
libc.so.6(GLIBC_2.33)(64bit)
libc.so.6(GLIBC_2.34)(64bit)
libc.so.6(GLIBC_2.38)(64bit)
libgcc_s.so.1()(64bit)
libgcc_s.so.1(GCC_3.0)(64bit)
libm.so.6()(64bit)
libstdc++.so.6()(64bit)
libstdc++.so.6(CXXABI_1.3)(64bit)
libstdc++.so.6(CXXABI_1.3.15)(64bit)
libstdc++.so.6(CXXABI_1.3.9)(64bit)
libstdc++.so.6(GLIBCXX_3.4)(64bit)
libstdc++.so.6(GLIBCXX_3.4.11)(64bit)
libstdc++.so.6(GLIBCXX_3.4.15)(64bit)
libstdc++.so.6(GLIBCXX_3.4.18)(64bit)
libstdc++.so.6(GLIBCXX_3.4.21)(64bit)
libstdc++.so.6(GLIBCXX_3.4.22)(64bit)
libstdc++.so.6(GLIBCXX_3.4.26)(64bit)
libstdc++.so.6(GLIBCXX_3.4.29)(64bit)
libstdc++.so.6(GLIBCXX_3.4.30)(64bit)
libstdc++.so.6(GLIBCXX_3.4.32)(64bit)
libstdc++.so.6(GLIBCXX_3.4.9)(64bit)
libuuid.so.1()(64bit)
libvxdna.so.1()(64bit)
libxrt_core.so.2()(64bit)
libxrt_coreutil.so.2()(64bit)
rpmlib(CompressedFileNames) <= 3.0.4-1
rpmlib(FileDigests) <= 4.6.0-1
rpmlib(PayloadFilesHavePrefix) <= 4.0-1
rpmlib(PayloadIsZstd) <= 5.4.18-1
rtld(GNU_HASH)
xrt-base >= 2.23
xrt-base < 2.24
<exited with exit code 0>

⏱️ 33m 50s

bash

Test installing local RPMs in Fedora container

$ set -euo pipefail && podman run --rm -v "$PWD:/pkgs:Z" fedora:43 bash -lc 'dnf install -y --setopt=install_weak_deps=False /pkgs/xrt_202610.2.23.0_43-x86_64-base.rpm /pkgs/xrt_202610.2.23.0_43-x86_64-npu.rpm /pkgs/xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm >/tmp/install.log && tail -n 40 /tmp/install.log'

71 lines
Updating and loading repositories:
 Fedora 43 - x86_64 - Updates           100% |   7.5 MiB/s |   9.8 MiB |  00m01s
 Fedora 43 openh264 (From Cisco) - x86_ 100% |   4.8 KiB/s |   5.8 KiB |  00m01s
 Fedora 43 - x86_64                     100% |  18.9 MiB/s |  35.7 MiB |  00m02s
Repositories loaded.
Total size of inbound packages is 18 MiB. Need to download 12 MiB.
After this operation, 129 MiB extra will be used (install 129 MiB, remove 0 B).
[ 1/11] boost-filesystem-0:1.83.0-17.fc 100% |   2.8 MiB/s |  68.1 KiB |  00m00s
[ 2/11] boost-program-options-0:1.83.0- 100% |   4.0 MiB/s | 110.7 KiB |  00m00s
[ 3/11] boost-atomic-0:1.83.0-17.fc43.x 100% | 604.9 KiB/s |  17.5 KiB |  00m00s
[ 4/11] boost-system-0:1.83.0-17.fc43.x 100% |   1.3 MiB/s |  13.3 KiB |  00m00s
[ 5/11] python3-0:3.14.3-2.fc43.x86_64  100% |   1.7 MiB/s |  28.3 KiB |  00m00s
[ 6/11] tcsh-0:6.24.14-4.fc43.x86_64    100% |  15.1 MiB/s | 463.2 KiB |  00m00s
[ 7/11] expat-0:2.7.3-1.fc43.x86_64     100% |  11.7 MiB/s | 119.9 KiB |  00m00s
[ 8/11] mpdecimal-0:4.0.1-2.fc43.x86_64 100% |   3.0 MiB/s |  97.1 KiB |  00m00s
[ 9/11] python-pip-wheel-0:25.1.1-18.fc 100% |  13.0 MiB/s |   1.2 MiB |  00m00s
[10/11] ocl-icd-0:2.3.4-1.fc43.x86_64   100% |   1.0 MiB/s |  73.3 KiB |  00m00s
[11/11] python3-libs-0:3.14.3-2.fc43.x8 100% |  56.6 MiB/s |   9.9 MiB |  00m00s
--------------------------------------------------------------------------------
[11/11] Total                           100% |  56.7 MiB/s |  12.0 MiB |  00m00s
Running transaction
[ 1/16] Verify package files            100% | 368.0   B/s |  14.0   B |  00m00s
[ 2/16] Prepare transaction             100% | 583.0   B/s |  14.0   B |  00m00s
[ 3/16] Installing boost-atomic-0:1.83. 100% |  21.4 MiB/s |  21.9 KiB |  00m00s
[ 4/16] Installing ocl-icd-0:2.3.4-1.fc 100% | 224.4 MiB/s | 229.8 KiB |  00m00s
[ 5/16] Installing python-pip-wheel-0:2 100% |   1.2 GiB/s |   1.2 MiB |  00m00s
[ 6/16] Installing mpdecimal-0:4.0.1-2. 100% | 213.7 MiB/s | 218.8 KiB |  00m00s
[ 7/16] Installing expat-0:2.7.3-1.fc43 100% |  26.9 MiB/s | 303.2 KiB |  00m00s
[ 8/16] Installing python3-libs-0:3.14. 100% | 363.0 MiB/s |  43.6 MiB |  00m00s
[ 9/16] Installing python3-0:3.14.3-2.f 100% |   3.3 MiB/s |  30.6 KiB |  00m00s
[10/16] Installing boost-system-0:1.83. 100% |   0.0   B/s |  13.2 KiB |  00m00s
[11/16] Installing boost-filesystem-0:1 100% | 141.3 MiB/s | 144.6 KiB |  00m00s
[12/16] Installing tcsh-0:6.24.14-4.fc4 100% |  59.5 MiB/s |   1.2 MiB |  00m00s
[13/16] Installing boost-program-option 100% | 275.2 MiB/s | 281.8 KiB |  00m00s
[14/16] Installing xrt-base-0:2.23.0-1. 100% | 650.8 MiB/s |  15.6 MiB |  00m00s
[15/16] Installing xrt-npu-0:2.23.0-1.x 100% | 685.6 MiB/s |   4.8 MiB |  00m00s
[16/16] Installing xrt_plugin-amdxdna-0 100% | 633.1 MiB/s |  61.4 MiB |  00m00s
>>> Running %post scriptlet: xrt_plugin-amdxdna-0:2.23-1.x86_64                 
>>> Finished %post scriptlet: xrt_plugin-amdxdna-0:2.23-1.x86_64                
>>> Scriptlet output:                                                           
>>> Installing new amdxdna Linux kernel module in dkms                          
>>> Installing xrt-amdxdna-2.23.0 from /opt/xilinx/xrt/share/amdxdna...         
>>> /opt/xilinx/xrt/./share/amdxdna/dkms_driver.sh: line 58: dkms: command not f
>>> Failed to enable DKMS for xrt-amdxdna/2.23.0                                
>>> Loading new amdxdna Linux kernel module                                     
>>> touch: cannot touch '/etc/udev/rules.d/99-amdxdna.rules': No such file or di
>>> /var/tmp/rpm-tmp.9xoSIe: line 41: /etc/udev/rules.d/99-amdxdna.rules: No suc
>>> /var/tmp/rpm-tmp.9xoSIe: line 49: modprobe: command not found               
>>>                                                                             
Warning: skipped OpenPGP checks for 3 packages from repository: @commandline
Complete!
Package                Arch   Version        Repository        Size
Installing:
 xrt-base              x86_64 2.23.0-1       @commandline  15.6 MiB
 xrt-npu               x86_64 2.23.0-1       @commandline   4.8 MiB
 xrt_plugin-amdxdna    x86_64 2.23-1         @commandline  61.4 MiB
Installing dependencies:
 boost-atomic          x86_64 1.83.0-17.fc43 fedora        20.9 KiB
 boost-filesystem      x86_64 1.83.0-17.fc43 fedora       143.6 KiB
 boost-program-options x86_64 1.83.0-17.fc43 fedora       280.8 KiB
 boost-system          x86_64 1.83.0-17.fc43 fedora        12.2 KiB
 expat                 x86_64 2.7.3-1.fc43   updates      301.1 KiB
 mpdecimal             x86_64 4.0.1-2.fc43   fedora       217.2 KiB
 ocl-icd               x86_64 2.3.4-1.fc43   fedora       227.9 KiB
 python-pip-wheel      noarch 25.1.1-18.fc43 fedora         1.2 MiB
 python3               x86_64 3.14.3-2.fc43  updates       28.9 KiB
 python3-libs          x86_64 3.14.3-2.fc43  updates       43.2 MiB
 tcsh                  x86_64 6.24.14-4.fc43 fedora         1.2 MiB

Transaction Summary:
 Installing:        14 packages
<exited with exit code 0>

⏱️ 33m 44s

sql

Finish followup todos

Arguments
{
  "description": "Finish followup todos",
  "query": "UPDATE todos SET status = 'done' WHERE id IN ('create-build-script', 'build-required-rpms');"
}
2 row(s) updated.

⏱️ 34m 4s

💬 Copilot

The clean install set is confirmed: xrt-base + xrt-npu + the plugin RPM resolves the dependency error. I’m just checking the final files in this directory, then I’ll hand you the exact command to use.


⏱️ 34m 4s

bash

List final deliverables

$ set -euo pipefail && ls -lh build-rpms.sh Dockerfile .dockerignore *.rpm

10 lines
-rwxr-xr-x. 1 raymond raymond  608 Apr 11 19:39 build-rpms.sh
-rw-r--r--. 1 raymond raymond  931 Apr 11 19:39 Dockerfile
-rw-r--r--. 1 raymond raymond  120 Apr 11 19:39 .dockerignore
-rw-r--r--. 1 raymond raymond 1.5M Apr 11 19:41 xrt_202610.2.23.0_43-x86_64-aiebu-devel.rpm
-rw-r--r--. 1 raymond raymond 2.3M Apr 11 19:41 xrt_202610.2.23.0_43-x86_64-aiebu.rpm
-rw-r--r--. 1 raymond raymond 2.2M Apr 11 19:41 xrt_202610.2.23.0_43-x86_64-base-devel.rpm
-rw-r--r--. 1 raymond raymond 3.9M Apr 11 19:41 xrt_202610.2.23.0_43-x86_64-base.rpm
-rw-r--r--. 1 raymond raymond 1.2M Apr 11 19:41 xrt_202610.2.23.0_43-x86_64-npu.rpm
-rw-r--r--. 1 raymond raymond 1.2M Apr 11 19:41 xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm
<exited with exit code 0>

⏱️ 34m 4s

sql

Confirm todo completion

Arguments
{
  "description": "Confirm todo completion",
  "query": "SELECT id, status FROM todos ORDER BY created_at;"
}
10 lines
7 row(s) returned:

| id | status |
| --- | --- |
| clone-upstream-repo | done |
| create-fedora-dockerfile | done |
| build-and-extract-rpm | done |
| update-build-plan | done |
| inspect-xrt-rpms | done |
| create-build-script | done |
| build-required-rpms | done |

⏱️ 34m 10s

task_complete

Added build-rpms.sh in this directory. Running it n...

Arguments
{
  "summary": "Added **`build-rpms.sh`** in this directory. Running it now rebuilds the full Fedora 43 podman image and extracts the required RPMs here.\n\nThe missing dependency issue is resolved by installing **`xrt-base`** and **`xrt-npu`** alongside the plugin. This local install set works:\n\n```bash\nsudo dnf install \\\n  ./xrt_202610.2.23.0_43-x86_64-base.rpm \\\n  ./xrt_202610.2.23.0_43-x86_64-npu.rpm \\\n  ./xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm\n```\n\nThe directory now contains:\n- **`build-rpms.sh`**\n- **`Dockerfile`**\n- **`xrt_202610.2.23.0_43-x86_64-base.rpm`**\n- **`xrt_202610.2.23.0_43-x86_64-npu.rpm`**\n- **`xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm`**\n\nIf your host does not already have **`dkms`**, install that from Fedora first, since the plugin RPM’s post-install step uses it."
}
15 lines
Added **`build-rpms.sh`** in this directory. Running it now rebuilds the full Fedora 43 podman image and extracts the required RPMs here.

The missing dependency issue is resolved by installing **`xrt-base`** and **`xrt-npu`** alongside the plugin. This local install set works:

```bash
sudo dnf install \
  ./xrt_202610.2.23.0_43-x86_64-base.rpm \
  ./xrt_202610.2.23.0_43-x86_64-npu.rpm \
  ./xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm
```

The directory now contains:
- **`build-rpms.sh`**
- **`Dockerfile`**
- **`xrt_202610.2.23.0_43-x86_64-base.rpm`**
- **`xrt_202610.2.23.0_43-x86_64-npu.rpm`**
- **`xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm`**

If your host does not already have **`dkms`**, install that from Fedora first, since the plugin RPM’s post-install step uses it.

⏱️ 34m 10s

✓ Task Complete

Added build-rpms.sh in this directory. Running it now rebuilds the full Fedora 43 podman image and extracts the required RPMs here.

The missing dependency issue is resolved by installing xrt-base and xrt-npu alongside the plugin. This local install set works:

sudo dnf install \
  ./xrt_202610.2.23.0_43-x86_64-base.rpm \
  ./xrt_202610.2.23.0_43-x86_64-npu.rpm \
  ./xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm

The directory now contains:

  • build-rpms.sh
  • Dockerfile
  • xrt_202610.2.23.0_43-x86_64-base.rpm
  • xrt_202610.2.23.0_43-x86_64-npu.rpm
  • xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm

If your host does not already have dkms, install that from Fedora first, since the plugin RPM’s post-install step uses it.


⏱️ 59m 20s

👤 User

❯ sudo dnf reinstall ./xrt_plugin.2.23.0_43-x86_64-amdxdna.rpm ./xrt_202610.2.23.0_43-x86_64-base.rpm ./xrt_202610.2.23.0_43-x86_64-npu.rpm ./xrt_202610.2.23.0_43-x86_64-base-devel.rpm
Updating and loading repositories:
Repositories loaded.
Package                          Arch    Version                      Repository          Size
Reinstalling:
 xrt-base                        x86_64  2.23.0-1                     @commandline    15.6 MiB
   replacing xrt-base            x86_64  2.23.0-1                     @commandline    28.8 MiB
 xrt-base-devel                  x86_64  2.23.0-1                     @commandline    18.2 MiB
   replacing xrt-base-devel      x86_64  2.23.0-1                     @commandline    37.5 MiB
 xrt-npu                         x86_64  2.23.0-1                     @commandline     4.8 MiB
   replacing xrt-npu             x86_64  2.23.0-1                     @commandline     4.8 MiB
 xrt_plugin-amdxdna              x86_64  2.23-1                       @commandline    61.4 MiB
   replacing xrt_plugin-amdxdna  x86_64  2.23-1                       @commandline    61.4 MiB

Transaction Summary:
 Reinstalling:       4 packages
 Replacing:          4 packages

Total size of inbound packages is 8 MiB. Need to download 0 B.
After this operation, 32 MiB will be freed (install 100 MiB, remove 132 MiB).
Is this ok [y/N]: y
Running transaction
[ 1/10] Verify package files                          100% | 222.0   B/s |   4.0   B |  00m00s
[ 2/10] Prepare transaction                           100% |  60.0   B/s |   8.0   B |  00m00s
[ 3/10] Reinstalling xrt-base-0:2.23.0-1.x86_64       100% | 371.9 MiB/s |  15.6 MiB |  00m00s
[ 4/10] Reinstalling xrt_plugin-amdxdna-0:2.23-1.x86_ 100% |   1.3 MiB/s |  61.4 MiB |  00m46s
\>\>\> Running %post scriptlet: xrt_plugin-amdxdna-0:2.23-1.x86_64
\>\>\> Finished %post scriptlet: xrt_plugin-amdxdna-0:2.23-1.x86_64
\>\>\> Scriptlet output:
\>\>\> Installing new amdxdna Linux kernel module in dkms
\>\>\> Installing xrt-amdxdna-2.23.0 from /opt/xilinx/xrt/share/amdxdna...
\>\>\> Deprecated feature: CLEAN (/usr/src/xrt-amdxdna-2.23.0/dkms.conf)
\>\>\> Creating symlink /var/lib/dkms/xrt-amdxdna/2.23.0/source -\> /usr/src/xrt-amdxdna-2.23.0
\>\>\>
\>\>\> Sign command: /lib/modules/6.19.11-200.fc43.x86_64/build/scripts/sign-file
\>\>\> Signing key: /var/lib/dkms/mok.key
\>\>\> Public certificate (MOK): /var/lib/dkms/mok.pub
\>\>\>
\>\>\> Running the pre_build script..... done.
\>\>\> Building module(s)... done.
\>\>\> Signing module /var/lib/dkms/xrt-amdxdna/2.23.0/build/driver/amdxdna/build/driver/amdxdna/
\>\>\> Found pre-existing /lib/modules/6.19.11-200.fc43.x86_64/kernel/drivers/accel/amdxdna/amdxd
\>\>\> Installing /lib/modules/6.19.11-200.fc43.x86_64/extra/amdxdna.ko.xz
\>\>\> Running depmod.... done.
\>\>\> Executing post-transaction command............ done.
\>\>\> Successfully intalled and enabled DKMS for xrt-amdxdna/2.23.0
\>\>\> Loading new amdxdna Linux kernel module
\>\>\> modprobe: ERROR: could not insert 'amdxdna': Key was rejected by service
\>\>\>
[ 5/10] Reinstalling xrt-npu-0:2.23.0-1.x86_64        100% | 299.9 MiB/s |   4.8 MiB |  00m00s
[ 6/10] Reinstalling xrt-base-devel-0:2.23.0-1.x86_64 100% | 530.6 KiB/s |  18.2 MiB |  00m35s
\>\>\> Running %preun scriptlet: xrt_plugin-amdxdna-0:2.23-1.x86_64
\>\>\> Finished %preun scriptlet: xrt_plugin-amdxdna-0:2.23-1.x86_64
\>\>\> Scriptlet output:
\>\>\> Removing driver source: xrt-amdxdna/2.23.0...
\>\>\> xrt-amdxdna/2.23.0, 6.19.11-200.fc43.x86_64, x86_64: installed (Original modules exist)
\>\>\> Module xrt-amdxdna/2.23.0 for kernel 6.19.11-200.fc43.x86_64 (x86_64):
\>\>\> Before uninstall, this module version was ACTIVE on this kernel.
\>\>\> Deleting /lib/modules/6.19.11-200.fc43.x86_64/extra/amdxdna.ko.xz
\>\>\> Restoring archived original module /lib/modules/6.19.11-200.fc43.x86_64/kernel/drivers/acc
\>\>\> Running depmod.... done.
\>\>\>
\>\>\> Deleting module xrt-amdxdna/2.23.0 completely from the DKMS tree.
\>\>\> Executing post-transaction command............ done.
\>\>\> Successfully removed driver source for xrt-amdxdna/2.23.0
\>\>\>
[ 7/10] Removing xrt_plugin-amdxdna-0:2.23-1.x86_64   100% |  18.6 KiB/s |  38.0   B |  00m00s
[ 8/10] Removing xrt-npu-0:2.23.0-1.x86_64            100% |  16.6 KiB/s |  17.0   B |  00m00s
[ 9/10] Removing xrt-base-devel-0:2.23.0-1.x86_64     100% |  41.5 KiB/s |  85.0   B |  00m00s
[10/10] Removing xrt-base-0:2.23.0-1.x86_64           100% | 105.0   B/s |  42.0   B |  00m00s
Warning: skipped OpenPGP checks for 4 packages from repository: @commandline
Complete!

⏱️ 59m 34s

💬 Copilot

The reinstall worked. The Removing ... lines are just the old package instances being removed as part of the reinstall transaction, not a rollback.

The real problem is this line:

modprobe: ERROR: could not insert 'amdxdna': Key was rejected by service

That means the DKMS-built module was signed, but the signing key is not enrolled for Secure Boot. The relevant key is:

  • /var/lib/dkms/mok.pub

Use:

sudo mokutil --import /var/lib/dkms/mok.pub
reboot

Then complete the MOK enrollment in the firmware screen on reboot, and load the module again:

sudo modprobe amdxdna

If you want to confirm the RPMs are installed, run:

rpm -q xrt-base xrt-base-devel xrt-npu xrt_plugin-amdxdna

If Secure Boot is disabled, this specific error would be unexpected; otherwise, MOK enrollment is the fix.


⏱️ 61m 2s

👤 User

Is this also the correct key, when building in podman?


⏱️ 61m 9s

💬 Copilot

Yes — for the installed RPM path, the correct key is the host’s DKMS MOK key, not anything from podman.

Your log shows the signing happened during the RPM post-install on the host:

Signing key: /var/lib/dkms/mok.key
Public certificate (MOK): /var/lib/dkms/mok.pub

So:

  • Building in podman does not determine the Secure Boot key
  • The RPM installs source into DKMS
  • DKMS rebuilds and signs the module on the host
  • The key you need to enroll is therefore /var/lib/dkms/mok.pub from the host

So the right command is still:

sudo mokutil --import /var/lib/dkms/mok.pub

If you were trying to load a module built inside the container directly, that would be different — then you’d need to sign that module with a key enrolled on the host. But for this RPM/DKMS workflow, the host DKMS MOK is the right one.


⏱️ 67m 9s

ℹ️ Info

Environment loaded: 1 skill


⏱️ 67m 9s

ℹ️ Info

MCP Servers reloaded: 1 server connected


Generated by GitHub Copilot CLI

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment