Closed tcwalther closed 2 years ago
How is that added? Could you open a pull request please?
I'm quite new to conda feedstocks. I'll happily submit a PR once I understand how it all works. In the meantime, it would be great if you could provide me some assistance.
I pulled the docker image condaforge/linux-anvil
, tried to ./configure
sox in there and looked at the output. I couldn't get it better than this:
OPTIONAL FILE FORMATS
amrnb......................no
amrwb......................no
flac.......................no
gsm........................yes (in-tree)
lpc10......................yes (in-tree)
mp2/mp3....................no
id3tag....................no
lame......................no
mad.......................no
twolame...................no
oggvorbis..................no
opus.......................no
sndfile....................no
wavpack....................no
First, I tried running ./configure
in a conda environnent, but when I did that, configure would just fail, saying that C compiler cannot create executables
. When running ./configure
outside an environment, I get the above output. I then tried installing lame via anaconda (HCC/lame
) - it's not available via yum - but that didn't help. I then tried installing libogg
via yum, but that didn't get picked up either.
I'd be happy for tips on how to proceed from here. In the meantime, I'll just use the sox that comes with my system's package manager.
Can you compile sox with mp3 support on your machine without conda and docker? What are the instructions?
On my Mac, I simply run ./configure
, followed by make
. I already have all the prerequisites installed, it seems. Here's the configure output: http://hastebin.com/ivafiqicej.txt
I tested the resulting sox binary, and it indeed loads mp3 and ogg files.
Looking through the configure log, the following lines seem to be important for MP3:
checking for mad.h... yes
checking for id3tag.h... yes
checking lame/lame.h usability... yes
And for ogg:
checking for vorbis/codec.h... yes
And since we're at it, FLAC:
checking for FLAC/all.h... yes
I found the following tutorial on installing sox with mp3 support on CentOS: http://arstech.net/installing-sox-with-mp3-support-on-centos/
However, they recommend installing the libraries libmad
, libid3tag
, lame
, libvorbis
and flac
(and their -devel
counterparts) via yum, which is of course not cross-platform compatible. I'm not sure how this is usually handled conda-forge.
Sorry somehow I forgot this thread.
@tcwalther you need to make those libraries (libmad, libid3tag, lame, libvorbis, and flac) available in conda-forge first and then add them as dependencies here.
libvorbis is on conda-forge but sox doesn't seem to find it.
conda install -c conda-forge -y sox libvorbis
soxi test.ogg
soxi FAIL formats: no handler for detected file type `vorbis'
Hi,
I am trying to apply GAIN for audio file extension [ WAVE ]. But SOX library is returning failure saying "no handler for given file type 'wav' "...
How do I add wave file format handler and recompile the SOX open source code.
Please let know...Thanks in Advance.
Any chance of adding Flac support?
Unless you put the effort or somebody else, I don't see it happening. Once dependencies of Sox are separate conda packages, you can open a pull request here to add support for them in sox.
mp3 support was added in https://github.com/conda-forge/sox-feedstock/pull/18 please open separate issues for other codecs.
It would be fantastic if you could add mp3 and ogg support to sox. Currently, it supports: