anchor.diff:          buildInputs = [ libxml2 ];
           configureFlags = [ "--enable-dom" ]
             # Required to build on darwin.
  -          ++ lib.optional (lib.versionOlder php.version "7.4") [ "--with-libxml-dir=${libxml2.dev}" ]; }
  +          ++ lib.optionals (lib.versionOlder php.version "7.4") [ "--with-libxml-dir=${libxml2.dev}" ]; }
         { name = "enchant";
           buildInputs = [ enchant1 ];
           configureFlags = [ "--with-enchant=${enchant1}" ];
  
positive.code:       # interbase (7.3, 7.2)
        { name = "intl";
          buildInputs = [ icu64 ];
          patches = lib.optional (lib.versionOlder php.version "7.4") (fetchpatch {
            url = "https://github.com/php/php-src/commit/93a9b56c90c334896e977721bfb3f38b1721cec6.patch";
            sha256 = "055l40lpyhb0rbjn6y23qkzdhvpp7inbnn6x13cpn4inmhjqfpg4";
          });
        }
        { name = "json"; enable = lib.versionOlder php.version "8.0"; }
        { name = "ldap";
  
negative.code:         buildInputs = [ libxml2 ];
          configureFlags = [ "--enable-xml" ]
            # Required to build on darwin.
            ++ lib.optionals (lib.versionOlder php.version "7.4") [ "--with-libxml-dir=${libxml2.dev}" ];
          doCheck = false; }
        { name = "xmlreader";
          buildInputs = [ libxml2 ];
  