From 52ee02d97169ee59072c24e2ac5d717cfaf359fc Mon Sep 17 00:00:00 2001 From: "Rafael G. Martins" Date: Sun, 10 Jan 2016 01:06:32 +0100 Subject: build: improved windows build script --- build-aux/build-windows.sh | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) (limited to 'build-aux') diff --git a/build-aux/build-windows.sh b/build-aux/build-windows.sh index 267a8aa..bdecc8b 100755 --- a/build-aux/build-windows.sh +++ b/build-aux/build-windows.sh @@ -5,24 +5,18 @@ # # mingw32-gcc mingw64-gcc zip # -# This script must be called with the xz source tarball as argument. +# This script must be called with the xz source tarball and the target version +# as arguments. set -ex -[[ $# -eq 1 ]] - - -get_version() { - local a=$(basename "${1}") - a="${a%.tar.xz}" - echo "${a#blogc-}" -} +[[ $# -eq 2 ]] build() { - local version=$(get_version "${1}") - local arch=${2} + local version=${2} + local arch=${3} local build_dir="/tmp/blogc_build_${version}_${arch}" local dest_dir="/tmp/blogc-${version}-w${arch}" @@ -50,5 +44,5 @@ build() { for arch in 32 64; do - build "$1" "${arch}" + build "$1" "$2" "${arch}" done -- cgit v1.2.3-18-g5258