Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: allow installed driver configs to live in /usr #163

Open
amluto opened this issue Mar 15, 2024 · 0 comments
Open

Feature request: allow installed driver configs to live in /usr #163

amluto opened this issue Mar 15, 2024 · 0 comments

Comments

@amluto
Copy link

amluto commented Mar 15, 2024

In recent years, Linux distributions have moved in the direction of separating files: /usr contains files that actually belong to the distribution (although /usr/local/ is still there, etc), and /etc contains non-default configuration. The end goal would be for distributions to be able to leave /etc mostly blank or perhaps to have all-commented-out files in it.

There are certainly tricky exceptions: /etc/nsswitch.conf, /etc/hosts, /etc/resolve.conf, /etc/os-release, and quite a few others. These mostly get handled by symlinks, and the ones that don't are considered annoying and people are slowly working on them.

/etc/odbcinst.ini is a somewhat annoying special case. Drivers get installed, but they don't work until entries get added to /etc/odbcinst.ini, but making /etc/odbcinst.ini be a symlink to somewhere in /usr would make little sense.

So here's my feature request: make driver config locations more flexible. As a baseline improvement, right now driver configs come from the "system" path and the "user" path (in _SQLGetInstalledDrivers). Add a third path, e.g. /usr/lib/unixODBC/odbcinst.ini.

As an IMO better improvement, add an entire directory and get all the ini files in it, for example /usr/lib/unixODBC/odbcinst.d/*.ini. This would allow individual packages to install ODBC drivers without all touching the same file and thus requiring an installation and uninstallation script: the packages could just contain files, and the presence of the files would be sufficient for the driver to work.

(I don't actually represent any distribution, but I am doing some container work, and I currently have a special case for /etc/odbcinst.ini.)

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

No branches or pull requests

1 participant