fltk.core.pkg_config
FLTK pkg-config and fltk-config Probing Module
This module provides functionality to query pkg-config and fltk-config for FLTK library configuration, including compiler flags, linker flags, include paths, and library paths.
The module supports probing for:
- fltk (core library)
- fltk-images (image loading library)
- fltk-gl (OpenGL support library)
License
BSD-3-ClauseCopyright
Copyright © 2025 DDN (D Developer Network) Members
Types 4
enumComponent
Enumeration of FLTK library components.
CORECore FLTK library
IMAGESFLTK images library for image format support
GLFLTK OpenGL library
structComponentConfig
Holds configuration information for an FLTK component.
Contains compiler flags, linker flags, include paths, library paths, and library names extracted from pkg-config or fltk-config.
Fields
Component componentThe component this configuration is forbool availableWhether this component is available on the systemstring versionStrVersion string of the component (if available)string[] cflagsCompiler flags (CFLAGS)string[] ldflagsLinker flags (LDFLAGS)string[] includePathsInclude directories extracted from cflags (-I paths)string[] libPathsLibrary directories extracted from ldflags (-L paths)string[] libsLibrary names extracted from ldflags (-l names)Methods
structConfig
Holds configuration for all FLTK components.
Fields
ComponentConfig coreCore FLTK library configurationComponentConfig imagesFLTK images library configurationComponentConfig glFLTK OpenGL library configurationMethods
enumConfigSource
Enumeration of configuration source types.
PKG_CONFIGConfiguration obtained from pkg-config
FLTK_CONFIGConfiguration obtained from fltk-config
NONENo configuration source available
Functions 11
fn
string pkgConfigName(Component component)Returns the pkg-config package name for an FLTK component.private fn
auto executeCommand(string[] args)Executes a command and returns its output if successful.fn
void parseFlags(
string flags,
out string[] includePaths,
out string[] libPaths,
out string[] libs
)Parses flags string into include paths, library paths, and library names.fn
ComponentConfig queryPkgConfig(Component component)Queries pkg-config for a specific FLTK component.fn
ComponentConfig queryFltkConfig(Component component)Queries fltk-config for library configuration.fn
ComponentConfig probeComponent(Component component)Probes for FLTK component configuration using all available methods.private fn
string[] uniquePaths(string[] paths)Removes duplicate entries from a path array while preserving order.