-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Raise ext/pgsql requirements to PostGreSQL 7.4 #5611
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
We can safely assume that users have at the very least libpq 7.4, for which official support ended on 2010-10-01; even CentOS 6 has 8.4 now. It is also noteworthy that PDO_PGSQL already requires libpq 7.4 or later.
oid = PQoidValue(pgsql_result); | ||
if (oid == InvalidOid) { | ||
RETURN_FALSE; | ||
} | ||
PGSQL_RETURN_OID(oid); | ||
#else | ||
Z_STRVAL_P(return_value) = (char *) PQoidStatus(pgsql_result); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this code ever compiled with PHP 7, so requiring libpq 7.4 seems to be a no-brainer.
Too much copy pasta.
cc @remicollet |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add a note to UPGRADING.
I'd also be happy with a followup that bumps pgsql + pdo_pgsql to 8.4. If even CentOS 6 has it, everyone has it :) |
Make sense
+1 Nobody serious will try to build PHP 8 on a so old distro providing some older version... |
Thanks! Applied as 4bc1d83. I'll gladly follow up with another PR bumping the version further. :) |
@remicollet Do you know since which version libpq ships with pkg-config file? We reverted the switch to pkg-config in PHP 7.4, but I wonder if it's okay to make it in PHP 8.0. |
According to a comment in ext/pgsql/config.m4, pkg-config is supported as of 9.3 (which seems to recent as minimum requirement for PHP 8; CentOS 7 is on 9.2 only). |
We can safely assume that users have at the very least libpq 7.4, for
which official support ended on 2010-10-01; even CentOS 6 has 8.4 now.
It is also noteworthy that PDO_PGSQL already requires libpq 7.4 or
later.
While having a closer look at removing the
PG_VERSION
dependency, I noticed that some of the code for older versions did version comparisions usingPG_VERSION
; these are gone with this patch, paving the way forward.I wouldn't mind to even require libpq 9.1, though.