diff --git a/srcpkgs/libserialport/patches/0001-Remove-termiox-as-it-has-been-removed-from-recent-ke.patch b/srcpkgs/libserialport/patches/0001-Remove-termiox-as-it-has-been-removed-from-recent-ke.patch new file mode 100644 index 00000000000..43ccc125e4b --- /dev/null +++ b/srcpkgs/libserialport/patches/0001-Remove-termiox-as-it-has-been-removed-from-recent-ke.patch @@ -0,0 +1,36 @@ +Inspired by this commit from the upstream package: +https://sigrok.org/gitweb/?p=libserialport.git;a=commit;h=6f9b03e597ea7200eb616a4e410add3dd1690cb1 + +Applying this patch directly added some extra dependencies (autoconf, +automake), as the configure script needs to be regenerated with the +original commit. + +original commit message: + +termiox was removed from linux in e0efb3168d34 +Some more information available in https://www.spinics.net/lists/linux-serial/msg41926.html + +Attempting to use the termiox ioctls on more modern kernels results in +"Inappropriate IOCTL" errors. + +While the "right" solution might be to remove the termiox code from the +linux path, simply not checking for termiox builds a libserialport that +functions on modern linux kernels. +--- +diff --git a/libserialport_internal.h b/libserialport_internal.new.h +index 669152b..9a57b81 100644 +--- libserialport_internal.h ++++ libserialport_internal.h +@@ -69,11 +69,6 @@ + #include "linux/serial.h" + #endif + #include "linux_termios.h" +- +-/* TCGETX/TCSETX is not available everywhere. */ +-#if defined(TCGETX) && defined(TCSETX) && defined(HAVE_STRUCT_TERMIOX) +-#define USE_TERMIOX +-#endif + #endif + + /* TIOCINQ/TIOCOUTQ is not available everywhere. */ + diff --git a/srcpkgs/libserialport/template b/srcpkgs/libserialport/template index 23b6b92a42f..7d1cdd3c763 100644 --- a/srcpkgs/libserialport/template +++ b/srcpkgs/libserialport/template @@ -1,7 +1,7 @@ # Template file for 'libserialport' pkgname=libserialport version=0.1.1 -revision=2 +revision=3 build_style=gnu-configure short_desc="Cross-platform library for accessing serial ports" maintainer="lemmi "