[Ffmpeg-devel] [PATCH] cs-test Darwin host issues

Marc Hoffman mmh
Thu Mar 29 14:19:19 CEST 2007


1. Darwin doesn't have a malloc.h header file so I have wrapped that with __APPLE__
   actually it shouldn't even be used, considering malloc is defined as please_use_av_malloc.
2. malloc is defined as av_malloc not malloc.

yoda:~/ffmpeg/host/libswscale mmh$ make cs_test
gcc  -DHAVE_AV_CONFIG_H -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_ISOC9X_SOURCE -I"/Users/mmh/ffmpeg
/Users/mmh/ffmpeg/ffmpeg-svn" -I"/Users/mmh/ffmpeg/ffmpeg-svn"/libavutil -no-cpp-precomp -pipe -force_cp
LL -Wno-sign-compare -fomit-frame-pointer -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-
on -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -O3 -mdynamic-no-pic  -c -o cs_test.o /Users/mmh/
peg-svn/libswscale/cs_test.c
/Users/mmh/ffmpeg/ffmpeg-svn/libswscale/cs_test.c: In function 'main':
/Users/mmh/ffmpeg/ffmpeg-svn/libswscale/cs_test.c:71: warning: implicit declaration of function 'please_
loc'
gcc -Wl,-dynamic,-search_paths_first  -rdynamic -o cs_test cs_test.o libswscale.a -L"/Users/mmh/ffmpeg/h
util -lavutil -lz -la52 -lmp3lame -lm -lx264 -lfaac -lfaad   
i686-apple-darwin8-gcc-4.0.1: unrecognized option '-rdynamic'
/usr/bin/ld: Undefined symbols:
_please_use_av_malloc
collect2: ld returned 1 exit status
make: *** [cs_test] Error 1

after patch is applied

yoda:~/ffmpeg/host/libswscale mmh$ ./cs_test 
memory corruption test ...
CPU capabilities forced to 0
....................................................................................................28 converters passed, 0 converters randomly overwrote memory

-------------- next part --------------
A non-text attachment was scrubbed...
Name: cs-test-darwin.patch
Type: application/octet-stream
Size: 560 bytes
Desc: patch darwin cs-test for malloc issue
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070329/2e7eca6b/attachment.obj>



More information about the ffmpeg-devel mailing list