#1095397 vdr-plugin-remote: FTBFS: error: invalid new-expression of abstract class type 'cLircRemote'

#1095397#5
Date:
2025-02-07 12:13:22 UTC
From:
To:
Dear maintainer:

During a rebuild of all packages in unstable, your package failed to build:
--------------------------------------------------------------------------------
[...]
 debian/rules clean
dh clean --with vdrplugin
   dh_auto_clean
	make -j2 clean
make[1]: Entering directory '/<<PKGBUILDDIR>>'
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
   dh_clean
 debian/rules binary
dh binary --with vdrplugin
   dh_update_autotools_config
   dh_autoreconf
   dh_auto_configure
   dh_auto_build
	make -j2 "INSTALL=install --strip-program=true"
make[1]: Entering directory '/<<PKGBUILDDIR>>'
g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/vdr-2.6.9=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -c -DPLUGIN_NAME_I18N='"remote"' -DREMOTE_FEATURE_LIRC -DREMOTE_FEATURE_TCPIP  remote.c
g++ -g -O2 -ffile-prefix-map=/build/reproducible-path/vdr-2.6.9=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -c -DPLUGIN_NAME_I18N='"remote"' -DREMOTE_FEATURE_LIRC -DREMOTE_FEATURE_TCPIP  ttystatus.c
remote.c: In member function ‘virtual bool cPluginRemote::Start()’:
remote.c:799:42: error: invalid new-expression of abstract class type ‘cLircRemote’
  799 |                 new cLircRemote(devnam[i]); // use vdr's lirc code
      |                                          ^
In file included from remote.c:27:
/usr/include/vdr/lirc.h:16:7: note:   because the following virtual functions are pure within ‘cLircRemote’:
   16 | class cLircRemote : public cRemote, protected cThread {
      |       ^~~~~~~~~~~
In file included from /usr/include/vdr/tools.h:29,
                 from /usr/include/vdr/i18n.h:14,
                 from /usr/include/vdr/plugin.h:13,
                 from remote.c:25:
/usr/include/vdr/thread.h:96:16: note:     ‘virtual void cThread::Action()’
   96 |   virtual void Action(void) = 0;
      |                ^~~~~~
remote.c:750:21: warning: ignoring return value of ‘int asprintf(char**, const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
  750 |             asprintf(&nam, "%s-%s", Name(), cp+1);
      |             ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
remote.c:752:21: warning: ignoring return value of ‘int asprintf(char**, const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
  752 |             asprintf(&nam, "%s-%s", Name(), devnam[i]);
      |             ~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ttystatus.c: In member function ‘virtual void cTtyStatus::display(const char*, bool, int)’:
ttystatus.c:69:26: warning: ignoring return value of ‘ssize_t write(int, const void*, size_t)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   69 |                     write(fd, blanks, 1);
      |                     ~~~~~^~~~~~~~~~~~~~~
ttystatus.c:79:22: warning: ignoring return value of ‘ssize_t write(int, const void*, size_t)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
   79 |                 write(fd, "\r\n", 2);
      |                 ~~~~~^~~~~~~~~~~~~~~
ttystatus.c:106:22: warning: ignoring return value of ‘ssize_t write(int, const void*, size_t)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
  106 |                 write(fd, buf+i, l);
      |                 ~~~~~^~~~~~~~~~~~~~
ttystatus.c:115:14: warning: ignoring return value of ‘ssize_t write(int, const void*, size_t)’ declared with attribute ‘warn_unused_result’ [-Wunused-result]
  115 |         write(fd, blanks, n);
      |         ~~~~~^~~~~~~~~~~~~~~
make[1]: *** [Makefile:138: remote.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory '/<<PKGBUILDDIR>>'
dh_auto_build: error: make -j2 "INSTALL=install --strip-program=true" returned exit code 2
make: *** [debian/rules:7: binary] Error 25
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2
--------------------------------------------------------------------------------

The above is just how the build ends and not necessarily the most relevant part.
If required, the full build log is available here:

https://people.debian.org/~sanvila/build-logs/202502/

About the archive rebuild: The build was made on virtual machines from AWS,
using sbuild and a reduced chroot with only build-essential packages.

If you could not reproduce the bug please contact me privately, as I
am willing to provide ssh access to a virtual machine where the bug is
fully reproducible.

If this is really a bug in one of the build-depends, please use
reassign and add an affects on src:vdr-plugin-remote, so that this is still
visible in the BTS web page for this package.

Thanks.

#1095397#10
Date:
2025-02-08 18:20:44 UTC
From:
To:
Fri, Feb 07, 2025 at 12:13:22PM +0000, Santiago Vila wrote:
driver in VDR 2.6.2 (revised in 2.6.4).  The earliest kernel with which
it was confirmed to work is Linux 5.10.  See
https://www.linuxtv.org/vdrwiki/index.php/LIRC where I had documented
this.

That there exist two totally different “LIRC” can be confusing.  The
user space code could have been at least 20 years earlier, but its name
at least nowadays is misleading because it not limited to Linux.  The
/dev/lirc* in the Linux kernel is also logical, because it is literally
the Linux (as in the actual kernel) Infrared Remote Control driver.

What was 25 to 30 years ago done with DIY bit-banging and voltage
conversion hacks on a commodity PC serial or parallel port would be done
more easily with modern single-board computers, working out of the box
with Linux’s native /dev/lirc* subsystem.  In
https://www.linuxtv.org/vdrwiki/index.php/Raspberry_Pi I documented my
setup: just specify a device tree overlay, and connect the 3 wires of a
TSOP38238 receiver module to the GPIO header.

I used to use vdr-plugin-remote, which allowed to connect an infrared
remote control unit via the “less native” /dev/input/event interface
whose key-repeat logic would interfere with what an infrared remote
control uint is naturally doing: sending bursts at a repeat rate that is
expected by TV users.

More than 10 years ago, I had been in irregular contact with the author
of vdr-plugin-remote, but did not get any replies in the recent years.
I think that the correct solution is to remove or disable this part of
this plugin as redundant.  I can’t say if there could be any practical
use of the /dev/input/event interface that wouldn’t be better supported
by the /dev/lirc*.

I had created https://www.linuxtv.org/vdrwiki/index.php/Systemd
to document some Systemd integration that I came up with.  Unfortunately
my request to include this in upstream VDR in any form had been
declined.  I feel that any “runvdr” shell script or whatever it might be
called is unacceptable under Systemd.  Dear maintainers, I’d look
forward to your feedback on this, and happy to test any Systemd unit
files that you think would be appropriate for the Debian packaging of
VDR.

Side note: The only VDR plugin that my setup depends on is
https://github.com/reufer/rpihddevice/, which I guess can’t be packaged
because it depends non-free software and hardware, namely the Videocore
Ⅳ GPU.

With best regards,

	Marko Mäkelä