Active Topics

 



Notices


Reply
Thread Tools
Posts: 2,225 | Thanked: 3,822 times | Joined on Jun 2010 @ Florida
#1
Hello, I have compiled xdotool for the N900 just now, because I was a bit annoyed by the fact that for once the N900 didn't have something I wanted that was open source and ubiquitously useful. If someone wants to explain to me how to package it as a deb, or how to send the source to the autobuilder, or how to optify it, please chime in. For now, it's just raw compiled binaries, for the people who want them, but don't know how to, or are too lazy to, compile them. I suspect skilled devs who would need xdotool already compile it for themselves, but you never know, might help someone:
xdotool.tar
I put them in:
/usr/bin/xdotool
/usr/lib/libxdo.so
/usr/lib/libxdo.so.2
/usr/include/xdo.h
So as root, unpack them there if you know what you're doing enough to fiddle with xdotool, but not enough to play with file paths. Near as I can tell, they have to be in the same folders, until you hit the last folder. Then they split into bin, lib, and include.

I'm not sure if I even need xdo.h. I did not include the man file in the above, because, well, lazy, but if someone wants it, I suppose I can dump that here too.

I have searched www.maemo.org/packages, and I used power search, for xdotool and I haven't found it yet - so if it's buried somewhere and common knowledge, my apologies. The only references to xdotool I see are when talking about Easy Debian, which makes me presume it's the Debian package in the chroot, not for the N900 itself.

To be clear, I have barely tested this at all. This is not optified (wouldn't know where to start), and for all I know your N900 will burn a horrible death upon use.

I have thus far tested the one thing I wanted xdotool for: xdotool key(up/down)

That works - in X-Terminal (only place I tested it). I have succesfully enabled auto-rotation from command-line using:
Code:
xdotool keydown ctrl && xdotool keydown shift && xdotool key r && xdotool keyup shift && xdotool keyup ctrl
--- Random backstory, feel free to skip ---
Why did I even bother? Because about 3 months ago, I was working on an auto-rotating conky.conf file. Everything worked perfectly, except for the part where I couldn't auto-enable auto-rotation, and the dev never compiled conky with the auto-rotation flag set to true. I asked this: http://talk.maemo.org/showthread.php?t=64816 No one replied, I spent a bunch of time banging my head on walls, etc. But I was a newb then.

As time passed, I developed my coding skills enough to install scratchbox on my debian virtual machine, get comfortable with compiling, and so on. Then, recently, I fiddled with some dbus scripts to get some keyboard short-cuts for myself. This inspired me to come back to the auto-rotation thing. I started seeing if I could see if I could send keypresses over dbus. I haven't figured that bit out yet, though I'm sure it's possible, but meh. At some point I finally looked at the shortcutd source code, to see if I could get ideas, and realized it was using some weird XTest stuff I never heard of. Looking around, I realized it was a library for X itself. I had no clue how to call functions from that library from the command-line either, but I DID stumble upon xdotool in the process. At first I didn't want to go through a whole special package just to enable it, but I thought, well, might as well.

Looking at the current hildon-desktop developments, this might be useless soon, for the one task I bothered installing it for myself for, as portrait mode seems to be getting progressively included into more parts of Hildon.
--- End backstory/rambling ---

Anyway, the attached binaries are compiled from the source package found in the .tar.gz on this page, using "make all install": http://www.semicomplete.com/projects/xdotool/

It's a couple months more recent than the xdotool package in debian sid armel. For all I know, there's more recent versions available already compiled that will run on the N900, so if this is useless, well, it'll sink into obscurity, and oh well. If there's any actual demand for this to make it to the repositories, and I can figure out packaging and autobuilder and so on, I can use even more recent SVN sources for that.
 

The Following 11 Users Say Thank You to Mentalist Traceur For This Useful Post:
Posts: 840 | Thanked: 823 times | Joined on Nov 2009
#2
http://maemo.org/packages/package_in...101012.3049-6/

I found this but trying to install it did not work, said it was incompatible. Any ideas why?
 
electroaudio's Avatar
Posts: 381 | Thanked: 336 times | Joined on Jan 2011 @ Stockholm, Sweden
#3
Originally Posted by Mentalist Traceur View Post
If someone wants to explain to me how to package it as a deb, or how to send the source to the autobuilder,
That part of the autobuilder is quite easy to do.
Just go here and follow the instructions: https://garage.maemo.org/extras-assistant/

However, if you wish to include other files like the manpages, it get a little more complicated but not so much.
-It is a series of Makefile.am files that needs to be created and edited to do that.
__________________
Deskypplet , a desktop for N900 *RIP*
 

The Following User Says Thank You to electroaudio For This Useful Post:
Posts: 127 | Thanked: 17 times | Joined on Jul 2010 @ stockton
#4
could this be used to get a right click in dosbox
 
Addison's Avatar
Posts: 3,811 | Thanked: 1,151 times | Joined on Oct 2007 @ East Lansing, MI
#5
Use Xbindkeys along with Xmodmap.

Right click
xmodmap -e "pointer = 3 2 1"

Left click
xmodmap -e "pointer = 1 2 3"
 

The Following 2 Users Say Thank You to Addison For This Useful Post:
Posts: 127 | Thanked: 17 times | Joined on Jul 2010 @ stockton
#6
i cant get that working on the n900 and i dont have any spare time to learn how these programs work just started a mechanical engineering course and all my spare time is used up with that was kinda hopeing some linux guru would come along and show me the error of my ways or a very noob freindly copy and paste type thing lol
 
qwazix's Avatar
Moderator | Posts: 2,622 | Thanked: 5,447 times | Joined on Jan 2010
#7
what exactly is your error message? I have it installed and it works just fine

(enable extras-devel after reading the warning well and then apt-get install xdotool)
__________________
Proud coding competition 2012 winner: ρcam
My other apps: speedcrunch N9 N900 Jolla –– contactlaunch –– timenow

Nemo UX blog: Grog
My website: qwazix.com
My job: oob
 
Posts: 840 | Thanked: 823 times | Joined on Nov 2009
#8
Originally Posted by qwazix View Post
what exactly is your error message? I have it installed and it works just fine

(enable extras-devel after reading the warning well and then apt-get install xdotool)
Me?
"apt-get install xdotool" did not find the package (guessing I didn't have extras-devel enabled in default appman) so I tried to get the .deb from the package page. That said "could not install package, package is incompatible" it wasn't really specific. I just used Mentalist Traceur's tarball and installed manually in the end, that worked fine.
 
qwazix's Avatar
Moderator | Posts: 2,622 | Thanked: 5,447 times | Joined on Jan 2010
#9
Ok, some times HAM refuses to install debs. You can go to xterm and
Code:
dpkg -i whatever.deb
as root
__________________
Proud coding competition 2012 winner: ρcam
My other apps: speedcrunch N9 N900 Jolla –– contactlaunch –– timenow

Nemo UX blog: Grog
My website: qwazix.com
My job: oob
 

The Following User Says Thank You to qwazix For This Useful Post:
Reply

Tags
keypress, xdotool


 
Forum Jump


All times are GMT. The time now is 04:37.