# Create a Docker image that is ready to run the full Daikon tests,
# including building the manual and Javadoc.
# But it's used primarily for running miscellaneous tests such as the manual
# and Javadoc.

FROM rockylinux:9
LABEL org.opencontainers.image.authors="Michael Ernst <mernst@cs.washington.edu>"

# According to
# https://docs.docker.com/engine/userguide/eng-image/dockerfile_best-practices/:
#  * Put "apt-get update" and "apt-get install" in the same RUN command.
#  * Do not run "apt-get upgrade"; instead get upstream to update.
RUN dnf -q -y upgrade && dnf -q -y install \
  autoconf \
  automake \
  bc \
  binutils-devel \
  diffutils \
  findutils \
  gcc \
  git \
  m4 \
  make \
  perl-English \
  perl-filetest \
  rsync \
  tar \
  unzip \
  which

# Install the JDK.
RUN dnf -q -y install \
  java-21-openjdk \
  java-21-openjdk-devel

# This enables the repository that contains jq
RUN dnf -q -y install \
  epel-release

RUN dnf -q -y install \
  jq

RUN dnf -q -y install \
  ctags \
  devscripts-checkbashisms \
  gcc-c++ \
  graphviz \
  netpbm \
  netpbm-progs \
  pip \
  python3 \
  python3-distutils-extra \
  ShellCheck \
  texlive \
  wget

# Alternately, run: dnf --enablerepo=crb install PACKAGENAME
RUN dnf config-manager --set-enabled crb \
&& dnf -y install dnf-plugins-core \
&& dnf -y install texinfo texinfo-tex

RUN pip install ruff

RUN dnf -q clean all
