File: Dockerfile.fedora

package info (click to toggle)
hydrasdr-host 1.1.0-3
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 1,436 kB
  • sloc: ansic: 17,644; sh: 26; xml: 23; makefile: 3
file content (41 lines) | stat: -rw-r--r-- 1,205 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
ARG IMAGE_NAME=fedora
ARG IMAGE_TAG=latest
FROM ${IMAGE_NAME}:${IMAGE_TAG}
LABEL org.opencontainers.image.authors='Daniel Ekman <knegge@gmail.com>'

ARG RHEL
RUN dnf update -y --best --allowerasing &&\
    if [ -n "$RHEL" ]; then \
        dnf install -y epel-release &&\
        dnf config-manager --set-enabled crb || dnf config-manager --set-enabled powertools || true ;\
    fi &&\
    dnf install -y \
        cmake \
        gcc \
        gcc-c++ \
        git \
        gzip \
        libusb1-devel \
        make \
        pkg-config \
        SoapySDR-devel \
        tar

ARG HOST_TOOLS_REF=https://github.com/hydrasdr/hydrasdr-host.git
RUN git clone --depth 1 ${HOST_TOOLS_REF} hydrasdr-host &&\
    cd hydrasdr-host &&\
    cmake -B build \
        -DCMAKE_BUILD_TYPE=Release \
        -DCMAKE_INSTALL_PREFIX=/usr &&\
    cmake --build build --target install

ARG SOAPY_MODULE_REF=https://github.com/hydrasdr/SoapyHydraSDR.git
RUN git clone --depth 1 ${SOAPY_MODULE_REF} soapyhydrasdr &&\
    cd soapyhydrasdr &&\
    cmake -B build \
        -DCMAKE_BUILD_TYPE=Release \
        -DCMAKE_INSTALL_PREFIX=/usr&&\
    cmake --build build --target install

COPY test.sh /
CMD ["bash", "/test.sh"]