-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
addb65b
commit 1be236c
Showing
15 changed files
with
175 additions
and
101 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
gopath/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
#!/bin/bash | ||
|
||
# globals | ||
outputDir=../../releases/go-ipfs | ||
goipfspath=github.com/ipfs/go-ipfs/cmd/ipfs | ||
|
||
function doBuild() { | ||
local goos=$1 | ||
local goarch=$2 | ||
local target=$3 | ||
local output=$4 | ||
|
||
echo "==> building $target $goos $goarch" | ||
dir=$output/$1-$2 | ||
if [ -e $dir ] | ||
then | ||
echo " skipping build" | ||
return | ||
fi | ||
echo " output to $dir" | ||
mkdir -p $dir | ||
(cd $dir && GOOS=$goos GOARCH=$goarch go build $target 2>&1 > build-log) | ||
echo $target, $goos, $goarch, $? >> $output/results | ||
} | ||
|
||
function buildWithMatrix() { | ||
local matfile=$1 | ||
local gobin=$2 | ||
local output=$3 | ||
local commit=$4 | ||
|
||
# print out build information | ||
mkdir -p $output | ||
go version > $output/build-info | ||
echo "git sha of code: $commit" >> $output/build-info | ||
uname -a >> $output/build-info | ||
echo built on `date` >> $output/build-info | ||
|
||
# build each os/arch combo | ||
while read line | ||
do | ||
doBuild $line $gobin $output | ||
done < $matfile | ||
} | ||
|
||
function checkoutVersion() { | ||
local repopath=$1 | ||
local ref=$2 | ||
|
||
echo "==> checking out version $v" | ||
(cd $repopath && git checkout $ref) | ||
} | ||
|
||
function currentSha() { | ||
(cd $REPO && git show --pretty="%H") | ||
} | ||
|
||
# if the output directory already exists, warn user | ||
if [ -e $outputDir ] | ||
then | ||
echo "dirty output directory" | ||
echo "will skip building already existing binaries" | ||
fi | ||
|
||
|
||
export GOPATH=$(pwd)/gopath | ||
echo "fetching ipfs code..." | ||
go get $goipfspath | ||
|
||
repopath=$GOPATH/src/$goipfspath | ||
|
||
while read v | ||
do | ||
echo "Building version $v binaries" | ||
checkoutVersion $repopath $v | ||
|
||
local output=$outputDir/$v | ||
buildWithMatrix matrices/$v $goipfspath $output $(currentSha $repopath) | ||
echo "" | ||
done < versions |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
darwin 386 | ||
darwin amd64 | ||
freebsd 386 | ||
freebsd amd64 | ||
freebsd arm | ||
linux 386 | ||
linux amd64 | ||
linux arm | ||
windows 386 | ||
windows amd64 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,5 @@ v0.3.5 | |
v0.3.6 | ||
v0.3.7 | ||
v0.3.8 | ||
v0.3.9 | ||
v0.3.10 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters