diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /media-video/vlc |
reinit the tree, so we can have metadata
Diffstat (limited to 'media-video/vlc')
19 files changed, 2783 insertions, 0 deletions
diff --git a/media-video/vlc/Manifest b/media-video/vlc/Manifest new file mode 100644 index 000000000000..87d4991267b0 --- /dev/null +++ b/media-video/vlc/Manifest @@ -0,0 +1,22 @@ +AUX qt4-select.patch 2171 SHA256 30c76f06553d0a341224009c3130e54624a266cd77a034340e39d2b922c60d69 SHA512 0c3fab4457f1b8c9f1c2c9b690c1a137e1544a09a710e24ba9c8e228f0490ec27030846974610b8976bfca77e03054c5254719836cabc695a527f095659a651d WHIRLPOOL a4d8a2689a0e034f26f0e2d52275004f21a20f0a553050ce7483b1ab5d42faa8f465ff4dfed08a5defc25917d8f225922d14eaea5adb53d3556b6e41c5704a37 +AUX vlc-2.1.0-TomWij-bisected-PA-broken-underflow.patch 700 SHA256 91752f1ed1fbe8a2fcc78336a0725e1450946bab8085a4efce85a076dff40b87 SHA512 c3aa82ba9252f87d8f87c0bbfed7e0cdbd93c4f454e0ca6a9d73346e2efa294864af7eea1ea76b504354fb1baf5378cf626b35dcbfba3d888dbf0168ddfbed13 WHIRLPOOL 87c5017c8cdc1ad8cb313b6342f89af7ca7e90b20f151dd226ad8863407dae4cefb5934040154020778d3eb5dc78c5be43ae1e8e33fd0e823628c69c8cac7e61 +AUX vlc-2.1.0-fix-libtremor-libs.patch 453 SHA256 5b2d4272b0258b30d1e34717ad83ebe2bcea78a5247798a74c0b86ace6d39463 SHA512 6c25995a518aeb1d501fa217d897962e1e81f66a4f28b6bb164dde3afe7f91772bb608f946d802857fa9a272cab1f88d3990d582be89ab8e37b1a8b6681798ae WHIRLPOOL 39d9d1670e244169087ecc81654b1d6407c9e5f0f0da1bb1b15d7c89a7dab232b9a174c2a5e9ed2586a57a370f3cd9d2c9434381387a1fbc70b7f7bd8de2ef85 +AUX vlc-2.2.2-qt5widgets.patch 603 SHA256 b23c3bf441ac9bef25ca053a8bccec2652c9a251889d38624877ffc5562218ca SHA512 b5d8946406e84bce240376015ed994d6265d07fe9b777fd05c0f722142e99502bd129ec4acfe2cafa7a6dd98c9612913fa8644109489fa48dab6dc5522601050 WHIRLPOOL a00159f261e617f8e0e5c6b51b94428ba1080eb6107f13ce5b9506ae460437f9246ab79795a3443289cba2db36c7a6c2d5f585f6f888ca4881625856ce0ffaf3 +AUX vlc-2.2.4-alsa-large-buffers.patch 1805 SHA256 1c31b7778b6f7249bc80de4e17ed1bad9ea8586f17cb7c990928842d702cdd01 SHA512 7376c79b935d56b51a3e039728764885b531435da92dad7d9f499bb47aff5363adb06405b86809cb5371ea45c34a28cf020a10d1edde4a16e59161c8bae2a7fd WHIRLPOOL 17d3969640a7ced8030497d89fd26c97923ace6918180a30a517915f0a7a7b436e06f795b90feae5b87be1b32b3bebcc28013f104b66b5eadcbfbe2bb26e4776 +AUX vlc-2.2.4-cxx0x.patch 598 SHA256 d7f4bd01278c1dfda8c72b41cdf54b7938b7e00ba5b537e6e3c367b4f0f3d94b SHA512 543357fdf86b56a236f2ff3f855e6ca3a3af2f5f6625539e923705671adcf29f8e3c967adf7f11bcec0e0d6646fcdb0c159bf70758bc2542b85f72eab8c280e4 WHIRLPOOL 6007ee11d3e1b9e68d50f553eef1b609df905f9356ee4f9140b14a0e4d6aefaae2b9b66d6e11f9b400250a0cc209f1d4a59c4f60f490d6993fa71d0ef9d1579b +AUX vlc-2.2.4-decoder-lock-scope.patch 1337 SHA256 612460a2d8eb1f32412d1857fb62aa31d5dac0f0dca91700f1cbd7cf81a5cca3 SHA512 a81704adf25aa54cc8fa7c2f97117ef6c300af15c5b78b74b0df5ee4eba1d8e0f9d9b3b99e2793f7362d1727de24990fb555222bd5f73cce31df2c49371063a1 WHIRLPOOL 1161c4640213d96b8f4f295d44aafd3b0db111d614ccf50da2923204cdb05b21aab841082ef711386e47daecfcfa17f911d7035dae0e21d55af80b04e363f766 +AUX vlc-2.2.4-ffmpeg3.patch 6377 SHA256 61c21d875d3ea5e0475194cfb199e2a95f20a5357bb2a0001d86dd1f4a5d3652 SHA512 efede86f7d4c8a475f14c88405d4f9810784b93b8dbee8a21ca2f59b4a62ba008996fbd72ad77300b76a6faa328720a7b99afdd753480f2a17dc25204e52d2ee WHIRLPOOL 49286dda70c1e510c8727f77bfec43786d0ae2b477f528032bf45e1fb9f34f9943e4a213c26f3c06e370c1e4856c16acb5d933cc91590d145a985fde81acbd09 +AUX vlc-2.2.4-libav-11.7.patch 291 SHA256 21fa395ee76954181de78113c786015b65c7f3495cc0a3a58c4188ff4cf83b50 SHA512 f216833dc1ad5ddbf6a19b497238e9c850582f16eae452862a4c7c9acd110a0033879b3e3555177ac0ef30663cdd3f72d1a1020999c44e1f577ef665dd658315 WHIRLPOOL 66954f1ed951694bfaf92543cd4fec2bc6dd57f282b09a28434a32f8505f242b9c0cf2295fc841ac75b54afb4b1769aee09ab82d202c446280df8ea5d01eaf2c +AUX vlc-2.2.4-qt57.patch 8624 SHA256 21f838efafed172bfdeab8ac6249cb5a965a7c74600705a987b7cbdfc5309e3e SHA512 4f7bf09fe6721c7bbaf26761c7f868dfe66b7b63e50892ee9b107a036c743331f14be9820cf0415ac5463b223699c86efe104092d13cda8d436073d0d76dad00 WHIRLPOOL a9a34ce734190b7f791efe0edf66f1c926ab7782f74a7a1679910edd6cd5e25e752deee3d2dfe239bdd312b8fa9974e0c455da6e7e064cfa9c6a9105b733e889 +AUX vlc-2.2.4-relax_ffmpeg.patch 1686 SHA256 3b76abff4553f581457252b6b98d3c3a537c91cd7b981f2f5a6772eb6597fd18 SHA512 a15862d6ac60575c0c338faff6052e3c28c4bd75f86f37ff8fbe36a64bc1a82689c56b2dc19f05109fc0913b85aab7ba28a94bfdd5fdd0e3c87cb7e6e58d1caa WHIRLPOOL aefdcf024869e7b074f3bc64ca12d187967edcbe31f03bb72a9d9dbb82be8453ec4866fae655a77ce4f500f8cae80e583de6e33b012c1f5ff1cc549a298a0596 +AUX vlc-2.2.6-decoder-lock-scope.patch 973 SHA256 7c6294f228b4bd67f2b3a400a92e4087d19ef612764e4da8ef13afee1d4c5250 SHA512 b6d360f4eb6923332a67605118c5a47ed2e54bedcc68625eb5f78313e971da66ab19998f3037dcc0ce588287da1510c93cf68247c47ae25d0b1305af931794e3 WHIRLPOOL a62009e9e088d8a0089f0fd4c8f5057ae9ee34c2011b24c01e4ca39752b56a146f514e50d2118ec70cfd4001b9b9cfb63eac1a711407d82f8b7c939d5f1122d5 +AUX vlc-9999-libva-1.2.1-compat.patch 291 SHA256 54eb34b32afe6876fa40abac2cb97097030f1d372bb81b63ef88231a17e5f237 SHA512 47b9d3f7a5e7c90045acac3b3253feb927da26646b6a457655669c1ab18f6a0e027160285695dc06642e6117ed1fcd87db90ae1f409e8fee737a2a41e80e1968 WHIRLPOOL df5cfdb4ba36ccd92e79de7b913b14c5416aca0834025dc51f8178db6c88f5eecb332ae7096800607d6f7526a56c7fb94e2f593bc0c0e19f643428bcd3eb5868 +DIST vlc-2.2.6.tar.xz 22198720 SHA256 c403d3accd9a400eb2181c958f3e7bc5524fe5738425f4253d42883b425a42a8 SHA512 9aff5922eb8b3c6a24e6153c367b0170dbc67602ae3e9304f52d2da00c9081d66cc98abd722b7c95b6c7d2e6cc7c86f21f9cba42c7d4bf29ca97d0f2d3553f8d WHIRLPOOL a2747219e4b12b4274468348c47c543f3266bb1ebc222d02f34d6679dfb8e56a6f2eebda4e1749de0eb91a84e3358700ea2e5ed1a6871ddfc9f19ef1e191cbc8 +EBUILD vlc-2.2.6-r2.ebuild 15134 SHA256 804fc96b79b99a02f61b208abedb08c170df0b3735ea28dce82bc8d101d30c7b SHA512 dd67d770e647236292a59212841addcb45ba9420b355c8f28c25493e9588f8513c7f05abf5fd05510d89ea544c227144c6322d3d97c8722aeba4fde5bcb2226e WHIRLPOOL ac3069096540ee23629a60d235f96d062561da4c4dd143285f06b164fe5744c8ee6cb761c8720aa5b9be94e4764ced13f8d5dbd3d075ed6814335f852a2b6d31 +EBUILD vlc-2.2.6.ebuild 15609 SHA256 e55f00b58026b01c6ef9c5e25d09c0ecc30cb43f03c50729eb34886e52eb0b78 SHA512 d096a788aadebe0494bf355e50da62405e0eeaaefd1870a98ffc30075ac2048b7237e1243f9bf092481122f11242bba838a41f6f5443ec51e973e40c8968e3e4 WHIRLPOOL 8fcc69f843ccd2d9708fc614ad0092ee1cf9429a67e37797ea41e91bbe9d2f5f96972bedbcced5954657949187b5970729bcbb618a4472b65ee531f92ffc9761 +EBUILD vlc-2.2.9999.ebuild 15130 SHA256 256dfc3a41f114002f8922c398389e50fbdf00db057750f24b635b9e730232d8 SHA512 92f703830575bd46c916ee3485cd0a51a13e331785f62033d5dc7229a78d229b7b9b2f9c6dbdfffc87b5c6902c6c1a079edf8f59a48869aaed01c6a621c010a1 WHIRLPOOL 1ac211c4901040dee387cb1cd33997aaa295e3439e99bcbcc76b78343f6e58c01109a54e322d888d62bceb620b9b938bb67d47eca8264d710782fa5838b92916 +EBUILD vlc-9999.ebuild 14422 SHA256 7b339733bdaf7f1af541d4b853c96d5abeecef74761768f1f3bb551add72b42a SHA512 ad69e3ea17c28faf9b001e8e9f32ff83d14f69d1ce8f9fe5f43f05b3eda8a8a4a7e79fe4ca6ed3157481c0f33df5a342317b0d6460d0f1ad67c35eb7eb617ea8 WHIRLPOOL 73b0046dd1b8b54d0c87bf624850223fe751b637d5a72a6d4a325ab8883f5d0c1a366046971de6909454b6c802bc4f78449e45c243bc2d6416f57e7deb6712c2 +MISC ChangeLog 13321 SHA256 f45f6f47a72e501ec9944e5f1e28abbf5de8d804eb4cf45c8c07703a3cc732df SHA512 e08dc2d7e9fa1804b123a670b61dde48284c4ea203c646515c0afaf5b153d80671c0908c8d96ec99ae1a3cdd909293b815807d7e3b587b4538667693da2f6aa8 WHIRLPOOL a2a04ba8047ede435df04a2e3a55c6c3041a9c362a4f6c65201be9bd97862f25e790acc2de11f6636a89c109c7d37f8ac2f1136de49fca4328e6d4b455a98957 +MISC ChangeLog-2011 113818 SHA256 34efd4743fdaa4b24df7042e0cff14ab00cc5fae0838bf489b2eea620654fcc2 SHA512 9b1060fc57d0a8912a38c269b7ec140287c883798f6f3528f0f2d43b5772817f31e0addf4f88f139b82cda4e094d2f9a30e3b9d1933022b81b974436ed158d9d WHIRLPOOL bfe449ace05bac74b195d82eb2b3648b2240f92dabf6446f6ba93ca51b7ecd999ab5b9247dfd1f1a7cdab8d309684ffcd1c829773a471d862c19814a18db7ffe +MISC ChangeLog-2015 39367 SHA256 d9a2012ec353502b05977c190ed321f2c912e42f8fb46fc74841ab804a8f3afd SHA512 4c6d7f2eac460ffb22dc4c51bb28406ea3e2b24ac25601149441288fb2ab7b7bcca3c6ef0514b0da23c236625831352e0ab39242fca87c07eee242b175a27f90 WHIRLPOOL 40f38d620ec15e07e4da6ef5100c11c01c4b45f8184ea54530053dbce5e407a13ba6b623788a22c937550a39036b2f06f53554b751530b8cd1cf539978a44c57 +MISC metadata.xml 6325 SHA256 9fcd49f26f702a9fea65f92daff539e330ea244f2874a9aca725b1630e720fb2 SHA512 737cc412a5b4832df066631792744c3e8cecd217634af6cc8feed4c0ab89a3ba324312af73c6da545eeb7f861896c0237c0f47397cdfbcd6cf08de33293e1ea9 WHIRLPOOL b11b33c7f6bed2c1104bee34fc83013d44d6380fefdc4786b09b0855bd0233a11dae4ccf5cbf7d6438a3000af2f9bb79aa6d08f7c9c87050c9ae12d035fba9cf diff --git a/media-video/vlc/files/qt4-select.patch b/media-video/vlc/files/qt4-select.patch new file mode 100644 index 000000000000..fb1526a30a7a --- /dev/null +++ b/media-video/vlc/files/qt4-select.patch @@ -0,0 +1,51 @@ +https://gist.github.com/karolherbst/fb9e3d8f6ba05f1f5d54 +For use until upstream ever accepts this patch or fixes it themsleves +--- a/configure.ac ++++ b/configure.ac +@@ -3709,7 +3709,8 @@ + ]) + ]) + AS_IF([test "${enable_qt}" != "no"], [ +- PKG_CHECK_MODULES([QT], [Qt5Core >= 5.1.0 Qt5Widgets Qt5Gui], [ ++ AS_IF([test "${enable_qt}" != "4"], [ ++ PKG_CHECK_MODULES([QT], [Qt5Core >= 5.1.0 Qt5Widgets Qt5Gui], [ + PKG_CHECK_MODULES([QTX11], [Qt5X11Extras], [ + VLC_ADD_LIBS([qt4],[${QTX11_LIBS}]) + VLC_ADD_CXXFLAGS([qt4],[${QTX11_CFLAGS} -DQT5_HAS_X11]) +@@ -3721,20 +3722,23 @@ + AC_PATH_PROGS(MOC, [moc-qt5 moc], moc, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"]) + AC_PATH_PROGS(RCC, [rcc-qt5 rcc], rcc, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"]) + AC_PATH_PROGS(UIC, [uic-qt5 uic], uic, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"]) ++ enable_qt="5" +- ], [ +- PKG_CHECK_MODULES([QT], [QtCore QtGui >= 4.6.0],, [ +- AS_IF([test -n "${enable_qt}"],[ +- AC_MSG_ERROR([${QT_PKG_ERRORS}.]) +- ],[ +- AC_MSG_WARN([${QT_PKG_ERRORS}.]) +- ]) +- enable_qt="no" ++ ]) ++ ]) ++ AS_IF([test "${enable_qt}" != "5"], [ ++ PKG_CHECK_MODULES([QT], [QtCore QtGui >= 4.6.0],, [ ++ AS_IF([test -n "${enable_qt}"],[ ++ AC_MSG_ERROR([${QT_PKG_ERRORS}.]) ++ ],[ ++ AC_MSG_WARN([${QT_PKG_ERRORS}.]) + ]) +- QT_PATH="$(eval $PKG_CONFIG --variable=exec_prefix QtCore)" +- AC_PATH_PROGS(MOC, [moc-qt4 moc], moc, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"]) +- AC_PATH_PROG(RCC, rcc, rcc, [${QT_PATH}/bin ${CONTRIB_DIR}/bin]) +- AC_PATH_PROGS(UIC, [uic-qt4 uic], uic, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"]) ++ enable_qt="no" + ]) ++ QT_PATH="$(eval $PKG_CONFIG --variable=exec_prefix QtCore)" ++ AC_PATH_PROGS(MOC, [moc-qt4 moc], moc, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"]) ++ AC_PATH_PROG(RCC, rcc, rcc, [${QT_PATH}/bin ${CONTRIB_DIR}/bin]) ++ AC_PATH_PROGS(UIC, [uic-qt4 uic], uic, ["${QT_PATH}/bin" "${CONTRIB_DIR}/bin"]) ++ ]) + ]) + AS_IF([test "${enable_qt}" != "no"], [ + VLC_ADD_PLUGIN([qt4]) + diff --git a/media-video/vlc/files/vlc-2.1.0-TomWij-bisected-PA-broken-underflow.patch b/media-video/vlc/files/vlc-2.1.0-TomWij-bisected-PA-broken-underflow.patch new file mode 100644 index 000000000000..3163410353a2 --- /dev/null +++ b/media-video/vlc/files/vlc-2.1.0-TomWij-bisected-PA-broken-underflow.patch @@ -0,0 +1,23 @@ +index 2debbcd..72e7fcf 100644 +--- a/modules/audio_output/pulse.c ++++ b/modules/audio_output/pulse.c +@@ -472,8 +472,17 @@ static void stream_underflow_cb(pa_stream *s, void *userdata) + { ++ uint32_t rate = pa_stream_get_sample_spec(s)->rate; + audio_output_t *aout = userdata; + +- msg_Dbg(aout, "underflow"); +- (void) s; ++ msg_Warn(aout, "underflow"); ++ stream_stop(s, aout); ++ ++ aout_sys_t *sys = aout->sys; ++ sys->first_pts = VLC_TS_INVALID; ++ ++ pa_operation *op = pa_stream_update_sample_rate(s, rate, NULL, NULL); ++ if (unlikely(op == NULL)) ++ return; ++ pa_operation_unref(op); + } + + static int stream_wait(pa_stream *stream, pa_threaded_mainloop *mainloop) diff --git a/media-video/vlc/files/vlc-2.1.0-fix-libtremor-libs.patch b/media-video/vlc/files/vlc-2.1.0-fix-libtremor-libs.patch new file mode 100644 index 000000000000..8a58969d0d8e --- /dev/null +++ b/media-video/vlc/files/vlc-2.1.0-fix-libtremor-libs.patch @@ -0,0 +1,11 @@ +--- a/modules/codec/Makefile.am ++++ b/modules/codec/Makefile.am +@@ -215,7 +215,7 @@ + libtremor_plugin_la_SOURCES = codec/vorbis.c + libtremor_plugin_la_CPPFLAGS = $(AM_CPPFLAGS) -DMODULE_NAME_IS_tremor + libtremor_plugin_la_LDFLAGS = $(AM_LDFLAGS) -rpath '$(codecdir)' +-libtremor_plugin_la_LIBADD = -lvorbisdec -logg ++libtremor_plugin_la_LIBADD = $(VORBIS_LIBS) $(OGG_LIBS) + EXTRA_LTLIBRARIES += libtremor_plugin.la + codec_LTLIBRARIES += $(LTLIBtremor) + diff --git a/media-video/vlc/files/vlc-2.2.2-qt5widgets.patch b/media-video/vlc/files/vlc-2.2.2-qt5widgets.patch new file mode 100644 index 000000000000..a024d0032b6d --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.2-qt5widgets.patch @@ -0,0 +1,13 @@ +--- vlc-2.2.2/configure.ac ++++ vlc-2.2.2/configure.ac +@@ -3754,10 +3754,6 @@ + AC_MSG_WARN([Not building Qt Interface with X11 helpers.]) + ]) + +- PKG_CHECK_EXISTS([Qt5Core >= 5.5.0 Qt5Core < 5.6.0], [ +- AC_MSG_ERROR(["You cannot build VLC with Qt-5.5.0. You need to backport I78ef29975181ee22429c9bd4b11d96d9e68b7a9c"]) +- ]) +- + QT_PATH="$(eval $PKG_CONFIG --variable=exec_prefix Qt5Core)" + QT_HOST_PATH="$(eval $PKG_CONFIG --variable=host_bins Qt5Core)" + AC_PATH_PROGS(MOC, [moc-qt5 moc], moc, ["${QT_HOST_PATH}" "${QT_PATH}/bin" "${CONTRIB_DIR}/bin"]) diff --git a/media-video/vlc/files/vlc-2.2.4-alsa-large-buffers.patch b/media-video/vlc/files/vlc-2.2.4-alsa-large-buffers.patch new file mode 100644 index 000000000000..b5a9ff7267fb --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.4-alsa-large-buffers.patch @@ -0,0 +1,47 @@ +X-Git-Url: https://git.videolan.org/?p=vlc.git;a=blobdiff_plain;f=modules%2Faudio_output%2Falsa.c;h=4e9fd53592d048baa8b57f30df15ab5806139d07;hp=2d1f99e9cb743bca12c6bdf32cc84a92d07fda8b;hb=47f74a83c161173b0d15e95dab8ceb7c97de51b4;hpb=6ae2905ef7fbc7de3a3a4a1bdf8ad6df46ce570a + +diff --git a/modules/audio_output/alsa.c b/modules/audio_output/alsa.c +index 2d1f99e..4e9fd53 100644 +--- a/modules/audio_output/alsa.c ++++ b/modules/audio_output/alsa.c +@@ -495,6 +495,15 @@ static int Start (audio_output_t *aout, audio_sample_format_t *restrict fmt) + } + sys->rate = fmt->i_rate; + ++#if 1 /* work-around for period-long latency outputs (e.g. PulseAudio): */ ++ param = AOUT_MIN_PREPARE_TIME; ++ val = snd_pcm_hw_params_set_period_time_near (pcm, hw, ¶m, NULL); ++ if (val) ++ { ++ msg_Err (aout, "cannot set period: %s", snd_strerror (val)); ++ goto error; ++ } ++#endif + /* Set buffer size */ + param = AOUT_MAX_ADVANCE_TIME; + val = snd_pcm_hw_params_set_buffer_time_near (pcm, hw, ¶m, NULL); +@@ -503,14 +512,22 @@ static int Start (audio_output_t *aout, audio_sample_format_t *restrict fmt) + msg_Err (aout, "cannot set buffer duration: %s", snd_strerror (val)); + goto error; + } +- +- param = AOUT_MIN_PREPARE_TIME; ++#if 0 ++ val = snd_pcm_hw_params_get_buffer_time (hw, ¶m, NULL); ++ if (val) ++ { ++ msg_Warn (aout, "cannot get buffer time: %s", snd_strerror(val)); ++ param = AOUT_MIN_PREPARE_TIME; ++ } ++ else ++ param /= 2; + val = snd_pcm_hw_params_set_period_time_near (pcm, hw, ¶m, NULL); + if (val) + { + msg_Err (aout, "cannot set period: %s", snd_strerror (val)); + goto error; + } ++#endif + + /* Commit hardware parameters */ + val = snd_pcm_hw_params (pcm, hw); diff --git a/media-video/vlc/files/vlc-2.2.4-cxx0x.patch b/media-video/vlc/files/vlc-2.2.4-cxx0x.patch new file mode 100644 index 000000000000..cb3d63522de3 --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.4-cxx0x.patch @@ -0,0 +1,11 @@ +--- a/configure.ac 2016-09-21 07:10:58.885508665 +0200 ++++ b/configure.ac 2016-09-21 07:19:17.835725004 +0200 +@@ -3746,7 +3746,7 @@ + PKG_CHECK_MODULES([QT], [Qt5Core >= 5.1.0 Qt5Widgets Qt5Gui], [ + PKG_CHECK_MODULES([QTX11], [Qt5X11Extras], [ + VLC_ADD_LIBS([qt4],[${QTX11_LIBS}]) +- VLC_ADD_CXXFLAGS([qt4],[${QTX11_CFLAGS} -DQT5_HAS_X11]) ++ VLC_ADD_CXXFLAGS([qt4],[${QTX11_CFLAGS} -DQT5_HAS_X11 -std=c++0x]) + PKG_CHECK_MODULES([XI], [xi], [ + VLC_ADD_LIBS([qt4], [${XI_LIBS}]) + VLC_ADD_CXXFLAGS([qt4], [${XI_CFLAGS} -DHAVE_XI]) diff --git a/media-video/vlc/files/vlc-2.2.4-decoder-lock-scope.patch b/media-video/vlc/files/vlc-2.2.4-decoder-lock-scope.patch new file mode 100644 index 000000000000..51a2cdcb16da --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.4-decoder-lock-scope.patch @@ -0,0 +1,47 @@ +X-Git-Url: https://git.videolan.org/?p=vlc.git;a=blobdiff_plain;f=src%2Finput%2Fdecoder.c;h=fe3cd428c65c18bfbdadb55baf11521afdc2bfc7;hp=83aa5bf54e2c29ad93fae803117558e4fcd0f658;hb=6ae2905ef7fbc7de3a3a4a1bdf8ad6df46ce570a;hpb=5b2de76965ee8b1ab5e3257f8b6d71bbb4e9e3f9 + +--- a/src/input/decoder.c ++++ b/src/input/decoder.c +@@ -1162,7 +1162,10 @@ + b_paused = p_owner->b_paused; + + if (!p_audio) ++ { ++ vlc_mutex_unlock( &p_owner->lock ); + break; ++ } + + /* */ + int i_rate = INPUT_RATE_DEFAULT; +@@ -1180,6 +1183,9 @@ + + if( unlikely(p_owner->b_paused != b_paused) ) + continue; /* race with input thread? retry... */ ++ ++ vlc_mutex_unlock( &p_owner->lock ); ++ + if( p_aout == NULL ) + b_reject = true; + +@@ -1199,7 +1205,6 @@ + + break; + } +- vlc_mutex_unlock( &p_owner->lock ); + } + + static void DecoderDecodeAudio( decoder_t *p_dec, block_t *p_block ) +@@ -1961,11 +1966,10 @@ + + /* Parameters changed, restart the aout */ + vlc_mutex_lock( &p_owner->lock ); +- +- aout_DecDelete( p_owner->p_aout ); + p_owner->p_aout = NULL; +- + vlc_mutex_unlock( &p_owner->lock ); ++ aout_DecDelete( p_owner->p_aout ); ++ + input_resource_PutAout( p_owner->p_resource, p_aout ); + } + diff --git a/media-video/vlc/files/vlc-2.2.4-ffmpeg3.patch b/media-video/vlc/files/vlc-2.2.4-ffmpeg3.patch new file mode 100644 index 000000000000..3bc5954920d0 --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.4-ffmpeg3.patch @@ -0,0 +1,160 @@ +Index: vlc-2.2.4/configure.ac +=================================================================== +--- vlc-2.2.4.orig/configure.ac ++++ vlc-2.2.4/configure.ac +@@ -2323,8 +2323,8 @@ AC_ARG_ENABLE(avcodec, + [ --enable-avcodec libavcodec codec (default enabled)]) + AS_IF([test "${enable_avcodec}" != "no"], [ + PKG_CHECK_MODULES(AVCODEC,[libavcodec >= 53.34.0 libavutil >= 51.22.0], [ +- PKG_CHECK_EXISTS([libavutil < 55],, [ +- AC_MSG_ERROR([libavutil versions 55 and later are not supported.]) ++ PKG_CHECK_EXISTS([libavutil < 56],, [ ++ AC_MSG_ERROR([libavutil versions 56 and later are not supported.]) + ]) + VLC_SAVE_FLAGS + CPPFLAGS="${CPPFLAGS} ${AVCODEC_CFLAGS}" +Index: vlc-2.2.4/modules/codec/avcodec/audio.c +=================================================================== +--- vlc-2.2.4.orig/modules/codec/avcodec/audio.c ++++ vlc-2.2.4/modules/codec/avcodec/audio.c +@@ -39,8 +39,6 @@ + #include <libavcodec/avcodec.h> + #include <libavutil/mem.h> + +-#include <libavutil/audioconvert.h> +- + #include "avcodec.h" + + /***************************************************************************** +Index: vlc-2.2.4/modules/codec/avcodec/encoder.c +=================================================================== +--- vlc-2.2.4.orig/modules/codec/avcodec/encoder.c ++++ vlc-2.2.4/modules/codec/avcodec/encoder.c +@@ -41,7 +41,6 @@ + #include <vlc_cpu.h> + + #include <libavcodec/avcodec.h> +-#include <libavutil/audioconvert.h> + + #include "avcodec.h" + #include "avcommon.h" +@@ -311,7 +310,7 @@ int OpenEncoder( vlc_object_t *p_this ) + else if( !GetFfmpegCodec( p_enc->fmt_out.i_codec, &i_cat, &i_codec_id, + &psz_namecodec ) ) + { +- if( FindFfmpegChroma( p_enc->fmt_out.i_codec ) == PIX_FMT_NONE ) ++ if( FindFfmpegChroma( p_enc->fmt_out.i_codec ) == AV_PIX_FMT_NONE ) + return VLC_EGENERIC; /* handed chroma output */ + + i_cat = VIDEO_ES; +@@ -555,7 +554,7 @@ int OpenEncoder( vlc_object_t *p_this ) + + if( p_codec->pix_fmts ) + { +- const enum PixelFormat *p = p_codec->pix_fmts; ++ const enum AVPixelFormat *p = p_codec->pix_fmts; + for( ; *p != -1; p++ ) + { + if( *p == p_context->pix_fmt ) break; +@@ -1017,7 +1016,7 @@ errmsg: + } + } + +- p_sys->frame = avcodec_alloc_frame(); ++ p_sys->frame = av_frame_alloc(); + if( !p_sys->frame ) + { + goto error; +@@ -1088,7 +1087,7 @@ static block_t *EncodeVideo( encoder_t * + AVFrame *frame = NULL; + if( likely(p_pict) ) { + frame = p_sys->frame; +- avcodec_get_frame_defaults( frame ); ++ av_frame_unref( frame ); + for( i_plane = 0; i_plane < p_pict->i_planes; i_plane++ ) + { + p_sys->frame->data[i_plane] = p_pict->p[i_plane].p_pixels; +@@ -1329,7 +1328,7 @@ static block_t *handle_delay_buffer( enc + //How much we need to copy from new packet + const int leftover = leftover_samples * p_sys->p_context->channels * p_sys->i_sample_bytes; + +- avcodec_get_frame_defaults( p_sys->frame ); ++ av_frame_unref( p_sys->frame ); + p_sys->frame->format = p_sys->p_context->sample_fmt; + p_sys->frame->nb_samples = leftover_samples + p_sys->i_samples_delay; + +@@ -1451,7 +1450,7 @@ static block_t *EncodeAudio( encoder_t * + while( ( p_aout_buf->i_nb_samples >= p_sys->i_frame_size ) || + ( p_sys->b_variable && p_aout_buf->i_nb_samples ) ) + { +- avcodec_get_frame_defaults( p_sys->frame ); ++ av_frame_unref( p_sys->frame ); + if( p_sys->b_variable ) + p_sys->frame->nb_samples = p_aout_buf->i_nb_samples; + else +Index: vlc-2.2.4/modules/codec/avcodec/vaapi.c +=================================================================== +--- vlc-2.2.4.orig/modules/codec/avcodec/vaapi.c ++++ vlc-2.2.4/modules/codec/avcodec/vaapi.c +@@ -598,7 +598,7 @@ static int Create( vlc_va_t *p_va, AVCod + return err; + + /* Only VLD supported */ +- p_va->pix_fmt = PIX_FMT_VAAPI_VLD; ++ p_va->pix_fmt = AV_PIX_FMT_VAAPI_VLD; + p_va->setup = Setup; + p_va->get = Get; + p_va->release = Release; +Index: vlc-2.2.4/modules/codec/avcodec/video.c +=================================================================== +--- vlc-2.2.4.orig/modules/codec/avcodec/video.c ++++ vlc-2.2.4/modules/codec/avcodec/video.c +@@ -108,8 +108,8 @@ static int lavc_GetFrame(struct AVCodecC + static int ffmpeg_GetFrameBuf ( struct AVCodecContext *, AVFrame * ); + static void ffmpeg_ReleaseFrameBuf( struct AVCodecContext *, AVFrame * ); + #endif +-static enum PixelFormat ffmpeg_GetFormat( AVCodecContext *, +- const enum PixelFormat * ); ++static enum AVPixelFormat ffmpeg_GetFormat( AVCodecContext *, ++ const enum AVPixelFormat * ); + + static uint32_t ffmpeg_CodecTag( vlc_fourcc_t fcc ) + { +@@ -234,7 +234,7 @@ int InitVideoDec( decoder_t *p_dec, AVCo + p_sys->p_codec = p_codec; + p_sys->i_codec_id = i_codec_id; + p_sys->psz_namecodec = psz_namecodec; +- p_sys->p_ff_pic = avcodec_alloc_frame(); ++ p_sys->p_ff_pic = av_frame_alloc(); + p_sys->b_delayed_open = true; + p_sys->p_va = NULL; + vlc_sem_init( &p_sys->sem_mt, 0 ); +@@ -446,7 +446,7 @@ int InitVideoDec( decoder_t *p_dec, AVCo + if( ffmpeg_OpenCodec( p_dec ) < 0 ) + { + msg_Err( p_dec, "cannot open codec (%s)", p_sys->psz_namecodec ); +- avcodec_free_frame( &p_sys->p_ff_pic ); ++ av_frame_free( &p_sys->p_ff_pic ); + vlc_sem_destroy( &p_sys->sem_mt ); + free( p_sys ); + return VLC_EGENERIC; +@@ -826,7 +826,7 @@ void EndVideoDec( decoder_t *p_dec ) + wait_mt( p_sys ); + + if( p_sys->p_ff_pic ) +- avcodec_free_frame( &p_sys->p_ff_pic ); ++ av_frame_free( &p_sys->p_ff_pic ); + + if( p_sys->p_va ) + vlc_va_Delete( p_sys->p_va ); +@@ -1313,8 +1313,8 @@ static void ffmpeg_ReleaseFrameBuf( stru + } + #endif + +-static enum PixelFormat ffmpeg_GetFormat( AVCodecContext *p_context, +- const enum PixelFormat *pi_fmt ) ++static enum AVPixelFormat ffmpeg_GetFormat( AVCodecContext *p_context, ++ const enum AVPixelFormat *pi_fmt ) + { + decoder_t *p_dec = p_context->opaque; + decoder_sys_t *p_sys = p_dec->p_sys; diff --git a/media-video/vlc/files/vlc-2.2.4-libav-11.7.patch b/media-video/vlc/files/vlc-2.2.4-libav-11.7.patch new file mode 100644 index 000000000000..932223632d73 --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.4-libav-11.7.patch @@ -0,0 +1,10 @@ +--- a/modules/codec/avcodec/audio.c 2016-09-10 13:46:51.066453337 -0700 ++++ a/modules/codec/avcodec/audio.c 2016-09-10 13:42:26.061451090 -0700 +@@ -38,6 +38,7 @@ + + #include <libavcodec/avcodec.h> + #include <libavutil/mem.h> ++#include <libavutil/channel_layout.h> + + #include "avcodec.h" + diff --git a/media-video/vlc/files/vlc-2.2.4-qt57.patch b/media-video/vlc/files/vlc-2.2.4-qt57.patch new file mode 100644 index 000000000000..97472a64c398 --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.4-qt57.patch @@ -0,0 +1,284 @@ +As the 2.2 headers are still using vlc_atomics (picture) +we cannot have a way to avoid collisions with early +or late <atomic> inclusion when using GCC >= 4.7 + +Conditionals in vlc_atomic won't work. + +Happens in ProjectM and Qt5. +--- + modules/gui/qt4/actions_manager.cpp | 2 ++ + modules/gui/qt4/adapters/seekpoints.cpp | 4 +-- + modules/gui/qt4/adapters/seekpoints.hpp | 4 +-- + modules/gui/qt4/components/controller.cpp | 2 ++ + .../gui/qt4/components/playlist/playlist_model.hpp | 4 +-- + modules/gui/qt4/components/playlist/views.cpp | 6 ++++ + modules/gui/qt4/dialogs/messages.cpp | 2 ++ + modules/gui/qt4/dialogs/vlm.cpp | 4 --- + modules/gui/qt4/dialogs/vlm.hpp | 4 ++- + modules/gui/qt4/input_manager.cpp | 2 ++ + modules/gui/qt4/input_manager.hpp | 3 +- + modules/gui/qt4/menus.cpp | 2 ++ + modules/gui/qt4/qt4.hpp | 32 ++++++++++++++++++---- + modules/gui/qt4/util/pictureflow.cpp | 2 ++ + modules/visualization/projectm.cpp | 4 +++ + 15 files changed, 56 insertions(+), 21 deletions(-) + +diff --git a/modules/gui/qt4/actions_manager.cpp b/modules/gui/qt4/actions_manager.cpp +index eff40d9..b7ca967 100644 +--- a/modules/gui/qt4/actions_manager.cpp ++++ b/modules/gui/qt4/actions_manager.cpp +@@ -25,6 +25,8 @@ + # include "config.h" + #endif + ++#include "qt4.hpp" ++ + #include <vlc_vout.h> + #include <vlc_keys.h> + +diff --git a/modules/gui/qt4/adapters/seekpoints.cpp b/modules/gui/qt4/adapters/seekpoints.cpp +index fbf2957..a3564bb 100644 +--- a/modules/gui/qt4/adapters/seekpoints.cpp ++++ b/modules/gui/qt4/adapters/seekpoints.cpp +@@ -19,14 +19,12 @@ + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA. + *****************************************************************************/ + ++#include "seekpoints.hpp" + + #include "recents.hpp" + #include "dialogs_provider.hpp" + #include "menus.hpp" + +-#include "seekpoints.hpp" +- +-#include "qt4.hpp" + #include "input_manager.hpp" + + SeekPoints::SeekPoints( QObject *parent, intf_thread_t *p_intf_ ) : +diff --git a/modules/gui/qt4/adapters/seekpoints.hpp b/modules/gui/qt4/adapters/seekpoints.hpp +index 0083989..bbb9214 100644 +--- a/modules/gui/qt4/adapters/seekpoints.hpp ++++ b/modules/gui/qt4/adapters/seekpoints.hpp +@@ -22,9 +22,7 @@ + #ifndef SEEKPOINTS_HPP + #define SEEKPOINTS_HPP + +-#ifdef HAVE_CONFIG_H +-#include "config.h" +-#endif ++#include "qt4.hpp" + + #include <vlc_common.h> + #include <vlc_interface.h> +diff --git a/modules/gui/qt4/components/controller.cpp b/modules/gui/qt4/components/controller.cpp +index d93e0db..c43d929 100644 +--- a/modules/gui/qt4/components/controller.cpp ++++ b/modules/gui/qt4/components/controller.cpp +@@ -26,6 +26,8 @@ + # include "config.h" + #endif + ++#include "qt4.hpp" ++ + #include <vlc_vout.h> /* vout_thread_t for FSC */ + + /* Widgets */ +diff --git a/modules/gui/qt4/components/playlist/playlist_model.hpp b/modules/gui/qt4/components/playlist/playlist_model.hpp +index f9d1d0c..1f71ac9 100644 +--- a/modules/gui/qt4/components/playlist/playlist_model.hpp ++++ b/modules/gui/qt4/components/playlist/playlist_model.hpp +@@ -25,9 +25,7 @@ + #ifndef _PLAYLIST_MODEL_H_ + #define _PLAYLIST_MODEL_H_ + +-#ifdef HAVE_CONFIG_H +-# include "config.h" +-#endif ++#include "qt4.hpp" + + #include <vlc_input.h> + #include <vlc_playlist.h> +diff --git a/modules/gui/qt4/components/playlist/views.cpp b/modules/gui/qt4/components/playlist/views.cpp +index 59f6535..0066205 100644 +--- a/modules/gui/qt4/components/playlist/views.cpp ++++ b/modules/gui/qt4/components/playlist/views.cpp +@@ -21,6 +21,12 @@ + * 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA. + *****************************************************************************/ + ++#ifdef HAVE_CONFIG_H ++#include "config.h" ++#endif ++ ++#include "qt4.hpp" ++ + #include "components/playlist/views.hpp" + #include "components/playlist/vlc_model.hpp" /* VLCModel */ + #include "components/playlist/sorting.h" /* Columns List */ +diff --git a/modules/gui/qt4/dialogs/messages.cpp b/modules/gui/qt4/dialogs/messages.cpp +index 30793a2..9c79c99 100644 +--- a/modules/gui/qt4/dialogs/messages.cpp ++++ b/modules/gui/qt4/dialogs/messages.cpp +@@ -24,6 +24,8 @@ + # include "config.h" + #endif + ++#include "qt4.hpp" ++ + #include "dialogs/messages.hpp" + + #include <QPlainTextEdit> +diff --git a/modules/gui/qt4/dialogs/vlm.cpp b/modules/gui/qt4/dialogs/vlm.cpp +index 0da88cc..595f015 100644 +--- a/modules/gui/qt4/dialogs/vlm.cpp ++++ b/modules/gui/qt4/dialogs/vlm.cpp +@@ -23,10 +23,6 @@ + * Foundation, Inc., 51 Franklin street, Fifth Floor, Boston MA 02110-1301, USA. + *****************************************************************************/ + +-#ifdef HAVE_CONFIG_H +-# include "config.h" +-#endif +- + #include "dialogs/vlm.hpp" + + #ifdef ENABLE_VLM +diff --git a/modules/gui/qt4/dialogs/vlm.hpp b/modules/gui/qt4/dialogs/vlm.hpp +index a3c6e5d..dcf7110 100644 +--- a/modules/gui/qt4/dialogs/vlm.hpp ++++ b/modules/gui/qt4/dialogs/vlm.hpp +@@ -25,8 +25,10 @@ + #ifndef QVLC_VLM_DIALOG_H_ + #define QVLC_VLM_DIALOG_H_ 1 + ++#include "qt4.hpp" ++ + #ifdef HAVE_CONFIG_H +-# include "config.h" ++#include "config.h" + #endif + + #ifdef ENABLE_VLM +diff --git a/modules/gui/qt4/input_manager.cpp b/modules/gui/qt4/input_manager.cpp +index fd45f4a..c50cb6c 100644 +--- a/modules/gui/qt4/input_manager.cpp ++++ b/modules/gui/qt4/input_manager.cpp +@@ -30,6 +30,8 @@ + # include "config.h" + #endif + ++#include "qt4.hpp" ++ + #include "input_manager.hpp" + #include "recents.hpp" + +diff --git a/modules/gui/qt4/input_manager.hpp b/modules/gui/qt4/input_manager.hpp +index 7d3b76a..4fbecbb 100644 +--- a/modules/gui/qt4/input_manager.hpp ++++ b/modules/gui/qt4/input_manager.hpp +@@ -29,9 +29,10 @@ + # include "config.h" + #endif + ++#include "qt4.hpp" ++ + #include <vlc_input.h> + +-#include "qt4.hpp" + #include "util/singleton.hpp" + #include "adapters/variables.hpp" + +diff --git a/modules/gui/qt4/menus.cpp b/modules/gui/qt4/menus.cpp +index 116e98c..46240b0 100644 +--- a/modules/gui/qt4/menus.cpp ++++ b/modules/gui/qt4/menus.cpp +@@ -34,6 +34,8 @@ + # include "config.h" + #endif + ++#include "qt4.hpp" ++ + #include <vlc_common.h> + #include <vlc_intf_strings.h> + #include <vlc_vout.h> /* vout_thread_t */ +diff --git a/modules/gui/qt4/qt4.hpp b/modules/gui/qt4/qt4.hpp +index 44d7db6..5aec957 100644 +--- a/modules/gui/qt4/qt4.hpp ++++ b/modules/gui/qt4/qt4.hpp +@@ -29,12 +29,7 @@ + # include "config.h" + #endif + +-#include <vlc_common.h> /* VLC_COMMON_MEMBERS for vlc_interface.h */ +-#include <vlc_interface.h> /* intf_thread_t */ +-#include <vlc_playlist.h> /* playlist_t */ +- +-#define QT_NO_CAST_TO_ASCII +-#include <QString> ++#include <QtGlobal> + + #if ( QT_VERSION < 0x040600 ) + # error Update your Qt version to at least 4.6.0 +@@ -43,6 +38,31 @@ + #define HAS_QT47 ( QT_VERSION >= 0x040700 ) + #define HAS_QT5 ( QT_VERSION >= 0x050000 ) + ++#if HAS_QT5 ++ #include <QtCore/qcompilerdetection.h> ++ #if defined(Q_COMPILER_ATOMICS) && \ ++ ( __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7 ) ) ++ #define VLC_ATOMIC_H ++ #include <atomic> ++ using namespace std; ++ # define atomic_store(object,desired) \ ++ do { \ ++ *(object) = (desired); \ ++ __sync_synchronize(); \ ++ } while (0) ++ ++ # define atomic_load(object) \ ++ (__sync_synchronize(), *(object)) ++ #endif ++#endif ++ ++#include <vlc_common.h> /* VLC_COMMON_MEMBERS for vlc_interface.h */ ++#include <vlc_interface.h> /* intf_thread_t */ ++#include <vlc_playlist.h> /* playlist_t */ ++ ++#define QT_NO_CAST_TO_ASCII ++#include <QString> ++ + enum { + DialogEventTypeOffset = 0, + IMEventTypeOffset = 100, +diff --git a/modules/gui/qt4/util/pictureflow.cpp b/modules/gui/qt4/util/pictureflow.cpp +index 9318953..a7e6a01 100644 +--- a/modules/gui/qt4/util/pictureflow.cpp ++++ b/modules/gui/qt4/util/pictureflow.cpp +@@ -29,6 +29,8 @@ + THE SOFTWARE. + */ + ++#include "qt4.hpp" ++ + #include "pictureflow.hpp" + + #include <QApplication> +diff --git a/modules/visualization/projectm.cpp b/modules/visualization/projectm.cpp +index e80fbf4..96d532d 100644 +--- a/modules/visualization/projectm.cpp ++++ b/modules/visualization/projectm.cpp +@@ -30,6 +30,10 @@ + #endif + + #include <assert.h> ++#if defined(__GNUC__) && \ ++ ( __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7 ) ) ++ #define VLC_ATOMIC_H /* Ensure C atomics wont collide with old intrinsics */ ++#endif + + #include <vlc_common.h> + #include <vlc_plugin.h> +-- +2.7.4 diff --git a/media-video/vlc/files/vlc-2.2.4-relax_ffmpeg.patch b/media-video/vlc/files/vlc-2.2.4-relax_ffmpeg.patch new file mode 100644 index 000000000000..218af58281fa --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.4-relax_ffmpeg.patch @@ -0,0 +1,45 @@ +commit b8869f97ea66ac7ec9912a74c2e8b5e15daf7752 +Author: Rafaël Carré <funman@videolan.org> +Date: Fri Feb 26 00:36:26 2016 +0000 + + Relax requirements for FFmpeg hwaccel + + It doesn't error out anymore since 5edd1f62ca1 + +Index: vlc-2.2.4/configure.ac +=================================================================== +--- vlc-2.2.4.orig/configure.ac ++++ vlc-2.2.4/configure.ac +@@ -2383,7 +2383,9 @@ AS_IF([test "${have_vaapi}" = "yes" -a " + case "${avfork}" in + ffmpeg) + PKG_CHECK_EXISTS([libavcodec >= 57.10.100], [ +- AC_MSG_ERROR([VA API requires FFmpeg libavcodec < 57.10 or libav.]) ++ PKG_CHECK_EXISTS([libavcodec <= 57.12.100], [ ++ AC_MSG_ERROR([VA API requires FFmpeg libavcodec < 57.10 or > 57.12 or libav.]) ++ ]) + ]) + ;; + esac +@@ -2417,7 +2419,9 @@ AS_IF([test "${enable_dxva2}" != "no"], + case "${avfork}" in + ffmpeg) + PKG_CHECK_EXISTS([libavcodec >= 57.10.100], [ +- AC_MSG_ERROR([DXVA2 requires FFmpeg libavcodec < 57.10 or libav.]) ++ PKG_CHECK_EXISTS([libavcodec <= 57.12.100], [ ++ AC_MSG_ERROR([DXVA2 requires FFmpeg libavcodec < 57.10 or > 57.12 or libav.]) ++ ]) + ]) + ;; + esac +@@ -3181,7 +3185,9 @@ AS_IF([test "${have_vdpau}" = "yes" -a " + libav) av_vdpau_ver="55.26.0" ;; + ffmpeg) av_vdpau_ver="55.42.100" + PKG_CHECK_EXISTS([libavcodec >= 57.10.100], [ +- AC_MSG_ERROR([VDPAU requires FFmpeg libavcodec < 57.10 or libav.]) ++ PKG_CHECK_EXISTS([libavcodec <= 57.12.100], [ ++ AC_MSG_ERROR([VDPAU requires FFmpeg libavcodec < 57.10 or > 57.12 or libav.]) ++ ]) + ]) + ;; + esac diff --git a/media-video/vlc/files/vlc-2.2.6-decoder-lock-scope.patch b/media-video/vlc/files/vlc-2.2.6-decoder-lock-scope.patch new file mode 100644 index 000000000000..2e8064446d05 --- /dev/null +++ b/media-video/vlc/files/vlc-2.2.6-decoder-lock-scope.patch @@ -0,0 +1,34 @@ +X-Git-Url: https://git.videolan.org/?p=vlc.git;a=blobdiff_plain;f=src%2Finput%2Fdecoder.c;h=fe3cd428c65c18bfbdadb55baf11521afdc2bfc7;hp=83aa5bf54e2c29ad93fae803117558e4fcd0f658;hb=6ae2905ef7fbc7de3a3a4a1bdf8ad6df46ce570a;hpb=5b2de76965ee8b1ab5e3257f8b6d71bbb4e9e3f9 + +--- a/src/input/decoder.c ++++ b/src/input/decoder.c +@@ -1162,7 +1162,10 @@ + b_paused = p_owner->b_paused; + + if (!p_audio) ++ { ++ vlc_mutex_unlock( &p_owner->lock ); + break; ++ } + + /* */ + int i_rate = INPUT_RATE_DEFAULT; +@@ -1180,6 +1183,9 @@ + + if( unlikely(p_owner->b_paused != b_paused) ) + continue; /* race with input thread? retry... */ ++ ++ vlc_mutex_unlock( &p_owner->lock ); ++ + if( p_aout == NULL ) + b_reject = true; + +@@ -1199,7 +1205,6 @@ + + break; + } +- vlc_mutex_unlock( &p_owner->lock ); + } + + static void DecoderDecodeAudio( decoder_t *p_dec, block_t *p_block ) + diff --git a/media-video/vlc/files/vlc-9999-libva-1.2.1-compat.patch b/media-video/vlc/files/vlc-9999-libva-1.2.1-compat.patch new file mode 100644 index 000000000000..adfdefec56af --- /dev/null +++ b/media-video/vlc/files/vlc-9999-libva-1.2.1-compat.patch @@ -0,0 +1,12 @@ +--- a/modules/codec/avcodec/vaapi.c ++++ b/modules/codec/avcodec/vaapi.c +@@ -34,6 +34,9 @@ + #ifdef VLC_VA_BACKEND_XLIB + # include <vlc_xlib.h> + # include <va/va_x11.h> ++#if VA_MINOR_VERSION >= 34 ++# include <va/va_compat.h> ++#endif + #endif + #ifdef VLC_VA_BACKEND_DRM + # include <sys/types.h> diff --git a/media-video/vlc/metadata.xml b/media-video/vlc/metadata.xml new file mode 100644 index 000000000000..688bffbb09ad --- /dev/null +++ b/media-video/vlc/metadata.xml @@ -0,0 +1,72 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>media-video@gentoo.org</email> + <name>Gentoo Video project</name> + </maintainer> + <use> + <flag name="atmo">Enables support for AtmoLight (homebrew Ambient Lighting Technology)</flag> + <flag name="audioqueue">Enables AudioQueue audio module for Mac OS X.</flag> + <flag name="avcodec">Enables libavcodec support for video/audio encoding/decoding. libavcodec is part of FFmpeg.</flag> + <flag name="avformat">Enables libformat support for reading and writing various media containers. libavformat is part of FFmpeg.</flag> + <flag name="bluray">Enables libbluray for Blu-ray disc support.</flag> + <flag name="chromaprint">Enables libchromaprint for Chromaprint based audio fingerprinter support.</flag> + <flag name="chromecast">Enable experimental support for Google Chromecast.</flag> + <flag name="dc1394">Enables IIDC cameras support.</flag> + <flag name="directx">Enable Win32 DirectX support.</flag> + <flag name="dvbpsi">Enables support for Mpeg-TS files (.ts, .m2ts, .mts) via <pkg>media-libs/libdvbpsi</pkg>.</flag> + <flag name="dxva2">Enables Win32 DxVA2 support.</flag> + <flag name="faad">Enable AAC audio decoding library support via media-libs/faad2.</flag> + <flag name="fdk">Enables the Fraunhofer AAC codec library.</flag> + <flag name="fluidsynth">Enables Fluidsynth MIDI software synthesis (with external sound fonts).</flag> + <flag name="gcrypt">Enables cryptography support via libgcrypt.</flag> + <flag name="gme">Enables support for <pkg>media-libs/game-music-emu</pkg> for playing various video game music formats.</flag> + <flag name="gnome">Adds support for GNOME's filesystem abstraction layer, <pkg>gnome-base/gnome-vfs</pkg>. This flag is not GUI-related.</flag> + <flag name="growl">Enables growl notification support (over UDP for remote access and native on OSX)</flag> + <flag name="gstreamer">Enables GStreamer based decoding support (currently supports only video decoding)</flag> + <flag name="httpd">Enables a web based interface for vlc.</flag> + <flag name="kate">Adds support for Ogg Kate subtitles via libkate.</flag> + <flag name="libtar">Uses libtar instead of the built-in tar reader for reading custom skins.</flag> + <flag name="libtiger">Enables Ogg Kate subtitles rendering using libtiger.</flag> + <flag name="linsys">Enables support for Linux Linear Systems Ltd. SDI and HD-SDI input cards.</flag> + <flag name="live">Enables live555 streaming media support (client support for rtsp).</flag> + <flag name="lua">Enable Lua scripting support, needed for including support for Jamendo (online music platform) and similar things.</flag> + <flag name="macosx-dialog-provider">Enables Mac OS X dialog module.</flag> + <flag name="macosx-eyetv">Enables Mac OS X EyeTV (TNT Tuner) module.</flag> + <flag name="macosx-notifications">Enables Mac OS X notifications module (formerly growl).</flag> + <flag name="macosx-quartztext">Enables Mac OS X quartz text module.</flag> + <flag name="macosx-qtkit">Enables Mac OS X qtkit module: qtcapture (video) and qtsound (audio) module.</flag> + <flag name="matroska">Enables matroska support using reference libraries (fallback on other existing matroska support if disabled, i.e., matroska enabled FFmpeg)</flag> + <flag name="mpeg">Add libmpeg2 support for mpeg-1 and mpeg-2 video streams</flag> + <flag name="omxil">Enables OpenMAX Integration Layer codec module.</flag> + <flag name="optimisememory">Enable optimisation for memory rather than performance.</flag> + <flag name="opencv">Enabled OpenCV (computer vision) filter module.</flag> + <flag name="opus">Support opus decoding via libopus.</flag> + <flag name="postproc">Enables image post-processing via libpostproc (part of FFmpeg).</flag> + <flag name="projectm">Enables the projectM visualization plugin.</flag> + <flag name="qt4" restrict=">=media-video/vlc-0.9">Builds a Qt4 based frontend, a graphical interface.</flag> + <flag name="qt5" restrict=">=media-video/vlc-2.2">Builds a Qt5 based frontend, a graphical interface (overrides qt4).</flag> + <flag name="rtsp">Enables real audio and RTSP modules.</flag> + <flag name="run-as-root">Allows vlc to start for root. Don't enable this unless you have a very specific (e.g. embedded) need for it!</flag> + <flag name="schroedinger">Enable Dirac video support (an advanced royalty-free video compression format) via libschroedinger (high-speed implementation in C of the Dirac codec).</flag> + <flag name="sid">Adds support for playing C64 SID files through <pkg>media-libs/libsidplay</pkg>:2.</flag> + <flag name="sdl-image">Enables sdl image video decoder (depends on sdl)</flag> + <flag name="sftp">Enables libssh2 to support SFTP file transfer.</flag> + <flag name="shout">Enables libshout output.</flag> + <flag name="skins">Enables support for the skins2 interface.</flag> + <flag name="swscale">Enables image scaling and conversion via libswscale (part of FFmpeg).</flag> + <flag name="tremor">Enables tremor, a fixed-point version of the Ogg Vorbis decoder.</flag> + <flag name="twolame">Enables twolame support (MPEG Audio Layer 2 encoder).</flag> + <flag name="upnp">Enables support for the Intel SDK stack based UPnP discovery module instead of CyberLink.</flag> + <flag name="vcdx">Enables VCD with navigation via libvcdinfo (depends on cdio)</flag> + <flag name="vlm">New videolan (media) manager (vlm), a little manager designed to launch and manage multiple streams from within one instance of VLC.</flag> + <flag name="vpx">Enables the decoder(s) from the WebM VP8 / VP9 Codec SDK.</flag> + <flag name="wma-fixed">Enables fixed point WMA decoder.</flag> + <flag name="X">Enables support for, e.g., fullscreen mode via the X Window System. By itself, this flag does not build a graphical interface.</flag> + <flag name="xcb">Support the X C-language Binding, a replacement for Xlib; !!! you will need this option to be able to integrate video in the Qt interface, see bug #500678.</flag> + <flag name="x265">Support X265 Encoder.</flag> + <flag name="zeroconf">Enables support for zero-configuration networking via avahi.</flag> + <flag name="zvbi">Enables support for teletext subtitles via the zvbi library.</flag> + </use> +</pkgmetadata> diff --git a/media-video/vlc/vlc-2.2.6-r2.ebuild b/media-video/vlc/vlc-2.2.6-r2.ebuild new file mode 100644 index 000000000000..62e7d7e9ef21 --- /dev/null +++ b/media-video/vlc/vlc-2.2.6-r2.ebuild @@ -0,0 +1,485 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +MY_PV="${PV/_/-}" +MY_PV="${MY_PV/-beta/-test}" +MY_P="${PN}-${MY_PV}" +if [[ ${PV} = *9999 ]] ; then + if [[ ${PV%.9999} != ${PV} ]] ; then + EGIT_REPO_URI="https://git.videolan.org/git/vlc/vlc-${PV%.9999}.git" + else + EGIT_REPO_URI="https://git.videolan.org/git/vlc.git" + fi + SCM="git-r3" +else + if [[ ${MY_P} = ${P} ]] ; then + SRC_URI="https://download.videolan.org/pub/videolan/${PN}/${PV}/${P}.tar.xz" + else + SRC_URI="https://download.videolan.org/pub/videolan/testing/${MY_P}/${MY_P}.tar.xz" + fi + KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 -sparc ~x86 ~x86-fbsd" +fi +inherit autotools flag-o-matic toolchain-funcs versionator virtualx ${SCM} + +DESCRIPTION="VLC media player - Video player and streamer" +HOMEPAGE="https://www.videolan.org/vlc/" + +LICENSE="LGPL-2.1 GPL-2" +SLOT="0/5-8" # vlc - vlccore + +IUSE="a52 aalib alsa altivec atmo +audioqueue +avcodec +avformat bidi bluray cdda + cddb chromaprint dbus dc1394 debug directfb directx dts dvb +dvbpsi dvd dxva2 + elibc_glibc +encode faad fdk fluidsynth +ffmpeg flac fontconfig +gcrypt gme + gnome gnutls growl gstreamer httpd ieee1394 jack jpeg kate kde libass libav + libcaca libnotify +libsamplerate libtiger linsys libtar lirc live lua + macosx-dialog-provider macosx-eyetv macosx-quartztext macosx-qtkit + matroska cpu_flags_x86_mmx modplug mp3 mpeg mtp musepack ncurses neon ogg + omxil opencv opengl optimisememory opus png postproc projectm pulseaudio + qt4 +qt5 rdp rtsp run-as-root samba schroedinger sdl sdl-image sftp shout + sid skins speex cpu_flags_x86_sse svg +swscale taglib theora tremor truetype + twolame udev upnp vaapi v4l vcdx vdpau vlm vnc vorbis vpx wma-fixed +X + x264 x265 +xcb xml xv zeroconf zvbi +" +REQUIRED_USE=" + aalib? ( X ) + bidi? ( truetype ) + cddb? ( cdda ) + dvb? ( dvbpsi ) + dxva2? ( avcodec ) + ffmpeg? ( avcodec avformat swscale ) + fontconfig? ( truetype ) + gnutls? ( gcrypt ) + httpd? ( lua ) + libcaca? ( X ) + libtar? ( skins ) + libtiger? ( kate ) + qt4? ( X ) + qt5? ( X ) + sdl? ( X ) + skins? ( truetype X xml || ( qt4 qt5 ) ) + vaapi? ( avcodec X ) + vdpau? ( X ) + vlm? ( encode ) + xv? ( xcb ) +" +RDEPEND=" + dev-libs/libgpg-error:0 + net-dns/libidn:0 + sys-libs/zlib:0[minizip] + virtual/libintl:0 + a52? ( >=media-libs/a52dec-0.7.4-r3:0 ) + aalib? ( media-libs/aalib:0 ) + alsa? ( >=media-libs/alsa-lib-1.0.24:0 ) + avcodec? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + avformat? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + bidi? ( dev-libs/fribidi:0 ) + bluray? ( >=media-libs/libbluray-0.3:0= ) + cddb? ( >=media-libs/libcddb-1.2:0 ) + chromaprint? ( >=media-libs/chromaprint-0.6:0 ) + dbus? ( >=sys-apps/dbus-1.6:0 ) + dc1394? ( >=sys-libs/libraw1394-2.0.1:0 >=media-libs/libdc1394-2.1:2 ) + directfb? ( dev-libs/DirectFB:0 sys-libs/zlib:0 ) + dts? ( >=media-libs/libdca-0.0.5:0 ) + dvbpsi? ( >=media-libs/libdvbpsi-1.0.0:0= ) + dvd? ( >=media-libs/libdvdread-4.9:0 >=media-libs/libdvdnav-4.9:0 ) + elibc_glibc? ( >=sys-libs/glibc-2.8:2.2 ) + faad? ( >=media-libs/faad2-2.6.1:0 ) + fdk? ( media-libs/fdk-aac:0 ) + flac? ( >=media-libs/libogg-1:0 >=media-libs/flac-1.1.2:0 ) + fluidsynth? ( >=media-sound/fluidsynth-1.1.2:0 ) + fontconfig? ( media-libs/fontconfig:1.0 ) + gcrypt? ( >=dev-libs/libgcrypt-1.2.0:0= ) + gme? ( media-libs/game-music-emu:0 ) + gnome? ( gnome-base/gnome-vfs:2 dev-libs/glib:2 ) + gnutls? ( >=net-libs/gnutls-3.0.20:0 ) + gstreamer? ( >=media-libs/gst-plugins-base-1.4.5:1.0 ) + ieee1394? ( >=sys-libs/libraw1394-2.0.1:0 >=sys-libs/libavc1394-0.5.3:0 ) + jack? ( virtual/jack ) + jpeg? ( virtual/jpeg:0 ) + kate? ( >=media-libs/libkate-0.3:0 ) + libass? ( >=media-libs/libass-0.9.8:0= media-libs/fontconfig:1.0 ) + libcaca? ( >=media-libs/libcaca-0.99_beta14:0 ) + libnotify? ( x11-libs/libnotify:0 x11-libs/gtk+:2 x11-libs/gdk-pixbuf:2 dev-libs/glib:2 ) + libsamplerate? ( media-libs/libsamplerate:0 ) + libtar? ( >=dev-libs/libtar-1.2.11-r3:0 ) + libtiger? ( >=media-libs/libtiger-0.3.1:0 ) + linsys? ( >=media-libs/zvbi-0.2.28:0 ) + lirc? ( app-misc/lirc:0 ) + live? ( >=media-plugins/live-2011.12.23:0 ) + lua? ( >=dev-lang/lua-5.1:0 ) + matroska? ( >=dev-libs/libebml-1:0= >=media-libs/libmatroska-1:0= ) + modplug? ( >=media-libs/libmodplug-0.8.4:0 !~media-libs/libmodplug-0.8.8 ) + mp3? ( media-libs/libmad:0 ) + mpeg? ( >=media-libs/libmpeg2-0.3.2:0 ) + mtp? ( >=media-libs/libmtp-1:0 ) + musepack? ( >=media-sound/musepack-tools-444:0 ) + ncurses? ( sys-libs/ncurses:0=[unicode] ) + ogg? ( >=media-libs/libogg-1:0 ) + opencv? ( >media-libs/opencv-2:0= ) + opengl? ( virtual/opengl:0 >=x11-libs/libX11-1.3.99.901:0 ) + opus? ( >=media-libs/opus-1.0.3:0 ) + png? ( media-libs/libpng:0= sys-libs/zlib:0 ) + postproc? ( + !libav? ( >=media-video/ffmpeg-2.2:0= ) + libav? ( media-libs/libpostproc:0= ) + ) + projectm? ( media-libs/libprojectm:0 media-fonts/dejavu:0 ) + pulseaudio? ( >=media-sound/pulseaudio-1:0 ) + !qt5? ( qt4? ( dev-qt/qtcore:4 dev-qt/qtgui:4 ) ) + qt5? ( dev-qt/qtcore:5 dev-qt/qtgui:5 dev-qt/qtwidgets:5 dev-qt/qtx11extras:5 ) + rdp? ( =net-misc/freerdp-1*:0=[client] ) + samba? ( >=net-fs/samba-4.0.0_alpha1:0[client] ) + schroedinger? ( >=media-libs/schroedinger-1.0.10:0 ) + sdl? ( >=media-libs/libsdl-1.2.10:0 + sdl-image? ( >=media-libs/sdl-image-1.2.10:0 sys-libs/zlib:0 ) ) + sftp? ( net-libs/libssh2:0 ) + shout? ( >=media-libs/libshout-2.1:0 ) + sid? ( media-libs/libsidplay:2 ) + skins? ( x11-libs/libXext:0 x11-libs/libXpm:0 x11-libs/libXinerama:0 ) + speex? ( >=media-libs/speex-1.2.0:0 media-libs/speexdsp:0 ) + svg? ( >=gnome-base/librsvg-2.9:2 >=x11-libs/cairo-1.13.1:0 ) + swscale? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + taglib? ( >=media-libs/taglib-1.9:0 sys-libs/zlib:0 ) + theora? ( >=media-libs/libtheora-1.0_beta3:0 ) + tremor? ( media-libs/tremor:0 ) + truetype? ( media-libs/freetype:2 virtual/ttf-fonts:0 + !fontconfig? ( media-fonts/dejavu:0 ) ) + twolame? ( media-sound/twolame:0 ) + udev? ( >=virtual/udev-142:0 ) + upnp? ( net-libs/libupnp:0 ) + v4l? ( media-libs/libv4l:0 ) + vaapi? ( + x11-libs/libva:0[X,drm] + !libav? ( media-video/ffmpeg:0=[vaapi] ) + libav? ( media-video/libav:0=[vaapi] ) + ) + vcdx? ( >=dev-libs/libcdio-0.78.2:0 >=media-video/vcdimager-0.7.22:0 ) + vdpau? ( + x11-libs/libvdpau:0 + !libav? ( media-video/ffmpeg:0= ) + libav? ( >=media-video/libav-10:0= ) + ) + vnc? ( >=net-libs/libvncserver-0.9.9:0 ) + vorbis? ( media-libs/libvorbis:0 ) + vpx? ( media-libs/libvpx:0= ) + X? ( x11-libs/libX11:0 ) + x264? ( media-libs/x264:0= ) + x265? ( media-libs/x265:0= ) + xcb? ( x11-libs/libxcb:0 x11-libs/xcb-util:0 x11-libs/xcb-util-keysyms:0 ) + xml? ( dev-libs/libxml2:2 ) + zeroconf? ( >=net-dns/avahi-0.6:0[dbus] ) + zvbi? ( media-libs/zvbi:0 ) +" +DEPEND="${RDEPEND} + app-arch/xz-utils:0 + >=sys-devel/gettext-0.18.3:* + virtual/pkgconfig:* + !qt5? ( kde? ( kde-frameworks/kdelibs:4 ) ) + amd64? ( dev-lang/yasm:* ) + x86? ( dev-lang/yasm:* ) + xcb? ( x11-proto/xproto:0 ) +" + +PATCHES=( + # Fix build system mistake. + "${FILESDIR}"/${PN}-2.1.0-fix-libtremor-libs.patch + + # Patch up incompatibilities and reconfigure autotools. +# "${FILESDIR}"/${PN}-9999-libva-1.2.1-compat.patch + + # Fix up broken audio when skipping using a fixed reversed bisected commit. +# "${FILESDIR}"/${PN}-2.1.0-TomWij-bisected-PA-broken-underflow.patch + + # Bug #541678 + "${FILESDIR}"/qt4-select.patch + + # Allow QT5.5 since Gentoo has a patched QTwidgets + "${FILESDIR}"/${PN}-2.2.2-qt5widgets.patch + + # Bug #575072 + "${FILESDIR}"/${PN}-2.2.4-relax_ffmpeg.patch + "${FILESDIR}"/${PN}-2.2.4-ffmpeg3.patch + + # Bug #589396 + "${FILESDIR}"/${PN}-2.2.4-cxx0x.patch + + # Bug #594126, #629294 + "${FILESDIR}"/${PN}-2.2.6-decoder-lock-scope.patch + "${FILESDIR}"/${PN}-2.2.4-alsa-large-buffers.patch + + # Bug #593460 + "${FILESDIR}"/${PN}-2.2.4-libav-11.7.patch +) + +DOCS=( AUTHORS THANKS NEWS README doc/fortunes.txt doc/intf-vcd.txt ) + +S="${WORKDIR}/${MY_P}" + +src_unpack() { + if [[ ${PV} = *9999 ]] ; then + git-r3_src_unpack + else + unpack ${A} + fi +} + +src_prepare() { + default + + # Remove unnecessary warnings about unimplemented pragmas on gcc for now. + # Need to recheck this with gcc 4.9 and every subsequent minor bump of gcc. + # + # config.h:792: warning: ignoring #pragma STDC FENV_ACCESS [-Wunknown-pragmas] + # config.h:793: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas] + # + # https://gcc.gnu.org/c99status.html + if tc-is-gcc ; then + sed -i 's/ifndef __FAST_MATH__/if 0/g' configure.ac || die + fi + + # Bootstrap when we are on a git checkout. + if [[ ${PV} = *9999 ]] ; then + ./bootstrap + fi + + # Make it build with libtool 1.5 + rm -f m4/lt* m4/libtool.m4 || die + + # We are not in a real git checkout due to the absence of a .git directory. + touch src/revision.txt || die + + # Don't use --started-from-file when not using dbus. + if ! use dbus ; then + sed -i 's/ --started-from-file//' share/vlc.desktop.in || die + fi + + eautoreconf + + # Disable automatic running of tests. + find . -name 'Makefile.in' -exec sed -i 's/\(..*\)check-TESTS/\1/' {} \; || die + + # If qtchooser is installed, it may break the build, because moc,rcc and uic binaries for wrong qt + # version may be used. Setting QT_SELECT environment variable will enforce correct binaries. + if use qt5; then + export QT_SELECT=qt5 + elif use qt4; then + export QT_SELECT=qt4 + fi +} + +src_configure() { + local myconf + + # Compatibility fix for Samba 4. + use samba && append-cppflags "-I/usr/include/samba-4.0" + + # We need to disable -fstack-check if use >=gcc 4.8.0. bug #499996 + use x86 && append-cflags $(test-flags-CC -fno-stack-check) + + # FIXME: Needs libresid-builder from libsidplay:2 which is in another directory... + append-ldflags "-L/usr/$(get_libdir)/sidplay/builders/" + + if use truetype || use projectm ; then + local dejavu="/usr/share/fonts/dejavu/" + myconf="--with-default-font=${dejavu}/DejaVuSans.ttf \ + --with-default-font-family=Sans \ + --with-default-monospace-font=${dejavu}/DejaVuSansMono.ttf + --with-default-monospace-font-family=Monospace" + fi + + if use qt5 ; then + myconf+=" --enable-qt=5" + else + if use qt4 ; then + myconf+=" --enable-qt=4" + else + myconf+=" --disable-qt" + fi + use kde && myconf+=" --with-kde-solid" + fi + + econf \ + ${myconf} \ + --enable-vlc \ + --docdir=/usr/share/doc/${PF} \ + --disable-dependency-tracking \ + --disable-optimizations \ + --disable-update-check \ + --enable-fast-install \ + --enable-screen \ + $(use_enable a52) \ + $(use_enable aalib aa) \ + $(use_enable alsa) \ + $(use_enable altivec) \ + $(use_enable atmo) \ + $(use_enable audioqueue) \ + $(use_enable avcodec) \ + $(use_enable avformat) \ + $(use_enable bidi fribidi) \ + $(use_enable bluray) \ + $(use_enable cdda vcd) \ + $(use_enable cddb libcddb) \ + $(use_enable chromaprint) \ + $(use_enable dbus) \ + $(use_enable directfb) \ + $(use_enable directx) \ + $(use_enable dc1394) \ + $(use_enable debug) \ + $(use_enable dts dca) \ + $(use_enable dvbpsi) \ + $(use_enable dvd dvdread) $(use_enable dvd dvdnav) \ + $(use_enable dxva2) \ + $(use_enable encode sout) \ + $(use_enable faad) \ + $(use_enable fdk fdkaac) \ + $(use_enable flac) \ + $(use_enable fluidsynth) \ + $(use_enable fontconfig) \ + $(use_enable gcrypt libgcrypt) \ + $(use_enable gme) \ + $(use_enable gnome gnomevfs) \ + $(use_enable gnutls) \ + $(use_enable growl) \ + $(use_enable gstreamer gst-decode) \ + $(use_enable httpd) \ + $(use_enable ieee1394 dv1394) \ + $(use_enable jack) \ + $(use_enable jpeg) \ + $(use_enable kate) \ + $(use_enable libass) \ + $(use_enable libcaca caca) \ + $(use_enable libnotify notify) \ + $(use_enable libsamplerate samplerate) \ + $(use_enable libtar) \ + $(use_enable libtiger tiger) \ + $(use_enable linsys) \ + $(use_enable lirc) \ + $(use_enable live live555) \ + $(use_enable lua) \ + $(use_enable macosx-dialog-provider) \ + $(use_enable macosx-eyetv) \ + $(use_enable macosx-qtkit) \ + $(use_enable macosx-quartztext) \ + $(use_enable matroska mkv) \ + $(use_enable cpu_flags_x86_mmx mmx) \ + $(use_enable modplug mod) \ + $(use_enable mp3 mad) \ + $(use_enable mpeg libmpeg2) \ + $(use_enable mtp) \ + $(use_enable musepack mpc) \ + $(use_enable ncurses) \ + $(use_enable neon) \ + $(use_enable ogg) $(use_enable ogg mux_ogg) \ + $(use_enable omxil) \ + $(use_enable omxil omxil-vout) \ + $(use_enable opencv) \ + $(use_enable opengl glspectrum) \ + $(use_enable opus) \ + $(use_enable optimisememory optimize-memory) \ + $(use_enable png) \ + $(use_enable postproc) \ + $(use_enable projectm) \ + $(use_enable pulseaudio pulse) \ + $(use_enable rdp freerdp) \ + $(use_enable rtsp realrtsp) \ + $(use_enable run-as-root) \ + $(use_enable samba smbclient) \ + $(use_enable schroedinger) \ + $(use_enable sdl) \ + $(use_enable sdl-image) \ + $(use_enable sid) \ + $(use_enable sftp) \ + $(use_enable shout) \ + $(use_enable skins skins2) \ + $(use_enable speex) \ + $(use_enable cpu_flags_x86_sse sse) \ + $(use_enable svg) \ + $(use_enable svg svgdec) \ + $(use_enable swscale) \ + $(use_enable taglib) \ + $(use_enable theora) \ + $(use_enable tremor) \ + $(use_enable truetype freetype) \ + $(use_enable twolame) \ + $(use_enable udev) \ + $(use_enable upnp) \ + $(use_enable v4l v4l2) \ + $(use_enable vaapi libva) \ + $(use_enable vcdx) \ + $(use_enable vdpau) \ + $(use_enable vlm) \ + $(use_enable vnc) \ + $(use_enable vorbis) \ + $(use_enable vpx) \ + $(use_enable wma-fixed) \ + $(use_with X x) \ + $(use_enable x264) \ + $(use_enable x265) \ + $(use_enable xcb) \ + $(use_enable xml libxml2) \ + $(use_enable xv xvideo) \ + $(use_enable zeroconf bonjour) \ + $(use_enable zvbi) $(use_enable !zvbi telx) \ + --disable-asdcp \ + --disable-coverage \ + --disable-cprof \ + --disable-crystalhd \ + --disable-decklink \ + --disable-gles1 \ + --disable-gles2 \ + --disable-goom \ + --disable-kai \ + --disable-kva \ + --disable-maintainer-mode \ + --disable-merge-ffmpeg \ + --disable-mfx \ + --disable-mmal-codec \ + --disable-mmal-vout \ + --disable-opensles \ + --disable-oss \ + --disable-quicktime \ + --disable-rpi-omxil \ + --disable-shine \ + --disable-sndio \ + --disable-vda \ + --disable-vsxu \ + --disable-wasapi + + # ^ We don't have these disabled libraries in the Portage tree yet. + + # _FORTIFY_SOURCE is set to 2 in config.h, which is also the default value on Gentoo. + # Other values of _FORTIFY_SOURCE may break the build (bug 523144), so definition should not be removed from config.h. + # To prevent redefinition warnings, we undefine _FORTIFY_SOURCE at the very start of config.h file + sed -i '1i#undef _FORTIFY_SOURCE' "${S}"/config.h || die +} + +src_test() { + virtx emake check-TESTS +} + +src_install() { + default + find "${D}" -name '*.la' -delete || die +} + +pkg_postinst() { + if [[ "$ROOT" = "/" ]] && [[ -x "/usr/$(get_libdir)/vlc/vlc-cache-gen" ]] ; then + einfo "Running /usr/$(get_libdir)/vlc/vlc-cache-gen on /usr/$(get_libdir)/vlc/plugins/" + "/usr/$(get_libdir)/vlc/vlc-cache-gen" -f "/usr/$(get_libdir)/vlc/plugins/" + else + ewarn "We cannot run vlc-cache-gen (most likely ROOT!=/)" + ewarn "Please run /usr/$(get_libdir)/vlc/vlc-cache-gen manually" + ewarn "If you do not do it, vlc will take a long time to load." + fi +} diff --git a/media-video/vlc/vlc-2.2.6.ebuild b/media-video/vlc/vlc-2.2.6.ebuild new file mode 100644 index 000000000000..f821f2168cc0 --- /dev/null +++ b/media-video/vlc/vlc-2.2.6.ebuild @@ -0,0 +1,513 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +SCM="" +if [[ ${PV} = *9999 ]] ; then + SCM="git-r3" + + if [ "${PV%.9999}" != "${PV}" ] ; then + EGIT_REPO_URI="git://git.videolan.org/vlc/vlc-${PV%.9999}.git" + else + EGIT_REPO_URI="git://git.videolan.org/vlc.git" + fi +fi + +inherit autotools flag-o-matic toolchain-funcs versionator virtualx ${SCM} + +MY_PV="${PV/_/-}" +MY_PV="${MY_PV/-beta/-test}" +MY_P="${PN}-${MY_PV}" + +DESCRIPTION="VLC media player - Video player and streamer" +HOMEPAGE="https://www.videolan.org/vlc/" +if [[ ${PV} = *9999 ]] ; then # Live ebuild + SRC_URI="" +elif [[ "${MY_P}" == "${P}" ]]; then + SRC_URI="https://download.videolan.org/pub/videolan/${PN}/${PV}/${P}.tar.xz" +else + SRC_URI="https://download.videolan.org/pub/videolan/testing/${MY_P}/${MY_P}.tar.xz" +fi + +LICENSE="LGPL-2.1 GPL-2" +SLOT="0/5-8" # vlc - vlccore + +if [[ ${PV} != *9999 ]] ; then + KEYWORDS="amd64 arm ppc ppc64 -sparc x86 ~x86-fbsd" +fi + +IUSE="a52 aalib alsa altivec atmo +audioqueue +avcodec + +avformat bidi bluray cdda cddb chromaprint dbus dc1394 debug + directfb directx dts dvb +dvbpsi dvd dxva2 elibc_glibc +encode faad fdk + fluidsynth +ffmpeg flac fontconfig +gcrypt gme gnome gnutls + growl gstreamer httpd ieee1394 jack jpeg kate kde libass libav libcaca libnotify + +libsamplerate libtiger linsys libtar lirc live lua + macosx-dialog-provider macosx-eyetv macosx-quartztext macosx-qtkit + matroska cpu_flags_x86_mmx modplug mp3 mpeg + mtp musepack ncurses neon ogg omxil opencv opengl optimisememory opus + png postproc projectm pulseaudio +qt4 qt5 rdp rtsp run-as-root samba + schroedinger sdl sdl-image sftp shout sid skins speex cpu_flags_x86_sse svg +swscale + taglib theora tremor truetype twolame udev upnp vaapi v4l vcdx vdpau + vlm vnc vorbis vpx wma-fixed +X x264 x265 +xcb xml xv zeroconf zvbi" + +RDEPEND=" + dev-libs/libgpg-error:0 + net-dns/libidn:0 + sys-libs/zlib:0[minizip] + virtual/libintl:0 + a52? ( >=media-libs/a52dec-0.7.4-r3:0 ) + aalib? ( media-libs/aalib:0 ) + alsa? ( >=media-libs/alsa-lib-1.0.24:0 ) + avcodec? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + avformat? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + bidi? ( dev-libs/fribidi:0 ) + bluray? ( >=media-libs/libbluray-0.3:0= ) + cddb? ( >=media-libs/libcddb-1.2:0 ) + chromaprint? ( >=media-libs/chromaprint-0.6:0 ) + dbus? ( >=sys-apps/dbus-1.6:0 ) + dc1394? ( >=sys-libs/libraw1394-2.0.1:0 >=media-libs/libdc1394-2.1:2 ) + directfb? ( dev-libs/DirectFB:0 sys-libs/zlib:0 ) + dts? ( >=media-libs/libdca-0.0.5:0 ) + dvbpsi? ( >=media-libs/libdvbpsi-1.0.0:0= ) + dvd? ( >=media-libs/libdvdread-4.9:0 >=media-libs/libdvdnav-4.9:0 ) + elibc_glibc? ( >=sys-libs/glibc-2.8:2.2 ) + faad? ( >=media-libs/faad2-2.6.1:0 ) + fdk? ( media-libs/fdk-aac:0 ) + flac? ( >=media-libs/libogg-1:0 >=media-libs/flac-1.1.2:0 ) + fluidsynth? ( >=media-sound/fluidsynth-1.1.2:0 ) + fontconfig? ( media-libs/fontconfig:1.0 ) + gcrypt? ( >=dev-libs/libgcrypt-1.2.0:0= ) + gme? ( media-libs/game-music-emu:0 ) + gnome? ( gnome-base/gnome-vfs:2 dev-libs/glib:2 ) + gnutls? ( >=net-libs/gnutls-3.0.20:0 ) + gstreamer? ( >=media-libs/gst-plugins-base-1.4.5:1.0 ) + ieee1394? ( >=sys-libs/libraw1394-2.0.1:0 >=sys-libs/libavc1394-0.5.3:0 ) + jack? ( virtual/jack ) + jpeg? ( virtual/jpeg:0 ) + kate? ( >=media-libs/libkate-0.3:0 ) + libass? ( >=media-libs/libass-0.9.8:0= media-libs/fontconfig:1.0 ) + libcaca? ( >=media-libs/libcaca-0.99_beta14:0 ) + libnotify? ( x11-libs/libnotify:0 x11-libs/gtk+:2 x11-libs/gdk-pixbuf:2 dev-libs/glib:2 ) + libsamplerate? ( media-libs/libsamplerate:0 ) + libtar? ( >=dev-libs/libtar-1.2.11-r3:0 ) + libtiger? ( >=media-libs/libtiger-0.3.1:0 ) + linsys? ( >=media-libs/zvbi-0.2.28:0 ) + lirc? ( app-misc/lirc:0 ) + live? ( >=media-plugins/live-2011.12.23:0 ) + lua? ( >=dev-lang/lua-5.1:0 ) + matroska? ( >=dev-libs/libebml-1:0= >=media-libs/libmatroska-1:0= ) + modplug? ( >=media-libs/libmodplug-0.8.4:0 !~media-libs/libmodplug-0.8.8 ) + mp3? ( media-libs/libmad:0 ) + mpeg? ( >=media-libs/libmpeg2-0.3.2:0 ) + mtp? ( >=media-libs/libmtp-1:0 ) + musepack? ( >=media-sound/musepack-tools-444:0 ) + ncurses? ( sys-libs/ncurses:0=[unicode] ) + ogg? ( >=media-libs/libogg-1:0 ) + opencv? ( >media-libs/opencv-2:0= ) + opengl? ( virtual/opengl:0 >=x11-libs/libX11-1.3.99.901:0 ) + opus? ( >=media-libs/opus-1.0.3:0 ) + png? ( media-libs/libpng:0= sys-libs/zlib:0 ) + postproc? ( + !libav? ( >=media-video/ffmpeg-2.2:0= ) + libav? ( media-libs/libpostproc:0= ) + ) + projectm? ( media-libs/libprojectm:0 media-fonts/dejavu:0 ) + pulseaudio? ( >=media-sound/pulseaudio-1:0 ) + !qt5? ( qt4? ( dev-qt/qtcore:4 dev-qt/qtgui:4 ) ) + qt5? ( dev-qt/qtcore:5 dev-qt/qtgui:5 dev-qt/qtwidgets:5 dev-qt/qtx11extras:5 ) + rdp? ( =net-misc/freerdp-1*:0=[client] ) + samba? ( >=net-fs/samba-4.0.0_alpha1:0[client] ) + schroedinger? ( >=media-libs/schroedinger-1.0.10:0 ) + sdl? ( >=media-libs/libsdl-1.2.10:0 + sdl-image? ( >=media-libs/sdl-image-1.2.10:0 sys-libs/zlib:0 ) ) + sftp? ( net-libs/libssh2:0 ) + shout? ( >=media-libs/libshout-2.1:0 ) + sid? ( media-libs/libsidplay:2 ) + skins? ( x11-libs/libXext:0 x11-libs/libXpm:0 x11-libs/libXinerama:0 ) + speex? ( media-libs/speex:0 ) + svg? ( >=gnome-base/librsvg-2.9:2 >=x11-libs/cairo-1.13.1:0 ) + swscale? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + taglib? ( >=media-libs/taglib-1.9:0 sys-libs/zlib:0 ) + theora? ( >=media-libs/libtheora-1.0_beta3:0 ) + tremor? ( media-libs/tremor:0 ) + truetype? ( media-libs/freetype:2 virtual/ttf-fonts:0 + !fontconfig? ( media-fonts/dejavu:0 ) ) + twolame? ( media-sound/twolame:0 ) + udev? ( >=virtual/udev-142:0 ) + upnp? ( net-libs/libupnp:0 ) + v4l? ( media-libs/libv4l:0 ) + vaapi? ( + x11-libs/libva:0[X,drm] + !libav? ( media-video/ffmpeg:0=[vaapi] ) + libav? ( media-video/libav:0=[vaapi] ) + ) + vcdx? ( >=dev-libs/libcdio-0.78.2:0 >=media-video/vcdimager-0.7.22:0 ) + zeroconf? ( >=net-dns/avahi-0.6:0[dbus] ) +" + +# Temporarily block non-live FFMPEG versions as they break vdpau, 9999 works; +# thus we'll have to wait for a new release there. +RDEPEND="${RDEPEND} + vdpau? ( + x11-libs/libvdpau:0 + !libav? ( media-video/ffmpeg:0= ) + libav? ( >=media-video/libav-10:0= ) + ) + vnc? ( >=net-libs/libvncserver-0.9.9:0 ) + vorbis? ( media-libs/libvorbis:0 ) + vpx? ( media-libs/libvpx:0= ) + X? ( x11-libs/libX11:0 ) + x264? ( media-libs/x264:0= ) + x265? ( media-libs/x265:0= ) + xcb? ( x11-libs/libxcb:0 x11-libs/xcb-util:0 x11-libs/xcb-util-keysyms:0 ) + xml? ( dev-libs/libxml2:2 ) + zvbi? ( media-libs/zvbi:0 ) +" + +DEPEND="${RDEPEND} + !qt5? ( kde? ( kde-frameworks/kdelibs:4 ) ) + amd64? ( dev-lang/yasm:* ) + x86? ( dev-lang/yasm:* ) + xcb? ( x11-proto/xproto:0 ) + app-arch/xz-utils:0 + >=sys-devel/gettext-0.18.3:* + virtual/pkgconfig:* +" + +REQUIRED_USE=" + aalib? ( X ) + bidi? ( truetype ) + cddb? ( cdda ) + dvb? ( dvbpsi ) + dxva2? ( avcodec ) + ffmpeg? ( avcodec avformat swscale ) + fontconfig? ( truetype ) + gnutls? ( gcrypt ) + httpd? ( lua ) + libcaca? ( X ) + libtar? ( skins ) + libtiger? ( kate ) + qt4? ( X ) + qt5? ( X ) + sdl? ( X ) + skins? ( truetype X xml || ( qt4 qt5 ) ) + vaapi? ( avcodec X ) + vdpau? ( X ) + vlm? ( encode ) + xv? ( xcb ) +" + +PATCHES=( + # Fix build system mistake. + "${FILESDIR}"/${PN}-2.1.0-fix-libtremor-libs.patch + + # Patch up incompatibilities and reconfigure autotools. + "${FILESDIR}"/${PN}-9999-libva-1.2.1-compat.patch + + # Fix up broken audio when skipping using a fixed reversed bisected commit. + "${FILESDIR}"/${PN}-2.1.0-TomWij-bisected-PA-broken-underflow.patch + + # Bug #541678 + "${FILESDIR}"/qt4-select.patch + + # Allow QT5.5 since Gentoo has a patched QTwidgets + "${FILESDIR}"/${PN}-2.2.2-qt5widgets.patch + + # Bug #575072 + "${FILESDIR}"/${PN}-2.2.4-relax_ffmpeg.patch + "${FILESDIR}"/${PN}-2.2.4-ffmpeg3.patch + + # Bug #589396 + "${FILESDIR}"/${PN}-2.2.4-cxx0x.patch + + # Bug #594126 + "${FILESDIR}"/${PN}-2.2.4-decoder-lock-scope.patch + "${FILESDIR}"/${PN}-2.2.4-alsa-large-buffers.patch + + # Bug #593460 + "${FILESDIR}"/${PN}-2.2.4-libav-11.7.patch +) + +DOCS=( AUTHORS THANKS NEWS README doc/fortunes.txt doc/intf-vcd.txt ) + +S="${WORKDIR}/${MY_P}" + +pkg_setup() { + if [[ "${MERGE_TYPE}" != "binary" ]] && tc-is-gcc ; then + if ! version_is_at_least 4.5 $(gcc-version) ; then + die "You need to have at least >=sys-devel/gcc-4.5 to build and/or have a working vlc, see bug #426754." + fi + fi +} + +src_unpack() { + if [[ ${PV} = *9999 ]] ; then + git-r3_src_unpack + else + unpack ${A} + fi +} + +src_prepare() { + # Remove unnecessary warnings about unimplemented pragmas on gcc for now. + # Need to recheck this with gcc 4.9 and every subsequent minor bump of gcc. + # + # config.h:792: warning: ignoring #pragma STDC FENV_ACCESS [-Wunknown-pragmas] + # config.h:793: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas] + # + # https://gcc.gnu.org/c99status.html + if tc-is-gcc ; then + sed -i 's/ifndef __FAST_MATH__/if 0/g' configure.ac || die + fi + + # Bootstrap when we are on a git checkout. + if [[ ${PV} = *9999 ]] ; then + ./bootstrap + fi + + # Make it build with libtool 1.5 + rm -f m4/lt* m4/libtool.m4 || die + + # We are not in a real git checkout due to the absence of a .git directory. + touch src/revision.txt || die + + default + + # Don't use --started-from-file when not using dbus. + if ! use dbus ; then + sed -i 's/ --started-from-file//' share/vlc.desktop.in || die + fi + + eautoreconf + + # Disable automatic running of tests. + find . -name 'Makefile.in' -exec sed -i 's/\(..*\)check-TESTS/\1/' {} \; || die + + # If qtchooser is installed, it may break the build, because moc,rcc and uic binaries for wrong qt + # version may be used. Setting QT_SELECT environment variable will enforce correct binaries. + if use qt5; then + export QT_SELECT=qt5 + elif use qt4; then + export QT_SELECT=qt4 + fi +} + +src_configure() { + local myconf + + # Compatibility fix for Samba 4. + use samba && append-cppflags "-I/usr/include/samba-4.0" + + # We need to disable -fstack-check if use >=gcc 4.8.0. + # See bug #499996 + use x86 && append-cflags $(test-flags-CC -fno-stack-check) + + # Needs libresid-builder from libsidplay:2 which is in another directory... + # FIXME! + append-ldflags "-L/usr/$(get_libdir)/sidplay/builders/" + + if use truetype || use projectm ; then + local dejavu="/usr/share/fonts/dejavu/" + myconf="--with-default-font=${dejavu}/DejaVuSans.ttf \ + --with-default-font-family=Sans \ + --with-default-monospace-font=${dejavu}/DejaVuSansMono.ttf + --with-default-monospace-font-family=Monospace" + fi + + if use qt5 ; then + myconf+=" --enable-qt=5" + else + if use qt4 ; then + myconf+=" --enable-qt=4" + else + myconf+=" --disable-qt" + fi + use kde && myconf+=" --with-kde-solid" + fi + + econf \ + ${myconf} \ + --enable-vlc \ + --docdir=/usr/share/doc/${PF} \ + --disable-dependency-tracking \ + --disable-optimizations \ + --disable-update-check \ + --enable-fast-install \ + --enable-screen \ + $(use_enable a52) \ + $(use_enable aalib aa) \ + $(use_enable alsa) \ + $(use_enable altivec) \ + $(use_enable atmo) \ + $(use_enable audioqueue) \ + $(use_enable avcodec) \ + $(use_enable avformat) \ + $(use_enable bidi fribidi) \ + $(use_enable bluray) \ + $(use_enable cdda vcd) \ + $(use_enable cddb libcddb) \ + $(use_enable chromaprint) \ + $(use_enable dbus) \ + $(use_enable directfb) \ + $(use_enable directx) \ + $(use_enable dc1394) \ + $(use_enable debug) \ + $(use_enable dts dca) \ + $(use_enable dvbpsi) \ + $(use_enable dvd dvdread) $(use_enable dvd dvdnav) \ + $(use_enable dxva2) \ + $(use_enable encode sout) \ + $(use_enable faad) \ + $(use_enable fdk fdkaac) \ + $(use_enable flac) \ + $(use_enable fluidsynth) \ + $(use_enable fontconfig) \ + $(use_enable gcrypt libgcrypt) \ + $(use_enable gme) \ + $(use_enable gnome gnomevfs) \ + $(use_enable gnutls) \ + $(use_enable growl) \ + $(use_enable gstreamer gst-decode) \ + $(use_enable httpd) \ + $(use_enable ieee1394 dv1394) \ + $(use_enable jack) \ + $(use_enable jpeg) \ + $(use_enable kate) \ + $(use_enable libass) \ + $(use_enable libcaca caca) \ + $(use_enable libnotify notify) \ + $(use_enable libsamplerate samplerate) \ + $(use_enable libtar) \ + $(use_enable libtiger tiger) \ + $(use_enable linsys) \ + $(use_enable lirc) \ + $(use_enable live live555) \ + $(use_enable lua) \ + $(use_enable macosx-dialog-provider) \ + $(use_enable macosx-eyetv) \ + $(use_enable macosx-qtkit) \ + $(use_enable macosx-quartztext) \ + $(use_enable matroska mkv) \ + $(use_enable cpu_flags_x86_mmx mmx) \ + $(use_enable modplug mod) \ + $(use_enable mp3 mad) \ + $(use_enable mpeg libmpeg2) \ + $(use_enable mtp) \ + $(use_enable musepack mpc) \ + $(use_enable ncurses) \ + $(use_enable neon) \ + $(use_enable ogg) $(use_enable ogg mux_ogg) \ + $(use_enable omxil) \ + $(use_enable omxil omxil-vout) \ + $(use_enable opencv) \ + $(use_enable opengl glspectrum) \ + $(use_enable opus) \ + $(use_enable optimisememory optimize-memory) \ + $(use_enable png) \ + $(use_enable postproc) \ + $(use_enable projectm) \ + $(use_enable pulseaudio pulse) \ + $(use_enable rdp freerdp) \ + $(use_enable rtsp realrtsp) \ + $(use_enable run-as-root) \ + $(use_enable samba smbclient) \ + $(use_enable schroedinger) \ + $(use_enable sdl) \ + $(use_enable sdl-image) \ + $(use_enable sid) \ + $(use_enable sftp) \ + $(use_enable shout) \ + $(use_enable skins skins2) \ + $(use_enable speex) \ + $(use_enable cpu_flags_x86_sse sse) \ + $(use_enable svg) \ + $(use_enable svg svgdec) \ + $(use_enable swscale) \ + $(use_enable taglib) \ + $(use_enable theora) \ + $(use_enable tremor) \ + $(use_enable truetype freetype) \ + $(use_enable twolame) \ + $(use_enable udev) \ + $(use_enable upnp) \ + $(use_enable v4l v4l2) \ + $(use_enable vaapi libva) \ + $(use_enable vcdx) \ + $(use_enable vdpau) \ + $(use_enable vlm) \ + $(use_enable vnc) \ + $(use_enable vorbis) \ + $(use_enable vpx) \ + $(use_enable wma-fixed) \ + $(use_with X x) \ + $(use_enable x264) \ + $(use_enable x265) \ + $(use_enable xcb) \ + $(use_enable xml libxml2) \ + $(use_enable xv xvideo) \ + $(use_enable zeroconf bonjour) \ + $(use_enable zvbi) $(use_enable !zvbi telx) \ + --disable-asdcp \ + --disable-coverage \ + --disable-cprof \ + --disable-crystalhd \ + --disable-decklink \ + --disable-gles1 \ + --disable-gles2 \ + --disable-goom \ + --disable-kai \ + --disable-kva \ + --disable-maintainer-mode \ + --disable-merge-ffmpeg \ + --disable-mfx \ + --disable-mmal-codec \ + --disable-mmal-vout \ + --disable-opensles \ + --disable-oss \ + --disable-quicktime \ + --disable-rpi-omxil \ + --disable-shine \ + --disable-sndio \ + --disable-vda \ + --disable-vsxu \ + --disable-wasapi + + # ^ We don't have these disabled libraries in the Portage tree yet. + + # _FORTIFY_SOURCE is set to 2 in config.h, which is also the default value on Gentoo. + # Other values of _FORTIFY_SOURCE may break the build (bug 523144), so definition should not be removed from config.h. + # To prevent redefinition warnings, we undefine _FORTIFY_SOURCE at the very start of config.h file + sed -i '1i#undef _FORTIFY_SOURCE' "${S}"/config.h || die +} + +src_test() { + virtx emake check-TESTS +} + +src_install() { + default + + # Punt useless libtool's .la files + find "${D}" -name '*.la' -delete || die +} + +pkg_postinst() { + if [ "$ROOT" = "/" ] && [ -x "/usr/$(get_libdir)/vlc/vlc-cache-gen" ] ; then + einfo "Running /usr/$(get_libdir)/vlc/vlc-cache-gen on /usr/$(get_libdir)/vlc/plugins/" + "/usr/$(get_libdir)/vlc/vlc-cache-gen" -f "/usr/$(get_libdir)/vlc/plugins/" + else + ewarn "We cannot run vlc-cache-gen (most likely ROOT!=/)" + ewarn "Please run /usr/$(get_libdir)/vlc/vlc-cache-gen manually" + ewarn "If you do not do it, vlc will take a long time to load." + fi +} diff --git a/media-video/vlc/vlc-2.2.9999.ebuild b/media-video/vlc/vlc-2.2.9999.ebuild new file mode 100644 index 000000000000..069a19e151fa --- /dev/null +++ b/media-video/vlc/vlc-2.2.9999.ebuild @@ -0,0 +1,485 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +MY_PV="${PV/_/-}" +MY_PV="${MY_PV/-beta/-test}" +MY_P="${PN}-${MY_PV}" +if [[ ${PV} = *9999 ]] ; then + if [[ ${PV%.9999} != ${PV} ]] ; then + EGIT_REPO_URI="https://git.videolan.org/git/vlc/vlc-${PV%.9999}.git" + else + EGIT_REPO_URI="https://git.videolan.org/git/vlc.git" + fi + SCM="git-r3" +else + if [[ ${MY_P} = ${P} ]] ; then + SRC_URI="https://download.videolan.org/pub/videolan/${PN}/${PV}/${P}.tar.xz" + else + SRC_URI="https://download.videolan.org/pub/videolan/testing/${MY_P}/${MY_P}.tar.xz" + fi + KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 -sparc ~x86 ~x86-fbsd" +fi +inherit autotools flag-o-matic toolchain-funcs versionator virtualx ${SCM} + +DESCRIPTION="VLC media player - Video player and streamer" +HOMEPAGE="https://www.videolan.org/vlc/" + +LICENSE="LGPL-2.1 GPL-2" +SLOT="0/5-8" # vlc - vlccore + +IUSE="a52 aalib alsa altivec atmo +audioqueue +avcodec +avformat bidi bluray cdda + cddb chromaprint dbus dc1394 debug directfb directx dts dvb +dvbpsi dvd dxva2 + elibc_glibc +encode faad fdk fluidsynth +ffmpeg flac fontconfig +gcrypt gme + gnome gnutls growl gstreamer httpd ieee1394 jack jpeg kate kde libass libav + libcaca libnotify +libsamplerate libtiger linsys libtar lirc live lua + macosx-dialog-provider macosx-eyetv macosx-quartztext macosx-qtkit + matroska cpu_flags_x86_mmx modplug mp3 mpeg mtp musepack ncurses neon ogg + omxil opencv opengl optimisememory opus png postproc projectm pulseaudio + qt4 +qt5 rdp rtsp run-as-root samba schroedinger sdl sdl-image sftp shout + sid skins speex cpu_flags_x86_sse svg +swscale taglib theora tremor truetype + twolame udev upnp vaapi v4l vcdx vdpau vlm vnc vorbis vpx wma-fixed +X + x264 x265 +xcb xml xv zeroconf zvbi +" +REQUIRED_USE=" + aalib? ( X ) + bidi? ( truetype ) + cddb? ( cdda ) + dvb? ( dvbpsi ) + dxva2? ( avcodec ) + ffmpeg? ( avcodec avformat swscale ) + fontconfig? ( truetype ) + gnutls? ( gcrypt ) + httpd? ( lua ) + libcaca? ( X ) + libtar? ( skins ) + libtiger? ( kate ) + qt4? ( X ) + qt5? ( X ) + sdl? ( X ) + skins? ( truetype X xml || ( qt4 qt5 ) ) + vaapi? ( avcodec X ) + vdpau? ( X ) + vlm? ( encode ) + xv? ( xcb ) +" +RDEPEND=" + dev-libs/libgpg-error:0 + net-dns/libidn:0 + sys-libs/zlib:0[minizip] + virtual/libintl:0 + a52? ( >=media-libs/a52dec-0.7.4-r3:0 ) + aalib? ( media-libs/aalib:0 ) + alsa? ( >=media-libs/alsa-lib-1.0.24:0 ) + avcodec? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + avformat? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + bidi? ( dev-libs/fribidi:0 ) + bluray? ( >=media-libs/libbluray-0.3:0= ) + cddb? ( >=media-libs/libcddb-1.2:0 ) + chromaprint? ( >=media-libs/chromaprint-0.6:0 ) + dbus? ( >=sys-apps/dbus-1.6:0 ) + dc1394? ( >=sys-libs/libraw1394-2.0.1:0 >=media-libs/libdc1394-2.1:2 ) + directfb? ( dev-libs/DirectFB:0 sys-libs/zlib:0 ) + dts? ( >=media-libs/libdca-0.0.5:0 ) + dvbpsi? ( >=media-libs/libdvbpsi-1.0.0:0= ) + dvd? ( >=media-libs/libdvdread-4.9:0 >=media-libs/libdvdnav-4.9:0 ) + elibc_glibc? ( >=sys-libs/glibc-2.8:2.2 ) + faad? ( >=media-libs/faad2-2.6.1:0 ) + fdk? ( media-libs/fdk-aac:0 ) + flac? ( >=media-libs/libogg-1:0 >=media-libs/flac-1.1.2:0 ) + fluidsynth? ( >=media-sound/fluidsynth-1.1.2:0 ) + fontconfig? ( media-libs/fontconfig:1.0 ) + gcrypt? ( >=dev-libs/libgcrypt-1.2.0:0= ) + gme? ( media-libs/game-music-emu:0 ) + gnome? ( gnome-base/gnome-vfs:2 dev-libs/glib:2 ) + gnutls? ( >=net-libs/gnutls-3.0.20:0 ) + gstreamer? ( >=media-libs/gst-plugins-base-1.4.5:1.0 ) + ieee1394? ( >=sys-libs/libraw1394-2.0.1:0 >=sys-libs/libavc1394-0.5.3:0 ) + jack? ( virtual/jack ) + jpeg? ( virtual/jpeg:0 ) + kate? ( >=media-libs/libkate-0.3:0 ) + libass? ( >=media-libs/libass-0.9.8:0= media-libs/fontconfig:1.0 ) + libcaca? ( >=media-libs/libcaca-0.99_beta14:0 ) + libnotify? ( x11-libs/libnotify:0 x11-libs/gtk+:2 x11-libs/gdk-pixbuf:2 dev-libs/glib:2 ) + libsamplerate? ( media-libs/libsamplerate:0 ) + libtar? ( >=dev-libs/libtar-1.2.11-r3:0 ) + libtiger? ( >=media-libs/libtiger-0.3.1:0 ) + linsys? ( >=media-libs/zvbi-0.2.28:0 ) + lirc? ( app-misc/lirc:0 ) + live? ( >=media-plugins/live-2011.12.23:0 ) + lua? ( >=dev-lang/lua-5.1:0 ) + matroska? ( >=dev-libs/libebml-1:0= >=media-libs/libmatroska-1:0= ) + modplug? ( >=media-libs/libmodplug-0.8.4:0 !~media-libs/libmodplug-0.8.8 ) + mp3? ( media-libs/libmad:0 ) + mpeg? ( >=media-libs/libmpeg2-0.3.2:0 ) + mtp? ( >=media-libs/libmtp-1:0 ) + musepack? ( >=media-sound/musepack-tools-444:0 ) + ncurses? ( sys-libs/ncurses:0=[unicode] ) + ogg? ( >=media-libs/libogg-1:0 ) + opencv? ( >media-libs/opencv-2:0= ) + opengl? ( virtual/opengl:0 >=x11-libs/libX11-1.3.99.901:0 ) + opus? ( >=media-libs/opus-1.0.3:0 ) + png? ( media-libs/libpng:0= sys-libs/zlib:0 ) + postproc? ( + !libav? ( >=media-video/ffmpeg-2.2:0= ) + libav? ( media-libs/libpostproc:0= ) + ) + projectm? ( media-libs/libprojectm:0 media-fonts/dejavu:0 ) + pulseaudio? ( >=media-sound/pulseaudio-1:0 ) + !qt5? ( qt4? ( dev-qt/qtcore:4 dev-qt/qtgui:4 ) ) + qt5? ( dev-qt/qtcore:5 dev-qt/qtgui:5 dev-qt/qtwidgets:5 dev-qt/qtx11extras:5 ) + rdp? ( =net-misc/freerdp-1*:0=[client] ) + samba? ( >=net-fs/samba-4.0.0_alpha1:0[client] ) + schroedinger? ( >=media-libs/schroedinger-1.0.10:0 ) + sdl? ( >=media-libs/libsdl-1.2.10:0 + sdl-image? ( >=media-libs/sdl-image-1.2.10:0 sys-libs/zlib:0 ) ) + sftp? ( net-libs/libssh2:0 ) + shout? ( >=media-libs/libshout-2.1:0 ) + sid? ( media-libs/libsidplay:2 ) + skins? ( x11-libs/libXext:0 x11-libs/libXpm:0 x11-libs/libXinerama:0 ) + speex? ( >=media-libs/speex-1.2.0:0 media-libs/speexdsp:0 ) + svg? ( >=gnome-base/librsvg-2.9:2 >=x11-libs/cairo-1.13.1:0 ) + swscale? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + taglib? ( >=media-libs/taglib-1.9:0 sys-libs/zlib:0 ) + theora? ( >=media-libs/libtheora-1.0_beta3:0 ) + tremor? ( media-libs/tremor:0 ) + truetype? ( media-libs/freetype:2 virtual/ttf-fonts:0 + !fontconfig? ( media-fonts/dejavu:0 ) ) + twolame? ( media-sound/twolame:0 ) + udev? ( >=virtual/udev-142:0 ) + upnp? ( net-libs/libupnp:0 ) + v4l? ( media-libs/libv4l:0 ) + vaapi? ( + x11-libs/libva:0[X,drm] + !libav? ( media-video/ffmpeg:0=[vaapi] ) + libav? ( media-video/libav:0=[vaapi] ) + ) + vcdx? ( >=dev-libs/libcdio-0.78.2:0 >=media-video/vcdimager-0.7.22:0 ) + vdpau? ( + x11-libs/libvdpau:0 + !libav? ( media-video/ffmpeg:0= ) + libav? ( >=media-video/libav-10:0= ) + ) + vnc? ( >=net-libs/libvncserver-0.9.9:0 ) + vorbis? ( media-libs/libvorbis:0 ) + vpx? ( media-libs/libvpx:0= ) + X? ( x11-libs/libX11:0 ) + x264? ( media-libs/x264:0= ) + x265? ( media-libs/x265:0= ) + xcb? ( x11-libs/libxcb:0 x11-libs/xcb-util:0 x11-libs/xcb-util-keysyms:0 ) + xml? ( dev-libs/libxml2:2 ) + zeroconf? ( >=net-dns/avahi-0.6:0[dbus] ) + zvbi? ( media-libs/zvbi:0 ) +" +DEPEND="${RDEPEND} + app-arch/xz-utils:0 + >=sys-devel/gettext-0.18.3:* + virtual/pkgconfig:* + !qt5? ( kde? ( kde-frameworks/kdelibs:4 ) ) + amd64? ( dev-lang/yasm:* ) + x86? ( dev-lang/yasm:* ) + xcb? ( x11-proto/xproto:0 ) +" + +PATCHES=( + # Fix build system mistake. + "${FILESDIR}"/${PN}-2.1.0-fix-libtremor-libs.patch + + # Patch up incompatibilities and reconfigure autotools. + "${FILESDIR}"/${PN}-9999-libva-1.2.1-compat.patch + + # Fix up broken audio when skipping using a fixed reversed bisected commit. + "${FILESDIR}"/${PN}-2.1.0-TomWij-bisected-PA-broken-underflow.patch + + # Bug #541678 + "${FILESDIR}"/qt4-select.patch + + # Allow QT5.5 since Gentoo has a patched QTwidgets + "${FILESDIR}"/${PN}-2.2.2-qt5widgets.patch + + # Bug #575072 + "${FILESDIR}"/${PN}-2.2.4-relax_ffmpeg.patch + "${FILESDIR}"/${PN}-2.2.4-ffmpeg3.patch + + # Bug #589396 + "${FILESDIR}"/${PN}-2.2.4-cxx0x.patch + + # Bug #594126, #629294 + "${FILESDIR}"/${PN}-2.2.6-decoder-lock-scope.patch + "${FILESDIR}"/${PN}-2.2.4-alsa-large-buffers.patch + + # Bug #593460 + "${FILESDIR}"/${PN}-2.2.4-libav-11.7.patch +) + +DOCS=( AUTHORS THANKS NEWS README doc/fortunes.txt doc/intf-vcd.txt ) + +S="${WORKDIR}/${MY_P}" + +src_unpack() { + if [[ ${PV} = *9999 ]] ; then + git-r3_src_unpack + else + unpack ${A} + fi +} + +src_prepare() { + default + + # Remove unnecessary warnings about unimplemented pragmas on gcc for now. + # Need to recheck this with gcc 4.9 and every subsequent minor bump of gcc. + # + # config.h:792: warning: ignoring #pragma STDC FENV_ACCESS [-Wunknown-pragmas] + # config.h:793: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas] + # + # https://gcc.gnu.org/c99status.html + if tc-is-gcc ; then + sed -i 's/ifndef __FAST_MATH__/if 0/g' configure.ac || die + fi + + # Bootstrap when we are on a git checkout. + if [[ ${PV} = *9999 ]] ; then + ./bootstrap + fi + + # Make it build with libtool 1.5 + rm -f m4/lt* m4/libtool.m4 || die + + # We are not in a real git checkout due to the absence of a .git directory. + touch src/revision.txt || die + + # Don't use --started-from-file when not using dbus. + if ! use dbus ; then + sed -i 's/ --started-from-file//' share/vlc.desktop.in || die + fi + + eautoreconf + + # Disable automatic running of tests. + find . -name 'Makefile.in' -exec sed -i 's/\(..*\)check-TESTS/\1/' {} \; || die + + # If qtchooser is installed, it may break the build, because moc,rcc and uic binaries for wrong qt + # version may be used. Setting QT_SELECT environment variable will enforce correct binaries. + if use qt5; then + export QT_SELECT=qt5 + elif use qt4; then + export QT_SELECT=qt4 + fi +} + +src_configure() { + local myconf + + # Compatibility fix for Samba 4. + use samba && append-cppflags "-I/usr/include/samba-4.0" + + # We need to disable -fstack-check if use >=gcc 4.8.0. bug #499996 + use x86 && append-cflags $(test-flags-CC -fno-stack-check) + + # FIXME: Needs libresid-builder from libsidplay:2 which is in another directory... + append-ldflags "-L/usr/$(get_libdir)/sidplay/builders/" + + if use truetype || use projectm ; then + local dejavu="/usr/share/fonts/dejavu/" + myconf="--with-default-font=${dejavu}/DejaVuSans.ttf \ + --with-default-font-family=Sans \ + --with-default-monospace-font=${dejavu}/DejaVuSansMono.ttf + --with-default-monospace-font-family=Monospace" + fi + + if use qt5 ; then + myconf+=" --enable-qt=5" + else + if use qt4 ; then + myconf+=" --enable-qt=4" + else + myconf+=" --disable-qt" + fi + use kde && myconf+=" --with-kde-solid" + fi + + econf \ + ${myconf} \ + --enable-vlc \ + --docdir=/usr/share/doc/${PF} \ + --disable-dependency-tracking \ + --disable-optimizations \ + --disable-update-check \ + --enable-fast-install \ + --enable-screen \ + $(use_enable a52) \ + $(use_enable aalib aa) \ + $(use_enable alsa) \ + $(use_enable altivec) \ + $(use_enable atmo) \ + $(use_enable audioqueue) \ + $(use_enable avcodec) \ + $(use_enable avformat) \ + $(use_enable bidi fribidi) \ + $(use_enable bluray) \ + $(use_enable cdda vcd) \ + $(use_enable cddb libcddb) \ + $(use_enable chromaprint) \ + $(use_enable dbus) \ + $(use_enable directfb) \ + $(use_enable directx) \ + $(use_enable dc1394) \ + $(use_enable debug) \ + $(use_enable dts dca) \ + $(use_enable dvbpsi) \ + $(use_enable dvd dvdread) $(use_enable dvd dvdnav) \ + $(use_enable dxva2) \ + $(use_enable encode sout) \ + $(use_enable faad) \ + $(use_enable fdk fdkaac) \ + $(use_enable flac) \ + $(use_enable fluidsynth) \ + $(use_enable fontconfig) \ + $(use_enable gcrypt libgcrypt) \ + $(use_enable gme) \ + $(use_enable gnome gnomevfs) \ + $(use_enable gnutls) \ + $(use_enable growl) \ + $(use_enable gstreamer gst-decode) \ + $(use_enable httpd) \ + $(use_enable ieee1394 dv1394) \ + $(use_enable jack) \ + $(use_enable jpeg) \ + $(use_enable kate) \ + $(use_enable libass) \ + $(use_enable libcaca caca) \ + $(use_enable libnotify notify) \ + $(use_enable libsamplerate samplerate) \ + $(use_enable libtar) \ + $(use_enable libtiger tiger) \ + $(use_enable linsys) \ + $(use_enable lirc) \ + $(use_enable live live555) \ + $(use_enable lua) \ + $(use_enable macosx-dialog-provider) \ + $(use_enable macosx-eyetv) \ + $(use_enable macosx-qtkit) \ + $(use_enable macosx-quartztext) \ + $(use_enable matroska mkv) \ + $(use_enable cpu_flags_x86_mmx mmx) \ + $(use_enable modplug mod) \ + $(use_enable mp3 mad) \ + $(use_enable mpeg libmpeg2) \ + $(use_enable mtp) \ + $(use_enable musepack mpc) \ + $(use_enable ncurses) \ + $(use_enable neon) \ + $(use_enable ogg) $(use_enable ogg mux_ogg) \ + $(use_enable omxil) \ + $(use_enable omxil omxil-vout) \ + $(use_enable opencv) \ + $(use_enable opengl glspectrum) \ + $(use_enable opus) \ + $(use_enable optimisememory optimize-memory) \ + $(use_enable png) \ + $(use_enable postproc) \ + $(use_enable projectm) \ + $(use_enable pulseaudio pulse) \ + $(use_enable rdp freerdp) \ + $(use_enable rtsp realrtsp) \ + $(use_enable run-as-root) \ + $(use_enable samba smbclient) \ + $(use_enable schroedinger) \ + $(use_enable sdl) \ + $(use_enable sdl-image) \ + $(use_enable sid) \ + $(use_enable sftp) \ + $(use_enable shout) \ + $(use_enable skins skins2) \ + $(use_enable speex) \ + $(use_enable cpu_flags_x86_sse sse) \ + $(use_enable svg) \ + $(use_enable svg svgdec) \ + $(use_enable swscale) \ + $(use_enable taglib) \ + $(use_enable theora) \ + $(use_enable tremor) \ + $(use_enable truetype freetype) \ + $(use_enable twolame) \ + $(use_enable udev) \ + $(use_enable upnp) \ + $(use_enable v4l v4l2) \ + $(use_enable vaapi libva) \ + $(use_enable vcdx) \ + $(use_enable vdpau) \ + $(use_enable vlm) \ + $(use_enable vnc) \ + $(use_enable vorbis) \ + $(use_enable vpx) \ + $(use_enable wma-fixed) \ + $(use_with X x) \ + $(use_enable x264) \ + $(use_enable x265) \ + $(use_enable xcb) \ + $(use_enable xml libxml2) \ + $(use_enable xv xvideo) \ + $(use_enable zeroconf bonjour) \ + $(use_enable zvbi) $(use_enable !zvbi telx) \ + --disable-asdcp \ + --disable-coverage \ + --disable-cprof \ + --disable-crystalhd \ + --disable-decklink \ + --disable-gles1 \ + --disable-gles2 \ + --disable-goom \ + --disable-kai \ + --disable-kva \ + --disable-maintainer-mode \ + --disable-merge-ffmpeg \ + --disable-mfx \ + --disable-mmal-codec \ + --disable-mmal-vout \ + --disable-opensles \ + --disable-oss \ + --disable-quicktime \ + --disable-rpi-omxil \ + --disable-shine \ + --disable-sndio \ + --disable-vda \ + --disable-vsxu \ + --disable-wasapi + + # ^ We don't have these disabled libraries in the Portage tree yet. + + # _FORTIFY_SOURCE is set to 2 in config.h, which is also the default value on Gentoo. + # Other values of _FORTIFY_SOURCE may break the build (bug 523144), so definition should not be removed from config.h. + # To prevent redefinition warnings, we undefine _FORTIFY_SOURCE at the very start of config.h file + sed -i '1i#undef _FORTIFY_SOURCE' "${S}"/config.h || die +} + +src_test() { + virtx emake check-TESTS +} + +src_install() { + default + find "${D}" -name '*.la' -delete || die +} + +pkg_postinst() { + if [[ "$ROOT" = "/" ]] && [[ -x "/usr/$(get_libdir)/vlc/vlc-cache-gen" ]] ; then + einfo "Running /usr/$(get_libdir)/vlc/vlc-cache-gen on /usr/$(get_libdir)/vlc/plugins/" + "/usr/$(get_libdir)/vlc/vlc-cache-gen" -f "/usr/$(get_libdir)/vlc/plugins/" + else + ewarn "We cannot run vlc-cache-gen (most likely ROOT!=/)" + ewarn "Please run /usr/$(get_libdir)/vlc/vlc-cache-gen manually" + ewarn "If you do not do it, vlc will take a long time to load." + fi +} diff --git a/media-video/vlc/vlc-9999.ebuild b/media-video/vlc/vlc-9999.ebuild new file mode 100644 index 000000000000..11808b476de3 --- /dev/null +++ b/media-video/vlc/vlc-9999.ebuild @@ -0,0 +1,458 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +MY_PV="${PV/_/-}" +MY_PV="${MY_PV/-beta/-test}" +MY_P="${PN}-${MY_PV}" +if [[ ${PV} = *9999 ]] ; then + if [[ ${PV%.9999} != ${PV} ]] ; then + EGIT_REPO_URI="https://git.videolan.org/git/vlc/vlc-${PV%.9999}.git" + else + EGIT_REPO_URI="https://git.videolan.org/git/vlc.git" + fi + SCM="git-r3" +else + if [[ ${MY_P} = ${P} ]] ; then + SRC_URI="https://download.videolan.org/pub/videolan/${PN}/${PV}/${P}.tar.xz" + else + SRC_URI="https://download.videolan.org/pub/videolan/testing/${MY_P}/${MY_P}.tar.xz" + fi + KEYWORDS="~amd64 ~arm ~arm64 ~ppc ~ppc64 -sparc ~x86 ~x86-fbsd" +fi +inherit autotools flag-o-matic toolchain-funcs versionator virtualx ${SCM} + +DESCRIPTION="VLC media player - Video player and streamer" +HOMEPAGE="https://www.videolan.org/vlc/" + +LICENSE="LGPL-2.1 GPL-2" +SLOT="0/5-8" # vlc - vlccore + +IUSE="a52 aalib alsa altivec +audioqueue +avcodec +avformat bidi bluray cddb + chromaprint chromecast dbus dc1394 debug directfb directx dts dvb +dvbpsi dvd + dxva2 elibc_glibc +encode faad fdk fluidsynth +ffmpeg flac fontconfig +gcrypt + gme gnutls gstreamer httpd ieee1394 jack jpeg kate kde libass libav libcaca + libnotify +libsamplerate libtiger linsys libtar lirc live lua macosx-eyetv + macosx-notifications macosx-qtkit matroska cpu_flags_x86_mmx modplug mp3 + mpeg mtp musepack ncurses neon ogg omxil opencv opengl optimisememory opus + png postproc projectm pulseaudio qt4 +qt5 rdp rtsp run-as-root samba + schroedinger sdl sdl-image sftp shout sid skins speex cpu_flags_x86_sse svg + +swscale taglib theora tremor truetype twolame udev upnp vaapi v4l vcd vdpau + vlm vnc vorbis vpx wma-fixed +X x264 x265 +xcb xml xv zeroconf zvbi +" +REQUIRED_USE=" + aalib? ( X ) + bidi? ( truetype ) + dvb? ( dvbpsi ) + dxva2? ( avcodec ) + ffmpeg? ( avcodec avformat swscale ) + fontconfig? ( truetype ) + gnutls? ( gcrypt ) + httpd? ( lua ) + libcaca? ( X ) + libtar? ( skins ) + libtiger? ( kate ) + qt4? ( X ) + qt5? ( X ) + sdl? ( X ) + skins? ( truetype X xml || ( qt4 qt5 ) ) + vaapi? ( avcodec X ) + vdpau? ( X ) + vlm? ( encode ) + xv? ( xcb ) +" +RDEPEND=" + dev-libs/libgpg-error:0 + net-dns/libidn:0 + sys-libs/zlib:0[minizip] + virtual/libintl:0 + a52? ( >=media-libs/a52dec-0.7.4-r3:0 ) + aalib? ( media-libs/aalib:0 ) + alsa? ( >=media-libs/alsa-lib-1.0.24:0 ) + avcodec? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + avformat? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + bidi? ( dev-libs/fribidi:0 ) + bluray? ( >=media-libs/libbluray-0.6.2:0= ) + cddb? ( >=media-libs/libcddb-1.2:0 ) + chromaprint? ( >=media-libs/chromaprint-0.6:0 ) + chromecast? ( >=dev-libs/protobuf-2.5.0 ) + dbus? ( >=sys-apps/dbus-1.6:0 ) + dc1394? ( >=sys-libs/libraw1394-2.0.1:0 >=media-libs/libdc1394-2.1:2 ) + directfb? ( dev-libs/DirectFB:0 sys-libs/zlib:0 ) + dts? ( >=media-libs/libdca-0.0.5:0 ) + dvbpsi? ( >=media-libs/libdvbpsi-1.2.0:0= ) + dvd? ( >=media-libs/libdvdread-4.9:0 >=media-libs/libdvdnav-4.9:0 ) + elibc_glibc? ( >=sys-libs/glibc-2.8:2.2 ) + faad? ( >=media-libs/faad2-2.6.1:0 ) + fdk? ( media-libs/fdk-aac:0 ) + flac? ( >=media-libs/libogg-1:0 >=media-libs/flac-1.1.2:0 ) + fluidsynth? ( >=media-sound/fluidsynth-1.1.2:0 ) + fontconfig? ( media-libs/fontconfig:1.0 ) + gcrypt? ( >=dev-libs/libgcrypt-1.6.0:0= ) + gme? ( media-libs/game-music-emu:0 ) + gnutls? ( >=net-libs/gnutls-3.2.0:0 ) + gstreamer? ( >=media-libs/gst-plugins-base-1.4.5:1.0 ) + ieee1394? ( >=sys-libs/libraw1394-2.0.1:0 >=sys-libs/libavc1394-0.5.3:0 ) + jack? ( virtual/jack ) + jpeg? ( virtual/jpeg:0 ) + kate? ( >=media-libs/libkate-0.3:0 ) + libass? ( >=media-libs/libass-0.9.8:0= media-libs/fontconfig:1.0 ) + libcaca? ( >=media-libs/libcaca-0.99_beta14:0 ) + libnotify? ( x11-libs/libnotify:0 x11-libs/gtk+:2 x11-libs/gdk-pixbuf:2 dev-libs/glib:2 ) + libsamplerate? ( media-libs/libsamplerate:0 ) + libtar? ( >=dev-libs/libtar-1.2.11-r3:0 ) + libtiger? ( >=media-libs/libtiger-0.3.1:0 ) + linsys? ( >=media-libs/zvbi-0.2.28:0 ) + lirc? ( app-misc/lirc:0 ) + live? ( >=media-plugins/live-2011.12.23:0 ) + lua? ( >=dev-lang/lua-5.1:0 ) + matroska? ( >=dev-libs/libebml-1:0= >=media-libs/libmatroska-1:0= ) + modplug? ( >=media-libs/libmodplug-0.8.4:0 !~media-libs/libmodplug-0.8.8 ) + mp3? ( media-libs/libmad:0 ) + mpeg? ( >=media-libs/libmpeg2-0.3.2:0 ) + mtp? ( >=media-libs/libmtp-1:0 ) + musepack? ( >=media-sound/musepack-tools-444:0 ) + ncurses? ( sys-libs/ncurses:0=[unicode] ) + ogg? ( >=media-libs/libogg-1:0 ) + opencv? ( >media-libs/opencv-2:0= ) + opengl? ( virtual/opengl:0 >=x11-libs/libX11-1.3.99.901:0 ) + opus? ( >=media-libs/opus-1.0.3:0 ) + png? ( media-libs/libpng:0= sys-libs/zlib:0 ) + postproc? ( + !libav? ( >=media-video/ffmpeg-3.1.3:0= ) + libav? ( media-libs/libpostproc:0= ) + ) + projectm? ( media-libs/libprojectm:0 media-fonts/dejavu:0 ) + pulseaudio? ( >=media-sound/pulseaudio-1:0 ) + !qt5? ( qt4? ( dev-qt/qtcore:4 dev-qt/qtgui:4 ) ) + qt5? ( dev-qt/qtcore:5 dev-qt/qtgui:5 dev-qt/qtwidgets:5 dev-qt/qtx11extras:5 ) + rdp? ( =net-misc/freerdp-1*:0=[client] ) + samba? ( >=net-fs/samba-4.0.0_alpha1:0[client] ) + schroedinger? ( >=media-libs/schroedinger-1.0.10:0 ) + sdl? ( >=media-libs/libsdl-1.2.10:0 + sdl-image? ( >=media-libs/sdl-image-1.2.10:0 sys-libs/zlib:0 ) ) + sftp? ( net-libs/libssh2:0 ) + shout? ( >=media-libs/libshout-2.1:0 ) + sid? ( media-libs/libsidplay:2 ) + skins? ( x11-libs/libXext:0 x11-libs/libXpm:0 x11-libs/libXinerama:0 ) + speex? ( >=media-libs/speex-1.2.0:0 media-libs/speexdsp:0 ) + svg? ( >=gnome-base/librsvg-2.9:2 >=x11-libs/cairo-1.13.1:0 ) + swscale? ( + !libav? ( media-video/ffmpeg:0= ) + libav? ( media-video/libav:0= ) + ) + taglib? ( >=media-libs/taglib-1.9:0 sys-libs/zlib:0 ) + theora? ( >=media-libs/libtheora-1.0_beta3:0 ) + tremor? ( media-libs/tremor:0 ) + truetype? ( media-libs/freetype:2 virtual/ttf-fonts:0 + !fontconfig? ( media-fonts/dejavu:0 ) ) + twolame? ( media-sound/twolame:0 ) + udev? ( >=virtual/udev-142:0 ) + upnp? ( net-libs/libupnp:0 ) + v4l? ( media-libs/libv4l:0 ) + vaapi? ( + x11-libs/libva:0[X,drm] + !libav? ( >=media-video/ffmpeg-3.1.3:0=[vaapi] ) + libav? ( media-video/libav:0=[vaapi] ) + ) + vcd? ( >=dev-libs/libcdio-0.78.2:0 ) + vdpau? ( + x11-libs/libvdpau:0 + !libav? ( media-video/ffmpeg:0= ) + libav? ( >=media-video/libav-10:0= ) + ) + vnc? ( >=net-libs/libvncserver-0.9.9:0 ) + vorbis? ( media-libs/libvorbis:0 ) + vpx? ( media-libs/libvpx:0= ) + X? ( x11-libs/libX11:0 ) + x264? ( media-libs/x264:0= ) + x265? ( media-libs/x265:0= ) + xcb? ( x11-libs/libxcb:0 x11-libs/xcb-util:0 x11-libs/xcb-util-keysyms:0 ) + xml? ( dev-libs/libxml2:2 ) + zeroconf? ( >=net-dns/avahi-0.6:0[dbus] ) + zvbi? ( media-libs/zvbi:0 ) +" +DEPEND="${RDEPEND} + app-arch/xz-utils:0 + >=sys-devel/gettext-0.19.6:* + virtual/pkgconfig:* + !qt5? ( kde? ( kde-frameworks/kdelibs:4 ) ) + amd64? ( dev-lang/yasm:* ) + x86? ( dev-lang/yasm:* ) + xcb? ( x11-proto/xproto:0 ) +" + +PATCHES=( + # Fix build system mistake. + "${FILESDIR}"/${PN}-2.1.0-fix-libtremor-libs.patch + + # Patch up incompatibilities and reconfigure autotools. + "${FILESDIR}"/${PN}-9999-libva-1.2.1-compat.patch + + # Fix up broken audio when skipping using a fixed reversed bisected commit. + "${FILESDIR}"/${PN}-2.1.0-TomWij-bisected-PA-broken-underflow.patch + + # Bug #593460 + "${FILESDIR}"/${PN}-2.2.4-libav-11.7.patch +) + +DOCS=( AUTHORS THANKS NEWS README doc/fortunes.txt ) + +S="${WORKDIR}/${MY_P}" + +src_unpack() { + if [[ ${PV} = *9999 ]] ; then + git-r3_src_unpack + else + unpack ${A} + fi +} + +src_prepare() { + default + + # Remove unnecessary warnings about unimplemented pragmas on gcc for now. + # Need to recheck this with gcc 4.9 and every subsequent minor bump of gcc. + # + # config.h:792: warning: ignoring #pragma STDC FENV_ACCESS [-Wunknown-pragmas] + # config.h:793: warning: ignoring #pragma STDC FP_CONTRACT [-Wunknown-pragmas] + # + # https://gcc.gnu.org/c99status.html + if tc-is-gcc ; then + sed -i 's/ifndef __FAST_MATH__/if 0/g' configure.ac || die + fi + + # Bootstrap when we are on a git checkout. + if [[ ${PV} = *9999 ]] ; then + ./bootstrap + fi + + # Make it build with libtool 1.5 + rm -f m4/lt* m4/libtool.m4 || die + + # We are not in a real git checkout due to the absence of a .git directory. + touch src/revision.txt || die + + # Don't use --started-from-file when not using dbus. + if ! use dbus ; then + sed -i 's/ --started-from-file//' share/vlc.desktop.in || die + fi + + eautoreconf + + # Disable automatic running of tests. + find . -name 'Makefile.in' -exec sed -i 's/\(..*\)check-TESTS/\1/' {} \; || die + + # If qtchooser is installed, it may break the build, because moc,rcc and uic binaries for wrong qt + # version may be used. Setting QT_SELECT environment variable will enforce correct binaries. + if use qt5; then + export QT_SELECT=qt5 + elif use qt4; then + export QT_SELECT=qt4 + fi +} + +src_configure() { + local myconf + + # Compatibility fix for Samba 4. + use samba && append-cppflags "-I/usr/include/samba-4.0" + + # We need to disable -fstack-check if use >=gcc 4.8.0. bug #499996 + use x86 && append-cflags $(test-flags-CC -fno-stack-check) + + # VLC now requires C++11 after commit 4b1c9dcdda0bbff801e47505ff9dfd3f274eb0d8 + append-cxxflags -std=c++11 + + # FIXME: Needs libresid-builder from libsidplay:2 which is in another directory... + append-ldflags "-L/usr/$(get_libdir)/sidplay/builders/" + + if use truetype || use projectm ; then + local dejavu="/usr/share/fonts/dejavu/" + myconf="--with-default-font=${dejavu}/DejaVuSans.ttf \ + --with-default-font-family=Sans \ + --with-default-monospace-font=${dejavu}/DejaVuSansMono.ttf + --with-default-monospace-font-family=Monospace" + fi + + if use qt4 || use qt5 ; then + myconf+=" --enable-qt" + fi + + if ! use qt5 && use kde ; then + myconf+=" --with-kde-solid" + fi + + econf \ + ${myconf} \ + --enable-vlc \ + --docdir=/usr/share/doc/${PF} \ + --disable-dependency-tracking \ + --disable-optimizations \ + --disable-update-check \ + --enable-fast-install \ + --enable-screen \ + $(use_enable a52) \ + $(use_enable aalib aa) \ + $(use_enable alsa) \ + $(use_enable altivec) \ + $(use_enable audioqueue) \ + $(use_enable avcodec) \ + $(use_enable avformat) \ + $(use_enable bidi fribidi) \ + $(use_enable bluray) \ + $(use_enable cddb libcddb) \ + $(use_enable chromaprint) \ + $(use_enable chromecast) \ + $(use_enable dbus) \ + $(use_enable directfb) \ + $(use_enable directx) \ + $(use_enable dc1394) \ + $(use_enable debug) \ + $(use_enable dts dca) \ + $(use_enable dvbpsi) \ + $(use_enable dvd dvdread) $(use_enable dvd dvdnav) \ + $(use_enable dxva2) \ + $(use_enable encode sout) \ + $(use_enable faad) \ + $(use_enable fdk fdkaac) \ + $(use_enable flac) \ + $(use_enable fluidsynth) \ + $(use_enable fontconfig) \ + $(use_enable gcrypt libgcrypt) \ + $(use_enable gme) \ + $(use_enable gnutls) \ + $(use_enable gstreamer gst-decode) \ + $(use_enable httpd) \ + $(use_enable ieee1394 dv1394) \ + $(use_enable jack) \ + $(use_enable jpeg) \ + $(use_enable kate) \ + $(use_enable libass) \ + $(use_enable libcaca caca) \ + $(use_enable libnotify notify) \ + $(use_enable libsamplerate samplerate) \ + $(use_enable libtar) \ + $(use_enable libtiger tiger) \ + $(use_enable linsys) \ + $(use_enable lirc) \ + $(use_enable live live555) \ + $(use_enable lua) \ + $(use_enable macosx-eyetv) \ + $(use_enable macosx-notifications osx-notifications) \ + $(use_enable macosx-qtkit) \ + $(use_enable cpu_flags_x86_mmx mmx) \ + $(use_enable modplug mod) \ + $(use_enable mp3 mad) \ + $(use_enable mpeg libmpeg2) \ + $(use_enable mtp) \ + $(use_enable musepack mpc) \ + $(use_enable ncurses) \ + $(use_enable neon) \ + $(use_enable ogg) $(use_enable ogg) \ + $(use_enable omxil) \ + $(use_enable omxil omxil-vout) \ + $(use_enable opencv) \ + $(use_enable opus) \ + $(use_enable optimisememory optimize-memory) \ + $(use_enable png) \ + $(use_enable postproc) \ + $(use_enable projectm) \ + $(use_enable pulseaudio pulse) \ + $(use_enable rdp freerdp) \ + $(use_enable rtsp realrtsp) \ + $(use_enable run-as-root) \ + $(use_enable samba smbclient) \ + $(use_enable schroedinger) \ + $(use_enable sdl) \ + $(use_enable sdl-image) \ + $(use_enable sid) \ + $(use_enable sftp) \ + $(use_enable shout) \ + $(use_enable skins skins2) \ + $(use_enable speex) \ + $(use_enable cpu_flags_x86_sse sse) \ + $(use_enable svg) \ + $(use_enable svg svgdec) \ + $(use_enable swscale) \ + $(use_enable taglib) \ + $(use_enable theora) \ + $(use_enable tremor) \ + $(use_enable truetype freetype) \ + $(use_enable twolame) \ + $(use_enable udev) \ + $(use_enable upnp) \ + $(use_enable v4l v4l2) \ + $(use_enable vaapi libva) \ + $(use_enable vcd) \ + $(use_enable vdpau) \ + $(use_enable vlm) \ + $(use_enable vnc) \ + $(use_enable vorbis) \ + $(use_enable vpx) \ + $(use_enable wma-fixed) \ + $(use_with X x) \ + $(use_enable x264) \ + $(use_enable xcb) \ + $(use_enable xml libxml2) \ + $(use_enable xv xvideo) \ + $(use_enable x265) \ + $(use_enable zeroconf avahi) \ + $(use_enable zvbi) $(use_enable !zvbi telx) \ + --disable-asdcp \ + --disable-coverage \ + --disable-cprof \ + --disable-crystalhd \ + --disable-decklink \ + --disable-gles1 \ + --disable-gles2 \ + --disable-goom \ + --disable-kai \ + --disable-kva \ + --disable-maintainer-mode \ + --disable-merge-ffmpeg \ + --disable-mfx \ + --disable-mmal \ + --disable-opensles \ + --disable-oss \ + --disable-rpi-omxil \ + --disable-shine \ + --disable-sndio \ + --disable-vda \ + --disable-vsxu \ + --disable-wasapi + + # ^ We don't have these disabled libraries in the Portage tree yet. + + # _FORTIFY_SOURCE is set to 2 in config.h, which is also the default value on Gentoo. + # Other values of _FORTIFY_SOURCE may break the build (bug 523144), so definition should not be removed from config.h. + # To prevent redefinition warnings, we undefine _FORTIFY_SOURCE at the very start of config.h file + sed -i '1i#undef _FORTIFY_SOURCE' "${S}"/config.h || die +} + +src_test() { + virtx emake check-TESTS +} + +src_install() { + default + find "${D}" -name '*.la' -delete || die +} + +pkg_postinst() { + if [[ "$ROOT" = "/" ]] && [[ -x "/usr/$(get_libdir)/vlc/vlc-cache-gen" ]] ; then + einfo "Running /usr/$(get_libdir)/vlc/vlc-cache-gen on /usr/$(get_libdir)/vlc/plugins/" + "/usr/$(get_libdir)/vlc/vlc-cache-gen" -f "/usr/$(get_libdir)/vlc/plugins/" + else + ewarn "We cannot run vlc-cache-gen (most likely ROOT!=/)" + ewarn "Please run /usr/$(get_libdir)/vlc/vlc-cache-gen manually" + ewarn "If you do not do it, vlc will take a long time to load." + fi +} |