Commit 4f4b8e00 authored by Michel Dänzer's avatar Michel Dänzer Committed by Michel Dänzer
Browse files

Drop Xorg DDX

parent 8f480147
......@@ -72,7 +72,7 @@ cache:
- '%CYGWIN_ROOT%\home\%USERNAME%\.ccache'
build_script:
- SET PATH=%CYGWIN_ROOT%/bin
- '%CYGWIN_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; meson setup --prefix=/usr -Dxv=false -Dxf86bigfont=true -Dxephyr=true -Dxvfb=true -Dxorg=true -Dhal=false -Dudev=false -Dpciaccess=false -Dint10=false build"'
- '%CYGWIN_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; meson setup --prefix=/usr -Dxv=false -Dxf86bigfont=true -Dxephyr=true -Dxvfb=true -Dhal=false -Dudev=false build"'
- '%CYGWIN_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; meson configure build"'
- '%CYGWIN_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; ninja -C build"'
- '%CYGWIN_ROOT%/bin/bash -lc "cd $APPVEYOR_BUILD_FOLDER; ccache -s"'
......
......@@ -73,5 +73,3 @@ libxserver_xext_vidmode = static_library('libxserver_xext_vidmode',
include_directories: inc,
dependencies: common_dep,
)
install_data(hdrs_xext, install_dir: xorgsdkdir)
......@@ -15,5 +15,3 @@ libxserver_composite = static_library('libxserver_composite',
include_directories: inc,
dependencies: common_dep,
)
install_data(hdrs_composite, install_dir: xorgsdkdir)
......@@ -22,14 +22,3 @@ endif
if host_machine.system() == 'openbsd'
srcs_config += 'wscons.c'
endif
if build_xorg
install_data('10-quirks.conf',
install_dir: join_paths(get_option('datadir'), 'X11/xorg.conf.d'))
endif
libxserver_config = static_library('libxserver_config',
srcs_config,
include_directories: inc,
dependencies: config_dep,
)
......@@ -12,5 +12,3 @@ libxserver_dbe = static_library('libxserver_dbe',
include_directories: inc,
dependencies: common_dep,
)
install_data(hdrs_dbe, install_dir: xorgsdkdir)
......@@ -16,5 +16,3 @@ if build_dri3
dependencies: [ common_dep, libdrm_dep ],
)
endif
install_data(hdrs_dri3, install_dir: xorgsdkdir)
......@@ -16,9 +16,4 @@ libxserver_exa = static_library('libxserver_exa',
srcs_exa,
include_directories: inc,
dependencies: common_dep,
c_args: '-DHAVE_XORG_CONFIG_H'
)
if build_xorg
install_data('exa.h', install_dir: xorgsdkdir)
endif
......@@ -53,5 +53,3 @@ libxserver_wfb = static_library('libxserver_wfb',
pic: true,
build_by_default: false,
)
install_data(hdrs_fb, install_dir: xorgsdkdir)
......@@ -54,7 +54,3 @@ glamor_egl_stubs = static_library('glamor_egl_stubs',
include_directories: inc,
dependencies: common_dep,
)
if build_xorg
install_data('glamor.h', install_dir: xorgsdkdir)
endif
......@@ -51,7 +51,7 @@ if build_glx
endif
srcs_glxdri2 = []
if build_dri2 or build_dri3
if build_dri3
srcs_glxdri2 = files('glxdri2.c')
endif
......@@ -78,6 +78,4 @@ if build_glx
dependency('gl', version: '>= 1.2'),
],
)
install_data(hdrs_vnd, install_dir : xorgsdkdir)
endif
......@@ -6,10 +6,6 @@ if get_option('xvfb')
subdir('vfb')
endif
if build_xorg
subdir('xfree86')
endif
if build_xwayland
subdir('xwayland')
endif
Xorg
Xorg.wrap
Xorg.sh
xorg.conf.example
sdksyms.c
sdksyms.dep
#!/bin/sh
#
# Execute Xorg.wrap if it exists otherwise execute Xorg directly.
# This allows distros to put the suid wrapper in a separate package.
basedir=@SUID_WRAPPER_DIR@
if [ -x "$basedir"/Xorg.wrap ]; then
exec "$basedir"/Xorg.wrap "$@"
else
exec "$basedir"/Xorg "$@"
fi
# Add & Override for this directory and its subdirectories
xf86Build.h
xf86DefModeSet.c
This diff is collapsed.
#ifndef __DGAPROC_H
#define __DGAPROC_H
#include <X11/Xproto.h>
#include "pixmap.h"
#define DGA_CONCURRENT_ACCESS 0x00000001
#define DGA_FILL_RECT 0x00000002
#define DGA_BLIT_RECT 0x00000004
#define DGA_BLIT_RECT_TRANS 0x00000008
#define DGA_PIXMAP_AVAILABLE 0x00000010
#define DGA_INTERLACED 0x00010000
#define DGA_DOUBLESCAN 0x00020000
#define DGA_FLIP_IMMEDIATE 0x00000001
#define DGA_FLIP_RETRACE 0x00000002
#define DGA_COMPLETED 0x00000000
#define DGA_PENDING 0x00000001
#define DGA_NEED_ROOT 0x00000001
typedef struct {
int num; /* A unique identifier for the mode (num > 0) */
const char *name; /* name of mode given in the XF86Config */
int VSync_num;
int VSync_den;
int flags; /* DGA_CONCURRENT_ACCESS, etc... */
int imageWidth; /* linear accessible portion (pixels) */
int imageHeight;
int pixmapWidth; /* Xlib accessible portion (pixels) */
int pixmapHeight; /* both fields ignored if no concurrent access */
int bytesPerScanline;
int byteOrder; /* MSBFirst, LSBFirst */
int depth;
int bitsPerPixel;
unsigned long red_mask;
unsigned long green_mask;
unsigned long blue_mask;
short visualClass;
int viewportWidth;
int viewportHeight;
int xViewportStep; /* viewport position granularity */
int yViewportStep;
int maxViewportX; /* max viewport origin */
int maxViewportY;
int viewportFlags; /* types of page flipping possible */
int offset;
int reserved1;
int reserved2;
} XDGAModeRec, *XDGAModePtr;
/* DDX interface */
extern Bool DGAScreenAvailable(ScreenPtr pScreen);
extern Bool DGAActive(int Index);
extern Bool DGAVTSwitch(void);
extern Bool DGAStealButtonEvent(DeviceIntPtr dev, int Index,
int button, int is_down);
extern Bool DGAStealMotionEvent(DeviceIntPtr dev, int Index, int dx, int dy);
extern Bool DGAStealKeyEvent(DeviceIntPtr dev, int Index,
int key_code, int is_down);
#endif /* __DGAPROC_H */
//
// Extra modes to include as default modes in the X server.
//
// $XFree86: xc/programs/Xserver/hw/xfree86/etc/extramodes,v 1.5 2002/06/05 19:43:05 dawes Exp $
//
# 832x624 @ 75Hz (74.55Hz) (fix if the official/Apple spec is different) hsync: 49.725kHz
ModeLine "832x624" 57.284 832 864 928 1152 624 625 628 667 -Hsync -Vsync
# 1400x1050 @ 60Hz (VESA GTF) hsync: 65.5kHz
ModeLine "1400x1050" 122.0 1400 1488 1640 1880 1050 1052 1064 1082 +hsync +vsync
# 1400x1050 @ 75Hz (VESA GTF) hsync: 82.2kHz
ModeLine "1400x1050" 155.8 1400 1464 1784 1912 1050 1052 1064 1090 +hsync +vsync
# 1920x1440 @ 85Hz (VESA GTF) hsync: 128.5kHz
Modeline "1920x1440" 341.35 1920 2072 2288 2656 1440 1441 1444 1512 -hsync +vsync
# 2048x1536 @ 60Hz (VESA GTF) hsync: 95.3kHz
Modeline "2048x1536" 266.95 2048 2200 2424 2800 1536 1537 1540 1589 -hsync +vsync
# 2048x1536 @ 75Hz (VESA GTF) hsync: 120.2kHz
Modeline "2048x1536" 340.48 2048 2216 2440 2832 1536 1537 1540 1603 -hsync +vsync
# 2048x1536 @ 85Hz (VESA GTF) hsync: 137.0kHz
Modeline "2048x1536" 388.04 2048 2216 2440 2832 1536 1537 1540 1612 -hsync +vsync
### 16:9 modelines generated by cvt
# 640x360 59.32 Hz (CVT 0.23M9-R) hsync: 22.19 kHz; pclk: 17.75 MHz
Modeline "640x360R" 17.75 640 688 720 800 360 363 368 374 +hsync -vsync
# 640x360 59.84 Hz (CVT 0.23M9) hsync: 22.50 kHz; pclk: 18.00 MHz
Modeline "640x360" 18.00 640 664 720 800 360 363 368 376 -hsync +vsync
# 720x405 58.99 Hz (CVT 0.29M9-R) hsync: 24.72 kHz; pclk: 21.75 MHz
Modeline "720x405R" 21.75 720 768 800 880 405 408 413 419 +hsync -vsync
# 720x405 59.51 Hz (CVT 0.29M9) hsync: 25.11 kHz; pclk: 22.50 MHz
Modeline "720x405" 22.50 720 744 808 896 405 408 413 422 -hsync +vsync
# 864x486 59.57 Hz (CVT 0.42M9-R) hsync: 29.79 kHz; pclk: 30.50 MHz
Modeline "864x486R" 30.50 864 912 944 1024 486 489 494 500 +hsync -vsync
# 864x486 59.92 Hz (CVT 0.42M9) hsync: 30.32 kHz; pclk: 32.50 MHz
Modeline "864x486" 32.50 864 888 968 1072 486 489 494 506 -hsync +vsync
# 960x540 59.82 Hz (CVT 0.52M9-R) hsync: 33.26 kHz; pclk: 37.25 MHz
Modeline "960x540R" 37.25 960 1008 1040 1120 540 543 548 556 +hsync -vsync
# 960x540 59.63 Hz (CVT 0.52M9) hsync: 33.51 kHz; pclk: 40.75 MHz
Modeline "960x540" 40.75 960 992 1088 1216 540 543 548 562 -hsync +vsync
# 1024x576 59.82 Hz (CVT 0.59M9-R) hsync: 35.47 kHz; pclk: 42.00 MHz
Modeline "1024x576R" 42.00 1024 1072 1104 1184 576 579 584 593 +hsync -vsync
# 1024x576 59.90 Hz (CVT 0.59M9) hsync: 35.88 kHz; pclk: 46.50 MHz
Modeline "1024x576" 46.50 1024 1064 1160 1296 576 579 584 599 -hsync +vsync
# 1280x720 59.74 Hz (CVT 0.92M9-R) hsync: 44.27 kHz; pclk: 63.75 MHz
Modeline "1280x720R" 63.75 1280 1328 1360 1440 720 723 728 741 +hsync -vsync
# 1280x720 59.86 Hz (CVT 0.92M9) hsync: 44.77 kHz; pclk: 74.50 MHz
Modeline "1280x720" 74.50 1280 1344 1472 1664 720 723 728 748 -hsync +vsync
# 1368x768 59.85 Hz (CVT) hsync: 47.28 kHz; pclk: 72.25 MHz
Modeline "1368x768R" 72.25 1368 1416 1448 1528 768 771 781 790 +hsync -vsync
# 1368x768 59.88 Hz (CVT) hsync: 47.79 kHz; pclk: 85.25 MHz
Modeline "1368x768" 85.25 1368 1440 1576 1784 768 771 781 798 -hsync +vsync
# 1600x900 59.82 Hz (CVT 1.44M9-R) hsync: 55.40 kHz; pclk: 97.50 MHz
Modeline "1600x900R" 97.50 1600 1648 1680 1760 900 903 908 926 +hsync -vsync
# 1600x900 59.95 Hz (CVT 1.44M9) hsync: 55.99 kHz; pclk: 118.25 MHz
Modeline "1600x900" 118.25 1600 1696 1856 2112 900 903 908 934 -hsync +vsync
# 1920x1080 59.93 Hz (CVT 2.07M9-R) hsync: 66.59 kHz; pclk: 138.50 MHz
Modeline "1920x1080R" 138.50 1920 1968 2000 2080 1080 1083 1088 1111 +hsync -vsync
# 1920x1080 59.96 Hz (CVT 2.07M9) hsync: 67.16 kHz; pclk: 173.00 MHz
Modeline "1920x1080" 173.00 1920 2048 2248 2576 1080 1083 1088 1120 -hsync +vsync
# 2048x1152 59.91 Hz (CVT 2.36M9-R) hsync: 70.99 kHz; pclk: 156.75 MHz
Modeline "2048x1152R" 156.75 2048 2096 2128 2208 1152 1155 1160 1185 +hsync -vsync
# 2048x1152 59.90 Hz (CVT 2.36M9) hsync: 71.58 kHz; pclk: 197.00 MHz
Modeline "2048x1152" 197.00 2048 2184 2400 2752 1152 1155 1160 1195 -hsync +vsync
# 2560x1440 59.95 Hz (CVT 3.69M9-R) hsync: 88.79 kHz; pclk: 241.50 MHz
Modeline "2560x1440R" 241.50 2560 2608 2640 2720 1440 1443 1448 1481 +hsync -vsync
# 2560x1440 59.96 Hz (CVT 3.69M9) hsync: 89.52 kHz; pclk: 312.25 MHz
Modeline "2560x1440" 312.25 2560 2752 3024 3488 1440 1443 1448 1493 -hsync +vsync
# 2880x1620 59.97 Hz (CVT 4.67M9-R) hsync: 99.92 kHz; pclk: 303.75 MHz
Modeline "2880x1620R" 303.75 2880 2928 2960 3040 1620 1623 1628 1666 +hsync -vsync
# 2880x1620 59.96 Hz (CVT 4.67M9) hsync: 100.67 kHz; pclk: 396.25 MHz
Modeline "2880x1620" 396.25 2880 3096 3408 3936 1620 1623 1628 1679 -hsync +vsync
# 3200x1800 59.94 Hz (CVT 5.76M9-R) hsync: 111.01 kHz; pclk: 373.00 MHz
Modeline "3200x1800R" 373.00 3200 3248 3280 3360 1800 1803 1808 1852 +hsync -vsync
# 3200x1800 59.96 Hz (CVT 5.76M9) hsync: 111.82 kHz; pclk: 492.00 MHz
Modeline "3200x1800" 492.00 3200 3456 3800 4400 1800 1803 1808 1865 -hsync +vsync
# 3840x2160 59.97 Hz (CVT 8.29M9-R) hsync: 133.25 kHz; pclk: 533.00 MHz
Modeline "3840x2160R" 533.00 3840 3888 3920 4000 2160 2163 2168 2222 +hsync -vsync
# 3840x2160 59.98 Hz (CVT 8.29M9) hsync: 134.18 kHz; pclk: 712.75 MHz
Modeline "3840x2160" 712.75 3840 4160 4576 5312 2160 2163 2168 2237 -hsync +vsync
# 4096x2304 59.98 Hz (CVT 9.44M9-R) hsync: 142.15 kHz; pclk: 605.00 MHz
Modeline "4096x2304R" 605.00 4096 4144 4176 4256 2304 2307 2312 2370 +hsync -vsync
# 4096x2304 59.99 Hz (CVT 9.44M9) hsync: 143.13 kHz; pclk: 813.00 MHz
Modeline "4096x2304" 813.00 4096 4440 4888 5680 2304 2307 2312 2386 -hsync +vsync
# 5120x2880 59.99 Hz (CVT 14.75M9-R) hsync: 177.70 kHz; pclk: 938.25 MHz
Modeline "5120x2880R" 938.25 5120 5168 5200 5280 2880 2883 2888 2962 +hsync -vsync
# 5120x2880 59.99 Hz (CVT 14.75M9) hsync: 178.88 kHz; pclk: 1276.50 MHz
Modeline "5120x2880" 1276.50 5120 5560 6128 7136 2880 2883 2888 2982 -hsync +vsync
# 7680x4320 59.99 Hz (CVT 33.18M9-R) hsync: 266.55 kHz; pclk: 2089.75 MHz
Modeline "7680x4320R" 2089.75 7680 7728 7760 7840 4320 4323 4328 4443 +hsync -vsync
# 7680x4320 59.99 Hz (CVT 33.18M9) hsync: 268.22 kHz; pclk: 2892.50 MHz
Modeline "7680x4320" 2892.50 7680 8376 9232 10784 4320 4323 4328 4471 -hsync +vsync
# 15360x8640 59.99 Hz (CVT 132.71M9-R) hsync: 533.10 kHz; pclk: 8273.75 MHz
Modeline "15360x8640R" 8273.75 15360 15408 15440 15520 8640 8643 8648 8886 +hsync -vsync
# 15360x8640 60.00 Hz (CVT 132.71M9) hsync: 536.27 kHz; pclk: 11669.25 MHz
Modeline "15360x8640" 11669.25 15360 16824 18560 21760 8640 8643 8648 8938 -hsync +vsync
## 16:10 modelines generated by cvt
# 1280x800 59.91 Hz (CVT 1.02MA-R) hsync: 49.31 kHz; pclk: 71.00 MHz
Modeline "1280x800R" 71.00 1280 1328 1360 1440 800 803 809 823 +hsync -vsync
# 1280x800 59.81 Hz (CVT 1.02MA) hsync: 49.70 kHz; pclk: 83.50 MHz
Modeline "1280x800" 83.50 1280 1352 1480 1680 800 803 809 831 -hsync +vsync
# 1400x900 59.88 Hz (CVT) hsync: 55.45 kHz; pclk: 86.50 MHz
Modeline "1400x900R" 86.50 1400 1448 1480 1560 900 903 913 926 +hsync -vsync
# 1400x900 59.96 Hz (CVT) hsync: 56.01 kHz; pclk: 103.50 MHz
Modeline "1400x900" 103.50 1400 1480 1624 1848 900 903 913 934 -hsync +vsync
# 1680x1050 59.88 Hz (CVT 1.76MA-R) hsync: 64.67 kHz; pclk: 119.00 MHz
Modeline "1680x1050R" 119.00 1680 1728 1760 1840 1050 1053 1059 1080 +hsync -vsync
# 1680x1050 59.95 Hz (CVT 1.76MA) hsync: 65.29 kHz; pclk: 146.25 MHz
Modeline "1680x1050" 146.25 1680 1784 1960 2240 1050 1053 1059 1089 -hsync +vsync
# 1920x1200 59.95 Hz (CVT 2.30MA-R) hsync: 74.04 kHz; pclk: 154.00 MHz
Modeline "1920x1200R" 154.00 1920 1968 2000 2080 1200 1203 1209 1235 +hsync -vsync
# 1920x1200 59.88 Hz (CVT 2.30MA) hsync: 74.56 kHz; pclk: 193.25 MHz
Modeline "1920x1200" 193.25 1920 2056 2256 2592 1200 1203 1209 1245 -hsync +vsync
# 2560x1600 59.97 Hz (CVT 4.10MA-R) hsync: 98.71 kHz; pclk: 268.50 MHz
Modeline "2560x1600R" 268.50 2560 2608 2640 2720 1600 1603 1609 1646 +hsync -vsync
# 2560x1600 59.99 Hz (CVT 4.10MA) hsync: 99.46 kHz; pclk: 348.50 MHz
Modeline "2560x1600" 348.50 2560 2760 3032 3504 1600 1603 1609 1658 -hsync +vsync
srcs_xorg_common = [
'xf86fbBus.c',
'xf86noBus.c',
'xf86Configure.c',
'xf86Bus.c',
'xf86Config.c',
'xf86Cursor.c',
'xf86DPMS.c',
'xf86Events.c',
'xf86Globals.c',
'xf86AutoConfig.c',
'xf86Option.c',
'xf86Init.c',
'xf86VidMode.c',
'xf86fbman.c',
'xf86cmap.c',
'xf86Helper.c',
'xf86PM.c',
'xf86RandR.c',
'xf86Xinput.c',
'xisb.c',
'xf86Mode.c',
'xorgHelper.c',
'xf86Extensions.c',
]
xorg_sdk_headers = [
'compiler.h',
'xf86.h',
'xf86Module.h',
'xf86Opt.h',
'xf86PciInfo.h',
'xf86Priv.h',
'xf86Privstr.h',
'xf86cmap.h',
'xf86fbman.h',
'xf86str.h',
'xf86Xinput.h',
'xisb.h',
'xorgVersion.h',
'xf86sbusBus.h',
'xf86VGAarbiter.h',
'xf86Optionstr.h',
'xf86platformBus.h',
'xf86MatchDrivers.h',
'xaarop.h',
]
fallback_driver = get_option('fallback_input_driver')
if fallback_driver == 'auto'
if host_machine.system() == 'linux'
fallback_driver = 'libinput'
else
fallback_driver = ''
endif
endif
if build_dga
srcs_xorg_common += 'xf86DGA.c'
xorg_sdk_headers += 'dgaproc.h'
endif
if build_xv
srcs_xorg_common += ['xf86xv.c', 'xf86xvmc.c']
xorg_sdk_headers += ['xf86xv.h', 'xf86xvmc.h', 'xf86xvpriv.h']
endif
if build_udev
srcs_xorg_common += 'xf86platformBus.c'
endif
if get_option('pciaccess')
srcs_xorg_common += ['xf86pciBus.c', 'xf86VGAarbiter.c']
endif
srcs_xorg_common += custom_target(
'xf86DefModeSet.c',
output: 'xf86DefModeSet.c',
input: ['modeline2c.awk', 'vesamodes', 'extramodes'],
command: [find_program('awk'), '-f', '@INPUT0@', '@INPUT1@', '@INPUT2@'],
capture: true,
)
xorg_common = static_library('xorg_common',
srcs_xorg_common,
include_directories: [inc, xorg_inc, top_dir_inc],
dependencies: [
common_dep,
dbus_dep,
pciaccess_dep,
libdrm_dep,
],
c_args: [
xorg_c_args,
'-DFALLBACK_INPUT_DRIVER="@0@"'.format(fallback_driver)
],
)
install_data(xorg_sdk_headers, install_dir: xorgsdkdir)
#!/usr/bin/awk -f
#
# Copyright (c) 2007 Joerg Sonnenberger <joerg@NetBSD.org>.
# All rights reserved.
#
# Based on Perl script by Dirk Hohndel.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
# are met:
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
# COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
# INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING,
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
# SUCH DAMAGE.
#
# Usage: modeline2c.awk < modefile > xf86DefModeSet.c
#
BEGIN {
flagsdict[""] = "0"
flagsdict["+hsync +vsync"] = "V_PHSYNC | V_PVSYNC"
flagsdict["+hsync -vsync"] = "V_PHSYNC | V_NVSYNC"
flagsdict["-hsync +vsync"] = "V_NHSYNC | V_PVSYNC"
flagsdict["-hsync -vsync"] = "V_NHSYNC | V_NVSYNC"
flagsdict["+hsync +vsync interlace"] = "V_PHSYNC | V_PVSYNC | V_INTERLACE"
flagsdict["+hsync -vsync interlace"] = "V_PHSYNC | V_NVSYNC | V_INTERLACE"
flagsdict["-hsync +vsync interlace"] = "V_NHSYNC | V_PVSYNC | V_INTERLACE"
flagsdict["-hsync -vsync interlace"] = "V_NHSYNC | V_NVSYNC | V_INTERLACE"
print "/* THIS FILE IS AUTOMATICALLY GENERATED -- DO NOT EDIT -- LOOK at"
print " * modeline2c.awk */"
print ""
print "/*"
print " * Author: Joerg Sonnenberger <joerg@NetBSD.org>"
print " * Based on Perl script from Dirk Hohndel <hohndel@XFree86.Org>"
print " */"
print ""
print "#ifdef HAVE_XORG_CONFIG_H"
print "#include <xorg-config.h>"
print "#endif"
print ""
print "#include \"xf86.h\""
print "#include \"xf86Config.h\""
print "#include \"xf86Priv.h\""
print "#include \"xf86_OSlib.h\""
print ""
print "#include \"globals.h\""
print ""
print "#define MODEPREFIX NULL, NULL, NULL, MODE_OK, M_T_DEFAULT"
print "#define MODESUFFIX 0,0, 0,0,0,0,0,0,0, 0,0,0,0,0,0,FALSE,FALSE,0,NULL,0,0.0,0.0"
print ""
print "const DisplayModeRec xf86DefaultModes [] = {"
modeline = "\t{MODEPREFIX,%d, %d,%d,%d,%d,0, %d,%d,%d,%d,0, %s, MODESUFFIX},\n"
modeline_data = "^[a-zA-Z]+[ \t]+[^ \t]+[ \t0-9.]+"
}
/^[mM][oO][dD][eE][lL][iI][nN][eE]/ {
flags = $0
gsub(modeline_data, "", flags)
flags = tolower(flags)
printf(modeline, $3 * 1000, $4, $5, $6, $7,
$8, $9, $10, $11, flagsdict[flags])
# Half-width double scanned modes
printf(modeline, $3 * 500, $4/2, $5/2, $6/2, $7/2,
$8/2, $9/2, $10/2, $11/2, flagsdict[flags] " | V_DBLSCAN")
}
/^#/ {
print "/*" substr($0, 2) " */"
}
END {
print "};"
printf "const int xf86NumDefaultModes = ARRAY_SIZE(xf86DefaultModes);"
}
//
// Default modes distilled from
// "VESA and Industry Standards and Guide for Computer Display Monitor
// Timing", version 1.0, revision 0.8, adopted September 17, 1998.
//
// $XFree86: xc/programs/Xserver/hw/xfree86/etc/vesamodes,v 1.3 1999/11/16 03:28:03 tsi Exp $
# 640x350 @ 85Hz (VESA) hsync: 37.9kHz
ModeLine "640x350" 31.5 640 672 736 832 350 382 385 445 +hsync -vsync
# 640x400 @ 85Hz (VESA) hsync: 37.9kHz
ModeLine "640x400" 31.5 640 672 736 832 400 401 404 445 -hsync +vsync
# 720x400 @ 85Hz (VESA) hsync: 37.9kHz
ModeLine "720x400" 35.5 720 756 828 936 400 401 404 446 -hsync +vsync
# 640x480 @ 60Hz (Industry standard) hsync: 31.5kHz
ModeLine "640x480" 25.175 640 656 752 800 480 490 492 525 -hsync -vsync
# 640x480 @ 72Hz (VESA) hsync: 37.9kHz
ModeLine "640x480" 31.5 640 664 704 832 480 489 492 520 -hsync -vsync
# 640x480 @ 75Hz (VESA) hsync: 37.5kHz
ModeLine "640x480" 31.5 640 656 720 840 480 481 484 500 -hsync -vsync
# 640x480 @ 85Hz (VESA) hsync: 43.3kHz
ModeLine "640x480" 36.0 640 696 752 832 480 481 484 509 -hsync -vsync
# 800x600 @ 56Hz (VESA) hsync: 35.2kHz
ModeLine "800x600" 36.0 800 824 896 1024 600 601 603 625 +hsync +vsync
# 800x600 @ 60Hz (VESA) hsync: 37.9kHz
ModeLine "800x600" 40.0 800 840 968 1056 600 601 605 628 +hsync +vsync
# 800x600 @ 72Hz (VESA) hsync: 48.1kHz
ModeLine "800x600" 50.0 800 856 976 1040 600 637 643 666 +hsync +vsync
# 800x600 @ 75Hz (VESA) hsync: 46.9kHz
ModeLine "800x600" 49.5 800 816 896 1056 600 601 604 625 +hsync +vsync
# 800x600 @ 85Hz (VESA) hsync: 53.7kHz
ModeLine "800x600" 56.3 800 832 896 1048 600 601 604 631 +hsync +vsync
# 1024x768i @ 43Hz (industry standard) hsync: 35.5kHz
ModeLine "1024x768" 44.9 1024 1032 1208 1264 768 768 776 817 +hsync +vsync Interlace
# 1024x768 @ 60Hz (VESA) hsync: 48.4kHz
ModeLine "1024x768" 65.0 1024 1048 1184 1344 768 771 777 806 -hsync -vsync
# 1024x768 @ 70Hz (VESA) hsync: 56.5kHz
ModeLine "1024x768" 75.0 1024 1048 1184 1328 768 771 777 806 -hsync -vsync
# 1024x768 @ 75Hz (VESA) hsync: 60.0kHz
ModeLine "1024x768" 78.75 1024 1040 1136 1312 768 769 772 800 +hsync +vsync
# 1024x768 @ 85Hz (VESA) hsync: 68.7kHz
ModeLine "1024x768" 94.5 1024 1072 1168 1376 768 769 772 808 +hsync +vsync
# 1152x864 @ 75Hz (VESA) hsync: 67.5kHz
ModeLine "1152x864" 108.0 1152 1216 1344 1600 864 865 868 900 +hsync +vsync
# 1280x960 @ 60Hz (VESA) hsync: 60.0kHz
ModeLine "1280x960" 108.0 1280 1376 1488 1800 960 961 964 1000 +hsync +vsync
# 1280x960 @ 85Hz (VESA) hsync: 85.9kHz
ModeLine "1280x960" 148.5 1280 1344 1504 1728 960 961 964 1011 +hsync +vsync
# 1280x1024 @ 60Hz (VESA) hsync: 64.0kHz