build: add driver_libdir option, install shim under libdir/odbc - #3
Merged
Conversation
The ODBC shim is a dlopen()ed plugin, not a linkable library, so it
belongs under <libdir>/odbc (e.g. /usr/lib64/odbc) - the Fedora
convention and the directory the F45 odbcinst-generate probes to turn a
bare "Driver = libseerodbc.so" into an absolute path - rather than in
the general loader search path.
Add a driver_libdir meson option (empty default resolves to
<libdir>/odbc, overridable via -Ddriver_libdir= for non-Fedora layouts)
and set it as the shim's install_dir.
Align the Fedora spec accordingly: package the driver from
%{_libdir}/odbc, add Requires: odbcinst-generate so the drop-in trigger
regenerates /etc/odbcinst.ini, and modernize the packaging boilerplate
(%autorelease/%autochangelog, VCS tag, archive Source URL, autosetup).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Install the ODBC driver shim under
<libdir>/odbc(e.g./usr/lib64/odbc) instead of the bare<libdir>, and add a meson option to override the location.Why
The shim is a
dlopen()ed plugin, not a linkable library, so it does not belong in the general loader search path.<libdir>/odbcis the long-standing Fedora convention for ODBC driver.sos, and — relevant to the incoming F45 ODBC Stack Modernization Change — it is exactly the directoryodbcinst-generateprobes to resolve a bareDriver = libseerodbc.sointo an absolute path in the generated/etc/odbcinst.ini. Targeting Fedora 45+.Changes
meson_options.txt— newdriver_libdirstring option. Empty default resolves to<libdir>/odbc; override with-Ddriver_libdir=<path>for non-Fedora layouts.src/odbc/meson.build— resolve the option and pass it as the shim'sinstall_dir.packaging/seerodbc.spec— package the driver from%{_libdir}/odbc, addRequires: odbcinst-generate(drop-in trigger regenerates/etc/odbcinst.ini), and modernize boilerplate (%autorelease/%autochangelog,VCStag, archiveSourceURL,%autosetup -p1).Verified
--libdir=lib64)/usr/lib64/odbc/libseerodbc.so-Ddriver_libdir=/opt/seer/lib/opt/seer/lib/libseerodbc.so🤖 Generated with Claude Code