1 /* This file defines the composition for R packages. */
4 importJSON = f: builtins.fromJSON (builtins.readFile f);
6 biocPackagesGenerated = importJSON ./bioc-packages.json;
7 biocAnnotationPackagesGenerated = importJSON ./bioc-annotation-packages.json;
8 biocExperimentPackagesGenerated = importJSON ./bioc-experiment-packages.json;
9 cranPackagesGenerated = importJSON ./cran-packages.json;
12 { R, pkgs, overrides }:
15 inherit (pkgs) cacert fetchurl stdenv lib;
17 buildRPackage = pkgs.callPackage ./generic-builder.nix {
19 inherit (pkgs.darwin.apple_sdk.frameworks) Cocoa Foundation;
20 inherit (pkgs) gettext gfortran;
23 # Generates package templates given per-repository settings
25 # some packages, e.g. cncaGUI, require X running while installation,
26 # so that we use xvfb-run if requireX is true.
27 mkDerive = {mkHomepage, mkUrls, hydraPlatforms ? null}: args:
28 let hydraPlatforms' = hydraPlatforms; in
29 lib.makeOverridable ({
30 name, version, sha256,
35 platforms ? R.meta.platforms,
36 hydraPlatforms ? if hydraPlatforms' != null then hydraPlatforms' else platforms,
39 name = "${name}-${version}";
42 urls = mkUrls (args // { inherit name version; });
44 inherit doCheck requireX;
45 propagatedBuildInputs = depends;
46 nativeBuildInputs = depends;
47 meta.homepage = mkHomepage (args // { inherit name; });
48 meta.platforms = platforms;
49 meta.hydraPlatforms = hydraPlatforms;
51 meta.maintainers = maintainers;
54 # Templates for generating Bioconductor and CRAN packages
55 # from the name, version, sha256, and optional per-package arguments above
57 deriveBioc = mkDerive {
58 mkHomepage = {name, biocVersion}: "https://bioconductor.org/packages/${biocVersion}/bioc/html/${name}.html";
59 mkUrls = {name, version, biocVersion}: [
60 "mirror://bioc/${biocVersion}/bioc/src/contrib/${name}_${version}.tar.gz"
61 "mirror://bioc/${biocVersion}/bioc/src/contrib/Archive/${name}/${name}_${version}.tar.gz"
62 "mirror://bioc/${biocVersion}/bioc/src/contrib/Archive/${name}_${version}.tar.gz"
65 deriveBiocAnn = mkDerive {
66 mkHomepage = {name, ...}: "http://www.bioconductor.org/packages/${name}.html";
67 mkUrls = {name, version, biocVersion}: [
68 "mirror://bioc/${biocVersion}/data/annotation/src/contrib/${name}_${version}.tar.gz"
72 deriveBiocExp = mkDerive {
73 mkHomepage = {name, ...}: "http://www.bioconductor.org/packages/${name}.html";
74 mkUrls = {name, version, biocVersion}: [
75 "mirror://bioc/${biocVersion}/data/experiment/src/contrib/${name}_${version}.tar.gz"
79 deriveCran = mkDerive {
80 mkHomepage = {name}: "https://cran.r-project.org/web/packages/${name}/";
81 mkUrls = {name, version}: [
82 "mirror://cran/${name}_${version}.tar.gz"
83 "mirror://cran/Archive/${name}/${name}_${version}.tar.gz"
87 # Overrides package definitions with nativeBuildInputs.
90 # overrideNativeBuildInputs {
97 # foo = old.foo.overrideAttrs (attrs: {
98 # nativeBuildInputs = attrs.nativeBuildInputs ++ [ pkgs.bar ];
101 overrideNativeBuildInputs = overrides: old:
102 lib.mapAttrs (name: value:
103 (builtins.getAttr name old).overrideAttrs (attrs: {
104 nativeBuildInputs = attrs.nativeBuildInputs ++ value;
108 # Overrides package definitions with buildInputs.
111 # overrideBuildInputs {
118 # foo = old.foo.overrideAttrs (attrs: {
119 # buildInputs = attrs.buildInputs ++ [ pkgs.bar ];
122 overrideBuildInputs = overrides: old:
123 lib.mapAttrs (name: value:
124 (builtins.getAttr name old).overrideAttrs (attrs: {
125 buildInputs = attrs.buildInputs ++ value;
129 # Overrides package definitions with maintainers.
132 # overrideMaintainers {
133 # foo = [ lib.maintainers.jsmith ]
139 # foo = old.foo.override {
140 # maintainers = [ lib.maintainers.jsmith ];
143 overrideMaintainers = overrides: old:
144 lib.mapAttrs (name: value:
145 (builtins.getAttr name old).override {
149 # Overrides package definitions with new R dependencies.
159 # foo = old.foo.overrideAttrs (attrs: {
160 # nativeBuildInputs = attrs.nativeBuildInputs ++ [ self.bar ];
161 # propagatedNativeBuildInputs = attrs.propagatedNativeBuildInputs ++ [ self.bar ];
164 overrideRDepends = overrides: old:
165 lib.mapAttrs (name: value:
166 (builtins.getAttr name old).overrideAttrs (attrs: {
167 nativeBuildInputs = (attrs.nativeBuildInputs or []) ++ value;
168 propagatedNativeBuildInputs = (attrs.propagatedNativeBuildInputs or []) ++ value;
172 # Overrides package definition requiring X running to install.
182 # foo = old.foo.override {
186 overrideRequireX = packageNames: old:
188 nameValuePairs = map (name: {
190 value = (builtins.getAttr name old).override {
195 builtins.listToAttrs nameValuePairs;
197 # Overrides package definition requiring a home directory to install or to
201 # overrideRequireHome [
208 # foo = old.foo.overrideAttrs (oldAttrs: {
210 # ${oldAttrs.preInstall or ""}
211 # export HOME=$(mktemp -d)
215 overrideRequireHome = packageNames: old:
217 nameValuePairs = map (name: {
219 value = (builtins.getAttr name old).overrideAttrs (oldAttrs: {
221 ${oldAttrs.preInstall or ""}
222 export HOME=$(mktemp -d)
227 builtins.listToAttrs nameValuePairs;
229 # Overrides package definition to skip check.
232 # overrideSkipCheck [
239 # foo = old.foo.override {
243 overrideSkipCheck = packageNames: old:
245 nameValuePairs = map (name: {
247 value = (builtins.getAttr name old).override {
252 builtins.listToAttrs nameValuePairs;
254 # Overrides package definition to mark it broken.
264 # foo = old.foo.override {
268 overrideBroken = packageNames: old:
270 nameValuePairs = map (name: {
272 value = (builtins.getAttr name old).override {
277 builtins.listToAttrs nameValuePairs;
279 defaultOverrides = old: new:
282 old1 = old0 // (overrideRequireX packagesRequiringX old0);
283 old2 = old1 // (overrideRequireHome packagesRequiringHome old1);
284 old3 = old2 // (overrideSkipCheck packagesToSkipCheck old2);
285 old4 = old3 // (overrideRDepends packagesWithRDepends old3);
286 old5 = old4 // (overrideNativeBuildInputs packagesWithNativeBuildInputs old4);
287 old6 = old5 // (overrideBuildInputs packagesWithBuildInputs old5);
288 old7 = old6 // (overrideBroken brokenPackages old6);
289 old8 = old7 // (overrideMaintainers packagesWithMaintainers old7);
291 in old // (otherOverrides old new);
293 # Recursive override pattern.
294 # `_self` is a collection of packages;
295 # `self` is `_self` with overridden packages;
296 # packages in `_self` may depends on overridden packages.
297 self = (defaultOverrides _self self) // overrides;
298 _self = { inherit buildRPackage; } //
299 mkPackageSet deriveBioc biocPackagesGenerated //
300 mkPackageSet deriveBiocAnn biocAnnotationPackagesGenerated //
301 mkPackageSet deriveBiocExp biocExperimentPackagesGenerated //
302 mkPackageSet deriveCran cranPackagesGenerated;
304 # Takes in a generated JSON file's imported contents
305 # and transforms it by swapping each element of the depends array with the dependency's derivation
306 # and passing this new object to the provided derive function
307 mkPackageSet = derive: packagesJSON: lib.mapAttrs (
308 k: v: derive packagesJSON.extraArgs (v // { depends = lib.map (name: builtins.getAttr name self) v.depends; })
309 ) packagesJSON.packages;
312 # tweaks for the individual packages and "in self" follow
314 packagesWithMaintainers = with lib.maintainers; {
315 data_table = [ jbedo ];
316 BiocManager = [ jbedo ];
319 svaRetro = [ jbedo ];
320 StructuralVariantAnnotation = [ jbedo ];
321 RQuantLib = [ kupac ];
324 packagesWithRDepends = {
325 spectralGraphTopology = [ self.CVXR ];
326 FactoMineR = [ self.car ];
327 pander = [ self.codetools ];
328 rmsb = [ self.rstantools ];
329 gastempt = [ self.rstantools ];
330 interactiveDisplay = [ self.BiocManager ];
331 disbayes = [ self.rstantools ];
332 tipsae = [ self.rstantools ];
333 TriDimRegression = [ self.rstantools ];
334 bbmix = [ self.rstantools ];
337 packagesWithNativeBuildInputs = {
338 adbcpostgresql = [ pkgs.postgresql ];
339 adimpro = [ pkgs.imagemagick ];
340 animation = [ pkgs.which ];
341 Apollonius = with pkgs; [ pkg-config gmp.dev mpfr.dev ];
342 arrow = with pkgs; [ pkg-config cmake ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ intltool ];
343 audio = [ pkgs.portaudio ];
344 BayesSAE = [ pkgs.gsl ];
345 BayesVarSel = [ pkgs.gsl ];
346 BayesXsrc = with pkgs; [ readline.dev ncurses gsl ];
347 bioacoustics = [ pkgs.fftw.dev pkgs.cmake ];
348 bigGP = [ pkgs.mpi ];
349 bigrquerystorage = with pkgs; [ grpc protobuf which ];
350 bio3d = [ pkgs.zlib ];
351 BiocCheck = [ pkgs.which ];
352 Biostrings = [ pkgs.zlib ];
353 CellBarcode = [ pkgs.zlib ];
354 cld3 = [ pkgs.protobuf ];
355 bnpmr = [ pkgs.gsl ];
356 caviarpd = [ pkgs.cargo ];
357 cairoDevice = [ pkgs.gtk2.dev ];
358 Cairo = with pkgs; [ libtiff libjpeg cairo.dev xorg.libXt.dev fontconfig.lib ];
359 Cardinal = [ pkgs.which ];
360 chebpol = [ pkgs.fftw.dev ];
361 ChemmineOB = [ pkgs.pkg-config ];
362 interpolation = [ pkgs.pkg-config ];
363 clarabel = [ pkgs.cargo ];
364 curl = [ pkgs.curl.dev ];
365 CytoML = [ pkgs.libxml2.dev ];
366 data_table = with pkgs; [ pkg-config zlib.dev ] ++ lib.optional stdenv.hostPlatform.isDarwin pkgs.llvmPackages.openmp;
367 devEMF = with pkgs; [ xorg.libXft.dev ];
368 diversitree = with pkgs; [ gsl fftw ];
369 exactextractr = [ pkgs.geos ];
370 EMCluster = [ pkgs.lapack ];
371 fangs = [ pkgs.cargo ];
372 fcl = [ pkgs.cargo ];
373 fftw = [ pkgs.fftw.dev ];
374 fftwtools = with pkgs; [ fftw.dev pkg-config ];
375 fingerPro = [ pkgs.gsl ];
376 Formula = [ pkgs.gmp ];
377 frailtyMMpen = [ pkgs.gsl ];
378 gamstransfer = [ pkgs.zlib ];
379 gdalraster = [ pkgs.pkg-config ];
380 gdtools = with pkgs; [ cairo.dev fontconfig.lib freetype.dev ];
381 GeneralizedWendland = [ pkgs.gsl ];
382 ggiraph = with pkgs; [ pkgs.libpng.dev ];
383 git2r = with pkgs; [ zlib.dev openssl.dev libssh2.dev libgit2 pkg-config ];
385 glpkAPI = with pkgs; [ gmp glpk ];
386 gmp = [ pkgs.gmp.dev ];
387 GPBayes = [ pkgs.gsl ];
388 graphscan = [ pkgs.gsl ];
390 gslnls = [ pkgs.gsl ];
391 gert = [ pkgs.libgit2 ];
392 haven = with pkgs; [ zlib.dev ];
393 hellorust = [ pkgs.cargo ];
394 hgwrr = [ pkgs.gsl ];
395 h5vc = with pkgs; [ zlib.dev bzip2.dev xz.dev ];
396 yyjsonr = with pkgs; [ zlib.dev ];
397 RNifti = with pkgs; [ zlib.dev ];
398 RNiftyReg = with pkgs; [ zlib.dev ];
399 highs = [ pkgs.which pkgs.cmake ];
400 crc32c = [ pkgs.which pkgs.cmake ];
401 rbedrock = [ pkgs.zlib.dev pkgs.which pkgs.cmake ];
402 HiCseg = [ pkgs.gsl ];
403 imager = [ pkgs.xorg.libX11.dev ];
404 imbibe = [ pkgs.zlib.dev ];
405 image_CannyEdges = with pkgs; [ fftw.dev libpng.dev ];
407 jack = [ pkgs.pkg-config ];
408 JavaGD = [ pkgs.jdk ];
409 jpeg = [ pkgs.libjpeg.dev ];
410 jqr = [ pkgs.jq.dev ];
411 KFKSDS = [ pkgs.gsl ];
412 KSgeneral = with pkgs; [ pkg-config ];
413 kza = [ pkgs.fftw.dev ];
414 leidenAlg = [ pkgs.gmp.dev ];
415 Libra = [ pkgs.gsl ];
416 libstable4u = [ pkgs.gsl ];
417 heck = [ pkgs.cargo ];
418 LOMAR = [ pkgs.gmp.dev ];
419 littler = [ pkgs.libdeflate ];
420 lpsymphony = with pkgs; [ pkg-config gfortran gettext ];
421 lwgeom = with pkgs; [ proj geos gdal ];
422 rsbml = [ pkgs.pkg-config ];
423 rvg = [ pkgs.libpng.dev ];
424 MAGEE = [ pkgs.zlib.dev pkgs.bzip2.dev ];
425 magick = [ pkgs.imagemagick.dev ];
426 ModelMetrics = lib.optional stdenv.hostPlatform.isDarwin pkgs.llvmPackages.openmp;
427 mvabund = [ pkgs.gsl ];
428 mwaved = [ pkgs.fftw.dev ];
429 mzR = with pkgs; [ zlib netcdf ];
430 nanonext = with pkgs; [ mbedtls nng ];
431 ncdf4 = [ pkgs.netcdf ];
432 neojags = [ pkgs.jags ];
433 nloptr = with pkgs; [ nlopt pkg-config ];
434 n1qn1 = [ pkgs.gfortran ];
435 odbc = [ pkgs.unixODBC ];
436 opencv = [ pkgs.pkg-config ];
437 pak = [ pkgs.curl.dev ];
438 pander = with pkgs; [ pandoc which ];
439 pbdMPI = [ pkgs.mpi ];
440 pbdPROF = [ pkgs.mpi ];
441 pbdZMQ = [ pkgs.pkg-config ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ pkgs.which ];
442 pcaL1 = [ pkgs.pkg-config pkgs.clp ];
443 pdftools = [ pkgs.poppler.dev ];
444 PEPBVS = [ pkgs.gsl ];
445 phytools = [ pkgs.which ];
446 PKI = [ pkgs.openssl.dev ];
447 png = [ pkgs.libpng.dev ];
448 protolite = [ pkgs.protobuf ];
449 R2SWF = with pkgs; [ zlib libpng freetype.dev ];
450 RAppArmor = [ pkgs.libapparmor ];
451 rapportools = [ pkgs.which ];
452 rapport = [ pkgs.which ];
453 rcdd = [ pkgs.gmp.dev ];
454 RcppCNPy = [ pkgs.zlib.dev ];
455 RcppGSL = [ pkgs.gsl ];
456 RcppZiggurat = [ pkgs.gsl ];
457 reprex = [ pkgs.which ];
458 rgdal = with pkgs; [ proj.dev gdal ];
459 Rhisat2 = [ pkgs.which pkgs.hostname ];
460 gdalcubes = [ pkgs.pkg-config ];
461 rgeos = [ pkgs.geos ];
462 Rglpk = [ pkgs.glpk ];
463 RGtk2 = [ pkgs.gtk2.dev ];
464 rhdf5 = [ pkgs.zlib ];
465 Rhdf5lib = with pkgs; [ zlib.dev ];
466 Rhpc = with pkgs; [ zlib bzip2.dev icu xz.dev mpi pcre.dev ];
467 Rhtslib = with pkgs; [ zlib.dev automake autoconf bzip2.dev xz.dev curl.dev ];
468 rjags = [ pkgs.jags ];
469 rJava = with pkgs; [ zlib bzip2.dev icu xz.dev pcre.dev jdk libzip libdeflate ];
470 Rlibeemd = [ pkgs.gsl ];
471 rmatio = [ pkgs.zlib.dev pkgs.pkg-config ];
472 Rmpfr = with pkgs; [ gmp mpfr.dev ];
474 RMySQL = with pkgs; [ zlib libmysqlclient openssl.dev ];
475 RNetCDF = with pkgs; [ netcdf udunits ];
476 RODBC = [ pkgs.libiodbc ];
477 rpanel = [ pkgs.tclPackages.bwidget ];
478 Rpoppler = [ pkgs.poppler ];
479 RPostgres = with pkgs; [ postgresql ];
480 RPostgreSQL = with pkgs; [ postgresql postgresql ];
481 RProtoBuf = [ pkgs.protobuf ];
482 RSclient = [ pkgs.openssl.dev ];
483 Rserve = [ pkgs.openssl ];
484 Rssa = [ pkgs.fftw.dev ];
485 rsvg = [ pkgs.pkg-config ];
486 runjags = [ pkgs.jags ];
487 xslt = [ pkgs.pkg-config ];
488 RVowpalWabbit = with pkgs; [ zlib.dev boost ];
489 rzmq = with pkgs; [ zeromq pkg-config ];
490 httpuv = [ pkgs.zlib.dev ];
491 clustermq = [ pkgs.zeromq ];
492 SAVE = with pkgs; [ zlib bzip2 icu xz pcre ];
493 salso = [ pkgs.cargo ];
494 ymd = [ pkgs.cargo ];
495 arcpbf = [ pkgs.cargo ];
496 sdcTable = with pkgs; [ gmp glpk ];
497 seewave = with pkgs; [ fftw.dev libsndfile.dev ];
498 seqinr = [ pkgs.zlib.dev ];
499 smcryptoR = with pkgs; [ cargo rustc which ];
500 webp = [ pkgs.pkg-config ];
501 seqminer = with pkgs; [ zlib.dev bzip2 ];
502 sf = with pkgs; [ gdal proj geos libtiff curl ];
503 strawr = with pkgs; [ curl.dev ];
504 string2path = [ pkgs.cargo ];
505 terra = with pkgs; [ gdal proj geos ];
506 tok = [ pkgs.cargo ];
507 rshift = [ pkgs.cargo ];
508 arcgisutils = with pkgs; [ cargo rustc ];
509 arcgisgeocode = with pkgs; [ cargo rustc ];
510 arcgisplaces = with pkgs; [ pkg-config openssl.dev cargo rustc ];
511 apcf = with pkgs; [ geos ];
512 SemiCompRisks = [ pkgs.gsl ];
513 showtext = with pkgs; [ zlib libpng icu freetype.dev ];
514 simplexreg = [ pkgs.gsl ];
515 spate = [ pkgs.fftw.dev ];
516 ssanv = [ pkgs.proj ];
518 stringi = [ pkgs.icu.dev ];
519 survSNP = [ pkgs.gsl ];
520 svglite = [ pkgs.libpng.dev ];
521 sysfonts = with pkgs; [ zlib libpng freetype.dev ];
522 systemfonts = with pkgs; [ fontconfig.dev freetype.dev ];
523 TAQMNGR = [ pkgs.zlib.dev ];
525 tesseract = with pkgs; [ tesseract leptonica ];
526 tiff = [ pkgs.libtiff.dev ];
527 tkrplot = with pkgs; [ xorg.libX11 tk.dev ];
528 topicmodels = [ pkgs.gsl ];
529 udunits2 = with pkgs; [ udunits expat ];
530 units = [ pkgs.udunits ];
531 unigd = [ pkgs.pkg-config ];
532 vdiffr = [ pkgs.libpng.dev ];
533 V8 = [ pkgs.nodejs.libv8 ];
534 XBRL = with pkgs; [ zlib libxml2.dev ];
535 XLConnect = [ pkgs.jdk ];
536 xml2 = [ pkgs.libxml2.dev ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ pkgs.perl ];
537 XML = with pkgs; [ libtool libxml2.dev xmlsec libxslt ];
538 affyPLM = [ pkgs.zlib.dev ];
539 BitSeq = [ pkgs.zlib.dev ];
540 DiffBind = with pkgs; [ zlib.dev xz.dev bzip2.dev ];
541 ShortRead = [ pkgs.zlib.dev ];
542 oligo = [ pkgs.zlib.dev ];
543 gmapR = [ pkgs.zlib.dev ];
544 Rsubread = [ pkgs.zlib.dev ];
545 XVector = [ pkgs.zlib.dev ];
546 Rsamtools = with pkgs; [ zlib.dev curl.dev bzip2 xz ];
547 rtracklayer = with pkgs; [ zlib.dev curl.dev ];
548 affyio = [ pkgs.zlib.dev ];
549 snpStats = [ pkgs.zlib.dev ];
550 vcfppR = [ pkgs.curl.dev pkgs.bzip2 pkgs.zlib.dev pkgs.xz];
551 httpgd = with pkgs; [ cairo.dev ];
552 SymTS = [ pkgs.gsl ];
553 VBLPCM = [ pkgs.gsl ];
555 mixlink = [ pkgs.gsl ];
556 ridge = [ pkgs.gsl ];
558 rnetcarto = [ pkgs.gsl ];
559 rGEDI = [ pkgs.gsl ];
560 mmpca = [ pkgs.gsl ];
561 monoreg = [ pkgs.gsl ];
563 mixture = [ pkgs.gsl ];
565 immunoClust = [ pkgs.gsl ];
567 flowPeaks = [ pkgs.gsl ];
570 diseq = [ pkgs.gsl ];
573 SimInf = [ pkgs.gsl ];
574 RJMCMCNucleosomes = [ pkgs.gsl ];
575 RDieHarder = [ pkgs.gsl ];
578 RationalMatrix = [ pkgs.pkg-config pkgs.gmp.dev];
579 RcppCWB = [ pkgs.pkg-config pkgs.pcre2 ];
580 redux = [ pkgs.pkg-config ];
581 rswipl = with pkgs; [ cmake pkg-config ];
582 rrd = [ pkgs.pkg-config ];
583 surveyvoi = [ pkgs.pkg-config ];
584 Rbwa = [ pkgs.zlib.dev ];
585 trackViewer = [ pkgs.zlib.dev ];
586 themetagenomics = [ pkgs.zlib.dev ];
587 Rsymphony = [ pkgs.pkg-config ];
588 NanoMethViz = [ pkgs.zlib.dev ];
589 RcppMeCab = [ pkgs.pkg-config ];
590 HilbertVisGUI = with pkgs; [ pkg-config which ];
591 textshaping = [ pkgs.pkg-config ];
592 ragg = [ pkgs.pkg-config ];
593 qqconf = [ pkgs.pkg-config ];
594 qspray = [ pkgs.pkg-config ];
595 ratioOfQsprays = [ pkgs.pkg-config ];
596 symbolicQspray = [ pkgs.pkg-config ];
597 sphereTessellation = [ pkgs.pkg-config ];
598 vapour = [ pkgs.pkg-config ];
601 packagesWithBuildInputs = {
603 asciicast = with pkgs; [ xz.dev bzip2.dev zlib.dev icu.dev libdeflate ];
604 island = [ pkgs.gsl.dev ];
605 svKomodo = [ pkgs.which ];
606 ulid = [ pkgs.zlib.dev ];
607 unrtf = with pkgs; [ xz.dev bzip2.dev zlib.dev icu.dev libdeflate ];
608 nat = [ pkgs.which ];
609 nat_templatebrains = [ pkgs.which ];
610 pbdZMQ = [ pkgs.zeromq ] ++ lib.optionals stdenv.hostPlatform.isDarwin [ pkgs.darwin.binutils ];
611 bigmemory = lib.optionals stdenv.hostPlatform.isLinux [ pkgs.libuuid.dev ];
612 bayesWatch = [ pkgs.boost.dev ];
613 clustermq = [ pkgs.pkg-config ];
614 coga = [ pkgs.gsl.dev ];
615 mBvs = [ pkgs.gsl.dev ];
616 rcontroll = [ pkgs.gsl.dev ];
617 deepSNV = with pkgs; [ xz.dev bzip2.dev zlib.dev ];
618 epialleleR = with pkgs; [ xz.dev bzip2.dev zlib.dev ];
619 gdalraster = with pkgs; [ gdal proj.dev sqlite.dev ];
620 mitoClone2 = with pkgs; [ xz.dev bzip2.dev zlib.dev ];
621 gpg = [ pkgs.gpgme ];
622 webp = [ pkgs.libwebp ];
623 RMark = [ pkgs.which ];
624 RPushbullet = [ pkgs.which ];
625 stpphawkes = [ pkgs.gsl ];
626 registr = with pkgs; [ icu.dev zlib.dev bzip2.dev xz.dev libdeflate ];
627 RCurl = [ pkgs.curl.dev ];
628 R2SWF = [ pkgs.pkg-config ];
629 rDEA = [ pkgs.glpk ];
630 rgl = with pkgs; [ libGLU libGL xorg.libX11.dev freetype.dev libpng.dev ];
631 RGtk2 = [ pkgs.pkg-config ];
632 RProtoBuf = [ pkgs.pkg-config ];
633 Rpoppler = [ pkgs.pkg-config ];
634 XML = [ pkgs.pkg-config ];
635 apsimx = [ pkgs.which ];
636 cairoDevice = [ pkgs.pkg-config ];
637 chebpol = [ pkgs.pkg-config ];
638 eds = [ pkgs.zlib.dev ];
639 pgenlibr = [ pkgs.zlib.dev ];
640 fftw = [ pkgs.pkg-config ];
641 gdtools = [ pkgs.pkg-config ];
642 archive = [ pkgs.libarchive];
643 gdalcubes = with pkgs; [ proj.dev gdal sqlite.dev netcdf ];
644 rsbml = [ pkgs.libsbml ];
645 SuperGauss = [ pkgs.pkg-config pkgs.fftw.dev];
646 specklestar = [ pkgs.fftw.dev ];
647 cartogramR = [ pkgs.fftw.dev ];
648 jqr = [ pkgs.jq.out ];
649 kza = [ pkgs.pkg-config ];
650 igraph = with pkgs; [ gmp libxml2.dev glpk ];
651 interpolation = [ pkgs.gmp ];
652 image_textlinedetector = with pkgs; [ pkg-config opencv ];
653 lwgeom = with pkgs; [ pkg-config proj.dev sqlite.dev ];
654 magick = [ pkgs.pkg-config ];
655 mwaved = [ pkgs.pkg-config ];
656 odbc = [ pkgs.pkg-config ];
657 openssl = [ pkgs.pkg-config ];
658 pdftools = [ pkgs.pkg-config ];
659 qckitfastq = [ pkgs.zlib.dev ];
660 raer = with pkgs; [ zlib.dev xz.dev bzip2.dev ];
661 RQuantLib = with pkgs; [ quantlib.dev boost.dev ];
662 sf = with pkgs; [ pkg-config sqlite.dev proj.dev ];
663 terra = with pkgs; [ pkg-config sqlite.dev proj.dev ];
664 showtext = [ pkgs.pkg-config ];
665 spate = [ pkgs.pkg-config ];
666 stringi = [ pkgs.pkg-config ];
667 sysfonts = [ pkgs.pkg-config ];
668 systemfonts = [ pkgs.pkg-config ];
669 tesseract = [ pkgs.pkg-config ];
670 Cairo = [ pkgs.pkg-config ];
671 CLVTools = [ pkgs.gsl ];
672 excursions = [ pkgs.gsl ];
673 gpuMagic = [ pkgs.ocl-icd ];
674 JMcmprsk = [ pkgs.gsl ];
675 KSgeneral = [ pkgs.fftw.dev ];
676 mashr = [ pkgs.gsl ];
677 hadron = [ pkgs.gsl ];
678 AMOUNTAIN = [ pkgs.gsl ];
679 Rsymphony = with pkgs; [ symphony doxygen graphviz subversion cgl clp];
680 tcltk2 = with pkgs; [ tcl tk ];
681 rswipl = with pkgs; [ ncurses.dev libxcrypt zlib.dev ];
682 GrafGen = [ pkgs.zlib ];
683 tikzDevice = with pkgs; [ which texliveMedium ];
684 gridGraphics = [ pkgs.which ];
685 adimpro = with pkgs; [ which xorg.xdpyinfo ];
686 tfevents = [ pkgs.protobuf ];
687 rsvg = [ pkgs.librsvg.dev ];
688 ssh = with pkgs; [ libssh ];
689 s2 = [ pkgs.openssl.dev ];
690 ArrayExpressHTS = with pkgs; [ zlib.dev curl.dev which ];
691 bbl = with pkgs; [ gsl ];
692 diffHic = with pkgs; [ xz.dev bzip2.dev ];
693 writexl = with pkgs; [ zlib.dev ];
694 xslt = with pkgs; [ libxslt libxml2 ];
695 qpdf = with pkgs; [ libjpeg.dev zlib.dev ];
696 vcfR = with pkgs; [ zlib.dev ];
697 bio3d = with pkgs; [ zlib.dev ];
698 arrangements = with pkgs; [ gmp.dev ];
699 gfilogisreg = [ pkgs.gmp.dev ];
700 spp = with pkgs; [ zlib.dev ];
701 bamsignals = with pkgs; [ zlib.dev xz.dev bzip2 ];
702 Rbowtie = with pkgs; [ zlib.dev ];
703 gaston = with pkgs; [ zlib.dev ];
704 csaw = with pkgs; [ zlib.dev xz.dev bzip2.dev curl ];
705 DirichletMultinomial = with pkgs; [ gsl ];
706 DiffBind = with pkgs; [ zlib.dev ];
707 CNEr = with pkgs; [ zlib ];
708 GMMAT = with pkgs; [ zlib.dev bzip2.dev ];
709 rmumps = with pkgs; [ zlib.dev ];
710 HiCDCPlus = [ pkgs.zlib.dev ];
711 PopGenome = [ pkgs.zlib.dev ];
712 QuasR = with pkgs; [ zlib.dev xz.dev bzip2.dev ];
713 Rarr = [ pkgs.zlib.dev ];
714 Rbowtie2 = [ pkgs.zlib.dev ];
715 Rfastp = with pkgs; [ xz.dev bzip2.dev zlib.dev ];
716 maftools = with pkgs; [ zlib.dev bzip2 xz.dev ];
717 Rmmquant = [ pkgs.zlib.dev ];
718 SICtools = with pkgs; [ zlib.dev ncurses.dev ];
719 Signac = [ pkgs.zlib.dev ];
720 TransView = with pkgs; [ xz.dev bzip2.dev zlib.dev ];
721 bigsnpr = [ pkgs.zlib.dev ];
722 zlib = [ pkgs.zlib.dev ];
723 divest = [ pkgs.zlib.dev ];
724 hipread = [ pkgs.zlib.dev ];
725 jack = with pkgs; [ gmp.dev mpfr.dev ];
726 jackalope = with pkgs; [ zlib.dev xz.dev bzip2.dev ];
727 largeList = [ pkgs.zlib.dev ];
728 mappoly = [ pkgs.zlib.dev ];
729 VariantAnnotation = with pkgs; [ zlib.dev curl.dev bzip2.dev xz.dev ];
730 matchingMarkets = [ pkgs.zlib.dev ];
731 methylKit = with pkgs; [ zlib.dev bzip2.dev xz.dev ];
732 ndjson = [ pkgs.zlib.dev ];
733 podkat = with pkgs; [ zlib.dev xz.dev bzip2.dev ];
734 qrqc = [ pkgs.zlib.dev ];
735 rJPSGCS = [ pkgs.zlib.dev ];
736 rhdf5filters = with pkgs; [ zlib.dev bzip2.dev ];
737 symengine = with pkgs; [ mpfr symengine flint ];
738 rtk = [ pkgs.zlib.dev ];
739 scPipe = with pkgs; [ bzip2.dev xz.dev zlib.dev ];
740 seqTools = [ pkgs.zlib.dev ];
741 seqbias = with pkgs; [ zlib.dev bzip2.dev xz.dev ];
742 sparkwarc = [ pkgs.zlib.dev ];
743 RoBMA = [ pkgs.jags ];
744 RoBSA = [ pkgs.jags ];
745 pexm = [ pkgs.jags ];
746 rGEDI = with pkgs; [ libgeotiff.dev libaec zlib.dev hdf5.dev ];
747 rawrr = [ pkgs.mono ];
748 HDF5Array = [ pkgs.zlib.dev ];
749 FLAMES = with pkgs; [ zlib.dev bzip2.dev xz.dev ];
750 ncdfFlow = [ pkgs.zlib.dev ];
751 proj4 = [ pkgs.proj.dev ];
752 rtmpt = [ pkgs.gsl ];
753 mixcat = [ pkgs.gsl ];
754 libstableR = [ pkgs.gsl ];
755 landsepi = [ pkgs.gsl ];
757 econetwork = [ pkgs.gsl ];
758 crandep = [ pkgs.gsl ];
759 catSurv = [ pkgs.gsl ];
760 ccfindR = [ pkgs.gsl ];
761 screenCounter = [ pkgs.zlib.dev ];
762 SPARSEMODr = [ pkgs.gsl ];
763 RKHSMetaMod = [ pkgs.gsl ];
764 LCMCR = [ pkgs.gsl ];
766 scModels = [ pkgs.mpfr.dev ];
767 multibridge = with pkgs; [ pkg-config mpfr.dev ];
768 RcppCWB = with pkgs; [ pcre.dev glib.dev ];
769 redux = [ pkgs.hiredis ];
770 RmecabKo = [ pkgs.mecab ];
771 markets = [ pkgs.gsl ];
772 rlas = [ pkgs.boost ];
773 PoissonBinomial = [ pkgs.fftw.dev ];
774 poisbinom = [ pkgs.fftw.dev ];
775 PoissonMultinomial = [ pkgs.fftw.dev ];
776 psbcGroup = [ pkgs.gsl.dev ];
777 rrd = [ pkgs.rrdtool ];
778 flowWorkspace = [ pkgs.zlib.dev ];
779 RITCH = [ pkgs.zlib.dev ];
780 RcppMeCab = [ pkgs.mecab ];
782 PROJ = [ pkgs.proj.dev ];
783 RcppAlgos = [ pkgs.gmp.dev ];
784 RcppBigIntAlgos = [ pkgs.gmp.dev ];
785 spaMM = [ pkgs.gsl ];
786 shrinkTVP = [ pkgs.gsl ];
787 sbrl = with pkgs; [ gsl gmp.dev ];
788 surveyvoi = with pkgs; [ gmp.dev mpfr.dev ];
789 unigd = with pkgs; [ cairo.dev libpng.dev ];
790 HilbertVisGUI = [ pkgs.gtkmm2.dev ];
791 textshaping = with pkgs; [ harfbuzz.dev freetype.dev fribidi libpng ];
792 DropletUtils = [ pkgs.zlib.dev ];
793 RMariaDB = [ pkgs.libmysqlclient.dev ];
794 ijtiff = [ pkgs.libtiff ];
795 ragg = with pkgs; [ freetype.dev libpng.dev libtiff.dev zlib.dev libjpeg.dev bzip2.dev ] ++ lib.optional stdenv.hostPlatform.isDarwin lerc.dev;
796 qqconf = [ pkgs.fftw.dev ];
797 spFW = [ pkgs.fftw.dev ];
798 qspray = with pkgs; [ gmp.dev mpfr.dev ];
799 ratioOfQsprays = with pkgs; [ gmp.dev mpfr.dev ];
800 symbolicQspray = with pkgs; [ gmp.dev mpfr.dev ];
801 sphereTessellation = with pkgs; [ gmp.dev mpfr.dev ];
802 vapour = with pkgs; [ proj.dev gdal ];
803 MedianaDesigner = [ pkgs.zlib.dev ];
804 ChemmineOB = with pkgs; [ eigen openbabel ];
805 DGP4LCF = [ pkgs.lapack pkgs.blas ];
808 packagesRequiringX = [
817 "CommunityCorrelogram"
819 "DeducerPlugInExample"
820 "DeducerPlugInScaling"
849 "OligoSpecificitySystem"
857 "RcmdrPlugin_FuzzyClust"
860 "RcmdrPlugin_PcaRobust"
861 "RcmdrPlugin_plotByGroup"
863 "RcmdrPlugin_sampling"
866 "RcmdrPlugin_steepness"
878 "TTAinterfaceTrendAnalysis"
884 packagesRequiringHome = [
929 "TotalCopheneticIndex"
951 packagesToSkipCheck = [
952 "MsDataHub" # tries to connect to ExperimentHub
953 "Rmpi" # tries to run MPI processes
954 "ReactomeContentService4R" # tries to connect to Reactome
955 "PhIPData" # tries to download something from a DB
956 "RBioFormats" # tries to download jar during load test
957 "pbdMPI" # tries to run MPI processes
958 "CTdata" # tries to connect to ExperimentHub
959 "rfaRm" # tries to connect to Ebi
960 "data_table" # fails to rename shared library before check
961 "coMethDMR" # tries to connect to ExperimentHub
962 "multiMiR" # tries to connect to DB
963 "snapcount" # tries to connect to snaptron.cs.jhu.edu
966 # Packages which cannot be installed due to lack of dependencies or other reasons.
975 # Impure network access during build
981 # ExperimentHub dependents, require net access during build
984 "GenomicDistributionsData"
991 "SingleMoleculeFootprintingData"
993 "benchmarkfdrData2019"
999 "metaboliteIDmapping"
1008 otherOverrides = old: new: {
1009 # it can happen that the major version of arrow-cpp is ahead of the
1010 # rPackages.arrow that would be built from CRAN sources; therefore, to avoid
1011 # build failures and manual updates of the hash, we use the R source at
1012 # the GitHub release state of libarrow (arrow-cpp) in Nixpkgs. This may
1013 # not exactly represent the CRAN sources, but because patching of the
1014 # CRAN R package is mostly done to meet special CRAN build requirements,
1015 # this is a straightforward approach. Example where patching was necessary
1016 # -> arrow 14.0.0.2 on CRAN; was lagging behind libarrow release:
1017 # https://github.com/apache/arrow/issues/39698 )
1019 vegan3d = old.vegan3d.overrideAttrs (attrs: {
1020 RGL_USE_NULL = "true";
1023 arrow = old.arrow.overrideAttrs (attrs: {
1024 src = pkgs.arrow-cpp.src;
1025 name = "r-arrow-${pkgs.arrow-cpp.version}";
1028 patchShebangs configure
1030 buildInputs = attrs.buildInputs ++ [
1035 gifski = old.gifski.overrideAttrs (attrs: {
1036 cargoDeps = pkgs.rustPlatform.fetchCargoTarball {
1038 sourceRoot = "gifski/src/myrustlib";
1039 hash = "sha256-e6nuiQU22GiO2I+bu0muyICGrdkCLSZUDHDz2mM2hz0=";
1042 cargoRoot = "src/myrustlib";
1044 nativeBuildInputs = attrs.nativeBuildInputs ++ [
1045 pkgs.rustPlatform.cargoSetupHook
1051 timeless = old.timeless.overrideAttrs (attrs: {
1052 cargoDeps = pkgs.rustPlatform.fetchCargoTarball {
1054 sourceRoot = "timeless/src/rust";
1055 hash = "sha256-n0/52CV3NzWe7T3N6VoaURMxWrnqeYaUMPKkUy+LRQs=";
1058 cargoRoot = "src/rust";
1060 nativeBuildInputs = attrs.nativeBuildInputs ++ [
1061 pkgs.rustPlatform.cargoSetupHook
1066 stringi = old.stringi.overrideAttrs (attrs: {
1068 icuName = "icudt52l";
1069 icuSrc = pkgs.fetchzip {
1070 url = "http://static.rexamine.com/packages/${icuName}.zip";
1071 sha256 = "0hvazpizziq5ibc9017i1bb45yryfl26wzfsv05vk9mc1575r6xj";
1075 ${attrs.postInstall or ""}
1076 cp ${icuSrc}/${icuName}.dat $out/library/stringi/libs
1080 xml2 = old.xml2.overrideAttrs (attrs: {
1082 export LIBXML_INCDIR=${pkgs.libxml2.dev}/include/libxml2
1083 patchShebangs configure
1087 sf = old.sf.overrideAttrs (attrs: {
1089 "--with-proj-lib=${pkgs.lib.getLib pkgs.proj}/lib"
1093 terra = old.terra.overrideAttrs (attrs: {
1095 "--with-proj-lib=${pkgs.lib.getLib pkgs.proj}/lib"
1099 vapour = old.vapour.overrideAttrs (attrs: {
1101 "--with-proj-lib=${pkgs.lib.getLib pkgs.proj}/lib"
1105 rzmq = old.rzmq.overrideAttrs (attrs: {
1106 preConfigure = "patchShebangs configure";
1109 clustermq = old.clustermq.overrideAttrs (attrs: {
1110 preConfigure = "patchShebangs configure";
1113 Cairo = old.Cairo.overrideAttrs (attrs: {
1114 NIX_LDFLAGS = "-lfontconfig";
1117 curl = old.curl.overrideAttrs (attrs: {
1118 preConfigure = "patchShebangs configure";
1121 Cyclops = old.Cyclops.overrideAttrs (attrs: {
1122 preConfigure = "patchShebangs configure";
1125 RcppParallel = old.RcppParallel.overrideAttrs (attrs: {
1126 preConfigure = "patchShebangs configure";
1129 Colossus = old.Colossus.overrideAttrs (_: {
1130 postPatch = "patchShebangs configure";
1133 gmailr = old.gmailr.overrideAttrs (attrs: {
1134 postPatch = "patchShebangs configure";
1137 heck = old.heck.overrideAttrs (attrs: {
1138 postPatch = "patchShebangs configure";
1141 surtvep = old.surtvep.overrideAttrs (attrs: {
1142 postPatch = "patchShebangs configure";
1145 purrr = old.purrr.overrideAttrs (attrs: {
1146 patchPhase = "patchShebangs configure";
1149 luajr = old.luajr.overrideAttrs (attrs: {
1150 hardeningDisable = [ "format" ];
1151 postPatch = "patchShebangs configure";
1154 RcppArmadillo = old.RcppArmadillo.overrideAttrs (attrs: {
1155 patchPhase = "patchShebangs configure";
1158 RcppGetconf = old.RcppGetconf.overrideAttrs (attrs: {
1159 postPatch = "patchShebangs configure";
1162 SpliceWiz = old.SpliceWiz.overrideAttrs (attrs: {
1163 postPatch = "patchShebangs configure";
1166 zoomerjoin = old.zoomerjoin.overrideAttrs (attrs: {
1167 nativeBuildInputs = [ pkgs.cargo ] ++ attrs.nativeBuildInputs;
1168 postPatch = "patchShebangs configure";
1171 b64 = old.b64.overrideAttrs (attrs: {
1172 nativeBuildInputs = [ pkgs.cargo ] ++ attrs.nativeBuildInputs;
1173 postPatch = "patchShebangs configure";
1176 ocf = old.ocf.overrideAttrs (attrs: {
1177 postPatch = "patchShebangs configure";
1180 data_table = old.data_table.overrideAttrs (attrs: {
1181 env = (attrs.env or { }) // {
1182 NIX_CFLAGS_COMPILE = attrs.env.NIX_CFLAGS_COMPILE + " -fopenmp";
1184 patchPhase = "patchShebangs configure";
1187 cisPath = old.cisPath.overrideAttrs (attrs: {
1188 hardeningDisable = [ "format" ];
1191 HilbertVis = old.HilbertVis.overrideAttrs (attrs: {
1192 hardeningDisable = [ "format" ];
1195 HilbertVisGUI = old.HilbertVisGUI.overrideAttrs (attrs: {
1196 hardeningDisable = [ "format" ];
1199 MANOR = old.MANOR.overrideAttrs (attrs: {
1200 hardeningDisable = [ "format" ];
1203 rGADEM = old.rGADEM.overrideAttrs (attrs: {
1204 hardeningDisable = [ "format" ];
1207 rsgeo = old.rsgeo.overrideAttrs (attrs: {
1208 nativeBuildInputs = [ pkgs.cargo ] ++ attrs.nativeBuildInputs;
1209 postPatch = "patchShebangs configure";
1212 instantiate = old.instantiate.overrideAttrs (attrs: {
1213 postPatch = "patchShebangs configure";
1216 exifr = old.exifr.overrideAttrs (attrs: {
1218 for f in .onLoad .onAttach ; do
1219 substituteInPlace R/load_hook.R \
1221 "$f <- function(libname, pkgname) {" \
1222 "$f <- function(libname, pkgname) {
1224 exifr.perlpath = \"${lib.getBin pkgs.perl}/bin/perl\",
1225 exifr.exiftoolcommand = \"${lib.getBin pkgs.exiftool}/bin/exiftool\"
1231 NGCHM = old.NGCHM.overrideAttrs (attrs: {
1233 substituteInPlace "inst/base.config/conf.d/01-server-protocol-scl.R" \
1235 "/bin/hostname" "${lib.getBin pkgs.hostname}/bin/hostname"
1239 ModelMetrics = old.ModelMetrics.overrideAttrs (attrs: {
1240 env = (attrs.env or { }) // {
1241 NIX_CFLAGS_COMPILE = attrs.env.NIX_CFLAGS_COMPILE + lib.optionalString stdenv.hostPlatform.isDarwin " -fopenmp";
1245 rawrr = old.rawrr.overrideAttrs (attrs: {
1247 substituteInPlace "R/zzz.R" "R/dotNetAssembly.R" --replace-warn \
1248 "Sys.which('mono')" "'${lib.getBin pkgs.mono}/bin/mono'"
1250 substituteInPlace "R/dotNetAssembly.R" --replace-warn \
1251 "Sys.which(\"xbuild\")" "\"${lib.getBin pkgs.mono}/bin/xbuild\""
1253 substituteInPlace "R/dotNetAssembly.R" --replace-warn \
1254 "cmd <- ifelse(Sys.which(\"msbuild\") != \"\", \"msbuild\", \"xbuild\")" \
1255 "cmd <- \"${lib.getBin pkgs.mono}/bin/xbuild\""
1257 substituteInPlace "R/rawrr.R" --replace-warn \
1258 "Sys.which(\"mono\")" "\"${lib.getBin pkgs.mono}/bin/mono\""
1262 rpf = old.rpf.overrideAttrs (attrs: {
1263 patchPhase = "patchShebangs configure";
1266 rJava = old.rJava.overrideAttrs (attrs: {
1268 export JAVA_CPPFLAGS=-I${pkgs.jdk}/include/
1269 export JAVA_HOME=${pkgs.jdk}
1273 JavaGD = old.JavaGD.overrideAttrs (attrs: {
1275 export JAVA_CPPFLAGS=-I${pkgs.jdk}/include/
1276 export JAVA_HOME=${pkgs.jdk}
1280 jqr = old.jqr.overrideAttrs (attrs: {
1282 patchShebangs configure
1286 pathfindR = old.pathfindR.overrideAttrs (attrs: {
1288 substituteInPlace "R/zzz.R" \
1289 --replace-fail " check_java_version()" " Sys.setenv(JAVA_HOME = \"${lib.getBin pkgs.jre_minimal}\"); check_java_version()"
1290 substituteInPlace "R/active_snw_search.R" \
1291 --replace-fail "system(paste0(\"java" "system(paste0(\"${lib.getBin pkgs.jre_minimal}/bin/java"
1295 pbdZMQ = old.pbdZMQ.overrideAttrs (attrs: {
1296 postPatch = lib.optionalString stdenv.hostPlatform.isDarwin ''
1297 for file in R/*.{r,r.in}; do
1298 sed -i 's#system("which \(\w\+\)"[^)]*)#"${pkgs.cctools}/bin/\1"#g' $file
1303 quarto = old.quarto.overrideAttrs (attrs: {
1304 propagatedBuildInputs = attrs.propagatedBuildInputs ++ [ pkgs.quarto ];
1306 substituteInPlace "R/quarto.R" \
1307 --replace-fail "Sys.getenv(\"QUARTO_PATH\", unset = NA_character_)" "Sys.getenv(\"QUARTO_PATH\", unset = '${lib.getBin pkgs.quarto}/bin/quarto')"
1311 Rhisat2 = old.Rhisat2.overrideAttrs (attrs: {
1312 enableParallelBuilding = false;
1315 s2 = old.s2.overrideAttrs (attrs: {
1316 PKGCONFIG_CFLAGS = "-I${pkgs.openssl.dev}/include";
1317 PKGCONFIG_LIBS = "-Wl,-rpath,${lib.getLib pkgs.openssl}/lib -L${lib.getLib pkgs.openssl}/lib -lssl -lcrypto";
1320 Rmpi = old.Rmpi.overrideAttrs (attrs: {
1322 "--with-Rmpi-type=OPENMPI"
1326 Rmpfr = old.Rmpfr.overrideAttrs (attrs: {
1328 "--with-mpfr-include=${pkgs.mpfr.dev}/include"
1332 covidsymptom = old.covidsymptom.overrideAttrs (attrs: {
1333 preConfigure = "rm R/covidsymptomdata.R";
1336 cubature = old.cubature.overrideAttrs (attrs: {
1337 enableParallelBuilding = false;
1340 RVowpalWabbit = old.RVowpalWabbit.overrideAttrs (attrs: {
1342 "--with-boost=${pkgs.boost.dev}" "--with-boost-libdir=${pkgs.boost.out}/lib"
1346 RAppArmor = old.RAppArmor.overrideAttrs (attrs: {
1347 patches = [ ./patches/RAppArmor.patch ];
1348 LIBAPPARMOR_HOME = pkgs.libapparmor;
1351 RMySQL = old.RMySQL.overrideAttrs (attrs: {
1352 MYSQL_DIR = "${pkgs.libmysqlclient}";
1353 PKGCONFIG_CFLAGS = "-I${pkgs.libmysqlclient.dev}/include/mysql";
1354 NIX_CFLAGS_LINK = "-L${pkgs.libmysqlclient}/lib/mysql -lmysqlclient";
1356 patchShebangs configure
1360 devEMF = old.devEMF.overrideAttrs (attrs: {
1361 NIX_CFLAGS_LINK = "-L${pkgs.xorg.libXft.out}/lib -lXft";
1362 NIX_LDFLAGS = "-lX11";
1365 hdf5r = old.hdf5r.overrideAttrs (attrs: {
1366 buildInputs = attrs.buildInputs ++ [ new.Rhdf5lib.hdf5 ];
1369 slfm = old.slfm.overrideAttrs (attrs: {
1370 PKG_LIBS = "-L${pkgs.blas}/lib -lblas -L${pkgs.lapack}/lib -llapack";
1373 SamplerCompare = old.SamplerCompare.overrideAttrs (attrs: {
1374 PKG_LIBS = "-L${pkgs.blas}/lib -lblas -L${pkgs.lapack}/lib -llapack";
1377 FLAMES = old.FLAMES.overrideAttrs (attrs: {
1378 patches = [ ./patches/FLAMES.patch ];
1381 openssl = old.openssl.overrideAttrs (attrs: {
1383 patchShebangs configure
1385 PKGCONFIG_CFLAGS = "-I${pkgs.openssl.dev}/include";
1386 PKGCONFIG_LIBS = "-Wl,-rpath,${lib.getLib pkgs.openssl}/lib -L${lib.getLib pkgs.openssl}/lib -lssl -lcrypto";
1389 websocket = old.websocket.overrideAttrs (attrs: {
1390 PKGCONFIG_CFLAGS = "-I${pkgs.openssl.dev}/include";
1391 PKGCONFIG_LIBS = "-Wl,-rpath,${lib.getLib pkgs.openssl}/lib -L${lib.getLib pkgs.openssl}/lib -lssl -lcrypto";
1394 Rserve = old.Rserve.overrideAttrs (attrs: {
1395 patches = [ ./patches/Rserve.patch ];
1397 "--with-server" "--with-client"
1401 universalmotif = old.universalmotif.overrideAttrs (attrs: {
1402 patches = [ ./patches/universalmotif.patch];
1405 V8 = old.V8.overrideAttrs (attrs: {
1407 substituteInPlace configure \
1408 --replace-fail " -lv8_libplatform" ""
1409 # Bypass the test checking if pointer compression is needed
1410 substituteInPlace configure \
1411 --replace-fail "./pctest1" "true"
1415 export INCLUDE_DIR=${pkgs.nodejs.libv8}/include
1416 export LIB_DIR=${pkgs.nodejs.libv8}/lib
1417 patchShebangs configure
1420 R_MAKEVARS_SITE = lib.optionalString (pkgs.stdenv.system == "aarch64-linux")
1421 (pkgs.writeText "Makevars" ''
1422 CXX14PICFLAGS = -fPIC
1426 acs = old.acs.overrideAttrs (attrs: {
1428 patchShebangs configure
1432 gdtools = old.gdtools.overrideAttrs (attrs: {
1434 patchShebangs configure
1436 NIX_LDFLAGS = "-lfontconfig -lfreetype";
1439 magick = old.magick.overrideAttrs (attrs: {
1441 patchShebangs configure
1445 libgeos = old.libgeos.overrideAttrs (attrs: {
1447 patchShebangs configure
1451 protolite = old.protolite.overrideAttrs (attrs: {
1453 patchShebangs configure
1457 rgoslin = old.rgoslin.overrideAttrs (attrs: {
1458 enableParallelBuilding = false;
1461 rpanel = old.rpanel.overrideAttrs (attrs: {
1463 export TCLLIBPATH="${pkgs.tclPackages.bwidget}/lib/bwidget${pkgs.tclPackages.bwidget.version}"
1465 TCLLIBPATH = "${pkgs.tclPackages.bwidget}/lib/bwidget${pkgs.tclPackages.bwidget.version}";
1468 networkscaleup = old.networkscaleup.overrideAttrs (attrs: {
1469 env = (attrs.env or { }) // {
1470 # needed to avoid "log limit exceeded" on Hydra
1471 NIX_CFLAGS_COMPILE = attrs.env.NIX_CFLAGS_COMPILE + " -Wno-ignored-attributes";
1474 # consumes a lot of resources in parallel
1475 enableParallelBuilding = false;
1478 RPostgres = old.RPostgres.overrideAttrs (attrs: {
1480 export INCLUDE_DIR=${pkgs.postgresql}/include
1481 export LIB_DIR=${pkgs.postgresql.lib}/lib
1482 patchShebangs configure
1486 OpenMx = old.OpenMx.overrideAttrs (attrs: {
1487 env = (attrs.env or { }) // {
1488 # needed to avoid "log limit exceeded" on Hydra
1489 NIX_CFLAGS_COMPILE = attrs.env.NIX_CFLAGS_COMPILE + " -Wno-ignored-attributes";
1492 patchShebangs configure
1496 odbc = old.odbc.overrideAttrs (attrs: {
1498 patchShebangs configure
1502 x13binary = old.x13binary.overrideAttrs (attrs: {
1504 patchShebangs configure
1508 FlexReg = old.FlexReg.overrideAttrs (attrs: {
1509 env = (attrs.env or { }) // {
1510 # needed to avoid "log limit exceeded" on Hydra
1511 NIX_CFLAGS_COMPILE = attrs.env.NIX_CFLAGS_COMPILE + " -Wno-ignored-attributes";
1514 # consumes a lot of resources in parallel
1515 enableParallelBuilding = false;
1518 geojsonio = old.geojsonio.overrideAttrs (attrs: {
1519 buildInputs = [ cacert ] ++ attrs.buildInputs;
1524 MHC41alleleList = fetchurl {
1525 url = "https://services.healthtech.dtu.dk/services/NetMHCpan-4.1/allele.list";
1526 hash = "sha256-CRZ+0uHzcq5zK5eONucAChXIXO8tnq5sSEAS80Z7jhg=";
1529 MHCII40alleleList = fetchurl {
1530 url = "https://services.healthtech.dtu.dk/services/NetMHCIIpan-4.0/alleles_name.list";
1531 hash = "sha256-K4Ic2NUs3P4IkvOODwZ0c4Yh8caex5Ih0uO5jXRHp40=";
1534 # List of valid countries, regions and ethnic groups
1535 # The original page is changing a bit every day, but the relevant
1536 # content does not. Use archive.org to get a stable snapshot.
1537 # It can be updated from time to time, or when the package becomes
1538 # deficient. This may be difficult to know.
1539 # Update the snapshot date, and add id_ after it, as described here:
1540 # https://web.archive.org/web/20130806040521/http://faq.web.archive.org/page-without-wayback-code/
1541 validGeographics = fetchurl {
1542 url = "https://web.archive.org/web/20240418194005id_/http://www.allelefrequencies.net/hla6006a.asp";
1543 hash = "sha256-m7Wkmh/cPxeqn94LwoznIh+fcFXskmSGErUYj6kTqak=";
1545 in old.immunotation.overrideAttrs (attrs: {
1546 patches = [ ./patches/immunotation.patch ];
1548 substituteInPlace "R/external_resources_input.R" --replace-fail \
1549 "nix-NetMHCpan-4.1-allele-list" ${MHC41alleleList}
1551 substituteInPlace "R/external_resources_input.R" --replace-fail \
1552 "nix-NETMHCIIpan-4.0-alleles-name-list" ${MHCII40alleleList}
1554 substituteInPlace "R/AFND_interface.R" --replace-fail \
1555 "nix-valid-geographics" ${validGeographics}
1560 angrist = fetchurl {
1561 url = "https://raw.githubusercontent.com/joerigdon/nearfar/master/angrist.csv";
1562 hash = "sha256-lb+HMHnRGonc26merFGB0B7Vk1Lk+sIJlay+JtQC8m4=";
1564 in old.nearfar.overrideAttrs (attrs: {
1566 substituteInPlace "R/nearfar.R" --replace-fail \
1567 'url("https://raw.githubusercontent.com/joerigdon/nearfar/master/angrist.csv")' '"${angrist}"'
1571 rstan = old.rstan.overrideAttrs (attrs: {
1572 env = (attrs.env or { }) // {
1573 NIX_CFLAGS_COMPILE = attrs.env.NIX_CFLAGS_COMPILE + " -DBOOST_PHOENIX_NO_VARIADIC_EXPRESSION";
1577 mongolite = old.mongolite.overrideAttrs (attrs: {
1579 patchShebangs configure
1581 PKGCONFIG_CFLAGS = "-I${pkgs.openssl.dev}/include -I${pkgs.cyrus_sasl.dev}/include -I${pkgs.zlib.dev}/include";
1582 PKGCONFIG_LIBS = "-Wl,-rpath,${lib.getLib pkgs.openssl}/lib -L${lib.getLib pkgs.openssl}/lib -L${pkgs.cyrus_sasl.out}/lib -L${pkgs.zlib.out}/lib -lssl -lcrypto -lsasl2 -lz";
1585 ChemmineOB = old.ChemmineOB.overrideAttrs (attrs: {
1586 # pkg-config knows openbabel-3 without the .0
1587 # Eigen3 is also looked for in the wrong location
1588 # pointer was changed in newer version of openbabel:
1589 # https://github.com/openbabel/openbabel/commit/305a6fd3183540e4a8ae1d79d10bf1860e6aa373
1591 substituteInPlace configure \
1592 --replace-fail openbabel-3.0 openbabel-3
1593 substituteInPlace src/Makevars.in \
1594 --replace-fail "-I/usr/include/eigen3" "-I${pkgs.eigen}/include/eigen3"
1595 substituteInPlace src/ChemmineOB.cpp \
1596 --replace-fail "obsharedptr<" "std::shared_ptr<"
1599 # copied from fastnlo-toolkit:
1600 # None of our currently packaged versions of swig are C++17-friendly
1601 # Use a workaround from https://github.com/swig/swig/issues/1538
1602 env = (attrs.env or { }) // {
1603 NIX_CFLAGS_COMPILE = (attrs.env.NIX_CFLAGS_COMPILE or "") + lib.optionalString stdenv.hostPlatform.isDarwin " -D_LIBCPP_ENABLE_CXX17_REMOVED_FEATURES";
1607 ps = old.ps.overrideAttrs (attrs: {
1608 preConfigure = "patchShebangs configure";
1611 rlang = old.rlang.overrideAttrs (attrs: {
1612 preConfigure = "patchShebangs configure";
1615 systemfonts = old.systemfonts.overrideAttrs (attrs: {
1616 preConfigure = "patchShebangs configure";
1619 littler = old.littler.overrideAttrs (attrs: with pkgs; {
1620 buildInputs = [ pcre xz zlib bzip2 icu which ] ++ attrs.buildInputs;
1622 install -d $out/bin $out/share/man/man1
1623 ln -s ../library/littler/bin/r $out/bin/r
1624 ln -s ../library/littler/bin/r $out/bin/lr
1625 ln -s ../../../library/littler/man-page/r.1 $out/share/man/man1
1626 # these won't run without special provisions, so better remove them
1627 rm -r $out/library/littler/script-tests
1631 lpsymphony = old.lpsymphony.overrideAttrs (attrs: {
1633 patchShebangs configure
1637 sodium = old.sodium.overrideAttrs (attrs: with pkgs; {
1639 patchShebangs configure
1641 nativeBuildInputs = [ pkg-config ] ++ attrs.nativeBuildInputs;
1642 buildInputs = [ libsodium.dev ] ++ attrs.buildInputs;
1645 keyring = old.keyring.overrideAttrs (attrs: {
1647 patchShebangs configure
1651 Rhtslib = old.Rhtslib.overrideAttrs (attrs: {
1653 substituteInPlace R/zzz.R --replace "-lcurl" "-L${pkgs.curl.out}/lib -lcurl"
1657 h2o = old.h2o.overrideAttrs (attrs: {
1659 # prevent download of jar file during install and postpone to first use
1660 sed -i '/downloadJar()/d' R/zzz.R
1662 # during runtime the package directory is not writable as it's in the
1663 # nix store, so store the jar in the user's cache directory instead
1664 substituteInPlace R/connection.R --replace \
1665 'dest_file <- file.path(dest_folder, "h2o.jar")' \
1666 'dest_file <- file.path("~/.cache/", "h2o.jar")'
1670 SICtools = old.SICtools.overrideAttrs (attrs: {
1672 substituteInPlace src/Makefile --replace-fail "-lcurses" "-lncurses"
1674 hardeningDisable = [ "format" ];
1677 Rbwa = old.Rbwa.overrideAttrs (attrs: {
1678 # Parallel build cleans up *.o before they can be packed in a library
1680 substituteInPlace src/Makefile --replace-fail \
1681 "all:\$(PROG) ../inst/bwa clean" \
1682 "all:\$(PROG) ../inst/bwa" \
1686 ROracle = old.ROracle.overrideAttrs (attrs: {
1688 "--with-oci-lib=${pkgs.oracle-instantclient.lib}/lib"
1689 "--with-oci-inc=${pkgs.oracle-instantclient.dev}/include"
1693 xslt = old.xslt.overrideAttrs (attrs: {
1694 env = (attrs.env or { }) // {
1695 NIX_CFLAGS_COMPILE = attrs.env.NIX_CFLAGS_COMPILE + " -fpermissive";
1699 sparklyr = old.sparklyr.overrideAttrs (attrs: {
1700 # Pyspark's spark is full featured and better maintained than pkgs.spark
1702 substituteInPlace R/zzz.R \
1703 --replace ".onLoad <- function(...) {" \
1704 ".onLoad <- function(...) {
1705 Sys.setenv(\"SPARK_HOME\" = Sys.getenv(\"SPARK_HOME\", unset = \"${pkgs.python3Packages.pyspark}/${pkgs.python3Packages.python.sitePackages}/pyspark\"))
1706 Sys.setenv(\"JAVA_HOME\" = Sys.getenv(\"JAVA_HOME\", unset = \"${pkgs.jdk}\"))"
1710 proj4 = old.proj4.overrideAttrs (attrs: {
1712 substituteInPlace configure \
1713 --replace "-lsqlite3" "-L${lib.makeLibraryPath [ pkgs.sqlite ]} -lsqlite3"
1717 rrd = old.rrd.overrideAttrs (attrs: {
1719 patchShebangs configure
1723 ChIPXpress = old.ChIPXpress.override { hydraPlatforms = []; };
1725 rgl = old.rgl.overrideAttrs (attrs: {
1726 RGL_USE_NULL = "true";
1729 Rrdrand = old.Rrdrand.override { platforms = lib.platforms.x86_64 ++ lib.platforms.x86; };
1731 symengine = old.symengine.overrideAttrs (_: {
1734 cat > src/Makevars << EOF
1735 PKG_LIBS=-lsymengine
1741 RandomFieldsUtils = old.RandomFieldsUtils.override { platforms = lib.platforms.x86_64 ++ lib.platforms.x86; };
1743 flowClust = old.flowClust.override { platforms = lib.platforms.x86_64 ++ lib.platforms.x86; };
1745 RcppCGAL = old.RcppCGAL.overrideAttrs (_: {
1746 postPatch = "patchShebangs configure";
1749 SharedObject = old.SharedObject.overrideAttrs (attrs: {
1750 # backport PR resolving build issues: https://github.com/Jiefei-Wang/SharedObject/pull/17
1751 patches = let inherit (pkgs) fetchpatch; in [
1753 url = "https://github.com/Jiefei-Wang/SharedObject/pull/17/commits/50c4b2964649d7f5a14d843bd7089ab62650fcd3.patch";
1754 sha256 = "sha256-zn535IeOYRvyQ2yxgoGEq2wccrl9xdu9nREmy7sV+PQ=";
1757 url = "https://github.com/Jiefei-Wang/SharedObject/pull/17/commits/bf096a39858e9210cbe246d4b136905d4cfbfaf4.patch";
1758 sha256 = "sha256-Z+BZOkFnLgIBiVuPsAHp7bMXzADcvuHV4hILdmLvd+k=";
1763 httr2 = old.httr2.overrideAttrs (attrs: {
1764 preConfigure = "patchShebangs configure";
1767 dbarts = old.dbarts.override { platforms = lib.platforms.x86_64 ++ lib.platforms.x86; };
1769 geomorph = old.geomorph.overrideAttrs (attrs: {
1770 RGL_USE_NULL = "true";
1773 gpuMagic = old.gpuMagic.overrideAttrs (_: {
1774 hardeningDisable = ["format"];
1777 Rdisop = old.Rdisop.overrideAttrs (_: {
1778 hardeningDisable = ["format"];
1782 opencvGtk = pkgs.opencv.override (old : { enableGtk2 = true; });
1783 in old.opencv.overrideAttrs (attrs: {
1784 buildInputs = attrs.buildInputs ++ [ opencvGtk ];
1788 hdf5 = pkgs.hdf5_1_10.overrideAttrs (attrs: {configureFlags = attrs.configureFlags ++ [ "--enable-cxx" ];});
1789 in old.Rhdf5lib.overrideAttrs (attrs: {
1790 propagatedBuildInputs = attrs.propagatedBuildInputs ++ [ hdf5.dev pkgs.libaec ];
1791 patches = [ ./patches/Rhdf5lib.patch ];
1792 passthru.hdf5 = hdf5;
1795 rhdf5filters = old.rhdf5filters.overrideAttrs (attrs: {
1796 patches = [ ./patches/rhdf5filters.patch ];
1799 rhdf5= old.rhdf5.overrideAttrs (attrs: {
1800 patches = [ ./patches/rhdf5.patch ];
1803 rmarkdown = old.rmarkdown.overrideAttrs (_: {
1805 substituteInPlace R/pandoc.R \
1806 --replace '"~/opt/pandoc"' '"~/opt/pandoc", "${pkgs.pandoc}/bin"'
1810 redland = old.redland.overrideAttrs (_: {
1811 PKGCONFIG_CFLAGS="-I${pkgs.redland}/include -I${pkgs.librdf_raptor2}/include/raptor2 -I${pkgs.librdf_rasqal}/include/rasqal";
1812 PKGCONFIG_LIBS="-L${pkgs.redland}/lib -L${pkgs.librdf_raptor2}/lib -L${pkgs.librdf_rasqal}/lib -lrdf -lraptor2 -lrasqal";
1815 textshaping = old.textshaping.overrideAttrs (attrs: {
1816 env.NIX_LDFLAGS = "-lfribidi -lharfbuzz";
1819 httpuv = old.httpuv.overrideAttrs (_: {
1821 patchShebangs configure
1825 oligo = old.oligo.overrideAttrs (_: {
1826 hardeningDisable = ["format"];
1829 tesseract = old.tesseract.overrideAttrs (_: {
1831 substituteInPlace configure \
1832 --replace 'PKG_CONFIG_NAME="tesseract"' 'PKG_CONFIG_NAME="tesseract lept"'
1836 ijtiff = old.ijtiff.overrideAttrs (_: {
1838 patchShebangs configure
1842 torch = old.torch.overrideAttrs (attrs: {
1844 patchShebangs configure
1848 pak = old.pak.overrideAttrs (attrs: {
1850 patchShebangs configure
1851 patchShebangs src/library/curl/configure
1852 patchShebangs src/library/pkgdepends/configure
1853 patchShebangs src/library/ps/configure
1857 pkgdepends = old.pkgdepends.overrideAttrs (attrs: {
1859 patchShebangs configure