# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 PortSystem 1.0 PortGroup cmake 1.1 PortGroup compiler_blacklist_versions 1.0 PortGroup github 1.0 github.setup FNA-XNA FAudio 24.04 revision 0 license zlib categories audio maintainers {@barracuda156 gmail.com:vital.had} openmaintainer description XAudio reimplementation long_description an XAudio reimplementation that focuses solely on developing \ fully accurate DirectX Audio runtime libraries for the FNA project,\ including XAudio2, X3DAudio, XAPO, and XACT3. depends_lib-append port:libsdl2 checksums rmd160 81624bc13bf83772f4b3261da1a7d6d5b6051837 \ sha256 a132b6c6162a5e110210c678ac0524dc3f0b0da9e845e64e68edd1a9a5da88e3 \ size 1122950 github.tarball_from archive # remove set deployment target and hard-coded RPATH setting patchfiles patch-faudio-remove-deployment-target.diff configure.args -DBUILD_UTILS=OFF \ -DBUILD_TESTS=ON \ -DXNASONG=ON \ -DCMAKE_INSTALL_INCLUDEDIR=include/FAudio # https://github.com/FNA-XNA/FAudio/issues/321 # Xcode clang on 10.6 also fails to build it. # FAudio.h: error: wrong number of arguments specified for ‘deprecated’ attribute compiler.blacklist-append \ *gcc-4.* {clang < 421} # On Sonoma this fails at the moment: # ld: warning: alignment (4) of atom '_FACT3DCalculate.DefaultCurve' # from '/opt/local/var/macports/build/_opt_svacchanda_SonomaPorts_audio_FAudio/FAudio/work/build/CMakeFiles/FAudio.dir/src/FACT3D.c.o' # is too small and may result in unaligned pointers. # Temporary fix by setting deployment target to Big Sur. # Related: https://github.com/ldc-developers/ldc/issues/3864 platform darwin 23 arm { macosx_deployment_target 11.0 } #pre-destroot { # there are some utilities to consider, but the facttool segfaulted when I tried to open an audio engine # they are not installed by default with the cmake install script, and other pkg systems don't install them # they can be re-enabled by toggling -DBUILD_UTILS=ON, and manually installed like so if desired # file copy ${workpath}/build/facttool ${destroot}${prefix}/bin/ #} test.run yes # Otherwise it looks in prefix, and if the port has not been installed earlier, that fails: # dyld: Library not loaded: /opt/local/lib/libFAudio.0.dylib # On PowerPC tests do not run: https://github.com/FNA-XNA/FAudio/issues/319 test.env-append DYLD_LIBRARY_PATH=${cmake.build_dir} test.cmd ./faudio_tests test.target