Last active
February 16, 2023 13:03
-
-
Save singingwolfboy/b2e33d9bc5d876593dc71f153d4f461f to your computer and use it in GitHub Desktop.
Failing build for torchaudio
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ 43%] Building CXX object torchaudio/csrc/CMakeFiles/_torchaudio_ffmpeg.dir/ffmpeg/pybind/pybind.cpp.o | |
cd /tmp/torchaudio-20230216-95817-nuezt6/build/torchaudio/csrc && /opt/homebrew/Library/Homebrew/shims/mac/super/clang++ -DUSE_C10D_GLOO -DUSE_DISTRIBUTED -DUSE_RPC -DUSE_TENSORPIPE -D_torchaudio_ffmpeg_EXPORTS -I/tmp/torchaudio-20230216-95817-nuezt6 -isystem /opt/homebrew/include/torch/csrc/api/include -Wall -O3 -DNDEBUG -arch arm64 -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX13.sdk -fPIC -std=gnu++14 -MD -MT torchaudio/csrc/CMakeFiles/_torchaudio_ffmpeg.dir/ffmpeg/pybind/pybind.cpp.o -MF CMakeFiles/_torchaudio_ffmpeg.dir/ffmpeg/pybind/pybind.cpp.o.d -o CMakeFiles/_torchaudio_ffmpeg.dir/ffmpeg/pybind/pybind.cpp.o -c /tmp/torchaudio-20230216-95817-nuezt6/torchaudio/csrc/ffmpeg/pybind/pybind.cpp | |
In file included from /tmp/torchaudio-20230216-95817-nuezt6/torchaudio/csrc/ffmpeg/pybind/pybind.cpp:1: | |
In file included from /opt/homebrew/include/pybind11/stl.h:12: | |
In file included from /opt/homebrew/include/pybind11/pybind11.h:13: | |
In file included from /opt/homebrew/include/pybind11/detail/class.h:12: | |
In file included from /opt/homebrew/include/pybind11/detail/../attr.h:13: | |
/opt/homebrew/include/pybind11/detail/common.h:266:10: fatal error: 'Python.h' file not found | |
#include <Python.h> | |
^~~~~~~~~~ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Torchaudio < Formula | |
include Language::Python::Virtualenv | |
desc "Data manipulation and transformation for audio signal processing" | |
homepage "https://github.com/pytorch/audio" | |
url "https://github.com/pytorch/audio.git", | |
tag: "v0.13.1", | |
revision: "b90d79882c3521fb3882833320b4b85df3b622f4" | |
license "BSD-2-Clause" | |
livecheck do | |
url :stable | |
regex(/^v?(\d+(?:\.\d+)+)$/i) | |
end | |
depends_on "cmake" => :build | |
depends_on "ninja" => :build | |
depends_on "pkg-config" => :build | |
depends_on "[email protected]" => [:build, :test] | |
depends_on "ffmpeg" | |
depends_on "pytorch" | |
depends_on "sentencepiece" | |
on_macos do | |
depends_on "libomp" | |
end | |
resource "sentencepiece" do | |
url "https://files.pythonhosted.org/packages/ec/87/f26695307c0aa00e6938f5de795fc7f2c718a448b48d29a4c8c8dbf829d3/sentencepiece-0.1.97.tar.gz" | |
sha256 "c901305e0a710bbcd296f66d79e96f744e6e175b29812bd5178318437d4e1f6c" | |
end | |
def install | |
python_exe = Formula["[email protected]"].opt_libexec/"bin/python" | |
args = %W[ | |
-DBUILD_TORCHAUDIO_PYTHON_EXTENSION=ON | |
-DPYTHON_EXECUTABLE=#{python_exe} | |
-DUSE_OPENMP=ON | |
-DUSE_FFMPEG=ON | |
] | |
ENV.append "CPPFLAGS", "-I#{Formula["[email protected]"].opt_include}" | |
system "cmake", "-S", ".", "-B", "build", *std_cmake_args, *args | |
system "cmake", "--build", "build" | |
system "cmake", "--install", "build" | |
virtualenv_install_with_resources using: "[email protected]" | |
pkgshare.install "examples" | |
end | |
test do | |
# todo | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment