diff options
author | Jeremy Olexa <darkside@gentoo.org> | 2011-01-27 16:55:39 +0000 |
---|---|---|
committer | Jeremy Olexa <darkside@gentoo.org> | 2011-01-27 16:55:39 +0000 |
commit | f894f37c95bc58c873203613dab89a6ddb5e72ba (patch) | |
tree | 8909be3da787296b4bcd1aedf8a4f88e6cc74fcf | |
parent | Push Gentoo Prefix changes from x11 overlay, as approved (diff) | |
download | gentoo-2-f894f37c95bc58c873203613dab89a6ddb5e72ba.tar.gz gentoo-2-f894f37c95bc58c873203613dab89a6ddb5e72ba.tar.bz2 gentoo-2-f894f37c95bc58c873203613dab89a6ddb5e72ba.zip |
Push Gentoo Prefix changes from x11 overlay, as approved
(Portage version: 2.1.9.35/cvs/Linux i686)
-rw-r--r-- | x11-libs/libdrm/ChangeLog | 9 | ||||
-rw-r--r-- | x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch | 33 | ||||
-rw-r--r-- | x11-libs/libdrm/files/libdrm-2.4.16-solaris.patch | 91 | ||||
-rw-r--r-- | x11-libs/libdrm/libdrm-2.4.23.ebuild | 11 |
4 files changed, 139 insertions, 5 deletions
diff --git a/x11-libs/libdrm/ChangeLog b/x11-libs/libdrm/ChangeLog index bcf2020a3967..8f57b561eded 100644 --- a/x11-libs/libdrm/ChangeLog +++ b/x11-libs/libdrm/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for x11-libs/libdrm -# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/ChangeLog,v 1.141 2010/12/31 19:45:31 jer Exp $ +# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/ChangeLog,v 1.142 2011/01/27 16:55:38 darkside Exp $ + + 27 Jan 2011; Jeremy Olexa <darkside@gentoo.org> + +files/libdrm-2.4.15-solaris.patch, +files/libdrm-2.4.16-solaris.patch, + libdrm-2.4.23.ebuild: + Push Gentoo Prefix changes from x11 overlay, as approved 31 Dec 2010; Jeroen Roovers <jer@gentoo.org> libdrm-2.4.22.ebuild: Stable for HPPA (bug #344827). diff --git a/x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch b/x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch new file mode 100644 index 000000000000..f344f0c75afc --- /dev/null +++ b/x11-libs/libdrm/files/libdrm-2.4.15-solaris.patch @@ -0,0 +1,33 @@ +http://bugs.gentoo.org/show_bug.cgi?id=288064 + +--- libdrm/nouveau/nouveau_bo.c ++++ libdrm/nouveau/nouveau_bo.c +@@ -31,6 +31,12 @@ + #include <sys/mman.h> + #include <sys/ioctl.h> + ++/* On solaris unistd.h and stropts.h are needed for ioctl */ ++#ifdef __sun ++#include <unistd.h> ++#include <stropts.h> ++#endif ++ + #include "nouveau_private.h" + + int +--- libdrm/radeon/radeon_bo_gem.c ++++ libdrm/radeon/radeon_bo_gem.c +@@ -39,6 +39,13 @@ + #include <sys/mman.h> + #include <sys/ioctl.h> + #include <errno.h> ++ ++/* On solaris unistd.h and stropts.h are needed for ioctl */ ++#ifdef __sun ++#include <unistd.h> ++#include <stropts.h> ++#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 new file mode 100644 index 000000000000..90f9a3de7c6e --- /dev/null +++ b/x11-libs/libdrm/files/libdrm-2.4.16-solaris.patch @@ -0,0 +1,91 @@ +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/libdrm-2.4.23.ebuild b/x11-libs/libdrm/libdrm-2.4.23.ebuild index c5463ee274cb..ef5f2108a179 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-2010 Gentoo Foundation +# 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.1 2010/12/10 19:18:18 scarabeus Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-libs/libdrm/libdrm-2.4.23.ebuild,v 1.2 2011/01/27 16:55:39 darkside Exp $ EAPI=3 inherit xorg-2 @@ -15,7 +15,7 @@ else SRC_URI="http://dri.freedesktop.org/${PN}/${P}.tar.bz2" fi -KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~x64-freebsd ~x86-freebsd ~amd64-linux ~x86-linux ~sparc-solaris ~x64-solaris ~x86-solaris" VIDEO_CARDS="intel nouveau radeon vmware" for card in ${VIDEO_CARDS}; do IUSE_VIDEO_CARDS+=" video_cards_${card}" @@ -27,6 +27,11 @@ RESTRICT="test" # see bug #236845 RDEPEND="dev-libs/libpthread-stubs" DEPEND="${RDEPEND}" +PATCHES=( + "${FILESDIR}"/${PN}-2.4.16-solaris.patch + "${FILESDIR}"/${PN}-2.4.15-solaris.patch +) + pkg_setup() { CONFIGURE_OPTIONS="--enable-udev $(use_enable video_cards_intel intel) |