[Flac-dev] Proposed change to code that handles output_prefix
xflac at yahoo.com
Tue Aug 20 10:02:05 PDT 2002
--- Justin Akehurst <akehurst at poindextrose.org> wrote:
> On line 734 in src/flac/main.c, ver 1.77, change:
> strcat(outfilename, infilename);
> strcat(outfilename, flac__file_get_basename(infilename));
> I did this change because I was calling flac with an input filename
> with a
> path on the front of it, and I wanted the output file to go to a
> location, such as this:
> flac --best --output-prefix /usr/share/flac
> before the change, it was just concatenating the input filename to
> output prefix.
The reason it is like that is so that you can preserve the
hierarchy of the input directory. e.g.
flac --output-prefix=/a/b/ x/1.wav y/2.wav
will give you /a/b/x/1.flac and /a/b/y/2.flac (also note
the trailing slash on the output prefix). To do what you're
describing you can do:
(cd /home/akehurst/tmp && flac --output-prefix=/usr/share/flac/
But if I used the basename, the power of --output-prefix
drops and I can no longer do the former.
Do You Yahoo!?
HotJobs - Search Thousands of New Jobs
More information about the Flac-dev