You are not logged in.
[andyrtr@workstation keytouch]$ keytouchd LibMXml: Could not open the XML document. keytouchd: '/etc/keytouch/current_keyboard.xml' is invalid [andyrtr@workstation keytouch]$
I think I have to configure the keyboard type first using keytouch-editor. I haven´t done that so far. I´m waiting for the integrated pkgbuild.
Not keytouch-editor! You first have to tell keyTouch what keyboard you are using. So first run "keytouch" and you will be asked for chosing your keyboard.
Offline
keytouchd will be started when the user starts an X-session. It grabs the extra function keys and excutes the action for the pressed key defined by the user.
If you get an error like:
X Error of failed request: BadAccess (attempt to access private resource denied)
Major opcode of failed request: 33 (X_GrabKey)
Serial number of failed request: 7
Current serial number in output stream: 68
another program is grabbing one of the extra function keys. So check if programs like Xbindkeys are running or you configured GNOME or KDE to grab one of the keys.
Packager: please hold on the packager-howto will be published within an hour.
Offline
The packagers howto is available at: http://keytouch.sourceforge.net/keytouc … ers-howto/
Offline
keytouchd will be started when the user starts an X-session. It grabs the extra function keys and excutes the action for the pressed key defined by the user.
If you get an error like:X Error of failed request: BadAccess (attempt to access private resource denied) Major opcode of failed request: 33 (X_GrabKey) Serial number of failed request: 7 Current serial number in output stream: 68
another program is grabbing one of the extra function keys. So check if programs like Xbindkeys are running or you configured GNOME or KDE to grab one of the keys.
Packager: please hold on the packager-howto will be published within an hour.
Yeah, I did configure some of the function keys in kde some time ago (but I'm using gnome right now)
Do you know how I can fix this problem without fully uninstalling KDE?
Offline
MarvinR wrote:keytouchd will be started when the user starts an X-session. It grabs the extra function keys and excutes the action for the pressed key defined by the user.
If you get an error like:X Error of failed request: BadAccess (attempt to access private resource denied) Major opcode of failed request: 33 (X_GrabKey) Serial number of failed request: 7 Current serial number in output stream: 68
another program is grabbing one of the extra function keys. So check if programs like Xbindkeys are running or you configured GNOME or KDE to grab one of the keys.
Packager: please hold on the packager-howto will be published within an hour.
Yeah, I did configure some of the function keys in kde some time ago (but I'm using gnome right now)
Do you know how I can fix this problem without fully uninstalling KDE?
If KDE isn't running there won't be a problem. Maybe GNOME grabs some keys by default (check your "Keyboard Shortcuts" configuration).
Offline
The packagers howto is available at: http://keytouch.sourceforge.net/keytouc … ers-howto/
Thank you for taking the time to register to this forum and answering our questions. I have read the packagers howto and it answered all the questions I was having. Hopefully, I'll have a working package tonight.
Offline
For some reason, the /etc/X11/Xsession.d/40keytouchd script isn't executed. It looks like the scripts in /etc/X11/Xsession.d are not sourced at all. There was only one script there and it was for a SysV init system while Arch use BSD style init. :? However, putting
keytouchd &
in your ~/.xinitrc (or ~/.xsession) solves that issue.
Below is the current PKGBUILD with daemon script. Let me know how they work. If everything is OK, I'll submit this to the AUR (with maybe a .install file informing to put keytouchd in .xinitrc). BTW, the Aumixer plugin work fine here.
pkgname=keytouch
pkgver=2.0.0
pkgrel=1
pkgdesc="A program which allows you to easily configure the extra function keys of your keyboard"
depends=('gtk2' 'gksu')
source=(http://dl.sourceforge.net/keytouch/$pkgname-$pkgver.tar.gz keytouch
http://dl.sourceforge.net/keytouch/keytouch-editor-2.0.2.tar.gz
http://dl.sourceforge.net/keytouch/keytouch-amixer_plugin-1.0.tar.gz)
md5sums=('a7a22320707b887b1c5dedb77d2cf3e6' 'c16fbda7e753cccab5fea2682cb47f51'
'da03fef05570cc5e1d49d00f7b15c810' 'be0c9cea666a02ec58f4f43830c3b659')
url="http://keytouch.sourceforge.net/"
build() {
cd $startdir/src/$pkgname-2.0
./configure --prefix=/usr --sysconfdir=/etc
make || return 1
#script check if Xsession directory exists, so create it
mkdir -p $startdir/pkg/etc/X11/Xsession.d
mkdir $startdir/pkg/etc/rc.d
make DESTDIR=$startdir/pkg install
cd $startdir/src/$pkgname-2.0/keytouch-config
./configure --prefix=/usr --sysconfdir=/etc
make || return 1
make DESTDIR=$startdir/pkg install
cd $startdir/src/$pkgname-2.0/keytouch-keyboard
./configure --prefix=/usr --sysconfdir=/etc
make || return 1
make DESTDIR=$startdir/pkg install
cd $startdir/src/'keytouch-editor 2.0'
make || return 1
install -m755 $startdir/src/'keytouch-editor 2.0'/keytouch-editor $startdir/pkg/usr/bin/keytouch-editor
cd $startdir/src/amixer
make || return 1
install -D -m755 amixer.so $startdir/pkg/usr/share/keytouch/plugins/amixer.so
rm $startdir/pkg/etc/rc.d/keytouch-init.sh
install -m755 $startdir/src/keytouch $startdir/pkg/etc/rc.d/keytouch
mkdir -p $startdir/pkg/usr/share/applications
echo '[Desktop Entry]
Name=keyTouch
Comment=Keyboard configuration tool
Icon=/usr/share/keytouch/pixmaps/icon.png
Exec=/usr/bin/keytouch
Terminal=false
Type=Application
Categories=Application;Accessories
StartupNotify=false' > $startdir/pkg/usr/share/applications/keytouch.desktop
}
#!/bin/bash
. /etc/rc.conf
. /etc/rc.d/functions
case "$1" in
start)
stat_busy "Starting keyTouch Daemon"
/usr/bin/keytouch-init
if [ $? -gt 0 ]; then
stat_fail
else
stat_done
fi
;;
stop)
stat_busy "Stopping keyTouch Daemon"
stat_done
;;
restart)
$0 stop
$0 start
;;
*)
echo "usage: $0 {start|stop|restart}"
esac
exit 0
Offline
For some reason, the /etc/X11/Xsession.d/40keytouchd script isn't executed. It looks like the scripts in /etc/X11/Xsession.d are not sourced at all. There was only one script there and it was for a SysV init system while Arch use BSD style init. :? However, putting
keytouchd &
in your ~/.xinitrc (or ~/.xsession) solves that issue.
No, you should put "keytouchd &" in /etc/X11/Xsession. This is described here:
http://keytouch.sourceforge.net/keytouc … ode15.html
Yes, my make install script checks if /etc/X11/Xsession.d/ exists, because when it exists the scripts in it will probably be executed. If this directory does not exist the "keytouchd &" line will be add to the beginning of /etc/X11/Xsession. So do not mkdir /etc/X11/Xsessions.d/.
Offline
Yes, my make install script checks if /etc/X11/Xsession.d/ exists, because when it exists the scripts in it will probably be executed. If this directory does not exist the "keytouchd &" line will be add to the beginning of /etc/X11/Xsession. So do not mkdir /etc/X11/Xsessions.d/.
It's a bit different in a PKGBUILD, it doesn't create /etc/X11/Xsession.d/ , but it creates that directory inside another directory, where the whole package is made. Afterwards all files from that directory are zipped, and when you install it, the files are just copied.
So you can change de PKGBUILD not to create the $startdir/pkg/etc/X11/Xsession.d, but the the script will fail. You should at least create $startdir/pkg/etc/X11 , then I guess the script will add keytouchd & to the Xsession file. But still then it won't work, as when pacman would install the pkgbuild, the original /etc/X11/Xsession file might exist on the filesystem, and pacman will produce an error.
I don't know how to fix it, do you know Snowman?
Anyway I think the /etc/X11/ directory can better be removed from the package as these file won't work (or someone should find a solution to add a line to a file during "pacman -A")
Besides that it also didn't work here when I added "keytouchd &" to the /etc/X11/Xsession file (or I might have made a misstake), but adding "keytouchd &" to ~/.xinitrc did do the trick, now it works :-)
(although keytouch stays complaining about the X_grabkey error)
btw:
Categories=Application;Accessories
in the desktop entry section should be replaced by:
Categories=Application;Utility;
(this creates a shortcut in the Accessories section in gnome, the first code block created a link in a section called "Other"
btw2: thank you snowman for fine-tuning my first PKGBUILD, it wouldn't have worked without you
Offline
MarvinR wrote:Yes, my make install script checks if /etc/X11/Xsession.d/ exists, because when it exists the scripts in it will probably be executed. If this directory does not exist the "keytouchd &" line will be add to the beginning of /etc/X11/Xsession. So do not mkdir /etc/X11/Xsessions.d/.
It's a bit different in a PKGBUILD, it doesn't create /etc/X11/Xsession.d/ , but it creates that directory inside another directory, where the whole package is made. Afterwards all files from that directory are zipped, and when you install it, the files are just copied.
So you can change de PKGBUILD not to create the $startdir/pkg/etc/X11/Xsession.d, but the the script will fail. You should at least create $startdir/pkg/etc/X11 , then I guess the script will add keytouchd & to the Xsession file. But still then it won't work, as when pacman would install the pkgbuild, the original /etc/X11/Xsession file might exist on the filesystem, and pacman will produce an error.
I don't know how to fix it, do you know Snowman?
Anyway I think the /etc/X11/ directory can better be removed from the package as these file won't work (or someone should find a solution to add a line to a file during "pacman -A")Besides that it also didn't work here when I added "keytouchd &" to the /etc/X11/Xsession file (or I might have made a misstake), but adding "keytouchd &" to ~/.xinitrc did do the trick, now it works :-)
(although keytouch stays complaining about the X_grabkey error)btw:
Categories=Application;Accessories
in the desktop entry section should be replaced by:
Categories=Application;Utility;
(this creates a shortcut in the Accessories section in gnome, the first code block created a link in a section called "Other"
btw2: thank you snowman for fine-tuning my first PKGBUILD, it wouldn't have worked without you
It is strange that adding the line to Xsession does not work. I know someone using keyTouch on ArchLinux but he didn't complain about this.
About the XKeyGrab error:
Run the program xev and press all your extra function keys. The key that does not produce a Key Press (and a Release) event is grabbed by another program.
Offline
Besides that it also didn't work here when I added "keytouchd &" to the /etc/X11/Xsession file (or I might have made a misstake), but adding "keytouchd &" to ~/.xinitrc did do the trick, now it works :-)
Did you put the line at the beginning of Xsession?
Offline
Yes, as I still had to create te Xsession file.
Maybe I did something wrong, I will try it again (but now I'm not on my linux box)
Offline
Again the following lines should be removed:
#script check if Xsession directory exists, so create it
mkdir -p $startdir/pkg/etc/X11/Xsession.d
Offline
Again the following lines should be removed:
#script check if Xsession directory exists, so create it mkdir -p $startdir/pkg/etc/X11/Xsession.d
If you remove that line the makepkg command will fail. you should at least leave the command
mkdir -p $startdir/pkg/etc/X11/
, but this will cause the pacman -A command to fail it the Xsession file already exists on the filesystem.
But besides that, I can't get keytouch to work
It does work when I add keytouchd& to ./xinitrc , and then manually run startx. But when I start x through GDM, it doesn't work. Also putting keytouchd& in Xsession also doesn't work.
I think I'm gonna search another way to make my function keys work
Offline
It seems that the scripts in /etc/X11/Xsession.d are not executed. I wanted to talk to a dev on IRC about that but didn't had time yet.
About gdm, try putting keytouchd& in ~/.xsession (create the file if it doesn't exist. xdm uses ~/.xsession instead of ~/.xinitrc. Maybe gdm use ~/.xsession too. :?
Offline
putting it into ~/.xsession also doesn't work.
When I start gdm, launch a failsafe terminal, type keytouchd&, it works.
I think I'll just drop this program, there must be another way to get my buttons working
Offline
I think I'll just drop this program, there must be another way to get my buttons working
OK. Try lineakd (pacman -S lineakd).
Offline
putting it into ~/.xsession also doesn't work.
No you should put it in /etc/X11/Xsession. But if keytouchd cannot grab one of the keys it will exit and I think that is why it doesn't work for you.
OK. Try lineakd (pacman -S lineakd).
Just like keytouch, lineak grabs your keys. And when another program is grabbing a key, lineak will also not be able to grab it.
On http://keytouch.sf.net/ you can read why you should use keytouch instead of lineak.
Offline
I modified keytouchd so that it continues when grabbing a key fails. This will solve the problem of mouse256.
You can download keytouch 2.0.1 from: http://prdownloads.sourceforge.net/keyt … z?download
Offline
I modified keytouchd so that it continues when grabbing a key fails. This will solve the problem of mouse256.
You can download keytouch 2.0.1 from: http://prdownloads.sourceforge.net/keyt … z?download
You're great, now it works perfectly :-p
All my function keys work with keytouch, only the volume-up and down are still grabbed by gnome. But that's no problem, it works better if gnome grabs them (I'm still using OSS, and I couldn't get aumix to work with OSS)
I still have keytouch& in my .xinitrc file, I will try putting it in Xsession file later, I don't have time for this now.
here is the PKGBUILD (and you still need the keytouch deamon script from snowman)
pkgname=keytouch
pkgver=2.0.1
pkgrel=1
pkgdesc="A program which allows you to easily configure the extra function keys of your keyboard"
depends=('gtk2' 'gksu')
source=(http://dl.sourceforge.net/keytouch/$pkgname-$pkgver.tar.gz keytouch
http://dl.sourceforge.net/keytouch/keytouch-editor-2.0.2.tar.gz
http://dl.sourceforge.net/keytouch/keytouch-amixer_plugin-1.0.tar.gz)
md5sums=('873b5d15116acc34fbebae7c4cd70093' 'a5f5da2fd3485e59855c9c3cfa1f36e7'
'da03fef05570cc5e1d49d00f7b15c810' 'be0c9cea666a02ec58f4f43830c3b659')
url="http://keytouch.sourceforge.net/"
build() {
cd $startdir/src/$pkgname-2.0
./configure --prefix=/usr --sysconfdir=/etc
make || return 1
#script check if Xsession directory exists, so create it
mkdir -p $startdir/pkg/etc/X11/Xsession.d
mkdir $startdir/pkg/etc/rc.d
make DESTDIR=$startdir/pkg install
cd $startdir/src/$pkgname-2.0/keytouch-config
./configure --prefix=/usr --sysconfdir=/etc
make || return 1
make DESTDIR=$startdir/pkg install
cd $startdir/src/$pkgname-2.0/keytouch-keyboard
./configure --prefix=/usr --sysconfdir=/etc
make || return 1
make DESTDIR=$startdir/pkg install
cd $startdir/src/'keytouch-editor 2.0'
make || return 1
install -m755 $startdir/src/'keytouch-editor 2.0'/keytouch-editor $startdir/pkg/usr/bin/keytouch-editor
cd $startdir/src/amixer
make || return 1
install -D -m755 amixer.so $startdir/pkg/usr/share/keytouch/plugins/amixer.so
rm $startdir/pkg/etc/rc.d/keytouch-init.sh
install -m755 $startdir/src/keytouch $startdir/pkg/etc/rc.d/keytouch
mkdir -p $startdir/pkg/usr/share/applications
echo '[Desktop Entry]
Name=keyTouch
Comment=Keyboard configuration tool
Icon=/usr/share/keytouch/pixmaps/icon.png
Exec=/usr/bin/keytouch
Terminal=false
Type=Application
Categories=Application;Utility;
StartupNotify=false' > $startdir/pkg/usr/share/applications/keytouch.desktop
}
SNOWMAN: are you going to add this into aur?
Offline
SNOWMAN: are you going to add this into aur?
Yes. Before to do so, I would like to find out why the scripts in /ect/X11/Xsession.d aren't executed by xorg.
Offline
mouse256 wrote:SNOWMAN: are you going to add this into aur?
Yes. Before to do so, I would like to find out why the scripts in /ect/X11/Xsession.d aren't executed by xorg.
Well it is very simple. When X starts a new session the /etc/X11/Xsession (yes without .d) script will be executed. Some distributions have the /etc/X11/Xsession.d/ directory containing some scripts. For those distros the Xsession script (not xorg) runs the scripts in Xsession.d/
I think using the Xsession.d/ directory is a better solution. However the Xsession script for Arch Linux does contain the code that runs the scripts in Xsession.d/. You should leave this as it is and add the line "keytouchd &" to the beginning of the Xsession script.
Note that when you create the Xsession.d directory, the make install thinks your distro excutes the scripts in this directory. So do not create the directory and put something in the post install script of the package that adds "keytouchd &" to the beginning of the /etc/X11/Xsession script (just like what was written in the keytouch packagers howto).
Offline
that might explain a lot.
There was a /etc/X11/Xsession.d/ directory already on my system, but no Xsession file, so no file to execute the Xsession.d directory...
Offline
mouse256 wrote:SNOWMAN: are you going to add this into aur?
Yes. Before to do so, I would like to find out why the scripts in /ect/X11/Xsession.d aren't executed by xorg.
I am sorry, I thought Arch Linux has no /etc/X11/Xsession.d/. Maybe another script than /etc/X11/Xsession calls the scripts in Xsession.d.
Note that the name of a script in this directory should begin with an integer (for the calling senquence). Name script "40keytouchd".
Does it work now?
Offline
Something new? Does it work fine now? Will you bring it to AUR soon?
Offline