NVPL Package Config Support#

NVPL has support for GNU pkg-config and provides several variants covering different ABIs.

Pkg-config usage#

NVPL *.pc are distributed in NVPL universal tarball and NVPL individual tarball packages starting with the NVPL-25.11 release.

Assume the NVPL Tarball distribution(s) are expanded to location NVPL_ROOT. To enable pkg-config support:

  1. Set environment variable PKG_CONFIG_PATH to include ${NVPL_ROOT}/lib/pkgconfig.

  2. Use the pkg-config --define-prefix argument to ensure the internal prefix variable is reset to the actual local prefix.

export NVPL_ROOT=/path/to/nvpl
export PKG_CONFIG_PATH=${NVPL_ROOT}/lib/pkgconfig:${PKG_CONFIG_PATH}

For build systems that call pkg-config (like Meson, CMake, etc.), you may need to configure them to use --define-prefix. The recommended approach is to create a wrapper script in your project directory:

cd /path/to/your/project
cat > pkg-config << 'EOF'
#!/bin/bash
exec $(which -a pkg-config | sed -n '2p') --define-prefix "$@"
EOF
chmod +x pkg-config
export PATH=$PWD:$PATH

Verify the configuration:

pkg-config --modversion nvpl-blas-lp64-omp
pkg-config --libs nvpl-blas-lp64-omp
# Should show: -L/path/to/nvpl/lib -lnvpl_blas_lp64_omp ...

Pkg-config targets#

pkg-config target name

Languages

Options

NVPL BLAS

nvpl-blas-lp64-seq

C/C++

ABI: lp64 + sequential

nvpl-blas-ilp64-seq

C/C++

ABI: ilp64 + sequential

nvpl-blas-lp64-omp

C/C++

ABI: lp64 + OpenMP threads

nvpl-blas-ilp64-omp

C/C++

ABI: ilp64 + OpenMP threads

NVPL FFT

nvpl-fftw

C/C++

FFTW3 API/ABI compatible interface

NVPL LAPACK

nvpl-lapack-lp64-seq

C/C++

ABI: lp64 + sequential

nvpl-lapack-ilp64-seq

C/C++

ABI: ilp64 + sequential

nvpl-lapack-lp64-omp

C/C++

ABI: lp64 + OpenMP threads

nvpl-lapack-ilp64-omp

C/C++

ABI: ilp64 + OpenMP threads

NVPL Rand

nvpl-rand

C/C++

Single-threaded API

nvpl-rand-mt

C/C++

OpenMP-threaded API

NVPL Sparse

nvpl-sparse

C/C++

NVPL Tensor

nvpl-tensor

C/C++