~siretart/libav/merge.raring.libav-0.8.6

« back to all changes in this revision

Viewing changes to configure

  • Committer: Package Import Robot
  • Author(s): Reinhard Tartler
  • Date: 2012-01-12 22:30:00 UTC
  • mfrom: (1.4.1)
  • mto: (1.3.11 sid) (26.1.1 quantal-security)
  • mto: This revision was merged to the branch mainline in revision 15.
  • Revision ID: package-import@ubuntu.com-20120112223000-s1reiy1e28hnix42
Tags: upstream-0.8~beta2
ImportĀ upstreamĀ versionĀ 0.8~beta2

Show diffs side-by-side

added added

removed removed

Lines of Context:
65
65
  --disable-logging        do not log configure debug information
66
66
  --prefix=PREFIX          install in PREFIX [$prefix]
67
67
  --bindir=DIR             install binaries in DIR [PREFIX/bin]
68
 
  --datadir=DIR            install data files in DIR [PREFIX/share/ffmpeg]
 
68
  --datadir=DIR            install data files in DIR [PREFIX/share/avconv]
69
69
  --libdir=DIR             install libs in DIR [PREFIX/lib]
70
70
  --shlibdir=DIR           install shared libs in DIR [PREFIX/lib]
71
71
  --incdir=DIR             install includes in DIR [PREFIX/include]
81
81
                           and binaries will be unredistributable [no]
82
82
  --disable-doc            do not build documentation
83
83
  --disable-ffmpeg         disable ffmpeg build
84
 
  --disable-ffplay         disable ffplay build
85
 
  --disable-ffprobe        disable ffprobe build
86
 
  --disable-ffserver       disable ffserver build
 
84
  --disable-avconv         disable avconv build
 
85
  --disable-avplay         disable avplay build
 
86
  --disable-avprobe        disable avprobe build
 
87
  --disable-avserver       disable avserver build
87
88
  --disable-avdevice       disable libavdevice build
88
89
  --disable-avcodec        disable libavcodec build
89
90
  --disable-avformat       disable libavformat build
90
91
  --disable-swscale        disable libswscale build
91
 
  --disable-postproc       disable libpostproc build
 
92
  --enable-postproc        enable libpostproc build (deprecated) [no]
92
93
  --disable-avfilter       disable video filter support [no]
93
94
  --disable-pthreads       disable pthreads [auto]
94
 
  --enable-w32threads      use Win32 threads [no]
 
95
  --disable-w32threads     disable Win32 threads [auto]
95
96
  --enable-x11grab         enable X11 grabbing [no]
96
97
  --disable-network        disable network support [no]
97
98
  --enable-gray            enable full grayscale support (slower color)
107
108
  --disable-mdct           disable MDCT code
108
109
  --disable-rdft           disable RDFT code
109
110
  --enable-vaapi           enable VAAPI code
 
111
  --enable-vda             enable VDA code
110
112
  --enable-vdpau           enable VDPAU code
111
113
  --disable-dxva2          disable DXVA2 code
112
114
  --enable-runtime-cpudetect detect cpu capabilities at runtime (bigger binary)
113
115
  --enable-hardcoded-tables use hardcoded tables instead of runtime generation
 
116
  --disable-safe-bitstream-reader
 
117
                           disable buffer boundary checking in bitreaders
 
118
                           (faster, but may crash)
114
119
  --enable-memalign-hack   emulate memalign, interferes with memory debuggers
115
120
  --disable-everything     disable all components listed below
116
121
  --disable-encoder=NAME   disable encoder NAME
161
166
  --enable-avisynth        enable reading of AVISynth script files [no]
162
167
  --enable-bzlib           enable bzlib [autodetect]
163
168
  --enable-frei0r          enable frei0r video filtering
 
169
  --enable-gnutls          enable gnutls [no]
164
170
  --enable-libopencore-amrnb enable AMR-NB de/encoding via libopencore-amrnb [no]
165
171
  --enable-libopencore-amrwb enable AMR-WB decoding via libopencore-amrwb [no]
166
172
  --enable-libopencv       enable video filtering via libopencv [no]
 
173
  --enable-libcdio         enable audio CD grabbing with libcdio
167
174
  --enable-libdc1394       enable IIDC-1394 grabbing using libdc1394
168
175
                           and libraw1394 [no]
169
176
  --enable-libdirac        enable Dirac support via libdirac [no]
174
181
  --enable-libnut          enable NUT (de)muxing via libnut,
175
182
                           native (de)muxer exists [no]
176
183
  --enable-libopenjpeg     enable JPEG 2000 decoding via OpenJPEG [no]
 
184
  --enable-libpulse        enable Pulseaudio input via libpulse [no]
177
185
  --enable-librtmp         enable RTMP[E] support via librtmp [no]
178
186
  --enable-libschroedinger enable Dirac support via libschroedinger [no]
179
 
  --enable-libspeex        enable Speex decoding via libspeex [no]
 
187
  --enable-libspeex        enable Speex support via libspeex [no]
180
188
  --enable-libtheora       enable Theora encoding via libtheora [no]
181
189
  --enable-libvo-aacenc    enable AAC encoding via libvo-aacenc [no]
182
190
  --enable-libvo-amrwbenc  enable AMR-WB encoding via libvo-amrwbenc [no]
188
196
  --enable-libxvid         enable Xvid encoding via xvidcore,
189
197
                           native MPEG-4/Xvid encoder exists [no]
190
198
  --enable-mlib            enable Sun medialib [no]
 
199
  --enable-openssl         enable openssl [no]
191
200
  --enable-zlib            enable zlib [autodetect]
192
201
 
193
202
Advanced options (experts only):
237
246
  --malloc-prefix=PFX      prefix malloc and related names with PFX
238
247
  --enable-sram            allow use of on-chip SRAM
239
248
  --disable-symver         disable symbol versioning
 
249
  --optflags               override optimization-related compiler flags
240
250
 
241
251
Developer options (useful when working on Libav itself):
242
252
  --disable-debug          disable debugging symbols
874
884
}
875
885
 
876
886
cp_if_changed(){
877
 
    cmp -s "$1" "$2" &&
878
 
        echo "$2 is unchanged" ||
879
 
        cp -f "$1" "$2"
 
887
    cmp -s "$1" "$2" && echo "$2 is unchanged" && return
 
888
    mkdir -p "$(dirname $2)"
 
889
    cp -f "$1" "$2"
880
890
}
881
891
 
882
892
# CONFIG_LIST contains configurable options, while HAVE_LIST is for
896
906
    protocols
897
907
"
898
908
 
 
909
PROGRAM_LIST="
 
910
    avconv
 
911
    avplay
 
912
    avprobe
 
913
    avserver
 
914
    ffmpeg
 
915
"
 
916
 
899
917
CONFIG_LIST="
900
918
    $COMPONENT_LIST
 
919
    $PROGRAM_LIST
901
920
    aandct
902
921
    ac3dsp
903
922
    avcodec
911
930
    dwt
912
931
    dxva2
913
932
    fastdiv
914
 
    ffmpeg
915
 
    ffplay
916
 
    ffprobe
917
 
    ffserver
918
933
    fft
919
934
    frei0r
 
935
    gnutls
920
936
    golomb
921
937
    gpl
922
938
    gray
 
939
    h264chroma
923
940
    h264dsp
924
941
    h264pred
925
942
    hardcoded_tables
926
943
    huffman
 
944
    libcdio
927
945
    libdc1394
928
946
    libdirac
929
947
    libfaac
935
953
    libopencore_amrwb
936
954
    libopencv
937
955
    libopenjpeg
 
956
    libpulse
938
957
    librtmp
939
958
    libschroedinger
940
959
    libspeex
954
973
    mpegaudiodsp
955
974
    network
956
975
    nonfree
 
976
    openssl
957
977
    pic
958
978
    postproc
959
979
    rdft
960
980
    rtpdec
961
981
    runtime_cpudetect
 
982
    safe_bitstream_reader
962
983
    shared
963
984
    sinewin
964
985
    small
966
987
    static
967
988
    swscale
968
989
    swscale_alpha
 
990
    thumb
969
991
    vaapi
 
992
    vda
970
993
    vdpau
971
994
    version3
972
995
    x11grab
1036
1059
    alsa_asoundlib_h
1037
1060
    altivec_h
1038
1061
    arpa_inet_h
 
1062
    asm_mod_y
1039
1063
    attribute_may_alias
1040
1064
    attribute_packed
1041
 
    bswap
1042
1065
    closesocket
1043
1066
    cmov
1044
1067
    dcbzl
1045
1068
    dev_bktr_ioctl_bt848_h
1046
1069
    dev_bktr_ioctl_meteor_h
1047
1070
    dev_ic_bt8xx_h
 
1071
    dev_video_bktr_ioctl_bt848_h
1048
1072
    dev_video_meteor_ioctl_meteor_h
1049
 
    dev_video_bktr_ioctl_bt848_h
1050
1073
    dlfcn_h
1051
1074
    dlopen
1052
1075
    dos_paths
1061
1084
    fork
1062
1085
    getaddrinfo
1063
1086
    gethrtime
 
1087
    GetProcessAffinityMask
1064
1088
    GetProcessMemoryInfo
1065
1089
    GetProcessTimes
1066
1090
    getrusage
1067
1091
    gnu_as
1068
 
    struct_rusage_ru_maxrss
1069
1092
    ibm_asm
1070
1093
    inet_aton
1071
1094
    inline_asm
1091
1114
    memalign
1092
1115
    mkstemp
1093
1116
    mmap
1094
 
    pld
 
1117
    poll_h
1095
1118
    posix_memalign
1096
1119
    round
1097
1120
    roundf
 
1121
    sched_getaffinity
1098
1122
    sdl
1099
1123
    sdl_video_size
1100
1124
    setmode
 
1125
    setrlimit
1101
1126
    sndio_h
1102
1127
    socklen_t
1103
1128
    soundcard_h
1104
 
    poll_h
1105
 
    setrlimit
1106
1129
    strerror_r
 
1130
    strptime
1107
1131
    strtok_r
1108
1132
    struct_addrinfo
1109
1133
    struct_ipv6_mreq
 
1134
    struct_rusage_ru_maxrss
1110
1135
    struct_sockaddr_in6
1111
1136
    struct_sockaddr_sa_len
1112
1137
    struct_sockaddr_storage
 
1138
    struct_v4l2_frmivalenum_discrete
1113
1139
    symver
 
1140
    symver_asm_label
1114
1141
    symver_gnu_asm
1115
 
    symver_asm_label
 
1142
    sysconf
 
1143
    sysctl
1116
1144
    sys_mman_h
 
1145
    sys_param_h
1117
1146
    sys_resource_h
1118
1147
    sys_select_h
1119
1148
    sys_soundcard_h
1120
1149
    sys_videoio_h
1121
 
    ten_operands
1122
1150
    threads
1123
1151
    trunc
1124
1152
    truncf
1181
1209
    logfile
1182
1210
    malloc_prefix
1183
1211
    nm
 
1212
    optflags
1184
1213
    pkg_config
1185
1214
    samples
1186
1215
    sysinclude
1227
1256
fast_clz_if_any="alpha armv5te avr32 mips ppc x86"
1228
1257
fast_unaligned_if_any="armv6 ppc x86"
1229
1258
 
 
1259
inline_asm_deps="!tms470"
1230
1260
need_memalign="altivec neon sse"
1231
 
inline_asm_deps="!tms470"
1232
1261
 
1233
1262
symver_if_any="symver_asm_label symver_gnu_asm"
1234
1263
 
1268
1297
flac_encoder_select="golomb lpc"
1269
1298
flashsv_decoder_select="zlib"
1270
1299
flashsv_encoder_select="zlib"
 
1300
flashsv2_decoder_select="zlib"
1271
1301
flv_decoder_select="h263_decoder"
1272
1302
flv_encoder_select="h263_encoder"
1273
1303
fraps_decoder_select="huffman"
1277
1307
h263_vaapi_hwaccel_select="vaapi h263_decoder"
1278
1308
h263i_decoder_select="h263_decoder"
1279
1309
h263p_encoder_select="h263_encoder"
1280
 
h264_decoder_select="golomb h264dsp h264pred"
 
1310
h264_decoder_select="golomb h264chroma h264dsp h264pred"
1281
1311
h264_dxva2_hwaccel_deps="dxva2api_h"
1282
1312
h264_dxva2_hwaccel_select="dxva2 h264_decoder"
1283
 
h264_vaapi_hwaccel_select="vaapi"
 
1313
h264_vaapi_hwaccel_select="vaapi h264_decoder"
 
1314
h264_vda_hwaccel_select="vda h264_decoder"
1284
1315
h264_vdpau_decoder_select="vdpau h264_decoder"
1285
1316
imc_decoder_select="fft mdct sinewin"
1286
1317
jpegls_decoder_select="golomb"
1290
1321
mjpeg_encoder_select="aandct"
1291
1322
mlp_decoder_select="mlp_parser"
1292
1323
mp1_decoder_select="mpegaudiodsp"
 
1324
mp1float_decoder_select="mpegaudiodsp"
1293
1325
mp2_decoder_select="mpegaudiodsp"
 
1326
mp2float_decoder_select="mpegaudiodsp"
 
1327
mp3_decoder_select="mpegaudiodsp"
1294
1328
mp3adu_decoder_select="mpegaudiodsp"
1295
 
mp3_decoder_select="mpegaudiodsp"
1296
 
mp3on4_decoder_select="mpegaudiodsp"
1297
 
mp1float_decoder_select="mpegaudiodsp"
1298
 
mp2float_decoder_select="mpegaudiodsp"
1299
1329
mp3adufloat_decoder_select="mpegaudiodsp"
1300
1330
mp3float_decoder_select="mpegaudiodsp"
 
1331
mp3on4_decoder_select="mpegaudiodsp"
1301
1332
mp3on4float_decoder_select="mpegaudiodsp"
1302
 
mpeg1video_encoder_select="aandct"
1303
 
mpeg2video_encoder_select="aandct"
1304
 
mpeg4_decoder_select="h263_decoder mpeg4video_parser"
1305
 
mpeg4_encoder_select="h263_encoder"
 
1333
mpc7_decoder_select="mpegaudiodsp"
 
1334
mpc8_decoder_select="mpegaudiodsp"
1306
1335
mpeg_vdpau_decoder_select="vdpau mpegvideo_decoder"
 
1336
mpeg_xvmc_decoder_deps="X11_extensions_XvMClib_h"
 
1337
mpeg_xvmc_decoder_select="mpegvideo_decoder"
1307
1338
mpeg1_vdpau_decoder_select="vdpau mpeg1video_decoder"
 
1339
mpeg1video_encoder_select="aandct"
1308
1340
mpeg2_dxva2_hwaccel_deps="dxva2api_h"
1309
1341
mpeg2_dxva2_hwaccel_select="dxva2 mpeg2video_decoder"
1310
1342
mpeg2_vaapi_hwaccel_select="vaapi mpeg2video_decoder"
 
1343
mpeg2video_encoder_select="aandct"
 
1344
mpeg4_decoder_select="h263_decoder mpeg4video_parser"
 
1345
mpeg4_encoder_select="h263_encoder"
1311
1346
mpeg4_vaapi_hwaccel_select="vaapi mpeg4_decoder"
1312
1347
mpeg4_vdpau_decoder_select="vdpau mpeg4_decoder"
1313
 
mpeg_xvmc_decoder_deps="X11_extensions_XvMClib_h"
1314
 
mpeg_xvmc_decoder_select="mpegvideo_decoder"
1315
1348
msmpeg4v1_decoder_select="h263_decoder"
1316
1349
msmpeg4v1_encoder_select="h263_encoder"
1317
1350
msmpeg4v2_decoder_select="h263_decoder"
1329
1362
rv10_encoder_select="h263_encoder"
1330
1363
rv20_decoder_select="h263_decoder"
1331
1364
rv20_encoder_select="h263_encoder"
1332
 
rv30_decoder_select="golomb h264pred"
1333
 
rv40_decoder_select="golomb h264pred"
 
1365
rv30_decoder_select="golomb h264chroma h264pred"
 
1366
rv40_decoder_select="golomb h264chroma h264pred"
1334
1367
shorten_decoder_select="golomb"
1335
1368
sipr_decoder_select="lsp"
1336
1369
snow_decoder_select="dwt"
1337
1370
snow_encoder_select="aandct dwt"
1338
1371
svq1_encoder_select="aandct"
1339
 
svq3_decoder_select="golomb h264dsp h264pred"
 
1372
svq3_decoder_select="golomb h264chroma h264dsp h264pred"
1340
1373
svq3_decoder_suggest="zlib"
1341
1374
theora_decoder_select="vp3_decoder"
1342
1375
tiff_decoder_suggest="zlib"
1344
1377
truehd_decoder_select="mlp_decoder"
1345
1378
tscc_decoder_select="zlib"
1346
1379
twinvq_decoder_select="mdct lsp sinewin"
1347
 
vc1_decoder_select="h263_decoder"
 
1380
vc1_decoder_select="h263_decoder h264chroma"
1348
1381
vc1_dxva2_hwaccel_deps="dxva2api_h DXVA_PictureParameters_wDecodedPictureIndex"
1349
1382
vc1_dxva2_hwaccel_select="dxva2 vc1_decoder"
1350
1383
vc1_vaapi_hwaccel_select="vaapi vc1_decoder"
1351
1384
vc1_vdpau_decoder_select="vdpau vc1_decoder"
 
1385
vc1image_decoder_select="vc1_decoder"
1352
1386
vorbis_decoder_select="mdct"
1353
1387
vorbis_encoder_select="mdct"
1354
1388
vp6_decoder_select="huffman"
1369
1403
wmv3_dxva2_hwaccel_select="vc1_dxva2_hwaccel"
1370
1404
wmv3_vaapi_hwaccel_select="vc1_vaapi_hwaccel"
1371
1405
wmv3_vdpau_decoder_select="vc1_vdpau_decoder"
 
1406
wmv3image_decoder_select="wmv3_decoder"
1372
1407
zlib_decoder_select="zlib"
1373
1408
zlib_encoder_select="zlib"
1374
1409
zmbv_decoder_select="zlib"
1375
1410
zmbv_encoder_select="zlib"
1376
1411
 
1377
1412
vaapi_deps="va_va_h"
 
1413
vda_deps="VideoDecodeAcceleration_VDADecoder_h pthreads"
1378
1414
vdpau_deps="vdpau_vdpau_h vdpau_vdpau_x11_h"
1379
1415
 
1380
1416
# parsers
1381
 
h264_parser_select="golomb h264dsp h264pred"
 
1417
h264_parser_select="golomb h264chroma h264dsp h264pred"
1382
1418
 
1383
1419
# external libraries
1384
1420
libdirac_decoder_deps="libdirac !libschroedinger"
1396
1432
libschroedinger_decoder_deps="libschroedinger"
1397
1433
libschroedinger_encoder_deps="libschroedinger"
1398
1434
libspeex_decoder_deps="libspeex"
 
1435
libspeex_encoder_deps="libspeex"
1399
1436
libtheora_encoder_deps="libtheora"
1400
1437
libvo_aacenc_encoder_deps="libvo_aacenc"
1401
1438
libvo_amrwbenc_encoder_deps="libvo_amrwbenc"
1444
1481
dv1394_indev_deps="dv1394 dv_demuxer"
1445
1482
fbdev_indev_deps="linux_fb_h"
1446
1483
jack_indev_deps="jack_jack_h"
 
1484
libcdio_indev_deps="libcdio"
1447
1485
libdc1394_indev_deps="libdc1394"
1448
1486
oss_indev_deps_any="soundcard_h sys_soundcard_h"
1449
1487
oss_outdev_deps_any="soundcard_h sys_soundcard_h"
 
1488
pulse_indev_deps="libpulse"
1450
1489
sndio_indev_deps="sndio_h"
1451
1490
sndio_outdev_deps="sndio_h"
1452
1491
v4l_indev_deps="linux_videodev_h"
1458
1497
 
1459
1498
# protocols
1460
1499
gopher_protocol_deps="network"
 
1500
httpproxy_protocol_deps="network"
 
1501
httpproxy_protocol_select="tcp_protocol"
1461
1502
http_protocol_deps="network"
1462
1503
http_protocol_select="tcp_protocol"
 
1504
https_protocol_select="tls_protocol"
1463
1505
mmsh_protocol_select="http_protocol"
1464
1506
mmst_protocol_deps="network"
1465
1507
rtmp_protocol_select="tcp_protocol"
1466
1508
rtp_protocol_select="udp_protocol"
1467
1509
tcp_protocol_deps="network"
 
1510
tls_protocol_deps_any="openssl gnutls"
 
1511
tls_protocol_select="tcp_protocol"
1468
1512
udp_protocol_deps="network"
1469
1513
 
1470
1514
# filters
1471
1515
blackframe_filter_deps="gpl"
 
1516
boxblur_filter_deps="gpl"
1472
1517
cropdetect_filter_deps="gpl"
 
1518
delogo_filter_deps="gpl"
1473
1519
drawtext_filter_deps="libfreetype"
1474
1520
frei0r_filter_deps="frei0r dlopen strtok_r"
1475
1521
frei0r_src_filter_deps="frei0r dlopen strtok_r"
1484
1530
postproc_deps="gpl"
1485
1531
 
1486
1532
# programs
 
1533
avconv_deps="avcodec avformat swscale"
 
1534
avplay_deps="avcodec avformat swscale sdl"
 
1535
avplay_select="rdft"
 
1536
avprobe_deps="avcodec avformat"
 
1537
avserver_deps="avformat ffm_muxer fork rtp_protocol rtsp_demuxer"
 
1538
avserver_extralibs='$ldl'
1487
1539
ffmpeg_deps="avcodec avformat swscale"
1488
 
ffmpeg_select="buffer_filter"
1489
 
ffplay_deps="avcodec avformat swscale sdl"
1490
 
ffplay_select="rdft"
1491
 
ffprobe_deps="avcodec avformat"
1492
 
ffserver_deps="avformat ffm_muxer fork rtp_protocol rtsp_demuxer"
1493
 
ffserver_extralibs='$ldl'
1494
1540
 
1495
1541
doc_deps="texi2html"
1496
1542
 
1509
1555
    done
1510
1556
}
1511
1557
 
1512
 
set_ne_test_deps(){
1513
 
    eval ${1}_be_test_deps="bigendian"
1514
 
    eval ${1}_le_test_deps="!bigendian"
1515
 
}
1516
 
 
1517
1558
mxf_d10_test_deps="avfilter"
1518
1559
seek_lavf_mxf_d10_test_deps="mxf_d10_test"
1519
1560
 
1520
1561
test_deps _encoder _decoder                                             \
1521
 
    adpcm_g726=g726                                                     \
1522
1562
    adpcm_ima_qt                                                        \
1523
1563
    adpcm_ima_wav                                                       \
1524
1564
    adpcm_ms                                                            \
1529
1569
    asv2                                                                \
1530
1570
    bmp                                                                 \
1531
1571
    dnxhd="dnxhd_1080i dnxhd_720p dnxhd_720p_rd"                        \
1532
 
    dvvideo="dv dv50"                                                   \
 
1572
    dvvideo="dv dv_411 dv50"                                            \
1533
1573
    ffv1                                                                \
1534
1574
    flac                                                                \
1535
1575
    flashsv                                                             \
1536
1576
    flv                                                                 \
 
1577
    adpcm_g726=g726                                                     \
1537
1578
    gif                                                                 \
1538
1579
    h261                                                                \
1539
1580
    h263="h263 h263p"                                                   \
1542
1583
    mjpeg="jpg mjpeg ljpeg"                                             \
1543
1584
    mp2                                                                 \
1544
1585
    mpeg1video="mpeg mpeg1b"                                            \
1545
 
    mpeg2video="mpeg2 mpeg2thread"                                      \
1546
 
    mpeg4="mpeg4 mpeg4adv mpeg4nr mpeg4thread error rc"                 \
 
1586
    mpeg2video="mpeg2 mpeg2_422 mpeg2_idct_int mpeg2_ilace mpeg2_ivlc_qprd" \
 
1587
    mpeg2video="mpeg2thread mpeg2thread_ilace"                          \
 
1588
    mpeg4="mpeg4 mpeg4_adap mpeg4_qpel mpeg4_qprd mpeg4adv mpeg4nr"     \
 
1589
    mpeg4="mpeg4thread error rc"                                        \
1547
1590
    msmpeg4v3=msmpeg4                                                   \
1548
1591
    msmpeg4v2                                                           \
1549
1592
    pbm=pbmpipe                                                         \
1593
1636
ac3_fixed_test_deps="ac3_fixed_encoder ac3_decoder rm_muxer rm_demuxer"
1594
1637
mpg_test_deps="mpeg1system_muxer mpegps_demuxer"
1595
1638
 
1596
 
set_ne_test_deps pixdesc
1597
 
set_ne_test_deps pixfmts_copy
1598
 
set_ne_test_deps pixfmts_crop
1599
 
set_ne_test_deps pixfmts_hflip
1600
 
set_ne_test_deps pixfmts_null
1601
 
set_ne_test_deps pixfmts_pad
1602
 
set_ne_test_deps pixfmts_scale
1603
 
set_ne_test_deps pixfmts_vflip
1604
 
 
1605
1639
# default parameters
1606
1640
 
1607
1641
logfile="config.log"
1609
1643
# installation paths
1610
1644
prefix_default="/usr/local"
1611
1645
bindir_default='${prefix}/bin'
1612
 
datadir_default='${prefix}/share/ffmpeg'
 
1646
datadir_default='${prefix}/share/avconv'
1613
1647
incdir_default='${prefix}/include'
1614
1648
libdir_default='${prefix}/lib'
1615
1649
mandir_default='${prefix}/share/man'
1626
1660
pkg_config_default=pkg-config
1627
1661
ranlib="ranlib"
1628
1662
yasmexe="yasm"
 
1663
 
 
1664
nm_opts='-g'
1629
1665
nogas=":"
1630
1666
 
1631
 
nm_opts='-g'
1632
 
 
1633
1667
# machine
1634
1668
arch_default=$(uname -m)
1635
1669
cpu="generic"
1639
1673
host_os=$target_os_default
1640
1674
 
1641
1675
# configurable options
 
1676
enable $PROGRAM_LIST
 
1677
 
1642
1678
enable avcodec
1643
1679
enable avdevice
1644
1680
enable avfilter
1645
1681
enable avformat
1646
1682
enable avutil
 
1683
enable swscale
 
1684
 
1647
1685
enable asm
1648
1686
enable debug
1649
1687
enable doc
1650
1688
enable fastdiv
1651
 
enable ffmpeg
1652
 
enable ffplay
1653
 
enable ffprobe
1654
 
enable ffserver
1655
1689
enable network
1656
1690
enable optimizations
1657
 
enable postproc
1658
 
enable protocols
 
1691
enable safe_bitstream_reader
1659
1692
enable static
1660
 
enable swscale
1661
1693
enable swscale_alpha
1662
1694
 
1663
1695
# build settings
1664
1696
SHFLAGS='-shared -Wl,-soname,$$(@F)'
1665
 
FFSERVERLDFLAGS=-Wl,-E
 
1697
AVSERVERLDFLAGS=-Wl,-E
1666
1698
LIBPREF="lib"
1667
1699
LIBSUF=".a"
1668
1700
FULLNAME='$(NAME)$(BUILDSUF)'
1673
1705
SLIBNAME_WITH_VERSION='$(SLIBNAME).$(LIBVERSION)'
1674
1706
SLIBNAME_WITH_MAJOR='$(SLIBNAME).$(LIBMAJOR)'
1675
1707
LIB_INSTALL_EXTRA_CMD='$$(RANLIB) "$(LIBDIR)/$(LIBNAME)"'
 
1708
SLIB_INSTALL_NAME='$(SLIBNAME_WITH_VERSION)'
 
1709
SLIB_INSTALL_LINKS='$(SLIBNAME_WITH_MAJOR) $(SLIBNAME)'
1676
1710
 
 
1711
AS_O='-o $@'
1677
1712
CC_O='-o $@'
1678
1713
 
1679
1714
host_cflags='-D_ISOC99_SOURCE -O3 -g'
1688
1723
 
1689
1724
# find source path
1690
1725
if test -f configure; then
1691
 
    source_path="$(pwd)"
1692
 
    disable source_path_used
 
1726
    source_path=.
1693
1727
else
1694
1728
    source_path=$(cd $(dirname "$0"); pwd)
1695
 
    enable source_path_used
1696
1729
    echo "$source_path" | grep -q '[[:blank:]]' &&
1697
1730
        die "Out of tree builds are impossible with whitespace in source path."
1698
1731
    test -e "$source_path/config.h" &&
1725
1758
PROTOCOL_LIST=$(find_things protocol PROTOCOL libavformat/allformats.c)
1726
1759
FILTER_LIST=$(find_things   filter   FILTER   libavfilter/allfilters.c)
1727
1760
 
 
1761
ALL_COMPONENTS="
 
1762
    $BSF_LIST
 
1763
    $DECODER_LIST
 
1764
    $DEMUXER_LIST
 
1765
    $ENCODER_LIST
 
1766
    $FILTER_LIST
 
1767
    $HWACCEL_LIST
 
1768
    $INDEV_LIST
 
1769
    $MUXER_LIST
 
1770
    $OUTDEV_LIST
 
1771
    $PARSER_LIST
 
1772
    $PROTOCOL_LIST
 
1773
"
 
1774
 
1728
1775
find_tests(){
1729
1776
    map "echo ${2}\${v}_test" $(ls "$source_path"/tests/ref/$1 | grep -v '[^-a-z0-9_]')
1730
1777
}
1735
1782
LAVFI_TESTS=$(find_tests lavfi)
1736
1783
SEEK_TESTS=$(find_tests seek seek_)
1737
1784
 
 
1785
ALL_TESTS="$ACODEC_TESTS $VCODEC_TESTS $LAVF_TESTS $LAVFI_TESTS $SEEK_TESTS"
 
1786
 
1738
1787
pcm_test_deps=$(map 'echo ${v%_*}_decoder $v' $(filter pcm_* $ENCODER_LIST))
1739
1788
 
1740
1789
for n in $COMPONENT_LIST; do
1743
1792
    eval ${n}_if_any="\$$v"
1744
1793
done
1745
1794
 
1746
 
enable $ARCH_EXT_LIST $ACODEC_TESTS $VCODEC_TESTS $LAVF_TESTS $LAVFI_TESTS $SEEK_TESTS
 
1795
enable $ARCH_EXT_LIST $ALL_TESTS
1747
1796
 
1748
1797
die_unknown(){
1749
1798
    echo "Unknown option \"$1\"."
1876
1925
 
1877
1926
trap 'rm -f -- $TMPFILES' EXIT
1878
1927
 
1879
 
tmpfile TMPC  .c
1880
 
tmpfile TMPE  $EXESUF
1881
 
tmpfile TMPH  .h
1882
 
tmpfile TMPO  .o
1883
 
tmpfile TMPS  .S
1884
 
tmpfile TMPV  .ver
1885
 
tmpfile TMPSH .sh
1886
1928
tmpfile TMPASM .asm
 
1929
tmpfile TMPC   .c
 
1930
tmpfile TMPE   $EXESUF
 
1931
tmpfile TMPH   .h
 
1932
tmpfile TMPO   .o
 
1933
tmpfile TMPS   .S
 
1934
tmpfile TMPSH  .sh
 
1935
tmpfile TMPV   .ver
1887
1936
 
1888
1937
unset -f mktemp
1889
1938
 
1902
1951
    die "Sanity test failed."
1903
1952
fi
1904
1953
 
 
1954
filter_asflags=echo
1905
1955
filter_cflags=echo
1906
1956
filter_cppflags=echo
1907
 
filter_asflags=echo
1908
1957
 
1909
1958
if   $cc -v 2>&1 | grep -q '^gcc.*LLVM'; then
1910
1959
    cc_type=llvm_gcc
2028
2077
    cc_ident=$($cc -V 2>&1 | head -n1 | cut -d' ' -f 2-)
2029
2078
    DEPEND_CMD='$(DEPCC) $(DEPFLAGS) $< | sed -e "1s,^.*: ,$@: ," -e "\$$!s,\$$, \\\," -e "1!s,^.*: , ," > $(@:.o=.d)'
2030
2079
    DEPFLAGS='$(CPPFLAGS) $(CFLAGS) -xM1'
 
2080
    add_ldflags -xc99
2031
2081
    speed_cflags='-O5'
2032
2082
    size_cflags='-O5 -xspace'
2033
2083
    filter_cflags=suncc_flags
2118
2168
        gcc|llvm_gcc)
2119
2169
            check_native(){
2120
2170
                $cc $1=native -v -c -o $TMPO $TMPC >$TMPE 2>&1 || return
2121
 
                sed -n "/$1=/{
 
2171
                sed -n "/cc1.*$1=/{
2122
2172
                            s/.*$1=\\([^ ]*\\).*/\\1/
2123
2173
                            p
2124
2174
                            q
2233
2283
            disable cmov
2234
2284
        ;;
2235
2285
        # targets that do support conditional mov (cmov)
2236
 
        i686|pentiumpro|pentium[23]|pentium-m|athlon|athlon-tbird|athlon-4|athlon-[mx]p|athlon64|k8|opteron|athlon-fx|core2|amdfam10|barcelona|atom)
 
2286
        i686|pentiumpro|pentium[23]|pentium-m|athlon|athlon-tbird|athlon-4|athlon-[mx]p|athlon64*|k8*|opteron*|athlon-fx|core2|amdfam10|barcelona|atom)
2237
2287
            cpuflags="-march=$cpu"
2238
2288
            enable cmov
2239
2289
            enable fast_cmov
2270
2320
            case $cpu in
2271
2321
                cortex-a*)                               subarch=armv7a  ;;
2272
2322
                cortex-r*)                               subarch=armv7r  ;;
2273
 
                cortex-m*)                               subarch=armv7m  ;;
 
2323
                cortex-m*)                 enable thumb; subarch=armv7m  ;;
2274
2324
                arm11*)                                  subarch=armv6   ;;
2275
2325
                arm[79]*e*|arm9[24]6*|arm96*|arm102[26]) subarch=armv5te ;;
2276
2326
                armv4*|arm7*|arm9[24]*)                  subarch=armv4   ;;
2367
2417
        host_libs=
2368
2418
        ;;
2369
2419
    sunos)
2370
 
        FFSERVERLDFLAGS=""
 
2420
        AVSERVERLDFLAGS=""
2371
2421
        SHFLAGS='-shared -Wl,-h,$$(@F)'
2372
2422
        enabled x86 && SHFLAGS="-mimpure-text $SHFLAGS"
2373
2423
        network_extralibs="-lsocket -lnsl"
2374
2424
        add_cppflags -D__EXTENSIONS__
 
2425
        # When using suncc to build, the Solaris linker will mark
 
2426
        # an executable with each instruction set encountered by
 
2427
        # the Solaris assembler.  As our libraries contain their own
 
2428
        # guards for processor-specific code, instead suppress
 
2429
        # generation of the HWCAPS ELF section on Solaris x86 only.
 
2430
        enabled_all suncc x86 && echo "hwcap_1 = OVERRIDE;" > mapfile && add_ldflags -Wl,-M,mapfile
2375
2431
        nm_opts='-P -g'
2376
2432
        ;;
2377
2433
    netbsd)
2412
2468
        SLIBSUF=".dylib"
2413
2469
        SLIBNAME_WITH_VERSION='$(SLIBPREF)$(FULLNAME).$(LIBVERSION)$(SLIBSUF)'
2414
2470
        SLIBNAME_WITH_MAJOR='$(SLIBPREF)$(FULLNAME).$(LIBMAJOR)$(SLIBSUF)'
2415
 
        FFSERVERLDFLAGS=-Wl,-bind_at_load
 
2471
        AVSERVERLDFLAGS=-Wl,-bind_at_load
2416
2472
        objformat="macho"
2417
2473
        enabled x86_64 && objformat="macho64"
2418
2474
        enabled_any pic shared ||
2436
2492
        SLIBSUF=".dll"
2437
2493
        SLIBNAME_WITH_VERSION='$(SLIBPREF)$(FULLNAME)-$(LIBVERSION)$(SLIBSUF)'
2438
2494
        SLIBNAME_WITH_MAJOR='$(SLIBPREF)$(FULLNAME)-$(LIBMAJOR)$(SLIBSUF)'
2439
 
        SLIB_EXTRA_CMD=-'$(DLLTOOL) -m $(LIBTARGET) -d $$(@:$(SLIBSUF)=.def) -l $(SUBDIR)$(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.lib) -D $(SLIBNAME_WITH_MAJOR)'
2440
 
        SLIB_INSTALL_EXTRA_CMD='-install -m 644 $(SUBDIR)$(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.lib) "$(SHLIBDIR)/$(SLIBNAME:$(SLIBSUF)=.lib)"; \
2441
 
            install -m 644 $(SUBDIR)$(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.lib) "$(SHLIBDIR)/$(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.lib)"; \
2442
 
            install -d "$(LIBDIR)"; \
2443
 
            install -m 644 $(SUBDIR)lib$(SLIBNAME:$(SLIBSUF)=.dll.a) "$(LIBDIR)/lib$(SLIBNAME:$(SLIBSUF)=.dll.a)"'
2444
 
        SLIB_UNINSTALL_EXTRA_CMD='rm -f "$(SHLIBDIR)/$(SLIBNAME:$(SLIBSUF)=.lib)"'
 
2495
        SLIB_EXTRA_CMD=-'$(DLLTOOL) -m $(LIBTARGET) -d $$(@:$(SLIBSUF)=.def) -l $(SUBDIR)$(SLIBNAME:$(SLIBSUF)=.lib) -D $(SLIBNAME_WITH_MAJOR)'
 
2496
        SLIB_INSTALL_NAME='$(SLIBNAME_WITH_MAJOR)'
 
2497
        SLIB_INSTALL_LINKS=
 
2498
        SLIB_INSTALL_EXTRA_SHLIB='$(SLIBNAME:$(SLIBSUF)=.lib)'
 
2499
        SLIB_INSTALL_EXTRA_LIB='lib$(SLIBNAME:$(SLIBSUF)=.dll.a) $(SLIBNAME_WITH_MAJOR:$(SLIBSUF)=.def)'
2445
2500
        SHFLAGS='-shared -Wl,--output-def,$$(@:$(SLIBSUF)=.def) -Wl,--out-implib,$(SUBDIR)lib$(SLIBNAME:$(SLIBSUF)=.dll.a) -Wl,--enable-runtime-pseudo-reloc -Wl,--enable-auto-image-base'
2446
2501
        objformat="win32"
2447
2502
        dlltool="${cross_prefix}dlltool"
2485
2540
        add_cppflags -D_GNU_SOURCE
2486
2541
        add_ldflags -Zomf -Zbin-files -Zargs-wild -Zmap
2487
2542
        SHFLAGS='$(SUBDIR)$(NAME).def -Zdll -Zomf'
2488
 
        FFSERVERLDFLAGS=""
 
2543
        AVSERVERLDFLAGS=""
2489
2544
        LIBSUF="_s.a"
2490
2545
        SLIBPREF=""
2491
2546
        SLIBSUF=".dll"
2499
2554
          emxexp -o $(OBJS) >> $(SUBDIR)$(NAME).def'
2500
2555
        SLIB_EXTRA_CMD='emximp -o $(SUBDIR)$(LIBPREF)$(NAME)_dll.a $(SUBDIR)$(NAME).def; \
2501
2556
          emximp -o $(SUBDIR)$(LIBPREF)$(NAME)_dll.lib $(SUBDIR)$(NAME).def;'
2502
 
        SLIB_INSTALL_EXTRA_CMD='install -m 644 $(SUBDIR)$(LIBPREF)$(NAME)_dll.a $(SUBDIR)$(LIBPREF)$(NAME)_dll.lib "$(LIBDIR)"'
2503
 
        SLIB_UNINSTALL_EXTRA_CMD='rm -f "$(LIBDIR)"/$(LIBPREF)$(NAME)_dll.a "$(LIBDIR)"/$(LIBPREF)$(NAME)_dll.lib'
 
2557
        SLIB_INSTALL_EXTRA_LIB='$(LIBPREF)$(NAME)_dll.a $(LIBPREF)$(NAME)_dll.lib'
2504
2558
        enable dos_paths
2505
2559
        ;;
2506
2560
    gnu/kfreebsd)
2516
2570
    symbian)
2517
2571
        SLIBSUF=".dll"
2518
2572
        enable dos_paths
2519
 
        add_cflags --include=$sysinclude/gcce/gcce.h
 
2573
        add_cflags --include=$sysinclude/gcce/gcce.h -fvisibility=default
 
2574
        add_cppflags -D__GCCE__ -D__SYMBIAN32__ -DSYMBIAN_OE_POSIX_SIGNALS
 
2575
        add_ldflags -Wl,--target1-abs,--no-undefined \
 
2576
                    -Wl,-Ttext,0x80000,-Tdata,0x1000000 -shared \
 
2577
                    -Wl,--entry=_E32Startup -Wl,-u,_E32Startup
 
2578
        add_extralibs -l:eexe.lib -l:usrt2_2.lib -l:dfpaeabi.dso \
 
2579
                      -l:drtaeabi.dso -l:scppnwdl.dso -lsupc++ -lgcc \
 
2580
                      -l:libc.dso -l:libm.dso -l:euser.dso -l:libcrt0.lib
2520
2581
        ;;
2521
2582
    none)
2522
2583
        ;;
2542
2603
    exit 1;
2543
2604
fi
2544
2605
 
2545
 
disabled static && LIBNAME=""
2546
 
 
2547
2606
die_license_disabled() {
2548
2607
    enabled $1 || { enabled $2 && die "$2 is $1 and --enable-$1 is not specified."; }
2549
2608
}
2550
2609
 
 
2610
die_license_disabled gpl libcdio
2551
2611
die_license_disabled gpl libx264
2552
2612
die_license_disabled gpl libxavs
2553
2613
die_license_disabled gpl libxvid
2554
2614
die_license_disabled gpl x11grab
2555
2615
 
2556
2616
die_license_disabled nonfree libfaac
 
2617
die_license_disabled nonfree openssl
2557
2618
 
2558
2619
die_license_disabled version3 libopencore_amrnb
2559
2620
die_license_disabled version3 libopencore_amrwb
2609
2670
 
2610
2671
elif enabled arm; then
2611
2672
 
2612
 
    check_cflags -marm
 
2673
    enabled thumb && check_cflags -mthumb || check_cflags -marm
2613
2674
    nogas=die
2614
2675
 
2615
2676
    if     check_cpp_condition stddef.h "defined __ARM_PCS_VFP"; then
2625
2686
        warn "Compiler does not indicate floating-point ABI, guessing $fpabi."
2626
2687
    fi
2627
2688
 
2628
 
    # We have to check if pld is a nop and disable it.
2629
 
    check_asm pld '"pld [r0]"'
2630
 
 
2631
2689
    enabled armv5te && check_asm armv5te '"qadd r0, r0, r0"'
2632
2690
    enabled armv6   && check_asm armv6   '"sadd16 r0, r0, r0"'
2633
2691
    enabled armv6t2 && check_asm armv6t2 '"movt r0, #0"'
2636
2694
    enabled neon    && check_asm neon    '"vadd.i16 q0, q0, q0"'
2637
2695
    enabled vfpv3   && check_asm vfpv3   '"vmov.f32 s0, #1.0"'
2638
2696
 
 
2697
    check_asm asm_mod_y '"vmul.i32 d0, d0, %y0" :: "x"(0)'
 
2698
 
2639
2699
    enabled_all armv6t2 shared !pic && enable_pic
2640
2700
 
2641
2701
elif enabled mips; then
2704
2764
    # check whether xmm clobbers are supported
2705
2765
    check_asm xmm_clobbers '"":::"%xmm0"'
2706
2766
 
2707
 
    # check whether more than 10 operands are supported
2708
 
    check_cc <<EOF && enable ten_operands
2709
 
int main(void) {
2710
 
    int x=0;
2711
 
    __asm__ volatile(
2712
 
        ""
2713
 
        :"+&rm"(x), "+&rm"(x), "+&rm"(x), "+&rm"(x), "+&rm"(x), "+&rm"(x)
2714
 
    );
2715
 
    return 0;
2716
 
}
2717
 
EOF
2718
 
 
2719
2767
    # check whether binutils is new enough to compile SSSE3/MMX2
2720
2768
    enabled ssse3 && check_asm ssse3 '"pabsw %xmm0, %xmm0"'
2721
2769
    enabled mmx2  && check_asm mmx2  '"pmaxub %mm0, %mm1"'
2722
2770
 
2723
 
    check_asm bswap '"bswap %%eax" ::: "%eax"'
2724
 
 
2725
2771
    if ! disabled_any asm mmx yasm; then
2726
2772
        if check_cmd $yasmexe --version; then
2727
2773
            enabled x86_64 && yasm_extra="-m amd64"
2810
2856
check_func  ${malloc_prefix}posix_memalign      && enable posix_memalign
2811
2857
check_func  setrlimit
2812
2858
check_func  strerror_r
 
2859
check_func  strptime
2813
2860
check_func  strtok_r
 
2861
check_func  sched_getaffinity
 
2862
check_func  sysconf
 
2863
check_func  sysctl
2814
2864
check_func_headers io.h setmode
2815
2865
check_func_headers lzo/lzo1x.h lzo1x_999_compress
2816
2866
check_lib2 "windows.h psapi.h" GetProcessMemoryInfo -lpsapi
 
2867
check_func_headers windows.h GetProcessAffinityMask
2817
2868
check_func_headers windows.h GetProcessTimes
2818
2869
check_func_headers windows.h MapViewOfFile
2819
2870
check_func_headers windows.h VirtualAlloc
2823
2874
check_header malloc.h
2824
2875
check_header poll.h
2825
2876
check_header sys/mman.h
 
2877
check_header sys/param.h
2826
2878
check_header sys/resource.h
2827
2879
check_header sys/select.h
2828
2880
check_header vdpau/vdpau.h
2834
2886
disabled  zlib || check_lib   zlib.h      zlibVersion -lz   || disable  zlib
2835
2887
disabled bzlib || check_lib2 bzlib.h BZ2_bzlibVersion -lbz2 || disable bzlib
2836
2888
 
 
2889
if ! disabled w32threads && ! enabled pthreads; then
 
2890
    check_func _beginthreadex && enable w32threads
 
2891
fi
 
2892
 
2837
2893
# check for some common methods of building with pthread support
2838
2894
# do this before the optional library checks as some of them require pthreads
2839
2895
if ! disabled pthreads && ! enabled w32threads; then
2880
2936
# these are off by default, so fail if requested and not available
2881
2937
enabled avisynth   && require2 vfw32 "windows.h vfw.h" AVIFileInit -lavifil32
2882
2938
enabled frei0r     && { check_header frei0r.h || die "ERROR: frei0r.h header not found"; }
 
2939
enabled gnutls     && require_pkg_config gnutls gnutls/gnutls.h gnutls_global_init
2883
2940
enabled libdirac   && require_pkg_config dirac                          \
2884
2941
    "libdirac_decoder/dirac_parser.h libdirac_encoder/dirac_encoder.h"  \
2885
2942
    "dirac_decoder_init dirac_encoder_init"
2892
2949
enabled libopencore_amrwb  && require libopencore_amrwb opencore-amrwb/dec_if.h D_IF_init -lopencore-amrwb
2893
2950
enabled libopencv  && require_pkg_config opencv opencv/cv.h cvCreateImageHeader
2894
2951
enabled libopenjpeg && require libopenjpeg openjpeg.h opj_version -lopenjpeg
 
2952
enabled libpulse && require_pkg_config libpulse-simple pulse/simple.h pa_simple_new
2895
2953
enabled librtmp    && require_pkg_config librtmp librtmp/rtmp.h RTMP_Socket
2896
2954
enabled libschroedinger && require_pkg_config schroedinger-1.0 schroedinger/schro.h schro_init
2897
2955
enabled libspeex   && require  libspeex speex/speex.h speex_decoder_init -lspeex
2905
2963
    enabled libvpx_encoder && { check_lib2 "vpx/vpx_encoder.h vpx/vp8cx.h" vpx_codec_enc_init_ver -lvpx ||
2906
2964
                                die "ERROR: libvpx encoder version must be >=0.9.1"; } }
2907
2965
enabled libx264    && require  libx264 x264.h x264_encoder_encode -lx264 &&
2908
 
                      { check_cpp_condition x264.h "X264_BUILD >= 115" ||
2909
 
                        die "ERROR: libx264 version must be >= 0.115."; }
 
2966
                      { check_cpp_condition x264.h "X264_BUILD >= 118" ||
 
2967
                        die "ERROR: libx264 version must be >= 0.118."; }
2910
2968
enabled libxavs    && require  libxavs xavs.h xavs_encoder_encode -lxavs
2911
2969
enabled libxvid    && require  libxvid xvid.h xvid_global -lxvidcore
2912
2970
enabled mlib       && require  mediaLib mlib_types.h mlib_VectorSub_S16_U8_Mod -lmlib
 
2971
enabled openssl    && { check_lib openssl/ssl.h SSL_library_init -lssl -lcrypto ||
 
2972
                        check_lib openssl/ssl.h SSL_library_init -lssl32 -leay32 ||
 
2973
                        check_lib openssl/ssl.h SSL_library_init -lssl -lcrypto -lws2_32 -lgdi32 ||
 
2974
                        die "ERROR: openssl not found"; }
2913
2975
 
2914
2976
# libdc1394 check
2915
2977
if enabled libdc1394; then
2931
2993
check_header linux/fb.h
2932
2994
check_header linux/videodev.h
2933
2995
check_header linux/videodev2.h
 
2996
check_struct linux/videodev2.h "struct v4l2_frmivalenum" discrete
 
2997
 
2934
2998
check_header sys/videoio.h
2935
2999
 
2936
3000
check_func_headers "windows.h vfw.h" capCreateCaptureWindow "$vfwcap_indev_extralibs"
2957
3021
 
2958
3022
enabled_any sndio_indev sndio_outdev && check_lib2 sndio.h sio_open -lsndio
2959
3023
 
 
3024
enabled libcdio &&
 
3025
    check_lib2 "cdio/cdda.h cdio/paranoia.h" cdio_cddap_open "-lcdio_paranoia -lcdio_cdda -lcdio"
 
3026
 
2960
3027
enabled x11grab                         &&
2961
3028
check_header X11/Xlib.h                 &&
2962
3029
check_header X11/extensions/XShm.h      &&
2965
3032
check_func XShmCreateImage -lX11 -lXext &&
2966
3033
check_func XFixesGetCursorImage -lX11 -lXext -lXfixes
2967
3034
 
 
3035
# check for VDA header
 
3036
if ! disabled vda && check_header VideoDecodeAcceleration/VDADecoder.h; then
 
3037
    enable vda && add_extralibs -framework CoreFoundation -framework VideoDecodeAcceleration -framework QuartzCore
 
3038
fi
 
3039
 
2968
3040
if ! disabled vdpau && enabled vdpau_vdpau_h; then
2969
3041
check_cpp_condition \
2970
3042
    vdpau/vdpau.h "defined VDP_DECODER_PROFILE_MPEG4_PART2_ASP" ||
2979
3051
check_cflags -Wall
2980
3052
check_cflags -Wno-parentheses
2981
3053
check_cflags -Wno-switch
 
3054
check_cflags -Wno-format-zero-length
2982
3055
check_cflags -Wdisabled-optimization
2983
3056
check_cflags -Wpointer-arith
2984
3057
check_cflags -Wredundant-decls
2988
3061
check_cflags -Wtype-limits
2989
3062
check_cflags -Wundef
2990
3063
check_cflags -Wmissing-prototypes
 
3064
check_cflags -Wstrict-prototypes
2991
3065
enabled extra_warnings && check_cflags -Winline
2992
3066
 
2993
3067
# add some linker flags
2994
3068
check_ldflags -Wl,--warn-common
2995
 
check_ldflags -Wl,-rpath-link,libpostproc -Wl,-rpath-link,libswscale -Wl,-rpath-link,libavfilter -Wl,-rpath-link,libavdevice -Wl,-rpath-link,libavformat -Wl,-rpath-link,libavcodec -Wl,-rpath-link,libavutil
 
3069
check_ldflags -Wl,-rpath-link=libpostproc:libswscale:libavfilter:libavdevice:libavformat:libavcodec:libavutil
2996
3070
test_ldflags -Wl,-Bsymbolic && append SHFLAGS -Wl,-Bsymbolic
2997
3071
 
2998
3072
echo "X{};" > $TMPV
3008
3082
EOF
3009
3083
fi
3010
3084
 
3011
 
if enabled small; then
 
3085
if [ -n "$optflags" ]; then
 
3086
    add_cflags $optflags
 
3087
elif enabled small; then
3012
3088
    add_cflags $size_cflags
3013
3089
elif enabled optimizations; then
3014
3090
    add_cflags $speed_cflags
3052
3128
    check_cflags -fno-tree-vectorize
3053
3129
    check_cflags -Werror=implicit-function-declaration
3054
3130
    check_cflags -Werror=missing-prototypes
 
3131
    check_cflags -Werror=declaration-after-statement
3055
3132
elif enabled llvm_gcc; then
3056
3133
    check_cflags -mllvm -stack-alignment=16
3057
3134
elif enabled clang; then
3076
3153
check_deps $CONFIG_LIST       \
3077
3154
           $CONFIG_EXTRA      \
3078
3155
           $HAVE_LIST         \
3079
 
           $DECODER_LIST      \
3080
 
           $ENCODER_LIST      \
3081
 
           $HWACCEL_LIST      \
3082
 
           $PARSER_LIST       \
3083
 
           $BSF_LIST          \
3084
 
           $DEMUXER_LIST      \
3085
 
           $MUXER_LIST        \
3086
 
           $FILTER_LIST       \
3087
 
           $INDEV_LIST        \
3088
 
           $OUTDEV_LIST       \
3089
 
           $PROTOCOL_LIST     \
3090
 
           $ACODEC_TESTS      \
3091
 
           $VCODEC_TESTS      \
3092
 
           $LAVF_TESTS        \
3093
 
           $LAVFI_TESTS       \
3094
 
           $SEEK_TESTS        \
 
3156
           $ALL_COMPONENTS    \
 
3157
           $ALL_TESTS         \
3095
3158
 
3096
3159
enabled asm || { arch=c; disable $ARCH_LIST $ARCH_EXT_LIST; }
3097
3160
 
3123
3186
    echo "CMOV is fast              ${fast_cmov-no}"
3124
3187
    echo "EBX available             ${ebx_available-no}"
3125
3188
    echo "EBP available             ${ebp_available-no}"
3126
 
    echo "10 operands supported     ${ten_operands-no}"
3127
3189
fi
3128
3190
if enabled arm; then
3129
3191
    echo "ARMv5TE enabled           ${armv5te-no}"
3153
3215
echo "new filter support        ${avfilter-no}"
3154
3216
echo "network support           ${network-no}"
3155
3217
echo "threading support         ${thread_type-no}"
 
3218
echo "safe bitstream reader     ${safe_bitstream_reader-no}"
3156
3219
echo "SDL support               ${sdl-no}"
3157
3220
echo "Sun medialib support      ${mlib-no}"
 
3221
echo "libdxva2 enabled          ${dxva2-no}"
 
3222
echo "libva enabled             ${vaapi-no}"
 
3223
echo "libvdpau enabled          ${vdpau-no}"
3158
3224
echo "AVISynth enabled          ${avisynth-no}"
3159
3225
echo "frei0r enabled            ${frei0r-no}"
 
3226
echo "gnutls enabled            ${gnutls-no}"
 
3227
echo "libcdio support           ${libcdio-no}"
3160
3228
echo "libdc1394 support         ${libdc1394-no}"
3161
3229
echo "libdirac enabled          ${libdirac-no}"
3162
3230
echo "libfaac enabled           ${libfaac-no}"
3167
3235
echo "libopencore-amrwb support ${libopencore_amrwb-no}"
3168
3236
echo "libopencv support         ${libopencv-no}"
3169
3237
echo "libopenjpeg enabled       ${libopenjpeg-no}"
 
3238
echo "libpulse enabled          ${libpulse-no}"
3170
3239
echo "librtmp enabled           ${librtmp-no}"
3171
3240
echo "libschroedinger enabled   ${libschroedinger-no}"
3172
3241
echo "libspeex enabled          ${libspeex-no}"
3173
3242
echo "libtheora enabled         ${libtheora-no}"
3174
 
echo "libva enabled             ${vaapi-no}"
3175
3243
echo "libvo-aacenc support      ${libvo_aacenc-no}"
3176
3244
echo "libvo-amrwbenc support    ${libvo_amrwbenc-no}"
3177
3245
echo "libvorbis enabled         ${libvorbis-no}"
3179
3247
echo "libx264 enabled           ${libx264-no}"
3180
3248
echo "libxavs enabled           ${libxavs-no}"
3181
3249
echo "libxvid enabled           ${libxvid-no}"
 
3250
echo "openssl enabled           ${openssl-no}"
3182
3251
echo "zlib enabled              ${zlib-no}"
3183
3252
echo "bzlib enabled             ${bzlib-no}"
3184
3253
echo
3205
3274
 
3206
3275
echo "Creating config.mak and config.h..."
3207
3276
 
3208
 
# build tree in object directory if source path is different from current one
3209
 
if enabled source_path_used; then
3210
 
    DIRS="
3211
 
        doc
3212
 
        libavcodec
3213
 
        libavcodec/$arch
3214
 
        libavcodec/mlib
3215
 
        libavdevice
3216
 
        libavfilter
3217
 
        libavfilter/$arch
3218
 
        libavformat
3219
 
        libavutil
3220
 
        libavutil/$arch
3221
 
        libpostproc
3222
 
        libswscale
3223
 
        libswscale/$arch
3224
 
        libswscale/mlib
3225
 
        tests
3226
 
        tools
3227
 
    "
3228
 
    FILES="
3229
 
        Makefile
3230
 
        common.mak
3231
 
        subdir.mak
3232
 
        doc/texi2pod.pl
3233
 
        libavcodec/Makefile
3234
 
        libavcodec/${arch}/Makefile
3235
 
        libavdevice/Makefile
3236
 
        libavfilter/Makefile
3237
 
        libavfilter/${arch}/Makefile
3238
 
        libavformat/Makefile
3239
 
        libavutil/Makefile
3240
 
        libpostproc/Makefile
3241
 
        libswscale/Makefile
3242
 
    "
3243
 
    map 'mkdir -p $v' $DIRS;
3244
 
    map 'test -f "$source_path/$v" && $ln_s "$source_path/$v" $v' $FILES
3245
 
fi
 
3277
test -e Makefile || $ln_s "$source_path/Makefile" .
3246
3278
 
3247
3279
config_files="$TMPH config.mak"
3248
3280
 
3249
3281
cat > config.mak <<EOF
3250
3282
# Automatically generated by configure - do not modify!
3251
 
ifndef LIBAV_CONFIG_MAK
3252
 
LIBAV_CONFIG_MAK=1
3253
3283
LIBAV_CONFIGURATION=$LIBAV_CONFIGURATION
3254
3284
prefix=$prefix
3255
3285
LIBDIR=\$(DESTDIR)$libdir
3258
3288
BINDIR=\$(DESTDIR)$bindir
3259
3289
DATADIR=\$(DESTDIR)$datadir
3260
3290
MANDIR=\$(DESTDIR)$mandir
3261
 
SRC_PATH="$source_path"
3262
 
SRC_PATH_BARE=$source_path
 
3291
SRC_PATH=$source_path
3263
3292
CC_IDENT=$cc_ident
3264
3293
ARCH=$arch
3265
3294
CC=$cc
3274
3303
CPPFLAGS=$CPPFLAGS
3275
3304
CFLAGS=$CFLAGS
3276
3305
ASFLAGS=$ASFLAGS
 
3306
AS_O=$CC_O
3277
3307
CC_O=$CC_O
3278
3308
DLLTOOL=$dlltool
3279
3309
LDFLAGS=$LDFLAGS
3280
 
FFSERVERLDFLAGS=$FFSERVERLDFLAGS
 
3310
AVSERVERLDFLAGS=$AVSERVERLDFLAGS
3281
3311
SHFLAGS=$SHFLAGS
3282
3312
YASMFLAGS=$YASMFLAGS
3283
3313
BUILDSUF=$build_suffix
3312
3342
SLIBNAME_WITH_MAJOR=${SLIBNAME_WITH_MAJOR}
3313
3343
SLIB_CREATE_DEF_CMD=${SLIB_CREATE_DEF_CMD}
3314
3344
SLIB_EXTRA_CMD=${SLIB_EXTRA_CMD}
3315
 
SLIB_INSTALL_EXTRA_CMD=${SLIB_INSTALL_EXTRA_CMD}
3316
 
SLIB_UNINSTALL_EXTRA_CMD=${SLIB_UNINSTALL_EXTRA_CMD}
 
3345
SLIB_INSTALL_NAME=${SLIB_INSTALL_NAME}
 
3346
SLIB_INSTALL_LINKS=${SLIB_INSTALL_LINKS}
 
3347
SLIB_INSTALL_EXTRA_LIB=${SLIB_INSTALL_EXTRA_LIB}
 
3348
SLIB_INSTALL_EXTRA_SHLIB=${SLIB_INSTALL_EXTRA_SHLIB}
3317
3349
SAMPLES:=${samples:-\$(FATE_SAMPLES)}
3318
3350
EOF
3319
3351
 
3327
3359
    eval echo "${lcname}_VERSION_MAJOR=\$${name}_VERSION_MAJOR" >> config.mak
3328
3360
}
3329
3361
 
3330
 
get_version LIBSWSCALE  libswscale/swscale.h
3331
 
get_version LIBPOSTPROC libpostproc/postprocess.h
3332
3362
get_version LIBAVCODEC  libavcodec/version.h
3333
3363
get_version LIBAVDEVICE libavdevice/avdevice.h
 
3364
get_version LIBAVFILTER libavfilter/avfilter.h
3334
3365
get_version LIBAVFORMAT libavformat/version.h
3335
3366
get_version LIBAVUTIL   libavutil/avutil.h
3336
 
get_version LIBAVFILTER libavfilter/avfilter.h
 
3367
get_version LIBPOSTPROC libpostproc/postprocess.h
 
3368
get_version LIBSWSCALE  libswscale/swscale.h
3337
3369
 
3338
3370
cat > $TMPH <<EOF
3339
3371
/* Automatically generated by configure - do not modify! */
3341
3373
#define LIBAV_CONFIG_H
3342
3374
#define LIBAV_CONFIGURATION "$(c_escape $LIBAV_CONFIGURATION)"
3343
3375
#define LIBAV_LICENSE "$(c_escape $license)"
3344
 
#define FFMPEG_DATADIR "$(eval c_escape $datadir)"
 
3376
#define AVCONV_DATADIR "$(eval c_escape $datadir)"
3345
3377
#define CC_TYPE "$cc_type"
3346
3378
#define CC_VERSION $cc_version
3347
3379
#define restrict $_restrict
3371
3403
print_config HAVE_   "$config_files" $HAVE_LIST
3372
3404
print_config CONFIG_ "$config_files" $CONFIG_LIST       \
3373
3405
                                     $CONFIG_EXTRA      \
3374
 
                                     $DECODER_LIST      \
3375
 
                                     $ENCODER_LIST      \
3376
 
                                     $HWACCEL_LIST      \
3377
 
                                     $PARSER_LIST       \
3378
 
                                     $BSF_LIST          \
3379
 
                                     $DEMUXER_LIST      \
3380
 
                                     $MUXER_LIST        \
3381
 
                                     $FILTER_LIST       \
3382
 
                                     $PROTOCOL_LIST     \
3383
 
                                     $INDEV_LIST        \
3384
 
                                     $OUTDEV_LIST       \
 
3406
                                     $ALL_COMPONENTS    \
3385
3407
 
3386
3408
cat >>config.mak <<EOF
3387
3409
ACODEC_TESTS=$(print_enabled -n _test $ACODEC_TESTS)
3392
3414
EOF
3393
3415
 
3394
3416
echo "#endif /* LIBAV_CONFIG_H */" >> $TMPH
3395
 
echo "endif # LIBAV_CONFIG_MAK" >> config.mak
3396
3417
 
3397
3418
# Do not overwrite an unchanged config.h to avoid superfluous rebuilds.
3398
3419
cp_if_changed $TMPH config.h
3424
3445
libs=$4
3425
3446
requires=$5
3426
3447
enabled ${name#lib} || return 0
 
3448
mkdir -p $name
3427
3449
cat <<EOF > $name/$name.pc
3428
3450
prefix=$prefix
3429
3451
exec_prefix=\${prefix}
3461
3483
pkgconfig_generate libavformat "Libav container format library" "$LIBAVFORMAT_VERSION" "$extralibs" "libavcodec = $LIBAVCODEC_VERSION"
3462
3484
pkgconfig_generate libavdevice "Libav device handling library" "$LIBAVDEVICE_VERSION" "$extralibs" "libavformat = $LIBAVFORMAT_VERSION"
3463
3485
pkgconfig_generate libavfilter "Libav video filtering library" "$LIBAVFILTER_VERSION" "$extralibs"
3464
 
pkgconfig_generate libpostproc "Libav post processing library" "$LIBPOSTPROC_VERSION" "" "libavutil = $LIBAVUTIL_VERSION"
 
3486
pkgconfig_generate libpostproc "Libav postprocessing library" "$LIBPOSTPROC_VERSION" "" "libavutil = $LIBAVUTIL_VERSION"
3465
3487
pkgconfig_generate libswscale "Libav image rescaling library" "$LIBSWSCALE_VERSION" "$LIBM" "libavutil = $LIBAVUTIL_VERSION"