-
Notifications
You must be signed in to change notification settings - Fork 3
/
Containerfile.appimage
251 lines (217 loc) · 11.6 KB
/
Containerfile.appimage
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
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
# Build an environment for creating an AppImage.
# Try to use a distro with an old libc to maximize support on as many linux
# distros as possible for x86_64 and aarch64.
FROM debian:10
ARG ARCH
RUN apt-get -qq -y update && \
apt-get -qq -y dist-upgrade && \
apt-get -qq -y install bison \
bzip2 \
curl \
file \
flex \
gcc \
gnupg2 \
jq \
libcairo2-dev \
libev-dev \
libffi-dev \
libfribidi-dev \
libharfbuzz-dev \
libssl-dev \
libsqlite3-dev \
make \
patch \
wget \
xz-utils \
zlib1g-dev && \
apt-get -qq -y clean && \
apt-get -qq -y autoclean
RUN mkdir -p \
/usr/local/share/licenses/cairo-$(dpkg-query -W -f='${Version}\n' libcairo2) && \
cp -p /usr/share/doc/libcairo2/copyright \
/usr/local/share/licenses/cairo-$(dpkg-query -W -f='${Version}\n' libcairo2)/
RUN mkdir -p \
/usr/local/share/licenses/freetype-$(dpkg-query -W -f='${Version}\n' libfreetype6) && \
cp -p /usr/share/doc/libfreetype6/copyright \
/usr/local/share/licenses/freetype-$(dpkg-query -W -f='${Version}\n' libfreetype6)/
RUN mkdir -p \
/usr/local/share/licenses/fribifi-$(dpkg-query -W -f='${Version}\n' libfribidi0) && \
cp -p /usr/share/doc/libfribidi0/copyright \
/usr/local/share/licenses/fribifi-$(dpkg-query -W -f='${Version}\n' libfribidi0)/
RUN mkdir -p \
/usr/local/share/licenses/graphite2-$(dpkg-query -W -f='${Version}\n' libgraphite2-3) && \
cp -p /usr/share/doc/libgraphite2-3/copyright \
/usr/local/share/licenses/graphite2-$(dpkg-query -W -f='${Version}\n' libgraphite2-3)/
RUN mkdir -p \
/usr/local/share/licenses/harfbuzz-$(dpkg-query -W -f='${Version}\n' libharfbuzz0b) && \
cp -p /usr/share/doc/libharfbuzz0b/copyright \
/usr/local/share/licenses/harfbuzz-$(dpkg-query -W -f='${Version}\n' libharfbuzz0b)/
RUN mkdir -p \
/usr/local/share/licenses/libpng-$(dpkg-query -W -f='${Version}\n' libpng16-16) && \
cp -p /usr/share/doc/libpng16-16/copyright \
/usr/local/share/licenses/libpng-$(dpkg-query -W -f='${Version}\n' libpng16-16)/
RUN mkdir -p \
/usr/local/share/licenses/libau-$(dpkg-query -W -f='${Version}\n' libxau6) && \
cp -p /usr/share/doc/libxau6/copyright \
/usr/local/share/licenses/libau-$(dpkg-query -W -f='${Version}\n' libxau6)/
RUN mkdir -p \
/usr/local/share/licenses/libbsd-$(dpkg-query -W -f='${Version}\n' libbsd0) && \
cp -p /usr/share/doc/libbsd0/copyright \
/usr/local/share/licenses/libbsd-$(dpkg-query -W -f='${Version}\n' libbsd0)/
RUN mkdir -p \
/usr/local/share/licenses/libev-$(dpkg-query -W -f='${Version}\n' libev-dev) && \
cp -p /usr/share/doc/libev-dev/copyright \
/usr/local/share/licenses/libev-$(dpkg-query -W -f='${Version}\n' libev-dev)/
RUN mkdir -p \
/usr/local/share/licenses/libssl1.1-$(dpkg-query -W -f='${Version}\n' libssl1.1) && \
cp -p /usr/share/doc/libssl1.1/copyright \
/usr/local/share/licenses/libssl1.1-$(dpkg-query -W -f='${Version}\n' libssl1.1)/
RUN mkdir -p \
/usr/local/share/licenses/libxcb-$(dpkg-query -W -f='${Version}\n' libxcb-shm0) && \
cp -p /usr/share/doc/libxcb-shm0/copyright \
/usr/local/share/licenses/libxcb-$(dpkg-query -W -f='${Version}\n' libxcb-shm0)/
RUN mkdir -p \
/usr/local/share/licenses/libxext-$(dpkg-query -W -f='${Version}\n' libxext6) && \
cp -p /usr/share/doc/libxext6/copyright \
/usr/local/share/licenses/libxext-$(dpkg-query -W -f='${Version}\n' libxext6)/
RUN mkdir -p \
/usr/local/share/licenses/libxdmcp-$(dpkg-query -W -f='${Version}\n' libxdmcp6) && \
cp -p /usr/share/doc/libxdmcp6/copyright \
/usr/local/share/licenses/libxdmcp-$(dpkg-query -W -f='${Version}\n' libxdmcp6)/
RUN mkdir -p \
/usr/local/share/licenses/libxrender-$(dpkg-query -W -f='${Version}\n' libxrender1) && \
cp -p /usr/share/doc/libxrender1/copyright \
/usr/local/share/licenses/libxrender-$(dpkg-query -W -f='${Version}\n' libxrender1)/
RUN mkdir -p \
/usr/local/share/licenses/pixman-$(dpkg-query -W -f='${Version}\n' libpixman-1-0) && \
cp -p /usr/share/doc/libpixman-1-0/copyright \
/usr/local/share/licenses/pixman-$(dpkg-query -W -f='${Version}\n' libpixman-1-0)/
RUN mkdir -p \
/usr/local/share/licenses/perl-$(dpkg-query -W -f='${Version}\n' perl) && \
cp -p /usr/share/doc/perl/copyright \
/usr/local/share/licenses/perl-$(dpkg-query -W -f='${Version}\n' perl)/
ARG LIBNSLVER="1.3.0"
RUN curl -o /tmp/libnsl-${LIBNSLVER}.tar.xz -SsOL \
https://github.com/thkukuk/libnsl/releases/download/v${LIBNSLVER}/libnsl-${LIBNSLVER}.tar.xz && \
tar -C /usr/local/src -xf /tmp/libnsl-${LIBNSLVER}.tar.xz
WORKDIR /usr/local/src/libnsl-${LIBNSLVER}
# Intentionally install libsnl next to debian 10's distro glibc version.
RUN ./configure --silent --prefix=/usr && \
make -s -j$(nproc) && \
make -s install && \
ln -sf /usr/lib/libnsl.so.2 /usr/lib/x86_64-linux-gnu/libnsl.so
RUN mkdir -p /usr/local/share/licenses/libnsl-${LIBNSLVER} && \
cp -p COPYING /usr/local/share/licenses/libnsl-${LIBNSLVER}/
ARG PYTHONMMVER="3.11"
ARG PYTHONVER="${PYTHONMMVER}.1"
RUN curl -o /tmp/Python-${PYTHONVER}.tgz -SsOL \
https://www.python.org/ftp/python/${PYTHONVER}/Python-${PYTHONVER}.tgz && \
tar -C /usr/local/src -xf /tmp/Python-${PYTHONVER}.tgz
WORKDIR /usr/local/src/Python-${PYTHONVER}
RUN ./configure --silent --prefix=/usr/local && \
make -s -j$(nproc) && \
make -s install
RUN mkdir -p /usr/local/AppDir/lib && \
cp -pr /usr/local/lib/python${PYTHONMMVER} /usr/local/AppDir/lib
RUN mkdir -p /usr/local/share/licenses/python-${PYTHONVER} && \
cp -p LICENSE /usr/local/share/licenses/python-${PYTHONVER}/
ARG DOCUTILSVER="0.21.2"
RUN /usr/local/bin/pip3 install docutils==${DOCUTILSVER}
RUN mkdir -p /usr/local/share/licenses/docutils-${DOCUTILSVER} && \
cp -p \
/usr/local/lib/python${PYTHONMMVER}/site-packages/docutils-${DOCUTILSVER}.dist-info/COPYING.txt \
/usr/local/share/licenses/docutils-${DOCUTILSVER}/
# PostgreSQL 11 is the first release creating the pg_type_d.h include file for
# CockroachDB binary support.
ARG PGVER="11.22"
RUN wget -O /tmp/postgresql-${PGVER}.tar.bz2 -q --no-check-certificate \
https://ftp.postgresql.org/pub/source/v${PGVER}/postgresql-${PGVER}.tar.bz2 && \
tar -C /usr/local/src -xf /tmp/postgresql-${PGVER}.tar.bz2
WORKDIR /usr/local/src/postgresql-${PGVER}
RUN ./configure --silent --without-ldap --without-readline --without-zlib \
--without-gssapi --with-openssl --prefix=/usr && \
make -s -j $(nproc) install && \
ldconfig
RUN mkdir -p /usr/local/share/licenses/postgresql-${PGVER} && \
cp -p COPYRIGHT /usr/local/share/licenses/postgresql-${PGVER}/
ARG CMAKEVER="3.7.2"
RUN curl -o /tmp/cmake-${CMAKEVER}-linux-${ARCH}.tar.gz -SsOL \
https://github.com/Kitware/CMake/releases/download/v${CMAKEVER}/cmake-${CMAKEVER}-linux-${ARCH}.tar.gz && \
tar -C /usr --strip-components=1 \
-xf /tmp/cmake-${CMAKEVER}-linux-${ARCH}.tar.gz
# Install DBT Tools
ARG DBTTOOLSVER="0.5.1"
RUN curl -o /tmp/v${DBTTOOLSVER}.tar.gz -SsOL \
https://github.com/osdldbt/dbttools/archive/refs/tags/v${DBTTOOLSVER}.tar.gz && \
tar -C /usr/local/src -xf /tmp/v${DBTTOOLSVER}.tar.gz
WORKDIR /usr/local/src/dbttools-${DBTTOOLSVER}
RUN cmake -H. -Bbuilds/release -DCMAKE_INSTALL_PREFIX=/usr && \
(cd builds/release && make -s install) && \
rm -f /tmp/v${DBTTOOLSVER}.tar.gz
RUN mkdir -p /usr/local/share/licenses/dbttools-${DBTTOOLSVER} && \
cp -p LICENSE /usr/local/share/licenses/dbttools-${DBTTOOLSVER}/
ARG SQLITE3VER=3410200
RUN wget -O /tmp/sqlite-autoconf-${SQLITE3VER}.tar.gz -q \
--no-check-certificate \
https://www.sqlite.org/2023/sqlite-autoconf-${SQLITE3VER}.tar.gz && \
tar -C /usr/local/src -xf /tmp/sqlite-autoconf-${SQLITE3VER}.tar.gz
WORKDIR /usr/local/src/sqlite-autoconf-${SQLITE3VER}
RUN ./configure --quiet --silent --prefix=/usr/local && \
make -s -j $(nproc) install
RUN mkdir -p /usr/local/share/licenses/sqlite-autoconf-${SQLITE3VER} && \
cp -p tea/license.terms \
/usr/local/share/licenses/sqlite-autoconf-${SQLITE3VER}/
ARG PANGOVER="1.42"
ARG PANGOMINORVER="4"
RUN curl -o /tmp/pango-${PANGOVER}.${PANGOMINORVER}.tar.xz -SsOL \
https://download.gnome.org/sources/pango/${PANGOVER}/pango-${PANGOVER}.${PANGOMINORVER}.tar.xz && \
tar -C /usr/local/src -xf /tmp/pango-${PANGOVER}.${PANGOMINORVER}.tar.xz
WORKDIR /usr/local/src/pango-${PANGOVER}.${PANGOMINORVER}
RUN ./configure --quiet --silent --prefix=/usr/local && \
make -s -j $(nproc) install && \
ldconfig
RUN mkdir -p /usr/local/share/licenses/pango-${PANGOVER}.${PANGOMINORVER} && \
cp -p COPYING /usr/local/share/licenses/pango-${PANGOVER}.${PANGOMINORVER}/
ARG GNUPLOTVER="5.4.6"
RUN wget -O /tmp/gnuplot-${GNUPLOTVER}.tar.gz -q --no-check-certificate \
https://sourceforge.net/projects/gnuplot/files/gnuplot/5.4.6/gnuplot-5.4.6.tar.gz/download && \
tar -C /usr/local/src -xf /tmp/gnuplot-${GNUPLOTVER}.tar.gz
WORKDIR /usr/local/src/gnuplot-${GNUPLOTVER}
RUN ./configure -q --prefix=/usr/local --without-libcerf \
--without-latex --without-readline --without-lua \
--without-tektronix --with-qt=no --disable-history-file \
--disable-x11-external --disable-raise-console \
--disable-wxwidgets --disable-plugins \
--disable-dependency-tracking && \
make -s -j$(nproc) install
RUN mkdir -p /usr/local/share/licenses/gnuplot-${GNUPLOTVER} && \
cp -p Copyright README /usr/local/share/licenses/gnuplot-${GNUPLOTVER}/
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs \
-o /tmp/sh.rustup.sh && \
sh /tmp/sh.rustup.sh -y
ARG TSTOOLSVER="0.9.1"
RUN curl -o /tmp/touchstone-tools-v${TSTOOLSVER}.tar.gz -SsOL \
https://gitlab.com/touchstone/touchstone-tools/-/archive/v${TSTOOLSVER}/touchstone-tools-v{TSTOOLSVER}.tar.gz && \
mkdir -p /usr/local/src/touchstone-tools-v${TSTOOLSVER} && \
tar -C /usr/local/src/touchstone-tools-v${TSTOOLSVER} \
--strip-components=1 \
-xf /tmp/touchstone-tools-v${TSTOOLSVER}.tar.gz
WORKDIR /usr/local/src/touchstone-tools-v${TSTOOLSVER}
RUN cmake -H. -Bbuilds/release -DCMAKE_INSTALL_PREFIX=/usr && \
(cd builds/release && make -s install) && \
(cd spar && ${HOME}/.cargo/bin/cargo install --root /usr/local --path .) && \
rm -f /tmp/touchstone-tools-v${TSTOOLSVER}.tar.gz
RUN mkdir -p /usr/local/share/licenses/touchstone-tools-v${TSTOOLSVER} && \
cp -p COPYRIGHT /usr/local/share/licenses/touchstone-tools-v${TSTOOLSVER}/
ARG TOMLCLIVER="0.2.3"
RUN ${HOME}/.cargo/bin/cargo install --version ${TOMLCLIVER} \
--root /usr/local toml-cli
RUN mkdir -p /usr/local/share/licenses/toml-cli-${TOMLCLIVER} && \
curl -o /usr/local/share/licenses/toml-cli-${TOMLCLIVER}/LICENSE -SsOL \
https://github.com/gnprice/toml-cli/raw/v${TOMLCLIVER}/LICENSE
WORKDIR /usr/local
RUN curl -SsOL \
https://github.com/AppImage/AppImageKit/releases/download/13/appimagetool-${ARCH}.AppImage && \
chmod +x appimagetool-${ARCH}.AppImage && \
./appimagetool-${ARCH}.AppImage --appimage-extract