From bff38ad9d0a5037028c8392f29d61942a8af66b6 Mon Sep 17 00:00:00 2001 From: Alexander Shevtsov <1616179+randomlogin@users.noreply.github.com> Date: Thu, 5 Sep 2024 15:28:50 +0200 Subject: [PATCH 1/6] gh actions macOS 2/n --- .github/workflows/build-macos-reusable.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/build-macos-reusable.yml b/.github/workflows/build-macos-reusable.yml index 608539c5..74e3a6a9 100644 --- a/.github/workflows/build-macos-reusable.yml +++ b/.github/workflows/build-macos-reusable.yml @@ -77,9 +77,7 @@ jobs: echo $CGO_CFLAGS echo $CGO_LDFLAGS chmod +x builds/macos/Fingertip.app/Contents/MacOS/hnsd - dylibbundler -od -b -x builds/macos/Fingertip.app/Contents/MacOS/hnsd -d builds/macos/Fingertip.app/Contents/Frameworks -p @executable_path/../Frameworks/ - ./builds/macos/build.sh - dylibbundler -od -b -x builds/macos/Fingertip.app/Contents/MacOS/fingertip -d builds/macos/Fingertip.app/Contents/Frameworks -p @executable_path/../Frameworks/ + ./builds/macos/build.sh ls -l builds/macos ls -l builds/macos/Fingertip.app/Contents/MacOS ls -l builds/macos/Fingertip.app/Contents/Frameworks From 9a2d5b0110cbb696157d7d73d515a1eff6dea0a0 Mon Sep 17 00:00:00 2001 From: Alexander Shevtsov <1616179+randomlogin@users.noreply.github.com> Date: Fri, 6 Sep 2024 14:29:09 +0200 Subject: [PATCH 2/6] Rename build-macos-reusable.yml to build-macos-arm.yml --- .../workflows/{build-macos-reusable.yml => build-macos-arm.yml} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename .github/workflows/{build-macos-reusable.yml => build-macos-arm.yml} (100%) diff --git a/.github/workflows/build-macos-reusable.yml b/.github/workflows/build-macos-arm.yml similarity index 100% rename from .github/workflows/build-macos-reusable.yml rename to .github/workflows/build-macos-arm.yml From e9c9c815be96e371a13f2532ab01af9db28a8af2 Mon Sep 17 00:00:00 2001 From: Alexander Shevtsov <1616179+randomlogin@users.noreply.github.com> Date: Fri, 6 Sep 2024 14:31:25 +0200 Subject: [PATCH 3/6] Update and rename build-macos.yml to build-macos-x86-64.yml --- .github/workflows/build-macos-x86-64.yml | 103 +++++++++++++++++++++++ .github/workflows/build-macos.yml | 15 ---- 2 files changed, 103 insertions(+), 15 deletions(-) create mode 100644 .github/workflows/build-macos-x86-64.yml delete mode 100644 .github/workflows/build-macos.yml diff --git a/.github/workflows/build-macos-x86-64.yml b/.github/workflows/build-macos-x86-64.yml new file mode 100644 index 00000000..71d523f4 --- /dev/null +++ b/.github/workflows/build-macos-x86-64.yml @@ -0,0 +1,103 @@ +name: Build and Package - MacOS (x86-64) + +on: + push: + branches: + - main + pull_request: + branches: + - main + workflow_dispatch: + +jobs: + build-hnsd: + runs-on: macos-13 + + steps: + - name: Checkout hnsd repository + uses: actions/checkout@v4 + with: + repository: 'handshake-org/hnsd' + ref: master + + - name: Install dependencies + run: brew install automake autoconf libtool unbound + + - name: Build hnsd + run: | + ./autogen.sh && ./configure --with-unbound=$(brew --prefix) && make + ls -l + + - name: Store hnsd binary + uses: actions/upload-artifact@v4 + with: + name: hnsd-bin-${{inputs.os}} + path: ./hnsd + if-no-files-found: error + + build-fingertip: + needs: build-hnsd + runs-on: macos-13 + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Install go + uses: actions/setup-go@v5 + with: + go-version: '1.21' + + - name: Install dependencies + run: brew install dylibbundler git automake autoconf libtool getdns + + - name: Verify getdns installation + run: | + echo $(brew --prefix getdns) + ls -l $(brew --prefix getdns)/include/getdns + ls -l $(brew --prefix getdns)/lib + + - name: Set environment variables + run: | + export BREW_PREFIX=$(brew --prefix getdns) + echo "BREW_PREFIX=$BREW_PREFIX" >> $GITHUB_ENV + echo $GITHUB_ENV + + - name: Download hnsd binary + uses: actions/download-artifact@v4 + with: + name: hnsd-bin-${{inputs.os}} + path: builds/macos/Fingertip.app/Contents/MacOS + + - name: Build fingertip + run: | + source $GITHUB_ENV + export CGO_CFLAGS="-I$BREW_PREFIX/include" + export CGO_LDFLAGS="-L$BREW_PREFIX/lib -lgetdns" + echo $CGO_CFLAGS + echo $CGO_LDFLAGS + chmod +x builds/macos/Fingertip.app/Contents/MacOS/hnsd + ./builds/macos/build.sh + ls -l builds/macos + ls -l builds/macos/Fingertip.app/Contents/MacOS + ls -l builds/macos/Fingertip.app/Contents/Frameworks + + - name: Create DMG + working-directory: ./builds/macos + run: | + hdiutil create -format UDZO -srcfolder ./Fingertip.app ./Fingertip.dmg + ls -l + + - name: Store fingertip binary + uses: actions/upload-artifact@v4 + with: + name: fingertip-bin-${{inputs.os}} + path: ./builds/macos/Fingertip.app/Contents/MacOS/fingertip + if-no-files-found: error + + - name: Store fingertip dmg + uses: actions/upload-artifact@v4 + with: + name: fingertip-dmg-${{inputs.os}} + path: ./builds/macos/Fingertip.dmg + if-no-files-found: error diff --git a/.github/workflows/build-macos.yml b/.github/workflows/build-macos.yml deleted file mode 100644 index 27fa9c30..00000000 --- a/.github/workflows/build-macos.yml +++ /dev/null @@ -1,15 +0,0 @@ -name: Build and Package - MacOS - -# on: [push, pull_request, workflow_dispatch] -on: [workflow_dispatch] - -jobs: - build-for-macos: - strategy: - fail-fast: false - matrix: - os: [macos-12, macos-14] # 12=x86, 14=M1 - uses: ./.github/workflows/build-macos-reusable.yml - with: - os: ${{ matrix.os }} - secrets: inherit From e579c71b8773b7e854c41fa1b730a4e2802459a3 Mon Sep 17 00:00:00 2001 From: Alexander Shevtsov <1616179+randomlogin@users.noreply.github.com> Date: Fri, 6 Sep 2024 14:32:32 +0200 Subject: [PATCH 4/6] Update build-macos-arm.yml --- .github/workflows/build-macos-arm.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/build-macos-arm.yml b/.github/workflows/build-macos-arm.yml index 74e3a6a9..969bb33f 100644 --- a/.github/workflows/build-macos-arm.yml +++ b/.github/workflows/build-macos-arm.yml @@ -1,4 +1,4 @@ -name: Build and Package - MacOS (reusable) +name: Build and Package - MacOS (arm) on: push: @@ -51,11 +51,6 @@ jobs: - name: Install dependencies run: brew install dylibbundler git automake autoconf libtool getdns - - name: Verify getdns installation - run: | - echo $(brew --prefix getdns) - ls -l $(brew --prefix getdns)/include/getdns - ls -l $(brew --prefix getdns)/lib - name: Set environment variables run: | From 49019c667a086206d59c4c53fe8f094895b2e671 Mon Sep 17 00:00:00 2001 From: Alexander Shevtsov <1616179+randomlogin@users.noreply.github.com> Date: Fri, 6 Sep 2024 14:38:38 +0200 Subject: [PATCH 5/6] Update build-macos-arm.yml --- .github/workflows/build-macos-arm.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-macos-arm.yml b/.github/workflows/build-macos-arm.yml index 969bb33f..70471848 100644 --- a/.github/workflows/build-macos-arm.yml +++ b/.github/workflows/build-macos-arm.yml @@ -31,7 +31,7 @@ jobs: - name: Store hnsd binary uses: actions/upload-artifact@v4 with: - name: hnsd-bin-${{inputs.os}} + name: hnsd-bin-${{runner.os}} path: ./hnsd if-no-files-found: error @@ -49,7 +49,7 @@ jobs: go-version: '1.21' - name: Install dependencies - run: brew install dylibbundler git automake autoconf libtool getdns + run: brew install dylibbundler getdns - name: Set environment variables @@ -61,7 +61,7 @@ jobs: - name: Download hnsd binary uses: actions/download-artifact@v4 with: - name: hnsd-bin-${{inputs.os}} + name: hnsd-bin-${{runner.os}} path: builds/macos/Fingertip.app/Contents/MacOS - name: Build fingertip @@ -86,13 +86,13 @@ jobs: - name: Store fingertip binary uses: actions/upload-artifact@v4 with: - name: fingertip-bin-${{inputs.os}} + name: fingertip-bin-${{runner.os}} path: ./builds/macos/Fingertip.app/Contents/MacOS/fingertip if-no-files-found: error - name: Store fingertip dmg uses: actions/upload-artifact@v4 with: - name: fingertip-dmg-${{inputs.os}} + name: fingertip-dmg-${{runner.os}} path: ./builds/macos/Fingertip.dmg if-no-files-found: error From a572981583e3427567d6621c10088b1a8fb2c527 Mon Sep 17 00:00:00 2001 From: Alexander Shevtsov <1616179+randomlogin@users.noreply.github.com> Date: Tue, 10 Sep 2024 02:09:56 +0200 Subject: [PATCH 6/6] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f5899733..6944282a 100644 --- a/README.md +++ b/README.md @@ -70,8 +70,8 @@ bash builds/linux/create_appimage.sh ### Windows -Due to the [difference](https://github.com/handshake-org/hnsd/issues/128) in hnsd behaviour on Windows and other platforms (and overall complexity of building for windows), -Windows is not supported. This may change in future. +Due to the [difference](https://github.com/handshake-org/hnsd/issues/128) in hnsd behaviour on Windows and other platforms (and overall complexity of building for windows), stateless DANE is not supported on Windows. +The version from the [v0.0.3 release](https://github.com/imperviousinc/fingertip/releases/tag/v0.0.3) should be used for usual DANE. ## Credits