2
2
ARG FROM
3
3
FROM $FROM
4
4
5
- # Build libcap 2.32 targeting armhf
5
+ COPY patch/* /
6
+
7
+ # Build libcap 2.66 targeting armhf
6
8
RUN export DEBIAN_FRONTEND=noninteractive \
7
9
# Install build dependencies
8
10
&& apt-get update -y \
9
11
&& apt-get install -y --no-install-recommends \
10
12
git \
11
13
# Build libcap
12
14
&& cd /root \
13
- && git clone git://git.kernel.org/pub/scm/libs/libcap/libcap.git \
15
+ && git clone --depth 1 --branch libcap-2.66 git://git.kernel.org/pub/scm/libs/libcap/libcap.git \
14
16
&& cd libcap \
15
- && git checkout 13227f9b2f2b2f222e8022e19bd46db6f6f898c6 \
16
- && sed -i "s/^BUILD_GPERF/#\0 /" Make.Rules \
17
17
# Compile binaries that run on the build machine using normal GCC
18
- && sed -i "s/^\( BUILD_CC\) : = \$ (CC)/\1 := gcc/" Make.Rules \
18
+ && sed -i "s/^\( BUILD_CC\) ? = \$ (CC)/\1 := gcc/" Make.Rules \
19
19
&& make \
20
20
AR="${CROSS_COMPILE}ar" \
21
21
CC="${CROSS_COMPILE}gcc" \
@@ -33,7 +33,7 @@ RUN export DEBIAN_FRONTEND=noninteractive \
33
33
&& apt-get clean \
34
34
&& rm -rf /var/lib/apt/lists/* /var/log/dpkg.log /var/log/apt
35
35
36
- # Build util-linux 2.36.1 targeting armhf
36
+ # Build util-linux 2.37.4 targeting armhf
37
37
RUN export DEBIAN_FRONTEND=noninteractive \
38
38
# Install build dependencies
39
39
&& apt-get update -y \
@@ -46,17 +46,16 @@ RUN export DEBIAN_FRONTEND=noninteractive \
46
46
libtool \
47
47
# Build util-linux
48
48
&& cd /root \
49
- && git clone https://github.com/karelzak/util-linux.git \
49
+ && git clone --depth 1 --branch v2.37.4 https://github.com/karelzak/util-linux.git \
50
50
&& cd util-linux \
51
- && git checkout 35c07c82be1ddc3b1c40f061b59008cac6405499 \
52
51
&& ./autogen.sh \
53
52
&& ./configure --host="$CHOST" \
54
53
&& make LDFLAGS="-Wl,-rpath-link,.libs" \
55
54
&& make install DESTDIR="$SYSROOT" \
56
55
&& cd .. \
57
56
# Clean up
58
57
&& rm -rf util-linux \
59
- && find "$SYSROOT" -type l,f -name "*.la" | xargs --no-run-if-empty rm \
58
+ && find "$SYSROOT" -type l,f -name "*.la" -delete \
60
59
&& apt-get autoremove -y \
61
60
automake \
62
61
autopoint \
@@ -67,8 +66,7 @@ RUN export DEBIAN_FRONTEND=noninteractive \
67
66
&& apt-get clean \
68
67
&& rm -rf /var/lib/apt/lists/* /var/log/dpkg.log /var/log/apt
69
68
70
- # Build systemd 244 targeting armhf
71
- COPY patch/*.patch /
69
+ # Build systemd 250 targeting armhf
72
70
RUN export DEBIAN_FRONTEND=noninteractive \
73
71
# Install build dependencies
74
72
&& apt-get update -y \
@@ -78,18 +76,12 @@ RUN export DEBIAN_FRONTEND=noninteractive \
78
76
gperf \
79
77
m4 \
80
78
rsync \
79
+ python3-pip \
80
+ && pip3 install --no-cache-dir --break-system-packages jinja2 \
81
81
# Build systemd
82
82
&& cd /root \
83
- && git clone https://github.com/systemd/systemd.git \
83
+ && git clone --depth 1 --branch v250.5 https://github.com/systemd/systemd.git \
84
84
&& cd systemd \
85
- && git checkout db9c5ae73e23d816e2df2a3e10a9a2a60b5b3ed7 \
86
- # Fix build errors with GCC 10 and -O3
87
- # (see <https://github.com/systemd/systemd/pull/15762>)
88
- && git apply /systemd-244-15762.patch \
89
- # Fix Meson syntax and semantic changes in recent versions
90
- # (see <https://github.com/systemd/systemd/pull/20633>)
91
- && git apply /systemd-244-20633.patch \
92
- && rm /systemd-244-*.patch \
93
85
&& ./configure \
94
86
--buildtype=release \
95
87
--cross-file="$CHOST" \
@@ -103,16 +95,18 @@ RUN export DEBIAN_FRONTEND=noninteractive \
103
95
&& cd .. \
104
96
# Clean up
105
97
&& rm -rf systemd \
98
+ # TODO: remove pip packages as well
106
99
&& apt-get autoremove -y \
107
100
gettext \
108
101
git \
109
102
gperf \
110
103
m4 \
111
104
rsync \
105
+ python3-pip \
112
106
&& apt-get clean \
113
107
&& rm -rf /var/lib/apt/lists/* /var/log/dpkg.log /var/log/apt
114
108
115
- # Build zlib 1.2.11 and libpng 1.6.37 targeting armhf
109
+ # Build zlib 1.2.11 and libpng 1.6.39 targeting armhf
116
110
RUN export DEBIAN_FRONTEND=noninteractive \
117
111
# Install build dependencies
118
112
&& apt-get update -y \
@@ -122,90 +116,85 @@ RUN export DEBIAN_FRONTEND=noninteractive \
122
116
libtool \
123
117
# Build static zlib
124
118
&& cd /root \
125
- && git clone https://github.com/madler/zlib \
119
+ && git clone --depth 1 --branch v1.2.11 https://github.com/madler/zlib \
126
120
&& cd zlib \
127
- && git checkout cacf7f1d4e3d44d871b605da3b647f07d718623f \
128
121
&& CC="${CROSS_COMPILE}gcc" CFLAGS=-fPIC ./configure \
129
122
--static \
130
123
--prefix=/usr \
131
124
&& make \
132
125
&& DESTDIR="$SYSROOT" make install \
133
126
&& cd .. \
134
127
# Build dynamic libpng
135
- && git clone git://git.code.sf.net/p/libpng/code libpng \
128
+ && git clone --depth 1 --branch v1.6.39 git://git.code.sf.net/p/libpng/code libpng \
136
129
&& cd libpng \
137
- && git checkout a40189cf881e9f0db80511c382292a5604c3c3d1 \
138
130
&& ./configure --prefix=/usr --host="$CHOST" \
139
131
&& make \
140
132
&& DESTDIR="$SYSROOT" make install \
141
133
&& cd .. \
142
134
# Clean up
143
135
&& rm -rf zlib libpng \
144
- && find "$SYSROOT" -type l,f -name "*.la" | xargs --no-run-if-empty rm \
136
+ && find "$SYSROOT" -type l,f -name "*.la" -delete \
145
137
&& apt-get autoremove -y \
146
138
automake \
147
139
git \
148
140
libtool \
149
141
&& apt-get clean \
150
142
&& rm -rf /var/lib/apt/lists/* /var/log/dpkg.log /var/log/apt
151
143
152
- # Build libevdev 1.9 .1 targeting armhf
144
+ # Build libevdev 1.12 .1 targeting armhf
153
145
RUN export DEBIAN_FRONTEND=noninteractive \
154
146
# Build libevdev
155
147
&& cd /root \
156
148
&& mkdir libevdev \
157
149
&& cd libevdev \
158
- && curl https://www.freedesktop.org/software/libevdev/libevdev-1.9.1.tar.xz -o libevdev.tar.xz \
159
- && echo "f5603c48c5afd76b14df7a5124e0a94a102f8da0d45826192325069d1bbc7acb libevdev.tar.xz" > sha256sums \
160
- && sha256sum -c sha256sums \
150
+ && curl https://www.freedesktop.org/software/libevdev/libevdev-1.12.1.tar.xz -o libevdev.tar.xz \
151
+ && echo "1dbba41bc516d3ca7abc0da5b862efe3ea8a7018fa6e9b97ce9d39401b22426c libevdev.tar.xz" | sha256sum -c \
161
152
&& tar --strip-components=1 -xf libevdev.tar.xz \
162
- && rm libevdev.tar.xz sha256sums \
153
+ && rm libevdev.tar.xz \
163
154
&& ./configure --prefix=/usr --host="$CHOST" \
164
155
&& make \
165
156
&& DESTDIR="$SYSROOT" make install \
166
157
&& cd .. \
167
158
# Clean up
168
159
&& rm -rf libevdev \
169
- && find "$SYSROOT" -type l,f -name "*.la" | xargs --no-run-if-empty rm
160
+ && find "$SYSROOT" -type l,f -name "*.la" -delete
170
161
171
- # Build OpenSSL 1.1.1g targeting armhf
162
+ # Build OpenSSL 3.0.7 targeting armhf
172
163
RUN export DEBIAN_FRONTEND=noninteractive \
173
164
# Build OpenSSL
174
165
&& cd /root \
175
166
&& mkdir openssl \
176
167
&& cd openssl \
177
- && curl https://www.openssl.org/source/openssl-1.1.1g.tar.gz -o openssl.tar.gz \
178
- && echo "ddb04774f1e32f0c49751e21b67216ac87852ceb056b75209af2443400636d46 openssl.tar.gz" > sha256sums \
179
- && sha256sum -c sha256sums \
168
+ && curl https://www.openssl.org/source/openssl-3.0.7.tar.gz -o openssl.tar.gz \
169
+ && echo "83049d042a260e696f62406ac5c08bf706fd84383f945cf21bd61e9ed95c396e openssl.tar.gz" | sha256sum -c \
180
170
&& tar --strip-components=1 -xf openssl.tar.gz \
181
- && rm openssl.tar.gz sha256sums \
171
+ && rm openssl.tar.gz \
182
172
&& ./Configure --prefix=/usr --cross-compile-prefix="$CROSS_COMPILE" linux-armv4 \
183
173
&& make \
184
174
&& make DESTDIR="$SYSROOT" install_sw \
185
175
&& cd .. \
186
176
# Clean up
187
177
&& rm -rf openssl
188
178
189
- # Build libcurl 7.69.1 targeting armhf
179
+ # Build libcurl 7.82.0 targeting armhf
190
180
RUN export DEBIAN_FRONTEND=noninteractive \
191
181
# Build libcurl
192
182
&& cd /root \
193
183
&& mkdir libcurl \
194
184
&& cd libcurl \
195
- && curl https://curl.se/download/curl-7.69.1.tar.xz -o curl.tar.xz \
196
- && echo "03c7d5e6697f7b7e40ada1b2256e565a555657398e6c1fcfa4cb251ccd819d4f curl.tar.xz" > sha256sums \
197
- && sha256sum -c sha256sums \
185
+ && curl https://curl.se/download/curl-7.82.0.tar.xz -o curl.tar.xz \
186
+ && echo "0aaa12d7bd04b0966254f2703ce80dd5c38dbbd76af0297d3d690cdce58a583c curl.tar.xz" | sha256sum -c \
198
187
&& tar --strip-components=1 -xf curl.tar.xz \
199
- && rm curl.tar.xz sha256sums \
188
+ && rm curl.tar.xz \
200
189
&& ./configure --prefix=/usr --host="$CHOST" --with-openssl \
201
190
&& make \
202
191
&& DESTDIR="$SYSROOT" make install \
203
192
&& cd .. \
204
193
# Clean up
205
194
&& rm -rf libcurl \
206
- && find "$SYSROOT" -type l,f -name "*.la" | xargs --no-run-if-empty rm
195
+ && find "$SYSROOT" -type l,f -name "*.la" -delete
207
196
208
- # Build breakpad 0.1 (db1cda2653 ) targeting armhf
197
+ # Build breakpad 0.1 (216cea7bca ) targeting armhf
209
198
RUN export DEBIAN_FRONTEND=noninteractive \
210
199
# Install build dependencies
211
200
&& apt-get update -y \
@@ -214,23 +203,25 @@ RUN export DEBIAN_FRONTEND=noninteractive \
214
203
zlib1g-dev \
215
204
libssl-dev \
216
205
# breakpad's build tools require python2 to be available as python on the path
217
- && git clone https://github.com/pyenv/pyenv.git .pyenv \
206
+ && cd /root \
207
+ && git clone --depth 1 https://github.com/pyenv/pyenv.git .pyenv \
218
208
&& export PYENV_ROOT="$(pwd)/.pyenv" \
219
209
&& export PATH="$PYENV_ROOT/bin:$PATH" \
220
210
&& eval "$(pyenv init --path)" \
221
211
&& pyenv install 2.7 \
222
212
&& pyenv global 2.7 \
223
213
# Fetch and activate depot_tools
224
- && cd /root \
225
214
&& git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git \
226
215
&& export PATH=$PATH:/root/depot_tools \
227
216
# Build static breakpad
228
- && cd /root \
229
217
&& mkdir breakpad \
230
218
&& cd breakpad \
231
219
&& fetch breakpad \
232
220
&& cd src \
233
- && git checkout db1cda26539c711c3da7ed4d410dfe8190e89b8f \
221
+ # fetch updates default.xml with seemingly useless diffs that break checkout later
222
+ && git checkout HEAD -- default.xml \
223
+ && git checkout 216cea7bca53fa441a3ee0d0f5fd339a3a894224 \
224
+ && git apply < /breakpad-216cea7bca-fix-int-type.patch \
234
225
&& ./configure --prefix=/usr --host="$CHOST" \
235
226
&& make \
236
227
&& DESTDIR="$SYSROOT" make install \
@@ -249,3 +240,5 @@ RUN export DEBIAN_FRONTEND=noninteractive \
249
240
libssl-dev \
250
241
&& apt-get clean \
251
242
&& rm -rf /var/lib/apt/lists/* /var/log/dpkg.log /var/log/apt
243
+
244
+ RUN rm /*.patch
0 commit comments