Added core/linux-api-headers-pb to see if udev builds properaly

This commit is contained in:
Mike Staszel 2010-05-05 18:37:06 -05:00
parent 3367a1ad03
commit 7859ad36b4
3 changed files with 87 additions and 0 deletions

View file

@ -0,0 +1,41 @@
# Maintainer: Mike Staszel <mikestaszel@plugbox.org>
# toolchain build order: linux-api-headers->glibc->binutils->gcc->binutils->glibc
pkgname=linux-api-headers
pkgver=2.6.33.3
_basever=2.6.33
pkgrel=1
pkgdesc="Kernel headers sanitized for use in userspace"
arch=('arm')
url="http://www.gnu.org/software/libc"
license=('GPL')
provides=("kernel-headers=${pkgver}")
conflicts=("glibc<=2.10.1-4" 'kernel-headers')
replaces=('kernel-headers')
source=(ftp://ftp.kernel.org/pub/linux/kernel/v2.6/linux-${_basever}.tar.bz2
http://www.kernel.org/pub/linux/kernel/v2.6/patch-${pkgver}.bz2
scsi.patch)
md5sums=('c3883760b18d50e8d78819c54d579b00'
'dd6cd6a3aea70a2d90d1e8fd6abc3b45'
'b6d05566fcfe07770d9386f0588f8758')
build() {
cd ${srcdir}/linux-${_basever}
patch -Np1 -i ${srcdir}/patch-${pkgver} || return 1
# fix issues with transition of scsi.h from glibc
patch -Np1 -i ${srcdir}/scsi.patch || return 1
make mrproper
make headers_check || return 1
}
package() {
cd ${srcdir}/linux-${_basever}
make INSTALL_HDR_PATH=${pkgdir}/usr headers_install
rm -rf ${pkgdir}/usr/include/drm
rm -f $(find ${pkgdir} -name .install -or -name ..install.cmd)
}

View file

@ -0,0 +1,4 @@
These, if they help make udev, will replace the With-Linux ones.
They are exactly the same as the vanilla Arch Linux ones, with
no changes made.

View file

@ -0,0 +1,42 @@
diff -Naur linux-2.6.32-old/include/scsi/scsi.h linux-2.6.32/include/scsi/scsi.h
--- linux-2.6.32-old/include/scsi/scsi.h 2009-12-03 13:51:21.000000000 +1000
+++ linux-2.6.32/include/scsi/scsi.h 2009-12-12 10:43:11.000000000 +1000
@@ -145,14 +145,15 @@
/* defined in T10 SCSI Primary Commands-2 (SPC2) */
struct scsi_varlen_cdb_hdr {
- u8 opcode; /* opcode always == VARIABLE_LENGTH_CMD */
- u8 control;
- u8 misc[5];
- u8 additional_cdb_length; /* total cdb length - 8 */
+ __u8 opcode; /* opcode always == VARIABLE_LENGTH_CMD */
+ __u8 control;
+ __u8 misc[5];
+ __u8 additional_cdb_length; /* total cdb length - 8 */
__be16 service_action;
/* service specific data follows */
};
+#ifdef __KERNEL__
static inline unsigned
scsi_varlen_cdb_length(const void *hdr)
{
@@ -168,6 +169,7 @@
return (cmnd[0] == VARIABLE_LENGTH_CMD) ?
scsi_varlen_cdb_length(cmnd) : COMMAND_SIZE(cmnd[0]);
}
+#endif
/*
* SCSI Architecture Model (SAM) Status codes. Taken from SAM-3 draft
@@ -284,8 +286,10 @@
SCSI_PROTOCOL_UNSPEC = 0xf, /* No specific protocol */
};
+#ifdef __KERNEL__
/* Returns a human-readable name for the device */
extern const char * scsi_device_type(unsigned type);
+#endif
/*
* standard mode-select header prepended to all mode-select commands