diff options
-rw-r--r-- | PHPINFO | 4 | ||||
-rw-r--r-- | REFLECTION | 589 | ||||
-rw-r--r-- | php-pecl-pq.spec | 155 | ||||
-rw-r--r-- | pq-php81.patch | 265 |
4 files changed, 485 insertions, 528 deletions
@@ -2,7 +2,7 @@ pq PQ Support => enabled -Extension Version => 2.1.8 +Extension Version => 2.2.3 Used Library => Compiled => Linked -libpq => 12.3 => 12.0.3 +libpq => 15.3 => 15.3 @@ -1,4 +1,4 @@ -Extension [ <persistent> extension #117 pq version 2.1.8 ] { +Extension [ <persistent> extension #89 pq version 2.2.3 ] { - Dependencies { Dependency [ raphf (Required) ] @@ -46,12 +46,13 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } } - Class [ <internal:pq> class pq\DateTime extends DateTime implements DateTimeInterface, JsonSerializable ] { + Class [ <internal:pq> class pq\DateTime extends DateTime implements Stringable, DateTimeInterface, JsonSerializable ] { - - Constants [13] { + - Constants [14] { Constant [ public string ATOM ] { Y-m-d\TH:i:sP } Constant [ public string COOKIE ] { l, d-M-Y H:i:s T } Constant [ public string ISO8601 ] { Y-m-d\TH:i:sO } + Constant [ public string ISO8601_EXPANDED ] { X-m-d\TH:i:sP } Constant [ public string RFC822 ] { D, d M y H:i:s O } Constant [ public string RFC850 ] { l, d-M-y H:i:s T } Constant [ public string RFC1036 ] { D, d M y H:i:s O } @@ -67,14 +68,15 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Static properties [0] { } - - Static methods [4] { + - Static methods [5] { Method [ <internal:pq, overwrites DateTime, prototype DateTime> static public method createFromFormat ] { - Parameters [3] { Parameter #0 [ <required> $format ] Parameter #1 [ <required> $datetime ] - Parameter #2 [ <optional> DateTimeZone or NULL $object ] + Parameter #2 [ <optional> ?DateTimeZone $object = <default> ] } + - Tentative return [ DateTime|false ] } Method [ <internal:date, inherits DateTime> static public method __set_state ] { @@ -82,149 +84,194 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [1] { Parameter #0 [ <required> array $array ] } + - Tentative return [ DateTime ] } Method [ <internal:date, inherits DateTime> static public method createFromImmutable ] { - Parameters [1] { - Parameter #0 [ <required> $DateTimeImmutable ] + Parameter #0 [ <required> DateTimeImmutable $object ] } + - Tentative return [ static ] + } + + Method [ <internal:date, inherits DateTime> static public method createFromInterface ] { + + - Parameters [1] { + Parameter #0 [ <required> DateTimeInterface $object ] + } + - Return [ DateTime ] } Method [ <internal:date, inherits DateTime> static public method getLastErrors ] { - Parameters [0] { } + - Tentative return [ array|false ] } } - Properties [1] { - Property [ <default> public $format ] + Property [ public $format = 'Y-m-d H:i:s.uO' ] } - - Methods [17] { - Method [ <internal:pq> public method __toString ] { + - Methods [19] { + Method [ <internal:pq, prototype Stringable> public method __toString ] { - Parameters [0] { } + - Return [ string ] } Method [ <internal:pq, prototype JsonSerializable> public method jsonSerialize ] { - Parameters [0] { } + - Tentative return [ mixed ] } Method [ <internal:date, inherits DateTime, ctor> public method __construct ] { - Parameters [2] { - Parameter #0 [ <optional> $time ] - Parameter #1 [ <optional> $timezone ] + Parameter #0 [ <optional> string $datetime = "now" ] + Parameter #1 [ <optional> ?DateTimeZone $timezone = null ] + } + } + + Method [ <internal:date, inherits DateTime, prototype DateTimeInterface> public method __serialize ] { + + - Parameters [0] { } + - Return [ array ] + } + + Method [ <internal:date, inherits DateTime, prototype DateTimeInterface> public method __unserialize ] { + + - Parameters [1] { + Parameter #0 [ <required> array $data ] + } + - Return [ void ] } Method [ <internal:date, inherits DateTime, prototype DateTimeInterface> public method __wakeup ] { + + - Parameters [0] { + } + - Tentative return [ void ] } Method [ <internal:date, inherits DateTime, prototype DateTimeInterface> public method format ] { - Parameters [1] { - Parameter #0 [ <required> $format ] + Parameter #0 [ <required> string $format ] } + - Tentative return [ string ] } Method [ <internal:date, inherits DateTime> public method modify ] { - Parameters [1] { - Parameter #0 [ <required> $modify ] + Parameter #0 [ <required> string $modifier ] } + - Tentative return [ DateTime|false ] } Method [ <internal:date, inherits DateTime> public method add ] { - Parameters [1] { - Parameter #0 [ <required> $interval ] + Parameter #0 [ <required> DateInterval $interval ] } + - Tentative return [ DateTime ] } Method [ <internal:date, inherits DateTime> public method sub ] { - Parameters [1] { - Parameter #0 [ <required> $interval ] + Parameter #0 [ <required> DateInterval $interval ] } + - Tentative return [ DateTime ] } Method [ <internal:date, inherits DateTime, prototype DateTimeInterface> public method getTimezone ] { - Parameters [0] { } + - Tentative return [ DateTimeZone|false ] } Method [ <internal:date, inherits DateTime> public method setTimezone ] { - Parameters [1] { - Parameter #0 [ <required> $timezone ] + Parameter #0 [ <required> DateTimeZone $timezone ] } + - Tentative return [ DateTime ] } Method [ <internal:date, inherits DateTime, prototype DateTimeInterface> public method getOffset ] { - Parameters [0] { } + - Tentative return [ int ] } Method [ <internal:date, inherits DateTime> public method setTime ] { - Parameters [4] { - Parameter #0 [ <required> $hour ] - Parameter #1 [ <required> $minute ] - Parameter #2 [ <optional> $second ] - Parameter #3 [ <optional> $microseconds ] + Parameter #0 [ <required> int $hour ] + Parameter #1 [ <required> int $minute ] + Parameter #2 [ <optional> int $second = 0 ] + Parameter #3 [ <optional> int $microsecond = 0 ] } + - Tentative return [ DateTime ] } Method [ <internal:date, inherits DateTime> public method setDate ] { - Parameters [3] { - Parameter #0 [ <required> $year ] - Parameter #1 [ <required> $month ] - Parameter #2 [ <required> $day ] + Parameter #0 [ <required> int $year ] + Parameter #1 [ <required> int $month ] + Parameter #2 [ <required> int $day ] } + - Tentative return [ DateTime ] } Method [ <internal:date, inherits DateTime> public method setISODate ] { - Parameters [3] { - Parameter #0 [ <required> $year ] - Parameter #1 [ <required> $week ] - Parameter #2 [ <optional> $day ] + Parameter #0 [ <required> int $year ] + Parameter #1 [ <required> int $week ] + Parameter #2 [ <optional> int $dayOfWeek = 1 ] } + - Tentative return [ DateTime ] } Method [ <internal:date, inherits DateTime> public method setTimestamp ] { - Parameters [1] { - Parameter #0 [ <required> $unixtimestamp ] + Parameter #0 [ <required> int $timestamp ] } + - Tentative return [ DateTime ] } Method [ <internal:date, inherits DateTime, prototype DateTimeInterface> public method getTimestamp ] { - Parameters [0] { } + - Tentative return [ int ] } Method [ <internal:date, inherits DateTime, prototype DateTimeInterface> public method diff ] { - Parameters [2] { - Parameter #0 [ <required> $object ] - Parameter #1 [ <optional> $absolute ] + Parameter #0 [ <required> DateTimeInterface $targetObject ] + Parameter #1 [ <optional> bool $absolute = false ] } + - Tentative return [ DateInterval ] } } } - Interface [ <internal:pq> interface pq\Exception extends Throwable ] { + Interface [ <internal:pq> interface pq\Exception extends Throwable, Stringable ] { - Constants [9] { Constant [ public int INVALID_ARGUMENT ] { 0 } @@ -249,32 +296,63 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Methods [8] { Method [ <internal:Core, inherits Throwable> abstract public method getMessage ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Throwable> abstract public method getCode ] { + + - Parameters [0] { + } } Method [ <internal:Core, inherits Throwable> abstract public method getFile ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Throwable> abstract public method getLine ] { + + - Parameters [0] { + } + - Return [ int ] } Method [ <internal:Core, inherits Throwable> abstract public method getTrace ] { + + - Parameters [0] { + } + - Return [ array ] } Method [ <internal:Core, inherits Throwable> abstract public method getPrevious ] { + + - Parameters [0] { + } + - Return [ ?Throwable ] } Method [ <internal:Core, inherits Throwable> abstract public method getTraceAsString ] { + + - Parameters [0] { + } + - Return [ string ] } - Method [ <internal:Core, inherits Throwable> abstract public method __toString ] { + Method [ <internal:Core, inherits Stringable> abstract public method __toString ] { + + - Parameters [0] { + } + - Return [ string ] } } } - Class [ <internal:pq> class pq\Exception\InvalidArgumentException extends InvalidArgumentException implements Throwable, pq\Exception ] { + Class [ <internal:pq> class pq\Exception\InvalidArgumentException extends InvalidArgumentException implements Throwable, Stringable, pq\Exception ] { - Constants [9] { Constant [ public int INVALID_ARGUMENT ] { 0 } @@ -295,52 +373,87 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [4] { - Property [ <default> protected $message ] - Property [ <default> protected $code ] - Property [ <default> protected $file ] - Property [ <default> protected $line ] + Property [ protected $message = '' ] + Property [ protected $code = 0 ] + Property [ protected string $file = '' ] + Property [ protected int $line = 0 ] } - Methods [10] { Method [ <internal:Core, inherits Exception, ctor> public method __construct ] { - Parameters [3] { - Parameter #0 [ <optional> $message ] - Parameter #1 [ <optional> $code ] - Parameter #2 [ <optional> $previous ] + Parameter #0 [ <optional> string $message = "" ] + Parameter #1 [ <optional> int $code = 0 ] + Parameter #2 [ <optional> ?Throwable $previous = null ] } } Method [ <internal:Core, inherits Exception> public method __wakeup ] { + + - Parameters [0] { + } + - Tentative return [ void ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getMessage ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getCode ] { + + - Parameters [0] { + } } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getFile ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getLine ] { + + - Parameters [0] { + } + - Return [ int ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getTrace ] { + + - Parameters [0] { + } + - Return [ array ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getPrevious ] { + + - Parameters [0] { + } + - Return [ ?Throwable ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getTraceAsString ] { + + - Parameters [0] { + } + - Return [ string ] } - Method [ <internal:Core, inherits Exception, prototype Throwable> public method __toString ] { + Method [ <internal:Core, inherits Exception, prototype Stringable> public method __toString ] { + + - Parameters [0] { + } + - Return [ string ] } } } - Class [ <internal:pq> class pq\Exception\RuntimeException extends RuntimeException implements Throwable, pq\Exception ] { + Class [ <internal:pq> class pq\Exception\RuntimeException extends RuntimeException implements Stringable, Throwable, pq\Exception ] { - Constants [9] { Constant [ public int INVALID_ARGUMENT ] { 0 } @@ -361,52 +474,87 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [4] { - Property [ <default> protected $message ] - Property [ <default> protected $code ] - Property [ <default> protected $file ] - Property [ <default> protected $line ] + Property [ protected $message = '' ] + Property [ protected $code = 0 ] + Property [ protected string $file = '' ] + Property [ protected int $line = 0 ] } - Methods [10] { Method [ <internal:Core, inherits Exception, ctor> public method __construct ] { - Parameters [3] { - Parameter #0 [ <optional> $message ] - Parameter #1 [ <optional> $code ] - Parameter #2 [ <optional> $previous ] + Parameter #0 [ <optional> string $message = "" ] + Parameter #1 [ <optional> int $code = 0 ] + Parameter #2 [ <optional> ?Throwable $previous = null ] } } Method [ <internal:Core, inherits Exception> public method __wakeup ] { + + - Parameters [0] { + } + - Tentative return [ void ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getMessage ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getCode ] { + + - Parameters [0] { + } } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getFile ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getLine ] { + + - Parameters [0] { + } + - Return [ int ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getTrace ] { + + - Parameters [0] { + } + - Return [ array ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getPrevious ] { + + - Parameters [0] { + } + - Return [ ?Throwable ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getTraceAsString ] { + + - Parameters [0] { + } + - Return [ string ] } - Method [ <internal:Core, inherits Exception, prototype Throwable> public method __toString ] { + Method [ <internal:Core, inherits Exception, prototype Stringable> public method __toString ] { + + - Parameters [0] { + } + - Return [ string ] } } } - Class [ <internal:pq> class pq\Exception\BadMethodCallException extends BadMethodCallException implements Throwable, pq\Exception ] { + Class [ <internal:pq> class pq\Exception\BadMethodCallException extends BadMethodCallException implements Stringable, Throwable, pq\Exception ] { - Constants [9] { Constant [ public int INVALID_ARGUMENT ] { 0 } @@ -427,52 +575,87 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [4] { - Property [ <default> protected $message ] - Property [ <default> protected $code ] - Property [ <default> protected $file ] - Property [ <default> protected $line ] + Property [ protected $message = '' ] + Property [ protected $code = 0 ] + Property [ protected string $file = '' ] + Property [ protected int $line = 0 ] } - Methods [10] { Method [ <internal:Core, inherits Exception, ctor> public method __construct ] { - Parameters [3] { - Parameter #0 [ <optional> $message ] - Parameter #1 [ <optional> $code ] - Parameter #2 [ <optional> $previous ] + Parameter #0 [ <optional> string $message = "" ] + Parameter #1 [ <optional> int $code = 0 ] + Parameter #2 [ <optional> ?Throwable $previous = null ] } } Method [ <internal:Core, inherits Exception> public method __wakeup ] { + + - Parameters [0] { + } + - Tentative return [ void ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getMessage ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getCode ] { + + - Parameters [0] { + } } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getFile ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getLine ] { + + - Parameters [0] { + } + - Return [ int ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getTrace ] { + + - Parameters [0] { + } + - Return [ array ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getPrevious ] { + + - Parameters [0] { + } + - Return [ ?Throwable ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getTraceAsString ] { + + - Parameters [0] { + } + - Return [ string ] } - Method [ <internal:Core, inherits Exception, prototype Throwable> public method __toString ] { + Method [ <internal:Core, inherits Exception, prototype Stringable> public method __toString ] { + + - Parameters [0] { + } + - Return [ string ] } } } - Class [ <internal:pq> class pq\Exception\DomainException extends DomainException implements Throwable, pq\Exception ] { + Class [ <internal:pq> class pq\Exception\DomainException extends DomainException implements Throwable, Stringable, pq\Exception ] { - Constants [9] { Constant [ public int INVALID_ARGUMENT ] { 0 } @@ -493,55 +676,90 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [5] { - Property [ <default> protected $message ] - Property [ <default> protected $code ] - Property [ <default> protected $file ] - Property [ <default> protected $line ] - Property [ <default> public $sqlstate ] + Property [ protected $message = '' ] + Property [ protected $code = 0 ] + Property [ protected string $file = '' ] + Property [ protected int $line = 0 ] + Property [ public $sqlstate = NULL ] } - Methods [10] { Method [ <internal:Core, inherits Exception, ctor> public method __construct ] { - Parameters [3] { - Parameter #0 [ <optional> $message ] - Parameter #1 [ <optional> $code ] - Parameter #2 [ <optional> $previous ] + Parameter #0 [ <optional> string $message = "" ] + Parameter #1 [ <optional> int $code = 0 ] + Parameter #2 [ <optional> ?Throwable $previous = null ] } } Method [ <internal:Core, inherits Exception> public method __wakeup ] { + + - Parameters [0] { + } + - Tentative return [ void ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getMessage ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getCode ] { + + - Parameters [0] { + } } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getFile ] { + + - Parameters [0] { + } + - Return [ string ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getLine ] { + + - Parameters [0] { + } + - Return [ int ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getTrace ] { + + - Parameters [0] { + } + - Return [ array ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getPrevious ] { + + - Parameters [0] { + } + - Return [ ?Throwable ] } Method [ <internal:Core, inherits Exception, prototype Throwable> final public method getTraceAsString ] { + + - Parameters [0] { + } + - Return [ string ] } - Method [ <internal:Core, inherits Exception, prototype Throwable> public method __toString ] { + Method [ <internal:Core, inherits Exception, prototype Stringable> public method __toString ] { + + - Parameters [0] { + } + - Return [ string ] } } } Class [ <internal:pq> class pq\Connection ] { - - Constants [22] { + - Constants [25] { Constant [ public int OK ] { 0 } Constant [ public int BAD ] { 1 } Constant [ public int STARTED ] { 2 } @@ -550,6 +768,9 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Constant [ public int AUTH_OK ] { 5 } Constant [ public int SSL_STARTUP ] { 7 } Constant [ public int SETENV ] { 6 } + Constant [ public int CHECK_WRITABLE ] { 9 } + Constant [ public int CONSUME ] { 10 } + Constant [ public int GSS_STARTUP ] { 11 } Constant [ public int TRANS_IDLE ] { 0 } Constant [ public int TRANS_ACTIVE ] { 1 } Constant [ public int TRANS_INTRANS ] { 2 } @@ -572,30 +793,33 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Static methods [0] { } - - Properties [23] { - Property [ <default> public $status ] - Property [ <default> public $transactionStatus ] - Property [ <default> public $socket ] - Property [ <default> public $errorMessage ] - Property [ <default> public $busy ] - Property [ <default> public $encoding ] - Property [ <default> public $unbuffered ] - Property [ <default> public $nonblocking ] - Property [ <default> public $db ] - Property [ <default> public $user ] - Property [ <default> public $pass ] - Property [ <default> public $host ] - Property [ <default> public $port ] - Property [ <default> public $params ] - Property [ <default> public $options ] - Property [ <default> public $eventHandlers ] - Property [ <default> public $listeners ] - Property [ <default> public $converters ] - Property [ <default> public $defaultFetchType ] - Property [ <default> public $defaultTransactionIsolation ] - Property [ <default> public $defaultTransactionReadonly ] - Property [ <default> public $defaultTransactionDeferrable ] - Property [ <default> public $defaultAutoConvert ] + - Properties [26] { + Property [ public $status = 1 ] + Property [ public $transactionStatus = 4 ] + Property [ public $socket = NULL ] + Property [ public $errorMessage = NULL ] + Property [ public $busy = false ] + Property [ public $encoding = NULL ] + Property [ public $unbuffered = false ] + Property [ public $nonblocking = false ] + Property [ public $db = NULL ] + Property [ public $user = NULL ] + Property [ public $pass = NULL ] + Property [ public $host = NULL ] + Property [ public $port = NULL ] + Property [ public $params = NULL ] + Property [ public $options = NULL ] + Property [ public $eventHandlers = NULL ] + Property [ public $listeners = NULL ] + Property [ public $converters = NULL ] + Property [ public $defaultFetchType = 0 ] + Property [ public $defaultTransactionIsolation = 0 ] + Property [ public $defaultTransactionReadonly = false ] + Property [ public $defaultTransactionDeferrable = false ] + Property [ public $defaultAutoConvert = 65535 ] + Property [ public readonly $libraryVersion = NULL ] + Property [ public readonly $protocolVersion = NULL ] + Property [ public readonly $serverVersion = NULL ] } - Methods [31] { @@ -603,7 +827,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [2] { Parameter #0 [ <required> $dsn ] - Parameter #1 [ <optional> $flags ] + Parameter #1 [ <optional> $flags = <default> ] } } @@ -642,7 +866,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [2] { Parameter #0 [ <required> $query ] - Parameter #1 [ <optional> $callable ] + Parameter #1 [ <optional> $callable = <default> ] } } @@ -651,7 +875,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [3] { Parameter #0 [ <required> $query ] Parameter #1 [ <required> array $params ] - Parameter #2 [ <optional> array or NULL $types ] + Parameter #2 [ <optional> ?array $types = <default> ] } } @@ -660,8 +884,8 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [4] { Parameter #0 [ <required> $query ] Parameter #1 [ <required> array $params ] - Parameter #2 [ <optional> array or NULL $types ] - Parameter #3 [ <optional> $callable ] + Parameter #2 [ <optional> ?array $types = <default> ] + Parameter #3 [ <optional> $callable = <default> ] } } @@ -670,7 +894,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [3] { Parameter #0 [ <required> $name ] Parameter #1 [ <required> $query ] - Parameter #2 [ <optional> array or NULL $types ] + Parameter #2 [ <optional> ?array $types = <default> ] } } @@ -679,7 +903,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [3] { Parameter #0 [ <required> $name ] Parameter #1 [ <required> $query ] - Parameter #2 [ <optional> array or NULL $types ] + Parameter #2 [ <optional> ?array $types = <default> ] } } @@ -697,7 +921,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [3] { Parameter #0 [ <required> $name ] Parameter #1 [ <required> $flags ] - Parameter #2 [ <optional> $query ] + Parameter #2 [ <optional> $query = <default> ] } } @@ -726,8 +950,8 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Method [ <internal:pq> public method listenAsync ] { - Parameters [2] { - Parameter #0 [ <optional> $channel ] - Parameter #1 [ <optional> $callable ] + Parameter #0 [ <optional> $channel = <default> ] + Parameter #1 [ <optional> $callable = <default> ] } } @@ -784,25 +1008,25 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Method [ <internal:pq> public method startTransaction ] { - Parameters [3] { - Parameter #0 [ <optional> $isolation ] - Parameter #1 [ <optional> $readonly ] - Parameter #2 [ <optional> $deferrable ] + Parameter #0 [ <optional> $isolation = <default> ] + Parameter #1 [ <optional> $readonly = <default> ] + Parameter #2 [ <optional> $deferrable = <default> ] } } Method [ <internal:pq> public method startTransactionAsync ] { - Parameters [3] { - Parameter #0 [ <optional> $isolation ] - Parameter #1 [ <optional> $readonly ] - Parameter #2 [ <optional> $deferrable ] + Parameter #0 [ <optional> $isolation = <default> ] + Parameter #1 [ <optional> $readonly = <default> ] + Parameter #2 [ <optional> $deferrable = <default> ] } } Method [ <internal:pq> public method trace ] { - Parameters [1] { - Parameter #0 [ <optional> $stdio_stream ] + Parameter #0 [ <optional> $stdio_stream = <default> ] } } @@ -849,7 +1073,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [1] { - Property [ <default> public $connection ] + Property [ public $connection = NULL ] } - Methods [2] { @@ -1041,7 +1265,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [1] { - Property [ <default> public $connection ] + Property [ public $connection = NULL ] } - Methods [2] { @@ -1049,22 +1273,22 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [2] { Parameter #0 [ <required> pq\Connection $connection ] - Parameter #1 [ <optional> array or NULL $namespaces ] + Parameter #1 [ <optional> ?array $namespaces = <default> ] } } Method [ <internal:pq> public method refresh ] { - Parameters [1] { - Parameter #0 [ <optional> array or NULL $namespaces ] + Parameter #0 [ <optional> ?array $namespaces = <default> ] } } } } - Class [ <internal:pq> <iterateable> class pq\Result implements Traversable, Countable ] { + Class [ <internal:pq> <iterateable> class pq\Result implements IteratorAggregate, Traversable, Countable ] { - - Constants [21] { + - Constants [22] { Constant [ public int EMPTY_QUERY ] { 0 } Constant [ public int COMMAND_OK ] { 1 } Constant [ public int TUPLES_OK ] { 2 } @@ -1085,6 +1309,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Constant [ public int CONV_ARRAY ] { 16 } Constant [ public int CONV_DATETIME ] { 32 } Constant [ public int CONV_JSON ] { 256 } + Constant [ public int CONV_BYTEA ] { 8 } Constant [ public int CONV_ALL ] { 65535 } } @@ -1095,18 +1320,18 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [9] { - Property [ <default> public $status ] - Property [ <default> public $statusMessage ] - Property [ <default> public $errorMessage ] - Property [ <default> public $diag ] - Property [ <default> public $numRows ] - Property [ <default> public $numCols ] - Property [ <default> public $affectedRows ] - Property [ <default> public $fetchType ] - Property [ <default> public $autoConvert ] + Property [ public $status = NULL ] + Property [ public $statusMessage = NULL ] + Property [ public $errorMessage = NULL ] + Property [ public $diag = NULL ] + Property [ public $numRows = 0 ] + Property [ public $numCols = 0 ] + Property [ public $affectedRows = 0 ] + Property [ public $fetchType = 0 ] + Property [ public $autoConvert = 65535 ] } - - Methods [9] { + - Methods [10] { Method [ <internal:pq> public method bind ] { - Parameters [2] { @@ -1124,7 +1349,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Method [ <internal:pq> public method fetchRow ] { - Parameters [1] { - Parameter #0 [ <optional> $fetch_type ] + Parameter #0 [ <optional> $fetch_type = <default> ] } } @@ -1132,21 +1357,21 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [2] { Parameter #0 [ <required> &$ref ] - Parameter #1 [ <optional> $col ] + Parameter #1 [ <optional> $col = <default> ] } } Method [ <internal:pq> public method fetchAll ] { - Parameters [1] { - Parameter #0 [ <optional> $fetch_type ] + Parameter #0 [ <optional> $fetch_type = <default> ] } } Method [ <internal:pq> public method fetchAllCols ] { - Parameters [1] { - Parameter #0 [ <optional> $col ] + Parameter #0 [ <optional> $col = <default> ] } } @@ -1154,14 +1379,15 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [0] { } + - Tentative return [ int ] } Method [ <internal:pq> public method map ] { - Parameters [3] { - Parameter #0 [ <optional> $keys ] - Parameter #1 [ <optional> $vals ] - Parameter #2 [ <optional> $fetch_type ] + Parameter #0 [ <optional> $keys = <default> ] + Parameter #1 [ <optional> $vals = <default> ] + Parameter #2 [ <optional> $fetch_type = <default> ] } } @@ -1170,6 +1396,13 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [0] { } } + + Method [ <internal:pq, prototype IteratorAggregate> public method getIterator ] { + + - Parameters [0] { + } + - Tentative return [ Traversable ] + } } } @@ -1185,10 +1418,10 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [4] { - Property [ <default> public $name ] - Property [ <default> public $connection ] - Property [ <default> public $query ] - Property [ <default> public $types ] + Property [ public $name = NULL ] + Property [ public $connection = NULL ] + Property [ public $query = NULL ] + Property [ public $types = NULL ] } - Methods [10] { @@ -1198,8 +1431,8 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Parameter #0 [ <required> pq\Connection $connection ] Parameter #1 [ <required> $name ] Parameter #2 [ <required> $query ] - Parameter #3 [ <optional> array or NULL $types ] - Parameter #4 [ <optional> $async ] + Parameter #3 [ <optional> ?array $types = <default> ] + Parameter #4 [ <optional> $async = <default> ] } } @@ -1239,15 +1472,15 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Method [ <internal:pq> public method exec ] { - Parameters [1] { - Parameter #0 [ <optional> array or NULL $params ] + Parameter #0 [ <optional> ?array $params = <default> ] } } Method [ <internal:pq> public method execAsync ] { - Parameters [2] { - Parameter #0 [ <optional> array or NULL $params ] - Parameter #1 [ <optional> $callable ] + Parameter #0 [ <optional> ?array $params = <default> ] + Parameter #1 [ <optional> $callable = <default> ] } } @@ -1280,10 +1513,10 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [4] { - Property [ <default> public $connection ] - Property [ <default> public $isolation ] - Property [ <default> public $readonly ] - Property [ <default> public $deferrable ] + Property [ public $connection = NULL ] + Property [ public $isolation = NULL ] + Property [ public $readonly = false ] + Property [ public $deferrable = false ] } - Methods [16] { @@ -1291,10 +1524,10 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [5] { Parameter #0 [ <required> pq\Connection $connection ] - Parameter #1 [ <optional> $async ] - Parameter #2 [ <optional> $isolation ] - Parameter #3 [ <optional> $readonly ] - Parameter #4 [ <optional> $deferrable ] + Parameter #1 [ <optional> $async = <default> ] + Parameter #2 [ <optional> $isolation = <default> ] + Parameter #3 [ <optional> $readonly = <default> ] + Parameter #4 [ <optional> $deferrable = <default> ] } } @@ -1364,14 +1597,14 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [2] { Parameter #0 [ <required> $oid ] - Parameter #1 [ <optional> $mode ] + Parameter #1 [ <optional> $mode = <default> ] } } Method [ <internal:pq> public method createLOB ] { - Parameters [1] { - Parameter #0 [ <optional> $mode ] + Parameter #0 [ <optional> $mode = <default> ] } } @@ -1386,7 +1619,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [2] { Parameter #0 [ <required> $local_path ] - Parameter #1 [ <optional> $oid ] + Parameter #1 [ <optional> $oid = <default> ] } } @@ -1417,10 +1650,10 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [4] { - Property [ <default> public $name ] - Property [ <default> public $connection ] - Property [ <default> public $query ] - Property [ <default> public $flags ] + Property [ public $name = NULL ] + Property [ public $connection = NULL ] + Property [ public $query = NULL ] + Property [ public $flags = NULL ] } - Methods [9] { @@ -1431,7 +1664,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Parameter #1 [ <required> $name ] Parameter #2 [ <required> $flags ] Parameter #3 [ <required> $query ] - Parameter #4 [ <optional> $async ] + Parameter #4 [ <optional> $async = <default> ] } } @@ -1469,23 +1702,23 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Method [ <internal:pq> public method move ] { - Parameters [1] { - Parameter #0 [ <optional> $spec ] + Parameter #0 [ <optional> $spec = <default> ] } } Method [ <internal:pq> public method fetchAsync ] { - Parameters [2] { - Parameter #0 [ <optional> $spec ] - Parameter #1 [ <optional> $callback ] + Parameter #0 [ <optional> $spec = <default> ] + Parameter #1 [ <optional> $callback = <default> ] } } Method [ <internal:pq> public method moveAsync ] { - Parameters [2] { - Parameter #0 [ <optional> $spec ] - Parameter #1 [ <optional> $callback ] + Parameter #0 [ <optional> $spec = <default> ] + Parameter #1 [ <optional> $callback = <default> ] } } } @@ -1505,10 +1738,10 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [4] { - Property [ <default> public $connection ] - Property [ <default> public $expression ] - Property [ <default> public $direction ] - Property [ <default> public $options ] + Property [ public $connection = NULL ] + Property [ public $expression = NULL ] + Property [ public $direction = NULL ] + Property [ public $options = NULL ] } - Methods [4] { @@ -1518,7 +1751,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Parameter #0 [ <required> pq\Connection $connection ] Parameter #1 [ <required> $expression ] Parameter #2 [ <required> $direction ] - Parameter #3 [ <optional> $options ] + Parameter #3 [ <optional> $options = <default> ] } } @@ -1532,7 +1765,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Method [ <internal:pq> public method end ] { - Parameters [1] { - Parameter #0 [ <optional> $error ] + Parameter #0 [ <optional> $error = <default> ] } } @@ -1561,9 +1794,9 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { } - Properties [3] { - Property [ <default> public $transaction ] - Property [ <default> public $oid ] - Property [ <default> public $stream ] + Property [ public $transaction = NULL ] + Property [ public $oid = 0 ] + Property [ public $stream = NULL ] } - Methods [6] { @@ -1571,8 +1804,8 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [3] { Parameter #0 [ <required> pq\Transaction $transaction ] - Parameter #1 [ <optional> $oid ] - Parameter #2 [ <optional> $mode ] + Parameter #1 [ <optional> $oid = <default> ] + Parameter #2 [ <optional> $mode = <default> ] } } @@ -1586,8 +1819,8 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Method [ <internal:pq> public method read ] { - Parameters [2] { - Parameter #0 [ <optional> $length ] - Parameter #1 [ <optional> &$read ] + Parameter #0 [ <optional> $length = <default> ] + Parameter #1 [ <optional> &$read = <default> ] } } @@ -1595,7 +1828,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { - Parameters [2] { Parameter #0 [ <required> $offset ] - Parameter #1 [ <optional> $whence ] + Parameter #1 [ <optional> $whence = <default> ] } } @@ -1608,7 +1841,7 @@ Extension [ <persistent> extension #117 pq version 2.1.8 ] { Method [ <internal:pq> public method truncate ] { - Parameters [1] { - Parameter #0 [ <optional> $length ] + Parameter #0 [ <optional> $length = <default> ] } } } diff --git a/php-pecl-pq.spec b/php-pecl-pq.spec index ce9c285..f87d346 100644 --- a/php-pecl-pq.spec +++ b/php-pecl-pq.spec @@ -1,57 +1,44 @@ # remirepo spec file for php-pecl-pq # -# Copyright (c) 2014-2021 Remi Collet -# License: CC-BY-SA +# Copyright (c) 2014-2024 Remi Collet +# License: CC-BY-SA-4.0 # http://creativecommons.org/licenses/by-sa/4.0/ # # Please, preserve the changelog entries # -%if 0%{?scl:1} -%global sub_prefix %{scl_prefix} -%scl_package php-pecl-pq -%endif +%{?scl:%scl_package php-pecl-pq} # Build using "--without tests" to disable tests %bcond_without tests -%global gh_commit e381164032a750583657e449875f62d52b7b6609 -%global gh_short %(c=%{gh_commit}; echo ${c:0:7}) -%global gh_owner m6w6 -%global gh_project ext-pq -#global gh_date 20150819 %global with_zts 0%{!?_without_zts:%{?__ztsphp:1}} %global pecl_name pq #global prever RC1 %global ini_name 50-%{pecl_name}.ini +%global sources %{pecl_name}-%{version} +%global _configure ../%{sources}/configure + Summary: PostgreSQL client library (libpq) binding -Name: %{?sub_prefix}php-pecl-%{pecl_name} -Version: 2.1.8 -%if 0%{?gh_date:1} -Release: 0.11.%{gh_date}git%{gh_short}%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} -Source0: https://github.com/%{gh_owner}/%{gh_project}/archive/%{gh_commit}/%{pecl_name}-%{version}-%{gh_short}.tar.gz -%else -Release: 5%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} +Name: %{?scl_prefix}php-pecl-%{pecl_name} +Version: 2.2.3 +Release: 2%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}} Source0: https://pecl.php.net/get/%{pecl_name}-%{version}%{?prever}.tgz -%endif -License: BSD +License: BSD-2-Clause URL: https://pecl.php.net/package/%{pecl_name} -# Upstream patches -Patch0: %{pecl_name}-php81.patch - -%if 0%{?fedora} >= 29 && 0%{?rhel} >= 8 +%if 0%{?fedora} >= 29 || 0%{?rhel} >= 8 BuildRequires: libpq-devel > 9 %else BuildRequires: postgresql-devel > 9 %endif BuildRequires: make BuildRequires: %{?dtsprefix}gcc -BuildRequires: %{?scl_prefix}php-devel > 7 +BuildRequires: %{?scl_prefix}php-devel >= 7.0 BuildRequires: %{?scl_prefix}php-pear BuildRequires: %{?scl_prefix}php-json -BuildRequires: %{?sub_prefix}php-pecl-raphf-devel >= 1.1.0 +BuildRequires: %{?scl_prefix}php-pecl-raphf-devel >= 1.1.0 %if %{with tests} BuildRequires: postgresql-server BuildRequires: postgresql-contrib @@ -60,33 +47,12 @@ BuildRequires: postgresql-contrib Requires: %{?scl_prefix}php(zend-abi) = %{php_zend_api} Requires: %{?scl_prefix}php(api) = %{php_core_api} Requires: %{?scl_prefix}php-json%{?_isa} -Requires: %{?sub_prefix}php-raphf%{?_isa} >= 1.1.0 -%{?_sclreq:Requires: %{?scl_prefix}runtime%{?_sclreq}%{?_isa}} +Requires: %{?scl_prefix}php-raphf%{?_isa} >= 1.1.0 Provides: %{?scl_prefix}php-%{pecl_name} = %{version} Provides: %{?scl_prefix}php-%{pecl_name}%{?_isa} = %{version} Provides: %{?scl_prefix}php-pecl(%{pecl_name}) = %{version} Provides: %{?scl_prefix}php-pecl(%{pecl_name})%{?_isa} = %{version} -%if "%{?scl_prefix}" != "%{?sub_prefix}" -Provides: %{?scl_prefix}php-pecl-%{pecl_name} = %{version}-%{release} -Provides: %{?scl_prefix}php-pecl-%{pecl_name}%{?_isa} = %{version}-%{release} -%endif - -%if "%{?packager}" == "Remi Collet" && 0%{!?scl:1} && 0%{?rhel} -# Other third party repo stuff -%if "%{php_version}" > "7.2" -Obsoletes: php72u-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.3" -Obsoletes: php73-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "7.4" -Obsoletes: php74-pecl-%{pecl_name} <= %{version} -%endif -%if "%{php_version}" > "8.0" -Obsoletes: php80-pecl-%{pecl_name} <= %{version} -%endif -%endif %description @@ -105,21 +71,13 @@ Package built for PHP %(%{__php} -r 'echo PHP_MAJOR_VERSION.".".PHP_MINOR_VERSIO %prep %setup -q -c -%if 0%{?ghdate} -mv %{gh_project}-%{gh_commit} NTS -mv NTS/package.xml . -%else -mv %{pecl_name}-%{version}%{?prever} NTS -%endif # Don't install tests sed -e '/role="test"/d' \ %{?_licensedir: -e '/LICENSE/s/role="doc"/role="src"/' }\ -i package.xml -cd NTS -%patch0 -p1 - +cd %{sources} # Sanity check, really often broken extver=$(sed -n '/#define PHP_PQ_VERSION/{s/.* "//;s/".*$//;p}' php_pq.h) if test "x${extver}" != "x%{version}%{?prever}"; then @@ -128,9 +86,9 @@ if test "x${extver}" != "x%{version}%{?prever}"; then fi cd .. +mkdir NTS %if %{with_zts} -# Duplicate source tree for NTS / ZTS build -cp -pr NTS ZTS +mkdir ZTS %endif # Create configuration file @@ -143,19 +101,20 @@ EOF %build %{?dtsenable} -cd NTS -%{_bindir}/phpize +cd %{sources} +%{__phpize} + +cd ../NTS %configure \ --with-libdir=%{_lib} \ - --with-php-config=%{_bindir}/php-config + --with-php-config=%{__phpconfig} make %{?_smp_mflags} %if %{with_zts} cd ../ZTS -%{_bindir}/zts-phpize %configure \ --with-libdir=%{_lib} \ - --with-php-config=%{_bindir}/zts-php-config + --with-php-config=%{__ztsphpconfig} make %{?_smp_mflags} %endif @@ -179,7 +138,7 @@ install -D -m 644 %{ini_name} %{buildroot}%{php_ztsinidir}/%{ini_name} # Documentation for i in $(grep 'role="doc"' package.xml | sed -e 's/^.*name="//;s/".*$//') -do install -Dpm 644 NTS/$i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i +do install -Dpm 644 %{sources}/$i %{buildroot}%{pecl_docdir}/%{pecl_name}/$i done @@ -205,8 +164,8 @@ fi %check : ignore tests with erratic results -rm ?TS/tests/cancel001.phpt -rm ?TS/tests/flush001.phpt +rm %{sources}/tests/cancel001.phpt +rm %{sources}/tests/flush001.phpt OPT="-n" [ -f %{php_extdir}/json.so ] && OPT="$OPT -d extension=json.so" @@ -215,13 +174,13 @@ OPT="-n" : Minimal load test for NTS extension %{__php} $OPT \ --define extension=%{buildroot}%{php_extdir}/%{pecl_name}.so \ - --modules | grep %{pecl_name} + --modules | grep '^%{pecl_name}$' %if %{with_zts} : Minimal load test for ZTS extension %{__ztsphp} $OPT \ --define extension=%{buildroot}%{php_ztsextdir}/%{pecl_name}.so \ - --modules | grep %{pecl_name} + --modules | grep '^%{pecl_name}$' %endif %if %{with tests} @@ -238,28 +197,23 @@ port = $PORT EOF pg_ctl -D $DATABASE -l $PWD/server.log -w -t 200 start createdb -h localhost -p $PORT rpmtest -cd NTS -sed -e "/PQ_DSN/s/\"host.*\"/'host=localhost port=$PORT dbname=rpmtest'/" \ - -i tests/_setup.inc + +cd %{sources} +export PQ_DSN="host=localhost port=$PORT dbname=rpmtest" : Upstream test suite for NTS extension TEST_PHP_EXECUTABLE=%{__php} \ -TEST_PHP_ARGS="$OPT -d extension=$PWD/modules/%{pecl_name}.so" \ +TEST_PHP_ARGS="$OPT -d extension=$PWD/../NTS/modules/%{pecl_name}.so" \ NO_INTERACTION=1 \ REPORT_EXIT_STATUS=1 \ -%{__php} -n run-tests.php --show-diff || RET=1 +%{__php} -n run-tests.php -q --show-diff || RET=1 %if %{with_zts} -cd ../ZTS -sed -e "/PQ_DSN/s/\"host.*\"/'host=localhost port=$PORT dbname=rpmtest'/" \ - -i tests/_setup.inc - : Upstream test suite for ZTS extension -TEST_PHP_EXECUTABLE=%{_bindir}/zts-php \ -TEST_PHP_ARGS="$OPT -d extension=$PWD/modules/%{pecl_name}.so" \ -NO_INTERACTION=1 \ +TEST_PHP_EXECUTABLE=%{__ztsphp} \ +TEST_PHP_ARGS="$OPT -d extension=$PWD/../ZTS/modules/%{pecl_name}.so" \ REPORT_EXIT_STATUS=1 \ -%{_bindir}/zts-php -n run-tests.php --show-diff || RET=1 +%{__ztsphp} -n run-tests.php -q --show-diff || RET=1 %endif cd .. @@ -274,7 +228,7 @@ exit $RET %files %doc %{pecl_docdir}/%{pecl_name} -%{?_licensedir:%license NTS/LICENSE} +%{?_licensedir:%license %{sources}/LICENSE} %{pecl_xmldir}/%{name}.xml %config(noreplace) %{php_inidir}/%{ini_name} @@ -287,6 +241,41 @@ exit $RET %changelog +* Fri Feb 16 2024 Remi Collet <remi@remirepo.net> - 2.2.3-2 +- F40: fix build dependencies + +* Tue Feb 6 2024 Remi Collet <remi@remirepo.net> - 2.2.3-1 +- update to 2.2.3 +- drop patch merged upstream + +* Mon Jan 29 2024 Remi Collet <remi@remirepo.net> - 2.2.2-5 +- Fix incompatible pointer types using patch from + https://github.com/m6w6/ext-pq/pull/52 + +* Wed Aug 30 2023 Remi Collet <remi@remirepo.net> - 2.2.2-2 +- rebuild for PHP 8.3.0RC1 + +* Mon Jun 12 2023 Remi Collet <remi@remirepo.net> - 2.2.2-1 +- update to 2.2.2 +- build out of sources tree + +* Fri Mar 3 2023 Remi Collet <remi@remirepo.net> - 2.2.1-1 +- update to 2.2.1 + +* Thu Sep 8 2022 Remi Collet <remi@remirepo.net> - 2.2.0-8 +- add upstream patch for 8.2 and from + https://github.com/m6w6/ext-pq/pull/44 + +* Wed Sep 1 2021 Remi Collet <remi@remirepo.net> - 2.2.0-7 +- rebuild for 8.1.0RC1 + +* Tue Aug 31 2021 Remi Collet <remi@remirepo.net> - 2.2.0-1 +- update to 2.2.0 + +* Wed Aug 4 2021 Remi Collet <remi@remirepo.net> - 2.1.8-6 +- add patch for 8.1.0beta2 from + https://github.com/m6w6/ext-pq/pull/41 + * Fri Jun 11 2021 Remi Collet <remi@remirepo.net> - 2.1.8-5 - add patches for 8.1 from upstream and from https://github.com/m6w6/ext-pq/pull/40 diff --git a/pq-php81.patch b/pq-php81.patch deleted file mode 100644 index 3d1fde6..0000000 --- a/pq-php81.patch +++ /dev/null @@ -1,265 +0,0 @@ -From c9082b82cd9275d2ff9027b108ea01ab88e70294 Mon Sep 17 00:00:00 2001 -From: Michael Wallner <mike@php.net> -Date: Fri, 15 Jan 2021 13:38:41 +0100 -Subject: [PATCH] fix PHP-master - ---- - src/php_pq_params.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/src/php_pq_params.c b/src/php_pq_params.c -index a3ee6b8..259fbb9 100644 ---- a/src/php_pq_params.c -+++ b/src/php_pq_params.c -@@ -307,7 +307,8 @@ static int apply_to_params(zval *zp, void *arg_ptr) - { - struct apply_to_params_arg *arg = arg_ptr; - -- SEPARATE_ZVAL_IF_NOT_REF(zp); -+ ZVAL_DEREF(zp); -+ SEPARATE_ZVAL(zp); - php_pq_params_set_param(arg->params, arg->index++, zp); - return ZEND_HASH_APPLY_KEEP; - } - -From 320bae0144fab755d678317f7ec14f9cb3ae1869 Mon Sep 17 00:00:00 2001 -From: Michael Wallner <mike@php.net> -Date: Wed, 10 Mar 2021 11:22:50 +0100 -Subject: [PATCH] compatibility with master - ---- - src/php_pq_misc.h | 14 +++++----- - src/php_pqres.c | 4 +-- - tests/res001.phpt | 67 ++++++++++++++++++++++++++--------------------- - 3 files changed, 46 insertions(+), 39 deletions(-) - -diff --git a/src/php_pq_misc.h b/src/php_pq_misc.h -index 07bd596..7ccda3e 100644 ---- a/src/php_pq_misc.h -+++ b/src/php_pq_misc.h -@@ -40,13 +40,6 @@ extern char *php_pq_rtrim(char *e); - /* R, W, RW */ - extern const char *php_pq_strmode(long mode); - --/* compare array index */ --#if PHP_VERSION_ID >= 80000 --extern int php_pq_compare_index(Bucket *lptr, Bucket *rptr); --#else --extern int php_pq_compare_index(const void *lptr, const void *rptr); --#endif -- - /* free zval ptr values (as hash dtor) */ - extern void php_pq_hash_ptr_dtor(zval *p); - -@@ -63,6 +56,8 @@ extern HashTable *php_pq_parse_array(php_pqres_t *res, const char *val_str, size - - /* ZE compat */ - #if PHP_VERSION_ID >= 80000 -+extern int php_pq_compare_index(Bucket *lptr, Bucket *rptr); -+ - # define php_pq_call_method(objval_ptr, method_name, num_args, ...) \ - zend_call_method_with_ ## num_args ## _params( \ - Z_OBJ_P(objval_ptr), Z_OBJCE_P(objval_ptr), NULL, \ -@@ -77,6 +72,11 @@ extern HashTable *php_pq_parse_array(php_pqres_t *res, const char *val_str, size - (Z_OBJ_HT_P(objval_ptr)->cast_object && \ - SUCCESS == Z_OBJ_HT_P(objval_ptr)->cast_object(Z_OBJ_P(objval_ptr), (retval_ptr), (cast_type))) - #else -+ -+extern int php_pq_compare_index(const void *lptr, const void *rptr); -+ -+# define zend_ze_countable spl_ce_Countable -+ - # define php_pq_call_method(objval_ptr, method_name, num_args, ...) \ - zend_call_method_with_ ## num_args ## _params( \ - (objval_ptr), NULL, NULL, \ -diff --git a/src/php_pqres.c b/src/php_pqres.c -index 7e51271..be3d039 100644 ---- a/src/php_pqres.c -+++ b/src/php_pqres.c -@@ -1249,9 +1249,9 @@ PHP_MINIT_FUNCTION(pqres) - php_pqres_class_entry->create_object = php_pqres_create_object; - php_pqres_class_entry->get_iterator = php_pqres_iterator_init; - #if PHP_VERSION_ID >= 80000 -- zend_class_implements(php_pqres_class_entry, 2, zend_ce_aggregate, spl_ce_Countable); -+ zend_class_implements(php_pqres_class_entry, 2, zend_ce_aggregate, zend_ce_countable); - #else -- zend_class_implements(php_pqres_class_entry, 2, zend_ce_traversable, spl_ce_Countable); -+ zend_class_implements(php_pqres_class_entry, 2, zend_ce_traversable, zend_ce_countable); - #endif - - memcpy(&php_pqres_object_handlers, zend_get_std_object_handlers(), sizeof(zend_object_handlers)); -diff --git a/tests/res001.phpt b/tests/res001.phpt -index b2a3667..a325247 100644 ---- a/tests/res001.phpt -+++ b/tests/res001.phpt -@@ -19,7 +19,13 @@ class r extends pq\Result { - public $dummy = 2; - } - --var_dump(new pq\Result, get_object_vars(new r)); -+var_dump(new pq\Result); -+ -+echo "Test\n"; -+$v = get_object_vars(new r); -+ksort($v); -+var_dump($v); -+ - ?> - Done - --EXPECTF-- -@@ -42,6 +48,27 @@ Warning: pq\Result not initialized in %s on line %d - Warning: pq\Result not initialized in %s on line %d - - Warning: pq\Result not initialized in %s on line %d -+object(pq\Result)#%d (9) { -+ ["status"]=> -+ NULL -+ ["statusMessage"]=> -+ NULL -+ ["errorMessage"]=> -+ NULL -+ ["diag"]=> -+ NULL -+ ["numRows"]=> -+ int(0) -+ ["numCols"]=> -+ int(0) -+ ["affectedRows"]=> -+ int(0) -+ ["fetchType"]=> -+ int(0) -+ ["autoConvert"]=> -+ int(65535) -+} -+Test - - Warning: pq\Result not initialized in %s on line %d - -@@ -62,46 +89,26 @@ Warning: pq\Result not initialized in %s on line %d - Warning: pq\Result not initialized in %s on line %d - - Warning: pq\Result not initialized in %s on line %d --object(pq\Result)#%d (9) { -- ["status"]=> -- NULL -- ["statusMessage"]=> -- NULL -- ["errorMessage"]=> -- NULL -- ["diag"]=> -- NULL -- ["numRows"]=> -- int(0) -- ["numCols"]=> -- int(0) -+array(10) { - ["affectedRows"]=> - int(0) -- ["fetchType"]=> -- int(0) - ["autoConvert"]=> - int(65535) --} --array(10) { -+ ["diag"]=> -+ NULL - ["dummy"]=> - int(2) -- ["status"]=> -- NULL -- ["statusMessage"]=> -- NULL - ["errorMessage"]=> - NULL -- ["diag"]=> -- NULL -- ["numRows"]=> -+ ["fetchType"]=> - int(0) - ["numCols"]=> - int(0) -- ["affectedRows"]=> -- int(0) -- ["fetchType"]=> -+ ["numRows"]=> - int(0) -- ["autoConvert"]=> -- int(65535) -+ ["status"]=> -+ NULL -+ ["statusMessage"]=> -+ NULL - } - Done - -From 7109996c98ad7df145d88693167023b7b9be9f8c Mon Sep 17 00:00:00 2001 -From: Michael Wallner <mike@php.net> -Date: Wed, 10 Mar 2021 13:33:17 +0100 -Subject: [PATCH] typo - ---- - src/php_pq_misc.h | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/php_pq_misc.h b/src/php_pq_misc.h -index 7ccda3e..1285d8e 100644 ---- a/src/php_pq_misc.h -+++ b/src/php_pq_misc.h -@@ -75,7 +75,7 @@ extern int php_pq_compare_index(Bucket *lptr, Bucket *rptr); - - extern int php_pq_compare_index(const void *lptr, const void *rptr); - --# define zend_ze_countable spl_ce_Countable -+# define zend_ce_countable spl_ce_Countable - - # define php_pq_call_method(objval_ptr, method_name, num_args, ...) \ - zend_call_method_with_ ## num_args ## _params( \ - -From 54542ca3e96ba72090f188692995047ae70d5d28 Mon Sep 17 00:00:00 2001 -From: Remi Collet <remi@remirepo.net> -Date: Fri, 11 Jun 2021 10:01:07 +0200 -Subject: [PATCH] fix prototype for 8.1 - ---- - src/php_pq_misc.c | 13 ++++++++++++- - 1 file changed, 12 insertions(+), 1 deletion(-) - -diff --git a/src/php_pq_misc.c b/src/php_pq_misc.c -index 3e334c6..9e622b4 100644 ---- a/src/php_pq_misc.c -+++ b/src/php_pq_misc.c -@@ -131,6 +131,13 @@ void php_pq_hash_ptr_dtor(zval *p) - - zend_class_entry *php_pqdt_class_entry; - -+#if PHP_VERSION_ID >= 80100 -+ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_TYPE_INFO_EX(ai_pqdt_jsonserialize, 0, 0, IS_MIXED, 0) -+#else -+#define ai_pqdt_jsonserialize ai_pqdt_to_string -+#endif -+ZEND_END_ARG_INFO() -+ - ZEND_BEGIN_ARG_INFO_EX(ai_pqdt_to_string, 0, 0, 0) - ZEND_END_ARG_INFO(); - static PHP_METHOD(pqdt, __toString) -@@ -142,7 +149,11 @@ static PHP_METHOD(pqdt, __toString) - RETVAL_ZVAL(&rv, 1, 1); - } - -+#if PHP_VERSION_ID >= 80100 -+ZEND_BEGIN_ARG_WITH_TENTATIVE_RETURN_OBJ_TYPE_MASK_EX(ai_pqdt_create_from_format, 0, 2, DateTime, MAY_BE_FALSE) -+#else - ZEND_BEGIN_ARG_INFO_EX(ai_pqdt_create_from_format, 0, 0, 2) -+#endif - ZEND_ARG_INFO(0, format) - ZEND_ARG_INFO(0, datetime) - #if PHP_VERSION_ID >= 70200 -@@ -171,7 +182,7 @@ static PHP_METHOD(pqdt, createFromFormat) - static zend_function_entry php_pqdt_methods[] = { - PHP_ME(pqdt, createFromFormat, ai_pqdt_create_from_format, ZEND_ACC_PUBLIC|ZEND_ACC_STATIC) - PHP_ME(pqdt, __toString, ai_pqdt_to_string, ZEND_ACC_PUBLIC) -- PHP_MALIAS(pqdt, jsonSerialize, __toString, ai_pqdt_to_string, ZEND_ACC_PUBLIC) -+ PHP_MALIAS(pqdt, jsonSerialize, __toString, ai_pqdt_jsonserialize, ZEND_ACC_PUBLIC) - {0} - }; - |