mirror of
https://github.com/X11Libre/xf86-input-evdev.git
synced 2026-04-14 11:44:16 +00:00
Compare commits
35 Commits
xf86-input
...
xlibre-xf8
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
26dde8fc21 | ||
|
|
51d93c47f7 | ||
|
|
3801a36ec9 | ||
|
|
e361cfad9f | ||
|
|
4570407894 | ||
|
|
9ee18e3450 | ||
|
|
e518cb19bd | ||
|
|
0b5b97bc6b | ||
|
|
96a4dc7565 | ||
|
|
abcafeede7 | ||
|
|
d893fc74d2 | ||
|
|
b9327e6b28 | ||
|
|
917c2ea204 | ||
|
|
b48c2b7028 | ||
|
|
aac329fd2a | ||
|
|
fbfb16edfe | ||
|
|
409e8205e8 | ||
|
|
7fc0d51f70 | ||
|
|
7c48b6225b | ||
|
|
8edcb2b9e8 | ||
|
|
84b2740814 | ||
|
|
469a30f158 | ||
|
|
23909c35a4 | ||
|
|
abf0fa611e | ||
|
|
6609d352f3 | ||
|
|
71036116be | ||
|
|
b6b36166bd | ||
|
|
67a97afbc0 | ||
|
|
2fb95783e0 | ||
|
|
456f23cbbd | ||
|
|
ab1d9adfd3 | ||
|
|
192fdb0690 | ||
|
|
8c1058f2eb | ||
|
|
4921912374 | ||
|
|
67681097b8 |
65
.github/ISSUE_TEMPLATE/01-bug-report.yml
vendored
Normal file
65
.github/ISSUE_TEMPLATE/01-bug-report.yml
vendored
Normal file
@@ -0,0 +1,65 @@
|
||||
name: 🐞 Bug report
|
||||
description: Create a report to help us improve
|
||||
|
||||
labels: [bug, needs-triage]
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Please fill out the sections below to help everyone identify and fix the bug. If you have a general idea or question then please use the [discussions](https://github.com/orgs/X11Libre/discussions).
|
||||
- type: dropdown
|
||||
id: affected-version
|
||||
attributes:
|
||||
label: Select the version
|
||||
options:
|
||||
- 2.11.0.1
|
||||
- Git master branch
|
||||
- other or don't know
|
||||
default: 1
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: description
|
||||
attributes:
|
||||
label: Describe your issue
|
||||
placeholder: When I did X then Y happened.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: steps
|
||||
attributes:
|
||||
label: Steps to reproduce
|
||||
placeholder: |
|
||||
1. Start ...
|
||||
2. Do this
|
||||
3. Do that
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: expected
|
||||
attributes:
|
||||
label: What did you expect?
|
||||
placeholder: I expected this to happen.
|
||||
- type: textarea
|
||||
id: environment
|
||||
attributes:
|
||||
label: Additional Information
|
||||
description: |
|
||||
Additional information you want to provide such as logs, system info, environment, screenshots, etc.
|
||||
placeholder: |
|
||||
Add any other context about the bug here.
|
||||
- type: checkboxes
|
||||
id: checks
|
||||
attributes:
|
||||
label: Extra fields
|
||||
options:
|
||||
- label: I have checked the existing [issues](https://github.com/X11Libre/xf86-input-evdev/issues)
|
||||
required: true
|
||||
- label: I have read the [Contributing Guidelines](https://github.com/X11Libre/xserver/blob/master/CONTRIBUTING.md)
|
||||
required: true
|
||||
- label: I'd like to work on this issue
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for reporting this issue! We will get back to you as soon as possible.
|
||||
49
.github/ISSUE_TEMPLATE/02-feature-request.yml
vendored
Normal file
49
.github/ISSUE_TEMPLATE/02-feature-request.yml
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
name: ✨ Feature request
|
||||
description: Suggest a feature for this software
|
||||
labels: [enhancement, needs-triage]
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Please fill out the sections below to properly describe the new software feature you are suggesting. If you have a general idea or question then please use the [discussions](https://github.com/orgs/X11Libre/discussions).
|
||||
- type: textarea
|
||||
id: description
|
||||
attributes:
|
||||
label: "Describe the feature"
|
||||
placeholder: A thing in X that allows to do Y.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: rationale
|
||||
attributes:
|
||||
label: "It should be done because"
|
||||
placeholder: Doing Y is needed for Z.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: alternative
|
||||
attributes:
|
||||
label: "What are the alternatives?"
|
||||
placeholder: We could do A or B instead.
|
||||
- type: textarea
|
||||
id: context
|
||||
attributes:
|
||||
label: Additional context
|
||||
description: Additional information you want to provide such as references to related issues or protocols, the implications on existing use cases, etc.
|
||||
placeholder: |
|
||||
Add any other context about the feature request here.
|
||||
- type: checkboxes
|
||||
id: checks
|
||||
attributes:
|
||||
label: Extra fields
|
||||
options:
|
||||
- label: I have checked the existing [issues](https://github.com/X11Libre/xf86-input-evdev/issues)
|
||||
required: true
|
||||
- label: I have read the [Contributing Guidelines](https://github.com/X11Libre/xserver/blob/master/CONTRIBUTING.md)
|
||||
required: true
|
||||
- label: I'd like to work on this issue
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for your suggestion! Let's see together if it can be done.
|
||||
49
.github/ISSUE_TEMPLATE/03-code-cleanup.yml
vendored
Normal file
49
.github/ISSUE_TEMPLATE/03-code-cleanup.yml
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
name: 🔧 Code cleanup
|
||||
description: Level up the source code
|
||||
labels: [code-cleanup, needs-triage]
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Please fill out the sections below to properly describe the code cleanup you are suggesting. If you have a general idea or question then please use the [discussions](https://github.com/orgs/X11Libre/discussions).
|
||||
- type: textarea
|
||||
id: description
|
||||
attributes:
|
||||
label: "Describe the cleanup"
|
||||
placeholder: C in X needs to be changed into D.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: rationale
|
||||
attributes:
|
||||
label: "It should be done because"
|
||||
placeholder: Having D is needed for E.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: alternative
|
||||
attributes:
|
||||
label: "What are the alternatives?"
|
||||
placeholder: We could do A or B instead.
|
||||
- type: textarea
|
||||
id: context
|
||||
attributes:
|
||||
label: Additional context
|
||||
description: Additional information you want to provide such as implications on existing code, how to ensure API/ABI stability, which tests are needed or to be run, related issues, etc.
|
||||
placeholder: |
|
||||
Add any other context about the cleanup here.
|
||||
- type: checkboxes
|
||||
id: checks
|
||||
attributes:
|
||||
label: Extra fields
|
||||
options:
|
||||
- label: I have checked the existing [issues](https://github.com/X11Libre/xf86-input-evdev/issues)
|
||||
required: true
|
||||
- label: I have read the [Contributing Guidelines](https://github.com/X11Libre/xserver/blob/master/CONTRIBUTING.md)
|
||||
required: true
|
||||
- label: I'd like to work on this issue
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for looking at the source code! Let's see together how it can be improved.
|
||||
38
.github/ISSUE_TEMPLATE/04-doc-update.yml
vendored
Normal file
38
.github/ISSUE_TEMPLATE/04-doc-update.yml
vendored
Normal file
@@ -0,0 +1,38 @@
|
||||
name: 🔖 Documentation update
|
||||
description: Make your mark for better documentation
|
||||
|
||||
labels: [documentation, needs-triage]
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Please fill out the sections below to help others understand our software. If you have a general idea or question then please use the [discussions](https://github.com/orgs/X11Libre/discussions).
|
||||
- type: textarea
|
||||
id: description
|
||||
attributes:
|
||||
label: Describe the update
|
||||
placeholder: These things need to be better documented.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: environment
|
||||
attributes:
|
||||
label: Additional Information
|
||||
description: Additional information you want to provide such as tickets related to changes in the software, affected files, screenshots, etc.
|
||||
placeholder: |
|
||||
Add any other context about the update here.
|
||||
- type: checkboxes
|
||||
id: checks
|
||||
attributes:
|
||||
label: Extra fields
|
||||
options:
|
||||
- label: I have checked the existing [issues](https://github.com/X11Libre/xf86-input-evdev/issues)
|
||||
required: true
|
||||
- label: I have read the [Contributing Guidelines](https://github.com/X11Libre/xserver/blob/master/CONTRIBUTING.md)
|
||||
required: true
|
||||
- label: I'd like to work on this issue
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for requesting this update! We will get back to you as soon as possible.
|
||||
43
.github/ISSUE_TEMPLATE/05-org-task.yml
vendored
Normal file
43
.github/ISSUE_TEMPLATE/05-org-task.yml
vendored
Normal file
@@ -0,0 +1,43 @@
|
||||
name: ✅ Organizational task
|
||||
description: Create a task for project organization
|
||||
|
||||
labels: [needs-triage, organization]
|
||||
|
||||
body:
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Please fill out the sections below to get organizational things done. If you have a general idea or question then please use the [discussions](https://github.com/orgs/X11Libre/discussions).
|
||||
- type: textarea
|
||||
id: description
|
||||
attributes:
|
||||
label: Describe the task
|
||||
placeholder: These things need to be done.
|
||||
validations:
|
||||
required: true
|
||||
- type: textarea
|
||||
id: rationale
|
||||
attributes:
|
||||
label: "It should be done because"
|
||||
placeholder: Doing Y is needed for Z.
|
||||
- type: textarea
|
||||
id: environment
|
||||
attributes:
|
||||
label: Additional Information
|
||||
description: Additional information you want to provide such as the context for bigger tasks, the implicatons on existing workflows, related issues, etc.
|
||||
placeholder: |
|
||||
Add any other context about the task here.
|
||||
- type: checkboxes
|
||||
id: checks
|
||||
attributes:
|
||||
label: Extra fields
|
||||
options:
|
||||
- label: I have checked the existing [issues](https://github.com/X11Libre/xf86-input-evdev/issues)
|
||||
required: true
|
||||
- label: I have read the [Contributing Guidelines](https://github.com/X11Libre/xserver/blob/master/CONTRIBUTING.md)
|
||||
required: true
|
||||
- label: I'd like to work on this issue
|
||||
- type: markdown
|
||||
attributes:
|
||||
value: |
|
||||
Thanks for adding this task! We will get back to you as soon as possible.
|
||||
8
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
8
.github/ISSUE_TEMPLATE/config.yml
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
blank_issues_enabled: false
|
||||
contact_links:
|
||||
- name: XLibre Community Support
|
||||
url: https://github.com/orgs/X11Libre/discussions
|
||||
about: Please ask and answer questions here.
|
||||
- name: Mailing List
|
||||
url: https://www.freelists.org/list/xlibre
|
||||
about: You can join the discussions on our mailing list.
|
||||
69
.github/actions/build-driver/action.yaml
vendored
Normal file
69
.github/actions/build-driver/action.yaml
vendored
Normal file
@@ -0,0 +1,69 @@
|
||||
name: 'build driver'
|
||||
description: 'build driver against specific Xserver'
|
||||
inputs:
|
||||
xserver-version:
|
||||
required: true
|
||||
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: check out driver repo
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: prepare build environment
|
||||
shell: bash
|
||||
run: |
|
||||
MACHINE=`gcc -dumpmachine`
|
||||
echo "MACHINE=$MACHINE" >> "$GITHUB_ENV"
|
||||
echo "PKG_CONFIG_PATH=$X11_PREFIX/share/pkgconfig:$X11_PREFIX/lib/$MACHINE/pkgconfig:$X11_PREFIX/lib/pkgconfig:$PKG_CONFIG_PATH" >> "$GITHUB_ENV"
|
||||
sudo chown root /bin/tar && sudo chmod u+s /bin/tar
|
||||
|
||||
- name: apt cache
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: /var/cache/apt
|
||||
key: apt-cache-${{ hashFiles('.github/scripts/ubuntu/install-pkg.sh') }}
|
||||
restore-keys: apt-cache-
|
||||
|
||||
- name: pkg install
|
||||
shell: bash
|
||||
run: sudo .github/scripts/ubuntu/install-pkg.sh
|
||||
|
||||
- name: X11 prereq cache
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
${{ env.X11_PREFIX }}
|
||||
key: ${{ runner.name }}-x11-deps-${{ hashFiles('.github/scripts/install-prereq.sh') }}
|
||||
restore-keys: ${{ runner.name }}-x11-deps-
|
||||
|
||||
- name: generic prereq
|
||||
shell: bash
|
||||
run: .github/scripts/install-prereq.sh
|
||||
|
||||
- name: check out xserver repo
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
repository: X11Libre/xserver
|
||||
path: xserver-sdk
|
||||
ref: ${{ inputs.xserver-version }}
|
||||
|
||||
- name: build xserver sdk
|
||||
shell: bash
|
||||
env:
|
||||
MESON_ARGS: -Dc_args="-fno-common" -Dprefix=/usr -Dnamespace=false -Dxselinux=false -Dxephyr=false -Dwerror=false -Dxcsecurity=false -Dxorg=true -Dxvfb=false -Dxnest=false -Ddocs=false
|
||||
run: |
|
||||
cd xserver-sdk
|
||||
echo -n > .meson_environment
|
||||
echo "export MESON_BUILDDIR=$MESON_BUILDDIR" >> .meson_environment
|
||||
echo "export PKG_CONFIG_PATH=$PKG_CONFIG_PATH" >> .meson_environment
|
||||
.gitlab-ci/meson-build.sh --skip-test
|
||||
sudo meson install --no-rebuild -C "$MESON_BUILDDIR"
|
||||
sudo mkdir -p /usr/local/lib/$MACHINE/xorg/modules # /home/runner/x11/lib/xorg/modules
|
||||
sudo chown -R runner /usr/local/lib/$MACHINE/xorg/modules # /home/runner/x11/lib/xorg/modules
|
||||
|
||||
- name: compile driver
|
||||
shell: bash
|
||||
run: |
|
||||
CFLAGS="-Wall" ./autogen.sh # --prefix=$X11_PREFIX
|
||||
CFLAGS="-Wall" make -j # install
|
||||
13
.github/scripts/conf.sh
vendored
Normal file
13
.github/scripts/conf.sh
vendored
Normal file
@@ -0,0 +1,13 @@
|
||||
export X11_OS=`uname -s`
|
||||
|
||||
export X11_PREFIX="${X11_PREFIX:-$HOME/x11}"
|
||||
export X11_BUILD_DIR="${X11_BUILD_DIR:-$HOME/build-deps}"
|
||||
export DRV_BUILD_DIR="${DRV_BUILD_DIR:-$HOME/build-drivers}"
|
||||
|
||||
case "$X11_OS" in
|
||||
Darwin) export FDO_CI_CONCURRENT=`sysctl -n hw.logicalcpu` ;;
|
||||
Linux) export FDO_CI_CONCURRENT=`nproc` ;;
|
||||
esac
|
||||
|
||||
export PATH="$X11_PREFIX/bin:$PATH"
|
||||
export PKG_CONFIG_PATH="$X11_PREFIX/lib/x86_64-linux-gnu/pkgconfig:$X11_PREFIX/lib/pkgconfig:$X11_PREFIX/share/pkgconfig:$PKG_CONFIG_PATH"
|
||||
17
.github/scripts/github/make-release
vendored
Executable file
17
.github/scripts/github/make-release
vendored
Executable file
@@ -0,0 +1,17 @@
|
||||
#!/bin/bash
|
||||
|
||||
err() {
|
||||
echo "$0: $*"
|
||||
}
|
||||
|
||||
[ "$GITHUB_REPOSITORY" ] || err "missing variable GITHUB_REPOSITORY"
|
||||
|
||||
TITLE=$(git tag -l --format='%(contents)' $tag)
|
||||
|
||||
echo "tag=$tag"
|
||||
echo "title=$TITLE"
|
||||
|
||||
gh release create "$tag" \
|
||||
--repo="$GITHUB_REPOSITORY" \
|
||||
--title="$tag" \
|
||||
--generate-notes
|
||||
15
.github/scripts/install-prereq.sh
vendored
Executable file
15
.github/scripts/install-prereq.sh
vendored
Executable file
@@ -0,0 +1,15 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
. .github/scripts/util.sh
|
||||
|
||||
mkdir -p $X11_BUILD_DIR
|
||||
cd $X11_BUILD_DIR
|
||||
|
||||
if [ "$X11_OS" = "Linux" ]; then
|
||||
build_meson drm https://gitlab.freedesktop.org/mesa/drm libdrm-2.4.121 "" \
|
||||
-Domap=enabled
|
||||
fi
|
||||
build_meson libxcvt https://gitlab.freedesktop.org/xorg/lib/libxcvt libxcvt-0.1.0
|
||||
build_ac xorgproto https://gitlab.freedesktop.org/xorg/proto/xorgproto xorgproto-2024.1
|
||||
94
.github/scripts/ubuntu/install-pkg.sh
vendored
Executable file
94
.github/scripts/ubuntu/install-pkg.sh
vendored
Executable file
@@ -0,0 +1,94 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
# Packages which are needed by this script, but not for the xserver build
|
||||
EPHEMERAL="
|
||||
libexpat-dev
|
||||
libgles2-mesa-dev
|
||||
libxkbcommon-dev
|
||||
x11-utils
|
||||
x11-xserver-utils
|
||||
xauth
|
||||
xvfb
|
||||
"
|
||||
|
||||
apt-get update
|
||||
|
||||
apt-get install -y \
|
||||
$EPHEMERAL \
|
||||
autoconf \
|
||||
automake \
|
||||
build-essential \
|
||||
ca-certificates \
|
||||
libaudit-dev \
|
||||
libbsd-dev \
|
||||
libcairo2-dev \
|
||||
libdbus-1-dev \
|
||||
libdrm-dev \
|
||||
libegl1-mesa-dev \
|
||||
libepoxy-dev \
|
||||
libevdev2 \
|
||||
libexpat1 \
|
||||
libffi-dev \
|
||||
libgbm-dev \
|
||||
libgcrypt-dev \
|
||||
libgl1-mesa-dev \
|
||||
libgles2 \
|
||||
libglx-mesa0 \
|
||||
libinput10 \
|
||||
libinput-dev \
|
||||
libnvidia-egl-wayland-dev \
|
||||
libpciaccess-dev \
|
||||
libpixman-1-dev \
|
||||
libspice-protocol-dev \
|
||||
libsystemd-dev \
|
||||
libudev-dev \
|
||||
libunwind-dev \
|
||||
libx11-dev \
|
||||
libx11-xcb-dev \
|
||||
libxau-dev \
|
||||
libxaw7-dev \
|
||||
libxcb-glx0-dev \
|
||||
libxcb-icccm4-dev \
|
||||
libxcb-image0-dev \
|
||||
libxcb-keysyms1-dev \
|
||||
libxcb-randr0-dev \
|
||||
libxcb-render-util0-dev \
|
||||
libxcb-render0-dev \
|
||||
libxcb-shape0-dev \
|
||||
libxcb-shm0-dev \
|
||||
libxcb-util0-dev \
|
||||
libxcb-xf86dri0-dev \
|
||||
libxcb-xkb-dev \
|
||||
libxcb-xv0-dev \
|
||||
libxcb1-dev \
|
||||
libxdmcp-dev \
|
||||
libxext-dev \
|
||||
libxfixes-dev \
|
||||
libxfont-dev \
|
||||
libxi-dev \
|
||||
libxinerama-dev \
|
||||
libxkbcommon0 \
|
||||
libxkbfile-dev \
|
||||
libxmu-dev \
|
||||
libxmuu-dev \
|
||||
libxpm-dev \
|
||||
libxrender-dev \
|
||||
libxres-dev \
|
||||
libxshmfence-dev \
|
||||
libxt-dev \
|
||||
libxtst-dev \
|
||||
libxv-dev \
|
||||
mesa-common-dev \
|
||||
meson \
|
||||
nettle-dev \
|
||||
libpango1.0-dev \
|
||||
pkg-config \
|
||||
x11-xkb-utils \
|
||||
xfonts-utils \
|
||||
xkb-data \
|
||||
xtrans-dev \
|
||||
xutils-dev \
|
||||
libxaw7-dev \
|
||||
python3-mako
|
||||
85
.github/scripts/util.sh
vendored
Normal file
85
.github/scripts/util.sh
vendored
Normal file
@@ -0,0 +1,85 @@
|
||||
|
||||
. .github/scripts/conf.sh
|
||||
|
||||
clone_source() {
|
||||
local pkgname="$1"
|
||||
local url="$2"
|
||||
local ref="$3"
|
||||
local commit="$4"
|
||||
|
||||
if [ ! -f $pkgname/.git/config ]; then
|
||||
echo "need to clone $pkgname"
|
||||
if [ "$commit" ]; then
|
||||
git clone $url $pkgname --branch=$ref
|
||||
else
|
||||
git clone $url $pkgname --branch=$ref --depth 1
|
||||
fi
|
||||
else
|
||||
echo "already cloned $pkgname"
|
||||
fi
|
||||
|
||||
if [ "$commit" ]; then
|
||||
( cd $pkgname && git checkout -f "$commit" )
|
||||
fi
|
||||
}
|
||||
|
||||
build_meson() {
|
||||
local pkgname="$1"
|
||||
local url="$2"
|
||||
local ref="$3"
|
||||
local commit="$4"
|
||||
shift
|
||||
shift
|
||||
shift
|
||||
shift || true
|
||||
if [ -f $X11_PREFIX/$pkgname.DONE ]; then
|
||||
echo "package $pkgname already built"
|
||||
else
|
||||
clone_source "$pkgname" "$url" "$ref" "$commit"
|
||||
(
|
||||
cd $pkgname
|
||||
meson "$@" build -Dprefix=$X11_PREFIX
|
||||
ninja -j${FDO_CI_CONCURRENT:-4} -C build install
|
||||
)
|
||||
touch $X11_PREFIX/$pkgname.DONE
|
||||
fi
|
||||
}
|
||||
|
||||
build_ac() {
|
||||
local pkgname="$1"
|
||||
local url="$2"
|
||||
local ref="$3"
|
||||
local commit="$4"
|
||||
shift
|
||||
shift
|
||||
shift
|
||||
shift || true
|
||||
if [ -f $X11_PREFIX/$pkgname.DONE ]; then
|
||||
echo "package $pkgname already built"
|
||||
else
|
||||
clone_source "$pkgname" "$url" "$ref" "$commit"
|
||||
(
|
||||
cd $pkgname
|
||||
./autogen.sh --prefix=$X11_PREFIX
|
||||
make -j${FDO_CI_CONCURRENT:-4} install
|
||||
)
|
||||
touch $X11_PREFIX/$pkgname.DONE
|
||||
fi
|
||||
}
|
||||
|
||||
build_drv_ac() {
|
||||
local pkgname="$1"
|
||||
local url="$2"
|
||||
local ref="$3"
|
||||
local commit="$4"
|
||||
shift
|
||||
shift
|
||||
shift
|
||||
shift || true
|
||||
clone_source "$pkgname" "$url" "$ref" "$commit"
|
||||
(
|
||||
cd $pkgname
|
||||
./autogen.sh # --prefix=$X11_PREFIX
|
||||
make -j${FDO_CI_CONCURRENT:-4} # install
|
||||
)
|
||||
}
|
||||
43
.github/workflows/build.yml
vendored
Normal file
43
.github/workflows/build.yml
vendored
Normal file
@@ -0,0 +1,43 @@
|
||||
name: Build driver
|
||||
|
||||
permissions:
|
||||
contents: write
|
||||
|
||||
env:
|
||||
MESON_BUILDDIR: "build"
|
||||
X11_PREFIX: /home/runner/x11
|
||||
X11_BUILD_DIR: /home/runner/build-deps
|
||||
|
||||
on:
|
||||
push:
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
for-xserver-stable-25_0:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: ./.github/actions/build-driver
|
||||
with:
|
||||
xserver-version: xlibre-xserver-25.0.0.5
|
||||
|
||||
for-xserver-master:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: ./.github/actions/build-driver
|
||||
with:
|
||||
xserver-version: master
|
||||
|
||||
release:
|
||||
name: Release pushed tag
|
||||
runs-on: ubuntu-latest
|
||||
if: ${{ startsWith(github.ref, 'refs/tags/xlibre-') }}
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- name: Create release
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
tag: ${{ github.ref_name }}
|
||||
run: .github/scripts/github/make-release
|
||||
106
.gitlab-ci.yml
Normal file
106
.gitlab-ci.yml
Normal file
@@ -0,0 +1,106 @@
|
||||
# vim: set expandtab shiftwidth=2 tabstop=8 textwidth=0 filetype=yaml:
|
||||
#
|
||||
# This CI uses the freedesktop.org ci-templates.
|
||||
# Please see the ci-templates documentation for details:
|
||||
# https://freedesktop.pages.freedesktop.org/ci-templates/
|
||||
|
||||
.templates_sha: &template_sha 25e8e9f020880aa35fffe3d6b259b933f0f9449f # see https://docs.gitlab.com/ee/ci/yaml/#includefile
|
||||
|
||||
|
||||
include:
|
||||
# Arch container builder template
|
||||
- project: 'freedesktop/ci-templates'
|
||||
ref: *template_sha
|
||||
file: '/templates/arch.yml'
|
||||
- project: 'freedesktop/ci-templates'
|
||||
ref: *template_sha
|
||||
file: '/templates/ci-fairy.yml'
|
||||
- template: Security/SAST.gitlab-ci.yml
|
||||
|
||||
|
||||
workflow:
|
||||
rules:
|
||||
- if: $CI_PIPELINE_SOURCE == "merge_request_event"
|
||||
- if: $CI_COMMIT_BRANCH && $CI_OPEN_MERGE_REQUESTS
|
||||
when: never
|
||||
- if: $CI_COMMIT_BRANCH
|
||||
|
||||
|
||||
stages:
|
||||
- prep # prep work like rebuilding the container images if there is a change
|
||||
- build # for actually building and testing things in a container
|
||||
- test
|
||||
- deploy
|
||||
|
||||
|
||||
variables:
|
||||
FDO_UPSTREAM_REPO: 'xorg/driver/xf86-input-evdev'
|
||||
# The tag should be updated each time the list of packages is updated.
|
||||
# Changing a tag forces the associated image to be rebuilt.
|
||||
# Note: the tag has no meaning, we use a date format purely for readability
|
||||
FDO_DISTRIBUTION_TAG: '2023-10-01.0'
|
||||
FDO_DISTRIBUTION_PACKAGES: 'git gcc pkgconf autoconf automake libtool make xorg-util-macros xorgproto xorg-server-devel pixman systemd-libs libevdev mtdev'
|
||||
|
||||
|
||||
#
|
||||
# Verify that commit messages are as expected
|
||||
#
|
||||
check-commits:
|
||||
extends:
|
||||
- .fdo.ci-fairy
|
||||
stage: prep
|
||||
script:
|
||||
- ci-fairy check-commits --junit-xml=results.xml
|
||||
except:
|
||||
- master@xorg/driver/xf86-input-evdev
|
||||
variables:
|
||||
GIT_DEPTH: 100
|
||||
artifacts:
|
||||
reports:
|
||||
junit: results.xml
|
||||
|
||||
#
|
||||
# Verify that the merge request has the allow-collaboration checkbox ticked
|
||||
#
|
||||
check-merge-request:
|
||||
extends:
|
||||
- .fdo.ci-fairy
|
||||
stage: deploy
|
||||
script:
|
||||
- ci-fairy check-merge-request --require-allow-collaboration --junit-xml=results.xml
|
||||
artifacts:
|
||||
when: on_failure
|
||||
reports:
|
||||
junit: results.xml
|
||||
allow_failure: true
|
||||
|
||||
|
||||
#
|
||||
# Build a container with the given tag and the packages pre-installed.
|
||||
# This only happens if the tag changes, otherwise the existing image is
|
||||
# re-used.
|
||||
#
|
||||
container-prep:
|
||||
extends:
|
||||
- .fdo.container-build@arch
|
||||
stage: prep
|
||||
variables:
|
||||
GIT_STRATEGY: none
|
||||
|
||||
|
||||
#
|
||||
# The default build, runs on the image built above.
|
||||
#
|
||||
build:
|
||||
stage: build
|
||||
extends:
|
||||
- .fdo.distribution-image@arch
|
||||
script:
|
||||
- autoreconf -ivf
|
||||
- mkdir _builddir
|
||||
- pushd _builddir > /dev/null
|
||||
- ../configure --disable-silent-rules
|
||||
- make
|
||||
- make check
|
||||
- make distcheck
|
||||
- popd > /dev/null
|
||||
@@ -19,8 +19,10 @@
|
||||
# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
|
||||
# Provide an sdk location that is writable by the evdev module
|
||||
DISTCHECK_CONFIGURE_FLAGS = --with-sdkdir='$${includedir}/xorg'
|
||||
# During distcheck, system locations (as provided by pkg-config) may
|
||||
# not be writable; provide instead relative locations.
|
||||
DISTCHECK_CONFIGURE_FLAGS = --with-xorg-module-dir='$${libdir}/xorg/modules' \
|
||||
--with-sdkdir='$${includedir}/xorg'
|
||||
|
||||
SUBDIRS = src man include
|
||||
MAINTAINERCLEANFILES = ChangeLog INSTALL
|
||||
@@ -39,3 +41,5 @@ ChangeLog:
|
||||
$(CHANGELOG_CMD)
|
||||
|
||||
dist-hook: ChangeLog INSTALL
|
||||
|
||||
EXTRA_DIST = README.md
|
||||
|
||||
20
README
20
README
@@ -1,20 +0,0 @@
|
||||
xf86-input-evdev - Generic Linux input driver for the Xorg X server
|
||||
|
||||
Please submit bugs & patches to the Xorg bugzilla:
|
||||
|
||||
https://bugs.freedesktop.org/enter_bug.cgi?product=xorg
|
||||
|
||||
All questions regarding this software should be directed at the
|
||||
Xorg mailing list:
|
||||
|
||||
http://lists.freedesktop.org/mailman/listinfo/xorg
|
||||
|
||||
The master development code repository can be found at:
|
||||
|
||||
git://anongit.freedesktop.org/git/xorg/driver/xf86-input-evdev
|
||||
|
||||
http://cgit.freedesktop.org/xorg/driver/xf86-input-evdev
|
||||
|
||||
For more information on the git code manager, see:
|
||||
|
||||
http://wiki.x.org/wiki/GitPage
|
||||
18
README.md
Normal file
18
README.md
Normal file
@@ -0,0 +1,18 @@
|
||||
xf86-input-evdev - Generic Linux input driver for the Xorg X server
|
||||
-------------------------------------------------------------------
|
||||
|
||||
All questions regarding this software should be directed at the
|
||||
Xorg mailing list:
|
||||
|
||||
https://lists.x.org/mailman/listinfo/xorg
|
||||
|
||||
The primary development code repository can be found at:
|
||||
|
||||
https://gitlab.freedesktop.org/xorg/driver/xf86-input-evdev
|
||||
|
||||
Please submit bug reports and requests to merge patches there.
|
||||
|
||||
For patch submission instructions, see:
|
||||
|
||||
https://www.x.org/wiki/Development/Documentation/SubmittingPatches
|
||||
|
||||
11
autogen.sh
11
autogen.sh
@@ -1,14 +1,17 @@
|
||||
#! /bin/sh
|
||||
|
||||
srcdir=`dirname $0`
|
||||
srcdir=`dirname "$0"`
|
||||
test -z "$srcdir" && srcdir=.
|
||||
|
||||
ORIGDIR=`pwd`
|
||||
cd $srcdir
|
||||
cd "$srcdir"
|
||||
|
||||
autoreconf -v --install || exit 1
|
||||
cd $ORIGDIR || exit $?
|
||||
cd "$ORIGDIR" || exit $?
|
||||
|
||||
git config --local --get format.subjectPrefix >/dev/null 2>&1 ||
|
||||
git config --local format.subjectPrefix "PATCH xf86-input-evdev"
|
||||
|
||||
if test -z "$NOCONFIGURE"; then
|
||||
$srcdir/configure "$@"
|
||||
exec "$srcdir"/configure "$@"
|
||||
fi
|
||||
|
||||
21
configure.ac
21
configure.ac
@@ -22,16 +22,16 @@
|
||||
|
||||
# Initialize Autoconf
|
||||
AC_PREREQ([2.60])
|
||||
AC_INIT([xf86-input-evdev],
|
||||
[2.10.5],
|
||||
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
|
||||
[xf86-input-evdev])
|
||||
AC_INIT([xlibre-xf86-input-evdev],
|
||||
[2.11.1],
|
||||
[https://github.com/X11Libre/xf86-input-evdev/issues],
|
||||
[xlibre-xf86-input-evdev])
|
||||
AC_CONFIG_SRCDIR([Makefile.am])
|
||||
AC_CONFIG_HEADERS([config.h])
|
||||
AC_CONFIG_AUX_DIR(.)
|
||||
|
||||
# Initialize Automake
|
||||
AM_INIT_AUTOMAKE([foreign dist-bzip2])
|
||||
AM_INIT_AUTOMAKE([foreign dist-xz])
|
||||
|
||||
# Initialize libtool
|
||||
AC_DISABLE_STATIC
|
||||
@@ -44,18 +44,19 @@ XORG_MACROS_VERSION(1.8)
|
||||
XORG_DEFAULT_OPTIONS
|
||||
|
||||
# Obtain compiler/linker options from server and required extensions
|
||||
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.12] xproto [inputproto >= 2.1.99.3])
|
||||
PKG_CHECK_MODULES(UDEV, libudev)
|
||||
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.18] xproto [inputproto >= 2.1.99.3])
|
||||
PKG_CHECK_MODULES(UDEV, libudev, [AC_DEFINE(HAVE_LIBUDEV, 1,[libudev support])])
|
||||
|
||||
PKG_CHECK_MODULES(LIBEVDEV, [libevdev >= 0.4])
|
||||
PKG_CHECK_MODULES(MTDEV, mtdev)
|
||||
|
||||
# Define a configure option for an alternate input module directory
|
||||
PKG_PROG_PKG_CONFIG([0.25])
|
||||
AC_ARG_WITH(xorg-module-dir,
|
||||
AC_HELP_STRING([--with-xorg-module-dir=DIR],
|
||||
[Default xorg module directory [[default=$libdir/xorg/modules]]]),
|
||||
AS_HELP_STRING([--with-xorg-module-dir=DIR],
|
||||
[Default xorg module directory]),
|
||||
[moduledir="$withval"],
|
||||
[moduledir="$libdir/xorg/modules"])
|
||||
[moduledir=`$PKG_CONFIG --variable=moduledir xorg-server`])
|
||||
inputdir=${moduledir}/input
|
||||
AC_SUBST(inputdir)
|
||||
|
||||
|
||||
322
man/evdev.man
322
man/evdev.man
@@ -1,8 +1,8 @@
|
||||
.\" shorthand for double quote that works everywhere.
|
||||
.ds q \N'34'
|
||||
.TH EVDEV __drivermansuffix__ __vendorversion__
|
||||
.TH EVDEV __drivermansuffix__ 2016-11-17 __vendorversion__
|
||||
.SH NAME
|
||||
evdev \- Generic Linux input driver
|
||||
evdev \- Generic Linux input driver for Xorg
|
||||
.SH SYNOPSIS
|
||||
.nf
|
||||
.B "Section \*qInputDevice\*q"
|
||||
@@ -16,103 +16,118 @@ evdev \- Generic Linux input driver
|
||||
.B EndSection
|
||||
.fi
|
||||
.SH DESCRIPTION
|
||||
.B evdev
|
||||
is an __xservername__ input driver for Linux\'s generic event devices. It
|
||||
therefore supports all input devices that the kernel knows about, including
|
||||
most mice, keyboards, tablets and touchscreens.
|
||||
.B evdev
|
||||
is an Xorg input driver for Linux\'s generic event devices.
|
||||
It therefore supports all input devices that the kernel knows about,
|
||||
including most mice, keyboards, tablets, and touchscreens.
|
||||
.B evdev
|
||||
is the default driver on the major Linux distributions.
|
||||
.PP
|
||||
The
|
||||
The
|
||||
.B evdev
|
||||
driver can serve as both a pointer and a keyboard input device. Multiple
|
||||
input devices are supported by multiple instances of this driver, with one
|
||||
InputDevice section of your __xconfigfile__ for each input device that will
|
||||
use this driver.
|
||||
driver can serve as both a pointer and a keyboard input device.
|
||||
Multiple input devices are supported by multiple instances of this driver,
|
||||
with one InputDevice section of your xorg.conf for each input device
|
||||
that will use this driver.
|
||||
.PP
|
||||
It is recommended that
|
||||
.B evdev
|
||||
devices are configured through the
|
||||
.B InputClass
|
||||
directive (refer to __xconfigfile__(__filemansuffix__)) instead of manual
|
||||
per-device configuration. Devices configured in the
|
||||
__xconfigfile__(__filemansuffix__) are not hot-plug capable.
|
||||
.PP
|
||||
directive (refer to
|
||||
.BR xorg.conf (__filemansuffix__))
|
||||
instead of manual per-device configuration.
|
||||
Devices configured in the
|
||||
.BR xorg.conf (__filemansuffix__)
|
||||
are not hot-plug capable.
|
||||
.SH SUPPORTED HARDWARE
|
||||
In general, any input device that the kernel has a driver for can be accessed
|
||||
through the
|
||||
through the
|
||||
.B evdev
|
||||
driver. See the Linux kernel documentation for a complete list.
|
||||
.PP
|
||||
driver.
|
||||
See the Linux kernel documentation for a complete list.
|
||||
.SH CONFIGURATION DETAILS
|
||||
Please refer to __xconfigfile__(__filemansuffix__) for general configuration
|
||||
details and for options that can be used with all input drivers. This
|
||||
section only covers configuration details specific to this driver.
|
||||
Please refer to
|
||||
.BR xorg.conf (__filemansuffix__)
|
||||
for general configuration details and
|
||||
for options that can be used with all input drivers.
|
||||
This section only covers configuration details specific to this driver.
|
||||
.PP
|
||||
The following driver
|
||||
The following driver
|
||||
.B Options
|
||||
are supported:
|
||||
.TP 7
|
||||
.BI "Option \*qButtonMapping\*q \*q" string \*q
|
||||
Sets the button mapping for this device. The mapping is a space-separated list
|
||||
of button mappings that correspond in order to the physical buttons on the
|
||||
device (i.e. the first number is the mapping for button 1, etc.). The default
|
||||
mapping is "1 2 3 ... 32". A mapping of 0 deactivates the button. Multiple
|
||||
buttons can have the same mapping.
|
||||
Sets the button mapping for this device.
|
||||
The mapping is a space-separated list of button mappings
|
||||
that correspond in order to the physical buttons on the device
|
||||
(i.e. the first number is the mapping for button 1, etc.).
|
||||
The default mapping is "1 2 3 ... 32".
|
||||
A mapping of 0 deactivates the button.
|
||||
Multiple buttons can have the same mapping.
|
||||
For example, a left-handed mouse with deactivated scroll-wheel would use a
|
||||
mapping of "3 2 1 0 0". Invalid mappings are ignored and the default mapping
|
||||
is used. Buttons not specified in the user's mapping use the default mapping.
|
||||
mapping of "3 2 1 0 0".
|
||||
Invalid mappings are ignored and the default mapping is used.
|
||||
Buttons not specified in the user's mapping use the default mapping.
|
||||
.TP 7
|
||||
.BI "Option \*qDevice\*q \*q" string \*q
|
||||
Specifies the device through which the device can be accessed. This will
|
||||
generally be of the form \*q/dev/input/eventX\*q, where X is some integer.
|
||||
The mapping from device node to hardware is system-dependent. Property:
|
||||
"Device Node" (read-only).
|
||||
Specifies the device through which the device can be accessed.
|
||||
This will generally be of the form \*q/dev/input/eventX\*q,
|
||||
where X is some integer.
|
||||
The mapping from device node to hardware is system-dependent.
|
||||
Property: "Device Node" (read-only).
|
||||
.TP 7
|
||||
.BI "Option \*qDragLockButtons\*q \*q" "L1 B2 L3 B4" \*q
|
||||
Sets \*qdrag lock buttons\*q that simulate holding a button down, so
|
||||
that low dexterity people do not have to hold a button down at the
|
||||
same time they move a mouse cursor. Button numbers occur in pairs,
|
||||
with the lock button number occurring first, followed by the button
|
||||
number that is the target of the lock button. Property: "Evdev
|
||||
same time they move a mouse cursor.
|
||||
Button numbers occur in pairs,
|
||||
with the lock button number occurring first,
|
||||
followed by the button number that is the target of the lock button.
|
||||
Property: "Evdev
|
||||
Drag Lock Buttons".
|
||||
.TP 7
|
||||
.BI "Option \*qDragLockButtons\*q \*q" "M1" \*q
|
||||
Sets a \*qmaster drag lock button\*q that acts as a \*qMeta Key\*q
|
||||
indicating that the next button pressed is to be
|
||||
\*qdrag locked\*q. Property: "Evdev Drag Lock Buttons".
|
||||
.TP 7
|
||||
indicating that the next button pressed is to be \*qdrag locked\*q.
|
||||
Property: "Evdev Drag Lock Buttons".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulate3Buttons\*q \*q" boolean \*q
|
||||
Enable/disable the emulation of the third (middle) mouse button for mice
|
||||
which only have two physical buttons. The third button is emulated by
|
||||
pressing both buttons simultaneously. Default: off. Property: "Evdev Middle
|
||||
Button Emulation".
|
||||
which only have two physical buttons.
|
||||
The third button is emulated by pressing both buttons simultaneously.
|
||||
Default: off.
|
||||
Property: "Evdev Middle Button Emulation".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulate3Timeout\*q \*q" integer \*q
|
||||
Sets the timeout (in milliseconds) that the driver waits before deciding
|
||||
if two buttons where pressed "simultaneously" when 3 button emulation is
|
||||
enabled. Default: 50. Property: "Evdev Middle Button Timeout".
|
||||
if two buttons were pressed "simultaneously" when 3 button emulation is enabled.
|
||||
Default: 50.
|
||||
Property: "Evdev Middle Button Timeout".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulate3Button\*q \*q" integer \*q
|
||||
Specifies the physical button number to be emitted if middle button emulation
|
||||
is triggered.
|
||||
Default: 2. Property: "Evdev Middle Button Button".
|
||||
Default: 2.
|
||||
Property: "Evdev Middle Button Button".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulateWheel\*q \*q" boolean \*q
|
||||
Enable/disable "wheel" emulation. Wheel emulation means emulating button
|
||||
press/release events when the mouse is moved while a specific real button
|
||||
is pressed. Wheel button events (typically buttons 4 and 5) are
|
||||
usually used for scrolling. Wheel emulation is useful for getting wheel-like
|
||||
behaviour with trackballs. It can also be useful for mice with 4 or
|
||||
more buttons but no wheel. See the description of the
|
||||
Enable/disable "wheel" emulation.
|
||||
Wheel emulation means emulating button press/release events
|
||||
when the mouse is moved while a specific real button is pressed.
|
||||
Wheel button events (typically buttons 4 and 5) are usually used for scrolling.
|
||||
Wheel emulation is useful for getting wheel-like behaviour with trackballs.
|
||||
It can also be useful for mice with 4 or more buttons but no wheel.
|
||||
See the description of the
|
||||
.BR EmulateWheelButton ,
|
||||
.BR EmulateWheelInertia ,
|
||||
.BR EmulateWheelTimeout ,
|
||||
.BR XAxisMapping ,
|
||||
and
|
||||
.B YAxisMapping
|
||||
options. Default: off. Property "Evdev Wheel Emulation".
|
||||
options.
|
||||
Default: off.
|
||||
Property: "Evdev Wheel Emulation".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulateWheelButton\*q \*q" integer \*q
|
||||
Specifies which button must be held down to enable wheel emulation mode.
|
||||
@@ -121,97 +136,119 @@ press/release events as specified for the
|
||||
.B XAxisMapping
|
||||
and
|
||||
.B YAxisMapping
|
||||
settings. If the button is 0 and
|
||||
.BR EmulateWheel
|
||||
is on, any motion of the device is converted into wheel events. Default: 4.
|
||||
settings.
|
||||
If the button is 0 and
|
||||
.B EmulateWheel
|
||||
is on, any motion of the device is converted into wheel events.
|
||||
Default: 4.
|
||||
Property: "Evdev Wheel Emulation Button".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulateWheelInertia\*q \*q" integer \*q
|
||||
Specifies how far (in pixels) the pointer must move to generate button
|
||||
press/release events in wheel emulation mode. Default: 10. Property: "Evdev
|
||||
Wheel Emulation Inertia".
|
||||
press/release events in wheel emulation mode.
|
||||
Default: 10.
|
||||
Property: "Evdev Wheel Emulation Inertia".
|
||||
.IP
|
||||
This value must be set for any device does not resemble a standard mouse.
|
||||
Specifically, on absolute devices such as tablets the value should be set to
|
||||
a reasonable fraction of the expected movement to avoid excess scroll events.
|
||||
.IP
|
||||
.B WARNING:
|
||||
the name \*qinertia\*q is a misnomer. This option defines the distance
|
||||
required to generate one scroll event similar to the
|
||||
the name \*qinertia\*q is a misnomer.
|
||||
This option defines the distance required to generate one scroll event
|
||||
similar to the
|
||||
.B VertScrollDelta
|
||||
and
|
||||
.B HorizScrollDelta
|
||||
options. It does not enable inertia in the
|
||||
physical sense, scrolling stops immediately once the movement has stopped.
|
||||
options.
|
||||
It does not enable inertia in the physical sense,
|
||||
scrolling stops immediately once the movement has stopped.
|
||||
.TP 7
|
||||
.BI "Option \*qEmulateWheelTimeout\*q \*q" integer \*q
|
||||
Specifies the time in milliseconds the
|
||||
.BR EmulateWheelButton
|
||||
must be pressed before wheel emulation is started. If the
|
||||
.BR EmulateWheelButton
|
||||
is released before this timeout, the original button press/release event
|
||||
is sent. Default: 200. Property: "Evdev Wheel Emulation Timeout".
|
||||
.B EmulateWheelButton
|
||||
must be pressed before wheel emulation is started.
|
||||
If the
|
||||
.B EmulateWheelButton
|
||||
is released before this timeout,
|
||||
the original button press/release event is sent.
|
||||
Default: 200.
|
||||
Property: "Evdev Wheel Emulation Timeout".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulateThirdButton\*q \*q" boolean \*q
|
||||
Enable third button emulation. Third button emulation emits a right button
|
||||
event (by default) by pressing and holding the first button. The first
|
||||
button must be held down for the configured timeout and must not move more
|
||||
than the configured threshold for the emulation to activate. Otherwise, the
|
||||
first button event is posted as normal. Default: off. Property: "Evdev
|
||||
Third Button Emulation".
|
||||
Enable third button emulation.
|
||||
Third button emulation emits a right button event (by default)
|
||||
by pressing and holding the first button.
|
||||
The first button must be held down for the configured timeout and
|
||||
must not move more than the configured threshold for the emulation to activate.
|
||||
Otherwise, the first button event is posted as normal.
|
||||
Default: off.
|
||||
Property: "Evdev Third Button Emulation".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulateThirdButtonTimeout\*q \*q" integer \*q
|
||||
Specifies the timeout in milliseconds between the initial button press and
|
||||
the generation of the emulated button event.
|
||||
Default: 1000. Property: "Evdev Third Button Emulation Timeout".
|
||||
Default: 1000.
|
||||
Property: "Evdev Third Button Emulation Timeout".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulateThirdButtonButton\*q \*q" integer \*q
|
||||
Specifies the physical button number to be emitted if third button emulation
|
||||
is triggered.
|
||||
Default: 3. Property: "Evdev Third Button Button".
|
||||
Default: 3.
|
||||
Property: "Evdev Third Button Button".
|
||||
.TP 7
|
||||
.BI "Option \*qEmulateThirdButtonMoveThreshold\*q \*q" integer \*q
|
||||
Specifies the maximum move fuzz in device coordinates for third button
|
||||
emulation. If the device moves by more than this threshold before the third
|
||||
emulation.
|
||||
If the device moves by more than this threshold before the third
|
||||
button emulation is triggered, the emulation is cancelled and a first button
|
||||
event is generated as normal.
|
||||
Default: 20. Property: "Evdev Third Button Emulation Threshold".
|
||||
Default: 20.
|
||||
Property: "Evdev Third Button Emulation Threshold".
|
||||
.TP 7
|
||||
.BI "Option \*qGrabDevice\*q \*q" boolean \*q
|
||||
Force a grab on the event device. Doing so will ensure that no other driver
|
||||
Force a grab on the event device.
|
||||
Doing so will ensure that no other driver
|
||||
can initialise the same device and it will also stop the device from sending
|
||||
events to /dev/kbd or /dev/input/mice. Events from this device will not be
|
||||
sent to virtual devices (e.g. rfkill or the Macintosh mouse button emulation).
|
||||
events to /dev/kbd or /dev/input/mice.
|
||||
Events from this device will not be sent to virtual devices
|
||||
(e.g. rfkill or the Macintosh mouse button emulation).
|
||||
Default: disabled.
|
||||
.TP 7
|
||||
.BI "Option \*qInvertX\*q \*q" Bool \*q
|
||||
.TP 7
|
||||
.BI "Option \*qInvertY\*q \*q" Bool \*q
|
||||
Invert the given axis. Default: off. Property: "Evdev Axis Inversion".
|
||||
Invert the given axis.
|
||||
Default: off.
|
||||
Property: "Evdev Axis Inversion".
|
||||
.TP 7
|
||||
.BI "Option \*qIgnoreRelativeAxes\*q \*q" Bool \*q
|
||||
.TP 7
|
||||
.BI "Option \*qIgnoreAbsoluteAxes\*q \*q" Bool \*q
|
||||
Ignore the specified type of axis. Default: unset. The X server cannot deal
|
||||
with devices that have both relative and absolute axes. Evdev tries to guess
|
||||
wich axes to ignore given the device type and disables absolute axes for
|
||||
mice and relative axes for tablets, touchscreens and touchpad. These options
|
||||
allow to forcibly disable an axis type. Mouse wheel axes are exempt and will
|
||||
work even if relative axes are ignored. No property, this configuration must
|
||||
be set in the configuration.
|
||||
Ignore the specified type of axis.
|
||||
Default: unset.
|
||||
The X server cannot deal with devices that have both relative and absolute axes.
|
||||
Evdev tries to guess which axes to ignore given the device type and
|
||||
disables absolute axes for mice and relative axes for tablets, touchscreens,
|
||||
and touchpad.
|
||||
These options allow to forcibly disable an axis type.
|
||||
Mouse wheel axes are exempt and will work even if relative axes are ignored.
|
||||
No property, this configuration must be set in the configuration.
|
||||
.br
|
||||
If either option is set to False, the driver will not ignore the specified
|
||||
axes regardless of the presence of other axes. This may trigger buggy
|
||||
behavior and events from this axis are always forwarded. Users are
|
||||
discouraged from setting this option.
|
||||
axes regardless of the presence of other axes.
|
||||
This may trigger buggy behavior and events from this axis are always forwarded.
|
||||
Users are discouraged from setting this option.
|
||||
.TP 7
|
||||
.BI "Option \*qCalibration\*q \*q" "min-x max-x min-y max-y" \*q
|
||||
Calibrates the X and Y axes for devices that need to scale to a different
|
||||
coordinate system than reported to the X server. This feature is required
|
||||
for devices that need to scale to a different coordinate system than
|
||||
originally reported by the kernel (e.g. touchscreens). The scaling to the
|
||||
custom coordinate system is done in-driver and the X server is unaware of
|
||||
the transformation. Property: "Evdev Axis Calibration".
|
||||
coordinate system than reported to the X server.
|
||||
This feature is required for devices that need to scale to
|
||||
a different coordinate system than originally reported by the kernel
|
||||
(e.g. touchscreens).
|
||||
The scaling to the custom coordinate system is done in-driver and
|
||||
the X server is unaware of the transformation.
|
||||
Property: "Evdev Axis Calibration".
|
||||
.TP 7
|
||||
.B Option \*qMode\*q \*qRelative\*q\fP|\fP\*qAbsolute\*q
|
||||
Sets the mode of the device if device has absolute axes.
|
||||
@@ -219,97 +256,114 @@ The default value for touchpads is relative, for other absolute.
|
||||
This option has no effect on devices without absolute axes.
|
||||
.TP 7
|
||||
.BI "Option \*qSwapAxes\*q \*q" Bool \*q
|
||||
Swap x/y axes. Default: off. Property: "Evdev Axes Swap".
|
||||
Swap x/y axes.
|
||||
Default: off.
|
||||
Property: "Evdev Axes Swap".
|
||||
.TP 7
|
||||
.BI "Option \*qXAxisMapping\*q \*q" "N1 N2" \*q
|
||||
Specifies which buttons are mapped to motion in the X direction in wheel
|
||||
emulation mode. Button number
|
||||
emulation mode.
|
||||
Button number
|
||||
.I N1
|
||||
is mapped to the negative X axis motion and button number
|
||||
.I N2
|
||||
is mapped to the positive X axis motion. Default: no mapping. Property:
|
||||
"Evdev Wheel Emulation Axes".
|
||||
is mapped to the positive X axis motion.
|
||||
Default: no mapping.
|
||||
Property: "Evdev Wheel Emulation Axes".
|
||||
.TP 7
|
||||
.BI "Option \*qYAxisMapping\*q \*q" "N1 N2" \*q
|
||||
Specifies which buttons are mapped to motion in the Y direction in wheel
|
||||
emulation mode. Button number
|
||||
emulation mode.
|
||||
Button number
|
||||
.I N1
|
||||
is mapped to the negative Y axis motion and button number
|
||||
.I N2
|
||||
is mapped to the positive Y axis motion. Default: "4 5". Property:
|
||||
"Evdev Wheel Emulation Axes".
|
||||
is mapped to the positive Y axis motion.
|
||||
Default: "4 5".
|
||||
Property: "Evdev Wheel Emulation Axes".
|
||||
.TP 7
|
||||
.BI "Option \*qTypeName\*q \*q"type"\*q
|
||||
Specify the X Input 1.x type (see XListInputDevices(__libmansuffix__)).
|
||||
.BI "Option \*qTypeName\*q" \*q"type"\*q
|
||||
Specify the X Input 1.x type (see
|
||||
.BR XListInputDevices (__libmansuffix__)).
|
||||
There is rarely a need to use this option, evdev will guess the device type
|
||||
based on the device's capabilities. This option is provided for devices that
|
||||
need quirks.
|
||||
based on the device's capabilities.
|
||||
This option is provided for devices that need quirks.
|
||||
.TP 7
|
||||
.BI "Option \*qVertScrollDelta\*q \*q" integer \*q
|
||||
The amount of motion considered one unit of scrolling vertically.
|
||||
Default: "1". Property: "Evdev Scrolling Distance".
|
||||
Default: "1".
|
||||
Property: "Evdev Scrolling Distance".
|
||||
.TP 7
|
||||
.BI "Option \*qHorizScrollDelta\*q \*q" integer \*q
|
||||
The amount of motion considered one unit of scrolling horizontally.
|
||||
Default: "1". Property: "Evdev Scrolling Distance".
|
||||
Default: "1".
|
||||
Property: "Evdev Scrolling Distance".
|
||||
.TP 7
|
||||
.BI "Option \*qDialDelta\*q \*q" integer \*q
|
||||
The amount of motion considered one unit of turning the dial. Default: "1".
|
||||
The amount of motion considered one unit of turning the dial.
|
||||
Default: "1".
|
||||
Property: "Evdev Scrolling Distance".
|
||||
.TP 7
|
||||
.BI "Option \*qResolution\*q \*q" integer \*q
|
||||
Sets the resolution of the device in dots per inch. The resolution is used
|
||||
to scale relative motion events from mouse devices to 1000 DPI resolution. This
|
||||
can be used to make high resolution mice less sensitive without turning off
|
||||
acceleration. If set to 0 no scaling will be performed. Default: "0".
|
||||
|
||||
Sets the resolution of the device in dots per inch.
|
||||
The resolution is used to scale relative motion events from mouse devices to
|
||||
1000 DPI resolution.
|
||||
This can be used to make high resolution mice less sensitive without turning off
|
||||
acceleration.
|
||||
If set to 0 no scaling will be performed.
|
||||
Default: "0".
|
||||
.SH SUPPORTED PROPERTIES
|
||||
The following properties are provided by the
|
||||
.B evdev
|
||||
driver.
|
||||
.TP 7
|
||||
.BI "Evdev Axis Calibration"
|
||||
.B "Evdev Axis Calibration"
|
||||
4 32-bit values, order min-x, max-x, min-y, max-y or 0 values to disable
|
||||
in-driver axis calibration.
|
||||
.TP 7
|
||||
.BI "Evdev Axis Inversion"
|
||||
2 boolean values (8 bit, 0 or 1), order X, Y. 1 inverts the axis.
|
||||
.B "Evdev Axis Inversion"
|
||||
2 boolean values (8 bit, 0 or 1), order X, Y.
|
||||
1 inverts the axis.
|
||||
.TP 7
|
||||
.BI "Evdev Axes Swap"
|
||||
1 boolean value (8 bit, 0 or 1). 1 swaps x/y axes.
|
||||
.B "Evdev Axes Swap"
|
||||
1 boolean value (8 bit, 0 or 1).
|
||||
1 swaps x/y axes.
|
||||
.TP 7
|
||||
.BI "Evdev Drag Lock Buttons"
|
||||
8-bit. Either 1 value or pairs of values. Value range 0-32, 0 disables a
|
||||
value.
|
||||
.B "Evdev Drag Lock Buttons"
|
||||
8-bit. Either 1 value or pairs of values.
|
||||
Value range 0-32, 0 disables a value.
|
||||
.TP 7
|
||||
.BI "Evdev Middle Button Emulation"
|
||||
.B "Evdev Middle Button Emulation"
|
||||
1 boolean value (8 bit, 0 or 1).
|
||||
.TP 7
|
||||
.BI "Evdev Middle Button Timeout"
|
||||
.B "Evdev Middle Button Timeout"
|
||||
1 16-bit positive value.
|
||||
.TP 7
|
||||
.BI "Evdev Middle Button Button"
|
||||
.B "Evdev Middle Button Button"
|
||||
1 8-bit value, allowed range 0-32, 0 disables the button.
|
||||
.TP 7
|
||||
.BI "Evdev Wheel Emulation"
|
||||
.B "Evdev Wheel Emulation"
|
||||
1 boolean value (8 bit, 0 or 1).
|
||||
.TP 7
|
||||
.BI "Evdev Wheel Emulation Axes"
|
||||
4 8-bit values, order X up, X down, Y up, Y down. 0 disables a value.
|
||||
.B "Evdev Wheel Emulation Axes"
|
||||
4 8-bit values, order X up, X down, Y up, Y down.
|
||||
0 disables a value.
|
||||
.TP 7
|
||||
.BI "Evdev Wheel Emulation Button"
|
||||
.B "Evdev Wheel Emulation Button"
|
||||
1 8-bit value, allowed range 0-32, 0 disables the button.
|
||||
.TP 7
|
||||
.BI "Evdev Wheel Emulation Inertia"
|
||||
.B "Evdev Wheel Emulation Inertia"
|
||||
1 16-bit positive value.
|
||||
.TP 7
|
||||
.BI "Evdev Wheel Emulation Timeout"
|
||||
.B "Evdev Wheel Emulation Timeout"
|
||||
1 16-bit positive value.
|
||||
.TP 7
|
||||
.BI "Evdev Scrolling Distance"
|
||||
.B "Evdev Scrolling Distance"
|
||||
3 32-bit values: vertical, horizontal and dial.
|
||||
|
||||
.SH AUTHORS
|
||||
Kristian Høgsberg, Peter Hutterer
|
||||
.SH "SEE ALSO"
|
||||
__xservername__(__appmansuffix__), __xconfigfile__(__filemansuffix__), Xserver(__appmansuffix__), X(__miscmansuffix__)
|
||||
.BR Xorg (__appmansuffix__),
|
||||
.BR xorg.conf (__filemansuffix__),
|
||||
.BR Xserver (__appmansuffix__),
|
||||
.BR X (__miscmansuffix__)
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
* Copyright 1994-2002 by The XFree86 Project, Inc.
|
||||
* Copyright 2002 by Paul Elliott
|
||||
* (Ported from xf86-input-mouse, above copyrights taken from there)
|
||||
* Copyright © 2008 University of South Australia
|
||||
* Copyright © 2008 University of South Australia
|
||||
* Copyright 2008 by Chris Salch
|
||||
* Copyright 2008 Red Hat, Inc.
|
||||
*
|
||||
|
||||
@@ -50,7 +50,7 @@ static Atom prop_wheel_inertia = 0;
|
||||
static Atom prop_wheel_timeout = 0;
|
||||
static Atom prop_wheel_button = 0;
|
||||
|
||||
/* Local Funciton Prototypes */
|
||||
/* Local Function Prototypes */
|
||||
static int EvdevWheelEmuInertia(InputInfoPtr pInfo, WheelAxisPtr axis, int value);
|
||||
|
||||
/* Filter mouse button events */
|
||||
@@ -210,9 +210,7 @@ EvdevWheelEmuHandleButtonMap(InputInfoPtr pInfo, WheelAxisPtr pAxis,
|
||||
((up_button > 0) && (up_button <= EVDEV_MAXBUTTONS)) &&
|
||||
((down_button > 0) && (down_button <= EVDEV_MAXBUTTONS))) {
|
||||
|
||||
/* Use xstrdup to allocate a string for us */
|
||||
msg = xstrdup("buttons XX and YY");
|
||||
|
||||
msg = strdup("buttons XX and YY");
|
||||
if (msg)
|
||||
sprintf(msg, "buttons %d and %d", up_button, down_button);
|
||||
|
||||
|
||||
62
src/evdev.c
62
src/evdev.c
@@ -38,9 +38,10 @@
|
||||
#include <X11/keysym.h>
|
||||
#include <X11/extensions/XI.h>
|
||||
|
||||
#include <linux/version.h>
|
||||
#include <sys/stat.h>
|
||||
#ifdef HAVE_LIBUDEV
|
||||
#include <libudev.h>
|
||||
#endif
|
||||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
@@ -74,8 +75,8 @@
|
||||
#define CAPSFLAG 1
|
||||
#define NUMFLAG 2
|
||||
#define SCROLLFLAG 4
|
||||
#define MODEFLAG 8
|
||||
#define COMPOSEFLAG 16
|
||||
#define COMPOSEFLAG 8
|
||||
#define MODEFLAG 16
|
||||
|
||||
#ifndef ABS_MT_SLOT
|
||||
#define ABS_MT_SLOT 0x2f
|
||||
@@ -226,6 +227,7 @@ EvdevIsDuplicate(InputInfoPtr pInfo)
|
||||
static BOOL
|
||||
EvdevDeviceIsVirtual(const char* devicenode)
|
||||
{
|
||||
#ifdef HAVE_LIBUDEV
|
||||
struct udev *udev = NULL;
|
||||
struct udev_device *device = NULL;
|
||||
struct stat st;
|
||||
@@ -256,6 +258,9 @@ out:
|
||||
udev_device_unref(device);
|
||||
udev_unref(udev);
|
||||
return rc;
|
||||
#else
|
||||
return FALSE;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
@@ -277,7 +282,7 @@ EvdevNextInQueue(InputInfoPtr pInfo)
|
||||
void
|
||||
EvdevQueueKbdEvent(InputInfoPtr pInfo, struct input_event *ev, int value)
|
||||
{
|
||||
int code = ev->code + MIN_KEYCODE;
|
||||
int code = ev->code;
|
||||
EventQueuePtr pQueue;
|
||||
|
||||
/* Filter all repeated events from device.
|
||||
@@ -285,10 +290,18 @@ EvdevQueueKbdEvent(InputInfoPtr pInfo, struct input_event *ev, int value)
|
||||
if (value == 2)
|
||||
return;
|
||||
|
||||
/* keycodes > 256 that have a historical mapping in xkeyboard-config */
|
||||
switch (code) {
|
||||
case KEY_TOUCHPAD_TOGGLE: code = KEY_F21; break;
|
||||
case KEY_TOUCHPAD_ON: code = KEY_F22; break;
|
||||
case KEY_TOUCHPAD_OFF: code = KEY_F23; break;
|
||||
case KEY_MICMUTE: code = KEY_F20; break;
|
||||
}
|
||||
|
||||
if ((pQueue = EvdevNextInQueue(pInfo)))
|
||||
{
|
||||
pQueue->type = EV_QUEUE_KEY;
|
||||
pQueue->detail.key = code;
|
||||
pQueue->detail.key = code + MIN_KEYCODE;
|
||||
pQueue->val = value;
|
||||
}
|
||||
}
|
||||
@@ -551,6 +564,16 @@ EvdevProcessProximityState(InputInfoPtr pInfo)
|
||||
}
|
||||
}
|
||||
|
||||
/* Wacom's last frame resets all values to 0, including x/y.
|
||||
Skip over this. */
|
||||
if (prox_state == 0) {
|
||||
int v;
|
||||
if (valuator_mask_fetch(pEvdev->abs_vals, 0, &v) && v == 0)
|
||||
valuator_mask_unset(pEvdev->abs_vals, 0);
|
||||
if (valuator_mask_fetch(pEvdev->abs_vals, 1, &v) && v == 0)
|
||||
valuator_mask_unset(pEvdev->abs_vals, 1);
|
||||
}
|
||||
|
||||
if ((prox_state && !pEvdev->in_proximity) ||
|
||||
(!prox_state && pEvdev->in_proximity))
|
||||
{
|
||||
@@ -681,12 +704,7 @@ EvdevProcessTouch(InputInfoPtr pInfo)
|
||||
static int
|
||||
num_slots(EvdevPtr pEvdev)
|
||||
{
|
||||
int value;
|
||||
|
||||
if (pEvdev->mtdev)
|
||||
value = pEvdev->mtdev->caps.slot.maximum + 1;
|
||||
else
|
||||
value = libevdev_get_num_slots(pEvdev->dev);
|
||||
int value = pEvdev->mtdev ? pEvdev->mtdev->caps.slot.maximum + 1 : libevdev_get_num_slots(pEvdev->dev);
|
||||
|
||||
/* If we don't know how many slots there are, assume at least 10 */
|
||||
return value > 1 ? value : 10;
|
||||
@@ -905,7 +923,7 @@ EvdevPostProximityEvents(InputInfoPtr pInfo, int which)
|
||||
break;
|
||||
case EV_QUEUE_PROXIMITY:
|
||||
if (pEvdev->queue[i].val == which)
|
||||
xf86PostProximityEvent(pInfo->dev, which, 0, 0);
|
||||
xf86PostProximityEventM(pInfo->dev, which, pEvdev->old_vals);
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -1062,11 +1080,13 @@ EvdevReadInput(InputInfoPtr pInfo)
|
||||
do {
|
||||
rc = libevdev_next_event(pEvdev->dev, LIBEVDEV_READ_FLAG_NORMAL, &ev);
|
||||
if (rc < 0) {
|
||||
if (rc == -ENODEV) /* May happen after resume */
|
||||
if (rc != -EAGAIN && rc != -EINTR && rc != -EWOULDBLOCK) {
|
||||
/* May happen after resume or at device detach */
|
||||
xf86RemoveEnabledDevice(pInfo);
|
||||
else if (rc != -EAGAIN)
|
||||
EvdevCloseDevice(pInfo);
|
||||
LogMessageVerbSigSafe(X_ERROR, 0, "%s: Read error: %s\n", pInfo->name,
|
||||
strerror(-rc));
|
||||
}
|
||||
break;
|
||||
} else if (rc == LIBEVDEV_READ_STATUS_SUCCESS) {
|
||||
if (pEvdev->mtdev)
|
||||
@@ -1100,8 +1120,8 @@ EvdevKbdCtrl(DeviceIntPtr device, KeybdCtrl *ctrl)
|
||||
{ CAPSFLAG, LED_CAPSL },
|
||||
{ NUMFLAG, LED_NUML },
|
||||
{ SCROLLFLAG, LED_SCROLLL },
|
||||
{ MODEFLAG, LED_KANA },
|
||||
{ COMPOSEFLAG, LED_COMPOSE }
|
||||
{ COMPOSEFLAG, LED_COMPOSE },
|
||||
{ MODEFLAG, LED_KANA }
|
||||
};
|
||||
|
||||
InputInfoPtr pInfo;
|
||||
@@ -1476,10 +1496,8 @@ EvdevAddAbsValuatorClass(DeviceIntPtr device, int num_scroll_axes)
|
||||
continue;
|
||||
|
||||
abs = libevdev_get_abs_info(pEvdev->dev, axis);
|
||||
#if LINUX_VERSION_CODE > KERNEL_VERSION(2, 6, 30)
|
||||
/* Kernel provides units/mm, X wants units/m */
|
||||
resolution = abs->resolution * 1000;
|
||||
#endif
|
||||
|
||||
xf86InitValuatorAxisStruct(device, axnum,
|
||||
atoms[axnum],
|
||||
@@ -1923,7 +1941,7 @@ EvdevInit(DeviceIntPtr device)
|
||||
* So, unless you have a small screen, you won't be enjoying it much;
|
||||
* consequently, absolute axes are generally ignored.
|
||||
*
|
||||
* However, currenly only a device with absolute axes can be registered
|
||||
* However, currently only a device with absolute axes can be registered
|
||||
* as a touch{pad,screen}. Thus, given such a device, absolute axes are
|
||||
* used and relative axes are ignored.
|
||||
*/
|
||||
@@ -2353,8 +2371,10 @@ EvdevProbe(InputInfoPtr pInfo)
|
||||
pInfo->type_name = XI_TOUCHSCREEN;
|
||||
} else {
|
||||
if (!libevdev_has_event_code(pEvdev->dev, EV_REL, REL_X) ||
|
||||
!libevdev_has_event_code(pEvdev->dev, EV_REL, REL_Y))
|
||||
!libevdev_has_event_code(pEvdev->dev, EV_REL, REL_Y)) {
|
||||
pEvdev->flags |= EVDEV_RELATIVE_EVENTS;
|
||||
EvdevForceXY(pInfo, Relative);
|
||||
}
|
||||
xf86IDrvMsg(pInfo, X_INFO, "Configuring as mouse\n");
|
||||
pInfo->type_name = XI_MOUSE;
|
||||
}
|
||||
@@ -2485,7 +2505,7 @@ EvdevOpenDevice(InputInfoPtr pInfo)
|
||||
}
|
||||
|
||||
if (pInfo->fd < 0) {
|
||||
xf86IDrvMsg(pInfo, X_ERROR, "Unable to open evdev device \"%s\".\n", device);
|
||||
xf86IDrvMsg(pInfo, X_ERROR, "Unable to open evdev device \"%s\" (%s).\n", device, strerror(errno));
|
||||
return BadValue;
|
||||
}
|
||||
|
||||
|
||||
@@ -36,7 +36,14 @@
|
||||
#define EVDEV_H
|
||||
|
||||
#include <linux/input.h>
|
||||
#include <linux/types.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
/* Tolerate prior #include <linux/input.h> */
|
||||
#undef BUS_NONE
|
||||
#undef BUS_PCI
|
||||
#undef BUS_SBUS
|
||||
#undef BUS_PLATFORM
|
||||
#undef BUS_USB
|
||||
|
||||
#include <xorg-server.h>
|
||||
#include <xf86Xinput.h>
|
||||
|
||||
Reference in New Issue
Block a user