Skip to content

Commit

Permalink
Merge pull request #150 from ooni/fix/buildscript
Browse files Browse the repository at this point in the history
Release v3.0.7-beta.1 with updated build script
  • Loading branch information
bassosimone authored Aug 24, 2020
2 parents fe89b24 + 8672791 commit b18a106
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 10 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ jobs:
with:
go-version: "1.14"
- uses: actions/checkout@v2
- run: ./build.sh macos
- run: ./smoketest.sh ./CLI/macos/amd64/ooniprobe
- run: ./build.sh darwin
- run: ./smoketest.sh ./CLI/darwin/amd64/ooniprobe
- uses: actions/upload-artifact@v1
with:
name: ooniprobe-macos-amd64
path: ./CLI/macos/amd64/ooniprobe
name: ooniprobe-darwin-amd64
path: ./CLI/darwin/amd64/ooniprobe
File renamed without changes.
14 changes: 9 additions & 5 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,23 +26,23 @@ case $1 in
go build -tags netgo -ldflags='-s -w -extldflags "-static"' ./cmd/ooniprobe
;;

macos)
macos|darwin)
# Note! The following line _assumes_ you have a working C compiler. If you
# have Xcode command line tools installed, you are fine.
go build -ldflags='-s -w' ./cmd/ooniprobe
tar -cvzf ooniprobe_${v}_macos_amd64.tar.gz LICENSE.md Readme.md ooniprobe
mv ooniprobe ./CLI/macos/amd64/
tar -cvzf ooniprobe_${v}_darwin_amd64.tar.gz LICENSE.md Readme.md ooniprobe
mv ooniprobe ./CLI/darwin/amd64/
;;

release)
$0 linux
$0 windows
$0 macos
$0 darwin
shasum -a 256 ooniprobe_${v}_*_amd64.* > ooniprobe_checksums.txt
;;

*)
echo "Usage: $0 linux|macos|windows|release"
echo "Usage: $0 darwin|linux|macos|windows|release"
echo ""
echo "You need a C compiler and Go >= 1.14. The C compiler must be a"
echo "UNIX like compiler like GCC, Clang, Mingw-w64."
Expand All @@ -54,5 +54,9 @@ case $1 in
echo "macOS has never been tested. We have a bunch of cross compiling"
echo "checks inside the .github/workflows/cross.yml file."
echo ""
echo "The macos rule is an alias for the darwin rule. The generated"
echo "binary file is named ooniprobe_${version}_darwin_${arch}.tar.gz"
echo "because the platform name is darwin."
echo ""
;;
esac
2 changes: 1 addition & 1 deletion version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ package version

const (
// Version is the software version
Version = "3.0.7-beta"
Version = "3.0.7-beta.1"
)

0 comments on commit b18a106

Please sign in to comment.