rebase docker image to Ubuntu 18.04

This commit is contained in:
Jens Petersen 2019-01-01 23:15:33 +09:00
parent 678d07b2bd
commit 363938a39f
2 changed files with 21 additions and 37 deletions

View File

@ -1,4 +1,4 @@
FROM fpco/pid1:16.04 FROM fpco/pid1:18.04
ENV HOME /home/stackage ENV HOME /home/stackage
ENV LANG en_US.UTF-8 ENV LANG en_US.UTF-8

View File

@ -62,16 +62,16 @@ apt-get install -y \
libfftw3-dev \ libfftw3-dev \
libflac-dev \ libflac-dev \
libfreenect-dev \ libfreenect-dev \
libgd2-xpm-dev \ libgd-dev \
libgeoip-dev \ libgeoip-dev \
libgirepository1.0-dev \ libgirepository1.0-dev \
libglfw3-dev \ libglfw3-dev \
libglib2.0-dev \ libglib2.0-dev \
libglu1-mesa-dev \ libglu1-mesa-dev \
libgmp3-dev \ libgmp3-dev \
libgnutls-dev \ libgnutls28-dev \
libgsasl7-dev \ libgsasl7-dev \
libgsl0-dev \ libgsl-dev \
libgtk-3-dev \ libgtk-3-dev \
libgtk2.0-dev \ libgtk2.0-dev \
libgtksourceview-3.0-dev \ libgtksourceview-3.0-dev \
@ -94,7 +94,7 @@ apt-get install -y \
libmp3lame-dev \ libmp3lame-dev \
libmpfr-dev \ libmpfr-dev \
libmysqlclient-dev \ libmysqlclient-dev \
libncurses-dev \ libncurses5-dev \
libnfc-dev \ libnfc-dev \
liboath-dev \ liboath-dev \
libnotify-dev \ libnotify-dev \
@ -131,15 +131,13 @@ apt-get install -y \
libzip-dev \ libzip-dev \
libzstd-dev \ libzstd-dev \
libzmq3-dev \ libzmq3-dev \
llvm-3.9 \ llvm-6.0 \
locales \ locales \
m4 \ m4 \
minisat \ minisat \
mono-mcs \ mono-mcs \
nettle-dev \ nettle-dev \
ninja-build \ ninja-build \
nodejs \
npm \
openjdk-8-jdk \ openjdk-8-jdk \
python-mpltoolkits.basemap \ python-mpltoolkits.basemap \
python3-matplotlib \ python3-matplotlib \
@ -169,15 +167,9 @@ curl -sSL https://get.haskellstack.org/ | sh
# Put documentation where we expect it # Put documentation where we expect it
mv /opt/ghc/$GHCVER/share/doc/ghc-$GHCVER/ /opt/ghc/$GHCVER/share/doc/ghc mv /opt/ghc/$GHCVER/share/doc/ghc-$GHCVER/ /opt/ghc/$GHCVER/share/doc/ghc
# llvm-5.0 for GHC (separate since it needs wget)
wget -O - http://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - \
&& add-apt-repository "deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-5.0 main" \
&& apt-get update \
&& apt-get install -y llvm-5.0
# llvm-7.0 for llvm-hs (separate since it needs wget) # llvm-7.0 for llvm-hs (separate since it needs wget)
wget -O - http://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - \ wget -O - http://apt.llvm.org/llvm-snapshot.gpg.key | apt-key add - \
&& add-apt-repository "deb http://apt.llvm.org/xenial/ llvm-toolchain-xenial-7 main" \ && add-apt-repository "deb http://apt.llvm.org/bionic/ llvm-toolchain-bionic-7 main" \
&& apt-get update \ && apt-get update \
&& apt-get install -y llvm-7 && apt-get install -y llvm-7
@ -191,14 +183,13 @@ update-alternatives --install "/usr/bin/ld" "ld" "/usr/bin/ld.bfd" 10
# This version is tracked here: # This version is tracked here:
# https://ghc.haskell.org/trac/ghc/wiki/Commentary/Compiler/Backends/LLVM/Installing # https://ghc.haskell.org/trac/ghc/wiki/Commentary/Compiler/Backends/LLVM/Installing
# #
# GHC 8.4 requires LLVM 5.0 tools (specifically, llc-5.0 and opt-5.0). # GHC 8.6 requires LLVM 6.0 tools (specifically, llc-6.0 and opt-6.0).
update-alternatives --install "/usr/bin/llc" "llc" "/usr/bin/llc-5.0" 50 update-alternatives --install "/usr/bin/llc" "llc" "/usr/bin/llc-6.0" 50
update-alternatives --install "/usr/bin/opt" "opt" "/usr/bin/opt-5.0" 50 update-alternatives --install "/usr/bin/opt" "opt" "/usr/bin/opt-6.0" 50
# Made sure a "node" binary is in the path, as well as "nodejs". # nodejs 10 (nodejs8 in bionic needs conflicting libssl10-dev)
# A historical naming collision on Debian means that the binary is called "nodejs", curl -sL https://deb.nodesource.com/setup_10.x | bash -
# but some tools like tsc still expect "node" to exist. apt-get install -y nodejs
ln -s /usr/bin/nodejs /usr/bin/node
# install ocilib dependencies then build and install ocilib # install ocilib dependencies then build and install ocilib
cd /tmp \ cd /tmp \
@ -229,9 +220,9 @@ echo "/usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server/" > /etc/ld.so.conf
# Install erlang/otp platform and its dependencies # Install erlang/otp platform and its dependencies
ERLANG_VERSION="20.2.2" ERLANG_VERSION="20.2.2"
ERLANG_DEB_FILE="esl-erlang_${ERLANG_VERSION}-1~debian~jessie_amd64.deb" ERLANG_DEB_FILE="esl-erlang_21.2-1~ubuntu~bionic_amd64.deb"
pushd /tmp \ pushd /tmp \
&& wget https://packages.erlang-solutions.com/erlang/esl-erlang/FLAVOUR_1_general/${ERLANG_DEB_FILE} \ && wget http://packages.erlang-solutions.com/site/esl/esl-erlang/FLAVOUR_1_general/${ERLANG_DEB_FILE}
&& (dpkg -i ${ERLANG_DEB_FILE}; apt-get install -yf) \ && (dpkg -i ${ERLANG_DEB_FILE}; apt-get install -yf) \
&& rm ${ERLANG_DEB_FILE} \ && rm ${ERLANG_DEB_FILE} \
&& popd && popd
@ -274,12 +265,12 @@ CUDA_VER=10.0
CUDA_APT=10-0 CUDA_APT=10-0
pushd /tmp \ pushd /tmp \
&& wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/cuda-repo-ubuntu1604_${CUDA_PKG}_amd64.deb \ && wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/cuda-repo-ubuntu1804_${CUDA_PKG}_amd64.deb \
&& apt-key adv --fetch-keys http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1604/x86_64/7fa2af80.pub \ && apt-key adv --fetch-keys http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/7fa2af80.pub \
&& dpkg -i cuda-repo-ubuntu1604_${CUDA_PKG}_amd64.deb \ && dpkg -i cuda-repo-ubuntu1804_${CUDA_PKG}_amd64.deb \
&& apt-get update -qq \ && apt-get update -qq \
&& apt-get install -y cuda-drivers cuda-core-${CUDA_APT} cuda-cudart-dev-${CUDA_APT} cuda-cufft-dev-${CUDA_APT} cuda-cublas-dev-${CUDA_APT} cuda-cusparse-dev-${CUDA_APT} cuda-cusolver-dev-${CUDA_APT} \ && apt-get install -y cuda-drivers cuda-core-${CUDA_APT} cuda-cudart-dev-${CUDA_APT} cuda-cufft-dev-${CUDA_APT} cuda-cublas-dev-${CUDA_APT} cuda-cusparse-dev-${CUDA_APT} cuda-cusolver-dev-${CUDA_APT} \
&& rm cuda-repo-ubuntu1604_${CUDA_PKG}_amd64.deb \ && rm cuda-repo-ubuntu1804_${CUDA_PKG}_amd64.deb \
&& export CUDA_PATH=/usr/local/cuda-${CUDA_VER} \ && export CUDA_PATH=/usr/local/cuda-${CUDA_VER} \
&& export LD_LIBRARY_PATH=${CUDA_PATH}/nvvm/lib64:${LD_LIBRARY_PATH+x} \ && export LD_LIBRARY_PATH=${CUDA_PATH}/nvvm/lib64:${LD_LIBRARY_PATH+x} \
&& export LD_LIBRARY_PATH=${CUDA_PATH}/lib64:${LD_LIBRARY_PATH} \ && export LD_LIBRARY_PATH=${CUDA_PATH}/lib64:${LD_LIBRARY_PATH} \
@ -291,15 +282,8 @@ apt-add-repository multiverse \
&& apt-get update \ && apt-get update \
&& apt-get install -y nvidia-cuda-dev && apt-get install -y nvidia-cuda-dev
# newer gcc version for yoga export CLANG_PURE_LLVM_LIB_DIR=/usr/lib/llvm-6.0/lib;
add-apt-repository ppa:ubuntu-toolchain-r/test \ export CLANG_PURE_LLVM_INCLUDE_DIR=/usr/lib/llvm-6.0/include;
&& apt-get update \
&& apt-get install gcc-7 \
&& update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-7 60 --slave /usr/bin/g++ g++ /usr/bin/g++-7
export CLANG_PURE_LLVM_LIB_DIR=/usr/lib/llvm-3.9/lib;
export CLANG_PURE_LLVM_INCLUDE_DIR=/usr/lib/llvm-3.9/include;
# finally run: # finally run:
ldconfig ldconfig