From bfdc8f494ae8f7b65f011f802fc316f179b6b398 Mon Sep 17 00:00:00 2001 From: takeshix <takeshix@adversec.com> Date: Mon, 19 Apr 2021 18:14:46 +0200 Subject: [PATCH 01/22] Updated README.md --- README.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 2c0a061..c9666c4 100644 --- a/README.md +++ b/README.md @@ -4,12 +4,13 @@ This repository includes prebuild static binaries and build-recipes for various The Linux versions are compiled with the musl-cross toolchain and the openssl-pm-snapshot fork of OpenSSL in order to support a wide range of SSL/TLS features (Warning: some of them are insecure!). -Compilation is done automatically with GitHub Actions. - -## Current Limitations +Compilation is done automatically with GitHub Actions. The binaries are uploaded to the [release section](https://github.com/ernw/static-toolbox/releases). The artifacts are also available in the artifacts of each GitHub Action. However, there are some limitations: * Downloading of build artifacts in GitHub Ations currently requires a GitHub account * Blobs in build artifacts are zipped by the GitHub frontend by default, even zip files themselves! Build artifact zips may contain other zip files. +* Build artifacts will expire after some time. + +Therefore, it is recommended to download the binaries from the release section. ## Building Status From dc233d4f74afc6f2cc0a0277f0bbc8eb1ab0a7a3 Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 11:22:07 +0200 Subject: [PATCH 02/22] Bumped OpenSSH to V_9_1_P1 --- build/targets/build_openssh.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/targets/build_openssh.sh b/build/targets/build_openssh.sh index e9ba48e..f8cebee 100755 --- a/build/targets/build_openssh.sh +++ b/build/targets/build_openssh.sh @@ -17,7 +17,7 @@ init_lib $1 build_openssh() { fetch "https://github.com/openssh/openssh-portable.git" "${BUILD_DIRECTORY}/openssh-portable" git cd "${BUILD_DIRECTORY}/openssh-portable" - git checkout V_8_6_P1 + git checkout V_9_1_P1 git clean -fdx autoreconf -i CC="gcc ${GCC_OPTS}" \ From c613b77803463bd326dae2a658dbd4a420eb4d70 Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 12:21:05 +0200 Subject: [PATCH 03/22] Bumped gdb to gdb-12.1-release --- build/targets/build_gdb.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/build/targets/build_gdb.sh b/build/targets/build_gdb.sh index 916d74b..2d00027 100755 --- a/build/targets/build_gdb.sh +++ b/build/targets/build_gdb.sh @@ -18,8 +18,7 @@ build_gdb() { fetch "$GIT_BINUTILS_GDB" "${BUILD_DIRECTORY}/binutils-gdb" git cd "${BUILD_DIRECTORY}/binutils-gdb/" || { echo "Cannot cd to ${BUILD_DIRECTORY}/binutils-gdb/"; exit 1; } git clean -fdx - git checkout gdb-10.1-release - + git checkout gdb-12.1-release CMD="CFLAGS=\"${GCC_OPTS}\" " CMD+="CXXFLAGS=\"${GXX_OPTS}\" " CMD+="LDFLAGS=\"-static\" " From 1431466df094f89c4d15c44bf10d0310e5f325c3 Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 12:42:20 +0200 Subject: [PATCH 04/22] Updated Nmap release creation --- .github/workflows/build-nmap.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build-nmap.yml b/.github/workflows/build-nmap.yml index 93e1188..b9823ca 100644 --- a/.github/workflows/build-nmap.yml +++ b/.github/workflows/build-nmap.yml @@ -147,10 +147,12 @@ jobs: - name: Tag Release run: | set +e - if git rev-list "nmap-v${{ needs.build-x86.outputs.version }}".. >/dev/null;then + git fetch --quiet --prune --unshallow --tags + if [[ $(git tag -l | grep nmap-v${{ needs.build-x86.outputs.version }} | wc -l) -gt 0 ]]; then echo "Tag for nmap-v${{ needs.build-x86.outputs.version }} already exists. Skipping release creation." echo ::set-output name=NEW_RELEASE::"false" else + echo "Tag for nmap-v${{ needs.build-x86.outputs.version }} missing. Starting release creation." git tag "nmap-v${{ needs.build-x86.outputs.version }}" git push origin "nmap-v${{ needs.build-x86.outputs.version }}" echo ::set-output name=NEW_RELEASE::"true" From ecf0f96df9ef12eec2e92b5379bcc1ccbc8840f5 Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 12:43:36 +0200 Subject: [PATCH 05/22] Updated install build compiler script --- build/02_install_build_compiler.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build/02_install_build_compiler.sh b/build/02_install_build_compiler.sh index 15cb8c3..7e6fd97 100755 --- a/build/02_install_build_compiler.sh +++ b/build/02_install_build_compiler.sh @@ -3,7 +3,7 @@ if [ $# -ne 1 ];then echo "Missing arch" exit 1 fi -ARCH="${1,,}" +ARCH="${1}" case $ARCH in x86_64|i686|aarch64) ARCH="${ARCH}-linux-musl" From 04a22777912d86df30ab730e6c482c8921b57088 Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 12:49:27 +0200 Subject: [PATCH 06/22] Updated install build compiler script --- build/02_install_build_compiler.sh | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/build/02_install_build_compiler.sh b/build/02_install_build_compiler.sh index 7e6fd97..bb70c9e 100755 --- a/build/02_install_build_compiler.sh +++ b/build/02_install_build_compiler.sh @@ -1,4 +1,10 @@ #!/bin/bash + +function die(){ + echo "$1" + exit 1 +} + if [ $# -ne 1 ];then echo "Missing arch" exit 1 @@ -20,7 +26,8 @@ case $ARCH in ;; esac HOST=http://musl.cc +echo "Fetching ${HOST}/${ARCH}-cross.tgz" cd / -curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz -tar -xf ${ARCH}-cross.tgz -rm ${ARCH}-cross.tgz \ No newline at end of file +curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz || die "Failed to download build compiler package" +tar -xf ${ARCH}-cross.tgz || die "Failed to extract build compiler package" +rm ${ARCH}-cross.tgz || die "Failed to remove build compiler package" \ No newline at end of file From 5d920d97ab5c80ab1dd93b9051f925d5f4bbf040 Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 12:59:56 +0200 Subject: [PATCH 07/22] Updated Nmap release creation --- .github/workflows/build-nmap.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-nmap.yml b/.github/workflows/build-nmap.yml index b9823ca..d79a2f9 100644 --- a/.github/workflows/build-nmap.yml +++ b/.github/workflows/build-nmap.yml @@ -147,7 +147,7 @@ jobs: - name: Tag Release run: | set +e - git fetch --quiet --prune --unshallow --tags + git fetch --quiet --prune --tags if [[ $(git tag -l | grep nmap-v${{ needs.build-x86.outputs.version }} | wc -l) -gt 0 ]]; then echo "Tag for nmap-v${{ needs.build-x86.outputs.version }} already exists. Skipping release creation." echo ::set-output name=NEW_RELEASE::"false" From 676eeb8f454eeab8207bb25b53453b43a389b4c5 Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 13:14:00 +0200 Subject: [PATCH 08/22] Updated Nmap release creation --- .github/workflows/build-nmap.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build-nmap.yml b/.github/workflows/build-nmap.yml index d79a2f9..bd6832d 100644 --- a/.github/workflows/build-nmap.yml +++ b/.github/workflows/build-nmap.yml @@ -145,6 +145,7 @@ jobs: run: ls -laR /tmp/releases - name: Tag Release + id: tag_release run: | set +e git fetch --quiet --prune --tags From a1cd885edc002e6ff8ca8a5f6831a07ae1786aa6 Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 16:35:44 +0200 Subject: [PATCH 09/22] Updated workflow links --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index c9666c4..ba52d22 100644 --- a/README.md +++ b/README.md @@ -23,9 +23,9 @@ The following table shows the building status for the current toolset. The follo | Tool | Status | | ---- | ------ | -|[Nmap](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22Nmap%22)|| -|[OpenSSH](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22OpenSSH%22)|| -|[socat](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22socat%22)|| -|[GDB & gdbserver](https://github.com/ernw/static-toolbox/actions?query=workflow%3AGDB)|| -|[tcpdump](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22tcpdump%22)|| +|[Nmap](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22Nmap%22)|| +|[OpenSSH](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22OpenSSH%22)|| +|[socat](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22socat%22)|| +|[GDB & gdbserver](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3AGDB)|| +|[tcpdump](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22tcpdump%22)|| From bd887fa3fcae79d12f1232716b4b002ac333ffbf Mon Sep 17 00:00:00 2001 From: Niklaus Schiess <najsc@amazon.com> Date: Wed, 5 Oct 2022 16:39:04 +0200 Subject: [PATCH 10/22] Updated workflow links --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index ba52d22..fff326a 100644 --- a/README.md +++ b/README.md @@ -23,9 +23,9 @@ The following table shows the building status for the current toolset. The follo | Tool | Status | | ---- | ------ | -|[Nmap](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22Nmap%22)|| -|[OpenSSH](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22OpenSSH%22)|| -|[socat](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22socat%22)|| -|[GDB & gdbserver](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3AGDB)|| -|[tcpdump](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22tcpdump%22)|| +|[Nmap](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22Nmap%22)|| +|[OpenSSH](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22OpenSSH%22)|| +|[socat](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22socat%22)|| +|[GDB & gdbserver](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3AGDB)|| +|[tcpdump](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22tcpdump%22)|| From 9a8f7c9e1a64cbb1007a9d6f5d3aaff1c9618319 Mon Sep 17 00:00:00 2001 From: hnzlmnn-ernw <83819013+hnzlmnn-ernw@users.noreply.github.com> Date: Thu, 9 Mar 2023 15:43:14 +0100 Subject: [PATCH 11/22] Update README.md --- README.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index fff326a..c9666c4 100644 --- a/README.md +++ b/README.md @@ -23,9 +23,9 @@ The following table shows the building status for the current toolset. The follo | Tool | Status | | ---- | ------ | -|[Nmap](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22Nmap%22)|| -|[OpenSSH](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22OpenSSH%22)|| -|[socat](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22socat%22)|| -|[GDB & gdbserver](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3AGDB)|| -|[tcpdump](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22tcpdump%22)|| +|[Nmap](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22Nmap%22)|| +|[OpenSSH](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22OpenSSH%22)|| +|[socat](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22socat%22)|| +|[GDB & gdbserver](https://github.com/ernw/static-toolbox/actions?query=workflow%3AGDB)|| +|[tcpdump](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22tcpdump%22)|| From b34b0980ef4f838f374bc85ed98f439166f59917 Mon Sep 17 00:00:00 2001 From: Dennis Heinze <ttdennis@users.noreply.github.com> Date: Tue, 16 May 2023 09:29:08 +0200 Subject: [PATCH 12/22] Start strace --- .github/workflows/build-strace.yml | 158 +++++++++++++++++++++++++++++ 1 file changed, 158 insertions(+) create mode 100644 .github/workflows/build-strace.yml diff --git a/.github/workflows/build-strace.yml b/.github/workflows/build-strace.yml new file mode 100644 index 0000000..f9b19c8 --- /dev/null +++ b/.github/workflows/build-strace.yml @@ -0,0 +1,158 @@ +name: strace +on: + workflow_dispatch +jobs: + build-x86: + name: Build strace x86 + runs-on: ubuntu-latest + container: muslcc/x86_64:i686-linux-musl + outputs: + version: ${{ steps.build_strace.outputs.PACKAGED_VERSION }} + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install dependencies + run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh + + - name: Install testing dependencies + run: apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing yodl + + - name: Build strace + id: build_strace + run: $GITHUB_WORKSPACE/build/targets/build_strace.sh x86 + + - name: Upload artifacts + uses: actions/upload-artifact@v2 + with: + name: ${{ steps.build_strace.outputs.PACKAGED_NAME }} + path: ${{ steps.build_strace.outputs.PACKAGED_NAME_PATH }} + + build-x86_64: + name: Build strace x86_64 + runs-on: ubuntu-latest + container: muslcc/x86_64:x86_64-linux-musl + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install dependencies + run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh + + - name: Install testing dependencies + run: apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing yodl + + - name: Build strace + id: build_strace + run: $GITHUB_WORKSPACE/build/targets/build_strace.sh x86_64 + + - name: Upload artifacts + uses: actions/upload-artifact@v2 + with: + name: ${{ steps.build_strace.outputs.PACKAGED_NAME }} + path: ${{ steps.build_strace.outputs.PACKAGED_NAME_PATH }} + + build-armhf: + name: Build strace ARMHF + runs-on: ubuntu-latest + container: muslcc/x86_64:arm-linux-musleabihf + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install dependencies + run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh + + - name: Install testing dependencies + run: apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing yodl + + - name: Install build compiler + run: /bin/sh -c "apk update && apk upgrade && apk add --no-cache curl rsync sudo util-linux && cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross" + env: + ARCH: x86_64-linux-musl + HOST: http://musl.cc/ + TEMP: /tmp + USER: 0 + + - name: Build strace + id: build_strace + run: $GITHUB_WORKSPACE/build/targets/build_strace.sh armhf + + - name: Upload artifacts + uses: actions/upload-artifact@v2 + with: + name: ${{ steps.build_strace.outputs.PACKAGED_NAME }} + path: ${{ steps.build_strace.outputs.PACKAGED_NAME_PATH }} + + build-aarch64: + name: Build strace AARCH64 + runs-on: ubuntu-latest + container: muslcc/x86_64:aarch64-linux-musl + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install dependencies + run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh + + - name: Install testing dependencies + run: apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing yodl + + - name: Install build compiler + run: /bin/sh -c "apk update && apk upgrade && apk add --no-cache curl rsync sudo util-linux && cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross" + env: + ARCH: x86_64-linux-musl + HOST: http://musl.cc/ + TEMP: /tmp + USER: 0 + + - name: Build strace + id: build_strace + run: $GITHUB_WORKSPACE/build/targets/build_strace.sh aarch64 + + - name: Upload artifacts + uses: actions/upload-artifact@v2 + with: + name: ${{ steps.build_strace.outputs.PACKAGED_NAME }} + path: ${{ steps.build_strace.outputs.PACKAGED_NAME_PATH }} + + create-release: + name: Create strace Release + runs-on: ubuntu-latest + needs: [build-x86, build-x86_64, build-armhf, build-aarch64] + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Prepare Environment + run: mkdir /tmp/releases + + - name: Download Artifacts + uses: actions/download-artifact@v2 + with: + path: /tmp/releases + + - name: List Artifacts + run: ls -laR /tmp/releases + + - name: Tag Release + id: tag_release + run: | + set +e + if git rev-list "strace-v${{ needs.build-x86.outputs.version }}".. >/dev/null;then + echo "Tag for strace-v${{ needs.build-x86.outputs.version }} already exists. Skipping release creation." + echo ::set-output name=NEW_RELEASE::"false" + else + git tag "strace-v${{ needs.build-x86.outputs.version }}" + git push origin "strace-v${{ needs.build-x86.outputs.version }}" + echo ::set-output name=NEW_RELEASE::"true" + fi + + - name: Create Release + uses: ncipollo/release-action@v1 + if: ${{ steps.tag_release.outputs.NEW_RELEASE == 'true' }} + with: + name: strace-v${{ needs.build-x86.outputs.version }} + tag: strace-v${{ needs.build-x86.outputs.version }} + artifacts: "/tmp/releases/*/*" + token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From 735d28224efda0bc465cd9060dffab731364c315 Mon Sep 17 00:00:00 2001 From: Dennis Heinze <ttdennis@users.noreply.github.com> Date: Tue, 16 May 2023 09:51:29 +0200 Subject: [PATCH 13/22] Finish strace build --- .github/workflows/build-strace.yml | 12 +++++++++++- build/targets/build_strace.sh | 21 +++++++++++++-------- 2 files changed, 24 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build-strace.yml b/.github/workflows/build-strace.yml index f9b19c8..4d1192e 100644 --- a/.github/workflows/build-strace.yml +++ b/.github/workflows/build-strace.yml @@ -1,6 +1,8 @@ name: strace on: - workflow_dispatch + push: + branches: + - strace jobs: build-x86: name: Build strace x86 @@ -18,6 +20,14 @@ jobs: - name: Install testing dependencies run: apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing yodl + - name: Install build compiler + run: /bin/sh -c "apk update && apk upgrade && apk add --no-cache curl rsync sudo util-linux && cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross" + env: + ARCH: x86_64-linux-musl + HOST: http://musl.cc/ + TEMP: /tmp + USER: 0 + - name: Build strace id: build_strace run: $GITHUB_WORKSPACE/build/targets/build_strace.sh x86 diff --git a/build/targets/build_strace.sh b/build/targets/build_strace.sh index 9b9c442..16fe54d 100755 --- a/build/targets/build_strace.sh +++ b/build/targets/build_strace.sh @@ -10,34 +10,39 @@ fi source $GITHUB_WORKSPACE/build/lib.sh init_lib "$1" +VERSION="v6.3" + build_strace() { fetch "https://github.com/strace/strace" "${BUILD_DIRECTORY}/strace" git cd "${BUILD_DIRECTORY}/strace" git clean -fdx - git checkout v5.7 + git checkout "$VERSION" ./bootstrap CMD="CFLAGS=\"${GCC_OPTS}\" " CMD+="CXXFLAGS=\"${GXX_OPTS}\" " CMD+="LDFLAGS=\"-static -pthread\" " - if [ "$CURRENT_ARCH" != "x86" ] && [ "$CURRENT_ARCH" != "x86_64" ];then - CMD+="CC_FOR_BUILD=\"/i686-linux-musl-cross/bin/i686-linux-musl-gcc\" " - CMD+="CPP_FOR_BUILD=\"/i686-linux-musl-cross/bin/i686-linux-musl-g++\" " + if [ "$CURRENT_ARCH" != "x86_64" ];then + CMD+="CC_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-gcc\" " + CMD+="CPP_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-g++ -E\" " + CMD+="CXX_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-g++ -E\" " fi - CMD+="./configure --host=i486-linux-musl --target=$(get_host_triple)" + CMD+="./configure --disable-mpers --host=$(get_host_triple)" eval "$CMD" make CFLAGS="-w" -j4 - strip strace + strip "${BUILD_DIRECTORY}/strace/src/strace" } main() { build_strace local version - version=$(get_version "${BUILD_DIRECTORY}/strace/strace --version 2>&1 | head -n1 | awk '{print \$4}'") - cp "${BUILD_DIRECTORY}/strace/strace" "${OUTPUT_DIRECTORY}/strace" + version=$(get_version "${BUILD_DIRECTORY}/strace/src/strace -V 2>&1 | head -n1 | awk '{print \$4}'") + version_number=$(echo "$version" | cut -d"-" -f2) + cp "${BUILD_DIRECTORY}/strace/src/strace" "${OUTPUT_DIRECTORY}/strace${version}" echo "[+] Finished building strace ${CURRENT_ARCH}" echo ::set-output name=PACKAGED_NAME::"strace${version}" echo ::set-output name=PACKAGED_NAME_PATH::"${OUTPUT_DIRECTORY}/*" + echo ::set-output name=PACKAGED_VERSION::"${version_number}" } main From 20ee0f7d17e0849a80ade3fc2d6deaf2a1a1d987 Mon Sep 17 00:00:00 2001 From: Dennis Heinze <ttdennis@users.noreply.github.com> Date: Fri, 19 May 2023 11:38:41 +0200 Subject: [PATCH 14/22] Clean + workflow dispatch --- .github/workflows/build-strace.yml | 4 +--- build/targets/build_strace.sh | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-strace.yml b/.github/workflows/build-strace.yml index 4d1192e..df90b2f 100644 --- a/.github/workflows/build-strace.yml +++ b/.github/workflows/build-strace.yml @@ -1,8 +1,6 @@ name: strace on: - push: - branches: - - strace + workflow_dispatch jobs: build-x86: name: Build strace x86 diff --git a/build/targets/build_strace.sh b/build/targets/build_strace.sh index 16fe54d..5853c98 100755 --- a/build/targets/build_strace.sh +++ b/build/targets/build_strace.sh @@ -24,7 +24,7 @@ build_strace() { if [ "$CURRENT_ARCH" != "x86_64" ];then CMD+="CC_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-gcc\" " CMD+="CPP_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-g++ -E\" " - CMD+="CXX_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-g++ -E\" " + CMD+="CXX_FOR_BUILD=\"/x86_64-linux-musl-cross/bin/x86_64-linux-musl-g++\" " fi CMD+="./configure --disable-mpers --host=$(get_host_triple)" eval "$CMD" From 98edf482f8536b3990ed25e951862d0c779c5158 Mon Sep 17 00:00:00 2001 From: Dennis Heinze <ttdennis@users.noreply.github.com> Date: Fri, 19 May 2023 12:14:58 +0200 Subject: [PATCH 15/22] Fix deprecated set-output --- .github/workflows/build-strace.yml | 4 ++-- build/targets/build_strace.sh | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-strace.yml b/.github/workflows/build-strace.yml index df90b2f..c5a426a 100644 --- a/.github/workflows/build-strace.yml +++ b/.github/workflows/build-strace.yml @@ -149,11 +149,11 @@ jobs: set +e if git rev-list "strace-v${{ needs.build-x86.outputs.version }}".. >/dev/null;then echo "Tag for strace-v${{ needs.build-x86.outputs.version }} already exists. Skipping release creation." - echo ::set-output name=NEW_RELEASE::"false" + echo "NEW_RELEASE=false" >> $GITHUB_OUTPUT else git tag "strace-v${{ needs.build-x86.outputs.version }}" git push origin "strace-v${{ needs.build-x86.outputs.version }}" - echo ::set-output name=NEW_RELEASE::"true" + echo "NEW_RELEASE=true" >> $GITHUB_OUTPUT fi - name: Create Release diff --git a/build/targets/build_strace.sh b/build/targets/build_strace.sh index 5853c98..b87db5c 100755 --- a/build/targets/build_strace.sh +++ b/build/targets/build_strace.sh @@ -40,9 +40,9 @@ main() { cp "${BUILD_DIRECTORY}/strace/src/strace" "${OUTPUT_DIRECTORY}/strace${version}" echo "[+] Finished building strace ${CURRENT_ARCH}" - echo ::set-output name=PACKAGED_NAME::"strace${version}" - echo ::set-output name=PACKAGED_NAME_PATH::"${OUTPUT_DIRECTORY}/*" - echo ::set-output name=PACKAGED_VERSION::"${version_number}" + echo "PACKAGED_NAME=strace${version}" >> $GITHUB_OUTPUT + echo "PACKAGED_NAME_PATH=${OUTPUT_DIRECTORY}/*" >> $GITHUB_OUTPUT + echo "PACKAGED_VERSION=${version_number}" >> $GITHUB_OUTPUT } main From e2515272f813ad7a2cd71c2f896e42230aead9b1 Mon Sep 17 00:00:00 2001 From: Dennis Heinze <ttdennis@users.noreply.github.com> Date: Mon, 22 May 2023 08:44:33 +0200 Subject: [PATCH 16/22] Fix deprecated set-output --- .github/workflows/build-nmap.yml | 4 ++-- .github/workflows/build-openssh.yml | 4 ++-- .github/workflows/build-socat.yml | 4 ++-- .github/workflows/build-tcpdump.yml | 4 ++-- build/targets/build_gdb.sh | 6 +++--- build/targets/build_openssh.sh | 6 +++--- build/targets/build_socat.sh | 6 +++--- build/targets/build_strace.sh | 4 ++-- build/targets/build_tcpdump.sh | 6 +++--- build/targets/build_tcpreplay.sh | 4 ++-- package/targets/nmap/package.sh | 10 +++++----- 11 files changed, 29 insertions(+), 29 deletions(-) diff --git a/.github/workflows/build-nmap.yml b/.github/workflows/build-nmap.yml index bd6832d..33f0d3d 100644 --- a/.github/workflows/build-nmap.yml +++ b/.github/workflows/build-nmap.yml @@ -151,12 +151,12 @@ jobs: git fetch --quiet --prune --tags if [[ $(git tag -l | grep nmap-v${{ needs.build-x86.outputs.version }} | wc -l) -gt 0 ]]; then echo "Tag for nmap-v${{ needs.build-x86.outputs.version }} already exists. Skipping release creation." - echo ::set-output name=NEW_RELEASE::"false" + echo "NEW_RELEASE=false" >> $GITHUB_OUTPUT else echo "Tag for nmap-v${{ needs.build-x86.outputs.version }} missing. Starting release creation." git tag "nmap-v${{ needs.build-x86.outputs.version }}" git push origin "nmap-v${{ needs.build-x86.outputs.version }}" - echo ::set-output name=NEW_RELEASE::"true" + echo "NEW_RELEASE=true" >> $GITHUB_OUTPUT fi - name: Create Release diff --git a/.github/workflows/build-openssh.yml b/.github/workflows/build-openssh.yml index cea4e49..de32095 100644 --- a/.github/workflows/build-openssh.yml +++ b/.github/workflows/build-openssh.yml @@ -113,11 +113,11 @@ jobs: set +e if git rev-list "openssh-v${{ needs.build-x86.outputs.version }}".. >/dev/null;then echo "Tag for openssh-v${{ needs.build-x86.outputs.version }} already exists. Skipping release creation." - echo ::set-output name=NEW_RELEASE::"false" + echo "NEW_RELEASE=false" >> $GITHUB_OUTPUT else git tag "openssh-v${{ needs.build-x86.outputs.version }}" git push origin "openssh-v${{ needs.build-x86.outputs.version }}" - echo ::set-output name=NEW_RELEASE::"true" + echo "NEW_RELEASE=true" >> $GITHUB_OUTPUT fi - name: Create Release diff --git a/.github/workflows/build-socat.yml b/.github/workflows/build-socat.yml index 3c8a4fd..feef419 100644 --- a/.github/workflows/build-socat.yml +++ b/.github/workflows/build-socat.yml @@ -141,11 +141,11 @@ jobs: set +e if git rev-list "socat-v${{ needs.build-x86.outputs.version }}".. >/dev/null;then echo "Tag for socat-v${{ needs.build-x86.outputs.version }} already exists. Skipping release creation." - echo ::set-output name=NEW_RELEASE::"false" + echo "NEW_RELEASE=false" >> $GITHUB_OUTPUT else git tag "socat-v${{ needs.build-x86.outputs.version }}" git push origin "socat-v${{ needs.build-x86.outputs.version }}" - echo ::set-output name=NEW_RELEASE::"true" + echo "NEW_RELEASE=true" >> $GITHUB_OUTPUT fi - name: Create Release diff --git a/.github/workflows/build-tcpdump.yml b/.github/workflows/build-tcpdump.yml index 12f3a05..080857c 100644 --- a/.github/workflows/build-tcpdump.yml +++ b/.github/workflows/build-tcpdump.yml @@ -112,11 +112,11 @@ jobs: set +e if git rev-list "tcpdump-v${{ needs.build-x86.outputs.version }}".. >/dev/null;then echo "Tag for tcpdump-v${{ needs.build-x86.outputs.version }} already exists. Skipping release creation." - echo ::set-output name=NEW_RELEASE::"false" + echo "NEW_RELEASE=false" >> $GITHUB_OUTPUT else git tag "tcpdump-v${{ needs.build-x86.outputs.version }}" git push origin "tcpdump-v${{ needs.build-x86.outputs.version }}" - echo ::set-output name=NEW_RELEASE::"true" + echo "NEW_RELEASE=true" >> $GITHUB_OUTPUT fi - name: Create Release diff --git a/build/targets/build_gdb.sh b/build/targets/build_gdb.sh index 2d00027..658b7e7 100755 --- a/build/targets/build_gdb.sh +++ b/build/targets/build_gdb.sh @@ -51,9 +51,9 @@ main() { cp "${BUILD_DIRECTORY}/gdb_build/gdbserver/gdbserver" "${OUTPUT_DIRECTORY}/gdbserver${GDBSERVER_VERSION}" echo "[+] Finished building GDB ${CURRENT_ARCH}" - echo ::set-output name=PACKAGED_NAME::"gdb${GDB_VERSION}" - echo ::set-output name=PACKAGED_NAME_PATH::"/output/*" - echo ::set-output name=PACKAGED_VERSION::"${version_number}" + echo "PACKAGED_NAME=gdb${GDB_VERSION}" >> $GITHUB_OUTPUT + echo "PACKAGED_NAME_PATH=/output/*" >> $GITHUB_OUTPUT + echo "PACKAGED_VERSION=${version_number}" >> $GITHUB_OUTPUT } main diff --git a/build/targets/build_openssh.sh b/build/targets/build_openssh.sh index f8cebee..37a4c0a 100755 --- a/build/targets/build_openssh.sh +++ b/build/targets/build_openssh.sh @@ -49,9 +49,9 @@ main() { echo "[+] Finished building OpenSSH ${CURRENT_ARCH}" OPENSSH_VERSION=$(echo $OPENSSH_VERSION | sed 's/-//') - echo ::set-output name=PACKAGED_NAME::"${OPENSSH_VERSION}" - echo ::set-output name=PACKAGED_NAME_PATH::"/output/*" - echo ::set-output name=PACKAGED_VERSION::"${version_number}" + echo "PACKAGED_NAME=${OPENSSH_VERSION} >> $GITHUB_OUTPUT" + echo "PACKAGED_NAME_PATH=/output/* >> $GITHUB_OUTPUT" + echo "PACKAGED_VERSION=${version_number} >> $GITHUB_OUTPUT" } main diff --git a/build/targets/build_socat.sh b/build/targets/build_socat.sh index 51b1f72..d09b841 100755 --- a/build/targets/build_socat.sh +++ b/build/targets/build_socat.sh @@ -41,9 +41,9 @@ main() { cp "${BUILD_DIRECTORY}/socat/socat" "${OUTPUT_DIRECTORY}/socat${version}" echo "[+] Finished building socat ${CURRENT_ARCH}" - echo ::set-output name=PACKAGED_NAME::"socat${version}" - echo ::set-output name=PACKAGED_NAME_PATH::"${OUTPUT_DIRECTORY}/*" - echo ::set-output name=PACKAGED_VERSION::"${version_number}" + echo "PACKAGED_NAME=socat${version}" >> $GITHUB_OUTPUT + echo "PACKAGED_NAME_PATH=${OUTPUT_DIRECTORY}/*" >> $GITHUB_OUTPUT + echo "PACKAGED_VERSION=${version_number}" >> $GITHUB_OUTPUT } main diff --git a/build/targets/build_strace.sh b/build/targets/build_strace.sh index 9b9c442..39eb5a6 100755 --- a/build/targets/build_strace.sh +++ b/build/targets/build_strace.sh @@ -36,8 +36,8 @@ main() { cp "${BUILD_DIRECTORY}/strace/strace" "${OUTPUT_DIRECTORY}/strace" echo "[+] Finished building strace ${CURRENT_ARCH}" - echo ::set-output name=PACKAGED_NAME::"strace${version}" - echo ::set-output name=PACKAGED_NAME_PATH::"${OUTPUT_DIRECTORY}/*" + echo "PACKAGED_NAME=strace${version}" >> $GITHUB_OUTPUT + echo "PACKAGED_NAME_PATH=${OUTPUT_DIRECTORY}/*" >> $GITHUB_OUTPUT } main diff --git a/build/targets/build_tcpdump.sh b/build/targets/build_tcpdump.sh index fdab747..3c6f8d6 100755 --- a/build/targets/build_tcpdump.sh +++ b/build/targets/build_tcpdump.sh @@ -39,9 +39,9 @@ main() { cp "${BUILD_DIRECTORY}/tcpdump/tcpdump" "${OUTPUT_DIRECTORY}/tcpdump${version}" echo "[+] Finished building tcpdump ${CURRENT_ARCH}" - echo ::set-output name=PACKAGED_NAME::"tcpdump${version}" - echo ::set-output name=PACKAGED_NAME_PATH::"${OUTPUT_DIRECTORY}/*" - echo ::set-output name=PACKAGED_VERSION::"${version_number}" + echo "PACKAGED_NAME=tcpdump${version}" >> $GITHUB_OUTPUT + echo "PACKAGED_NAME_PATH=${OUTPUT_DIRECTORY}/*" >> $GITHUB_OUTPUT + echo "PACKAGED_VERSION=${version_number}" >> $GITHUB_OUTPUT } main diff --git a/build/targets/build_tcpreplay.sh b/build/targets/build_tcpreplay.sh index eb46fcf..ed326b1 100755 --- a/build/targets/build_tcpreplay.sh +++ b/build/targets/build_tcpreplay.sh @@ -50,8 +50,8 @@ main() { cp "${BUILD_DIRECTORY}/tcpreplay/tcpreplay" "${OUTPUT_DIRECTORY}/tcpreplay" echo "[+] Finished building tcpreplay ${CURRENT_ARCH}" - echo ::set-output name=PACKAGED_NAME::"tcpreplay${version}" - echo ::set-output name=PACKAGED_NAME_PATH::"${OUTPUT_DIRECTORY}/*" + echo "PACKAGED_NAME=tcpreplay${version}" + echo "PACKAGED_NAME_PATH=${OUTPUT_DIRECTORY}/*" } main diff --git a/package/targets/nmap/package.sh b/package/targets/nmap/package.sh index 85ca112..51f2d05 100755 --- a/package/targets/nmap/package.sh +++ b/package/targets/nmap/package.sh @@ -53,13 +53,13 @@ cd "$tmp_dir" TARBALL="nmap-${version}-${arch}-portable.tar.gz" tar czf "${output}/${TARBALL}" -C "$tmp_dir" . cp "${output}/${TARBALL}" /packaged -echo ::set-output name=PACKAGED_TARBALL::${TARBALL} -echo ::set-output name=PACKAGED_TARBALL_PATH::"/packaged/${TARBALL}" +echo "PACKAGED_TARBALL=${TARBALL}" >> $GITHUB_OUTPUT +echo "PACKAGED_TARBALL_PATH=/packaged/${TARBALL}" >> $GITHUB_OUTPUT ZIP="nmap-${version}-${arch}-portable.zip" zip -r -q "${output}/${ZIP}" . cp "${output}/${ZIP}" /packaged -echo ::set-output name=PACKAGED_ZIP::${ZIP} -echo ::set-output name=PACKAGED_ZIP_PATH::"/packaged/${ZIP}" +echo "PACKAGED_ZIP=${ZIP}" >> $GITHUB_OUTPUT +echo "PACKAGED_ZIP_PATH=/packaged/${ZIP}" >> $GITHUB_OUTPUT -echo ::set-output name=PACKAGED_VERSION::${version} \ No newline at end of file +echo "PACKAGED_VERSION=${version}" >> $GITHUB_OUTPUT \ No newline at end of file From fd09b1375d688127908ab903ba17e37dded4fe72 Mon Sep 17 00:00:00 2001 From: Dennis Heinze <ttdennis@users.noreply.github.com> Date: Mon, 22 May 2023 14:04:57 +0200 Subject: [PATCH 17/22] Add strace badge to readme --- README.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index fff326a..1918cc8 100644 --- a/README.md +++ b/README.md @@ -23,9 +23,11 @@ The following table shows the building status for the current toolset. The follo | Tool | Status | | ---- | ------ | -|[Nmap](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22Nmap%22)|| -|[OpenSSH](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22OpenSSH%22)|| -|[socat](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22socat%22)|| -|[GDB & gdbserver](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3AGDB)|| -|[tcpdump](https://github.com/takeshixx/static-toolbox/actions?query=workflow%3A%22tcpdump%22)|| +|[Nmap](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22Nmap%22)|| +|[OpenSSH](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22OpenSSH%22)|| +|[socat](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22socat%22)|| +|[GDB & gdbserver](https://github.com/ernw/static-toolbox/actions?query=workflow%3AGDB)|| +|[tcpdump](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22tcpdump%22)|| +|[strace](https://github.com/ernw/static-toolbox/actions?query=workflow%3A%22strace%22)|| + From 44979a970308679f363a7e1a153851acee29a2fe Mon Sep 17 00:00:00 2001 From: Dennis Heinze <ttdennis@users.noreply.github.com> Date: Thu, 25 May 2023 08:21:08 +0200 Subject: [PATCH 18/22] Start ppc implementation --- .github/workflows/build-socat.yml | 70 ++++++++++++++++++++++++++++++- build/install_deps_alpine.sh | 2 + build/lib.sh | 22 ++++++++++ build/targets/build_socat.sh | 2 +- 4 files changed, 93 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-socat.yml b/.github/workflows/build-socat.yml index feef419..882a1a2 100644 --- a/.github/workflows/build-socat.yml +++ b/.github/workflows/build-socat.yml @@ -1,6 +1,8 @@ name: socat on: - workflow_dispatch + push: + branches: + - socat-ppc jobs: build-x86: name: Build socat x86 @@ -116,10 +118,74 @@ jobs: name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} + build-ppc32: + name: Build socat powerpc32 + runs-on: ubuntu-latest + container: muslcc/x86_64:powerpc-linux-musl + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install dependencies + run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh + + - name: Install testing dependencies + run: apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing yodl + + - name: Install build compiler + run: /bin/sh -c "apk update && apk upgrade && apk add --no-cache curl rsync sudo util-linux && cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross" + env: + ARCH: x86_64-linux-musl + HOST: http://musl.cc/ + TEMP: /tmp + USER: 0 + + - name: Build socat + id: build_socat + run: $GITHUB_WORKSPACE/build/targets/build_socat.sh ppc32 + + - name: Upload artifacts + uses: actions/upload-artifact@v2 + with: + name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} + path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} + + build-ppc64: + name: Build socat powerpc64 + runs-on: ubuntu-latest + container: muslcc/x86_64:powerpc64-linux-musl + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Install dependencies + run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh + + - name: Install testing dependencies + run: apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing yodl + + - name: Install build compiler + run: /bin/sh -c "apk update && apk upgrade && apk add --no-cache curl rsync sudo util-linux && cd / && curl -so ${ARCH}-cross.tgz ${HOST}/${ARCH}-cross.tgz && tar -xf ${ARCH}-cross.tgz && rm ${ARCH}-cross.tgz && cd ${ARCH}-cross" + env: + ARCH: x86_64-linux-musl + HOST: http://musl.cc/ + TEMP: /tmp + USER: 0 + + - name: Build socat + id: build_socat + run: $GITHUB_WORKSPACE/build/targets/build_socat.sh ppc64 + + - name: Upload artifacts + uses: actions/upload-artifact@v2 + with: + name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} + path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} + create-release: name: Create socat Release runs-on: ubuntu-latest - needs: [build-x86, build-x86_64, build-armhf, build-aarch64] + needs: [build-x86, build-x86_64, build-armhf, build-aarch64, build-ppc32, build-ppc64] steps: - name: Checkout uses: actions/checkout@v2 diff --git a/build/install_deps_alpine.sh b/build/install_deps_alpine.sh index 3f916b0..15b52b7 100755 --- a/build/install_deps_alpine.sh +++ b/build/install_deps_alpine.sh @@ -13,6 +13,8 @@ apk add \ libtool \ qemu-arm \ qemu-aarch64 \ + qemu-ppc \ + qemu-ppc64 \ file \ texinfo \ zip \ diff --git a/build/lib.sh b/build/lib.sh index 8107faa..3d09984 100755 --- a/build/lib.sh +++ b/build/lib.sh @@ -47,6 +47,10 @@ get_host_triple(){ host="arm-linux-musleabihf" elif [ "$CURRENT_ARCH" == "aarch64" ];then host="aarch64-linux-musl" + elif [ "$CURRENT_ARCH" == "ppc32" ];then + host="powerpc-linux-musl" + elif [ "$CURRENT_ARCH" == "ppc64" ];then + host="powerpc64-linux-musl" fi echo $host } @@ -145,6 +149,20 @@ get_version(){ else echo "qemu-aarch64 not found, skipping AARCH64 version checks." >&2 fi + elif [ "$CURRENT_ARCH" == "ppc32" ];then + if which qemu-ppc 1>&2 2>/dev/null;then + cmd="qemu-ppc ${cmd}" + version+=$(eval "$cmd") + else + echo "qemu-ppc not found, skipping ppc32 version checks." >&2 + fi + elif [ "$CURRENT_ARCH" == "ppc64" ];then + if which qemu-ppc64 1>&2 2>/dev/null;then + cmd="qemu-ppc64 ${cmd}" + version+=$(eval "$cmd") + else + echo "qemu-ppc64 not found, skipping ppc64 version checks." >&2 + fi else version+=$(eval "$cmd") fi @@ -214,6 +232,10 @@ lib_build_openssl(){ openssl_arch="linux-x86_64" elif [ "${CURRENT_ARCH}" == "aarch64" ];then openssl_arch="linux-generic64" + elif [ "${CURRENT_ARCH}" == "ppc32" ];then + openssl_arch="linux-ppc" + elif [ "${CURRENT_ARCH}" == "ppc64" ];then + openssl_arch="linux-ppc" fi CFLAGS="${GCC_OPTS}" \ ./Configure \ diff --git a/build/targets/build_socat.sh b/build/targets/build_socat.sh index d09b841..5550a88 100755 --- a/build/targets/build_socat.sh +++ b/build/targets/build_socat.sh @@ -4,7 +4,7 @@ if [ -z "$GITHUB_WORKSPACE" ];then exit 1 fi if [ "$#" -ne 1 ];then - echo "Usage: ${0} [x86|x86_64|armhf|aarch64]" + echo "Usage: ${0} [x86|x86_64|armhf|aarch64|ppc32|ppc64]" echo "Example: ${0} x86_64" exit 1 fi From b322d1b36c556e57df7a5f6933b55063ca7460db Mon Sep 17 00:00:00 2001 From: Dennis Heinze <ttdennis@users.noreply.github.com> Date: Fri, 26 May 2023 09:17:44 +0200 Subject: [PATCH 19/22] Socat ppc and ppc64 build --- .github/workflows/build-socat.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/build-socat.yml b/.github/workflows/build-socat.yml index 882a1a2..bee15b4 100644 --- a/.github/workflows/build-socat.yml +++ b/.github/workflows/build-socat.yml @@ -1,8 +1,6 @@ name: socat on: - push: - branches: - - socat-ppc + workflow_dispatch jobs: build-x86: name: Build socat x86 From 6ea45868db55f33969b5f227a0279edbb6f2428b Mon Sep 17 00:00:00 2001 From: Benjamin Collet <benjamin@collet.eu> Date: Tue, 17 Dec 2024 20:02:35 +0100 Subject: [PATCH 20/22] Migrate CI to forgejo --- {.github => .forgejo}/workflows/build-gdb.yml | 0 .../workflows/build-nmap.yml | 0 .../workflows/build-openssh.yml | 0 .../workflows/build-socat.yml | 42 +++++++++---------- .../workflows/build-strace.yml | 0 .../workflows/build-tcpdump.yml | 0 6 files changed, 21 insertions(+), 21 deletions(-) rename {.github => .forgejo}/workflows/build-gdb.yml (100%) rename {.github => .forgejo}/workflows/build-nmap.yml (100%) rename {.github => .forgejo}/workflows/build-openssh.yml (100%) rename {.github => .forgejo}/workflows/build-socat.yml (89%) rename {.github => .forgejo}/workflows/build-strace.yml (100%) rename {.github => .forgejo}/workflows/build-tcpdump.yml (100%) diff --git a/.github/workflows/build-gdb.yml b/.forgejo/workflows/build-gdb.yml similarity index 100% rename from .github/workflows/build-gdb.yml rename to .forgejo/workflows/build-gdb.yml diff --git a/.github/workflows/build-nmap.yml b/.forgejo/workflows/build-nmap.yml similarity index 100% rename from .github/workflows/build-nmap.yml rename to .forgejo/workflows/build-nmap.yml diff --git a/.github/workflows/build-openssh.yml b/.forgejo/workflows/build-openssh.yml similarity index 100% rename from .github/workflows/build-openssh.yml rename to .forgejo/workflows/build-openssh.yml diff --git a/.github/workflows/build-socat.yml b/.forgejo/workflows/build-socat.yml similarity index 89% rename from .github/workflows/build-socat.yml rename to .forgejo/workflows/build-socat.yml index bee15b4..b23beea 100644 --- a/.github/workflows/build-socat.yml +++ b/.forgejo/workflows/build-socat.yml @@ -4,13 +4,13 @@ on: jobs: build-x86: name: Build socat x86 - runs-on: ubuntu-latest + runs-on: docker container: muslcc/x86_64:i686-linux-musl outputs: version: ${{ steps.build_socat.outputs.PACKAGED_VERSION }} steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Install dependencies run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh @@ -23,18 +23,18 @@ jobs: run: $GITHUB_WORKSPACE/build/targets/build_socat.sh x86 - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: https://code.forgejo.org/forgejo/upload-artifact@v4 with: name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} build-x86_64: name: Build socat x86_64 - runs-on: ubuntu-latest + runs-on: docker container: muslcc/x86_64:x86_64-linux-musl steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Install dependencies run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh @@ -47,18 +47,18 @@ jobs: run: $GITHUB_WORKSPACE/build/targets/build_socat.sh x86_64 - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: https://code.forgejo.org/forgejo/upload-artifact@v4 with: name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} build-armhf: name: Build socat ARMHF - runs-on: ubuntu-latest + runs-on: docker container: muslcc/x86_64:arm-linux-musleabihf steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Install dependencies run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh @@ -79,18 +79,18 @@ jobs: run: $GITHUB_WORKSPACE/build/targets/build_socat.sh armhf - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: https://code.forgejo.org/forgejo/upload-artifact@v4 with: name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} build-aarch64: name: Build socat AARCH64 - runs-on: ubuntu-latest + runs-on: docker container: muslcc/x86_64:aarch64-linux-musl steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Install dependencies run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh @@ -111,18 +111,18 @@ jobs: run: $GITHUB_WORKSPACE/build/targets/build_socat.sh aarch64 - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: https://code.forgejo.org/forgejo/upload-artifact@v4 with: name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} build-ppc32: name: Build socat powerpc32 - runs-on: ubuntu-latest + runs-on: docker container: muslcc/x86_64:powerpc-linux-musl steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Install dependencies run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh @@ -143,18 +143,18 @@ jobs: run: $GITHUB_WORKSPACE/build/targets/build_socat.sh ppc32 - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: https://code.forgejo.org/forgejo/upload-artifact@v4 with: name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} build-ppc64: name: Build socat powerpc64 - runs-on: ubuntu-latest + runs-on: docker container: muslcc/x86_64:powerpc64-linux-musl steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Install dependencies run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh @@ -175,24 +175,24 @@ jobs: run: $GITHUB_WORKSPACE/build/targets/build_socat.sh ppc64 - name: Upload artifacts - uses: actions/upload-artifact@v2 + uses: https://code.forgejo.org/forgejo/upload-artifact@v4 with: name: ${{ steps.build_socat.outputs.PACKAGED_NAME }} path: ${{ steps.build_socat.outputs.PACKAGED_NAME_PATH }} create-release: name: Create socat Release - runs-on: ubuntu-latest + runs-on: docker needs: [build-x86, build-x86_64, build-armhf, build-aarch64, build-ppc32, build-ppc64] steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Prepare Environment run: mkdir /tmp/releases - name: Download Artifacts - uses: actions/download-artifact@v2 + uses: https://code.forgejo.org/forgejo/download-artifact@v4 with: path: /tmp/releases diff --git a/.github/workflows/build-strace.yml b/.forgejo/workflows/build-strace.yml similarity index 100% rename from .github/workflows/build-strace.yml rename to .forgejo/workflows/build-strace.yml diff --git a/.github/workflows/build-tcpdump.yml b/.forgejo/workflows/build-tcpdump.yml similarity index 100% rename from .github/workflows/build-tcpdump.yml rename to .forgejo/workflows/build-tcpdump.yml From ff74c3de0148b660651cf4e61c7c5889e57315a5 Mon Sep 17 00:00:00 2001 From: Benjamin Collet <benjamin@collet.eu> Date: Tue, 17 Dec 2024 21:01:36 +0100 Subject: [PATCH 21/22] Fix --- .forgejo/workflows/build-socat.yml | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/.forgejo/workflows/build-socat.yml b/.forgejo/workflows/build-socat.yml index b23beea..090760e 100644 --- a/.forgejo/workflows/build-socat.yml +++ b/.forgejo/workflows/build-socat.yml @@ -7,13 +7,16 @@ jobs: runs-on: docker container: muslcc/x86_64:i686-linux-musl outputs: - version: ${{ steps.build_socat.outputs.PACKAGED_VERSION }} + version: "${{ steps.build_socat.outputs.PACKAGED_VERSION }}" steps: + - name: Install dependencies + run: sudo apk update && sudo apk add bash nodejs git-lfs + - name: Checkout uses: actions/checkout@v4 - - name: Install dependencies - run: sudo apk update && sudo apk add bash && sudo bash build/install_deps_alpine.sh + - name: Install build dependencies + run: sudo bash build/install_deps_alpine.sh - name: Install testing dependencies run: apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing yodl @@ -33,6 +36,15 @@ jobs: runs-on: docker container: muslcc/x86_64:x86_64-linux-musl steps: + - name: Install dependencies + run: sudo apk update && sudo apk add bash nodejs git-lfs + + - name: Checkout + uses: actions/checkout@v4 + + - name: Install build dependencies + run: sudo bash build/install_deps_alpine.sh + - name: Checkout uses: actions/checkout@v4 From 574763abbaf7721de322cbb7eb1a0cd2aecf687e Mon Sep 17 00:00:00 2001 From: Benjamin Collet <benjamin@collet.eu> Date: Tue, 17 Dec 2024 21:08:26 +0100 Subject: [PATCH 22/22] fix --- .forgejo/workflows/build-socat.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.forgejo/workflows/build-socat.yml b/.forgejo/workflows/build-socat.yml index 090760e..6113268 100644 --- a/.forgejo/workflows/build-socat.yml +++ b/.forgejo/workflows/build-socat.yml @@ -5,7 +5,8 @@ jobs: build-x86: name: Build socat x86 runs-on: docker - container: muslcc/x86_64:i686-linux-musl + container: + image: muslcc/x86_64:i686-linux-musl outputs: version: "${{ steps.build_socat.outputs.PACKAGED_VERSION }}" steps: