1
0
mirror of https://github.com/postgres/postgres.git synced 2025-08-30 06:01:21 +03:00

Refactor dlopen() support

Nowadays, all platforms except Windows and older HP-UX have standard
dlopen() support.  So having a separate implementation per platform
under src/backend/port/dynloader/ is a bit excessive.  Instead, treat
dlopen() like other library functions that happen to be missing
sometimes and put a replacement implementation under src/port/.

Discussion: https://www.postgresql.org/message-id/flat/e11a49cb-570a-60b7-707d-7084c8de0e61%402ndquadrant.com#54e735ae37476a121abb4e33c2549b03
This commit is contained in:
Peter Eisentraut
2018-09-06 10:07:24 +02:00
parent ac27c74def
commit 842cb9fa62
37 changed files with 172 additions and 540 deletions

View File

@@ -98,7 +98,7 @@ sub mkvcbuild
erand48.c snprintf.c strlcat.c strlcpy.c dirmod.c noblock.c path.c
pg_strong_random.c pgcheckdir.c pgmkdirp.c pgsleep.c pgstrcasecmp.c
pqsignal.c mkdtemp.c qsort.c qsort_arg.c quotes.c system.c
sprompt.c tar.c thread.c getopt.c getopt_long.c dirent.c
sprompt.c tar.c thread.c getopt.c getopt_long.c dirent.c dlopen.c
win32env.c win32error.c win32security.c win32setlocale.c);
push(@pgportfiles, 'rint.c') if ($vsVersion < '12.00');
@@ -155,9 +155,6 @@ sub mkvcbuild
$postgres->AddIncludeDir('src/backend');
$postgres->AddDir('src/backend/port/win32');
$postgres->AddFile('src/backend/utils/fmgrtab.c');
$postgres->ReplaceFile(
'src/backend/port/dynloader.c',
'src/backend/port/dynloader/win32.c');
$postgres->ReplaceFile('src/backend/port/pg_sema.c',
'src/backend/port/win32_sema.c');
$postgres->ReplaceFile('src/backend/port/pg_shmem.c',