Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
argo
argopkgs
Commits
54b27173
Commit
54b27173
authored
Feb 26, 2019
by
Valentin Reis
Browse files
update grafting logic.
parent
b9f5d910
Pipeline
#5661
passed with stages
in 34 minutes and 21 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
pkgs/default.nix
View file @
54b27173
{
# host package set (unused except for fetching nixpkgs)
hostPkgs
?
import
<
nixpkgs
>
{}
hostPkgs
?
import
<
nixpkgs
>
{}
,
# versioned nixpkgs
pkgs
?
import
(
hostPkgs
.
nix-update-source
.
fetch
./pkgs.json
)
.
src
{}
pkgs
?
import
(
hostPkgs
.
nix-update-source
.
fetch
./pkgs.json
)
.
src
{}
,
# versioned nixpkgs-older version for zmcat
pkgs-old
?
import
(
hostPkgs
.
nix-update-source
.
fetch
./pkgs-old.json
)
.
src
{}
pkgs-old
?
import
(
hostPkgs
.
nix-update-source
.
fetch
./pkgs-old.json
)
.
src
{}
,
# fetcher alias for the remaining arguments
fetched
?
s
:
(
pkgs
.
nix-update-source
.
fetch
s
)
.
src
fetched
?
s
:
(
pkgs
.
nix-update-source
.
fetch
s
)
.
src
,
#source overrides: core nrm components
aml-src
?
fetched
aml/pin.json
,
libnrm-src
?
fetched
libnrm/pin.json
,
nrm-src
?
fetched
nrm/pin.json
,
containers-src
?
fetched
containers/pin.json
aml-src
?
fetched
aml/pin.json
,
libnrm-src
?
fetched
libnrm/pin.json
,
nrm-src
?
fetched
nrm/pin.json
,
containers-src
?
fetched
containers/pin.json
,
#source overrides: applications
amg-src
?
fetched
amg/pin.json
,
qmcpack-src
?
fetched
qmcpack/pin.json
,
openmc-src
?
fetched
openmc/pin.json
,
stream-src
?
fetched
stream/pin.json
,
lammps-src
?
fetched
lammps/pin.json
amg-src
?
fetched
amg/pin.json
,
qmcpack-src
?
fetched
qmcpack/pin.json
,
openmc-src
?
fetched
openmc/pin.json
,
stream-src
?
fetched
stream/pin.json
,
lammps-src
?
fetched
lammps/pin.json
,
#source overrides: tooling
argotk-src
?
builtins
.
fetchGit
{
inherit
(
fetched
argotk/pin.json
)
url
rev
;}
...
...
@@ -30,10 +30,10 @@
,
experiments-src
?
fetched
experiments/pin.json
,
#used for hardware experiments.
sudoPath
?
null
sudoPath
?
null
,
#whether to
rebuild
apps
whe
n libnrm
changes
.
rebuildApps
?
tru
e
,
#whether to
graft
apps
o
n libnrm.
graftLibnrm
?
fals
e
}:
let
callPackage
=
pkgs
.
lib
.
callPackageWith
(
pkgs
//
argopkgs
);
...
...
@@ -60,11 +60,13 @@ let
src
=
src
;
libnrm
=
libnrm-pinned
;
};
in
if
!
rebuildApps
then
drv
else
pkgs
.
replaceDependency
{
drv
=
drv
;
oldDependency
=
libnrm-pinned
;
newDependency
=
libnrm
;
};
rebuilt
=
drv
.
override
{
libnrm
=
libnrm
;};
grafted
=
pkgs
.
replaceDependency
{
drv
=
drv
;
oldDependency
=
libnrm-pinned
;
newDependency
=
libnrm
;
};
in
if
graftLibnrm
then
grafted
else
rebuilt
;
amg
=
repLibnrm
./amg
amg-src
{};
qmcpack
=
repLibnrm
./qmcpack
qmcpack-src
{};
openmc
=
repLibnrm
./openmc
openmc-src
{};
...
...
@@ -273,33 +275,3 @@ let
};
# re-exporting a full nixpkgs-like package set
in
pkgs
//
argopkgs
#jupyter =
#let
#jupyter = import (fetched jupyter/pin.json) {};
#in
#(jupyter.jupyterlabWith {
#kernels = [
#(jupyter.kernels.juniperWith {
#name = "analysis";
#packages = p: with p; [ ggplot2
#pkgs.which
#docopt
#purrr
#knitr
#cowplot
#plotly
#lubridate
#dplyr
#ggplot2
#xtable
#ggthemes
#data_table
#];
#})
#];
#}).env;
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment