# Add PHP 7.4 branch to test against

**URL:** <https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179>\
**Category:** PHP\
**Created:** [February 7, 2019, 7:05pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179 "2019-02-07T19:05:40Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![BenMorel](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/benmorel/32/604_2.png) [@BenMorel](https://travis-ci.community/u/BenMorel)\
**Post date:** [February 7, 2019, 7:05pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/1 "2019-02-07T19:05:40Z")

</div>

PHP 7.4 [was branched 10 days ago](https://externals.io/message/103436#103861), and master is now PHP 8.0.0-dev.

This means that using `php: nightly` in my builds conflicts with phpunit which expects PHP 7:

> phpunit/phpunit 7.5.4 requires php ^7.1 -\> your PHP version (8.0.0-dev) does not satisfy that requirement.

And `php: 7.4` is not available yet:

> rbenv: version `7.4’ not installed

Could you please add the `php: 7.4` version, that would point to the [PHP-7.4](https://github.com/php/php-src/tree/PHP-7.4) branch?

Thank you.

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [February 7, 2019, 7:53pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/2 "2019-02-07T19:53:27Z")

</div>

There is no 7.4 release yet. So we will be building `7.4snapshot`, but currently it is breaking with apcu. [https://travis-ci.org/travis-ci/php-src-builder/jobs/489915434#L4847](https://travis-ci.org/travis-ci/php-src-builder/jobs/489915434#L4847)

---

<div class="post-metadata">

**Author:** ![BenMorel](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/benmorel/32/604_2.png) [@BenMorel](https://travis-ci.community/u/BenMorel)\
**Post date:** [February 8, 2019, 10:40am UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/3 "2019-02-08T10:40:19Z")

</div>

Thanks, I pinged krakjoe here:

> <https://github.com/krakjoe/apcu/issues/363>

---

<div class="post-metadata">

**Author:** ![nikic](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/nikic/32/963_2.png) [@nikic](https://travis-ci.community/u/nikic)\
**Post date:** [February 8, 2019, 11:30am UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/4 "2019-02-08T11:30:33Z")

</div>

A new apcu release with compatibility fixes for PHP 7.4 is out, so hopefully the next build will work.

---

<div class="post-metadata">

**Author:** ![nikic](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/nikic/32/963_2.png) [@nikic](https://travis-ci.community/u/nikic)\
**Post date:** [February 11, 2019, 9:11am UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/5 "2019-02-11T09:11:47Z")

</div>

The last PHP 7.4 snapshot build was successful ([https://travis-ci.org/travis-ci/php-src-builder/builds/491493967](https://travis-ci.org/travis-ci/php-src-builder/builds/491493967)) and I just checked that `7.4snapshot` does indeed work ([https://travis-ci.org/nikic/php-ast/jobs/491525179](https://travis-ci.org/nikic/php-ast/jobs/491525179)).

It would be great if `7.4` could be added as an alias for `7.4snapshot` until we have actual PHP 7.4 releases, as I think most people don’t know about the `snapshot` versions.

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [February 11, 2019, 1:32pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/6 "2019-02-11T13:32:49Z")

</div>

There is no 7.4 release of any kind, so it is misleading to offer snapshots with aliases that suggest an official release.

We can document `*snapshot`, but that’s as far as I suggest we go.

Note: We have aliased RCs as releases before. (e.g., [https://travis-ci.org/travis-ci/php-src-builder/builds/292953190](https://travis-ci.org/travis-ci/php-src-builder/builds/292953190))

---

<div class="post-metadata">

**Author:** ![Majkl578](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/majkl578/32/1135_2.png) [@Majkl578](https://travis-ci.community/u/Majkl578)\
**Post date:** [February 11, 2019, 4:29pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/7 "2019-02-11T16:29:06Z")

</div>

I agree aliasing it to 7.4 would be misleading. I would personally prefer “7.4-dev” but “7.4snapshot” works for me too.  
We have already switched from nightly to 7.4snapshot in Doctrine.

---

<div class="post-metadata">

**Author:** ![sminnee](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/sminnee/32/1365_2.png) [@sminnee](https://travis-ci.community/u/sminnee)\
**Post date:** [March 13, 2019, 1:11am UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/8 "2019-03-13T01:11:11Z")

</div>

I noticed that 7.4snapshot doesn’t seem to provide the GD2 extension. Is this an artefact of the way snapshots are built, so is it more likely to be a more common change for 7.4 (i.e. are they removing GD2 by default).

Is there a way of adding GD2 back in?

---

<div class="post-metadata">

**Author:** ![Majkl578](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/majkl578/32/1135_2.png) [@Majkl578](https://travis-ci.community/u/Majkl578)\
**Post date:** [March 14, 2019, 2:19am UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/9 "2019-03-14T02:19:44Z")

</div>

Yes, the build steps for GD have changed in PHP 7.4, see: [https://github.com/php/php-src/blob/9499484ed2f0377678b2b4d88573327ee0e4ce6d/UPGRADING#L394-L403](https://github.com/php/php-src/blob/9499484ed2f0377678b2b4d88573327ee0e4ce6d/UPGRADING#L394-L403)

---

<div class="post-metadata">

**Author:** ![sminnee](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/sminnee/32/1365_2.png) [@sminnee](https://travis-ci.community/u/sminnee)\
**Post date:** [March 28, 2019, 9:35pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/10 "2019-03-28T21:35:27Z")

</div>

The builds for 7.4snapshot are currently failing. It looks like the issue is that there are a lot of checks that are skipped for “master” that should probably be skipped for “7.4snapshot” as well:

[https://travis-ci.org/travis-ci/php-src-builder/jobs/512476201#L3005](https://travis-ci.org/travis-ci/php-src-builder/jobs/512476201#L3005)

> <https://github.com/travis-ci/php-src-builder/blob/default/bin/compile#L31>

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [April 4, 2019, 6:32pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/11 "2019-04-04T18:32:25Z")

</div>

7.4snapshot appears to be incompatible with the `go-pear.phar` we fetch.

[https://travis-ci.org/travis-ci/php-src-builder/jobs/515841765#L3000-L3006](https://travis-ci.org/travis-ci/php-src-builder/jobs/515841765#L3000-L3006)

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [April 8, 2019, 5:51pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/12 "2019-04-08T17:51:20Z")

</div>

I tracked the recent 7.4snapshot issue to

> <https://github.com/pear/pearweb_phars/issues/8>

and resolved it by pinning `go-pear.phar` to version 1.10.12 for the time being.

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [April 8, 2019, 6:29pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/13 "2019-04-08T18:29:00Z")

</div>

As with `nightly`, Oniguruma is necessary.

```auto
addons:
  apt:
    packages:
      - libonig-dev

```

[https://travis-ci.org/BanzaiMan/travis\_production\_test/builds/517402547#L205](https://travis-ci.org/BanzaiMan/travis_production_test/builds/517402547#L205)

---

<div class="post-metadata">

**Author:** ![nikic](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/nikic/32/963_2.png) [@nikic](https://travis-ci.community/u/nikic)\
**Post date:** [April 11, 2019, 8:56am UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/14 "2019-04-11T08:56:33Z")

</div>

I have opened [https://github.com/travis-ci/php-src-builder/pull/36](https://github.com/travis-ci/php-src-builder/pull/36) to link against oniguruma statically, which should remove the need to install libonig when using nightly and 7.4snapshot.

---

<div class="post-metadata">

**Author:** ![staabm](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/staabm/32/1659_2.png) [@staabm](https://travis-ci.community/u/staabm)\
**Post date:** [April 23, 2019, 2:51pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/15 "2019-04-23T14:51:36Z")

</div>

the gd extension is still missing from the 7.4snapshot build.

it was mentioned in this thread that the compile flags for gd changed, but it seems travis already is passing those new named ones

> [@Add PHP 7.4 branch to test against](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/9):
>
> Yes, the build steps for GD have changed in PHP 7.4, see: [https://github.com/php/php-src/blob/9499484ed2f0377678b2b4d88573327ee0e4ce6d/UPGRADING#L394-L403](https://github.com/php/php-src/blob/9499484ed2f0377678b2b4d88573327ee0e4ce6d/UPGRADING#L394-L403)

---

<div class="post-metadata">

**Author:** ![klausi](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/klausi/32/3316_2.png) [@klausi](https://travis-ci.community/u/klausi)\
**Post date:** [December 3, 2019, 11:05am UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/16 "2019-12-03T11:05:33Z")

</div>

“PHP 7.4” works now .travis.yml but the GD extensions is still missing, see for example [https://travis-ci.org/drupal-graphql/graphql/jobs/620057767?utm\_medium=notification&utm\_source=github\_status](https://travis-ci.org/drupal-graphql/graphql/jobs/620057767?utm_medium=notification&utm_source=github_status)

How can we enable that for PHP 7.4 testing?

---

<div class="post-metadata">

**Author:** ![BanzaiMan](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/banzaiman/32/67_2.png) [@BanzaiMan](https://travis-ci.community/u/BanzaiMan)\
**Post date:** [December 3, 2019, 1:09pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/17 "2019-12-03T13:09:43Z")

</div>

We need [https://github.com/php-build/php-build/](https://github.com/php-build/php-build/) to be 7.4-compatible, in the first place, but

> <https://github.com/php-build/php-build/pull/597#issuecomment-560386404>

  
suggests some difficulties.

I encourage you to look at that tool to move this issue forward.

---

<div class="post-metadata">

**Author:** ![ruudboon](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/ruudboon/32/3362_2.png) [@ruudboon](https://travis-ci.community/u/ruudboon)\
**Post date:** [December 10, 2019, 1:13pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/18 "2019-12-10T13:13:57Z")

</div>

Got merged.

---

<div class="post-metadata">

**Author:** ![ChristophWurst](https://avatars.discourse-cdn.com/v4/letter/c/b19c9b/32.png) [@ChristophWurst](https://travis-ci.community/u/ChristophWurst)\
**Post date:** [December 18, 2019, 10:02am UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/19 "2019-12-18T10:02:04Z")

</div>

Hi,

what’s the status here? We need GD as well and I naively tried to install it with pecl. But that fails miserably [https://travis-ci.com/nextcloud/mail/jobs/268449896#L1637](https://travis-ci.com/nextcloud/mail/jobs/268449896#L1637).

---

<div class="post-metadata">

**Author:** ![Schlaefer](https://sea1.discourse-cdn.com/flex015/user_avatar/travis-ci.community/schlaefer/32/3526_2.png) [@Schlaefer](https://travis-ci.community/u/Schlaefer)\
**Post date:** [December 30, 2019, 2:05pm UTC](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179/20 "2019-12-30T14:05:24Z")

</div>

I’m also running into the issue that the gd extension isn’t available for PHP 7.4. Any update on that?

[Next page](https://travis-ci.community/t/add-php-7-4-branch-to-test-against/2179.md?page=2)
