Skip to content

Commit

Permalink
Reworked the spack develop stuff for the tutorial. (#100)
Browse files Browse the repository at this point in the history
* Adding the developer workflows.

* Adding all script output for the development stuff.

* update dev commands

* update dev outputs

Co-authored-by: Gregory Becker <becker33@llnl.gov>
  • Loading branch information
rblake-llnl and becker33 committed Apr 16, 2021
1 parent 45c6cd3 commit c162065
Show file tree
Hide file tree
Showing 16 changed files with 745 additions and 185 deletions.
4 changes: 2 additions & 2 deletions outputs/basics.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ example basics/list-py "spack list 'py-*'"
# spack install
example basics/zlib "spack install zlib"

example basics/mirror "spack mirror add tutorial s3://spack-binaries-prs/tutorial/ecp21/mirror"
example basics/mirror "spack buildcache keys -it"
example basics/mirror "spack mirror add tutorial /mirror"
example basics/mirror "spack buildcache keys --install --trust"

example basics/zlib-clang "spack install zlib %clang"

Expand Down
55 changes: 39 additions & 16 deletions outputs/dev.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,34 +10,57 @@ pip install boto3
example dev/up-to-date "git clone https://github.com/spack/spack ~/spack"
example dev/up-to-date "cd ~/spack"
cd ~/spack
example dev/up-to-date "git checkout releases/v0.15"
example dev/up-to-date "git checkout releases/v0.16"
example dev/up-to-date ". share/spack/setup-env.sh"
. share/spack/setup-env.sh
spack config add "config:suppress_gpg_warnings:true"
spack config add "packages:all:target:[x86_64]"

example dev/up-to-date "spack mirror add tutorial s3://spack-tutorial-container/mirror/"
example dev/up-to-date "spack mirror add tutorial /mirror"
example dev/up-to-date "spack gpg trust share/spack/keys/tutorial.pub"

example dev/setup-hwloc "cd ~"
example dev/setup-scr "cd ~"
cd ~
example dev/setup-hwloc "git clone https://github.com/open-mpi/hwloc.git"
example dev/setup-hwloc "cd hwloc"
cd hwloc
example dev/setup-scr "mkdir devel-env"
example dev/setup-scr "cd devel-env"
cd devel-env
example dev/setup-scr "spack env create -d ."
fake_example dev/setup-scr "spacktivate ." "spack env activate ."
spack env activate .
example dev/setup-scr "# for now, disable fortran support in all packages"
example dev/setup-scr 'spack config add "packages:all:variants: ~fortran"'
example dev/setup-scr "spack add macsio+scr"
example dev/setup-scr "spack install"

example dev/dev-build-1 "spack dev-build hwloc@master"
example dev/develop-1 "spack develop scr@2.0.0"
example dev/develop-1 "grep -3 develop: spack.yaml"

example dev/info "spack info hwloc"
example dev/develop-conc "spack concretize -f"

echo y | example dev/dev-build-2 "spack uninstall hwloc@master"
fake_example dev/dev-build-2 "spack dev-build --until configure --drop-in bash hwloc@master" "spack dev-build --until configure hwloc@master"
example dev/develop-2 "spack install"

export EDITOR="bash -c exit 0"
fake_example dev/edit-1 '$EDITOR hwloc/base64.c' "/bin/true"
sed -i~ s'|\("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"\);|\1|' hwloc/base64.c | head -n 70
fake_example dev/edit-1 '$EDITOR scr/src/scr_copy.c' "/bin/true"
sed -i~ s'|\(static char hostname\[256\] = "UNKNOWN_HOST"\);|\1|' scr/src/scr_copy.c | head -n 70

fake_example dev/hand-build-1 "make" "spack build-env hwloc@master -- make"
example dev/develop-3 "spack install"

fake_example dev/hand-build-2 '$EDITOR hwloc/base64.c' "/bin/true"
sed -i~ s'|\("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"\)|\1;|' hwloc/base64.c | head -n 70
fake_example dev/hand-build-2 "make" "spack build-env hwloc@master -- make"
fake_example dev/develop-4 '$EDITOR scr/src/scr_copy.c' "/bin/true"
sed -i~ s'|\(static char hostname\[256\] = "UNKNOWN_HOST"\)|\1;|' scr/src/scr_copy.c | head -n 70
example dev/develop-4 "spack install"

example dev/develop-5 "spack develop macsio@1.1"
example dev/develop-5 "spack concretize -f"

example dev/otherdevel "cd ~"
cd ~
example dev/otherdevel "mkdir devel-other"
example dev/otherdevel "cd devel-other"
cd devel-other
example dev/otherdevel "cp ../devel-env/spack.yaml ."
fake_example dev/otherdevel "spacktivate ." "spack env activate ."
spack env activate .
example dev/otherdevel "spack develop"
example dev/otherdevel "ls"

example dev/wrapup "spack undevelop scr macsio"
44 changes: 22 additions & 22 deletions outputs/dev/dev-build-1.out
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@ autoreconf: Leaving directory `.'
==> hwloc: Executing phase: 'configure'
==> [2020-07-28-12:08:30.318962] '/home/spack/hwloc/configure' '--prefix=/home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/hwloc-master-umvxpk7m424rjq5f52bfzwwbrwj26b3p' '--disable-opencl' '--disable-cairo' '--disable-nvml' '--disable-gl' '--disable-cuda' '--enable-libxml2' '--disable-libudev' '--enable-pci' '--enable-shared'

##
## Configuring hwloc distribution tarball
## Startup tests
##
#
# Configuring hwloc distribution tarball
# Startup tests
#
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
Expand Down Expand Up @@ -175,9 +175,9 @@ checking for pkg-config... /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/
checking pkg-config is at least version 0.9.0... yes
checking for X... no

##
## Configuring hwloc core
##
#
# Configuring hwloc core
#
checking hwloc building mode... standalone
configure: hwloc builddir: /home/spack/hwloc
configure: hwloc srcdir: /home/spack/hwloc
Expand Down Expand Up @@ -334,9 +334,9 @@ checking if plugin support is enabled... no
checking components to build statically... noos xml synthetic xml_nolibxml linux pci xml_libxml x86
checking components to build as plugins...

##
## Configuring netloc core
##
#
# Configuring netloc core
#
checking for asprintf... yes
checking if netloc supports this platform... yes
checking for SCOTCH_archSub in -lscotch... no
Expand All @@ -346,9 +346,9 @@ checking for mpi.h... no
checking for xz... yes
checking for diff... /usr/bin/diff

##
## Configuring hwloc documentation
##
#
# Configuring hwloc documentation
#
checking if this is a developer build... yes
checking for doxygen... no
checking for pdflatex... no
Expand All @@ -363,9 +363,9 @@ checking if can build top-level README... no
checking if will build doxygen docs... no
checking if will install doxygen docs... no

##
## Configuring hwloc command line utilities
##
#
# Configuring hwloc command line utilities
#
checking X11/Xlib.h usability... no
checking X11/Xlib.h presence... no
checking for X11/Xlib.h... no
Expand Down Expand Up @@ -400,9 +400,9 @@ checking time.h presence... yes
checking for time.h... yes
checking for clock_gettime... yes

##
## Configuring tests
##
#
# Configuring tests
#
checking for pthread_self in -lpthread... yes
checking for NUMA... no
checking for numa_available in -lnuma... no
Expand All @@ -416,9 +416,9 @@ checking for bunzip2... bunzip2
checking if CXX works... yes
checking whether diff accepts -u... yes

##
## Performing final hwloc configuration
##
#
# Performing final hwloc configuration
#
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
Expand Down
44 changes: 22 additions & 22 deletions outputs/dev/dev-build-2.out
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ $ spack dev-build --until configure --drop-in bash hwloc@master
==> hwloc: Executing phase: 'configure'
==> [2020-07-28-09:52:32.411527] '/home/spack/hwloc/configure' '--prefix=/home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/hwloc-master-umvxpk7m424rjq5f52bfzwwbrwj26b3p' '--disable-opencl' '--disable-cairo' '--disable-nvml' '--disable-gl' '--disable-cuda' '--enable-libxml2' '--disable-libudev' '--enable-pci' '--enable-shared'

##
## Configuring hwloc distribution tarball
## Startup tests
##
#
# Configuring hwloc distribution tarball
# Startup tests
#
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking target system type... x86_64-pc-linux-gnu
Expand Down Expand Up @@ -151,9 +151,9 @@ checking for pkg-config... /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/
checking pkg-config is at least version 0.9.0... yes
checking for X... no

##
## Configuring hwloc core
##
#
# Configuring hwloc core
#
checking hwloc building mode... standalone
configure: hwloc builddir: /home/spack/hwloc
configure: hwloc srcdir: /home/spack/hwloc
Expand Down Expand Up @@ -310,9 +310,9 @@ checking if plugin support is enabled... no
checking components to build statically... noos xml synthetic xml_nolibxml linux pci xml_libxml x86
checking components to build as plugins...

##
## Configuring netloc core
##
#
# Configuring netloc core
#
checking for asprintf... yes
checking if netloc supports this platform... yes
checking for SCOTCH_archSub in -lscotch... no
Expand All @@ -322,9 +322,9 @@ checking for mpi.h... no
checking for xz... yes
checking for diff... /usr/bin/diff

##
## Configuring hwloc documentation
##
#
# Configuring hwloc documentation
#
checking if this is a developer build... yes
checking for doxygen... no
checking for pdflatex... no
Expand All @@ -339,9 +339,9 @@ checking if can build top-level README... no
checking if will build doxygen docs... no
checking if will install doxygen docs... no

##
## Configuring hwloc command line utilities
##
#
# Configuring hwloc command line utilities
#
checking X11/Xlib.h usability... no
checking X11/Xlib.h presence... no
checking for X11/Xlib.h... no
Expand Down Expand Up @@ -376,9 +376,9 @@ checking time.h presence... yes
checking for time.h... yes
checking for clock_gettime... yes

##
## Configuring tests
##
#
# Configuring tests
#
checking for pthread_self in -lpthread... yes
checking for NUMA... no
checking for numa_available in -lnuma... no
Expand All @@ -392,9 +392,9 @@ checking for bunzip2... bunzip2
checking if CXX works... yes
checking whether diff accepts -u... yes

##
## Performing final hwloc configuration
##
#
# Performing final hwloc configuration
#
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
Expand Down
12 changes: 12 additions & 0 deletions outputs/dev/develop-1.out
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
$ spack develop scr@2.0.0
==> Configuring spec scr@2.0.0 for development at path scr
==> Fetching https://spack-llnl-mirror.s3-us-west-2.amazonaws.com/_source-cache/archive/47/471978ae0afb56a20847d3989b994fbd680d1dea21e77a5a46a964b6e3deed6b.tar.gz
################################################################################################ 100.0%
==> Updating view at /home/spack/devel-env/.spack-env/view
$ grep -3 develop: spack.yaml
packages:
all:
variants: ~fortran
develop:
scr:
spec: scr@2.0.0
47 changes: 47 additions & 0 deletions outputs/dev/develop-2.out
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
$ spack install
==> Installing environment /home/spack/devel-env
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/pkgconf-1.7.3-4sh6pymrm2ms4auu3ajbjjr6fiuhz5g7
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/berkeley-db-18.1.40-4ihuiazsglf22f3pntq5hc4kyszqzexn
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/zlib-1.2.11-smoyzzo2qhzpn6mg6rd3l2p7b23enshg
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/libsigsegv-2.12-lbrx7lnfz46ukewxbhxnucmx76g23c6q
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/util-macros-1.19.1-gs6ag7ktdoiirb62t7bcagjw62szrrg2
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/libiconv-1.16-jearpk4xci4zc7dkrza4fufaqfkq7rfl
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/xz-5.2.5-komekkmyciga3kl24edjmredhj3uyt7v
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/libyogrt-1.24-ld352tmlkqdjwucj2u5g4fktj2ab2xte
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/pdsh-2.31-pv3zp64j5luhresoommun73mk5joqpb5
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/ncurses-6.2-crhlefo3dv7lmsv5pf4icsy4gepkdorm
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/m4-1.4.18-mkc3u4x2p2wie6jfhuku7g5rkovcrxps
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/libxml2-2.9.10-yn2r3wfhiilelyulh5toteicdtxjhw7d
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/readline-8.0-t54jzdy2jj4snltjazlm3br2urcilc6v
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/libtool-2.4.6-jdxbjftheiotj6solpomva7dowrhlerl
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/gdbm-1.18.1-4av4gywgpaspkhy3dvbb62nulqogtzbb
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/libpciaccess-0.16-bob4o5m3uku6vtdil5imasprgy775zg7
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/perl-5.32.0-zfdvt2jjuaees43ffrrtphqs2ky3o22t
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/openssl-1.1.1h-es377uqsqougfc67jyg7yfjyyuukin52
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/autoconf-2.69-mm33a3ocsv3jsh2tfxc4mlab4xsurtdd
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/cmake-3.18.4-bltycqwh5oofai4f6o42q4uuj4w5zb3j
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/automake-1.16.2-d2krmb5gweivlnztcymhklzsqbrpatt6
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/numactl-2.0.14-wbqbc5vw5sxzwhvu56p6x5nd5n4abrvh
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/json-cwx-0.12-7tkgwjvu2mi4ea2wsdetunq7g4k4r2nh
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/hwloc-1.11.11-zqwfzhw5k2ollygh6nrjpsi7u4d4g6lu
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/openmpi-3.1.6-pmsyupw6w3gql4loaor25gfumlmvkl25
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/lwgrp-1.0.3-tzf27ncg7jccpnayixks4hlam3wpv4wy
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/hdf5-1.10.7-vedchc5aoqyu3ydbp346qrbpe6kg46rq
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/dtcmp-1.1.1-fxiami4ydeszdv55txp4zfin3kzfvpc7
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/silo-4.10.2-vfrf7asfclt7epufnoxibfqbkntbk5k3
==> Installing scr-2.0.0-jlvvs27eu2jsvzeobu22z6skocq3fmte
==> No binary for scr-2.0.0-jlvvs27eu2jsvzeobu22z6skocq3fmte found: installing from source
==> scr: Executing phase: 'cmake'
==> scr: Executing phase: 'build'
==> scr: Executing phase: 'install'
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/scr-2.0.0-jlvvs27eu2jsvzeobu22z6skocq3fmte
==> Installing macsio-1.1-6x6pqmrjajd57kbzgtwgdz3rpozuwzex
==> No binary for macsio-1.1-6x6pqmrjajd57kbzgtwgdz3rpozuwzex found: installing from source
==> Fetching https://spack-llnl-mirror.s3-us-west-2.amazonaws.com/_source-cache/archive/a8/a86249b0f10647c0b631773db69568388094605ec1a0af149d9e61e95e6961ec.tar.gz
################################################################################################ 100.0%
==> macsio: Executing phase: 'cmake'
==> macsio: Executing phase: 'build'
==> macsio: Executing phase: 'install'
[+] /home/spack/spack/opt/spack/linux-ubuntu18.04-x86_64/gcc-7.5.0/macsio-1.1-6x6pqmrjajd57kbzgtwgdz3rpozuwzex
==> Updating view at /home/spack/devel-env/.spack-env/view
==> Updating view at /home/spack/devel-env/.spack-env/view

0 comments on commit c162065

Please sign in to comment.