Skip to content

Commit

Permalink
Added new merging script and updated build scripts accordingly
Browse files Browse the repository at this point in the history
Recent commits in the PG17 code added additional API changes,
making the "single src directory with ifdefs" approach inpractical.

This commit adds a new python based script (documented with comments
in the file) to help with version specific merges, where the copied
heap files reside in srcXX directories, where XX is the version.
  • Loading branch information
dutow committed Aug 14, 2024
1 parent f9ed3ce commit 6cbd7c8
Show file tree
Hide file tree
Showing 6 changed files with 247 additions and 429 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
*.so
*.o
__pycache__

/config.cache
/config.log
/config.status
/Makefile
/autom4te.cache
/configure~
/configure~
18 changes: 9 additions & 9 deletions Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -24,16 +24,16 @@ TAP_TESTS = 1
OBJS = src/encryption/enc_tde.o \
src/encryption/enc_aes.o \
src/access/pg_tde_slot.o \
src/access/pg_tde_io.o \
src/access/pg_tdeam_visibility.o \
src/access/pg_tde_tdemap.o \
src/access/pg_tdeam.o \
src/access/pg_tdetoast.o \
src/access/pg_tde_prune.o \
src/access/pg_tde_vacuumlazy.o \
src/access/pg_tde_visibilitymap.o \
src/access/pg_tde_rewrite.o \
src/access/pg_tdeam_handler.o \
src$(MAJORVERSION)/access/pg_tde_io.o \
src$(MAJORVERSION)/access/pg_tdeam_visibility.o \
src$(MAJORVERSION)/access/pg_tdeam.o \
src$(MAJORVERSION)/access/pg_tdetoast.o \
src$(MAJORVERSION)/access/pg_tde_prune.o \
src$(MAJORVERSION)/access/pg_tde_vacuumlazy.o \
src$(MAJORVERSION)/access/pg_tde_visibilitymap.o \
src$(MAJORVERSION)/access/pg_tde_rewrite.o \
src$(MAJORVERSION)/access/pg_tdeam_handler.o \
src/access/pg_tde_ddl.o \
src/access/pg_tde_xlog.o \
src/transam/pg_tde_xact_handler.o \
Expand Down
23 changes: 13 additions & 10 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -13,20 +13,23 @@ conf_data.set_quoted('PACKAGE_TARNAME', 'pg_tde')
configure_file(output : 'config.h',
configuration : conf_data)

pg_version = meson.project_version().substring(0,2)
src_version = 'src' + pg_version

pg_tde_sources = files(
'src/pg_tde.c',
'src/transam/pg_tde_xact_handler.c',
'src/access/pg_tde_tdemap.c',
'src/access/pg_tde_slot.c',
'src/access/pg_tdeam.c',
'src/access/pg_tdeam_handler.c',
'src/access/pg_tdeam_visibility.c',
'src/access/pg_tdetoast.c',
'src/access/pg_tde_io.c',
'src/access/pg_tde_prune.c',
'src/access/pg_tde_rewrite.c',
'src/access/pg_tde_vacuumlazy.c',
'src/access/pg_tde_visibilitymap.c',
src_version / 'access/pg_tdeam.c',
src_version / 'access/pg_tdeam_handler.c',
src_version / 'access/pg_tdeam_visibility.c',
src_version / 'access/pg_tdetoast.c',
src_version / 'access/pg_tde_io.c',
src_version / 'access/pg_tde_prune.c',
src_version / 'access/pg_tde_rewrite.c',
src_version / 'access/pg_tde_vacuumlazy.c',
src_version / 'access/pg_tde_visibilitymap.c',
'src/access/pg_tde_ddl.c',
'src/access/pg_tde_xlog.c',

Expand All @@ -51,7 +54,7 @@ pg_tde_sources = files(
'src/pg_tde_event_capture.c',
)

incdir = include_directories('src/include', '.')
incdir = include_directories(src_version / 'include', 'src/include', '.')

deps_update = {'dependencies': contrib_mod_args.get('dependencies') + [curldep]}

Expand Down
Loading

0 comments on commit 6cbd7c8

Please sign in to comment.