diff --git a/Makefile b/Makefile index 809f067a..e1a0c5c1 100644 --- a/Makefile +++ b/Makefile @@ -125,6 +125,7 @@ $(PGDIR): cd $(PGDIR); patch -p1 < $(root_dir)/patches/07_plpgsql_start_finish_datums.patch cd $(PGDIR); patch -p1 < $(root_dir)/patches/08_avoid_zero_length_delimiter_in_regression_tests.patch cd $(PGDIR); patch -p1 < $(root_dir)/patches/09_allow_param_junk.patch + cd $(PGDIR); patch -p1 < $(root_dir)/patches/10_ifndef_namedatalen.patch cd $(PGDIR); ./configure $(PG_CONFIGURE_FLAGS) cd $(PGDIR); rm src/pl/plpgsql/src/pl_gram.h cd $(PGDIR); make -C src/pl/plpgsql/src pl_gram.h diff --git a/patches/10_ifndef_namedatalen.patch b/patches/10_ifndef_namedatalen.patch new file mode 100644 index 00000000..7aade806 --- /dev/null +++ b/patches/10_ifndef_namedatalen.patch @@ -0,0 +1,14 @@ +diff --git a/src/include/pg_config_manual.h b/src/include/pg_config_manual.h +index a1a93ad..c978d76 100644 +--- a/src/include/pg_config_manual.h ++++ b/src/include/pg_config_manual.h +@@ -26,7 +26,9 @@ + * + * Changing this requires an initdb. + */ ++#ifndef NAMEDATALEN + #define NAMEDATALEN 64 ++#endif + + /* + * Maximum number of arguments to a function. diff --git a/src/postgres/include/pg_config_manual.h b/src/postgres/include/pg_config_manual.h index a1a93ad7..c978d76d 100644 --- a/src/postgres/include/pg_config_manual.h +++ b/src/postgres/include/pg_config_manual.h @@ -26,7 +26,9 @@ * * Changing this requires an initdb. */ +#ifndef NAMEDATALEN #define NAMEDATALEN 64 +#endif /* * Maximum number of arguments to a function.