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:
Set environment variable
PKG_CONFIG_PATHto include${NVPL_ROOT}/lib/pkgconfig.Use the
pkg-config --define-prefixargument to ensure the internalprefixvariable 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 |
||
|
C/C++ |
ABI: |
|
C/C++ |
ABI: |
|
C/C++ |
ABI: |
|
C/C++ |
ABI: |
NVPL FFT |
||
|
C/C++ |
FFTW3 API/ABI compatible interface |
NVPL LAPACK |
||
|
C/C++ |
ABI: |
|
C/C++ |
ABI: |
|
C/C++ |
ABI: |
|
C/C++ |
ABI: |
NVPL Rand |
||
|
C/C++ |
Single-threaded API |
|
C/C++ |
OpenMP-threaded API |
NVPL Sparse |
||
|
C/C++ |
|
NVPL Tensor |
||
|
C/C++ |