@@ -1,49 +0,0 @@ | |||
FROM ubuntu:18.04 | |||
MAINTAINER falkTX <falktx@falktx.com> | |||
ENV DEBIAN_FRONTEND noninteractive | |||
# enable i386 | |||
RUN dpkg --add-architecture i386 | |||
RUN echo "deb [arch=amd64,i386] http://archive.ubuntu.com/ubuntu/ bionic main restricted universe multiverse" > /etc/apt/sources.list && \ | |||
echo "deb [arch=amd64,i386] http://archive.ubuntu.com/ubuntu/ bionic-updates main restricted universe multiverse" >> /etc/apt/sources.list && \ | |||
echo "deb [arch=amd64,i386] http://archive.ubuntu.com/ubuntu/ bionic-backports main restricted universe multiverse" >> /etc/apt/sources.list && \ | |||
echo "deb [arch=amd64,i386] http://security.ubuntu.com/ubuntu bionic-security main restricted universe multiverse" >> /etc/apt/sources.list | |||
# update and upgrade system | |||
RUN apt-get update && apt-get upgrade -qy && apt-get clean | |||
# install packages | |||
RUN apt-get install -qy mingw-w64 && \ | |||
apt-get install -qy qemu-user-static libwine-development-dev wine64-development-tools && \ | |||
apt-get install -qy locales acl bash bash-completion git nano patch python3 tar wget && \ | |||
apt-get install -qy automake binutils build-essential cmake libglib2.0-dev-bin libtool-bin && \ | |||
apt-get clean | |||
# basic setup | |||
RUN locale-gen en_US.UTF-8 | |||
RUN echo "source /etc/bash_completion" >> $HOME/.bashrc | |||
# user configurations | |||
ENV USER builder | |||
ENV HOME /home/$USER | |||
# create user | |||
RUN useradd -d $HOME -m -G sudo $USER | |||
# switch user | |||
USER $USER | |||
# checkout scripts dir | |||
RUN mkdir $HOME/scripts | |||
RUN mkdir $HOME/scripts/patches | |||
COPY common.env build-*.sh $HOME/scripts/ | |||
COPY patches/* $HOME/scripts/patches/ | |||
# build deps | |||
WORKDIR $HOME/scripts | |||
RUN ./build-deps.sh | |||
RUN ./build-pyqt.sh | |||
# CMD | |||
CMD ["bash"] |
@@ -1,37 +0,0 @@ | |||
#!/usr/bin/env python3 | |||
# -*- coding: utf-8 -*- | |||
# ------------------------------------------------------------------------------------------------------------ | |||
# Imports (cx_Freeze) | |||
from cx_Freeze import setup, Executable | |||
# ------------------------------------------------------------------------------------------------------------ | |||
# Imports (Custom Stuff) | |||
from carla_host import VERSION | |||
# ------------------------------------------------------------------------------------------------------------ | |||
options = { | |||
"zip_include_packages": ["*"], | |||
"zip_exclude_packages": ["PyQt5"], | |||
"replace_paths": [["*",".\\lib\\"]], | |||
"build_exe": ".\\Carla\\", | |||
"optimize": True, | |||
} | |||
exe_options = { | |||
"script": "..\\..\\source\\frontend\\carla", | |||
"icon": "..\\..\\resources\\ico\\carla.ico", | |||
"copyright": "Copyright (C) 2011-2019 Filipe Coelho", | |||
"targetName": "CarlaDebug.exe", | |||
} | |||
setup(name = "Carla", | |||
version = VERSION, | |||
description = "Carla Plugin Host", | |||
options = {"build_exe": options}, | |||
executables = [Executable(**exe_options)]) | |||
# ------------------------------------------------------------------------------------------------------------ |
@@ -1,41 +0,0 @@ | |||
#!/usr/bin/env python3 | |||
# -*- coding: utf-8 -*- | |||
# ------------------------------------------------------------------------------------------------------------ | |||
# Imports (cx_Freeze) | |||
from cx_Freeze import setup, Executable | |||
# ------------------------------------------------------------------------------------------------------------ | |||
# Imports (Custom Stuff) | |||
from carla_host import VERSION | |||
from os import getenv | |||
# ------------------------------------------------------------------------------------------------------------ | |||
name = getenv("TARGET_NAME") | |||
options = { | |||
"zip_include_packages": ["*"], | |||
"zip_exclude_packages": ["PyQt5"], | |||
"replace_paths": [["*",".\\lib\\"]], | |||
"build_exe": ".\\build\\CarlaControl\\", | |||
"optimize": True, | |||
} | |||
exe_options = { | |||
"script": ".\\source\\frontend\\carla-control", | |||
"icon": ".\\resources\\ico\\carla-control.ico", | |||
"copyright": "Copyright (C) 2011-2021 Filipe Coelho", | |||
"base": "Win32GUI", | |||
"targetName": "CarlaControl.exe", | |||
} | |||
setup(name = "CarlaControl", | |||
version = VERSION, | |||
description = "Carla Remote Control", | |||
options = {"build_exe": options}, | |||
executables = [Executable(**exe_options)]) | |||
# ------------------------------------------------------------------------------------------------------------ |
@@ -1,41 +0,0 @@ | |||
#!/usr/bin/env python3 | |||
# -*- coding: utf-8 -*- | |||
# ------------------------------------------------------------------------------------------------------------ | |||
# Imports (cx_Freeze) | |||
from cx_Freeze import setup, Executable | |||
# ------------------------------------------------------------------------------------------------------------ | |||
# Imports (Custom Stuff) | |||
from carla_host import VERSION | |||
from os import getenv | |||
# ------------------------------------------------------------------------------------------------------------ | |||
name = getenv("TARGET_NAME") | |||
options = { | |||
"zip_include_packages": ["*"], | |||
"zip_exclude_packages": ["PyQt5"], | |||
"replace_paths": [["*",".\\lib\\"]], | |||
"build_exe": ".\\build\\Carla\\resources\\", | |||
"optimize": True, | |||
} | |||
exe_options = { | |||
"script": ".\\source\\frontend\\{}".format(name), | |||
"icon": ".\\resources\\ico\\carla.ico", | |||
"copyright": "Copyright (C) 2011-2021 Filipe Coelho", | |||
"base": "Win32GUI", | |||
"targetName": "{}.exe".format(name), | |||
} | |||
setup(name = name, | |||
version = VERSION, | |||
description = name, | |||
options = {"build_exe": options}, | |||
executables = [Executable(**exe_options)]) | |||
# ------------------------------------------------------------------------------------------------------------ |
@@ -1,393 +0,0 @@ | |||
#!/bin/bash | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# stop on error | |||
set -e | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# cd to correct path | |||
cd $(dirname $0) | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# set variables | |||
source common.env | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# function to remove old stuff | |||
cleanup_prefix() | |||
{ | |||
rm -rf ${TARGETDIR}/carla-w32nosse ${TARGETDIR}/carla-w32 ${TARGETDIR}/carla-w64 | |||
} | |||
cleanup_pkgs() | |||
{ | |||
rm -rf Carla | |||
rm -rf Carla.exe | |||
rm -rf Carla.lv2 | |||
rm -rf Carla.vst | |||
rm -rf Carla_* | |||
rm -rf flac-* | |||
rm -rf fluidsynth-* | |||
rm -rf fftw-* | |||
rm -rf glib-* | |||
rm -rf liblo-* | |||
rm -rf libogg-* | |||
rm -rf libsndfile-* | |||
rm -rf libvorbis-* | |||
rm -rf mxml-* | |||
rm -rf pkg-config-* | |||
rm -rf pyliblo-* | |||
rm -rf zlib-* | |||
} | |||
cleanup() | |||
{ | |||
cleanup_prefix | |||
cleanup_pkgs | |||
exit 0 | |||
} | |||
# ------------------------------------------------------------------------------------ | |||
# function to build base libs | |||
build_base() | |||
{ | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# clean env | |||
unset AR | |||
unset CC | |||
unset CXX | |||
unset STRIP | |||
unset WINDRES | |||
unset PKG_CONFIG_PATH | |||
unset CFLAGS | |||
unset CPPFLAGS | |||
unset CXXFLAGS | |||
unset LDFLAGS | |||
export PREFIX=${TARGETDIR}/carla-w${ARCH_PREFIX} | |||
export PATH=${PREFIX}/bin:/usr/sbin:/usr/bin:/sbin:/bin | |||
export PKG_CONFIG_PATH=${PREFIX}/lib/pkgconfig | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# pkgconfig | |||
if [ ! -d pkg-config-${PKG_CONFIG_VERSION} ]; then | |||
wget -c https://pkg-config.freedesktop.org/releases/pkg-config-${PKG_CONFIG_VERSION}.tar.gz | |||
tar -xf pkg-config-${PKG_CONFIG_VERSION}.tar.gz | |||
fi | |||
if [ ! -f pkg-config-${PKG_CONFIG_VERSION}/build-done ]; then | |||
cd pkg-config-${PKG_CONFIG_VERSION} | |||
env AR="ar" CC="gcc" STRIP="strip" CFLAGS="" LDFLAGS="" PATH="/usr/sbin:/usr/bin:/sbin:/bin" \ | |||
./configure --enable-indirect-deps --with-internal-glib --with-pc-path=${PKG_CONFIG_PATH} --prefix=${PREFIX} | |||
make ${MAKE_ARGS} | |||
make install | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# setup | |||
if [ x"${ARCH}" != x"32" ]; then | |||
CPUARCH="x86_64" | |||
else | |||
CPUARCH="i686" | |||
fi | |||
HOST_ARCH=$(dpkg-architecture -qDEB_BUILD_GNU_TYPE) | |||
MINGW_PREFIX="${CPUARCH}-w64-mingw32" | |||
export AR=${MINGW_PREFIX}-ar | |||
export CC=${MINGW_PREFIX}-gcc | |||
export CXX=${MINGW_PREFIX}-g++ | |||
export STRIP=${MINGW_PREFIX}-strip | |||
export WINDRES=${MINGW_PREFIX}-windres | |||
if [ -z "${NOSSE}" ]; then | |||
export CFLAGS="-O3 -mtune=generic -msse -msse2 -mfpmath=sse -mstackrealign -fvisibility=hidden -fdata-sections -ffunction-sections" | |||
else | |||
export CFLAGS="-O2 -mstackrealign -fvisibility=hidden -fdata-sections -ffunction-sections" | |||
fi | |||
export CFLAGS="${CFLAGS} -DNDEBUG -DPTW32_STATIC_LIB -DFLUIDSYNTH_NOT_A_DLL -I${PREFIX}/include -I/opt/mingw${ARCH}/include" | |||
export CXXFLAGS="${CFLAGS} -fvisibility-inlines-hidden" | |||
export CPPFLAGS="-DPIC -DNDEBUG -DPTW32_STATIC_LIB -I${PREFIX}/include -I/opt/mingw${ARCH}/include" | |||
export LDFLAGS="-fdata-sections -ffunction-sections -Wl,--gc-sections -Wl,-O1 -Wl,--as-needed -Wl,--strip-all" | |||
export LDFLAGS="${LDFLAGS} -L${PREFIX}/lib -L/opt/mingw${ARCH}/lib" | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# liblo | |||
if [ ! -d liblo-${LIBLO_VERSION} ]; then | |||
wget -c https://github.com/radarsat1/liblo/releases/download/${LIBLO_VERSION}/liblo-${LIBLO_VERSION}.tar.gz | |||
tar -xf liblo-${LIBLO_VERSION}.tar.gz | |||
fi | |||
if [ ! -f liblo-${LIBLO_VERSION}/build-done ]; then | |||
cd liblo-${LIBLO_VERSION} | |||
sed -i "s/@extralibs@/@extralibs@ -lm/" liblo.pc.in | |||
./configure --enable-static --disable-shared --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} \ | |||
--enable-threads \ | |||
--disable-examples --disable-tools | |||
make ${MAKE_ARGS} | |||
make install | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# zlib | |||
if [ ! -d zlib-${ZLIB_VERSION} ]; then | |||
wget -c https://github.com/madler/zlib/archive/v${ZLIB_VERSION}.tar.gz -O zlib-${ZLIB_VERSION}.tar.gz | |||
tar -xf zlib-${ZLIB_VERSION}.tar.gz | |||
fi | |||
if [ ! -f zlib-${ZLIB_VERSION}/build-done ]; then | |||
cd zlib-${ZLIB_VERSION} | |||
./configure --static --prefix=${PREFIX} | |||
make ${MAKE_ARGS} | |||
make install | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# libogg | |||
if [ ! -d libogg-${LIBOGG_VERSION} ]; then | |||
wget -c https://ftp.osuosl.org/pub/xiph/releases/ogg/libogg-${LIBOGG_VERSION}.tar.gz | |||
tar -xf libogg-${LIBOGG_VERSION}.tar.gz | |||
fi | |||
if [ ! -f libogg-${LIBOGG_VERSION}/build-done ]; then | |||
cd libogg-${LIBOGG_VERSION} | |||
./configure --enable-static --disable-shared --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} | |||
make ${MAKE_ARGS} | |||
make install | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# libvorbis | |||
if [ ! -d libvorbis-${LIBVORBIS_VERSION} ]; then | |||
wget -c https://ftp.osuosl.org/pub/xiph/releases/vorbis/libvorbis-${LIBVORBIS_VERSION}.tar.gz | |||
tar -xf libvorbis-${LIBVORBIS_VERSION}.tar.gz | |||
fi | |||
if [ ! -f libvorbis-${LIBVORBIS_VERSION}/build-done ]; then | |||
cd libvorbis-${LIBVORBIS_VERSION} | |||
./configure --enable-static --disable-shared --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} | |||
make ${MAKE_ARGS} | |||
make install | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# flac | |||
if [ ! -d flac-${FLAC_VERSION} ]; then | |||
wget -c https://ftp.osuosl.org/pub/xiph/releases/flac/flac-${FLAC_VERSION}.tar.xz | |||
tar -xf flac-${FLAC_VERSION}.tar.xz | |||
fi | |||
if [ ! -f flac-${FLAC_VERSION}/build-done ]; then | |||
cd flac-${FLAC_VERSION} | |||
chmod +x configure install-sh | |||
./configure --enable-static --disable-shared --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} \ | |||
--disable-cpplibs | |||
make ${MAKE_ARGS} | |||
make install | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# libsndfile | |||
if [ ! -d libsndfile-${LIBSNDFILE_VERSION} ]; then | |||
wget -c http://www.mega-nerd.com/libsndfile/files/libsndfile-${LIBSNDFILE_VERSION}.tar.gz | |||
tar -xf libsndfile-${LIBSNDFILE_VERSION}.tar.gz | |||
fi | |||
if [ ! -f libsndfile-${LIBSNDFILE_VERSION}/build-done ]; then | |||
cd libsndfile-${LIBSNDFILE_VERSION} | |||
./configure --enable-static --disable-shared --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} \ | |||
--disable-full-suite --disable-alsa --disable-sqlite | |||
make ${MAKE_ARGS} | |||
make install | |||
touch build-done | |||
cd .. | |||
fi | |||
# ------------------------------------------------------------------------------------ | |||
# glib | |||
if [ ! -d glib-${GLIB_VERSION} ]; then | |||
wget -c http://caesar.ftp.acc.umu.se/pub/GNOME/sources/glib/${GLIB_MVERSION}/glib-${GLIB_VERSION}.tar.gz | |||
tar -xf glib-${GLIB_VERSION}.tar.gz | |||
fi | |||
if [ ! -f glib-${GLIB_VERSION}/build-done ]; then | |||
cd glib-${GLIB_VERSION} | |||
if [ ! -f patched ]; then | |||
patch -p1 -i ../../patches/glib_skip-gettext.patch | |||
sed -i "s|po docs|po|" Makefile.in | |||
touch patched | |||
fi | |||
chmod +x configure install-sh | |||
autoconf | |||
./configure --enable-static --disable-shared --disable-docs --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} \ | |||
--with-threads=win32 | |||
make ${MAKE_ARGS} | |||
make install | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# fluidsynth | |||
if [ ! -d fluidsynth-${FLUIDSYNTH_VERSION} ]; then | |||
wget -c https://github.com/FluidSynth/fluidsynth/archive/v${FLUIDSYNTH_VERSION}.tar.gz -O fluidsynth-${FLUIDSYNTH_VERSION}.tar.gz | |||
tar -xf fluidsynth-${FLUIDSYNTH_VERSION}.tar.gz | |||
fi | |||
if [ ! -f fluidsynth-${FLUIDSYNTH_VERSION}/build-done ]; then | |||
cd fluidsynth-${FLUIDSYNTH_VERSION} | |||
if [ ! -f patched ]; then | |||
patch -p1 -i ../../patches/fluidsynth-skip-drivers-build.patch | |||
touch patched | |||
fi | |||
cmake . -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=${PREFIX} -DBUILD_SHARED_LIBS=OFF \ | |||
-Denable-debug=OFF -Denable-profiling=OFF -Denable-ladspa=OFF -Denable-fpe-check=OFF -Denable-portaudio=OFF \ | |||
-Denable-trap-on-fpe=OFF -Denable-aufile=OFF -Denable-dbus=OFF -Denable-ipv6=OFF -Denable-jack=OFF \ | |||
-Denable-midishare=OFF -Denable-oss=OFF -Denable-pulseaudio=OFF -Denable-readline=OFF -Denable-ladcca=OFF \ | |||
-Denable-lash=OFF -Denable-alsa=OFF -Denable-coreaudio=OFF -Denable-coremidi=OFF -Denable-framework=OFF \ | |||
-Denable-floats=ON \ | |||
-DCMAKE_C_COMPILER_WORKS=1 \ | |||
-DCMAKE_CROSSCOMPILING=1 \ | |||
-DCMAKE_SYSTEM_NAME="Windows" \ | |||
-DCMAKE_HOST_SYSTEM_NAME=${HOST_ARCH} | |||
make ${MAKE_ARGS} | |||
make install | |||
sed -i -e "s|-lfluidsynth|-lfluidsynth -lglib-2.0 -lgthread-2.0 -lsndfile -lFLAC -lvorbisenc -lvorbis -logg -lm -ldsound -lwinmm -lole32 -lws2_32|" ${PREFIX}/lib/pkgconfig/fluidsynth.pc | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# mxml | |||
if [ ! -d mxml-${MXML_VERSION} ]; then | |||
wget -c https://github.com/michaelrsweet/mxml/releases/download/v${MXML_VERSION}/mxml-${MXML_VERSION}.tar.gz -O mxml-${MXML_VERSION}.tar.gz | |||
tar -xf mxml-${MXML_VERSION}.tar.gz | |||
fi | |||
if [ ! -f mxml-${MXML_VERSION}/build-done ]; then | |||
cd mxml-${MXML_VERSION} | |||
./configure --disable-shared --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} | |||
make libmxml.a | |||
cp *.a ${PREFIX}/lib/ | |||
cp *.pc ${PREFIX}/lib/pkgconfig/ | |||
cp mxml.h ${PREFIX}/include/ | |||
touch build-done | |||
cd .. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# fftw3 (needs to be last as it modifies C[XX]FLAGS) | |||
if [ ! -d fftw-${FFTW3_VERSION} ]; then | |||
curl -O http://www.fftw.org/fftw-${FFTW3_VERSION}.tar.gz | |||
tar -xf fftw-${FFTW3_VERSION}.tar.gz | |||
fi | |||
if [ ! -f fftw-${FFTW3_VERSION}/build-done ]; then | |||
export CFLAGS="${CFLAGS} -ffast-math" | |||
export CXXFLAGS="${CXXFLAGS} -ffast-math" | |||
EXTRA_ARGS="" | |||
cd fftw-${FFTW3_VERSION} | |||
if [ -z "${NOSSE}" ]; then | |||
EXTRA_ARGS="--enable-sse2" | |||
fi | |||
./configure --enable-static --disable-shared --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} \ | |||
${EXTRA_ARGS} \ | |||
--disable-debug --disable-alloca --disable-fortran \ | |||
--with-our-malloc | |||
make | |||
make install | |||
make clean | |||
if [ -z "${NOSSE}" ]; then | |||
EXTRA_ARGS="--enable-sse2 --enable-sse" | |||
fi | |||
./configure --enable-static --disable-shared --prefix=${PREFIX} \ | |||
--target=${MINGW_PREFIX} --host=${MINGW_PREFIX} --build=${HOST_ARCH} \ | |||
${EXTRA_ARGS} --enable-single \ | |||
--disable-debug --disable-alloca --disable-fortran \ | |||
--with-our-malloc | |||
make | |||
make install | |||
make clean | |||
touch build-done | |||
cd .. | |||
fi | |||
} | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# build base libs | |||
cleanup_prefix | |||
cleanup_pkgs | |||
export ARCH=32 | |||
export ARCH_PREFIX=32nosse | |||
export NOSSE=1 | |||
build_base | |||
cleanup_pkgs | |||
unset NOSSE | |||
export ARCH=32 | |||
export ARCH_PREFIX=32 | |||
build_base | |||
cleanup_pkgs | |||
export ARCH=64 | |||
export ARCH_PREFIX=64 | |||
build_base | |||
cleanup_pkgs | |||
# --------------------------------------------------------------------------------------------------------------------- |
@@ -1,249 +0,0 @@ | |||
#!/bin/bash | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# stop on error | |||
set -e | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# cd to correct path | |||
cd $(dirname $0) | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# set variables | |||
source common.env | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# function to remove old stuff | |||
cleanup_prefix() | |||
{ | |||
rm -rf ${TARGETDIR}/msys2-i686 ${TARGETDIR}/msys2-x86_64 | |||
rm -rf python-pkgs-* | |||
} | |||
cleanup_pkgs() | |||
{ | |||
rm -rf Carla | |||
rm -rf Carla.exe | |||
rm -rf Carla.lv2 | |||
rm -rf Carla.vst | |||
rm -rf Carla_* | |||
rm -rf pyliblo-* | |||
} | |||
cleanup() | |||
{ | |||
cleanup_prefix | |||
cleanup_pkgs | |||
exit 0 | |||
} | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# function to download python stuff from msys2 | |||
download_python() | |||
{ | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# setup | |||
if [ x"${ARCH}" != x"32" ]; then | |||
CPUARCH="x86_64" | |||
else | |||
CPUARCH="i686" | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# list packages | |||
PACKAGES=( | |||
"binutils-2.32-3" | |||
"bzip2-1.0.8-1" | |||
"crt-git-7.0.0.5524.2346384e-1" | |||
"dbus-1.12.8-1" | |||
"double-conversion-3.1.5-1" | |||
"expat-2.2.8-1" | |||
"freetype-2.10.1-1" | |||
"gcc-9.2.0-2" | |||
"gcc-libs-9.2.0-2" | |||
"gettext-0.19.8.1-8" | |||
"glib2-2.62.1-1" | |||
"gmp-6.1.2-1" | |||
"graphite2-1.3.13-1" | |||
"harfbuzz-2.6.2-1" | |||
"icu-64.2-1" | |||
"jasper-2.0.16-1" | |||
"libffi-3.2.1-4" | |||
"libiconv-1.16-1" | |||
"libjpeg-turbo-2.0.3-1" | |||
"libpng-1.6.37-3" | |||
"libtiff-4.0.9-2" | |||
"libwebp-1.0.3-1" | |||
"libxml2-2.9.9-2" | |||
"libxslt-1.1.33-1" | |||
"libwinpthread-git-7.0.0.5522.977a9720-1" | |||
"headers-git-7.0.0.5524.2346384e-1" | |||
"openssl-1.1.1.d-1" | |||
"pcre-8.43-1" | |||
"pcre2-10.33-1" | |||
"pyqt5-common-5.13.1-1" | |||
"python3-3.7.4-7" | |||
"python3-cx_Freeze-5.1.1-3" | |||
"python3-nuitka-0.6.4-1" | |||
"python3-sip-4.19.19-1" | |||
"python3-pyqt5-5.13.1-1" | |||
"qt5-5.13.1-1" | |||
"qtwebkit-5.212.0alpha2-6" | |||
"sqlite3-3.30.0-1" | |||
"windows-default-manifest-6.4-3" | |||
"winpthreads-git-7.0.0.5522.977a9720-1" | |||
"xz-5.2.4-1" | |||
"zlib-1.2.11-7" | |||
"zstd-1.4.3-1" | |||
) | |||
# qt5-static-5.12.4-1 | |||
PKG_DIR="$(pwd)/python-pkgs-${CPUARCH}" | |||
PKG_PREFIX="mingw-w64-${CPUARCH}-" | |||
PKG_SUFFIX="-any.pkg.tar.xz" | |||
REPO_URL="http://repo.msys2.org/mingw/${CPUARCH}" | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# download stuff | |||
mkdir -p "${PKG_DIR}" | |||
pushd "${PKG_DIR}" | |||
for PKG in ${PACKAGES[@]}; do | |||
wget -c "${REPO_URL}/${PKG_PREFIX}${PKG}${PKG_SUFFIX}" | |||
done | |||
popd | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# extract into target dir | |||
rm -rf "${TARGETDIR}/msys2-${CPUARCH}" | |||
mkdir "${TARGETDIR}/msys2-${CPUARCH}" | |||
pushd "${TARGETDIR}/msys2-${CPUARCH}" | |||
for PKG in ${PACKAGES[@]}; do | |||
tar xf "${PKG_DIR}/${PKG_PREFIX}${PKG}${PKG_SUFFIX}" | |||
done | |||
sed -i "s|E:/mingwbuild/mingw-w64-qt5/pkg/mingw-w64-${CPUARCH}-qt5|${TARGETDIR}/msys2-${CPUARCH}|" ./mingw${ARCH}/lib/pkgconfig/Qt5*.pc | |||
popd | |||
} | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# function to build python modules | |||
build_python() | |||
{ | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# setup | |||
if [ x"${ARCH}" != x"32" ]; then | |||
CPUARCH="x86_64" | |||
else | |||
CPUARCH="i686" | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# clean env | |||
unset AR | |||
unset CC | |||
unset CXX | |||
unset STRIP | |||
unset WINDRES | |||
unset CFLAGS | |||
unset CPPFLAGS | |||
unset CXXFLAGS | |||
unset LDFLAGS | |||
export DEPS_PREFIX=${TARGETDIR}/carla-w${ARCH_PREFIX} | |||
export MSYS2_PREFIX=${TARGETDIR}/msys2-${CPUARCH}/mingw${ARCH} | |||
export PATH=${DEPS_PREFIX}/bin:${MSYS2_PREFIX}/bin:/usr/sbin:/usr/bin:/sbin:/bin | |||
export PKG_CONFIG_PATH=${DEPS_PREFIX}/lib/pkgconfig:${MSYS2_PREFIX}/lib/pkgconfig | |||
HOST_ARCH=$(dpkg-architecture -qDEB_BUILD_GNU_TYPE) | |||
MINGW_PREFIX="${CPUARCH}-w64-mingw32" | |||
export AR=${MINGW_PREFIX}-ar | |||
export CC=${MINGW_PREFIX}-gcc | |||
export CXX=${MINGW_PREFIX}-g++ | |||
export STRIP=${MINGW_PREFIX}-strip | |||
export WINDRES=${MINGW_PREFIX}-windres | |||
export CFLAGS="-O2 -DNDEBUG -mstackrealign -fvisibility=hidden -fdata-sections -ffunction-sections" | |||
export CFLAGS="${CFLAGS} -I${DEPS_PREFIX}/include -I${MSYS2_PREFIX}/include" | |||
export CXXFLAGS="${CFLAGS} -fvisibility-inlines-hidden" | |||
export LDFLAGS="-Wl,--gc-sections -Wl,-O1 -Wl,--as-needed -Wl,--strip-all" | |||
export LDFLAGS="${LDFLAGS} -L${DEPS_PREFIX}/lib -L${MSYS2_PREFIX}/lib" | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# pyliblo | |||
if [ ! -d pyliblo-${PYLIBLO_VERSION} ]; then | |||
wget -c http://das.nasophon.de/download/pyliblo-${PYLIBLO_VERSION}.tar.gz | |||
tar -xf pyliblo-${PYLIBLO_VERSION}.tar.gz | |||
fi | |||
if [ ! -f pyliblo-${PYLIBLO_VERSION}/build-done ]; then | |||
cd pyliblo-${PYLIBLO_VERSION} | |||
if [ ! -f patched ]; then | |||
patch -p1 -i ../../patches/pyliblo-python3.7.patch | |||
touch patched | |||
fi | |||
mkdir -p build | |||
# build | |||
${CC} -pthread -Wall ${CFLAGS} \ | |||
src/liblo.c -c -o build/liblo.o \ | |||
$(python3-config --cflags | awk 'sub("-ne ","")') \ | |||
-D_FORTIFY_SOURCE=2 -fPIC -fno-strict-aliasing \ | |||
-Wdate-time -Werror-implicit-function-declaration -Wfatal-errors | |||
# link | |||
${CC} -pthread -shared ${LDFLAGS} \ | |||
build/liblo.o -o build/liblo-cpython-37m.dll \ | |||
-llo $(python3-config --ldflags | awk 'sub("-ne ","")') -lws2_32 -liphlpapi | |||
# install | |||
install -m 644 build/liblo-cpython-37m.dll ${MSYS2_PREFIX}/lib/python3.7/site-packages/ | |||
touch build-done | |||
cd .. | |||
fi | |||
} | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# build base libs | |||
export ARCH=32 | |||
export ARCH_PREFIX=32nosse | |||
download_python | |||
build_python | |||
cleanup_pkgs | |||
export ARCH=64 | |||
export ARCH_PREFIX=64 | |||
download_python | |||
build_python | |||
cleanup_pkgs | |||
# --------------------------------------------------------------------------------------------------------------------- |
@@ -1,52 +0,0 @@ | |||
#!/bin/bash | |||
VERSION="2.3.0-alpha1" | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# stop on error | |||
set -e | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# cd to correct path | |||
if [ ! -f Makefile ]; then | |||
cd $(dirname $0)/../.. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# cleanup | |||
if [ ! -f Makefile ] || [ ! -f source/frontend/carla ]; then | |||
echo "wrong dir" | |||
exit 1 | |||
fi | |||
rm -rf data/windows/*.exe | |||
rm -rf data/windows/*.lv2 | |||
rm -rf data/windows/*.vst | |||
rm -rf data/windows/*.zip | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# start | |||
make distclean | |||
pushd data/windows | |||
./build-win.sh 32nosse | |||
./pack-win.sh 32nosse | |||
mv Carla_${VERSION}-win32.zip Carla_${VERSION}-win32-nosse.zip | |||
popd | |||
make distclean | |||
pushd data/windows | |||
./build-win.sh 32 | |||
./pack-win.sh 32 | |||
popd | |||
make distclean | |||
pushd data/windows | |||
./build-win.sh 64 | |||
./pack-win.sh 64 | |||
popd | |||
# --------------------------------------------------------------------------------------------------------------------- |
@@ -1,100 +0,0 @@ | |||
#!/bin/bash | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# check input | |||
ARCH="${1}" | |||
ARCH_PREFIX="${1}" | |||
if [ x"${ARCH}" != x"32" ] && [ x"${ARCH}" != x"32nosse" ] && [ x"${ARCH}" != x"64" ]; then | |||
echo "usage: $0 32|32nonosse|64" | |||
exit 1 | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# stop on error | |||
set -e | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# cd to correct path | |||
if [ ! -f Makefile ]; then | |||
cd $(dirname $0)/../.. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# set variables | |||
source data/windows/common.env | |||
if [ x"${ARCH}" = x"32nosse" ]; then | |||
ARCH="32" | |||
MAKE_ARGS="${MAKE_ARGS} NOOPT=true" | |||
fi | |||
MAKE_ARGS="${MAKE_ARGS} BUILDING_FOR_WINDOWS=true CROSS_COMPILING=true" | |||
export WIN32=true | |||
if [ x"${ARCH}" != x"32" ]; then | |||
export WIN64=true | |||
CPUARCH="x86_64" | |||
else | |||
CPUARCH="i686" | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
export_vars() { | |||
local _ARCH="${1}" | |||
local _ARCH_PREFIX="${2}" | |||
local _MINGW_PREFIX="${3}-w64-mingw32" | |||
export DEPS_PREFIX=${TARGETDIR}/carla-w${ARCH_PREFIX} | |||
export MSYS2_PREFIX=${TARGETDIR}/msys2-${CPUARCH}/mingw${ARCH} | |||
export PATH=${DEPS_PREFIX}/bin:/opt/wine-staging/bin:/usr/sbin:/usr/bin:/sbin:/bin | |||
export PKG_CONFIG_PATH=${DEPS_PREFIX}/lib/pkgconfig:${MSYS2_PREFIX}/lib/pkgconfig | |||
export AR=${_MINGW_PREFIX}-ar | |||
export CC=${_MINGW_PREFIX}-gcc | |||
export CXX=${_MINGW_PREFIX}-g++ | |||
export STRIP=${_MINGW_PREFIX}-strip | |||
export WINDRES=${_MINGW_PREFIX}-windres | |||
export CFLAGS="-DPTW32_STATIC_LIB -DFLUIDSYNTH_NOT_A_DLL" | |||
export CFLAGS="${CFLAGS} -I${DEPS_PREFIX}/include" | |||
export CXXFLAGS="${CFLAGS}" | |||
export LDFLAGS="-L${DEPS_PREFIX}/lib" | |||
export MOC_QT5="wine ${MSYS2_PREFIX}/bin/moc.exe" | |||
export RCC_QT5="wine ${MSYS2_PREFIX}/bin/rcc.exe" | |||
export UIC_QT5="wine ${MSYS2_PREFIX}/bin/uic.exe" | |||
} | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
export_vars "${ARCH}" "${ARCH_PREFIX}" "${CPUARCH}" | |||
export WINEARCH=win${ARCH} | |||
export WINEDEBUG=-all | |||
export WINEPREFIX=~/.winepy3_x${ARCH} | |||
export PYTHON_EXE="wine ${MSYS2_PREFIX}/bin/python.exe" | |||
export PYRCC5="${PYTHON_EXE} -m PyQt5.pyrcc_main" | |||
export PYUIC5="${PYTHON_EXE} -m PyQt5.uic.pyuic" | |||
make ${MAKE_ARGS} | |||
if [ x"${ARCH}" != x"32" ]; then | |||
export_vars "32" "32" "i686" | |||
make ${MAKE_ARGS} win32r | |||
fi | |||
# Testing: | |||
echo "export WINEPREFIX=~/.winepy3_x${ARCH}" | |||
echo "/opt/wine-staging/bin/${PYTHON_EXE} ./source/frontend/carla" | |||
# --------------------------------------------------------------------------------------------------------------------- |
@@ -1,19 +0,0 @@ | |||
#!/bin/bash | |||
PKG_CONFIG_VERSION=0.28 | |||
LIBLO_VERSION=0.30 | |||
ZLIB_VERSION=1.2.11 | |||
FILE_VERSION=5.34 | |||
LIBOGG_VERSION=1.3.4 | |||
LIBVORBIS_VERSION=1.3.6 | |||
FLAC_VERSION=1.3.2 | |||
LIBSNDFILE_VERSION=1.0.28 | |||
GLIB_VERSION=2.22.5 | |||
GLIB_MVERSION=2.22 | |||
FLUIDSYNTH_VERSION=1.1.11 | |||
MXML_VERSION=2.12 | |||
FFTW3_VERSION=3.3.8 | |||
PYLIBLO_VERSION=0.9.2 | |||
MAKE_ARGS="-j 4" | |||
TARGETDIR=${HOME}/builds |
@@ -1,34 +0,0 @@ | |||
#!/bin/bash | |||
rm -rf ~/.winepy3 | |||
rm -rf ~/.winepy3_x32 | |||
rm -rf ~/.winepy3_x86 | |||
rm -rf ~/.winepy3_x64 | |||
export WINEARCH=win32 | |||
export WINEPREFIX=~/.winepy3_x32 | |||
wineboot | |||
winetricks winxp | |||
winetricks vcrun2010 | |||
winetricks corefonts | |||
winetricks fontsmooth=rgb | |||
# cd data/windows/python | |||
# msiexec /i python-3.4.4.msi /qn | |||
# wine cx_Freeze-4.3.4.win32-py3.4.exe | |||
# wine PyQt5-5.5.1-gpl-Py3.4-Qt5.5.1-x32.exe | |||
# cd ../../.. | |||
export WINEARCH=win64 | |||
export WINEPREFIX=~/.winepy3_x64 | |||
wineboot | |||
winetricks win7 | |||
winetricks vcrun2010 | |||
winetricks corefonts | |||
winetricks fontsmooth=rgb | |||
# cd data/windows/python | |||
# msiexec /i python-3.4.4.amd64.msi /qn | |||
# wine cx_Freeze-4.3.4.win-amd64-py3.4.exe | |||
# wine PyQt5-5.5.1-gpl-Py3.4-Qt5.5.1-x64.exe | |||
# cd ../../.. |
@@ -1,311 +0,0 @@ | |||
#!/bin/bash | |||
VERSION="2.3.0-alpha1" | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# check input | |||
ARCH="${1}" | |||
ARCH_PREFIX="${1}" | |||
if [ x"${ARCH}" != x"32" ] && [ x"${ARCH}" != x"32nosse" ] && [ x"${ARCH}" != x"64" ]; then | |||
echo "usage: $0 32|32nosse|64" | |||
exit 1 | |||
fi | |||
if [ x"${ARCH}" = x"32nosse" ]; then | |||
ARCH="32" | |||
MAKE_ARGS="NOOPT=true" | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# stop on error | |||
set -e | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# cd to correct path | |||
if [ ! -f Makefile ]; then | |||
cd $(dirname $0)/../.. | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# set variables | |||
source data/windows/common.env | |||
PKG_FOLDER="Carla_${VERSION}-win${ARCH}" | |||
export WIN32=true | |||
if [ x"${ARCH}" != x"32" ]; then | |||
export WIN64=true | |||
CPUARCH="x86_64" | |||
else | |||
CPUARCH="i686" | |||
fi | |||
export PYTHONPATH="$(pwd)/source/frontend" | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
export_vars() { | |||
local _ARCH="${1}" | |||
local _ARCH_PREFIX="${2}" | |||
local _MINGW_PREFIX="${3}-w64-mingw32" | |||
export DEPS_PREFIX=${TARGETDIR}/carla-w${ARCH_PREFIX} | |||
export MSYS2_PREFIX=${TARGETDIR}/msys2-${CPUARCH}/mingw${ARCH} | |||
export PATH=${DEPS_PREFIX}/bin:/opt/wine-staging/bin:/usr/sbin:/usr/bin:/sbin:/bin | |||
export PKG_CONFIG_PATH=${DEPS_PREFIX}/lib/pkgconfig:${MSYS2_PREFIX}/lib/pkgconfig | |||
export AR=${_MINGW_PREFIX}-ar | |||
export CC=${_MINGW_PREFIX}-gcc | |||
export CXX=${_MINGW_PREFIX}-g++ | |||
export STRIP=${_MINGW_PREFIX}-strip | |||
export WINDRES=${_MINGW_PREFIX}-windres | |||
export CFLAGS="-DPTW32_STATIC_LIB -DFLUIDSYNTH_NOT_A_DLL" | |||
export CFLAGS="${CFLAGS} -I${DEPS_PREFIX}/include" | |||
export CXXFLAGS="${CFLAGS}" | |||
export LDFLAGS="-L${DEPS_PREFIX}/lib" | |||
export WINEARCH=win${ARCH} | |||
export WINEDEBUG=-all | |||
export WINEPREFIX=~/.winepy3_x${ARCH} | |||
export PYTHON_EXE="wine ${MSYS2_PREFIX}/bin/python.exe" | |||
export CXFREEZE="${PYTHON_EXE} ${MSYS2_PREFIX}/bin/cxfreeze" | |||
} | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
export_vars "${ARCH}" "${ARCH_PREFIX}" "${CPUARCH}" | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
cd data/windows/ | |||
rm -rf Carla Carla.lv2 Carla.vst CarlaControl | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# freeze carla (console and gui) | |||
${PYTHON_EXE} ./app-console.py build_exe | |||
mv Carla/lib/library.zip Carla/lib/library-console.zip | |||
${PYTHON_EXE} ./app-gui.py build_exe | |||
mv Carla/lib/library.zip Carla/lib/library-gui.zip | |||
mkdir Carla/lib/_lib | |||
pushd Carla/lib/_lib | |||
unzip -o ../library-console.zip | |||
unzip -o ../library-gui.zip | |||
zip -r -9 ../library.zip * | |||
popd | |||
rm -r Carla/lib/_lib Carla/lib/library-*.zip | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# freeze carla-control | |||
${PYTHON_EXE} ./app-control.py build_exe | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# freeze pyqt plugin uis (resources) | |||
TARGET_NAME="bigmeter-ui" ${PYTHON_EXE} ./app-plugin-ui.py build_exe | |||
mv Carla/resources/lib/library.zip Carla/resources/lib/library-bigmeter.zip | |||
TARGET_NAME="midipattern-ui" ${PYTHON_EXE} ./app-plugin-ui.py build_exe | |||
mv Carla/resources/lib/library.zip Carla/resources/lib/library-midipattern.zip | |||
TARGET_NAME="notes-ui" ${PYTHON_EXE} ./app-plugin-ui.py build_exe | |||
mv Carla/resources/lib/library.zip Carla/resources/lib/library-notes.zip | |||
TARGET_NAME="xycontroller-ui" ${PYTHON_EXE} ./app-plugin-ui.py build_exe | |||
mv Carla/resources/lib/library.zip Carla/resources/lib/library-xycontroller.zip | |||
TARGET_NAME="carla-plugin" ${PYTHON_EXE} ./app-plugin-ui.py build_exe | |||
mv Carla/resources/lib/library.zip Carla/resources/lib/library-carla1.zip | |||
TARGET_NAME="carla-plugin-patchbay" ${PYTHON_EXE} ./app-plugin-ui.py build_exe | |||
mv Carla/resources/lib/library.zip Carla/resources/lib/library-carla2.zip | |||
mkdir Carla/resources/lib/_lib | |||
pushd Carla/resources/lib/_lib | |||
unzip -o ../library-bigmeter.zip | |||
unzip -o ../library-midipattern.zip | |||
unzip -o ../library-notes.zip | |||
unzip -o ../library-xycontroller.zip | |||
unzip -o ../library-carla1.zip | |||
unzip -o ../library-carla2.zip | |||
zip -r -9 ../library.zip * | |||
popd | |||
rm -r Carla/resources/lib/_lib Carla/resources/lib/library-*.zip | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# cleanup pyqt stuff | |||
find Carla CarlaControl -name "QAxContainer*" -delete | |||
find Carla CarlaControl -name "QtDBus*" -delete | |||
find Carla CarlaControl -name "QtDesigner*" -delete | |||
find Carla CarlaControl -name "QtBluetooth*" -delete | |||
find Carla CarlaControl -name "QtHelp*" -delete | |||
find Carla CarlaControl -name "QtLocation*" -delete | |||
find Carla CarlaControl -name "QtMultimedia*" -delete | |||
find Carla CarlaControl -name "QtMultimediaWidgets*" -delete | |||
find Carla CarlaControl -name "QtNetwork*" -delete | |||
find Carla CarlaControl -name "QtNetworkAuth*" -delete | |||
find Carla CarlaControl -name "QtNfc*" -delete | |||
find Carla CarlaControl -name "QtPositioning*" -delete | |||
find Carla CarlaControl -name "QtPrintSupport*" -delete | |||
find Carla CarlaControl -name "QtQml*" -delete | |||
find Carla CarlaControl -name "QtQuick*" -delete | |||
find Carla CarlaControl -name "QtQuickWidgets*" -delete | |||
find Carla CarlaControl -name "QtRemoteObjects*" -delete | |||
find Carla CarlaControl -name "QtSensors*" -delete | |||
find Carla CarlaControl -name "QtSerialPort*" -delete | |||
find Carla CarlaControl -name "QtSql*" -delete | |||
find Carla CarlaControl -name "QtTest*" -delete | |||
find Carla CarlaControl -name "QtWebChannel*" -delete | |||
find Carla CarlaControl -name "QtWebKit*" -delete | |||
find Carla CarlaControl -name "QtWebKitWidgets*" -delete | |||
find Carla CarlaControl -name "QtWebSockets*" -delete | |||
find Carla CarlaControl -name "QtWinExtras*" -delete | |||
find Carla CarlaControl -name "QtXml*" -delete | |||
find Carla CarlaControl -name "QtXmlPatterns*" -delete | |||
find Carla CarlaControl -name "*.pyi" -delete | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# copy relevant files to binary dir | |||
cp ../../bin/libcarla_utils.dll Carla/ | |||
mkdir -p Carla/imageformats | |||
cp ${MSYS2_PREFIX}/share/qt5/plugins/imageformats/qsvg.dll Carla/imageformats/ | |||
mkdir -p Carla/platforms | |||
cp ${MSYS2_PREFIX}/share/qt5/plugins/platforms/qwindows.dll Carla/platforms/ | |||
mkdir -p Carla/styles | |||
cp ../../bin/styles/carlastyle.dll Carla/styles/ | |||
cp ${MSYS2_PREFIX}/bin/Qt5{Core,Gui,OpenGL,Svg,Widgets}.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libbz2-1.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libcrypto-1_*.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libdouble-conversion.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libffi-6.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libfreetype-6.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libgcc_s_*.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libglib-2.0-0.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libgraphite2.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libharfbuzz-0.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libiconv-2.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libicudt64.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libicuin64.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libicuuc64.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libintl-8.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libpcre-1.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libpcre2-16-0.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libpng16-16.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libpython3.7m.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libstdc++-6.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libwinpthread-1.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/libzstd.dll Carla/ | |||
cp ${MSYS2_PREFIX}/bin/zlib1.dll Carla/ | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# also for CarlaControl | |||
cp Carla/*.dll CarlaControl/ | |||
mkdir -p CarlaControl/imageformats | |||
cp ${MSYS2_PREFIX}/share/qt5/plugins/imageformats/qsvg.dll CarlaControl/imageformats/ | |||
mkdir -p CarlaControl/platforms | |||
cp ${MSYS2_PREFIX}/share/qt5/plugins/platforms/qwindows.dll CarlaControl/platforms/ | |||
mkdir -p CarlaControl/styles | |||
cp ../../bin/styles/carlastyle.dll CarlaControl/styles/ | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# Carla standalone specifics | |||
cp ../../bin/libcarla_standalone2.dll Carla/ | |||
cp ../../bin/carla-bridge-lv2.dll Carla/ | |||
cp ../../bin/carla-bridge-*.exe Carla/ | |||
cp ../../bin/carla-discovery-win*.exe Carla/ | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# prepare lv2 bundle | |||
mkdir -p Carla.lv2 | |||
cp -r Carla/* Carla.lv2/ | |||
cp ../../bin/carla.lv2/*.dll Carla.lv2/ | |||
cp ../../bin/carla.lv2/*.ttl Carla.lv2/ | |||
mv Carla.lv2/{Qt5,lib,zlib}*.dll Carla.lv2/resources/ | |||
mv Carla.lv2/resources/libcarla_utils.dll Carla.lv2/ | |||
rm Carla.lv2/Carla.exe | |||
rm Carla.lv2/CarlaDebug.exe | |||
rm Carla.lv2/resources/libcarla_standalone2.dll | |||
rm -r Carla.lv2/lib | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# copy relevant files to binary dir | |||
mkdir -p Carla.vst | |||
cp -r Carla/* Carla.vst/ | |||
cp ../../bin/CarlaVst*.dll Carla.vst/ | |||
mv Carla.vst/{Qt5,lib,zlib}*.dll Carla.vst/resources/ | |||
mv Carla.vst/resources/libcarla_utils.dll Carla.vst/ | |||
rm Carla.vst/Carla.exe | |||
rm Carla.vst/CarlaDebug.exe | |||
rm Carla.vst/resources/libcarla_standalone2.dll | |||
rm -r Carla.vst/lib | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# stop here for development | |||
if [ x"${CARLA_DEV}" != x"" ]; then | |||
exit 0 | |||
fi | |||
# --------------------------------------------------------------------------------------------------------------------- | |||
# create self-contained zip | |||
# Build unzipfx | |||
make -C unzipfx-carla -f Makefile.win32 clean | |||
make -C unzipfx-carla -f Makefile.win32 ${MAKE_ARGS} | |||
# Build unzipfx-control | |||
make -C unzipfx-carla-control -f Makefile.win32 clean | |||
make -C unzipfx-carla-control -f Makefile.win32 ${MAKE_ARGS} | |||
# Create zip of Carla and CarlaControl | |||
rm -f Carla.zip CarlaControl.zip | |||
mv Carla Carla-${VERSION} | |||
mv CarlaControl CarlaControl-${VERSION} | |||
zip -r -9 Carla.zip Carla-${VERSION} | |||
zip -r -9 CarlaControl.zip CarlaControl-${VERSION} | |||
# Create static builds | |||
rm -f Carla.exe | |||
cat unzipfx-carla/unzipfx2cat.exe Carla.zip > Carla.exe | |||
chmod +x Carla.exe | |||
rm -f CarlaControl.exe | |||
cat unzipfx-carla-control/unzipfx2cat.exe CarlaControl.zip > CarlaControl.exe | |||
chmod +x CarlaControl.exe | |||
# Cleanup | |||
rm -f Carla.zip CarlaControl.zip | |||
rm -rf Carla-${VERSION} CarlaControl-${VERSION} | |||
# Create release zip | |||
rm -rf ${PKG_FOLDER} | |||
mkdir ${PKG_FOLDER} | |||
cp -r Carla.exe CarlaControl.exe Carla.lv2 Carla.vst README.txt ${PKG_FOLDER} | |||
unix2dos ${PKG_FOLDER}/README.txt | |||
zip -r -9 ${PKG_FOLDER}.zip ${PKG_FOLDER} | |||
cd ../.. | |||
# --------------------------------------------------------------------------------------------------------------------- |