forked from home-assistant/addons
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
97 lines (93 loc) · 2.7 KB
/
Dockerfile
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
ARG BUILD_FROM
FROM ${BUILD_FROM}
ENV QT_ASSUME_STDERR_HAS_CONSOLE=1
ARG OZW_VERSION
ARG QTMQTT_VERSION
ARG QTOZW_VERSION
ARG QTOZWADMIN_VERSION
ARG QTWEBSOCKETS_VERSION
# Install QT Open Z-Wave
WORKDIR /usr/src
RUN \
apk add --no-cache \
eudev-libs \
fontconfig \
mosquitto \
mosquitto-clients \
openssl \
pwgen \
qt5-qtbase \
qt5-qtremoteobjects \
qt5-qtserialport \
qt5-qtsvg \
rapidjson \
ttf-freefont \
&& apk add --no-cache --repository=http://dl-cdn.alpinelinux.org/alpine/edge/main \
libunwind \
libunwind-dev \
&& apk add --no-cache --repository=http://dl-cdn.alpinelinux.org/alpine/edge/testing \
novnc \
websockify \
&& apk add --no-cache --virtual .build-dependencies \
binutils \
build-base \
cmake \
coreutils \
curl-dev \
eudev-dev \
git \
openssl-dev \
qt5-qtbase-dev \
qt5-qtremoteobjects-dev \
qt5-qtserialport-dev \
qt5-qtsvg-dev \
rapidjson-dev \
\
&& git clone --depth 1 -b \
${QTWEBSOCKETS_VERSION} https://github.com/qt/qtwebsockets /usr/src/qtwebsockets \
&& cd /usr/src/qtwebsockets \
&& /usr/lib/qt5/bin/qmake QT_BUILD_PARTS="libs tools" \
&& make -j $(( $(nproc) + 1 )) \
&& make install \
\
&& git clone --depth 1 -b \
${QTMQTT_VERSION} https://github.com/qt/qtmqtt /usr/src/qtmqtt \
&& cd /usr/src/qtmqtt \
&& /usr/lib/qt5/bin/qmake CONFIG+=release QT_BUILD_PARTS="libs tools" \
&& make -j $(( $(nproc) + 1 )) \
&& make install \
\
&& git clone \
https://github.com/OpenZWave/open-zwave /usr/src/ozw \
&& cd /usr/src/ozw \
&& git checkout ${OZW_VERSION} \
&& make -j $(( $(nproc) + 1 )) \
&& make install \
\
&& git clone \
https://github.com/OpenZWave/qt-openzwave /usr/src/qtozw \
&& cd /usr/src/qtozw \
&& git checkout ${QTOZW_VERSION} \
&& /usr/lib/qt5/bin/qmake -r CONFIG+=release \
&& make -j $(( $(nproc) + 1 )) \
&& make install \
\
&& git clone \
https://github.com/OpenZWave/ozw-admin.git /usr/src/ozw-admin \
&& cd /usr/src/ozw-admin \
&& git checkout ${QTOZWADMIN_VERSION} \
&& /usr/lib/qt5/bin/qmake -r CONFIG+=release \
&& make -j $(( $(nproc) + 1 )) \
&& make install \
\
&& strip --remove-section=.note.ABI-tag /usr/lib/libQt5Core.so \
\
&& mkdir -p /usr/share/OpenZWave \
&& mv /usr/share/qt5/qt-openzwavedatabase.rcc /usr/share/OpenZWave/ \
\
&& apk del --no-cache \
.build-dependencies \
libunwind-dev \
&& rm -rf /usr/src/*
WORKDIR /
COPY rootfs /