On Feb 19, 2010, at 7:43 AM, David E. Wheeler wrote:
> Usually PGXS loads after setting all the environment variables, though I suspect that it wouldn't have any side
effectsto set regress_opts afterward. Also, there is no MAJORVERSION in earlier versions, so module authors would have
towork around that.
>
> Basically though, you're asking all third party module authors who depend on plpgsql in their code and/or tests to
modifytheir makefiles and release new versions to work around something that pg_regress could have fixed internally in
1-2lines of code and be done with it.
I'm sure this is bad C and should do a case-insensitive comparison, but this is essentially what I mean:
*** a/src/test/regress/pg_regress.c
--- b/src/test/regress/pg_regress.c
*************** create_database(const char *dbname)
*** 1795,1802 **** */ for (sl = loadlanguage; sl != NULL; sl = sl->next) {
! header(_("installing %s"), sl->str);
! psql_command(dbname, "CREATE LANGUAGE \"%s\"", sl->str); } }
--- 1795,1804 ---- */ for (sl = loadlanguage; sl != NULL; sl = sl->next) {
! if (sl->str != "plpgsql") {
! header(_("installing %s"), sl->str);
! psql_command(dbname, "CREATE LANGUAGE \"%s\"", sl->str);
! } } }
Does that seem unreasonable?
Best,
David