I can't test on real hardware, but the patch from my previous looks fine
and builds on ia64 (and sparc and i386 too, and even on mips which is
not in the supported architecture list in debian/control). So here's the
full NMU patch.

Brice

diff -u eciadsl-0.11/debian/changelog eciadsl-0.11/debian/changelog
--- eciadsl-0.11/debian/changelog
+++ eciadsl-0.11/debian/changelog
@@ -1,3 +1,11 @@
+eciadsl (0.11-3.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * Added get_pagesize_from_sysconf_at_open to fix a FTBFS on
+    architectures with variable page size, closes: #394214.
+
+ -- Brice Goglin <[EMAIL PROTECTED]>  Mon,  8 Jan 2007 14:29:06 +0100
+
 eciadsl (0.11-3) unstable; urgency=medium
 
   * Fixed postrm to remove the right rules symlink. (Closes: #332487)
only in patch2:
unchanged:
--- eciadsl-0.11.orig/debian/patches/get_pagesize_from_sysconf_at_open
+++ eciadsl-0.11/debian/patches/get_pagesize_from_sysconf_at_open
@@ -0,0 +1,39 @@
+Index: eciadsl-usermode-0.11/pusb-linux.c
+===================================================================
+--- eciadsl-usermode-0.11/pusb-linux.c 2006-12-29 15:25:26.000000000 +0100
++++ eciadsl-usermode-0.11/pusb-linux.c 2006-12-29 15:33:20.000000000 +0100
+@@ -29,7 +29,6 @@
+ #include <string.h>
+ 
+ #include "pusb-linux.h"
+-#include <asm/page.h>
+ 
+ struct pusb_endpoint_t
+ {
+@@ -217,10 +216,15 @@
+       return(make_device(fd));
+ }
+ 
++/* save page_size at open */
++static unsigned long page_size;
++
+ pusb_device_t pusb_open(const char* path)
+ {
+       int fd; 
+ 
++      page_size = sysconf(_SC_PAGESIZE);
++
+       fd = open(path, O_RDWR);
+       if (fd < 0)
+       {
+@@ -352,8 +356,8 @@
+     {
+               bulk.ep      = ep;
+               bulk.len     = size;
+-              if (bulk.len > PAGE_SIZE)
+-                      bulk.len = PAGE_SIZE;
++              if (bulk.len > page_size)
++                      bulk.len = page_size;
+               bulk.timeout = timeout;
+               bulk.data    = buf;
+ 

Reply via email to