Comments (32)
So your Homebrew installation lives in
/opt/homebrew
(which is where it would typically be under Apple Silicon), and yourflite
installation is in/usr/local/lib
which would be Homebrew's previous location (under x64). Indeedclang
can't find the libraries and therefore fails.Assuming the headers are in /usr/local/include, you should add
-I/usr/local/include
explicitly to theclang
command. Homebrew does not do that on its own, see: https://github.com/orgs/Homebrew/discussions/868Can you try with:
export CPPFLAGS=-I/usr/local/include" brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-chromaprint --with-decklink --with-fdk-aac --with-libflite --with-game-music-emu --with-harfbuzz --with-jack --with-jpeg-xl --with-libaribb24 --with-libaribcaption --with-libmodplug --with-libopenmpt --with-librist --with-librsvg --with-libsoxr --with-libssh --with-tesseract --with-libvidstab --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rav1e --with-svt-av1 --with-rtmpdump --with-rubberband --with-two-lame --with-webp --with-xvid --with-zeromq --with-zimg --with-srt --with-libvmaf --with-libxml2 --with-libzvbi --with-aribb24 --with-libbluray --with-libbs2b --with-libcaca --with-libgsm [email protected] --with-speex
I try
export CPPFLAGS=-I/usr/local/include"
It doesn’t work. but you inspired me.
Then I tried this
ln -s /usr/local/lib/libflite* /opt/homebrew/lib/
ln -s /usr/local/include/flite /opt/homebrew/include/flite
brew reinstall homebrew-ffmpeg/ffmpeg/ffmpeg --with-chromaprint --with-decklink --with-fdk-aac --with-libflite --with-game-music-emu --with-harfbuzz --with-jack --with-jpeg-xl --with-libaribb24 --with-libaribcaption --with-libmodplug --with-libopenmpt --with-librist --with-librsvg --with-libsoxr --with-libssh --with-tesseract --with-libvidstab --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rav1e --with-svt-av1 --with-rtmpdump --with-rubberband --with-two-lame --with-webp --with-xvid --with-zeromq --with-zimg --with-srt --with-libvmaf --with-libxml2 --with-libzvbi --with-aribb24 --with-libbluray --with-libbs2b --with-libcaca --with-libgsm [email protected] --with-speex
and I reinstalled it successfully.
So, I am summarizing how to install FFmpeg on Apple Silicon.
- Install Flite
git clone https://github.com/festvox/flite.git
cd flite/
./configure
make
sudo make install
- Make there are links.
ln -s /usr/local/lib/libflite* /opt/homebrew/lib/
ln -s /usr/local/include/flite /opt/homebrew/include/flite
- Follow Readme
brew install homebrew-ffmpeg/ffmpeg/ffmpeg $(brew options homebrew-ffmpeg/ffmpeg/ffmpeg --compact)
It works for me.
from homebrew-ffmpeg.
Why do you not write a Homebrew formula for Flite?
I am not a maintainer for flite or homebrew core
You have to be neither to do that. Anyone can provide a formula.
from homebrew-ffmpeg.
I will check if it's possible to link against non-Homebrew libraries
It's not supported, but sure, check. The rest of us understand that you cannot maintain a functioning, up-to-date, dependency hierarchy when you start mixing in unmanaged packages.
There is a solution that involves creating a symlink.
monkeying with homebrew and breaking the mechanics is a hack. Not a solution
As said, there is a solution that I'm well aware of is not a reliable one. Please take this kind of demeaning and snarky attitude somewhere else. You're free to not use this option if it doesn't work for you.
from homebrew-ffmpeg.
The exact command you were trying to run:
brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-chromaprint --with-decklink --with-fdk-aac --with-libflite --with-game-music-emu --with-harfbuzz --with-jack --with-jpeg-xl --with-libaribb24 --with-libaribcaption --with-libmodplug --with-libopenmpt --with-librist --with-librsvg --with-libsoxr --with-libssh --with-tesseract --with-libvidstab --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rav1e --with-svt-av1 --with-rtmpdump --with-rubberband --with-two-lame --with-webp --with-xvid --with-zeromq --with-zimg --with-srt --with-libvmaf --with-libxml2 --with-libzvbi --with-aribb24 --with-libbluray --with-libbs2b --with-libcaca --with-libgsm [email protected] --with-speex
Why did you set [email protected]
?
from homebrew-ffmpeg.
The exact command you were trying to run:
brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-chromaprint --with-decklink --with-fdk-aac --with-libflite --with-game-music-emu --with-harfbuzz --with-jack --with-jpeg-xl --with-libaribb24 --with-libaribcaption --with-libmodplug --with-libopenmpt --with-librist --with-librsvg --with-libsoxr --with-libssh --with-tesseract --with-libvidstab --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rav1e --with-svt-av1 --with-rtmpdump --with-rubberband --with-two-lame --with-webp --with-xvid --with-zeromq --with-zimg --with-srt --with-libvmaf --with-libxml2 --with-libzvbi --with-aribb24 --with-libbluray --with-libbs2b --with-libcaca --with-libgsm [email protected] --with-speexWhy did you set
[email protected]
?
Hey @retokromer , thanks for your reply. Actually, I successfully installed it by deleting --with-libflite after I posted this issue. And why did I set [email protected]? I'm not sure. I used brew options homebrew-ffmpeg/ffmpeg/ffmpeg --compact to get it. I believe I might have installed another tool that depends on [email protected], so I have multiple versions of OpenSSL in my system.
Thanks again.
from homebrew-ffmpeg.
Hello @iiiyu : you need to install Flite before running the FFmpeg formula, as indicated in the ReadMe, then it should work fine.
from homebrew-ffmpeg.
Hello @iiiyu : you need to install Flite before running the FFmpeg formula, as indicated in the ReadMe, then it should work fine.
I've been researching for three hours and I can't find a way to install it.
from homebrew-ffmpeg.
If I remember carefully, it’s MacPorts.
from homebrew-ffmpeg.
I've found a guide here: https://stackoverflow.com/a/61189269/435093 — maybe this works?
from homebrew-ffmpeg.
I've found a guide here: https://stackoverflow.com/a/61189269/435093 — maybe this works?
Hey @slhck In fact, I have already compiled and installed it. But it doesn't seem to be working.
If I remember carefully, it’s MacPorts.
So, it looks like I have to install MacPorts. To be honest, I don't want to install both Homebrew and MacPorts on my computer at the same time.
from homebrew-ffmpeg.
I have already compiled and installed it
It would be good if you could already provide more background on what you've tried and where you got stuck, to avoid us having to research things that you already know.
Regarding the specific problem, it looks like you already have the library compiled and installed but ffmpeg is not finding it. Per the error message, can you access ffbuild/config.log
and show its contents?
So, it looks like I have to install MacPorts. To be honest, I don't want to install both Homebrew and MacPorts on my computer at the same time.
That makes sense. (I mean, not installing both.)
from homebrew-ffmpeg.
So, it looks like I have to install MacPorts. To be honest, I don't want to install both Homebrew and MacPorts on my computer at the same time.
As long as I know, there is no Homebrew formula for Flite.
from homebrew-ffmpeg.
I have already compiled and installed it
It would be good if you could already provide more background on what you've tried and where you got stuck, to avoid us having to research things that you already know.
Regarding the specific problem, it looks like you already have the library compiled and installed but ffmpeg is not finding it. Per the error message, can you access
ffbuild/config.log
and show its contents?So, it looks like I have to install MacPorts. To be honest, I don't want to install both Homebrew and MacPorts on my computer at the same time.
That makes sense. (I mean, not installing both.)
Sure, I am glad to provide this log. Where can I find it? ffbuild/config.log
from homebrew-ffmpeg.
I am travelling at the moment. Next weekend I can check what I did, when I added the option. I used it last year with the students (more for fun rather than seriously).
from homebrew-ffmpeg.
I am travelling at the moment. Next weekend I can check what I did, when I added the option. I used it last year with the students (more for fun rather than seriously).
Please enjoy your travelling, I am really thankful for your reply. Actually, I just need fdk-aac at the moment. So, even if my ffmpeg is without libflite, I am good now.
from homebrew-ffmpeg.
I am afraid I don't know where it is stored exactly; I would expect it to be in the same directory as the last lines from the log: /Users/ewan/Library/Logs/Homebrew/ffmpeg
from homebrew-ffmpeg.
I am afraid I don't know where it is stored exactly; I would expect it to be in the same directory as the last lines from the log:
/Users/ewan/Library/Logs/Homebrew/ffmpeg
I am not good with Clang. Could it be because /usr/local/lib
isn’t included in the Clang path when ffmpeg is compiled?
from homebrew-ffmpeg.
So your Homebrew installation lives in /opt/homebrew
(which is where it would typically be under Apple Silicon), and your flite
installation is in /usr/local/lib
which would be Homebrew's previous location (under x64). Indeed clang
can't find the libraries and therefore fails.
Assuming the headers are in /usr/local/include, you should add -I/usr/local/include
explicitly to the clang
command. Homebrew does not do that on its own, see: https://github.com/orgs/Homebrew/discussions/868
Can you try with:
export CPPFLAGS=-I/usr/local/include"
brew install homebrew-ffmpeg/ffmpeg/ffmpeg --with-chromaprint --with-decklink --with-fdk-aac --with-libflite --with-game-music-emu --with-harfbuzz --with-jack --with-jpeg-xl --with-libaribb24 --with-libaribcaption --with-libmodplug --with-libopenmpt --with-librist --with-librsvg --with-libsoxr --with-libssh --with-tesseract --with-libvidstab --with-opencore-amr --with-openh264 --with-openjpeg --with-openssl --with-rav1e --with-svt-av1 --with-rtmpdump --with-rubberband --with-two-lame --with-webp --with-xvid --with-zeromq --with-zimg --with-srt --with-libvmaf --with-libxml2 --with-libzvbi --with-aribb24 --with-libbluray --with-libbs2b --with-libcaca --with-libgsm [email protected] --with-speex
from homebrew-ffmpeg.
Glad you got it solved. It's certainly not the cleanest solution, and I thought passing the CPPFLAGS would work, but having a symlink in place is surely also works. It's just that if you ever decide to update flite you would need to modify/update the symlinks.
from homebrew-ffmpeg.
Is it possible to update here
homebrew-ffmpeg/Formula/ffmpeg.rb
Lines 207 to 208 in 51676b0
like
--extra-ldflags=-L/first/path -L/second/path -L/opt/homebrew/include
maybe. I am not sure.
from homebrew-ffmpeg.
No, because we would not want to hardcode other paths into a Formula. What if you wanted to install flite somewhere else? That's where the environment variables would come into play, by passing in the extra include paths to the compiler. I am not sure why they are not working though.
from homebrew-ffmpeg.
No, because we would not want to hardcode other paths into a Formula. What if you wanted to install flite somewhere else? That's where the environment variables would come into play, by passing in the extra include paths to the compiler. I am not sure why they are not working though.
You are right, forget about my dirty solution.
from homebrew-ffmpeg.
If I remember carefully, it’s MacPorts.
You have tested this? If so I'd love to know how you run both package managers concurrently on a system without conflict, and how you pursuaded HB to use MP packages (or any non-HB packages) as dependencies because HB is definitely not designed to work that way out of the box.
from homebrew-ffmpeg.
You have tested this?
Indeed, my students did it last year. The path issue has already been discussed earlier in this thread. This was just meant as a quick and dirty solution. Yet if this year they are still interested in experimenting text to speech synthesis, then they should compile Flite manually. Note that writing the corresponding Homebrew formula would non be difficult.
from homebrew-ffmpeg.
I don't think so. Maybe when your students tried, there was a hombrew core formula for flite.
As things are now, the option cannot work as advertised, and certainly not without modification.
the --with-libflite option should be removed from the formula
from homebrew-ffmpeg.
Maybe when your students tried, there was a hombrew core formula for flite.
No, there wasn’t.
the --with-libflite option should be removed from the formula
Why? It was included as option to FFmpeg twelve years ago. I added it here after my last year’s course and I am not going to remove it. You are completely free not to use it.
from homebrew-ffmpeg.
Because HB does not support non-HB dependencies, thus this is a broken formula.
And because issues like this one exist, and you will get more, since this repository is being suggested all over the internet as solution to the complaints about HB removing options. ffmpeg is a very popular tool. The issue was discussed but not really resolved.
Removing it is simply the right thing to do.
from homebrew-ffmpeg.
There is a solution that involves creating a symlink.
I will check if it's possible to link against non-Homebrew libraries that are installed locally. The flag I suggested does not seem to be the right one.
So the option works, but requires some manual changes. In any case the user has to compile the dependency manually. I am against removing the option.
from homebrew-ffmpeg.
Removing it is simply the right thing to do.
No, not at all: it’s part of the official FFmpeg, and we wish to include the option in our Homebrew formula as well. As said, our formula works in different ways, one of them was described in detail above.
Why do you not write a Homebrew formula for Flite? Here in this repository that is out of scope.
from homebrew-ffmpeg.
I will check if it's possible to link against non-Homebrew libraries
It's not supported, but sure, check. The rest of us understand that you cannot maintain a functioning, up-to-date, dependency hierarchy when you start mixing in unmanaged packages.
There is a solution that involves creating a symlink.
monkeying with homebrew and breaking the mechanics is a hack. Not a solution
from homebrew-ffmpeg.
Why do you not write a Homebrew formula for Flite?
I am not a maintainer for flite or homebrew core
from homebrew-ffmpeg.
You're free to not use this option if it doesn't work for you.
Indeed, I already said it above.
from homebrew-ffmpeg.
Related Issues (20)
- Brewing custom ffmpeg but failure at metal execution HOT 13
- add libzbvi to the default options in Homebrew formula from your repo HOT 9
- Please enable the ffplay building option, as the official brew formula does HOT 4
- Possible formula fixes/changes HOT 2
- Can't upgrade to 5.1 HOT 10
- Unknown decoder 'libx265' HOT 1
- FFmpeg 6.0 HOT 4
- Additional codecs don't seem to be included with installation HOT 1
- "unpaper" won't run without ffmpeg 5.x HOT 9
- Can you support installing older version of ffmpeg (e.g. ffmpeg@4) with the option --with-fdk-aac ? HOT 1
- Add `libplacebo` as a supported (optional) library HOT 11
- Install with a different name HOT 7
- Apple Silicon support in homebrew HOT 4
- Patch failure for libavcodec when re-installing ffmpeg HEAD HOT 7
- libavdevice build error (Mac M1 Silicon) HOT 24
- libvidstab error, failed on the 2nd pass, "Cannot parse localmotion" HOT 3
- Test optional installations in CI pipeline
- Error installing with`VkVideoDecodeAV1SessionParametersCreateInfoMESA` HOT 10
- tap comparison HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from homebrew-ffmpeg.