Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
base: 3407b8c0fb25
Choose a base ref
...
head repository: NixOS/nixpkgs
compare: 27b9b7b3af72
Choose a head ref
  • 12 commits
  • 11 files changed
  • 2 contributors

Commits on Apr 24, 2020

  1. php.buildEnv: Make the exported php package overridable

    This implements the override pattern for builds done with buildEnv, so
    that we can, for example, write
    
    php.override { fpmSupport = false; }
    
    and get a PHP package with the default extensions enabled, but PHP
    compiled without fpm support.
    talyz committed Apr 24, 2020
    Copy the full SHA
    a463261 View commit details
    Browse the repository at this point in the history
  2. php: Make all arguments to a PHP build overridable

    Make all arguments to a PHP build overridable; i.e, both configuration
    flags, such as valgrindSupport, and packages, such as valgrind:
    
    php.override { valgrindSupport = false; valgrind = valgrind-light; }
    
    This applies to packages built by generic and buildEnv/withExtensions;
    i.e, it works with both phpXX and phpXXBase packages.
    
    The following changes were also made to facilitate this:
    
     - generic and generic' are merged into one function
    
     - generic now takes all required arguments for a complete build and
       is meant to be called by callPackage
    
     - The main function called from all-packages.nix no longer takes all
       required arguments for a complete build - all arguments passed to it
       are however forwarded to the individual builds, thus default
       arguments can still be overridden from all-packages.nix
    talyz committed Apr 24, 2020
    Copy the full SHA
    dde5f5f View commit details
    Browse the repository at this point in the history
  3. php.buildEnv: Respect override

    Make buildEnv take earlier overridden values into account by
    forwarding all arguments (a merge of generic's arguments, all previous
    arguments and the current arguments) to the next invocation of
    buildEnv.
    talyz committed Apr 24, 2020
    Copy the full SHA
    abedfad View commit details
    Browse the repository at this point in the history

Commits on Apr 26, 2020

  1. php.buildEnv: Provide a list of currently enabled extensions

    Rework withExtensions / buildEnv to handle currently enabled
    extensions better and make them compatible with override. They now
    accept a function with the named arguments enabled and all, where
    enabled is a list of currently enabled extensions and all is the set
    of all extensions. This gives us several nice properties:
    
     - You always get the right version of the list of currently enabled
       extensions
    
     - Invocations chain
    
     - It works well with overridden PHP packages - you always get the
       correct versions of extensions
    
    As a contrived example of what's possible, you can add ImageMagick,
    then override the version and disable fpm, then disable cgi, and
    lastly remove the zip extension like this:
    
    { pkgs ? (import <nixpkgs>) {} }:
    with pkgs;
    
    let
      phpWithImagick = php74.withExtensions ({ all, enabled }: enabled ++ [ all.imagick ]);
    
      phpWithImagickWithoutFpm743 = phpWithImagick.override {
        version = "7.4.3";
        sha256 = "wVF7pJV4+y3MZMc6Ptx21PxQfEp6xjmYFYTMfTtMbRQ=";
        fpmSupport = false;
      };
    
      phpWithImagickWithoutFpmZip743 = phpWithImagickWithoutFpm743.withExtensions (
        { enabled, all }:
          lib.filter (e: e != all.zip) enabled);
    
      phpWithImagickWithoutFpmZipCgi743 = phpWithImagickWithoutFpmZip743.override {
        cgiSupport = false;
      };
    in
      phpWithImagickWithoutFpmZipCgi743
    talyz committed Apr 26, 2020
    Copy the full SHA
    2ba7926 View commit details
    Browse the repository at this point in the history
  2. php: Get rid of all config.php parameters

    Since all options controlled by the config.php parameters can now be
    overridden directly, there's no reason to keep them around.
    talyz committed Apr 26, 2020
    Copy the full SHA
    72636bc View commit details
    Browse the repository at this point in the history
  3. php.buildEnv: Automatically include extension dependencies

    Some extensions depend on other extensions. Previously, these had to
    be added manually to the list of included extensions, or we got a
    cryptic error message pointing to strings-with-deps.nix, which wasn't
    very helpful. This makes sure all required extensions are included in
    the set from which textClosureList chooses its snippets.
    talyz committed Apr 26, 2020
    Copy the full SHA
    d610407 View commit details
    Browse the repository at this point in the history

Commits on Apr 29, 2020

  1. Copy the full SHA
    c3d5d92 View commit details
    Browse the repository at this point in the history
  2. php.buildEnv: Provide the unwrapped php package in php.unwrapped

    This is useful if you need to access the dev output of the unwrapped
    derivation.
    talyz committed Apr 29, 2020
    Copy the full SHA
    ef99096 View commit details
    Browse the repository at this point in the history
  3. php: Add passthru.tests

    talyz committed Apr 29, 2020
    Copy the full SHA
    3bfd4e8 View commit details
    Browse the repository at this point in the history
  4. php: Get rid of the phpXXbase attributes, update docs

    Since the introduction of php.unwrapped there's no real need for the
    phpXXbase attributes, so let's remove them to lessen potential
    confusion and clutter. Also update the docs to make it clear how to
    get hold of an unwrapped PHP if needed.
    talyz committed Apr 29, 2020
    Copy the full SHA
    5cad1b4 View commit details
    Browse the repository at this point in the history
  5. php: Unify the usage of the php package in php-packages.nix

    Instead of using two different php packages in php-packages.nix, one
    wrapper and one unwrapped, simply use the wrapper and use its
    "unwrapped" attribute when necessary. Also, get rid of the packages
    and extensions attributes from the base package, since they're no
    longer needed.
    talyz committed Apr 29, 2020
    Copy the full SHA
    2535cdf View commit details
    Browse the repository at this point in the history
  6. Merge pull request #85026 from talyz/php_buildenv_override

    php.buildEnv: Make the exported php package overridable, improve handling of currently enabled extensions, etc
    etu committed Apr 29, 2020
    Copy the full SHA
    27b9b7b View commit details
    Browse the repository at this point in the history