Re: DSO Terms Galore

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: DSO Terms Galore
Дата
Msg-id d07b9caf-fd08-439b-a57e-b161c556e34a@eisentraut.org
обсуждение исходный текст
Ответ на DSO Terms Galore  ("David E. Wheeler" <david@justatheory.com>)
Ответы Re: DSO Terms Galore
Список pgsql-hackers
On 19.07.24 21:27, David E. Wheeler wrote:
> I’m trying to understand the standard terms for extension libraries. There seem too a bewildering number of terms
usedto refer to a shared object library, for example:
 
> 
> * LOAD[1]:
>    * “shared library”
>    * “shared library file”
> * dynamic_library_path[2]:
>    * “dynamically loadable module”
> * xfunc-c[3]:
>    * “dynamically loadable object”
>    * “shared library”
>    * “loadable object”
>    * “loadable object file”
>    * “object file”
>    * “dynamically loaded object file”
> * pg_config[5]:
>    * “object code libraries” (static?)
>    * “dynamically loadable modules”
> * PGXS[4]:
>    * “MODULES”
>    * “shared-library objects”
>    * “shared library”

I think in the POSIX-ish realm, the best term is "dynamically loadable 
library".  It's a library, because it contains functions you can, uh, 
borrow, just like a static library.  And it's dynamically loadable, as 
opposed to being loaded in a fixed manner at startup time.

Also, the "dl" in dlopen() etc. presumably stands for dynamic-something 
load-something.

Libtool uses the term "dlopened module" for this, and the command-line 
option is -module. 
(https://www.gnu.org/software/libtool/manual/libtool.html#Dlopened-modules)

Meson uses shared_module() for this.  (It has shared_library() and 
static_library() for things like libpq.)

Things like "object" or "object file" or probably wrong-ish.  I 
understand an object file to be a .o file, which you can't dlopen directly.

Shared library is semi-ok because on many platforms, link-time shared 
libraries (like libpq) and dynamically loadable libraries (like plpgsql) 
are the same file format.  But on some they're not, so it leads to 
confusion.

I think we can unify this around terms like "dynamically loadable 
library" and "dynamically loadable module" (or "loaded" in cases where 
it's talking about a file that has already been loaded).



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Amit Kapila
Дата:
Сообщение: Re: Slow catchup of 2PC (twophase) transactions on replica in LR
Следующее
От: jian he
Дата:
Сообщение: Re: pgsql: Add more SQL/JSON constructor functions