]> git.pld-linux.org Git - packages/util-linux.git/commitdiff
- correct version of this patch as will be sent to the maintainer
authorMariusz Mazur <mmazur@pld-linux.org>
Sun, 8 Feb 2004 18:14:07 +0000 (18:14 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    util-linux-blk.patch -> 1.3

util-linux-blk.patch

index 6089367aa79c485d42a61bb9125882b306841586..e1e466499f3487f2e30ec9d0abaf530d68def834 100644 (file)
@@ -1,37 +1,74 @@
---- util-linux-2.12/disk-utils/elvtune.c.orig  2002-03-08 23:57:49.000000000 +0100
-+++ util-linux-2.12/disk-utils/elvtune.c       2003-12-28 00:47:21.716360592 +0100
-@@ -37,8 +37,8 @@
+--- util-linux-2.12/disk-utils/elvtune.c.orig  Sun Feb  8 18:37:01 2004
++++ util-linux-2.12/disk-utils/elvtune.c       Sun Feb  8 18:39:03 2004
+@@ -27,6 +27,7 @@
+ #include <unistd.h>
+ #include <stdlib.h>
+ #include "nls.h"
++#include <linux/version.h>
+ /* this has to match with the kernel structure */
+ /* current version for ac19 and 2.2.16 */
+@@ -37,8 +38,13 @@
        int max_bomb_segments;
  } blkelv_ioctl_arg_t;
  
--#define BLKELVGET   _IOR(0x12,106,sizeof(blkelv_ioctl_arg_t))
--#define BLKELVSET   _IOW(0x12,107,sizeof(blkelv_ioctl_arg_t))
-+#define BLKELVGET   _IOR(0x12,106,size_t) /* blkelv_ioctl_arg_t, broken by sizeof() */
-+#define BLKELVSET   _IOW(0x12,107,size_t) /* blkelv_ioctl_arg_t, broken by sizeof() */
++#ifdef LIBC_HEADERS_VERSION 
++/* Fixed headers detected */
++#include <linux/fs.h>
++#else
+ #define BLKELVGET   _IOR(0x12,106,sizeof(blkelv_ioctl_arg_t))
+ #define BLKELVSET   _IOW(0x12,107,sizeof(blkelv_ioctl_arg_t))
++#endif
  
  static void
  usage(void) {
---- util-linux-2.12/disk-utils/blockdev.c.orig 2003-12-28 00:46:18.483973376 +0100
-+++ util-linux-2.12/disk-utils/blockdev.c      2003-12-28 00:47:12.833710960 +0100
-@@ -24,8 +24,8 @@
- #define BLKRASET   _IO(0x12,98)
- #define BLKRAGET   _IO(0x12,99)
- #define BLKSSZGET  _IO(0x12,104)
--#define BLKBSZGET  _IOR(0x12,112,sizeof(int))
--#define BLKBSZSET  _IOW(0x12,113,sizeof(int))
-+#define BLKBSZGET  _IOR(0x12,112,size_t) /* int, broken by sizeof() */
-+#define BLKBSZSET  _IOW(0x12,113,size_t) /* int, broken by sizeof() */
+--- util-linux-2.12/disk-utils/blockdev.c.orig Sun Feb  8 18:39:35 2004
++++ util-linux-2.12/disk-utils/blockdev.c      Sun Feb  8 18:47:44 2004
+@@ -9,12 +9,14 @@
+ #include <string.h>
+ #include <unistd.h>
+ #include <sys/ioctl.h>
++#include <linux/version.h>
+ #include "nls.h"
+-/* Since it is impossible to include <linux/fs.h>, let us
+-   give the ioctls explicitly. */
+-
++#ifdef LIBC_HEADERS_VERSION
++/* Fixed headers detected */
++#include <linux/fs.h>
++#else
+ #ifndef BLKROSET
+ #define BLKROSET   _IO(0x12,93)
+ #define BLKROGET   _IO(0x12,94)
+@@ -27,6 +29,7 @@
+ #define BLKBSZGET  _IOR(0x12,112,sizeof(int))
+ #define BLKBSZSET  _IOW(0x12,113,sizeof(int))
  #endif
++#endif
  
  /* Maybe <linux/hdreg.h> could be included */
---- util-linux-2.12/fdisk/common.h.orig        2003-07-13 15:59:53.000000000 +0200
-+++ util-linux-2.12/fdisk/common.h     2003-12-28 00:52:43.568431640 +0100
-@@ -6,7 +6,7 @@
+ #ifndef HDIO_GETGEO
+--- util-linux-2.12/fdisk/common.h.orig        Sun Feb  8 18:48:00 2004
++++ util-linux-2.12/fdisk/common.h     Sun Feb  8 18:51:04 2004
+@@ -1,12 +1,18 @@
+ /* common stuff for fdisk, cfdisk, sfdisk */
+-/* including <linux/fs.h> fails */
+ #include <sys/ioctl.h>
++#include <linux/version.h>
++
++#ifdef LIBC_HEADERS_VERSION
++/* Fixed headers detected */
++#include <linux/fs.h>
++#else
+ #define BLKRRPART    _IO(0x12,95)    /* re-read partition table */
  #define BLKGETSIZE   _IO(0x12,96)    /* return device size */
  #define BLKFLSBUF    _IO(0x12,97)    /* flush buffer cache */
  #define BLKSSZGET    _IO(0x12,104)   /* get block device sector size */
--#define BLKGETSIZE64 _IOR(0x12,114,8) /* 8 = sizeof(u64) */
-+#define BLKGETSIZE64 _IOR(0x12,114,size_t) /* u64, broken by sizeof(); sizeof(8) was the same on 32-bit, but not on 64-bit archs */
+ #define BLKGETSIZE64 _IOR(0x12,114,8) /* 8 = sizeof(u64) */
++#endif
  
  /* including <linux/hdreg.h> also fails */
  struct hd_geometry {
This page took 0.328649 seconds and 4 git commands to generate.