lol

piper: Apply patch to build with onnxruntime 1.15.1

authored by

Christian Bourjau and committed by
Martin Weinelt
6ae62cd2 a21ee82a

+22
+4
pkgs/tools/audio/piper/default.nix
··· 25 25 26 26 sourceRoot = "source/src/cpp"; 27 27 28 + patches = [ 29 + ./fix-compilation-with-newer-onnxruntime.patch 30 + ]; 31 + 28 32 postPatch = '' 29 33 substituteInPlace CMakeLists.txt \ 30 34 --replace "/usr/local/include/onnxruntime" "${onnxruntime}"
+18
pkgs/tools/audio/piper/fix-compilation-with-newer-onnxruntime.patch
··· 1 + diff --git a/src/cpp/synthesize.hpp b/src/cpp/synthesize.hpp 2 + index ef61aef..4c7db7a 100644 3 + --- a/synthesize.hpp 4 + +++ b/synthesize.hpp 5 + @@ -119,11 +119,11 @@ void synthesize(SynthesisConfig &synthesisConfig, ModelSession &session, 6 + 7 + // Clean up 8 + for (size_t i = 0; i < outputTensors.size(); i++) { 9 + - Ort::OrtRelease(outputTensors[i].release()); 10 + + Ort::detail::OrtRelease(outputTensors[i].release()); 11 + } 12 + 13 + for (size_t i = 0; i < inputTensors.size(); i++) { 14 + - Ort::OrtRelease(inputTensors[i].release()); 15 + + Ort::detail::OrtRelease(inputTensors[i].release()); 16 + } 17 + } 18 + } // namespace larynx