document why we use find

This commit is contained in:
Emil Lerch 2021-01-06 10:22:41 -08:00
parent febb6e955c
commit a669d9adac
Signed by: lobo
GPG Key ID: A7B62D657EF764F8

View File

@ -39,14 +39,21 @@ COPY etags.py /src/
WORKDIR /src WORKDIR /src
RUN true \ # We use find here because different architectures might be wildly different.
&& pip3 install -r requirements.txt \ # The specific directory is named by the gcc toolchain, which doesn't really
&& pyinstaller -F etags.py \ # line up here with uname -m. As an example, 32 bit arm libraries can be the
&& staticx \ # same across arm versions (arm7/arm8 32 bit)
--strip \ # x86_64: /lib/x86_64-linux-gnu
--no-compress \ # arm64: /lib/aarch64-linux-gnu
-l $(find /lib -name libgcc_s.so.1) \ # arm7: /lib/arm-linux-gnueabihf
dist/etags dist/app \ RUN true \
&& pip3 install -r requirements.txt \
&& pyinstaller -F etags.py \
&& staticx \
--strip \
--no-compress \
-l "$(find /lib -name libgcc_s.so.1 -print -quit)" \
dist/etags dist/app \
&& chmod 755 dist/app && chmod 755 dist/app
FROM scratch FROM scratch