Import of pkgsrc-2015Q3

This commit is contained in:
2016-01-21 23:42:40 +01:00
committed by sambuc
parent f641581404
commit 9d819b6d54
7578 changed files with 228313 additions and 80017 deletions
+7 -2
View File
@@ -1,8 +1,8 @@
# $NetBSD: Makefile,v 1.3 2015/04/25 14:25:14 tnn Exp $
# $NetBSD: Makefile,v 1.6 2015/09/20 16:39:18 tnn Exp $
DISTNAME= xorg-server-1.12.4
PKGNAME= modular-${DISTNAME}
PKGREVISION= 13
PKGREVISION= 15
CATEGORIES= x11
MASTER_SITES= ${MASTER_SITE_XORG:=xserver/}
EXTRACT_SUFX= .tar.bz2
@@ -99,6 +99,11 @@ SUNOS_ARCH= sparcv8plus
. endif
.endif
PLIST_VARS+= sparc
.if !empty(MACHINE_ARCH:Msparc*)
PLIST.sparc= yes
.endif
# Workaround for PR#41556.
# Avoid to use bsd_kqueue_apm, force to use bsd_apm instead.
.if ${OPSYS} == "NetBSD"
+2 -1
View File
@@ -1,4 +1,4 @@
@comment $NetBSD: PLIST,v 1.1 2015/04/03 09:46:18 tnn Exp $
@comment $NetBSD: PLIST,v 1.2 2015/09/20 16:39:18 tnn Exp $
bin/X
bin/Xnest
bin/Xorg
@@ -147,6 +147,7 @@ include/xorg/xf86Priv.h
include/xorg/xf86Privstr.h
include/xorg/xf86RamDac.h
include/xorg/xf86RandR12.h
${PLIST.sparc}include/xorg/xf86Sbus.h
include/xorg/xf86Rename.h
include/xorg/xf86VGAarbiter.h
include/xorg/xf86Xinput.h
+6 -2
View File
@@ -1,4 +1,4 @@
$NetBSD: distinfo,v 1.1 2015/04/03 09:46:18 tnn Exp $
$NetBSD: distinfo,v 1.2 2015/09/20 16:39:18 tnn Exp $
SHA1 (xorg-server-1.12.4.tar.bz2) = 6d616874f9c7677bda08dc073c03f83e78fbc585
RMD160 (xorg-server-1.12.4.tar.bz2) = 4907b5dc42efd6b3fb6bf9d64f1441080a6a6983
@@ -43,9 +43,13 @@ SHA1 (patch-glx_singlepix.c) = 72ac42939b37ae0d57fc06453344ca76cdf2c856
SHA1 (patch-glx_singlepixswap.c) = 1e3d54d3082a59d21edd81276980b953efc39ebb
SHA1 (patch-glx_swap__interval.c) = 2ff4e2e7d2793dd8558b04c1f72abfa81998f2c6
SHA1 (patch-glx_unpack.h) = 5ae5c10c93835cb51c08f5dae05c5a5e2afaad98
SHA1 (patch-hw_xfree86_common_compiler.h) = 88de747715b80b22f448869ab32dce1641bcb6db
SHA1 (patch-hw_xfree86_common_compiler.h) = 55ddbe73946ca3d3d8c5c398838cbfa60f06af42
SHA1 (patch-hw_xfree86_common_xf86sbusBus.h) = 9095519b466df814bd8a7bc1decbc186d997c5cd
SHA1 (patch-hw_xfree86_dri2_dri2.c) = 32a8c309f9ae417c99fe81b6a9c3b1f402880981
SHA1 (patch-hw_xfree86_dri2_dri2ext.c) = bc2b57e4bef5ae386d1d3a015c01d243f8880ab4
SHA1 (patch-hw_xfree86_os-support_bsd_sparc64__video.c) = d85331bbcf14ccae99bd8485aff8055a9f470f27
SHA1 (patch-hw_xfree86_os-support_bus_Sbus.c) = f4e1d8b6ac917e0310e64409f1e4dd246a6107b3
SHA1 (patch-hw_xfree86_os-support_bus_xf86Sbus.h) = b05b6c6f7c68bdbfd98b559d9b87a35c229fb946
SHA1 (patch-hw_xfree86_os-support_xf86__OSlib.h) = 7c2760509610b44915da077b22899bef9c338cc1
SHA1 (patch-include_dix.h) = ab0dc2debd87f29c0ac7f971a3cad4850b239c3a
SHA1 (patch-include_regionstr.h) = c6f3e3b263593b622e7087d3ebe2b470cf9526e3
@@ -1,7 +1,16 @@
$NetBSD: patch-hw_xfree86_common_compiler.h,v 1.1 2015/04/03 09:46:18 tnn Exp $
$NetBSD: patch-hw_xfree86_common_compiler.h,v 1.2 2015/09/20 16:39:18 tnn Exp $
--- hw/xfree86/common/compiler.h.orig 2013-05-21 17:33:57.000000000 +0000
--- hw/xfree86/common/compiler.h.orig 2012-05-17 17:09:03.000000000 +0000
+++ hw/xfree86/common/compiler.h
@@ -470,7 +470,7 @@ inl(unsigned short port)
return ret;
}
-#elif (defined(linux) || defined(sun) || defined(__OpenBSD__) || defined(__FreeBSD__)) && defined(__sparc__)
+#elif (defined(linux) || defined(sun) || defined(__OpenBSD__) || defined(__FreeBSD__) || defined(__NetBSD__)) && defined(__sparc__)
#ifndef ASI_PL
#define ASI_PL 0x88
@@ -1392,26 +1392,26 @@ inl(unsigned short port)
static __inline__ void
outb(unsigned short port, unsigned char val)
@@ -0,0 +1,24 @@
$NetBSD: patch-hw_xfree86_common_xf86sbusBus.h,v 1.1 2015/09/20 16:39:18 tnn Exp $
NetBSD/sparc64 support partially from xsrc.
--- hw/xfree86/common/xf86sbusBus.h.orig 2012-05-17 17:09:03.000000000 +0000
+++ hw/xfree86/common/xf86sbusBus.h
@@ -39,6 +39,8 @@
#define SBUS_DEVICE_FFB 0x000b
#define SBUS_DEVICE_GT 0x000c
#define SBUS_DEVICE_MGX 0x000d
+#define SBUS_DEVICE_P9100 0x000e
+#define SBUS_DEVICE_AG10E 0x000f
typedef struct sbus_prom_node {
int node;
@@ -50,7 +52,7 @@ typedef struct sbus_device {
int devId;
int fbNum;
int fd;
- int width, height;
+ int width, height, size;
sbusPromNode node;
char *descr;
char *device;
@@ -0,0 +1,26 @@
$NetBSD: patch-hw_xfree86_os-support_bsd_sparc64__video.c,v 1.1 2015/09/20 16:39:18 tnn Exp $
For some reason we need these symbols to link.
--- hw/xfree86/os-support/bsd/sparc64_video.c.orig 2012-05-17 17:09:03.000000000 +0000
+++ hw/xfree86/os-support/bsd/sparc64_video.c
@@ -50,6 +50,19 @@ xf86OSInitVidMem(VidMemInfoPtr pVidMem)
pVidMem->initialised = TRUE;
}
+void
+xf86SetTVOut(int mode)
+{
+ return;
+}
+
+void
+xf86SetRGBOut()
+{
+ return;
+}
+
+
static pointer
sparc64MapVidMem(int ScreenNum, unsigned long Base, unsigned long Size,
int flags)
@@ -0,0 +1,172 @@
$NetBSD: patch-hw_xfree86_os-support_bus_Sbus.c,v 1.1 2015/09/20 16:39:18 tnn Exp $
Merge most of netbsdSbus.c from xsrc.
--- hw/xfree86/os-support/bus/Sbus.c.orig 2012-08-19 15:45:54.000000000 +0000
+++ hw/xfree86/os-support/bus/Sbus.c
@@ -34,6 +34,9 @@
#ifdef sun
#include <sys/utsname.h>
#endif
+#if defined(__NetBSD__) && defined(__sparc__)
+#include <dev/ofw/openfirmio.h>
+#endif
#include "xf86.h"
#include "xf86Priv.h"
#include "xf86_OSlib.h"
@@ -50,7 +53,6 @@ static int promP1275 = -1;
#define MAX_PROP 128
#define MAX_VAL (4096-128-4)
-static struct openpromio *promOpio;
sbusDevicePtr *xf86SbusInfo = NULL;
@@ -68,68 +70,75 @@ struct sbus_devtable sbusDeviceTable[] =
{SBUS_DEVICE_GT, FBTYPE_SUNGT, "gt", NULL, "Sun Graphics Tower"},
{SBUS_DEVICE_MGX, -1, "mgx", NULL, "Quantum 3D MGXplus"},
{SBUS_DEVICE_LEO, FBTYPE_SUNLEO, "leo", "sunleo", "Sun ZX or Turbo ZX"},
- {SBUS_DEVICE_TCX, FBTYPE_TCXCOLOR, "tcx", "suntcx", "Sun TCX"},
+ {SBUS_DEVICE_TCX, FBTYPE_TCXCOLOR, "tcx", "suntcx", "Sun TCX or S24"},
{SBUS_DEVICE_FFB, FBTYPE_CREATOR, "ffb", "sunffb", "Sun FFB"},
{SBUS_DEVICE_FFB, FBTYPE_CREATOR, "afb", "sunffb", "Sun Elite3D"},
+ {SBUS_DEVICE_P9100, FBTYPE_P9100, "pnozz", "pnozz", "Weitek P9100"},
+ {SBUS_DEVICE_AG10E, FBTYPE_AG10E, "ag10e", "ag10e", "Fujitsu AG-10e"},
{0, 0, NULL}
};
+static struct ofiocdesc ofio;
+static char of_buf[256];
+
int
promGetSibling(int node)
{
- promOpio->oprom_size = sizeof(int);
if (node == -1)
return 0;
- *(int *) promOpio->oprom_array = node;
- if (ioctl(promFd, OPROMNEXT, promOpio) < 0)
+ if (ioctl(promFd, OFIOCGETNEXT, &node) < 0)
return 0;
- promCurrentNode = *(int *) promOpio->oprom_array;
- return *(int *) promOpio->oprom_array;
+ promCurrentNode = node;
+ return node;
}
int
promGetChild(int node)
{
- promOpio->oprom_size = sizeof(int);
if (!node || node == -1)
return 0;
- *(int *) promOpio->oprom_array = node;
- if (ioctl(promFd, OPROMCHILD, promOpio) < 0)
+ if (ioctl(promFd, OFIOCGETCHILD, &node) < 0)
return 0;
- promCurrentNode = *(int *) promOpio->oprom_array;
- return *(int *) promOpio->oprom_array;
+ promCurrentNode = node;
+ return node;
}
char *
promGetProperty(const char *prop, int *lenp)
{
- promOpio->oprom_size = MAX_VAL;
- strcpy(promOpio->oprom_array, prop);
- if (ioctl(promFd, OPROMGETPROP, promOpio) < 0)
+ ofio.of_nodeid = promCurrentNode;
+ ofio.of_name = (char *)prop;
+ ofio.of_namelen = strlen(prop);
+ ofio.of_buf = of_buf;
+ ofio.of_buflen = sizeof(of_buf);
+
+ if (ioctl(promFd, OFIOCGET, &ofio) < 0)
return 0;
+
+ of_buf[ofio.of_buflen] = '\0';
+
if (lenp)
- *lenp = promOpio->oprom_size;
- return promOpio->oprom_array;
+ *lenp = ofio.of_buflen;
+ return of_buf;
}
int
promGetBool(const char *prop)
{
- promOpio->oprom_size = 0;
+ ofio.of_nodeid = promCurrentNode;
+ ofio.of_name = (char *)prop;
+ ofio.of_namelen = strlen(prop);
+ ofio.of_buf = of_buf;
+ ofio.of_buflen = sizeof(of_buf);
- *(int *) promOpio->oprom_array = 0;
- for (;;) {
- promOpio->oprom_size = MAX_PROP;
- if (ioctl(promFd, OPROMNXTPROP, promOpio) < 0)
- return 0;
- if (!promOpio->oprom_size)
- return 0;
- if (!strcmp(promOpio->oprom_array, prop))
- return 1;
- }
+ if (ioctl(promFd, OFIOCGET, &ofio) < 0)
+ return 0;
+ if (ofio.of_buflen < 0)
+ return 0;
+ return 1;
}
#define PROM_NODE_SIBLING 0x01
@@ -180,8 +189,8 @@ promIsP1275(void)
promP1275 = TRUE;
else
promP1275 = FALSE;
-#elif defined(__FreeBSD__)
- promP1275 = TRUE;
+#elif defined(__FreeBSD__) || defined(__NetBSD__)
+ promP1275 = TRUE;
#else
#error Missing promIsP1275() function for this OS
#endif
@@ -198,8 +207,6 @@ sparcPromClose(void)
close(promFd);
promFd = -1;
}
- free(promOpio);
- promOpio = NULL;
promOpenCount = 0;
}
@@ -213,11 +220,6 @@ sparcPromInit(void)
promFd = open("/dev/openprom", O_RDONLY, 0);
if (promFd == -1)
return -1;
- promOpio = (struct openpromio *) malloc(4096);
- if (!promOpio) {
- sparcPromClose();
- return -1;
- }
promRootNode = promGetSibling(0);
if (!promRootNode) {
sparcPromClose();
@@ -399,9 +401,9 @@ sparcPromAssignNodes(void)
* were the types of the cards missed. */
char buffer[64];
int fbNum, devId;
- static struct {
- int devId;
- char *prefix;
+ static const struct {
+ const int devId;
+ const char *prefix;
} procFbPrefixes[] = {
{SBUS_DEVICE_BW2, "BWtwo"},
{SBUS_DEVICE_CG14, "CGfourteen"},
@@ -0,0 +1,15 @@
$NetBSD: patch-hw_xfree86_os-support_bus_xf86Sbus.h,v 1.1 2015/09/20 16:39:18 tnn Exp $
NetBSD/sparc64 support.
--- hw/xfree86/os-support/bus/xf86Sbus.h.orig 2012-05-17 17:09:03.000000000 +0000
+++ hw/xfree86/os-support/bus/xf86Sbus.h
@@ -36,6 +36,8 @@
#elif defined(SVR4)
#include <sys/fbio.h>
#include <sys/openpromio.h>
+#elif defined(__NetBSD__) && defined(__sparc64__)
+#include <dev/sun/fbio.h>
#elif defined(__OpenBSD__) && defined(__sparc64__)
/* XXX */
#elif defined(CSRG_BASED)