]> git.pld-linux.org Git - packages/linux-gpib.git/commitdiff
- upstream: disable driver that does not build on kernel 5.10 auto/th/linux-gpib-4.3.3-2
authorJan Rękorajski <baggins@pld-linux.org>
Thu, 24 Dec 2020 21:35:23 +0000 (22:35 +0100)
committerJan Rękorajski <baggins@pld-linux.org>
Thu, 24 Dec 2020 21:35:23 +0000 (22:35 +0100)
- rel 2

kernel-5.10.patch [new file with mode: 0644]
linux-gpib.spec

diff --git a/kernel-5.10.patch b/kernel-5.10.patch
new file mode 100644 (file)
index 0000000..3141c67
--- /dev/null
@@ -0,0 +1,30 @@
+------------------------------------------------------------------------
+r1927 | dpenkler | 2020-11-23 12:54:12 +0100 (Mon, 23 Nov 2020) | 1 line
+
+Exclude compilation of lpvo for KERNEL >= 5.10
+
+Index: linux-gpib-kernel/drivers/gpib/Makefile
+===================================================================
+--- linux-gpib-kernel/drivers/gpib/Makefile    (revision 1926)
++++ linux-gpib-kernel/drivers/gpib/Makefile    (revision 1927)
+@@ -2,6 +2,9 @@
+       LINUXINCLUDE := -I$(GPIB_TOP_DIR)/compat/include $(LINUXINCLUDE)
+ endif
++KERNEL_GE_5_10 = $(shell expr \( $(VERSION) '>' "5" \) \| \
++ \( \( $(VERSION) '=' "5" \) \& \( $(PATCHLEVEL) '>=' 10 \) \) )
++
+ subdir-ccflags-y := -I$(src)/include \
+                       -DHAVE_DEV_OF_NODE=$(HAVE_DEV_OF_NODE) \
+                       -DGPIB_CONFIG_PCMCIA=$(GPIB_CONFIG_PCMCIA) \
+@@ -17,7 +20,9 @@
+ obj-y += hp_82335/
+ obj-y += hp_82341/
+ obj-y += ines/
+-obj-$(CONFIG_USB) += lpvo_usb_gpib/
++ifeq (${KERNEL_GE_5_10},0)
++      obj-$(CONFIG_USB) += lpvo_usb_gpib/
++endif
+ obj-y += nec7210/
+ obj-$(CONFIG_USB) += ni_usb/
+ ifeq ($(CONFIG_GPIB_ISA),yes)
index 026c37473b4cccb61bb01e697a41f5382c7fecd2..605ee45b7d8f101e14856b351b95aa7a9c68acbb 100644 (file)
@@ -34,7 +34,7 @@ exit 1
 
 %define                php_name        php%{?php_suffix}
 
-%define                rel     1
+%define                rel     2
 %define                pname   linux-gpib
 Summary:       GPIB (IEEE 488) Linux support
 Summary(pl.UTF-8):     Obsługa GPIB (IEEE 488) dla Linuksa
@@ -51,6 +51,7 @@ Patch4:               %{pname}-firmwaredir.patch
 Patch5:                %{pname}-guile2.patch
 Patch6:                %{pname}-php7.patch
 Patch8:                kernel-5.2.patch
+Patch9:                kernel-5.10.patch
 URL:           http://linux-gpib.sourceforge.net/
 BuildRequires: autoconf >= 2.50
 BuildRequires: automake
@@ -253,10 +254,15 @@ Ten pakiet zawiera sterowniki dla Linuksa do urządzeń GPIB (IEEE 488).\
 %define build_kernel_pkg()\
 %{__make} VERBOSE=1 LINUX_SRCDIR=%{_kernelsrcdir}\
 cd drivers/gpib\
+%if %{_kernel_version_code} < %{_kernel_version_magic 5 10 0}\
+%if %{with drivers_usb}\
+%install_kernel_modules -D installed -m lpvo_usb_gpib/lpvo_usb_gpib -d kernel/gpib\
+%endif\
+%endif\
 %ifarch %{ix86}\
-%install_kernel_modules -D installed -m agilent_82350b/agilent_82350b,cb7210/cb7210,cec/cec_gpib,hp_82335/hp82335,ines/ines_gpib,nec7210/nec7210,sys/gpib_common,tms9914/tms9914,tnt4882/tnt4882%{?with_drivers_isa:,pc2/pc2_gpib}%{?with_drivers_usb:,agilent_82357a/agilent_82357a,lpvo_usb_gpib/lpvo_usb_gpib,ni_usb/ni_usb_gpib} -d kernel/gpib\
+%install_kernel_modules -D installed -m agilent_82350b/agilent_82350b,cb7210/cb7210,cec/cec_gpib,hp_82335/hp82335,ines/ines_gpib,nec7210/nec7210,sys/gpib_common,tms9914/tms9914,tnt4882/tnt4882%{?with_drivers_isa:,pc2/pc2_gpib}%{?with_drivers_usb:,agilent_82357a/agilent_82357a,ni_usb/ni_usb_gpib} -d kernel/gpib\
 %else\
-%install_kernel_modules -D installed -m agilent_82350b/agilent_82350b,cb7210/cb7210,cec/cec_gpib,hp_82335/hp82335,hp_82341/hp_82341,ines/ines_gpib,nec7210/nec7210,sys/gpib_common,tms9914/tms9914,tnt4882/tnt4882%{?with_drivers_isa:,pc2/pc2_gpib}%{?with_drivers_usb:,agilent_82357a/agilent_82357a,lpvo_usb_gpib/lpvo_usb_gpib,ni_usb/ni_usb_gpib} -d kernel/gpib\
+%install_kernel_modules -D installed -m agilent_82350b/agilent_82350b,cb7210/cb7210,cec/cec_gpib,hp_82335/hp82335,hp_82341/hp_82341,ines/ines_gpib,nec7210/nec7210,sys/gpib_common,tms9914/tms9914,tnt4882/tnt4882%{?with_drivers_isa:,pc2/pc2_gpib}%{?with_drivers_usb:,agilent_82357a/agilent_82357a,ni_usb/ni_usb_gpib} -d kernel/gpib\
 %endif\
 cd ../..\
 %{nil}
@@ -285,6 +291,7 @@ cd linux-gpib-kernel-%{version}
 %ifarch %{ix86}
 %patch8 -p1
 %endif
+%patch9 -p1
 %endif
 
 %build
This page took 0.048199 seconds and 4 git commands to generate.