# Image to build TOL 4.1 and its .deb on Ubuntu 22.04.  It carries the build
# dependencies and nothing else: the sources and the package area are mounted.
#
# Two entries deserve a note, because both were found the hard way on 2026-09-16:
# libsparsehash-dev is REQUIRED by the engine and was missing from the documented
# recipe, and libatlas-base-dev is deliberately ABSENT -- its cblas.h collides with
# the one GSL pulls in.  See doc/rescue/02-compilar.md.
FROM ubuntu:22.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update -qq && apt-get install -y --no-install-recommends \
      build-essential cmake wget file dpkg-dev lsb-release zip \
      libsparsehash-dev libnlopt-dev libnlopt-cxx-dev coinor-libipopt-dev \
      libgsl-dev liblapacke-dev libsuitesparse-dev libfftw3-dev \
      libboost-thread-dev libboost-system-dev libboost-filesystem-dev \
      libbz2-dev zlib1g-dev libltdl-dev \
      unixodbc-dev libpq-dev libmysqlclient-dev \
      tcl-dev tk-dev tcllib tklib \
      r-cran-rinside \
 && rm -rf /var/lib/apt/lists/*
