Skip to content

CI: auto-discover pkg-config and library paths for local installs#1571

Open
DawidWesierski4 wants to merge 1 commit into
OpenVisualCloud:mainfrom
DawidWesierski4:ci/local-install-path-discovery
Open

CI: auto-discover pkg-config and library paths for local installs#1571
DawidWesierski4 wants to merge 1 commit into
OpenVisualCloud:mainfrom
DawidWesierski4:ci/local-install-path-discovery

Conversation

@DawidWesierski4

Copy link
Copy Markdown
Collaborator

Problem

When building with MTL_INSTALL_PREFIX (local-install mode), downstream builds like GStreamer cannot find mtl.pc or DPDK headers because PKG_CONFIG_PATH and LD_LIBRARY_PATH are either hardcoded to a specific libdir layout or not propagated between build steps.

Solution

Add _export_local_paths() helper to setup_environment.sh that dynamically discovers .pc files and shared libraries under a given prefix and exports the correct paths.

Key changes:

  • Bootstrap block at script start — picks up paths from pre-existing/cached installs so downstream builds work even when upstream components were cache-hits (not rebuilt)
  • Per-build exports after DPDK, MTL, FFmpeg — ensures each subsequent build inherits correct paths
  • Pre-GStreamer exports — explicitly ensures mtl.pc and DPDK pkgconfig are discoverable before the GStreamer meson build
  • DPDK local-install — routes DPDK build to ${local_base}/dpdk when MTL_INSTALL_PREFIX is set

This eliminates the need to hardcode lib/x86_64-linux-gnu vs lib64 paths and makes the build robust across different system layouts.

Add _export_local_paths() helper that dynamically discovers .pc files
and shared libraries under a local install prefix, then exports
PKG_CONFIG_PATH and LD_LIBRARY_PATH so downstream builds (FFmpeg,
GStreamer) can find DPDK/MTL headers and libs without hardcoding
directory layouts.

- Bootstrap block at script start picks up paths from cached installs
- Per-build exports after DPDK, MTL, FFmpeg ensure cascading visibility
- Pre-GStreamer exports guarantee mtl.pc is discoverable via pkg-config
- DPDK build uses MTL_INSTALL_PREFIX for local-install support
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant