From 578684f208b98d3e37afca96f13926ede777a3dd Mon Sep 17 00:00:00 2001 From: David Beckingsale Date: Tue, 12 Dec 2023 13:56:38 -0800 Subject: [PATCH] Update clang --- scripts/ubuntu/setup.sh | 1 + ubuntu/20.04/Dockerfile | 2 +- ubuntu/22.04/Dockerfile | 22 ++++----------- ubuntu/clang/Dockerfile | 7 ++--- ubuntu/clang/uptodate.yaml | 10 +++---- ubuntu/gcc/Dockerfile | 58 +++++++++++--------------------------- 6 files changed, 31 insertions(+), 69 deletions(-) diff --git a/scripts/ubuntu/setup.sh b/scripts/ubuntu/setup.sh index 7271580..293cab0 100755 --- a/scripts/ubuntu/setup.sh +++ b/scripts/ubuntu/setup.sh @@ -26,6 +26,7 @@ packages=( python3 python3-dev python3-pip + software-properties-common sudo unzip vim-nox diff --git a/ubuntu/20.04/Dockerfile b/ubuntu/20.04/Dockerfile index bc65a66..86cca76 100644 --- a/ubuntu/20.04/Dockerfile +++ b/ubuntu/20.04/Dockerfile @@ -9,4 +9,4 @@ WORKDIR /opt COPY ./scripts /opt/scripts RUN ./scripts/ubuntu/setup.sh && \ - ./scripts/install-cmake-binary.sh \ No newline at end of file + ./scripts/install-cmake-binary.sh diff --git a/ubuntu/22.04/Dockerfile b/ubuntu/22.04/Dockerfile index 43ef034..1e7c08a 100644 --- a/ubuntu/22.04/Dockerfile +++ b/ubuntu/22.04/Dockerfile @@ -1,25 +1,13 @@ -FROM ubuntu:22.04@sha256:8eab65df33a6de2844c9aefd19efe8ddb87b7df5e9185a4ab73af936225685bb +FROM ubuntu:22.04 -LABEL maintainer="@vsoch" +LABEL maintainer="Chris White ,@vsoch,David Beckingsale " -ARG uptodate_github_commit_spack__spack__develop=5351382501e280838d148f15dfd485f2a78667f2 -ENV spack_commit=${uptodate_github_commit_spack__spack__develop} ENV DEBIAN_FRONTEND=noninteractive ENV TZ=America/Los_Angeles -# Add appropriate paths pointing to the view -ENV PATH=/opt/view/bin:/opt/spack/bin:$PATH \ - MANPATH=/opt/view/share/man:$MANPATH \ - PKG_CONFIG_PATH=/opt/view/lib/pkgconfig:/opt/view/lib64/pkgconfig:/opt/view/share/pkgconfig:$PKG_CONFIG_PATH \ - CMAKE_PREFIX_PATH=/opt/view \ - ACLOCAL_PATH=/opt/view/share/aclocal - WORKDIR /opt COPY ./scripts /opt/scripts -# Install spack -RUN ./scripts/ubuntu/apt-install-defaults-plus-args.sh && \ + +RUN ./scripts/ubuntu/setup.sh && \ ./scripts/install-cmake-binary.sh && \ - ./scripts/set-up-spack.sh -# Tell spack to use this one without arguments -# NOTE: this has to be here, setting it earlier will kill spack -ENV SPACK_ENV=/opt/env + add-apt-repository -y ppa:ubuntu-toolchain-r/test diff --git a/ubuntu/clang/Dockerfile b/ubuntu/clang/Dockerfile index 9943e4b..f8b974a 100644 --- a/ubuntu/clang/Dockerfile +++ b/ubuntu/clang/Dockerfile @@ -1,10 +1,9 @@ ARG ubuntu_version -# FROM ghcr.io/llnl/ubuntu:$ubuntu_version -FROM ubuntu-base +FROM ghcr.io/llnl/ubuntu:$ubuntu_version # Install llvm with spack # ARG llvm_version -ENV llvm_version=12 +ENV llvm_version=${llvm_version} RUN \ sudo apt-get -qq update \ @@ -20,4 +19,4 @@ RUN \ && sudo apt-get clean USER radiuss -WORKDIR /home/radiuss \ No newline at end of file +WORKDIR /home/radiuss diff --git a/ubuntu/clang/uptodate.yaml b/ubuntu/clang/uptodate.yaml index 0e6bcfc..63f6167 100644 --- a/ubuntu/clang/uptodate.yaml +++ b/ubuntu/clang/uptodate.yaml @@ -3,8 +3,8 @@ dockerbuild: # Specific combinations of build args to exclude (optional) # Spack doesn't work with 14 nor 15 exclude: - llvm_version: ["14", "15"] - ubuntu_version: ["20.04", "20.04"] + llvm_version: ["13", "14", "15", "10", "11", "12"] + ubuntu_version: ["20.04", "20.04", "20.04", "22.04", "22.04", "22.04"] build_args: llvm_version: @@ -12,13 +12,11 @@ dockerbuild: versions: - "10" - "11" - - "12" + - "12" #20.04 - "13" - "14" - - "15" - - "16" + - "15" #22.04 - # Only support those in spack build cache ubuntu_version: key: ubuntu versions: diff --git a/ubuntu/gcc/Dockerfile b/ubuntu/gcc/Dockerfile index 4c6e0b4..dc778e8 100644 --- a/ubuntu/gcc/Dockerfile +++ b/ubuntu/gcc/Dockerfile @@ -1,44 +1,20 @@ ARG ubuntu_version -FROM ghcr.io/rse-ops/ubuntu:$ubuntu_version - -# Install gcc with spack -ARG gcc_version -ARG JOBS=2 -ENV gcc_version=$gcc_version \ - gcc_spec="gcc@${gcc_version}+bootstrap+strip+binutils languages=c,c++,fortran,lto" \ - COMPILER_NAME=gcc \ - COMPILER_VERSION=$gcc_version \ - CC=/opt/view/bin/gcc \ - CXX=/opt/view/bin/g++ \ - FC=/opt/view/bin/gfortran \ - CPP=/opt/view/bin/cpp - -RUN apt-get -qq update \ - && apt-get -qq install -y --no-install-recommends gawk texinfo \ - && rm -rf /var/lib/apt/lists/* \ - && apt-get clean - -# build compiler and set defaults -# note the IFS to split the spec, spack can't tolerate a single-string spec with -# multiple flags components apparently -RUN spack external find hwloc ncurses gawk texinfo \ - && EXTRA_LANG=$(bash -c "[[ ${gcc_version} > 5 ]] && echo ',jit'" || true) \ - && spack spec --reuse ${gcc_spec}$EXTRA_LANG "^binutils@2.38:" \ - && spack mirror add develop https://binaries.spack.io/releases/develop \ - && spack buildcache keys --install --trust \ - && spack add ${gcc_spec} \ - && spack -v install --jobs $JOBS --deprecated \ - && spack compiler add \ - && spack config add "packages:all:compiler:[${COMPILER_NAME}@${COMPILER_VERSION}]" \ - && update-alternatives --install /usr/bin/cc cc ${CC} 50 \ - && update-alternatives --install /usr/bin/c++ c++ ${CXX} 50 \ - && update-alternatives --install /usr/bin/gcc gcc ${CC} 50 \ - && update-alternatives --install /usr/bin/g++ g++ ${CXX} 50 \ - && update-alternatives --install /usr/bin/gfortran gfortran ${FC} 50 \ - && update-alternatives --install /usr/bin/f77 f77 ${FC} 50 \ - && update-alternatives --install /usr/bin/f95 f95 ${FC} 50 \ - && update-alternatives --install /usr/bin/cpp cpp ${CPP} 50 \ - && update-alternatives --install /usr/bin/c89 c89 ${CC} 50 \ - && update-alternatives --install /usr/bin/c99 c99 ${CC} 50 +#FROM ghcr.io/rse-ops/ubuntu:$ubuntu_version +FROM ubuntu-base +# ARG gcc_version +# ENV gcc_version=$gcc_version +ENV gcc_version=9 +RUN \ + sudo apt-get -qq update \ + && sudo apt-get -qq install -y --no-install-recommends \ + g++-${gcc_version} \ + && sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-${gcc_version} 100 \ + && sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-${gcc_version} 100 \ + && sudo update-alternatives --install /usr/bin/cc cc /usr/bin/gcc-${gcc_version} 100 \ + && sudo update-alternatives --install /usr/bin/c++ c++ /usr/bin/g++-${gcc_version} 100 \ + && sudo rm -rf /var/lib/apt/lists/* \ + && sudo apt-get clean +USER radiuss +WORKDIR /home/radiuss \ No newline at end of file