Skip to content

Commit

Permalink
fix gcc-runtime behavior by version-naming each compiler
Browse files Browse the repository at this point in the history
  • Loading branch information
trws committed Jan 30, 2024
1 parent cf03ae1 commit 03c4119
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
6 changes: 3 additions & 3 deletions share/spack/spackos-bootstrap/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ clean: stage1/cleanstage stage2/cleanstage stage3/cleanstage stage4/cleanstage
for file in $(TGT_FILES) ; do\
rm -rf $(STAGE)/$${file} ; \
done

SPACK=SPACK_USER_CONFIG_PATH=$(STAGE) spack
SPACK_FLAGS ?=
SPACK=SPACK_USER_CONFIG_PATH=$(STAGE) spack $(SPACK_FLAGS)
stage1/%: STAGE=stage1
stage2/%: STAGE=stage2
stage3/%: STAGE=stage3
Expand Down Expand Up @@ -61,7 +61,7 @@ HOST_COMPILER_PATH=
# was what follows, but then need path modifications, now using compiler path addition to get bison and gawk $$(spack -e $(PREV) find --format '{prefix}' gcc)
echo $(CURDIR)/$(PREV)/.spack-env/view/bin
[ "$(STAGE)" = "stage1" ] || env $(ENV) $(SPACK) compiler find --scope=user $(CURDIR)/$(PREV)/.spack-env/view/bin
# [ "$(STAGE)" = "stage1" ] || sed -i'' -e '/spec:/s/\(@=.*\)/\1.$(PREV)/' $(STAGE)/compilers.yaml
[ "$(STAGE)" = "stage1" ] || sed -i'' -e '/spec:/s/\(@=.*\)/\1.$(PREV)/' $(STAGE)/compilers.yaml
env $(ENV) $(SPACK) compiler find --scope=user $(HOST_COMPILER_PATH)

%/spack.yaml: %/spack.in.yaml
Expand Down
2 changes: 1 addition & 1 deletion share/spack/spackos-bootstrap/stage1/spack.in.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ spack:
- compilers.yaml
specs:
- binutils +stage1
- gcc @13.2.0 +stage1 +binutils ~bootstrap languages=c,c++
- gcc @13.2.0 +stage1 +binutils ~bootstrap languages=c,c++ ~auto_rpath
- gawk
- bison
view: true
Expand Down
4 changes: 2 additions & 2 deletions share/spack/spackos-bootstrap/stage2/spack.in.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spack:
specs:
- glibc
- binutils
- gcc@13.2.0 ~bootstrap ~graphite +binutils
- gcc@13.2.0 ~bootstrap ~graphite +binutils ~auto_rpath
- gmp
# we have no C++ right now, disable
- berkeley-db ~cxx ~stl
Expand All @@ -27,7 +27,7 @@ spack:
- 'target=x86_64_v3,aarch64'
- '~stage1'
- '+stage2'
- '%gcc@=13.2.0'
- '%gcc@=13.2.0.stage1'
linux-headers:
require:
# Still not fond of this, better though
Expand Down
4 changes: 2 additions & 2 deletions share/spack/spackos-bootstrap/stage3/spack.in.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ spack:
specs:
- glibc +stage2
- binutils +gold +lto
- gcc@13.2.0 +binutils +piclibs languages=c,c++,fortran,lto ~bootstrap
- gcc@13.2.0 +binutils +piclibs languages=c,c++,fortran,lto ~bootstrap ~auto_rpath
config:
install_root:
padded_length: 256
Expand All @@ -23,7 +23,7 @@ spack:
- 'target=x86_64_v3,aarch64'
- '~stage1'
- '~stage2'
- '%gcc@=13.2.0'
- '%gcc@=13.2.0.stage2'
glibc:
require:
- +stage2
Expand Down
4 changes: 2 additions & 2 deletions share/spack/spackos-bootstrap/stage4/spack.in.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ spack:
# together, use hash
- glibc +stage2
- binutils +gold +lto
- gcc@13.2.0 +binutils +piclibs ~bootstrap languages=c,c++,fortran,lto
- gcc@13.2.0 +binutils +piclibs ~bootstrap languages=c,c++,fortran,lto +auto_rpath
# base system
- m4
- ncurses
Expand Down Expand Up @@ -61,7 +61,7 @@ spack:
- 'target=x86_64_v3,aarch64'
- '~stage1'
- '~stage2'
- '%gcc@=13.2.0'
- '%gcc@=13.2.0.stage3'
glibc:
require:
- +stage2
Expand Down

0 comments on commit 03c4119

Please sign in to comment.