-
Notifications
You must be signed in to change notification settings - Fork 66
Developer's Guide
Clone this repo and update submodules: git submodule update --init --recursive
Then go to thirdparty/libfaust
. On macOS/Linux, run sh download_libfaust.sh
, and on Windows run call download_libfaust.bat
.
If you don't already have python3 installed, do
apt-get install -yq --no-install-recommends python3 python3.10-dev
Then set these environment variables, confirming that they make sense for your system.
export PYTHONLIBPATH=/usr/lib/python3.10
export PYTHONINCLUDEPATH=/usr/include/python3.10
Then look at the content of the script build_linux.sh
. If you're on Ubuntu instead of CentOS, then instead of the yum install
command, you'd substitute the following:
apt-get install -yq --no-install-recommends \
ca-certificates \
build-essential \
clang \
pkg-config \
libboost-all-dev \
libboost-python-dev \
libfreetype6-dev \
libx11-dev \
libxinerama-dev \
libxrandr-dev \
libxcursor-dev \
mesa-common-dev \
libasound2-dev \
freeglut3-dev \
libxcomposite-dev \
libcurl4-gnutls-dev \
git \
cmake \
python3 \
python3.10-dev
After confirming build_linux.sh
makes sense for your operating system, run sh build_linux.sh
. When it finishes, you can proceed to the section "Building a Wheel".
To build an image with the Dockerfile
, run:
docker build -t dawdreamer .
Then run the dockerfile:
docker run -it dawdreamer /bin/bash
See https://github.com/DBraun/DawDreamer/issues/82#issuecomment-1097937567
- CMake
- Python
- On Windows install Python 3.11.x Windows x86-64 to
C:/Python311
- On macOS install with the standard settings (including the Pylauncher) Python 3.11.3 (macOS) Universal Installer
- On Windows install Python 3.11.x Windows x86-64 to
These are case-sensitive and feel free to replace 3.11
for your needs.
-
PYTHONMAJOR
: 3.11 -
pythonLocation
:-
C:\Python311
on Windows -
/Library/Frameworks/Python.framework/Versions/3.11
on macOS -
/usr/local/opt/python@3.11/Frameworks/Python.framework/Versions/3.11
on macOS, if you installed Python with homebrew
-
The Faust Libraries should already be in the dawdreamer/faustlibraries
directory of this repo. If you aren't going to create a wheel, you need to copy the Faust Libraries to a specific location:
- macOS / Linux: Download Faust Libraries to
/usr/local/share/faust
or/usr/share/faust
. Example file path:/usr/local/share/faust/stdfaust.lib
- Windows: Download Faust Libraries to
C:/share/faust
. The reason is that we're usingC:/Python311/python.exe
, so the sibling directory would beC:/share/faust
. Example file path:C:/Python39/share/faust/stdfaust.lib
cd thirdparty/libsamplerate
cmake -DCMAKE_BUILD_TYPE=Release -Bbuild_release
cmake --build build_release --config Release
You can find a working Linux Makefile, Visual Studio Solution, and Xcode Project in the Builds/
folder. If you want to make changes, the best way is to get JUCE's Projucer and open DawDreamer.jucer
.
In an x64 Native Tools Command Prompt for Visual Studio 2022, run msbuild Builds/VisualStudio2022/DawDreamer.sln /property:Configuration=Release
. This will automatically use a post-build command which moves the recently built dawdreamer.dll
to C:/Python311/dawdreamer.pyd
.
On macOS, Xcode 15 will not work. You should have Xcode 14 installed.
On macOS, you can run build_macos.sh
. Note that it will move the dawdreamer.so
to the tests
folder so that you can run the tests there without building and installing a wheel.
On macOS you should define your architecture type such as
export ARCHS=x86_64
orexport ARCHS=arm64
We will build a wheel inside the root of this DawDreamer repo. Start by installing the build
and wheel
modules:
python -m pip install build wheel
Then build the wheel:
python -m build --wheel
Then install the wheel:
python -m pip install dist/dawdreamer.whl
with the correct file path to the wheel.
Go to the tests
directory and follow the instructions.