--- dvswitch-0.8.3.6.orig/CMakeLists.txt +++ dvswitch-0.8.3.6/CMakeLists.txt @@ -19,6 +19,13 @@ message(FATAL_ERROR "Could not find Boost.Thread library") endif(NOT BOOST_THREAD_LIBRARIES) +find_library(BOOST_SYSTEM_LIBRARIES + NAMES boost_system-mt boost_system + NO_SYSTEM_ENVIRONMENT_PATH) +if(NOT BOOST_SYSTEM_LIBRARIES) + message(FATAL_ERROR "Could not find Boost.System library") +endif(NOT BOOST_SYSTEM_LIBRARIES) + # Cope with recent move of ffmpeg headers into subdirectories set(LIBAVCODEC_INCLUDE_DIRS ${LIBAVCODEC_INCLUDE_DIRS} ${LIBAVCODEC_INCLUDEDIR}/libavcodec) --- dvswitch-0.8.3.6.orig/src/avcodec_wrap.h +++ dvswitch-0.8.3.6/src/avcodec_wrap.h @@ -20,6 +20,7 @@ #endif #include +#include #if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(52, 26, 0) static inline int --- dvswitch-0.8.3.6.orig/src/CMakeLists.txt +++ dvswitch-0.8.3.6/src/CMakeLists.txt @@ -26,7 +26,7 @@ frame.c auto_codec.cpp format_dialog.cpp dif_audio.c vu_meter.cpp status_overlay.cpp ${common_sources}) target_link_libraries(dvswitch m pthread rt X11 Xext Xv - ${BOOST_THREAD_LIBRARIES} ${GTKMM_LIBRARIES} ${LIBAVCODEC_LIBRARIES} + ${BOOST_THREAD_LIBRARIES} ${BOOST_SYSTEM_LIBRARIES} ${GTKMM_LIBRARIES} ${LIBAVCODEC_LIBRARIES} ${LIBAVUTIL_LIBRARIES}) install(TARGETS dvsink-command dvsink-files dvsource-file dvsource-dvgrab --- dvswitch-0.8.3.6.orig/src/auto_codec.cpp +++ dvswitch-0.8.3.6/src/auto_codec.cpp @@ -16,7 +16,6 @@ { avcodec_initialiser() { - avcodec_init(); avcodec_register_all(); } } initialiser; @@ -24,7 +23,7 @@ auto_codec auto_codec_open_decoder(CodecID codec_id) { - auto_codec result(avcodec_alloc_context()); + auto_codec result(avcodec_alloc_context3(NULL)); if (!result.get()) throw std::bad_alloc(); auto_codec_open_decoder(result, codec_id); @@ -37,12 +36,12 @@ AVCodec * codec = avcodec_find_decoder(codec_id); if (!codec) throw os_error("avcodec_find_decoder", ENOENT); - os_check_error("avcodec_open", -avcodec_open(context.get(), codec)); + os_check_error("avcodec_open", -avcodec_open2(context.get(), codec, NULL)); } auto_codec auto_codec_open_encoder(CodecID codec_id) { - auto_codec result(avcodec_alloc_context()); + auto_codec result(avcodec_alloc_context3(NULL)); if (!result.get()) throw std::bad_alloc(); auto_codec_open_encoder(result, codec_id); @@ -55,7 +54,7 @@ AVCodec * codec = avcodec_find_encoder(codec_id); if (!codec) throw os_error("avcodec_find_encoder", ENOENT); - os_check_error("avcodec_open", -avcodec_open(context.get(), codec)); + os_check_error("avcodec_open", -avcodec_open2(context.get(), codec, NULL)); } void auto_codec_closer::operator()(AVCodecContext * context) const --- dvswitch-0.8.3.6.orig/src/dv_display_widget.cpp +++ dvswitch-0.8.3.6/src/dv_display_widget.cpp @@ -84,7 +84,7 @@ // dv_display_widget dv_display_widget::dv_display_widget(int lowres) - : decoder_(avcodec_alloc_context()), + : decoder_(avcodec_alloc_context3(NULL)), decoded_serial_num_(-1), shm_busy_(false) { --- dvswitch-0.8.3.6.orig/src/mixer.cpp +++ dvswitch-0.8.3.6/src/mixer.cpp @@ -623,7 +623,7 @@ dec->release_buffer = raw_frame_release_buffer; dec->reget_buffer = raw_frame_reget_buffer; - auto_codec encoder(avcodec_alloc_context()); + auto_codec encoder(avcodec_alloc_context3(NULL)); AVCodecContext * enc = encoder.get(); if (!enc) throw std::bad_alloc(); @@ -633,21 +633,18 @@ enc->width = 720; enc->height = 576; enc->pix_fmt = PIX_FMT_YUV420P; - auto_codec_open_encoder(encoder, CODEC_ID_DVVIDEO); { // Try to use one thread per CPU, up to a limit of 8 int enc_thread_count = std::min(8, std::max(sysconf(_SC_NPROCESSORS_ONLN), 1)); - if (enc_thread_count >= 2 && avcodec_thread_init(enc, enc_thread_count)) - { - std::cerr << "WARN: avcodec_thread_init(" - << enc_thread_count << ") failed\n"; - enc_thread_count = 1; - } + + enc->thread_count = enc_thread_count; std::cout << "INFO: DV encoder threads: " << enc_thread_count << "\n"; } + auto_codec_open_encoder(encoder, CODEC_ID_DVVIDEO); + for (;;) { // Get the next set of source frames and mix settings (or stop --- dvswitch-0.8.3.6.orig/tests/CMakeLists.txt +++ dvswitch-0.8.3.6/tests/CMakeLists.txt @@ -5,7 +5,7 @@ add_executable(mixer mixer.cpp ../src/mixer.cpp ../src/frame_timer.c ../src/dif.c ../src/dif_audio.c ../src/frame_pool.cpp ../src/auto_codec.cpp ../src/frame.c ../src/os_error.cpp ../src/video_effect.c) -target_link_libraries(mixer pthread rt ${BOOST_THREAD_LIBRARIES} +target_link_libraries(mixer pthread rt ${BOOST_THREAD_LIBRARIES} ${BOOST_SYSTEM_LIBRARIES} ${LIBAVCODEC_LIBRARIES} ${LIBAVUTIL_LIBRARIES}) add_executable(ring_buffer ring_buffer.cpp) --- dvswitch-0.8.3.6.orig/tests/pic_in_pic.cpp +++ dvswitch-0.8.3.6/tests/pic_in_pic.cpp @@ -268,7 +268,6 @@ int main() { - avcodec_init(); avcodec_register_all(); test_format(PIX_FMT_YUV420P); test_format(PIX_FMT_YUV411P); --- dvswitch-0.8.3.6.orig/debian/copyright +++ dvswitch-0.8.3.6/debian/copyright @@ -0,0 +1,12 @@ +This is the Debian package of DVswitch, put together by Ben Hutchings +. + +It is based on source from http://alioth.debian.org/projects/dvswitch/ + +DVswitch is: +Copyright 2005-2009 Ben Hutchings +Copyright 2008 Petter Reinholdtsen + +DVswitch is licensed under the GNU General Public License (GPL), +version 2 or later. On Debian systems the text of the GPL can be +found in /usr/share/common-licenses/GPL --- dvswitch-0.8.3.6.orig/debian/dvsource.install +++ dvswitch-0.8.3.6/debian/dvsource.install @@ -0,0 +1,2 @@ +usr/bin/dvsource-* +usr/share/man/man1/dvsource-*.1 --- dvswitch-0.8.3.6.orig/debian/dvsink.install +++ dvswitch-0.8.3.6/debian/dvsink.install @@ -0,0 +1,2 @@ +usr/bin/dvsink-* +usr/share/man/man1/dvsink-*.1 --- dvswitch-0.8.3.6.orig/debian/changelog +++ dvswitch-0.8.3.6/debian/changelog @@ -0,0 +1,165 @@ +dvswitch (0.8.3.6-1.2build1) trusty; urgency=low + + * No change rebuild against libav 9. + + -- Dmitrijs Ledkovs Mon, 11 Nov 2013 02:01:44 +0000 + +dvswitch (0.8.3.6-1.2) unstable; urgency=low + + * Non-maintainer upload. + + [ Reinhard Tartler ] + * Fix compilation against libav9, closes: #720783 + + [ Sebastian Ramacher ] + * debian/control: Bump libavcodec-dev B-D to >= 6:9 since the changes to + build with libav9 are not backwards compatible. + + -- Sebastian Ramacher Thu, 03 Oct 2013 19:01:13 +0200 + +dvswitch (0.8.3.6-1.1) unstable; urgency=low + + * Non-maintainer upload. + * Depend on gnome-icon-theme - closes: #663095 + * Fix typo in package description - closes: #557465 + * Add boost-system dependency for boost 1.53 transition. + * Patch CMake to look for boost-system and link against it. - closes: #709251 + + -- Dmitrijs Ledkovs Fri, 05 Jul 2013 23:10:31 +0100 + +dvswitch (0.8.3.6-1) unstable; urgency=low + + * New upstream version + - Fix build failure with ffmpeg 0.7 - closes: #633717 + + -- Ben Hutchings Fri, 15 Jul 2011 21:54:51 +0100 + +dvswitch (0.8.3.5-1) unstable; urgency=low + + * New upstream version + - Fix build failure with binutils-gold or ffmpeg 0.6.1 - closes: #554310 + + -- Ben Hutchings Thu, 24 Feb 2011 04:07:52 +0000 + +dvswitch (0.8.3.4-1) unstable; urgency=low + + * New upstream version + - Fix build failure with ffmpeg 0.6 - closes: #587074; LP: #598118 + + -- Ben Hutchings Fri, 25 Jun 2010 12:09:18 +0100 + +dvswitch (0.8.3.3-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Fri, 05 Feb 2010 13:40:26 +0100 + +dvswitch (0.8.3.2-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Thu, 23 Jul 2009 15:12:55 +0200 + +dvswitch (0.8.3.1-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Thu, 09 Jul 2009 22:00:19 +0100 + +dvswitch (0.8.3-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Sun, 28 Jun 2009 20:50:06 +0100 + +dvswitch (0.8.2-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Thu, 26 Mar 2009 22:45:28 -0500 + +dvswitch (0.8.1-1) unstable; urgency=low + + * New upstream version + - Adds missing #include directive - closes: #519211 + * Update archive section to 'video' + + -- Ben Hutchings Tue, 17 Mar 2009 01:06:23 +0000 + +dvswitch (0.8-2) unstable; urgency=low + + * Initial upload to Debian - closes: #467414 + + -- Ben Hutchings Wed, 18 Feb 2009 02:32:18 +0000 + +dvswitch (0.8-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Wed, 04 Feb 2009 23:16:25 +0000 + +dvswitch (0.8~rc1-1) unstable; urgency=low + + * New upstream release candidate + + -- Ben Hutchings Tue, 27 Jan 2009 01:04:54 +0000 + +dvswitch (0.7-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Sun, 20 Apr 2008 22:18:46 +0100 + +dvswitch (0.6.2-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Sun, 24 Feb 2008 01:50:12 +0100 + +dvswitch (0.6.1-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Thu, 21 Feb 2008 22:21:40 +0000 + +dvswitch (0.6-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Tue, 19 Feb 2008 09:37:32 +0000 + +dvswitch (0.5.1-1) unstable; urgency=low + + * New upstream version + + -- Ben Hutchings Sun, 10 Jun 2007 21:41:21 +0100 + +dvswitch (0.5.0-1) etch-backports; urgency=low + + * New upstream version + + -- Ben Hutchings Mon, 30 Apr 2007 02:23:43 +0100 + +dvswitch (0.4-1) etch-backports; urgency=low + + * New upstream version + + -- Ben Hutchings Sun, 15 Apr 2007 16:28:09 +0100 + +dvswitch (0.3-1) etch-backports; urgency=low + + * New upstream version + + -- Ben Hutchings Tue, 10 Apr 2007 01:59:38 +0100 + +dvswitch (0.2-1) testing; urgency=low + + * New upstream version + + -- Ben Hutchings Fri, 6 Apr 2007 00:54:25 +0100 + +dvswitch (0.1-1) testing; urgency=low + + * Initial release + + -- Ben Hutchings Mon, 2 Apr 2007 03:18:16 +0100 --- dvswitch-0.8.3.6.orig/debian/dvswitch.install +++ dvswitch-0.8.3.6/debian/dvswitch.install @@ -0,0 +1,3 @@ +usr/bin/dvswitch* +usr/share/dvswitch +usr/share/man/man1/dvswitch*.1 --- dvswitch-0.8.3.6.orig/debian/control +++ dvswitch-0.8.3.6/debian/control @@ -0,0 +1,49 @@ +Source: dvswitch +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Ben Hutchings +Section: video +Priority: extra +Build-Depends: debhelper (>= 5), libasound2-dev, libavcodec-dev, pkg-config, libgtkmm-2.4-dev, libboost-dev, libboost-system-dev, libboost-thread-dev, libxv-dev, cmake +Standards-Version: 3.8.0 +Vcs-Browser: http://svn.debian.org/wsvn/dvswitch/trunk/ +Vcs-Svn: svn://svn.debian.org/svn/dvswitch/trunk +Homepage: http://dvswitch.alioth.debian.org/ + +Package: dvswitch +Architecture: any +Depends: ${shlibs:Depends}, gnome-icon-theme +Suggests: dvsink, dvsource +Description: basic video mixer for live DV streams + dvswitch is a very basic video mixer that receives DV streams from + sources and sends a DV stream to sinks over a TCP/IP network. It has + a graphical interface in which all source streams can be viewed and + selected from. + . + It is intended to be used for live editing at conferences. + +Package: dvsource +Architecture: any +Depends: ${shlibs:Depends}, dvgrab +Description: programs to provide source streams for dvswitch + This package provides sources for dvswitch: + . + dvsource-alsa captures audio from an ALSA device. + . + dvsource-file reads DV frames from a file and sends them at the + normal frame rate. + . + dvsource-firewire reads DV frames from a camera or other device + connected by Firewire (1394). + . + dvsource-v4l2-dv reads DV frames from a Video4Linux2 device such + as a USB-connected DV camera. + +Package: dvsink +Architecture: any +Depends: ${shlibs:Depends} +Description: programs to sink streams from dvswitch + This package provides two sinks for dvswitch: + . + dvsink-command runs a command with the DV stream on its standard input. + . + dvsink-files stores DV frames in files named according to a pattern. --- dvswitch-0.8.3.6.orig/debian/rules +++ dvswitch-0.8.3.6/debian/rules @@ -0,0 +1,44 @@ +#!/usr/bin/make -f + +export CFLAGS := -g +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) +CFLAGS += -O0 +else +CFLAGS += -O2 +endif +export CXXFLAGS := $(CFLAGS) + +build : build/Makefile + make -C build + +build/Makefile : + mkdir -p build + cd build && cmake -D prefix=/usr .. + +install-stamp : build + dh_testroot + make -C build DESTDIR=$$(pwd)/debian/tmp install + touch install-stamp + +binary : binary-arch binary-indep + +binary-arch : install-stamp + dh_install -a --sourcedir=debian/tmp + dh_strip + dh_shlibdeps + dh_installchangelogs -a ChangeLog + dh_installdocs -a -A doc/README + dh_compress -a + dh_fixperms -a + dh_installdeb -a + dh_gencontrol -a + dh_md5sums -a + dh_builddeb -a + +binary-indep : + +clean : + rm -rf build + dh_clean install-stamp + +.PHONY : build binary binary-arch binary-indep clean --- dvswitch-0.8.3.6.orig/debian/compat +++ dvswitch-0.8.3.6/debian/compat @@ -0,0 +1 @@ +5