...
A development machine running Windows ARM64 (Surface, Thinkpad, Project Volterra, Windows VM on Apple M2):
Setup necessary build tools. Follow the steps from wenv
Download Audacity source from https://github.com/audacity/audacity
Steps
Clone
Code Block |
---|
git clone https://github.com/audacity/audacity cd audacity # current master is under a major refactoring, so we build stable branch instead. # https://github.com/audacity/audacity?tab=readme-ov-file#this-repository-is-currently-undergoing-major-structural-change git checkout Audacity-3.7.1 |
Patch
Seems like a header change for MSVC broke compilation (at least with latest VS2022).
...
Code Block |
---|
diff --git a/libraries/lib-project-file-io/DBConnection.cpp b/libraries/lib-project-file-io/DBConnection.cpp index 26d6d0e87..6c039a986 100644 --- a/libraries/lib-project-file-io/DBConnection.cpp +++ b/libraries/lib-project-file-io/DBConnection.cpp @@ -13,6 +13,7 @@ Paul Licameli -- split from ProjectFileIO.cpp #include "sqlite3.h" +#include <chrono> #include <wx/string.h> #include "AudacityLogger.h" diff --git a/modules/import-export/mod-cl/ExportCL.cpp b/modules/import-export/mod-cl/ExportCL.cpp index 3f0ab7848..d97973389 100644 --- a/modules/import-export/mod-cl/ExportCL.cpp +++ b/modules/import-export/mod-cl/ExportCL.cpp @@ -13,6 +13,7 @@ #include "ProjectRate.h" +#include <chrono> #include <thread> #include <wx/app.h> |
...
Build
Code Block |
---|
# Open MSYS2 bash shell cmd.exe /c C:/wenv/arm64/activate.bat bash # from this shell python -m pip install conan conan profile detect cat > global.conf << EOF tools.microsoft.bash:path=c:/wenv/msys2/msys64/usr/bin/bash.exe tools.microsoft.bash:subsystem=msys2 EOF conan config install global.conf rm global.conf |
Once the environment configuration is set up, building a binary is simple as following these steps :
Code Block |
---|
# now perform the build
mkdir build
cd build
cmake -A arm64 -S ../ -B .
cmake --build . --config Release |
...