1 # Buildsheet autogenerated by ravenadm tool -- Do not edit.
6 VARIANTS= standard virtual dmx xephyr nest wayland
7 SDESC[xephyr]= X server from X.Org based on kdrive
8 SDESC[virtual]= X virtual framebuffer server from X.Org
9 SDESC[wayland]= X Clients under Wayland
10 SDESC[standard]= X.Org X server and related programs
11 SDESC[dmx]= Distributed Multihead X from X.Org
12 SDESC[nest]= Nesting X server from X.Org
13 HOMEPAGE= https://www.x.org/
17 SITES[main]= XORG/individual/xserver
18 DISTFILE[1]= xorg-server-1.19.6.tar.bz2:main
21 SPKGS[virtual]= single
22 SPKGS[wayland]= single
23 SPKGS[standard]= single
27 OPTIONS_AVAILABLE= XORG VIRTUAL DMX XEPHYR NEST WAYLAND DEVD SUID
28 OPTIONS_STANDARD= XORG DEVD SUID
29 VOPTS[xephyr]= XORG=OFF VIRTUAL=OFF DMX=OFF XEPHYR=ON NEST=OFF
30 WAYLAND=OFF DEVD=OFF SUID=OFF
31 VOPTS[virtual]= XORG=OFF VIRTUAL=ON DMX=OFF XEPHYR=OFF NEST=OFF
32 WAYLAND=OFF DEVD=OFF SUID=OFF
33 VOPTS[wayland]= XORG=OFF VIRTUAL=OFF DMX=OFF XEPHYR=OFF NEST=OFF
34 WAYLAND=ON DEVD=OFF SUID=OFF
35 VOPTS[dmx]= XORG=OFF VIRTUAL=OFF DMX=ON XEPHYR=OFF NEST=OFF
36 WAYLAND=OFF DEVD=OFF SUID=OFF
37 VOPTS[nest]= XORG=OFF VIRTUAL=OFF DMX=OFF XEPHYR=OFF NEST=ON
38 WAYLAND=OFF DEVD=OFF SUID=OFF
39 OPT_ON[all]= XORG SUID
41 BUILD_DEPENDS= xorg-fontutil:single:standard
42 xorg-xkbfile:single:standard
43 RUN_DEPENDS= xorg-xkeyboard-config:single:standard
44 xorg-xkbcomp:single:standard
46 USES= gmake libtool perl:build ssl
47 XORG_COMPONENTS= bigreqsproto compositeproto damageproto dri2proto
48 dri3proto fixesproto fontsproto glproto inputproto
49 kbproto pixman presentproto randrproto recordproto
50 renderproto resourceproto scrnsaverproto videoproto
51 xtransproto xcmiscproto xextproto xf86driproto
52 xineramaproto xproto xshmfence xau xdmcp xfont2
54 FPC_EQUIVALENT= x11-servers/xorg-server
57 CONFIGURE_ARGS= --with-xkb-path={{LOCALBASE}}/share/X11/xkb
58 --with-fontrootdir={{LOCALBASE}}/share/fonts
63 --with-shared-memory-dir=/tmp
66 --disable-config-udev-kms
67 --disable-install-setuid
72 INSTALL_TARGET= install-strip
74 VAR_OPSYS[sunos]= CFLAGS=-DO_CLOEXEC=0
76 [DEVD].DESCRIPTION= Use devd for autoconfiguration of input devices
78 [NEST].DESCRIPTION= Build as nesting X server
79 [NEST].BUILD_DEPENDS_ON= libepoxy:single:standard
81 [NEST].CONFIGURE_ENABLE_BOTH= xnest
83 [NEST].XORG_COMPONENTS_ON= x11
86 [XEPHYR].DESCRIPTION= Build as kdrive-base X server
87 [XEPHYR].BUILDRUN_DEPENDS_ON= libdrm:single:standard
88 libepoxy:single:standard
89 [XEPHYR].BUILD_DEPENDS_ON= mesa:drivers:standard
90 [XEPHYR].CONFIGURE_ENABLE_BOTH= xephyr
92 [XEPHYR].USES_ON= mesa
93 [XEPHYR].XORG_COMPONENTS_ON= x11
101 [DMX].DESCRIPTION= Build as distributed multihead X server
102 [DMX].BUILD_DEPENDS_ON= libepoxy:single:standard
103 mesa:drivers:standard
104 xorg-xtst:single:standard
105 xorg-xres:single:standard
106 [DMX].CONFIGURE_ENABLE_BOTH= dmx
107 [DMX].XORG_COMPONENTS_ON= dmx
118 [VIRTUAL].DESCRIPTION= Build as virtual framebuffer server
119 [VIRTUAL].BUILD_DEPENDS_ON= libepoxy:single:standard
120 mesa:drivers:standard
121 [VIRTUAL].CONFIGURE_ENABLE_BOTH= xvfb
122 [VIRTUAL].USES_ON= mesa
124 [XORG].DESCRIPTION= Build as X server (don't change setting!)
125 [XORG].BUILDRUN_DEPENDS_ON= libdrm:single:standard
126 libepoxy:single:standard
127 mesa:drivers:standard
128 [XORG].CONFIGURE_ENABLE_BOTH= docs
131 [XORG].SUB_FILES_ON= pkg-install-single
134 [XORG].XORG_COMPONENTS_ON= pciaccess
139 [WAYLAND].DESCRIPTION= Build Wayland X clients
140 [WAYLAND].BROKEN_ON= Wayland itself not yet implemented
141 [WAYLAND].BUILDRUN_DEPENDS_ON= libdrm:single:standard
142 libepoxy:single:standard
143 [WAYLAND].BUILD_DEPENDS_ON= mesa:drivers:standard
144 [WAYLAND].CONFIGURE_ARGS_ON= --disable-xquartz
146 [WAYLAND].CONFIGURE_ENABLE_BOTH= xwayland
147 [WAYLAND].XORG_COMPONENTS_ON= x11
150 [SUID].DESCRIPTION= Install the Xorg server with setuid bit set
153 # build libglx.so but don't install it yet. (done in pre-install)
154 @${REINPLACE_CMD} -e 's|@GLX_TRUE@GLXMODS =|@GLX_BOGUS@GLXMODS =|g' \
155 -e 's|^LTLIBRARIES = |LTLIBRARIES = libglx.la |g' \
156 ${WRKSRC}/hw/xfree86/dixmods/Makefile.in
158 do-install-XEPHYR-ON:
159 (cd ${WRKSRC}/hw/kdrive/ephyr && \
160 DESTDIR=${STAGEDIR} ${MAKE_CMD} install)
162 do-install-WAYLAND-ON:
163 (cd ${WRKSRC}/hw/xwayland && \
164 DESTDIR=${STAGEDIR} ${MAKE_CMD} install)
166 post-install-XORG-OFF:
167 ${RM} -r ${STAGEDIR}${PREFIX}/lib/xorg
168 ${RM} ${STAGEDIR}${PREFIX}/share/man/man1/Xserver.1
170 post-configure-DEVD-ON:
171 @${REINPLACE_CMD} -e 's|config\.c|config.c devd.c|g' \
172 -e 's|config\.lo|config.lo devd.lo|g' \
173 ${WRKSRC}/config/Makefile
174 @${REINPLACE_CMD} -e 's|^/\* #undef CONFIG_UDEV \*/|#define CONFIG_DEVD 1|' \
175 ${WRKSRC}/include/dix-config.h
177 do-install-VIRTUAL-ON:
178 (cd ${WRKSRC}/hw/vfb && \
179 DESTDIR=${STAGEDIR} ${MAKE_CMD} install)
182 (cd ${WRKSRC}/hw/xnest && \
183 DESTDIR=${STAGEDIR} ${MAKE_CMD} install)
186 (cd ${WRKSRC}/hw/dmx && \
187 DESTDIR=${STAGEDIR} ${MAKE_CMD} install)
189 post-install-XORG-ON:
190 # The .xorg dir because else the xorg-server might not load the
191 # correct libglx module.
192 @${MKDIR} ${STAGEDIR}${PREFIX}/lib/xorg/modules/extensions/.xorg
193 ${INSTALL_LIB} ${WRKSRC}/hw/xfree86/dixmods/.libs/libglx.so \
194 ${STAGEDIR}${PREFIX}/lib/xorg/modules/extensions/.xorg/
195 @${MKDIR} ${STAGEDIR}${PREFIX}/etc/X11/xorg.conf.d
196 ${RM} -r ${STAGEDIR}/var
198 [FILE:71:descriptions/desc.single.standard]
199 This package contains the X.Org X server and some associated programs.
202 [FILE:60:descriptions/desc.single.virtual]
203 This package contains Xvfb, a virtual framebuffer X server.
206 [FILE:287:descriptions/desc.single.dmx]
207 Xdmx is proxy X server that provides multi-head support for multiple
208 displays attached to different machines (each of which is running a
209 typical X server). When Xinerama is used with Xdmx, the multiple displays
210 on multiple machines are presented to the user as a single unified screen.
213 [FILE:173:descriptions/desc.single.xephyr]
214 Xephyr is a kdrive server that outputs to a window on a pre-existing
215 'host' X display. Think Xnest but with support for modern extensions
216 like composite, damage and randr.
219 [FILE:78:descriptions/desc.single.nest]
220 This package contains Xnest, a nesting X Server that displays on an X
224 [FILE:148:descriptions/desc.single.wayland]
225 XWayland is an X Server running as a Wayland client, thus capable of
226 displaying native X11 client applications in a Wayland compositor
231 a732502f1db000cf36a376cd0c010ffdbf32ecdd7f1fa08ba7f5bdf9601cc197 5984528 xorg-server-1.19.6.tar.bz2
234 [FILE:2477:manifests/plist.single.standard]
237 %%SUID-ON%%@(,,4555) bin/Xorg
348 %%ONLY-SUNOS%%include/xorg/solaris-amd64.il
401 lib/xorg/modules/drivers/modesetting_drv.so
402 lib/xorg/modules/extensions/.xorg/libglx.so
414 lib/xorg/protocol.txt
415 lib/pkgconfig/xorg-server.pc
428 share/aclocal/xorg-server.m4
429 @dir etc/X11/xorg.conf.d
432 [FILE:34:manifests/plist.single.virtual]
434 share/man/man1/Xvfb.1.gz
437 [FILE:214:manifests/plist.single.dmx]
458 [FILE:38:manifests/plist.single.xephyr]
460 share/man/man1/Xephyr.1.gz
463 [FILE:36:manifests/plist.single.nest]
465 share/man/man1/Xnest.1.gz
468 [FILE:13:manifests/plist.single.wayland]
472 [FILE:293:patches/patch-config_config-backends.h]
473 --- config/config-backends.h.orig 2017-12-20 20:32:33 UTC
474 +++ config/config-backends.h
475 @@ -44,3 +44,8 @@ void config_hal_fini(void);
476 int config_wscons_init(void);
477 void config_wscons_fini(void);
481 +int config_devd_init(void);
482 +void config_devd_fini(void);
486 [FILE:537:patches/patch-config_config.c]
487 --- config/config.c.orig 2017-12-20 20:32:33 UTC
489 @@ -55,6 +55,9 @@ config_init(void)
490 #elif defined(CONFIG_WSCONS)
491 if (!config_wscons_init())
492 ErrorF("[config] failed to initialise wscons\n");
493 +#elif defined(CONFIG_DEVD)
494 + if (!config_devd_init())
495 + ErrorF("[config] failed to initialise devd\n");
499 @@ -67,6 +70,8 @@ config_fini(void)
501 #elif defined(CONFIG_WSCONS)
502 config_wscons_fini();
503 +#elif defined(CONFIG_DEVD)
504 + config_devd_fini();
510 [FILE:12171:patches/patch-config_devd.c]
511 --- /dev/null 2018-02-08 20:22:25 UTC
515 + * Copyright (c) 2012 Baptiste Daroussin
516 + * Copyright (c) 2013, 2014 Alex Kozlov
517 + * Copyright (c) 2014 Robert Millan
518 + * Copyright (c) 2014 Jean-Sebastien Pedron
520 + * Permission is hereby granted, free of charge, to any person obtaining a
521 + * copy of this software and associated documentation files (the "Software"),
522 + * to deal in the Software without restriction, including without limitation
523 + * the rights to use, copy, modify, merge, publish, distribute, sublicense,
524 + * and/or sell copies of the Software, and to permit persons to whom the
525 + * Software is furnished to do so, subject to the following conditions:
527 + * The above copyright notice and this permission notice (including the next
528 + * paragraph) shall be included in all copies or substantial portions of the
531 + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
532 + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
533 + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
534 + * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
535 + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
536 + * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
537 + * DEALINGS IN THE SOFTWARE.
539 + * Author: Baptiste Daroussin <bapt@FreeBSD.org>
542 +#ifdef HAVE_DIX_CONFIG_H
543 +#include <dix-config.h>
546 +#include <sys/types.h>
547 +#include <sys/kbio.h>
548 +#include <sys/socket.h>
549 +#include <sys/stat.h>
550 +#include <sys/sysctl.h>
558 +#include <stdbool.h>
562 +#include "inputstr.h"
563 +#include "hotplug.h"
564 +#include "config-backends.h"
567 +#define DEVD_SOCK_PATH "/var/run/devd.pipe"
569 +#define DEVD_EVENT_ADD '+'
570 +#define DEVD_EVENT_REMOVE '-'
572 +#define RECONNECT_DELAY 5 * 1000
574 +static int sock_devd;
575 +static bool is_console_kbd = false;
576 +static bool is_kbdmux = false;
577 +static OsTimerPtr rtimer = NULL;
580 + const char *driver;
582 + const char *xdriver;
585 +static struct hw_type hw_types[] = {
586 + { "ukbd", ATTR_KEYBOARD, "kbd" },
587 + { "atkbd", ATTR_KEYBOARD, "kbd" },
588 + { "kbdmux", ATTR_KEYBOARD, "kbd" },
589 + { "sysmouse", ATTR_POINTER, "mouse" },
590 + { "ums", ATTR_POINTER, "mouse" },
591 + { "psm", ATTR_POINTER, "mouse" },
592 + { "vboxguest", ATTR_POINTER, "vboxmouse" },
593 + { "joy", ATTR_JOYSTICK, NULL },
594 + { "atp", ATTR_TOUCHPAD, NULL },
595 + { "uep", ATTR_TOUCHSCREEN, NULL },
596 + { NULL, -1, NULL },
600 +sysctl_exists(const struct hw_type *device, int unit,
601 + char *devname, size_t devname_len)
603 + char sysctlname[PATH_MAX];
607 + if (device == NULL || device->driver == NULL)
610 + /* Check if a sysctl exists. */
611 + snprintf(sysctlname, sizeof(sysctlname), "dev.%s.%i.%%desc",
612 + device->driver, unit);
613 + ret = sysctlbyname(sysctlname, NULL, &len, NULL, 0);
615 + if (ret == 0 && len > 0) {
616 + snprintf(devname, devname_len, "%s%i", device->driver, unit);
624 +devpath_exists(const struct hw_type *device,
625 + char *devname, size_t devname_len)
631 + if (device == NULL || device->driver == NULL)
634 + /* Check if /dev/$driver exists. */
635 + asprintf(&devpath, "/dev/%s", device->driver);
636 + if (devpath == NULL)
639 + ret = stat(devpath, &st);
643 + strncpy(devname, device->driver, devname_len);
651 +sysctl_get_str(const char *sysctlname)
656 + if (sysctlname == NULL)
659 + if (sysctlbyname(sysctlname, NULL, &len, NULL, 0) == 0) {
660 + dest = malloc(len + 1);
662 + if (sysctlbyname(sysctlname, dest, &len, NULL, 0) == 0)
675 +device_added(const char *devname)
677 + char path[PATH_MAX];
678 + char sysctlname[PATH_MAX];
680 + char *product = NULL;
681 + char *config_info = NULL;
683 + InputOption *options = NULL;
684 + InputAttributes attrs = { };
685 + DeviceIntPtr dev = NULL;
689 + for (i = 0; hw_types[i].driver != NULL; i++) {
692 + len = strlen(hw_types[i].driver);
693 + if (strcmp(devname, hw_types[i].driver) == 0 ||
694 + (strncmp(devname, hw_types[i].driver, len) == 0 &&
695 + isnumber(*(devname + len)))) {
696 + attrs.flags |= hw_types[i].flag;
701 + if (hw_types[i].driver == NULL || hw_types[i].xdriver == NULL) {
702 + LogMessage(X_INFO, "config/devd: ignoring device %s\n",
707 + /* Skip keyboard devices if kbdmux is enabled */
708 + if (is_kbdmux && is_console_kbd && hw_types[i].flag & ATTR_KEYBOARD) {
709 + LogMessage(X_INFO, "config/devd: kbdmux is enabled, ignoring device %s\n",
714 + snprintf(path, sizeof(path), "/dev/%s", devname);
716 + options = input_option_new(NULL, "_source", "server/devd");
720 + snprintf(sysctlname, sizeof(sysctlname), "dev.%s.%s.%%desc",
721 + hw_types[i].driver, devname + strlen(hw_types[i].driver));
722 + vendor = sysctl_get_str(sysctlname);
723 + if (vendor == NULL) {
724 + options = input_option_new(options, "name", devname);
727 + if ((walk = strchr(vendor, ' ')) != NULL) {
731 + if ((walk = strchr(product, ',')) != NULL)
735 + attrs.vendor = strdup(vendor);
737 + attrs.product = strdup(product);
738 + options = input_option_new(options, "name", product);
741 + options = input_option_new(options, "name", "(unnamed)");
746 + /* XXX implement usb_id */
747 + attrs.usb_id = NULL;
748 + attrs.device = strdup(path);
749 + options = input_option_new(options, "driver", hw_types[i].xdriver);
751 + fd = open(path, O_RDONLY);
754 + options = input_option_new(options, "device", path);
757 + if (attrs.flags & ~ATTR_KEYBOARD) {
758 + LogMessage(X_INFO, "config/devd: device %s already opened\n",
762 + * Fail if cannot open device, it breaks AllowMouseOpenFail,
763 + * but it should not matter when config/devd enabled
768 + if (is_console_kbd) {
770 + * There can be only one keyboard attached to console and
771 + * it is already added.
773 + LogMessage(X_WARNING, "config/devd: console keyboard is "
774 + "already added, ignoring %s (%s)\n",
775 + attrs.product, path);
780 + * Don't pass "device" option if the keyboard is already
781 + * attached to the console (ie. open() fails).
782 + * This would activate a special logic in xf86-input-keyboard.
783 + * Prevent any other attached to console keyboards being
784 + * processed. There can be only one such device.
786 + is_console_kbd = true;
789 + if (asprintf(&config_info, "devd:%s", devname) == -1) {
790 + config_info = NULL;
794 + if (device_is_duplicate(config_info)) {
795 + LogMessage(X_WARNING, "config/devd: device %s (%s) already added. "
796 + "ignoring\n", attrs.product, path);
800 + options = input_option_new(options, "config_info", config_info);
801 + LogMessage(X_INFO, "config/devd: adding input device %s (%s)\n",
802 + attrs.product, path);
804 + NewInputDeviceRequest(options, &attrs, &dev);
808 + input_option_free_list(&options);
809 + free(attrs.usb_id);
810 + free(attrs.product);
811 + free(attrs.device);
812 + free(attrs.vendor);
816 +device_removed(char *devname)
820 + if (asprintf(&config_info, "devd:%s", devname) == -1)
823 + remove_devices("devd", config_info);
828 +static bool is_kbdmux_enabled(void)
830 + /* Xorg uses /dev/ttyv0 as a console device */
831 + /* const char device[]="/dev/console"; */
832 + const char device[]="/dev/ttyv0";
833 + keyboard_info_t info;
836 + fd = open(device, O_RDONLY);
841 + if (ioctl(fd, KDGKBINFO, &info) == -1) {
848 + if (!strncmp(info.kb_name, "kbdmux", 6))
855 +disconnect_devd(int sock)
858 + RemoveGeneralSocket(sock);
866 + struct sockaddr_un devd;
869 + sock = socket(AF_UNIX, SOCK_STREAM, 0);
871 + LogMessage(X_ERROR, "config/devd: fail opening stream socket\n");
875 + devd.sun_family = AF_UNIX;
876 + strlcpy(devd.sun_path, DEVD_SOCK_PATH, sizeof(devd.sun_path));
878 + if (connect(sock, (struct sockaddr *) &devd, sizeof(devd)) < 0) {
880 + LogMessage(X_ERROR, "config/devd: fail to connect to devd\n");
884 + AddGeneralSocket(sock);
890 +reconnect_handler(OsTimerPtr timer, CARD32 time, void *arg)
894 + if ((newsock = connect_devd()) > 0) {
895 + sock_devd = newsock;
898 + LogMessage(X_INFO, "config/devd: reopening devd socket\n");
902 + /* Try again after RECONNECT_DELAY */
903 + return RECONNECT_DELAY;
907 +socket_getline(int fd, char **out)
909 + char *buf, *newbuf;
910 + ssize_t ret, cap, sz = 0;
914 + buf = malloc(cap * sizeof(char));
919 + ret = read(sock_devd, &c, 1);
921 + if (errno == EINTR)
925 + /* EOF - devd socket is lost */
926 + } else if (ret == 0) {
927 + disconnect_devd(sock_devd);
928 + rtimer = TimerSet(NULL, 0, 1, reconnect_handler, NULL);
929 + LogMessage(X_WARNING, "config/devd: devd socket is lost\n");
936 + if (sz + 1 >= cap) {
938 + newbuf = realloc(buf, cap * sizeof(char));
955 + /* Number of bytes in the line, not counting the line break */
960 +wakeup_handler(void *data, int err, void *read_mask)
968 + if (FD_ISSET(sock_devd, (fd_set *) read_mask)) {
969 + if (socket_getline(sock_devd, &line) < 0)
972 + walk = strchr(line + 1, ' ');
977 + case DEVD_EVENT_ADD:
978 + device_added(line + 1);
980 + case DEVD_EVENT_REMOVE:
981 + device_removed(line + 1);
991 +block_handler(void *data, struct timeval **tv, void *read_mask)
996 +config_devd_init(void)
998 + char devicename[1024];
1001 + LogMessage(X_INFO, "config/devd: probing input devices...\n");
1004 + * Add fake keyboard and give up on keyboards management
1005 + * if kbdmux is enabled
1007 + if ((is_kbdmux = is_kbdmux_enabled()) == true)
1008 + device_added("kbdmux");
1010 + for (i = 0; hw_types[i].driver != NULL; i++) {
1011 + /* First scan the sysctl to determine the hardware */
1012 + for (j = 0; j < 16; j++) {
1013 + if (sysctl_exists(&hw_types[i], j,
1014 + devicename, sizeof(devicename)) != 0)
1015 + device_added(devicename);
1018 + if (devpath_exists(&hw_types[i], devicename, sizeof(devicename)) != 0)
1019 + device_added(devicename);
1022 + if ((sock_devd = connect_devd()) < 0)
1025 + RegisterBlockAndWakeupHandlers(block_handler, wakeup_handler, NULL);
1031 +config_devd_fini(void)
1033 + LogMessage(X_INFO, "config/devd: terminating backend...\n");
1036 + TimerFree(rtimer);
1040 + disconnect_devd(sock_devd);
1042 + RemoveBlockAndWakeupHandlers(block_handler, wakeup_handler, NULL);
1044 + is_console_kbd = false;
1048 [FILE:1457:patches/patch-configure]
1049 --- configure.orig 2017-12-20 20:32:47 UTC
1051 @@ -12101,7 +12101,6 @@ fi
1053 if test x$FILE_MAN_SUFFIX = x ; then
1055 - solaris*) FILE_MAN_SUFFIX=4 ;;
1056 *) FILE_MAN_SUFFIX=5 ;;
1059 @@ -12111,7 +12110,6 @@ fi
1061 if test x$MISC_MAN_SUFFIX = x ; then
1063 - solaris*) MISC_MAN_SUFFIX=5 ;;
1064 *) MISC_MAN_SUFFIX=7 ;;
1067 @@ -12121,7 +12119,6 @@ fi
1069 if test x$DRIVER_MAN_SUFFIX = x ; then
1071 - solaris*) DRIVER_MAN_SUFFIX=7 ;;
1072 *) DRIVER_MAN_SUFFIX=4 ;;
1075 @@ -12131,7 +12128,6 @@ fi
1077 if test x$ADMIN_MAN_SUFFIX = x ; then
1079 - solaris*) ADMIN_MAN_SUFFIX=1m ;;
1080 *) ADMIN_MAN_SUFFIX=8 ;;
1083 @@ -21754,7 +21750,7 @@ if test `${RAWCPP} < conftest.$ac_ext |
1084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
1085 $as_echo "no" >&6; }
1087 - if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then
1089 TRADITIONALCPPFLAGS="-traditional"
1090 RAWCPPFLAGS="${RAWCPPFLAGS} -traditional"
1091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
1092 @@ -23263,9 +23259,14 @@ $as_echo "#define USE_ALPHA_PIO 1" >>con
1094 GLX_ARCH_DEFINES="-D__GLX_ALIGN64 -mieee"
1099 DEFAULT_INT10="stub"
1102 + $as_echo "#define USE_DEV_IO 1" >>confdefs.h
1110 [FILE:256:patches/patch-hw_kdrive_ephyr_hostx.c]
1111 --- hw/kdrive/ephyr/hostx.c.orig 2017-12-20 20:32:33 UTC
1112 +++ hw/kdrive/ephyr/hostx.c
1114 #include <string.h> /* for memset */
1119 #include <sys/ipc.h>
1120 #include <sys/shm.h>
1123 [FILE:785:patches/patch-hw_xfree86_common_xf86AutoConfig.c]
1124 --- hw/xfree86/common/xf86AutoConfig.c.orig 2017-12-20 20:32:33 UTC
1125 +++ hw/xfree86/common/xf86AutoConfig.c
1126 @@ -276,7 +276,7 @@ listPossibleVideoDrivers(char *matches[]
1127 i += xf86PciMatchDriver(&matches[i], nmatches - i);
1130 -#if defined(__linux__)
1131 +#if defined(__linux__) || defined(__FreeBSD__) || defined(__DragonFly__)
1132 matches[i++] = xnfstrdup("modesetting");
1135 @@ -285,8 +285,10 @@ listPossibleVideoDrivers(char *matches[]
1136 if (i < (nmatches - 1)) {
1137 #if !defined(__linux__) && defined(__sparc__)
1138 matches[i++] = xnfstrdup("wsfb");
1140 +#elif defined(__linux__)
1141 matches[i++] = xnfstrdup("fbdev");
1142 +#elif defined(__FreeBSD__)
1143 + matches[i++] = xnfstrdup("scfb");
1149 [FILE:700:patches/patch-hw_xfree86_common_xf86Config.c]
1150 --- hw/xfree86/common/xf86Config.c.orig 2017-12-20 20:32:33 UTC
1151 +++ hw/xfree86/common/xf86Config.c
1152 @@ -1375,13 +1375,16 @@ checkCoreInputDevices(serverLayoutPtr se
1155 if (!xf86Info.forceInputDevices && !(foundPointer && foundKeyboard)) {
1156 -#if defined(CONFIG_HAL) || defined(CONFIG_UDEV) || defined(CONFIG_WSCONS)
1157 +#if defined(CONFIG_HAL) || defined(CONFIG_UDEV) || defined(CONFIG_WSCONS) || \
1158 + defined(CONFIG_DEVD)
1159 const char *config_backend;
1161 #if defined(CONFIG_HAL)
1162 config_backend = "HAL";
1163 #elif defined(CONFIG_UDEV)
1164 config_backend = "udev";
1165 +#elif defined(CONFIG_DEVD)
1166 + config_backend = "devd";
1168 config_backend = "wscons";
1172 [FILE:496:patches/patch-hw_xfree86_common_xf86Globals.c]
1173 --- hw/xfree86/common/xf86Globals.c.orig 2017-12-20 20:32:33 UTC
1174 +++ hw/xfree86/common/xf86Globals.c
1175 @@ -122,7 +122,8 @@ xf86InfoRec xf86Info = {
1177 .disableRandR = FALSE,
1178 .randRFrom = X_DEFAULT,
1179 -#if defined(CONFIG_HAL) || defined(CONFIG_UDEV) || defined(CONFIG_WSCONS)
1180 +#if defined(CONFIG_HAL) || defined(CONFIG_UDEV) || defined(CONFIG_WSCONS) || \
1181 + defined(CONFIG_DEVD)
1182 .forceInputDevices = FALSE,
1183 .autoAddDevices = TRUE,
1184 .autoEnableDevices = TRUE,
1187 [FILE:690:patches/patch-hw_xfree86_common_xf86Xinput.c]
1188 --- hw/xfree86/common/xf86Xinput.c.orig 2017-12-20 20:32:33 UTC
1189 +++ hw/xfree86/common/xf86Xinput.c
1190 @@ -874,7 +874,7 @@ xf86NewInputDevice(InputInfoPtr pInfo, D
1192 InputDriverPtr drv = NULL;
1193 DeviceIntPtr dev = NULL;
1199 @@ -1037,6 +1037,7 @@ NewInputDeviceRequest(InputOption *optio
1200 if (strcmp(key, "_source") == 0 &&
1201 (strcmp(value, "server/hal") == 0 ||
1202 strcmp(value, "server/udev") == 0 ||
1203 + strcmp(value, "server/devd") == 0 ||
1204 strcmp(value, "server/wscons") == 0)) {
1206 if (!xf86Info.autoAddDevices) {
1209 [FILE:450:patches/patch-hw_xfree86_os-support_bsd_bsd__init.c]
1210 --- hw/xfree86/os-support/bsd/bsd_init.c.orig 2017-12-20 20:32:33 UTC
1211 +++ hw/xfree86/os-support/bsd/bsd_init.c
1212 @@ -230,6 +230,9 @@ xf86OpenConsole()
1213 * Add cases for other *BSD that behave the same.
1215 #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
1216 +#if defined(__sparc64__)
1217 + pci_system_init_dev_mem(fd);
1220 i = atof(uts.release) * 100;
1224 [FILE:315:patches/patch-hw_xfree86_os-support_bsd_i386__video.c]
1225 Index: programs/Xserver/hw/xfree86/os-support/bsd/i386_video.c
1226 --- hw/xfree86/os-support/bsd/i386_video.c.orig 2017-12-20 20:32:33 UTC
1227 +++ hw/xfree86/os-support/bsd/i386_video.c
1229 #include "xf86Priv.h"
1232 +#include <sys/types.h>
1233 #include <sys/mman.h>
1235 #include "xf86_OSlib.h"
1238 [FILE:380:patches/patch-hw_xfree86_os-support_bsd_ppc__video.c]
1239 --- hw/xfree86/os-support/bsd/ppc_video.c.orig 2017-12-20 20:32:33 UTC
1240 +++ hw/xfree86/os-support/bsd/ppc_video.c
1241 @@ -79,7 +79,11 @@ xf86DisableIO()
1244 if (ioBase != MAP_FAILED) {
1245 +#if defined(__FreeBSD__)
1246 + munmap(__DEVOLATILE(unsigned char *, ioBase), 0x10000);
1248 munmap(__UNVOLATILE(ioBase), 0x10000);
1250 ioBase = MAP_FAILED;
1255 [FILE:714:patches/patch-hw_xfree86_os-support_solaris_sun__init.c]
1256 --- hw/xfree86/os-support/solaris/sun_init.c.orig 2017-12-20 20:32:33 UTC
1257 +++ hw/xfree86/os-support/solaris/sun_init.c
1258 @@ -54,6 +54,22 @@ static int xf86StartVT = -1;
1259 static int vtEnabled = 0;
1263 +#define VTIOC ('V'<<8)
1264 +#define VT_OPENQRY (VTIOC|1)
1265 +#define VT_SETMODE (VTIOC|2)
1266 +#define VT_GETMODE (VTIOC|3)
1267 +#define VT_ACTIVATE (VTIOC|5)
1268 +#define VT_WAITACTIVE (VTIOC|6)
1269 +#define VT_GETSTATE (VTIOC|100)
1270 +#define VT_ENABLED (VTIOC|101)
1271 +#define VT_SETDISPINFO (VTIOC|103)
1272 +#define VT_GET_CONSUSER (VTIOC|108)
1273 +#define VT_SET_CONSUSER (VTIOC|109)
1275 +enum { VT_AUTO = 0, VT_PROCESS };
1278 /* Device to open as xf86Info.consoleFd */
1279 static char consoleDev[PATH_MAX] = "/dev/fb";
1283 [FILE:193:patches/patch-os_backtrace.c]
1284 --- os/backtrace.c.orig 2017-12-20 20:32:33 UTC
1290 +#include <unistd.h>
1292 #ifdef HAVE_LIBUNWIND
1296 [FILE:1021:patches/patch-test_simple-xinit.c]
1297 --- test/simple-xinit.c.orig 2017-12-20 20:32:33 UTC
1298 +++ test/simple-xinit.c
1300 #include <sys/wait.h>
1304 +#include <sys/varargs.h>
1306 +vasprintf(char **strp, const char *fmt, va_list args)
1308 + va_list args_copy;
1309 + int status, needed;
1311 + va_copy(args_copy, args);
1312 + needed = vsnprintf(NULL, 0, fmt, args_copy);
1313 + va_end(args_copy);
1318 + *strp = malloc(needed + 1);
1319 + if (*strp == NULL)
1321 + status = vsnprintf(*strp, needed + 1, fmt, args);
1332 +asprintf(char **strp, const char *fmt, ...)
1337 + va_start(args, fmt);
1338 + status = vasprintf(strp, fmt, args);
1345 kill_server(int server_pid)
1349 [FILE:215:patches/patch-xkb_Makefile.in]
1350 --- xkb/Makefile.in.orig 2017-12-20 20:32:55 UTC
1352 @@ -886,7 +886,7 @@ info: info-am
1356 -install-data-am: install-dist_xkbcompiledDATA
1359 install-dvi: install-dvi-am
1363 [FILE:135:files/pkg-deinstall-single.in]
1366 PREFIX="${PKG_PREFIX-/raven}"
1370 /bin/rm -rf ${PREFIX}/lib/xorg/modules/extensions/libglx.so*
1375 [FILE:531:files/pkg-install-single.in]
1378 PREFIX="${PKG_PREFIX-/raven}"
1382 if [ -f ${PREFIX}/lib/xorg/modules/extensions/.nvidia/libglx.so.1 ]; then
1383 /bin/ln -f ${PREFIX}/lib/xorg/modules/extensions/.nvidia/libglx.so.1 \
1384 ${PREFIX}/lib/xorg/modules/extensions/libglx.so
1385 /bin/ln -f ${PREFIX}/lib/xorg/modules/extensions/.nvidia/libglx.so.1 \
1386 ${PREFIX}/lib/xorg/modules/extensions/libglx.so.1
1388 /bin/ln -f ${PREFIX}/lib/xorg/modules/extensions/.xorg/libglx.so \
1389 ${PREFIX}/lib/xorg/modules/extensions/libglx.so