X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=configure;h=4bb20301e76aeec9ff811baa5dbb64a2cd09fd3f;hb=8517e9c476e8cf92d9ed25b6486bb43d3dc2c49d;hp=29fb432fb9d633239ad9f7799d2320ee95f252ec;hpb=363bd1c62c1bcbac2dcb56f3dc47824f075888d2;p=ffmpeg diff --git a/configure b/configure index 29fb432fb9d..4bb20301e76 100755 --- a/configure +++ b/configure @@ -59,8 +59,21 @@ cat <&1 | grep -q Open64; then speed_cflags='-O2' size_cflags='-Os' filter_cflags='filter_out -Wdisabled-optimization|-Wtype-limits|-fno-signed-zeros' +elif $cc -V 2>&1 | grep -q Portland; then + cc_type=pgi + cc_version='AV_STRINGIFY(__PGIC__.__PGIC_MINOR__.__PGIC_PATCHLEVEL__)' + cc_ident="PGI $($cc -V 2>&1 | awk '/^pgcc/ { print $2; exit }')" + opt_common='-alias=ansi -Mlre -Mpre' + speed_cflags="-O3 -Mautoinline -Munroll=c:4 $opt_common" + size_cflags="-O2 -Munroll=c:1 $opt_common" + noopt_cflags="-O1" + filter_cflags=pgi_flags + pgi_flags(){ + for flag; do + case $flag in + -fomit-frame-pointer) echo -Mnoframe ;; + -g) echo -gopt ;; + *) echo $flag ;; + esac + done + } fi test -n "$cc_type" && enable $cc_type || @@ -2250,9 +2227,12 @@ elif enabled ppc; then 74*|ppc74*|powerpc74*) cpuflags="-mcpu=7400 -mpowerpc-gfxopt" ;; - g5|970|ppc970|powerpc970|power4*) + g5|970|ppc970|powerpc970) cpuflags="-mcpu=970 -mpowerpc-gfxopt -mpowerpc64" ;; + power[3-7]*) + cpuflags="-mcpu=$cpu -mpowerpc-gfxopt -mpowerpc64" + ;; cell) cpuflags="-mcpu=cell" enable ldbrx @@ -2418,7 +2398,7 @@ case $target_os in SHFLAGS='-shared -Wl,-h,$$(@F)' enabled x86 && SHFLAGS="-mimpure-text $SHFLAGS" network_extralibs="-lsocket -lnsl" - add_cppflags -D__EXTENSIONS__ + add_cppflags -D__EXTENSIONS__ -D_XOPEN_SOURCE=600 # When using suncc to build, the Solaris linker will mark # an executable with each instruction set encountered by # the Solaris assembler. As our libraries contain their own @@ -2433,7 +2413,6 @@ case $target_os in oss_outdev_extralibs="-lossaudio" ;; openbsd) - enable malloc_aligned # On OpenBSD 4.5. the compiler does not use PIC unless # explicitly using -fPIC. Libav builds fine without PIC, # however the generated executable will not do anything @@ -2446,17 +2425,14 @@ case $target_os in oss_outdev_extralibs="-lossaudio" ;; dragonfly) - enable malloc_aligned disable symver ;; freebsd) - enable malloc_aligned ;; bsd/os) add_extralibs -lpoll -lgnugetopt ;; darwin) - enable malloc_aligned gas="gas-preprocessor.pl $cc" enabled ppc && add_asflags -force_cpusubtype_ALL SHFLAGS='-dynamiclib -Wl,-single_module -Wl,-install_name,$(SHLIBDIR)/$(SLIBNAME_WITH_MAJOR),-current_version,$(LIBVERSION),-compatibility_version,$(LIBMAJOR)' @@ -2479,7 +2455,6 @@ case $target_os in fi LIBTARGET=i386 if enabled x86_64; then - enable malloc_aligned LIBTARGET="i386:x86-64" elif enabled arm; then LIBTARGET=arm-wince @@ -2583,7 +2558,11 @@ case $target_os in ;; esac -echo "config:$arch:$subarch:$cpu:$target_os:$cc_ident:$LIBAV_CONFIGURATION" >config.fate +esc(){ + echo "$*" | sed 's/%/%25/g;s/:/%3a/g' +} + +echo "config:$arch:$subarch:$cpu:$target_os:$(esc $cc_ident):$(esc $LIBAV_CONFIGURATION)" >config.fate check_cpp_condition stdlib.h "defined(__PIC__) || defined(__pic__) || defined(PIC)" && enable pic @@ -2815,6 +2794,7 @@ if enabled network; then check_type netinet/in.h "struct sockaddr_in6" check_type "sys/types.h sys/socket.h" "struct sockaddr_storage" check_struct "sys/types.h sys/socket.h" "struct sockaddr" sa_len + check_header netinet/sctp.h # Prefer arpa/inet.h over winsock2 if check_header arpa/inet.h ; then check_func closesocket @@ -2858,7 +2838,6 @@ check_func sched_getaffinity check_func sysconf check_func sysctl check_func_headers io.h setmode -check_func_headers lzo/lzo1x.h lzo1x_999_compress check_lib2 "windows.h psapi.h" GetProcessMemoryInfo -lpsapi check_func_headers windows.h GetProcessAffinityMask check_func_headers windows.h GetProcessTimes @@ -2931,14 +2910,10 @@ check_mathfunc truncf enabled avisynth && require2 vfw32 "windows.h vfw.h" AVIFileInit -lavifil32 enabled frei0r && { check_header frei0r.h || die "ERROR: frei0r.h header not found"; } enabled gnutls && require_pkg_config gnutls gnutls/gnutls.h gnutls_global_init -enabled libdirac && require_pkg_config dirac \ - "libdirac_decoder/dirac_parser.h" \ - "dirac_decoder_init" enabled libfaac && require2 libfaac "stdint.h faac.h" faacEncGetVersion -lfaac enabled libfreetype && require_pkg_config freetype2 "ft2build.h freetype/freetype.h" FT_Init_FreeType enabled libgsm && require libgsm gsm/gsm.h gsm_create -lgsm enabled libmp3lame && require "libmp3lame >= 3.98.3" lame/lame.h lame_set_VBR_quality -lmp3lame -enabled libnut && require libnut libnut.h nut_demuxer_init -lnut enabled libopencore_amrnb && require libopencore_amrnb opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb enabled libopencore_amrwb && require libopencore_amrwb opencore-amrwb/dec_if.h D_IF_init -lopencore-amrwb enabled libopencv && require_pkg_config opencv opencv/cv.h cvCreateImageHeader @@ -2975,7 +2950,7 @@ if enabled libdc1394; then die "ERROR: No version of libdc1394 found " fi -if check_pkg_config sdl SDL_version.h SDL_Linked_Version; then +if check_pkg_config sdl SDL_events.h SDL_PollEvent; then check_cpp_condition SDL.h "(SDL_MAJOR_VERSION<<16 | SDL_MINOR_VERSION<<8 | SDL_PATCHLEVEL) >= 0x010201" $sdl_cflags && enable sdl && check_struct SDL.h SDL_VideoInfo current_w $sdl_cflags && enable sdl_video_size @@ -3009,20 +2984,18 @@ check_header soundcard.h enabled_any alsa_indev alsa_outdev && check_lib2 alsa/asoundlib.h snd_pcm_htimestamp -lasound -enabled jack_indev && check_lib2 jack/jack.h jack_client_open -ljack +enabled jack_indev && check_lib2 jack/jack.h jack_client_open -ljack && + check_func jack_port_get_latency_range -ljack enabled_any sndio_indev sndio_outdev && check_lib2 sndio.h sio_open -lsndio enabled libcdio && check_lib2 "cdio/cdda.h cdio/paranoia.h" cdio_cddap_open "-lcdio_paranoia -lcdio_cdda -lcdio" -enabled x11grab && -check_header X11/Xlib.h && -check_header X11/extensions/XShm.h && -check_header X11/extensions/Xfixes.h && -check_func XOpenDisplay -lX11 && -check_func XShmCreateImage -lX11 -lXext && -check_func XFixesGetCursorImage -lX11 -lXext -lXfixes +enabled x11grab && +require X11 X11/Xlib.h XOpenDisplay -lX11 && +require Xext X11/extensions/XShm.h XShmCreateImage -lXext && +require Xfixes X11/extensions/Xfixes.h XFixesGetCursorImage -lXfixes # check for VDA header if ! disabled vda && check_header VideoDecodeAcceleration/VDADecoder.h; then @@ -3058,7 +3031,7 @@ enabled extra_warnings && check_cflags -Winline # add some linker flags check_ldflags -Wl,--warn-common -check_ldflags -Wl,-rpath-link=libswscale:libavfilter:libavdevice:libavformat:libavcodec:libavutil +check_ldflags -Wl,-rpath-link=libswscale:libavfilter:libavdevice:libavformat:libavcodec:libavutil:libavresample test_ldflags -Wl,-Bsymbolic && append SHFLAGS -Wl,-Bsymbolic enabled xmm_clobber_test && \ @@ -3103,10 +3076,11 @@ if enabled icc; then # -wd: Disable following warnings # 144, 167, 556: -Wno-pointer-sign # 1292: attribute "foo" ignored + # 1419: external declaration in primary source file # 10006: ignoring unknown option -fno-signed-zeros # 10148: ignoring unknown option -Wno-parentheses # 10156: ignoring option '-W'; no argument required - check_cflags -wd144,167,556,1292,10006,10148,10156 + check_cflags -wd144,167,556,1292,1419,10006,10148,10156 # 11030: Warning unknown option --as-needed # 10156: ignoring option '-export'; no argument required check_ldflags -wd10156,11030 @@ -3161,7 +3135,7 @@ check_deps $CONFIG_LIST \ enabled asm || { arch=c; disable $ARCH_LIST $ARCH_EXT_LIST; } -! enabled_any memalign posix_memalign malloc_aligned && +! enabled_any memalign posix_memalign && enabled_any $need_memalign && enable memalign_hack echo "install prefix $prefix" @@ -3226,11 +3200,9 @@ echo "frei0r enabled ${frei0r-no}" echo "gnutls enabled ${gnutls-no}" echo "libcdio support ${libcdio-no}" echo "libdc1394 support ${libdc1394-no}" -echo "libdirac enabled ${libdirac-no}" echo "libfaac enabled ${libfaac-no}" echo "libgsm enabled ${libgsm-no}" echo "libmp3lame enabled ${libmp3lame-no}" -echo "libnut enabled ${libnut-no}" echo "libopencore-amrnb support ${libopencore_amrnb-no}" echo "libopencore-amrwb support ${libopencore_amrwb-no}" echo "libopencv support ${libopencv-no}" @@ -3346,7 +3318,7 @@ SLIB_INSTALL_NAME=${SLIB_INSTALL_NAME} SLIB_INSTALL_LINKS=${SLIB_INSTALL_LINKS} SLIB_INSTALL_EXTRA_LIB=${SLIB_INSTALL_EXTRA_LIB} SLIB_INSTALL_EXTRA_SHLIB=${SLIB_INSTALL_EXTRA_SHLIB} -SAMPLES:=${samples:-\$(FATE_SAMPLES)} +SAMPLES:=${samples:-\$(LIBAV_SAMPLES)} EOF get_version(){ @@ -3363,6 +3335,7 @@ get_version LIBAVCODEC libavcodec/version.h get_version LIBAVDEVICE libavdevice/avdevice.h get_version LIBAVFILTER libavfilter/version.h get_version LIBAVFORMAT libavformat/version.h +get_version LIBAVRESAMPLE libavresample/version.h get_version LIBAVUTIL libavutil/avutil.h get_version LIBSWSCALE libswscale/swscale.h @@ -3405,8 +3378,6 @@ print_config CONFIG_ "$config_files" $CONFIG_LIST \ $ALL_COMPONENTS \ cat >>config.mak <