Pimp your project!

Forum: LinuxTotal Replies: 14
Author Content
Sander_Marechal

Sep 13, 2007
3:48 PM EDT
And now for something completely different. Just to get away from all the endless circular Mono/Moonlight flamefest we've been having.

I know from most LXer regulars what kind of advocacy/marketing/etcetera projects they are involved in (tux-project et. al), because news usually floats through the newswire here. But who among you are actually productive for FOSS in the traditional way? Who of you are programmers trying to build and improve the software? Pimp your project here, because I'm interested to see what you're working on :-)

If you're involved in some non-programming project that you think we don't know about yet, feel free to post too. Let's get productive again!
jezuch

Sep 13, 2007
5:10 PM EDT
Well, I'm no one special, just a sole maintainer of my usual testbed for silly ideas, the half-alive Starmapper project: http://sourceforge.net/projects/starmapper In a similar spirit I recently got involved in a Thousand Parsec project: http://www.thousandparsec.net/tp/ I'm writing a Java implementation of the TP protocol and generally helping out with a "fresh view".
Sander_Marechal

Sep 13, 2007
10:47 PM EDT
Quoting:Well, I'm no one special, just a sole maintainer of my usual testbed for silly ideas, the half-alive Starmapper project


Sounds interesting. Have you got any screenshots for version 3?

Aside from the occasional hacking I do on other people's projects, I am running 4 of my own.

Gnome Hearts: This is a simple card game similar to MS-Hearts for GNOME. Version 0.2 was released last week. Code, screenshots, etcetera at http://www.jejik.com/gnome-hearts

Jukebox: I'm writing a jukebox daemon similar to MPD, the Music Player Daemon. The biggest difference from MPD is that I want my jukebox to be aware of other jukeboxes and be able to manage multiple libraries dynamically. MPD can only manage one library. I want to make it work with Avahi/Zeroconf.

Imagine that at your job you have a jukebox daemon playing music. The employees can all carry a personal music collection on their laptops, Maemo, Linux-powered MP3 player, phone, whatever. As soon as they walk in the door, the jukebox daemon integrates those personal collections into it's own library and starts playing them. When someone leaves, their collection is removed again. Cool stuff :-)

There is no website yet (because the project has no name yet. I can't name it "jukebox". Got ideas?) but the code so far is available at http://svn.jejik.com/viewvc.cgi/jukebox/trunk/ in Subversion. It doesn't do Avahi/Zeroconf yet, but it can randomly play a local library and you can control it through telnet (port 3000). It currently outputs an MP3 stream to an IceCast server.

ODF-XSLT: This is a small library that allows you to process ODF documents with XSLT. It's very powerfull (based on XPath) but it's written in PHP. I hope to port this to C one day so I can easily write PHP, Python and Java wrappers. The code is available under GPLv3 on request (no website yet).

Filevert: A file conversion server. It's really immature at the moment and can only convert office documents (through OOo). You can control it through a webinterface or with XML-RPC. I have written a Nautilus plugin that uses the latter. It's pretty cool. On my GNOME desktop, I can simply right-click a .doc file and the context menu will have entries like "Convert to OpenDocument", "Convert to PDF", etcetera. The server should be fully pluggable when it's done, so you can easily add new conversion engines (e.g. integrate ImageMagick, etcetera). Code not available yet, sorry :-)
jezuch

Sep 14, 2007
3:55 AM EDT
Quoting:Sounds interesting. Have you got any screenshots for version 3?


Yes, I actually have a [sligtly outdated] Wiki, I should have liked it instead of sf page :) http://starmapper.sourceforge.net/ - the links to screens are on the right.

Quoting:As soon as they walk in the door, the jukebox daemon integrates those personal collections into it's own library and starts playing them. When someone leaves, their collection is removed again. Cool stuff :-)


Sounds like it :) Too bad I don't work in an office and can't test it ;)
ColonelPanik

Sep 14, 2007
5:43 AM EDT
ODF-XSLT Cannot wait to see this in the package list on Synaptic!
Sander_Marechal

Sep 14, 2007
7:15 AM EDT
Quoting:the links to screens are on the right.


I love the smooth-mixed plot: http://starmapper.sourceforge.net/demos/apocal-2510-sm.png

Quoting:ODF-XSLT Cannot wait to see this in the package list on Synaptic!


Because of the name? Wait till I ported it to C. Then it'll be "libodfxslt". Say that 5 times fast :-)

If you want the code, just give me a holler and PM me an e-mail address or something.
jezuch

Sep 14, 2007
3:18 PM EDT
Quoting:I love the smooth-mixed plot


Yeah, I like it too :) Looks much like a nebula.

Quoting:Because of the name? Wait till I ported it to C. Then it'll be "libodfxslt". Say that 5 times fast :-)


My mother language is Polish, piece of cake for me ;)
Sander_Marechal

Sep 14, 2007
11:47 PM EDT
Quoting:Looks much like a nebula.


It's a bit mesmerizing, really. But you can't really see the difference between the players belonging to the same group (color) in there.
gus3

Sep 15, 2007
8:49 PM EDT
I once had this little idea for low-resource systems, in which unused code is never loaded, but invoked functions (or function families) are loaded at call-time.

http://gus3.typepad.com/i_am_therefore_i_think/2006/02/callt...

It isn't exactly "open-source," more of a programming-theory exercise. I provide an example that works with the GNU run-time linker.
Sander_Marechal

Sep 16, 2007
5:30 AM EDT
gus3: That's an interesting idea. However, I see only limited applicability for it (perhaps I'm seeing it wrong though?). Usually when I link to a shared library it's because I want to use some functions from it, so the library will be loaded anyway. It then becomes a question of when it will be loaded: at start-up or somewhere after that.

There are two use cases that this could be useful though:

1) unused codepaths. For example, I have some game X that can be played over the network using library Y. But, when I don't play over the network, the networking code never executes so library Y is never loaded. But in this use case it might be better to load at run-time on a library-by-library basis instead of a function-by-function bases. Less overhead :-)

2) unused dependencies: E.g. library X contains functions foo() and bar(). Library X needs library Y for function bar(). My program links with library X but I only need function foo(), not bar(). Normally library Y would get loaded regardless, but in this case it would not (because bar() never executes). But in this example, the code to link at run-time is in the libraries, not in the program itself. Good luck trying to convince all the library builders :-)

Perhaps it would be best to solve this at the compiler/linker level? I.e. a smart linker that keeps track of the function calls between different shared libraries and that can tell that I am only using foo() and not bar(), hence it should not link library Y.

I have run into this very problem myself with Gnome Hearts. I used Lua for the AI and now switched to Python. Both these languages require that I use the -ldl linker flag, causing me to link much more libraries than I really need. Debian even filed a bug report with me about that: http://bugzilla.jejik.com/show_bug.cgi?id=10
gus3

Sep 16, 2007
8:09 AM EDT
Sander: You hit the nail on the head with both points. Why do I need to map all of glibc, if I only need memory, network, and file I/O? Or, if I'm only doing number grinding and writing the results to a file, why do I need network and console support code?
gus3

Sep 16, 2007
8:22 AM EDT
I just thought of a real-world, working counterpart: Linux used to load kernel modules on demand. Unused devices meant unloaded drivers. Remember modules.conf? If you never opened a device with char-major-4, the serial I/O driver never used up your memory. OTOH, as soon as you wanted to get on the Internet, the driver was loaded, linked, and initialized, ready for you to use, transparently to pppd.

Nowadays, drivers are loaded on bootup device detection instead...
jezuch

Sep 16, 2007
8:27 AM EDT
Well, "managed" languages (or rather environments) like Java implement something like this "natively". In Java, for example, the loading happens per-class. Unused classes are never touched and the runtime tries to avoid loading until absolutely necessary (because it's slow - disk accesses, code verification and stuff).

And even in C... Isn't it that the libraries are memory-mapped and the code pages are brought to memory only if they are needed? This way unused code stays on disk even though it is present in virtual memory... [remember that Unix was designed when a megabyte of memory was a lot of space]

Or maybe I don't understand what you mean :)
gus3

Sep 16, 2007
9:04 AM EDT
In Java, the potential cost of loading all the code at launch can be very high, if classes are coming from a dial-up network connection.

I just took a little browse through the Linux kernel, and it does appear that mmap()-ing a file does simply set a couple vectors to call on a page fault. I'm not schooled enough in the deep magic of the GNU linker to know how it creates links to text symbols at program launch.
Sander_Marechal

Sep 16, 2007
3:29 PM EDT
I'm afraid I am not familiar enough with the linker as well.

You cannot post until you login.