Code copies that could be replaced by Debian-packaged code
==========================================================

This is a review of the third-party code under src/libs_3rdparty and
src/plugins_3rdparty.  It is not a blocker for the current upload.

High priority, low risk
-----------------------

* src/plugins/biostruct3d_view/src/gl2ps (gl2ps 1.4.2)
  Replace by libgl2ps-dev (1.4.2).  The bundled version is exactly the
  Debian version and the public gl2ps.h API is unchanged.
  Action: add libgl2ps-dev to Build-Depends, stop globbing src/gl2ps/*,
  link the gl2ps library instead.

* src/libs_3rdparty/qtscript (bundled QtScript/JavaScriptCore, ~7 MB)
  Replace by qtscript5-dev (libQt5Script).  qtscript5-dev is already in
  Build-Depends, but the bundled copy is still built.  The public
  QScript* headers match Qt 5.15 apart from include paths.
  Action: link Qt5::Script, include <QtScript/...> via Qt, and remove
  the bundled qtscript target and the top-level include of
  src/libs_3rdparty/qtscript/script/api.
  Caveat: this only works for the Qt5 build.  A future Qt6 port has to
  replace QScriptEngine by QJSEngine (QtQml).

Medium priority, needs porting or a new Debian -dev package
-----------------------------------------------------------

* src/libs_3rdparty/samtools (samtools + htslib)
  Debian has libhts-dev (htslib 1.21/1.24) and the samtools package.
  The bundled code uses the old samtools API (samFile, bam_header) and
  BAMUtils.cpp even includes samtools_core/bam_sort.c directly, so this
  is a real port, not a drop-in replacement.

* src/plugins_3rdparty/umuscle (MUSCLE 3.8.1551)
  Debian already ships both muscle 5.x (muscle) and MUSCLE 3.8.1551
  (muscle3), so no new source package is needed.  UGENE runs the
  bundled algorithm in-process; the external-tool support or a small
  QProcess wrapper could call /usr/bin/muscle3 instead.
  Note: libmuscle1/libmuscle-dev is a different library (from MAUVE),
  not Robert Edgar's MUSCLE.

* src/plugins_3rdparty/hmm2 (HMMER 2.3.2)
  Debian's hmmer2 package ships exactly 2.3.2 but only the binaries.
  Options: use the existing external-tool support with /usr/bin/hmm2*
  (hmmer2 is already in Recommends), or create a libhmmer2-dev package.

* src/plugins_3rdparty/primer3 (primer3 2.x)
  Debian's primer3 package only ships primer3_core/ntthal/oligotm, no
  library.  Options: use the primer3_core binary through external-tool
  support (primer3 is already in Recommends), or create a -dev package.

* src/plugins_3rdparty/ball (BALL)
  Debian's ballview ships libBALL.so but no headers/dev package.  A
  libball-dev package would be needed before this can be reused.

Not replaceable by a Debian package
-----------------------------------

* src/libs_3rdparty/breakpad
  No breakpad package in Debian.  libbacktrace/libunwind only provide
  stack unwinding, not minidump generation.  A possible future change
  is to drop breakpad on Linux and rely on the existing backtrace()/
  core-dump path, but this changes crash-reporting behaviour.

* src/libs_3rdparty/QSpec
  UGENE's own GUI-testing library, not packaged.  It is only needed by
  the test plugins.  Debian could skip CoreTests, GUITestBase and
  api_tests (and QSpec with them) to reduce the binary size.

* src/libs_3rdparty/qscore
  Part of the MUSCLE distribution, no separate Debian package.  It goes
  away together with the bundled MUSCLE code.

* src/plugins_3rdparty/gor4 and src/plugins_3rdparty/ptools
  No Debian packages.  Both are small GPL code copies; removal would
  only be worthwhile together with the corresponding GUI feature.
