File tree Expand file tree Collapse file tree 5 files changed +6
-8
lines changed
.devcontainer/features/desktop-selkies/src Expand file tree Collapse file tree 5 files changed +6
-8
lines changed Original file line number Diff line number Diff line change @@ -44,7 +44,6 @@ sudo chmod 777 /dev/input/js*
44
44
if [ -e " /usr/lib/x86_64-linux-gnu/selkies_joystick_interposer.so" ]; then
45
45
export SELKIES_INTERPOSER=' /usr/$LIB/selkies_joystick_interposer.so'
46
46
export LD_PRELOAD=" ${SELKIES_INTERPOSER}${LD_PRELOAD: +: ${LD_PRELOAD} } "
47
- export SDL_JOYSTICK_DEVICE=/dev/input/js0
48
47
fi
49
48
50
49
# Start desktop environment
Original file line number Diff line number Diff line change @@ -12,10 +12,10 @@ until [ -d "${XDG_RUNTIME_DIR}" ]; do sleep 0.5; done
12
12
# Configure joystick interposer
13
13
export SELKIES_INTERPOSER=' /usr/$LIB/selkies_joystick_interposer.so'
14
14
export LD_PRELOAD=" ${SELKIES_INTERPOSER}${LD_PRELOAD: +: ${LD_PRELOAD} } "
15
- export SDL_JOYSTICK_DEVICE=/dev/input/js0
16
15
mkdir -pm1777 /dev/input || sudo-root mkdir -pm1777 /dev/input || echo ' Failed to create joystick interposer directory'
17
16
touch /dev/input/js0 /dev/input/js1 /dev/input/js2 /dev/input/js3 || sudo-root touch /dev/input/js0 /dev/input/js1 /dev/input/js2 /dev/input/js3 || echo ' Failed to create joystick interposer devices'
18
- chmod 777 /dev/input/js* || sudo-root chmod 777 /dev/input/js* || echo ' Failed to change permission for joystick interposer devices'
17
+ touch /dev/input/event1000 /dev/input/event1001 /dev/input/event1002 /dev/input/event1003 || sudo-root touch /dev/input/event1000 /dev/input/event1001 /dev/input/event1002 /dev/input/event1003 || echo ' Failed to create joystick interposer devices'
18
+ chmod 777 /dev/input/js* /dev/input/event* || sudo-root chmod 777 /dev/input/js* /dev/input/event* || echo ' Failed to change permission for joystick interposer devices'
19
19
20
20
# Set default display
21
21
export DISPLAY=" ${DISPLAY:-: 20} "
Original file line number Diff line number Diff line change @@ -12,7 +12,6 @@ until [ -d "${XDG_RUNTIME_DIR}" ]; do sleep 0.5; done
12
12
# Configure joystick interposer
13
13
export SELKIES_INTERPOSER=' /usr/$LIB/selkies_joystick_interposer.so'
14
14
export LD_PRELOAD=" ${SELKIES_INTERPOSER}${LD_PRELOAD: +: ${LD_PRELOAD} } "
15
- export SDL_JOYSTICK_DEVICE=/dev/input/js0
16
15
17
16
# Set default display
18
17
export DISPLAY=" ${DISPLAY:-: 20} "
Original file line number Diff line number Diff line change @@ -186,15 +186,15 @@ The following paths are required to exist for the Joystick Interposer to pass th
186
186
``` bash
187
187
sudo mkdir -pm1777 /dev/input
188
188
sudo touch /dev/input/js0 /dev/input/js1 /dev/input/js2 /dev/input/js3
189
- sudo chmod 777 /dev/input/js*
189
+ sudo touch /dev/input/event1000 /dev/input/event1001 /dev/input/event1002 /dev/input/event1003
190
+ sudo chmod 777 /dev/input/js* /dev/input/event*
190
191
```
191
192
192
193
The following environment variables are required to be set in the environment each application is being run in to receive the joystick/gamepad input.
193
194
194
195
``` bash
195
196
export SELKIES_INTERPOSER=' /usr/$LIB/selkies_joystick_interposer.so'
196
197
export LD_PRELOAD=" ${SELKIES_INTERPOSER}${LD_PRELOAD: +: ${LD_PRELOAD} } "
197
- export SDL_JOYSTICK_DEVICE=/dev/input/js0
198
198
```
199
199
200
200
You can replace ` /usr/$LIB/selkies_joystick_interposer.so ` with any non-root path of your choice if using the ` .tar.gz ` tarball.
Original file line number Diff line number Diff line change @@ -185,10 +185,10 @@ export DISPLAY="${DISPLAY:-:0}"
185
185
# Configure the Joystick Interposer
186
186
export SELKIES_INTERPOSER=' /usr/$LIB/selkies_joystick_interposer.so'
187
187
export LD_PRELOAD=" ${SELKIES_INTERPOSER}${LD_PRELOAD: +: ${LD_PRELOAD} } "
188
- export SDL_JOYSTICK_DEVICE=/dev/input/js0
189
188
sudo mkdir -pm1777 /dev/input
190
189
sudo touch /dev/input/js0 /dev/input/js1 /dev/input/js2 /dev/input/js3
191
- sudo chmod 777 /dev/input/js*
190
+ sudo touch /dev/input/event1000 /dev/input/event1001 /dev/input/event1002 /dev/input/event1003
191
+ sudo chmod 777 /dev/input/js* /dev/input/event*
192
192
193
193
# Commented sections are optional but may be mandatory based on setup
194
194
You can’t perform that action at this time.
0 commit comments