Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

Building

Turion64 edited this page Jan 22, 2022 · 8 revisions

Prerequisites

  • python3 >= 3.5
  • conan >= 1.32.0
  • cmake >= 3.16
  • A working C++17 compiler

Conan

The best way to install Conan is pip.

pip install conan

You might need to use sudo on macOS and Linux.

Alternatively, on macOS, Conan is available from brew.

CMake

On Windows, use the prebuilt binaries.

On macOS, install CMake with brew install cmake.

On Linux, install CMake from your package manager.

Building

First, clone the repository : git clone https://github.com/SartoxOnlyGNU/audacium

After that, follow the steps for your platform below.

Windows

We build Audacium using Microsoft Visual Studio 2019. In order to build the project, the workload Desktop development with C++ is required.

As we require C++17, MSVC 2017 should work fine too.

  1. Open CMake GUI.

    Set Where is the source code to the location where Audacium was cloned.

    Set Where to build the binaries to the location you want to place your build in. It is preferred that this location is not within the directory with the source code.

  2. Press Configure.

    You can choose which version of Visual Studio to use and the platform to build for in the pop-up. We support the x64 and Win32 platforms. Press Finish to start the configuration process.

  3. After successful configuration, you will see Configuring done as the last line in the log. Press Generate to generate the Visual Studio project.

  4. After you see Generating done, press Open Project to open the project in Visual Studio.

  5. You can now build and run Audacium!

Generally, steps 1-4 are only needed the first-time you configure. Then, after you've generated the solution, you can open it in Visual Studio the next time. If the project configuration has changed, the IDE will invoke CMake internally.

NOTE : Conan Center provides prebuilt binaries only for x64. Configuring the project for Win32 will take much longer, as all the 3rd party libraries will be built during the configuration.

macOS

We build Audacium using XCode 12. However, it is likely possible to build it with XCode 7.

Alternatively, you can use CLion. If you chose to do so, open the directory where you have cloned Audacium using CLion and you are good to go (no need to follow the steps below).

  1. Configure Audacium using CMake.

    $ mkdir build && cd build
    $ cmake -GXcode -T buildsystem=1 ..
    

    At the moment we only support x86_64 builds. It is possible to build using AppleSilicon hardware but mad and id3tag should be disabled like so :

    $ cmake -GXcode -T buildsystem=1 -Daudacity_use_mad=off -Daudacity_use_id3tag=off ..
    
  2. Open the Audacium XCode project, then build using the IDE.

    $ open Audacium.xcodeproj
    

Those steps are only required for first-time builds.

Linux

We use GCC 11, but any C++17 compliant compiler should work.

On Debian or Ubuntu, you can install everything required using the following commands :

$ sudo apt update && sudo apt dist-upgrade
$ sudo apt install -y build-essential cmake git python3-pip libgtk2.0-dev libasound2-dev libavformat-dev libjack-jackd2-dev uuid-dev
  1. Configure Audacium using CMake.

    $ ./configure.sh
    

    By default, Debug build will be configured. To change that, pass the -DCMAKE_BUILD_TYPE=Release argument to the cmake command inside the configure.sh script.

  2. Go to the builds folder.

    $ cd builds
    
  3. Build Audacium.

    $ make -j`nproc`
    
  4. Test the build.

    Adding a "Portable Settings" folder allows Audacium to ignore the settings of any existing Audacium installation.

    $ cd bin/Debug
    $ mkdir "Portable Settings"
    $ ./audacium
    

Advanced

CMake options

You can use cmake -LH to get a list of the options available (or use CMake GUI or ccmake). The list will include documentation about each option. For your convenience, here is a list of the most notable options.

Building using system libraries

On Linux it is possible to build Audacium using (almost) only the libraries provided by the package manager. Please see the list of required libraries here first though.

$ mkdir build && cd build
$ cmake -G "Unix Makefiles" \
        -Daudacity_use_ffmpeg=loaded \
        -Daudacity_lib_preference=system \
        -Daudacity_obey_system_dependencies=On \
         ../audacium

There are a few librairies that are integrated into Audacium though :

  1. wxWidgets : While Audacium on Linux uses vanilla version of wxWidgets, we require that version 3.1.3 is used. This version is not available in most of the distributions.
  2. portaudio-v19 : Audacium currently uses some custom patches, so using system portaudio is not yet possible.
  3. vamp-host-sdk : Development packages are not available in Ubuntu 20.04.
  4. libnyquist & portmixer : Libraries are not available in Ubuntu 20.04.
  5. sqlite3 & libsmbs : Libraries are very outdated in Ubuntu 20.04.

It is not advised to mix system and local libraries, except for the list above. zlib is a very common dependency; it is possible to mix system and local libraries in one build. However, we advise against doing so.

To find the system packages, we rely on pkg-config. There are several packages that have broken *.pc or do not use pkg-config at all.

Clone this wiki locally