mirror of
https://github.com/30hours/blah2.git
synced 2024-11-08 12:25:42 +00:00
42 lines
1.6 KiB
Docker
42 lines
1.6 KiB
Docker
# TODO: update devcontainer with vcpkg manifest
|
|
|
|
# ubuntu-22.04 by default
|
|
ARG VARIANT="jammy"
|
|
FROM mcr.microsoft.com/vscode/devcontainers/cpp:0-${VARIANT}
|
|
LABEL maintainer="30hours <nathan@30hours.dev>"
|
|
|
|
ENV DEBIAN_FRONTEND=noninteractive
|
|
|
|
WORKDIR /blah2
|
|
ADD lib lib
|
|
RUN apt-get update && apt-get install -y software-properties-common \
|
|
&& apt-add-repository ppa:ettusresearch/uhd \
|
|
&& apt-get update \
|
|
&& DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get install -y \
|
|
g++ make cmake git curl zip unzip doxygen graphviz \
|
|
libfftw3-dev pkg-config gfortran \
|
|
libuhd-dev=4.6.0.0-0ubuntu1~jammy1 \
|
|
uhd-host=4.6.0.0-0ubuntu1~jammy1 \
|
|
&& apt-get autoremove -y \
|
|
&& apt-get clean -y \
|
|
&& rm -rf /var/lib/apt/lists/*
|
|
|
|
# install dependencies from vcpkg
|
|
RUN git clone https://github.com/microsoft/vcpkg /opt/vcpkg \
|
|
&& /opt/vcpkg/bootstrap-vcpkg.sh
|
|
ENV PATH="/opt/vcpkg:${PATH}" VCPKG_ROOT=/opt/vcpkg
|
|
RUN cd /blah2/lib && vcpkg integrate install \
|
|
&& vcpkg install --clean-after-build
|
|
|
|
# install SDRplay API
|
|
RUN chmod +x /blah2/lib/sdrplay-3.14.0/SDRplay_RSP_API-Linux-3.14.0.run \
|
|
&& /blah2/lib/sdrplay-3.14.0/SDRplay_RSP_API-Linux-3.14.0.run --tar -xvf -C /blah2/lib/sdrplay-3.14.0 \
|
|
&& cp /blah2/lib/sdrplay-3.14.0/x86_64/libsdrplay_api.so.3.14 /usr/local/lib/libsdrplay_api.so \
|
|
&& cp /blah2/lib/sdrplay-3.14.0/x86_64/libsdrplay_api.so.3.14 /usr/local/lib/libsdrplay_api.so.3.14 \
|
|
&& cp /blah2/lib/sdrplay-3.14.0/inc/* /usr/local/include \
|
|
&& chmod 644 /usr/local/lib/libsdrplay_api.so /usr/local/lib/libsdrplay_api.so.3.14 \
|
|
&& ldconfig
|
|
|
|
# install UHD API
|
|
RUN uhd_images_downloader
|
|
|