Browse Source

build: upx latest version

dev
Dnomd343 2 years ago
parent
commit
1dda73669f
  1. 11
      Dockerfile

11
Dockerfile

@ -4,9 +4,14 @@ ARG GOLANG="golang:1.18-alpine3.16"
FROM ${ALPINE} AS upx FROM ${ALPINE} AS upx
RUN apk add build-base cmake RUN apk add build-base cmake
ENV UPX="4.0.0" #ENV UPX="4.0.0"
RUN wget https://github.com/upx/upx/releases/download/v${UPX}/upx-${UPX}-src.tar.xz && tar xf upx-${UPX}-src.tar.xz #RUN wget https://github.com/upx/upx/releases/download/v${UPX}/upx-${UPX}-src.tar.xz && tar xf upx-${UPX}-src.tar.xz
WORKDIR ./upx-${UPX}-src/ RUN apk add git
RUN git clone https://github.com/upx/upx.git
WORKDIR ./upx/
RUN git submodule update --init
RUN rm -rf ./.git/
#WORKDIR ./upx-${UPX}-src/
RUN make UPX_CMAKE_CONFIG_FLAGS=-DCMAKE_EXE_LINKER_FLAGS=-static RUN make UPX_CMAKE_CONFIG_FLAGS=-DCMAKE_EXE_LINKER_FLAGS=-static
WORKDIR ./build/release/ WORKDIR ./build/release/
RUN strip upx && mv upx /tmp/ RUN strip upx && mv upx /tmp/

Loading…
Cancel
Save