[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH]: gnu: Add guile-dbi.
From: |
Ludovic Courtès |
Subject: |
Re: [PATCH]: gnu: Add guile-dbi. |
Date: |
Tue, 21 Jun 2016 22:56:21 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) |
address@hidden (宋文武) skribis:
> address@hidden (Ludovic Courtès) writes:
>
>> Hi!
>>
>> Maurizio Boriani <address@hidden> skribis:
>>
>>> I'm the maintainer and first author of guile-dbi
>>
>> Good to see you here! :-)
>>
> Oh, nice!
>
>>> >> Unfortunately, Guile DBI loads its backends using `dlopen', so I
>>> >> have to set 'LD_LIBRARY_PATH' to '$guile-dbd-sqlite/lib' for
>>> >> loading it.
>>>
>>> Ludovic> I don’t have any great ideas.
>>>
>>> Ludovic> If it uses lt_dlopen, then we should recommend setting
>>> Ludovic> LTDL_LIBRARY_PATH instead of LD_LIBRARY_PATH, which is a
>>> Ludovic> lesser evil.
>>>
>>> Ludovic> Otherwise, we could also hard-code the file name of, say,
>>> Ludovic> guile-dbd-sqlite in guile-dbi, such that there’s always at
>>> Ludovic> least one backend available.
>>>
>>> may be ok for you if I introduce and 'hardcoded' default search path
>>> for library lookup in guile-dbi source code and do a new release?
>>
>> I don’t think there’s any good default search path that we could hard
>> code, though, except arbitrarily choosing one of the backends as I
>> suggested above.
>>
>> Ideas?
> I think it will be great to introduce a new search path (eg: GUILE_DBD_PATH)
> in addition to LD_LIBRARY_PATH. Find the absolute so filepath in it
> ourself, then pass to dlopen.
Why not, but then it would be redundant with LD_LIBRARY_PATH and
LTDL_LIBRARY_PATH, which would further complicate the search rules.
> Another idea is changing dbd libraries to scheme modules. Then dbi will
> use the '(dbi dbd mysql)' module, the module may use 'load-extension'.
> So we can patch the scheme file of each dbd module.
I like this approach!
Ludo’.