[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: odbc_config missing



On Thu 21 Jul 2022 at 10:15:43 (-0400), Greg Wooledge wrote:
> On Thu, Jul 21, 2022 at 09:06:53AM -0500, David Wright wrote:
> > I thought that was what the attached was (actually for Ubuntu AIUI).
> > As I originally wrote, "As if by magic, […] someone else supplies a copy."
> > 
> 
> > #! /bin/sh
> > 
> > # This shell script saves various pieces of information about the
> > # installed version of unixODBC. Packages that interface to
> > # unixODBC can use it to configure their build.
> > # This file replaces the standard odbc_config, which is not
> > # relocatable
> > #
> > # Author: Alberto Di Meglio <alberto.di.meglio@cern.ch>
> > # Public domain
> > 
> > me=`basename $0`
> > mydir=`dirname $0`
> > mydir=${mydir%/bin}
> > 
> > # stored configuration values
> > val_prefix="$mydir"
> > val_bindir="$mydir/bin"
> > val_includedir="$mydir/include"
> > val_libdir="$mydir/lib"
> > val_libs="-L$mydir/lib -lodbc"
> > val_version='2.2.11'
> 
> This is not going to give the correct linker arguments.  It's going to
> spit out a -L option which is totally unneeded, and worse, the *content*
> of that -L option is going to depend on where the operating system thinks
> the script has been "installed".
> 
> If the script is "installed" in /usr/local/bin/odbc_config, it's going
> to spit out -L/usr/local/lib -lodbc.

Yes, there's a hint in the file: "This file replaces the standard
odbc_config, which is not relocatable". It may be that this script
is sensitive to where it is placed, even though that was not the
intention. That alone might cause it, or something else, to fail.

It's also quite possible that the OP copied it into …/pkg-config,
ran that, and reported "it fails." Who knows?, hence my complaint:
"whether you have taken any actions as a result of reading the
URLs that have been mentioned".

> As the script itself says, 
> 
> > # This file replaces the standard odbc_config
> 
> So, why not use the "standard odbc_config", whatever that is?

We're told that it's not part of the Debian distribution.

> Again, this really needs to be taken up with the upstream maintainers of
> the library, and with the Debian maintainer(s) of the Debian packages of
> the library.

I think it kind of was, in the Debian BTS that I referenced and
advised the OP to read carefully. I can say no more because,
unlike you, my experience of compiling C runs to not much more
than including a couple of libraries and producing an a.out.
(Two decades ago, I compiled kernels, but kernel-package made
that trivial apart from deciding which items to include.)

Cheers,
David.


Reply to: