[packages/mjpegtools] - build fix, release 5
qboosh
qboosh at pld-linux.org
Tue Jun 2 20:53:15 CEST 2026
commit cbc738690885bf3fb61b78fbd814eb9af1660f48
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Tue Jun 2 20:53:28 2026 +0200
- build fix, release 5
mjpegtools-dead-code.patch | 272 +++++++++++++++++++++++++++++++++++++++++++++
mjpegtools.spec | 4 +-
2 files changed, 275 insertions(+), 1 deletion(-)
---
diff --git a/mjpegtools.spec b/mjpegtools.spec
index 1d60d12..8228f23 100644
--- a/mjpegtools.spec
+++ b/mjpegtools.spec
@@ -10,13 +10,14 @@ Summary: Tools for recording, editing, playing back and MPEG-encoding video unde
Summary(pl.UTF-8): Narzędzia do nagrywania, edycji, odtwarzania i kodowania do MPEG obrazu
Name: mjpegtools
Version: 2.2.1
-Release: 4
+Release: 5
License: GPL v2+
Group: Applications/Graphics
Source0: https://downloads.sourceforge.net/mjpeg/%{name}-%{version}.tar.gz
# Source0-md5: 168e0131c0b8a2e31df7a73eb602fc32
Patch0: %{name}-pthread.patch
Patch1: x32.patch
+Patch2: %{name}-dead-code.patch
URL: https://mjpeg.sourceforge.io/
BuildRequires: SDL-devel >= 1.1.3
BuildRequires: SDL_gfx-devel
@@ -103,6 +104,7 @@ Statyczne biblioteki mjpegtools.
%setup -q
%patch -P0 -p1
%patch -P1 -p1
+%patch -P2 -p1
%build
%{__libtoolize}
diff --git a/mjpegtools-dead-code.patch b/mjpegtools-dead-code.patch
new file mode 100644
index 0000000..58244a1
--- /dev/null
+++ b/mjpegtools-dead-code.patch
@@ -0,0 +1,272 @@
+Remove dead code referring to previously removed methods.
+--- mjpegtools-2.2.1/y4mdenoise/Region2D.hh.orig 2021-09-05 08:14:13.037372932 +0200
++++ mjpegtools-2.2.1/y4mdenoise/Region2D.hh 2026-06-02 20:17:31.361770418 +0200
+@@ -404,85 +404,6 @@ Region2D<INDEX,SIZE>::~Region2D()
+
+
+
+-// Add the given horizontal extent to the region.
+-template <class INDEX, class SIZE>
+-template <class REGION, class REGION_TEMP>
+-void
+-Region2D<INDEX,SIZE>::UnionDebug (Status_t &a_reStatus, INDEX a_tnY,
+- INDEX a_tnXStart, INDEX a_tnXEnd, REGION_TEMP &a_rTemp)
+-{
+- typename REGION::ConstIterator itHere;
+- typename REGION_TEMP::ConstIterator itHereO;
+- INDEX tnX;
+- // Used to loop through points.
+-
+- // Make sure they didn't start us off with an error.
+- assert (a_reStatus == g_kNoError);
+-
+- // Calculate the union.
+- a_rTemp.Assign (a_reStatus, *this);
+- if (a_reStatus != g_kNoError)
+- return;
+- a_rTemp.Union (a_reStatus, a_tnY, a_tnXStart, a_tnXEnd);
+- if (a_reStatus != g_kNoError)
+- return;
+-
+- // Loop through every point in the result, make sure it's in
+- // one of the two input regions.
+- for (itHereO = a_rTemp.Begin(); itHereO != a_rTemp.End(); ++itHereO)
+- {
+- const Extent &rHere = *itHereO;
+- for (tnX = rHere.m_tnXStart; tnX < rHere.m_tnXEnd; ++tnX)
+- {
+- if (!((rHere.m_tnY == a_tnY
+- && (tnX >= a_tnXStart && tnX < a_tnXEnd))
+- || this->DoesContainPoint (rHere.m_tnY, tnX)))
+- goto error;
+- }
+- }
+-
+- // Loop through every point in the original region, make sure
+- // it's in the result.
+- for (itHere = this->Begin(); itHere != this->End(); ++itHere)
+- {
+- const Extent &rHere = *itHere;
+- for (tnX = rHere.m_tnXStart; tnX < rHere.m_tnXEnd; ++tnX)
+- {
+- if (!a_rTemp.DoesContainPoint (rHere.m_tnY, tnX))
+- goto error;
+- }
+- }
+-
+- // Loop through every point in the added extent, make sure it's in
+- // the result.
+- for (tnX = a_tnXStart; tnX < a_tnXEnd; ++tnX)
+- {
+- if (!a_rTemp.DoesContainPoint (a_tnY, tnX))
+- goto error;
+- }
+-
+- // The operation succeeded. Commit it.
+- Assign (a_reStatus, a_rTemp);
+- if (a_reStatus != g_kNoError)
+- return;
+-
+- // All done.
+- return;
+-
+-error:
+- // Handle deviations.
+- fprintf (stderr, "Region2D::Union() failed\n");
+- fprintf (stderr, "Input region:\n");
+- PrintRegion (*this);
+- fprintf (stderr, "Input extent: [%d,%d-%d]\n",
+- int (a_tnY), int (a_tnXStart), int (a_tnXEnd));
+- fprintf (stderr, "Result:\n");
+- PrintRegion (a_rTemp);
+- assert (false);
+-}
+-
+-
+-
+ // Make the current region represent the union between itself
+ // and the other given region.
+ template <class INDEX, class SIZE>
+@@ -512,182 +433,6 @@ Region2D<INDEX,SIZE>::Union (Status_t &a
+ }
+
+
+-
+-// Make the current region represent the union between itself
+-// and the other given region.
+-template <class INDEX, class SIZE>
+-template <class REGION, class REGION_O, class REGION_TEMP>
+-void
+-Region2D<INDEX,SIZE>::UnionDebug (Status_t &a_reStatus,
+- REGION_O &a_rOther, REGION_TEMP &a_rTemp)
+-{
+- typename REGION::ConstIterator itHere;
+- typename REGION_O::ConstIterator itHereO;
+- typename REGION_TEMP::ConstIterator itHereT;
+- INDEX tnX;
+- // Used to loop through points.
+-
+- // Make sure they didn't start us off with an error.
+- assert (a_reStatus == g_kNoError);
+-
+- // Calculate the union.
+- a_rTemp.Assign (a_reStatus, *this);
+- if (a_reStatus != g_kNoError)
+- return;
+- a_rTemp.Union (a_reStatus, a_rOther);
+- if (a_reStatus != g_kNoError)
+- return;
+-
+- // Loop through every point in the result, make sure it's in
+- // one of the two input regions.
+- for (itHereT = a_rTemp.Begin(); itHereT != a_rTemp.End(); ++itHereT)
+- {
+- const Extent &rHere = *itHereT;
+- for (tnX = rHere.m_tnXStart; tnX < rHere.m_tnXEnd; ++tnX)
+- {
+- if (!a_rOther.DoesContainPoint (rHere.m_tnY, tnX)
+- && !this->DoesContainPoint (rHere.m_tnY, tnX))
+- goto error;
+- }
+- }
+-
+- // Loop through every point in the first input region, make sure
+- // it's in the result.
+- for (itHere = this->Begin(); itHere != this->End(); ++itHere)
+- {
+- const Extent &rHere = *itHere;
+- for (tnX = rHere.m_tnXStart; tnX < rHere.m_tnXEnd; ++tnX)
+- {
+- if (!a_rTemp.DoesContainPoint (rHere.m_tnY, tnX))
+- goto error;
+- }
+- }
+-
+- // Loop through every point in the second input region, make sure
+- // it's in the result.
+- for (itHereO = a_rOther.Begin();
+- itHereO != a_rOther.End();
+- ++itHereO)
+- {
+- const Extent &rHere = *itHereO;
+- for (tnX = rHere.m_tnXStart; tnX < rHere.m_tnXEnd; ++tnX)
+- {
+- if (!a_rTemp.DoesContainPoint (rHere.m_tnY, tnX))
+- goto error;
+- }
+- }
+-
+- // The operation succeeded. Commit it.
+- Assign (a_reStatus, a_rTemp);
+- if (a_reStatus != g_kNoError)
+- return;
+-
+- // All done.
+- return;
+-
+-error:
+- // Handle deviations.
+- fprintf (stderr, "Region2D::Union() failed\n");
+- fprintf (stderr, "First input region:\n");
+- PrintRegion (*this);
+- fprintf (stderr, "Second input region:\n");
+- PrintRegion (a_rOther);
+- fprintf (stderr, "Result:\n");
+- PrintRegion (a_rTemp);
+- assert (false);
+-}
+-
+-
+-
+-// Subtract the other region from the current region, i.e.
+-// remove from the current region any areas that exist in the
+-// other region.
+-template <class INDEX, class SIZE>
+-template <class REGION, class REGION_O, class REGION_TEMP>
+-void
+-Region2D<INDEX,SIZE>::SubtractDebug (Status_t &a_reStatus,
+- REGION_O &a_rOther, REGION_TEMP &a_rTemp)
+-{
+- typename REGION::ConstIterator itHere;
+- typename REGION_O::ConstIterator itHereO;
+- typename REGION_TEMP::ConstIterator itHereT;
+- INDEX tnX;
+- // Used to loop through points.
+-
+- // Make sure they didn't start us off with an error.
+- assert (a_reStatus == g_kNoError);
+-
+- // Calculate the difference.
+- a_rTemp.Assign (a_reStatus, *this);
+- if (a_reStatus != g_kNoError)
+- return;
+- a_rTemp.Subtract (a_reStatus, a_rOther);
+- if (a_reStatus != g_kNoError)
+- return;
+-
+- // Loop through every point in the result, make sure it's in
+- // the first input region but not the second.
+- for (itHereT = a_rTemp.Begin(); itHereT != a_rTemp.End(); ++itHereT)
+- {
+- const Extent &rHere = *itHereT;
+- for (tnX = rHere.m_tnXStart; tnX < rHere.m_tnXEnd; ++tnX)
+- {
+- if (!(this->DoesContainPoint (rHere.m_tnY, tnX)
+- && !a_rOther.DoesContainPoint (rHere.m_tnY, tnX)))
+- goto error;
+- }
+- }
+-
+- // Loop through every point in the first input region, and if it's
+- // not in the second input region, make sure it's in the result.
+- for (itHere = this->Begin(); itHere != this->End(); ++itHere)
+- {
+- const Extent &rHere = *itHere;
+- for (tnX = rHere.m_tnXStart; tnX < rHere.m_tnXEnd; ++tnX)
+- {
+- if (!a_rOther.DoesContainPoint (rHere.m_tnY, tnX))
+- {
+- if (!a_rTemp.DoesContainPoint (rHere.m_tnY, tnX))
+- goto error;
+- }
+- }
+- }
+-
+- // Loop through every point in the second input region, make sure
+- // it's not in the result.
+- for (itHereO = a_rOther.Begin();
+- itHereO != a_rOther.End();
+- ++itHereO)
+- {
+- const Extent &rHere = *itHere;
+- for (tnX = rHere.m_tnXStart; tnX < rHere.m_tnXEnd; ++tnX)
+- {
+- if (a_rTemp.DoesContainPoint (rHere.m_tnY, tnX))
+- goto error;
+- }
+- }
+-
+- // The operation succeeded. Commit it.
+- Assign (a_reStatus, a_rTemp);
+- if (a_reStatus != g_kNoError)
+- return;
+-
+- // All done.
+- return;
+-
+-error:
+- // Handle deviations.
+- fprintf (stderr, "Region2D::Subtract() failed\n");
+- fprintf (stderr, "First input region:\n");
+- PrintRegion (*this);
+- fprintf (stderr, "Second input region:\n");
+- PrintRegion (a_rOther);
+- fprintf (stderr, "Result:\n");
+- PrintRegion (a_rTemp);
+- assert (false);
+-}
+-
+-
+
+ // Flood-fill the current region.
+ template <class INDEX, class SIZE>
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/mjpegtools.git/commitdiff/cbc738690885bf3fb61b78fbd814eb9af1660f48
More information about the pld-cvs-commit
mailing list