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
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 36fe55487a05
Choose a base ref
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 3bc76218a307
Choose a head ref
  • 2 commits
  • 1 file changed
  • 2 contributors

Commits on Oct 30, 2019

  1. R: Add static argument.

    R's autoconf does not use the normal configure flags for that.
    nh2 committed Oct 30, 2019
    Copy the full SHA
    edbe2d8 View commit details
  2. Merge pull request #72058 from nh2/r-static-library

    R: Add enableShared/enableStatic arguments
    peti authored Oct 30, 2019

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature.
    Copy the full SHA
    3bc7621 View commit details
Showing with 6 additions and 1 deletion.
  1. +6 −1 pkgs/applications/science/math/R/default.nix
7 changes: 6 additions & 1 deletion pkgs/applications/science/math/R/default.nix
Original file line number Diff line number Diff line change
@@ -4,6 +4,9 @@
, curl, Cocoa, Foundation, libobjc, libcxx, tzdata, fetchpatch
, withRecommendedPackages ? true
, enableStrictBarrier ? false
# R as of writing does not support outputting both .so and .a files; it outputs:
# --enable-R-static-lib conflicts with --enable-R-shlib and will be ignored
, static ? false
, javaSupport ? (!stdenv.hostPlatform.isAarch32 && !stdenv.hostPlatform.isAarch64)
}:

@@ -33,6 +36,8 @@ stdenv.mkDerivation rec {
substituteInPlace configure --replace "-install_name libR.dylib" "-install_name $out/lib/R/lib/libR.dylib"
'';

dontDisableStatic = static;

preConfigure = ''
configureFlagsArray=(
--disable-lto
@@ -47,7 +52,7 @@ stdenv.mkDerivation rec {
--with-libtiff
--with-ICU
${stdenv.lib.optionalString enableStrictBarrier "--enable-strict-barrier"}
--enable-R-shlib
${if static then "--enable-R-static-lib" else "--enable-R-shlib"}
AR=$(type -p ar)
AWK=$(type -p gawk)
CC=$(type -p cc)