From e4b7d19b5280815532eafce4c11e84fd1bb4383e Mon Sep 17 00:00:00 2001 From: Diego Elio Pettenò Date: Mon, 28 Mar 2011 22:08:38 +0000 Subject: Collapse the two solaris patches in one, and remove solaris patching for nouveau (meaningless). Acked by scarabeus. (Portage version: 2.2.0_alpha29/cvs/Linux x86_64) --- x11-libs/libdrm/ChangeLog | 9 +- x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch | 33 ------- x11-libs/libdrm/files/libdrm-2.4.16-solaris.patch | 91 ------------------ x11-libs/libdrm/files/libdrm-2.4.23-solaris.patch | 111 ++++++++++++++++++++++ x11-libs/libdrm/libdrm-2.4.23.ebuild | 5 +- x11-libs/libdrm/libdrm-2.4.24.ebuild | 5 +- 6 files changed, 123 insertions(+), 131 deletions(-) delete mode 100644 x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch delete mode 100644 x11-libs/libdrm/files/libdrm-2.4.16-solaris.patch create mode 100644 x11-libs/libdrm/files/libdrm-2.4.23-solaris.patch (limited to 'x11-libs') diff --git a/x11-libs/libdrm/ChangeLog b/x11-libs/libdrm/ChangeLog index 829d97b1e6b1..e0d50354657f 100644 --- a/x11-libs/libdrm/ChangeLog +++ b/x11-libs/libdrm/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for x11-libs/libdrm # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/ChangeLog,v 1.152 2011/03/15 21:14:04 xarthisius Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/ChangeLog,v 1.153 2011/03/28 22:08:38 flameeyes Exp $ + + 28 Mar 2011; Diego E. Pettenò + -files/libdrm-2.4.15-solaris.patch, -files/libdrm-2.4.16-solaris.patch, + libdrm-2.4.23.ebuild, +files/libdrm-2.4.23-solaris.patch, + libdrm-2.4.24.ebuild: + Collapse the two solaris patches in one, and remove solaris patching for + nouveau (meaningless). Acked by scarabeus. 15 Mar 2011; Kacper Kowalik libdrm-2.4.24.ebuild: ppc/ppc64 stable wrt #359059 diff --git a/x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch b/x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch deleted file mode 100644 index f344f0c75afc..000000000000 --- a/x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch +++ /dev/null @@ -1,33 +0,0 @@ -http://bugs.gentoo.org/show_bug.cgi?id=288064 - ---- libdrm/nouveau/nouveau_bo.c -+++ libdrm/nouveau/nouveau_bo.c -@@ -31,6 +31,12 @@ - #include - #include - -+/* On solaris unistd.h and stropts.h are needed for ioctl */ -+#ifdef __sun -+#include -+#include -+#endif -+ - #include "nouveau_private.h" - - int ---- libdrm/radeon/radeon_bo_gem.c -+++ libdrm/radeon/radeon_bo_gem.c -@@ -39,6 +39,13 @@ - #include - #include - #include -+ -+/* On solaris unistd.h and stropts.h are needed for ioctl */ -+#ifdef __sun -+#include -+#include -+#endif -+ - #include "xf86drm.h" - #include "drm.h" - #include "radeon_drm.h" diff --git a/x11-libs/libdrm/files/libdrm-2.4.16-solaris.patch b/x11-libs/libdrm/files/libdrm-2.4.16-solaris.patch deleted file mode 100644 index 90f9a3de7c6e..000000000000 --- a/x11-libs/libdrm/files/libdrm-2.4.16-solaris.patch +++ /dev/null @@ -1,91 +0,0 @@ -This is a reapply (hopefully in the relevant places) of the original -patch found here: -http://www.mail-archive.com/dri-devel@lists.sourceforge.net/msg35327.html - ---- libdrm-2.4.16/include/drm/drm.h -+++ libdrm-2.4.16/include/drm/drm.h -@@ -54,7 +54,11 @@ - typedef uint32_t __u32; - typedef int64_t __s64; - typedef uint64_t __u64; -+#if defined(__sun) -+typedef unsigned long long drm_handle_t; -+#else - typedef unsigned long drm_handle_t; -+#endif - - #endif - -@@ -210,12 +214,22 @@ - * \sa drmAddMap(). - */ - struct drm_map { -+#ifdef __sun -+ unsigned long long offset; -+ /**< Requested physical address (0 for SAREA)*/ -+ unsigned long long handle; -+ /**< User-space: "Handle" to pass to mmap() */ -+ /**< Kernel-space: kernel-virtual address */ -+#else - unsigned long offset; /**< Requested physical address (0 for SAREA)*/ -+#endif - unsigned long size; /**< Requested physical size (bytes) */ - enum drm_map_type type; /**< Type of memory to map */ - enum drm_map_flags flags; /**< Flags */ -+#ifndef __sun - void *handle; /**< User-space: "Handle" to pass to mmap() */ - /**< Kernel-space: kernel-virtual address */ -+#endif - int mtrr; /**< MTRR slot used */ - /* Private data */ - }; -@@ -375,6 +389,9 @@ - int count; /**< Length of the buffer list */ - void *virtual; /**< Mmap'd area in user-virtual */ - struct drm_buf_pub *list; /**< Buffer information */ -+#ifdef __sun -+ int fd; -+#endif - }; - - /** ---- libdrm-2.4.16/xf86drm.c -+++ libdrm-2.4.16/xf86drm.c -@@ -967,7 +967,11 @@ - { - drm_map_t map; - -+#ifdef __sun -+ map.handle = handle; -+#else - map.handle = (void *)handle; -+#endif - - if(drmIoctl(fd, DRM_IOCTL_RM_MAP, &map)) - return -errno; -@@ -1205,6 +1209,9 @@ - bufs.count = 0; - bufs.list = NULL; - bufs.virtual = NULL; -+#ifdef __sun -+ bufs.fd = fd; -+#endif - if (drmIoctl(fd, DRM_IOCTL_MAP_BUFS, &bufs)) - return NULL; - ---- libdrm-2.4.16/xf86drm.h -+++ libdrm-2.4.16/xf86drm.h -@@ -64,6 +64,13 @@ - - #endif - -+#if defined(__sun) && !defined(_IOC) -+#define _IOC(dir, group, nr, size) \ -+ (dir == DRM_IOC_READWRITE ? _IOWRN(group, nr, size) : \ -+ (dir == DRM_IOC_WRITE ? _IOWN(group, nr, size) : \ -+ /* dir == DRM_IOC_READ */ _IORN(group, nr, size) )) -+#endif -+ - /* Defaults, if nothing set in xf86config */ - #define DRM_DEV_UID 0 - #define DRM_DEV_GID 0 diff --git a/x11-libs/libdrm/files/libdrm-2.4.23-solaris.patch b/x11-libs/libdrm/files/libdrm-2.4.23-solaris.patch new file mode 100644 index 000000000000..5c148a41f500 --- /dev/null +++ b/x11-libs/libdrm/files/libdrm-2.4.23-solaris.patch @@ -0,0 +1,111 @@ +Index: libdrm-2.4.23/include/drm/drm.h +=================================================================== +--- libdrm-2.4.23.orig/include/drm/drm.h ++++ libdrm-2.4.23/include/drm/drm.h +@@ -54,7 +54,11 @@ typedef int32_t __s32; + typedef uint32_t __u32; + typedef int64_t __s64; + typedef uint64_t __u64; ++#if defined(__sun) ++typedef unsigned long long drm_handle_t; ++#else + typedef unsigned long drm_handle_t; ++#endif + + #endif + +@@ -210,12 +214,22 @@ struct drm_ctx_priv_map { + * \sa drmAddMap(). + */ + struct drm_map { ++#ifdef __sun ++ unsigned long long offset; ++ /**< Requested physical address (0 for SAREA)*/ ++ unsigned long long handle; ++ /**< User-space: "Handle" to pass to mmap() */ ++ /**< Kernel-space: kernel-virtual address */ ++#else + unsigned long offset; /**< Requested physical address (0 for SAREA)*/ ++#endif + unsigned long size; /**< Requested physical size (bytes) */ + enum drm_map_type type; /**< Type of memory to map */ + enum drm_map_flags flags; /**< Flags */ ++#ifndef __sun + void *handle; /**< User-space: "Handle" to pass to mmap() */ + /**< Kernel-space: kernel-virtual address */ ++#endif + int mtrr; /**< MTRR slot used */ + /* Private data */ + }; +@@ -379,6 +393,9 @@ struct drm_buf_map { + void *virtual; /**< Mmap'd area in user-virtual */ + #endif + struct drm_buf_pub *list; /**< Buffer information */ ++#ifdef __sun ++ int fd; ++#endif + }; + + /** +Index: libdrm-2.4.23/radeon/radeon_bo_gem.c +=================================================================== +--- libdrm-2.4.23.orig/radeon/radeon_bo_gem.c ++++ libdrm-2.4.23/radeon/radeon_bo_gem.c +@@ -38,6 +38,13 @@ + #include + #include + #include ++ ++/* On solaris unistd.h and stropts.h are needed for ioctl */ ++#ifdef __sun ++#include ++#include ++#endif ++ + #include "xf86drm.h" + #include "xf86atomic.h" + #include "drm.h" +Index: libdrm-2.4.23/xf86drm.c +=================================================================== +--- libdrm-2.4.23.orig/xf86drm.c ++++ libdrm-2.4.23/xf86drm.c +@@ -972,7 +972,11 @@ int drmRmMap(int fd, drm_handle_t handle + { + drm_map_t map; + ++#ifdef __sun ++ map.handle = handle; ++#else + map.handle = (void *)handle; ++#endif + + if(drmIoctl(fd, DRM_IOCTL_RM_MAP, &map)) + return -errno; +@@ -1210,6 +1214,9 @@ drmBufMapPtr drmMapBufs(int fd) + bufs.count = 0; + bufs.list = NULL; + bufs.virtual = NULL; ++#ifdef __sun ++ bufs.fd = fd; ++#endif + if (drmIoctl(fd, DRM_IOCTL_MAP_BUFS, &bufs)) + return NULL; + +Index: libdrm-2.4.23/xf86drm.h +=================================================================== +--- libdrm-2.4.23.orig/xf86drm.h ++++ libdrm-2.4.23/xf86drm.h +@@ -64,6 +64,13 @@ + + #endif + ++#if defined(__sun) && !defined(_IOC) ++#define _IOC(dir, group, nr, size) \ ++ (dir == DRM_IOC_READWRITE ? _IOWRN(group, nr, size) : \ ++ (dir == DRM_IOC_WRITE ? _IOWN(group, nr, size) : \ ++ /* dir == DRM_IOC_READ */ _IORN(group, nr, size) )) ++#endif ++ + /* Defaults, if nothing set in xf86config */ + #define DRM_DEV_UID 0 + #define DRM_DEV_GID 0 diff --git a/x11-libs/libdrm/libdrm-2.4.23.ebuild b/x11-libs/libdrm/libdrm-2.4.23.ebuild index b0d0b9a9c735..073865381677 100644 --- a/x11-libs/libdrm/libdrm-2.4.23.ebuild +++ b/x11-libs/libdrm/libdrm-2.4.23.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/libdrm-2.4.23.ebuild,v 1.8 2011/03/05 17:55:53 xarthisius Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/libdrm-2.4.23.ebuild,v 1.9 2011/03/28 22:08:38 flameeyes Exp $ EAPI=3 inherit xorg-2 @@ -28,8 +28,7 @@ RDEPEND="dev-libs/libpthread-stubs" DEPEND="${RDEPEND}" PATCHES=( - "${FILESDIR}"/${PN}-2.4.16-solaris.patch - "${FILESDIR}"/${PN}-2.4.15-solaris.patch + "${FILESDIR}"/${PN}-2.4.23-solaris.patch ) pkg_setup() { diff --git a/x11-libs/libdrm/libdrm-2.4.24.ebuild b/x11-libs/libdrm/libdrm-2.4.24.ebuild index e9756c751f17..80329615a1d7 100644 --- a/x11-libs/libdrm/libdrm-2.4.24.ebuild +++ b/x11-libs/libdrm/libdrm-2.4.24.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/libdrm-2.4.24.ebuild,v 1.2 2011/03/15 21:14:04 xarthisius Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/libdrm-2.4.24.ebuild,v 1.3 2011/03/28 22:08:38 flameeyes Exp $ EAPI=4 inherit xorg-2 @@ -28,8 +28,7 @@ RDEPEND="dev-libs/libpthread-stubs" DEPEND="${RDEPEND}" PATCHES=( - "${FILESDIR}"/${PN}-2.4.16-solaris.patch - "${FILESDIR}"/${PN}-2.4.15-solaris.patch + "${FILESDIR}"/${PN}-2.4.23-solaris.patch ) pkg_setup() { -- cgit v1.2.3-65-gdbad