[Ffmpeg-devel] ffmpeg failed to compile

carboncopy carboncopy.public
Tue Feb 14 06:18:14 CET 2006


On 2/14/06, carboncopy <carboncopy.public at gmail.com> wrote:
> On 2/14/06, carboncopy <carboncopy.public at gmail.com> wrote:
> > > This is really weird.  I don't know what I was thinking when I
> > > suggested that change.  The next line is running ranlib explicitly.
> > > But then how can it make any difference running it again manually?
> > >
> > > What OS was this on?
> > >
> > Mac Os X 10.4.4
> >
>
>
> Oh, I have to let you know, I need to sudo ranlib /opt/local/lib/[foo.a]
>

I added sudo to $(RANLIB) :
<snip>
$(LIB): $(STATIC_OBJS)
	rm -f $@
	$(AR) rcs $@ $^ $(EXTRAOBJS)
	sudo $(RANLIB) $@

$(SLIBNAME): $(SHARED_OBJS)
	$(CC) $(SHFLAGS) $(LDFLAGS) -o $@ $^ $(EXTRALIBS) $(EXTRAOBJS)
<snip>

It did asked me for password while compiling. But further down
compilation, this is what I get :


sudo ranlib libavformat.a
cc -O3 -Wall -Wno-switch -O3 -mcpu=970 -mtune=970 -fast
-I/opt/local/include -DHAVE_LRINTF -ftree-vectorize -maltivec
-mabi=altivec -mpim-altivec -floop-optimize2 -mpowerpc-gfxopt
-mpowerpc64 -no-cpp-precomp -pipe -fomit-frame-pointer
-force_cpusubtype_ALL -Wno-sign-compare -mcpu=970 -mtune=970
-mpowerpc-gfxopt -mpowerpc64 -faltivec -mdynamic-no-pic -I.
-I/Users/carboncopy/coding/ffmpeg
-I/Users/carboncopy/coding/ffmpeg/libavutil
-I/Users/carboncopy/coding/ffmpeg/libavcodec
-I/Users/carboncopy/coding/ffmpeg/libavformat -D_FILE_OFFSET_BITS=64
-D_LARGEFILE_SOURCE -D_GNU_SOURCE -c -o ffmpeg.o
/Users/carboncopy/coding/ffmpeg/ffmpeg.c
cc -O3 -Wall -Wno-switch -O3 -mcpu=970 -mtune=970 -fast
-I/opt/local/include -DHAVE_LRINTF -ftree-vectorize -maltivec
-mabi=altivec -mpim-altivec -floop-optimize2 -mpowerpc-gfxopt
-mpowerpc64 -no-cpp-precomp -pipe -fomit-frame-pointer
-force_cpusubtype_ALL -Wno-sign-compare -mcpu=970 -mtune=970
-mpowerpc-gfxopt -mpowerpc64 -faltivec -mdynamic-no-pic -I.
-I/Users/carboncopy/coding/ffmpeg
-I/Users/carboncopy/coding/ffmpeg/libavutil
-I/Users/carboncopy/coding/ffmpeg/libavcodec
-I/Users/carboncopy/coding/ffmpeg/libavformat -D_FILE_OFFSET_BITS=64
-D_LARGEFILE_SOURCE -D_GNU_SOURCE -c -o cmdutils.o
/Users/carboncopy/coding/ffmpeg/cmdutils.c
cc -Wl,-dynamic,-search_paths_first -L/opt/local/lib -g -o ffmpeg_g
ffmpeg.o cmdutils.o -L./libavformat -lavformat -L./libavcodec
-lavcodec -L./libavutil -lavutil -lx264 -lxvidcore -lmp3lame -logg
-lvorbis -lvorbisenc -ltheora -lfaad -lfaac -lz -llzo  -lpthread
/usr/bin/ld: table of contents for archive:
/opt/local/lib/libavformat.a is out of date; rerun ranlib(1) (can't
load from it)
/usr/bin/ld: table of contents for archive:
/opt/local/lib/libavcodec.a is out of date; rerun ranlib(1) (can't
load from it)
/usr/bin/ld: table of contents for archive: /opt/local/lib/libavutil.a
is out of date; rerun ranlib(1) (can't load from it)
collect2: ld returned 1 exit status
make: *** [ffmpeg_g] Error 1


The funny thing is, I am not getting this problem on my iBook G4
compilation. I guess I should nuke /opt/local/lib/libavformat.a,
libavcodec.a and libavutil.a for a try,

The iBook have not gone through the troubled compilation and installation cycle.





More information about the ffmpeg-devel mailing list