|
|
6abdee |
#!/bin/bash
|
|
|
6abdee |
|
|
|
6abdee |
set -e
|
|
|
6abdee |
|
|
|
6abdee |
BASE_DIR=$(cd `dirname "$0"`; pwd)
|
|
|
6abdee |
DATA_DIR="$BASE_DIR/docker-builder-data"
|
|
|
6abdee |
BUILD_DIR=$DATA_DIR/build
|
|
|
17be73 |
PUBLISH_DIR=$BASE_DIR/publish
|
|
|
6abdee |
CONFIG_FILE="$BASE_DIR/config.sh"
|
|
|
6abdee |
PACKET_BUILD_DIR="$BUILD_DIR/packet"
|
|
|
6abdee |
SCRIPT_BUILD_DIR="$BUILD_DIR/script"
|
|
|
91875d |
|
|
|
91875d |
source "$BASE_DIR/gen-name.sh"
|
|
|
91875d |
|
|
|
6abdee |
if [ -f $CONFIG_FILE ]; then
|
|
|
6abdee |
source $CONFIG_FILE
|
|
|
6abdee |
fi
|
|
|
6abdee |
|
|
|
6dca2e |
SCRIPT="$BASE_DIR/docker/run.sh"
|
|
|
6dca2e |
|
|
|
6dca2e |
run_appimage() {
|
|
|
6dca2e |
export PLATFORM="$1"
|
|
|
6dca2e |
export ARCH="$2"
|
|
|
6dca2e |
|
|
|
6dca2e |
echo ""
|
|
|
5ef601 |
echo "Update and build opentoonz for $PLATFORM-$ARCH"
|
|
|
6dca2e |
echo ""
|
|
|
5ef601 |
$SCRIPT chain update opentoonz-master \
|
|
|
5ef601 |
chain clean_before_do install_release opentoonz-appimage
|
|
|
6dca2e |
|
|
|
91875d |
local TEMPLATE=`gen_name_template "OpenToonz" "" "$PLATFORM" "$ARCH" ".appimage"`
|
|
|
6dca2e |
"$PUBLISH_DIR/publish.sh" \
|
|
|
6dca2e |
"opentoonz" \
|
|
|
91875d |
"$TEMPLATE" \
|
|
|
6dca2e |
"$PACKET_BUILD_DIR/$PLATFORM-$ARCH/opentoonz-appimage/install_release" \
|
|
|
6dca2e |
"*.appimage" \
|
|
|
6dca2e |
"$PACKET_BUILD_DIR/$PLATFORM-$ARCH/opentoonz-appimage/envdeps_release/version-opentoonz-master"
|
|
|
6dca2e |
}
|
|
|
6dca2e |
|
|
|
6dca2e |
run_nsis() {
|
|
|
6dca2e |
export PLATFORM="$1"
|
|
|
6dca2e |
export ARCH="$2"
|
|
|
6dca2e |
|
|
|
6dca2e |
echo ""
|
|
|
5ef601 |
echo "Update and build opentoonz for $PLATFORM-$ARCH"
|
|
|
6dca2e |
echo ""
|
|
|
f0ec65 |
PLATFORM=win ARCH=32 $SCRIPT clean_before_do env zlib-1.2.11 # for NSIS
|
|
|
5ef601 |
$SCRIPT chain update opentoonz-master \
|
|
|
84db19 |
chain clean_before_do install_release opentoonz-nsis \
|
|
|
84db19 |
chain clean_before_do install_release opentoonz-portable
|
|
|
6dca2e |
|
|
|
91875d |
local TEMPLATE=`gen_name_template "OpenToonz" "" "$PLATFORM" "$ARCH" ".exe"`
|
|
|
6dca2e |
"$PUBLISH_DIR/publish.sh" \
|
|
|
6dca2e |
"opentoonz" \
|
|
|
91875d |
"$TEMPLATE" \
|
|
|
6dca2e |
"$PACKET_BUILD_DIR/$PLATFORM-$ARCH/opentoonz-nsis/install_release" \
|
|
|
6dca2e |
"*.exe" \
|
|
|
6dca2e |
"$PACKET_BUILD_DIR/$PLATFORM-$ARCH/opentoonz-nsis/envdeps_release/version-opentoonz-master"
|
|
|
84db19 |
|
|
|
84db19 |
local TEMPLATE=`gen_name_template "OpenToonz" "" "$PLATFORM" "$ARCH" ".zip"`
|
|
|
84db19 |
"$PUBLISH_DIR/publish.sh" \
|
|
|
84db19 |
"opentoonz" \
|
|
|
84db19 |
"$TEMPLATE" \
|
|
|
84db19 |
"$PACKET_BUILD_DIR/$PLATFORM-$ARCH/opentoonz-portable/install_release" \
|
|
|
84db19 |
"*.zip" \
|
|
|
84db19 |
"$PACKET_BUILD_DIR/$PLATFORM-$ARCH/opentoonz-portable/envdeps_release/version-opentoonz-master"
|
|
|
6abdee |
}
|
|
|
cc5124 |
|
|
|
6dca2e |
run_appimage linux 64
|
|
|
6dca2e |
run_appimage linux 32
|
|
|
6dca2e |
run_nsis win 64
|
|
|
7de9b7 |
run_nsis win 32
|