only create builddir for linux
This commit is contained in:
parent
0454c5ecb0
commit
609890aec1
3
build.sh
3
build.sh
@ -4,7 +4,6 @@
|
|||||||
|
|
||||||
RELEASE_VERSION=
|
RELEASE_VERSION=
|
||||||
buildpath=
|
buildpath=
|
||||||
builddir=
|
|
||||||
|
|
||||||
function setuptree() {
|
function setuptree() {
|
||||||
b=$( mktemp -d $buildpath/gh-ostXXXXXX ) || return 1
|
b=$( mktemp -d $buildpath/gh-ostXXXXXX ) || return 1
|
||||||
@ -19,7 +18,6 @@ function build {
|
|||||||
GOOS=$3
|
GOOS=$3
|
||||||
GOARCH=$4
|
GOARCH=$4
|
||||||
|
|
||||||
builddir=$(setuptree)
|
|
||||||
|
|
||||||
|
|
||||||
if ! go version | egrep -q 'go(1[.]9|1[.]1[0-9])' ; then
|
if ! go version | egrep -q 'go(1[.]9|1[.]1[0-9])' ; then
|
||||||
@ -41,6 +39,7 @@ function build {
|
|||||||
|
|
||||||
if [ "$GOOS" == "linux" ] ; then
|
if [ "$GOOS" == "linux" ] ; then
|
||||||
echo "Creating Distro full packages"
|
echo "Creating Distro full packages"
|
||||||
|
builddir=$(setuptree)
|
||||||
cp $buildpath/$target $builddir/gh-ost/usr/bin
|
cp $buildpath/$target $builddir/gh-ost/usr/bin
|
||||||
cd $buildpath
|
cd $buildpath
|
||||||
fpm -v "${RELEASE_VERSION}" --epoch 1 -f -s dir -n gh-ost -m shlomi-noach --description "GitHub's Online Schema Migrations for MySQL " --url "https://github.com/github/gh-ost" --vendor "GitHub" --license "Apache 2.0" -C $builddir/gh-ost --prefix=/ -t rpm .
|
fpm -v "${RELEASE_VERSION}" --epoch 1 -f -s dir -n gh-ost -m shlomi-noach --description "GitHub's Online Schema Migrations for MySQL " --url "https://github.com/github/gh-ost" --vendor "GitHub" --license "Apache 2.0" -C $builddir/gh-ost --prefix=/ -t rpm .
|
||||||
|
Loading…
Reference in New Issue
Block a user