Re: [Fink-devel] ffmpeg: AC3 library bug and patch (0.4.8-4 in 10.3/unstable)

2003-12-28 Thread Mark Mentovai
TheSin wrote:
okay now updated...
The fix is incomplete: dlopen requires a fully-qualified pathname or it 
will attempt to open the library relative to cwd.  It does not 
automatically use any search path.  I trust most users aren't executing 
ffmpeg from %p/lib.

Hence, my patch specified:

--
  ### Still more fixes for dylib
  perl -pi -e 's,liba52.so.0,%p/lib/liba52.0.dylib,g' 
libavcodec/a52dec.c
  perl -pi -e 's,libfaad.so.0,%p/lib/libfaad.0.dylib,g' 
libavcodec/faad.c
--
instead of merely:

--
  ### Fix dlopen filenames
  perl -pi -e 's,liba52.so.0,liba52.0.dylib,g' libavcodec/a52dec.c
  perl -pi -e 's,libfaad.so.0,libfaad.0.dylib,g' libavcodec/faad.c
--
ffmpeg 0.4.8-10 still generates the following errors (unless executed 
from %p/lib):

--
A52 library liba52.0.dylib could not be opened!
dlcompat: file liba52.0.dylib not found
--
Mark



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278alloc_id=3371op=click
___
Fink-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/fink-devel


[Fink-devel] ffmpeg: AC3 library bug and patch (0.4.8-4 in 10.3/unstable)

2003-12-26 Thread Mark Mentovai
Dear finx (or list manager that will promptly ask me to subscribe),

ffmpeg in 10.3/unstable will not decode AC3 audio.  ffmpeg's libavcodec 
needs to dlopen liba52, but the path passed to dlopen is hardcoded with 
the .so extension, which does not match the .dylib extension that the 
library is installed with.

The same problem is present in the dlopen of libfaad elsewhere in 
libavcodec.

Adding the following to PatchScript in ffmpeg.info takes care of both 
of these problems.  They should logically be added near the other 
.so-to-.dylib patches.

--
  ### Still more fixes for dylib
  perl -pi -e 's,liba52.so.0,%p/lib/liba52.0.dylib,g' 
libavcodec/a52dec.c
  perl -pi -e 's,libfaad.so.0,%p/lib/libfaad.0.dylib,g' 
libavcodec/faad.c
--

Patch for ffmpeg.info follows.  For two lines, I don't know why, but 
some people really just prefer patch files.

--
Index: 10.3/unstable/main/finkinfo/graphics/ffmpeg.info
diff -ur 10.3/unstable/main/finkinfo/graphics/ffmpeg.info.dist 
10.3/unstable/main/finkinfo/graphics/ffmpeg.info
--- 10.3/unstable/main/finkinfo/graphics/ffmpeg.info.distThu Nov 13 
12:32:46 2003
+++ 10.3/unstable/main/finkinfo/graphics/ffmpeg.info Mon Dec 22 
23:55:05 2003
@@ -27,6 +27,9 @@
   perl -pi -e 
's,SLIB=,SLIB_INSTALL=\$(SLIBPREF)avformat.0\$(SLIBSUF)\nSLIB=,g' 
libavformat/Makefile
   perl -pi -e 's,\$\(CC\) \$\(SHFLAGS\) -o \$\@ \$\(OBJS\) 
\$\(EXTRALIBS\) \$\(AMREXTRALIBS\),\$\(CC\) \$\(SHFLAGS\) -o \$\@ 
\$\(OBJS\) \$\(EXTRALIBS\) \$\(AMREXTRALIBS\)\n\tln -sf \$\(SLIB\) 
\$\(SLIBPREF\)avcodec.0\$\(SLIBSUF\)\n\tln -sf \$(SLIB\) 
\$\(SLIBPREF\)avcodec\$\(SLIBSUF\),g' libavcodec/Makefile
   perl -pi -e 's,\$\(CC\) \$\(SHFLAGS\) -o (.*),\$\(CC\) \$\(SHFLAGS\) 
-o $1\n\tln -sf \$\(SLIB\) \$\(SLIBPREF\)avformat.0\$\(SLIBSUF\)\n\tln 
-sf \$(SLIB\) \$\(SLIBPREF\)avformat\$\(SLIBSUF\),g' 
libavformat/Makefile
+  ### Still more fixes for dylib
+  perl -pi -e 's,liba52.so.0,%p/lib/liba52.0.dylib,g' 
libavcodec/a52dec.c
+  perl -pi -e 's,libfaad.so.0,%p/lib/libfaad.0.dylib,g' 
libavcodec/faad.c
   ### libsvformat shared lib linking
   perl -pi -e 's,PPOBJS=,PPOBJS=\nLIBS+=-L../libavcodec 
-lavcodec\nEXTRALIBS+=-lmp3lame -lvorbis -lvorbisenc -logg,g' 
libavformat/Makefile
   perl -pi -e 's,\$\(EXTRALIBS\),\$\(LIBS\) \$\(EXTRALIBS\),g' 
libavformat/Makefile
--

This bug is accounted for and patched in ffmpeg 0.4.6-11 in 
10.2-gcc3/unstable, apparently the patch never made the leap to the new 
tree.

Mark



---
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278alloc_id=3371op=click
___
Fink-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/fink-devel