####################################################################################################
################################### BUILDING POLYPHONE FOR LINUX ###################################
####################################################################################################


######### 1. Prerequisite ##########################################################################

The following libraries are required (the name may vary depending on your system):
 - qt          (qtbase5-dev / qt5-devel) (also libqt5svg5-dev)
 - alsa        (libasound2-dev / alsa-lib-devel)
 - jack        (libjack-jack2-dev / jack-audio-connection-kit-devel)
 - portaudio   (portaudio19-dev / portaudio-devel)
 - rtmidi      (librtmidi-dev)
 - stk         (libstk0-dev)
 - qcustomplot (libqcustomplot-dev)
 - vorbis      (libvorbis-dev)
 - ogg         (libogg-dev)
 - wolfssl     (libwolfssl-dev)
 - flac        (libflac-dev)

Use your package manager to install them: apt, synaptic, yum,...


######### 2. Build #################################################################################

Run "qmake -qt5 && make" (or qmake-qt5 && make) in the root directory to compile the project. An
executable file "polyphone" in the directory "RELEASE" should then appear if everything went right.

Note: If you are using QT Creator, the project may be opened via its .pro file present in the root 
directory.

If you experience compiling issues related to RtMidi, Stk, or QCustomplot you can opt to use the
local copies that come with Polyphone by commenting out the related lines at the top of
`polyphone.pro`:

```
# Use local copies of RtMidi, Stk and QCustomplot libraries
# (this is forced to true for Windows or Mac OS X)
# Uncomment a line if your distribution doesn't come with some of the following libraries
#DEFINES += USE_LOCAL_RTMIDI
#DEFINES += USE_LOCAL_STK
#DEFINES += USE_LOCAL_QCUSTOMPLOT
```


####################################################################################################
################################## BUILDING POLYPHONE FOR MAC OS X #################################
####################################################################################################


######### 1. Prerequisite ##########################################################################

The following applications are required:
 - Xcode (available in app store)
 - qt    (http://qt-project.org/downloads)


######### 2. Build #################################################################################

Open polyphone.pro with QT Creator. When configuring the project, take care shadow build is not
checked.
Build the project, a bundle should appear in the directory "RELEASE".


######### 3. Complete the bundle ###################################################################

Run the following command to include libraries and frameworks inside the bundle (adjust the path
first!):
/Path/To/Qt/5.2.0/clang_64/bin/macdeployqt /Path/To/trunk/RELEASE/Polyphone.app

Copy / paste the framework Jackmp from trunk/lib/mac to:
trunk/RELEASE/Polyphone.app/Contents/Frameworks

Finally, run the following command in a single line (adjust the last path first!):
install_name_tool -change /System/Library/Frameworks/Jackmp.framework/Versions/A/Jackmp 
@executable_path/../Frameworks/Jackmp.framework/Versions/A/Jackmp 
/Path/To/trunk/RELEASE/Polyphone.app/Contents/MacOS/Polyphone 

If you want to provide a .dmg file, drag the file Polyphone.app onto the icon of the application
"Disk Utility".



####################################################################################################
###################################### TRANSLATING POLYPHONE #######################################
####################################################################################################


If you want to add a new translation or improve an existing one, please see this page:
https://www.polyphone-soundfonts.com/en/documentation/development/translate-polyphone/122
