<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="FeedCreator 1.7.6(BH)" -->
<rss version="2.0">
    <channel xmlns:g="http://base.google.com/ns/1.0">
        <title>Planet Maemo: category &quot;feed:d657281da8f1046af5c5fb58128972cc&quot;</title>
        <description>Blog entries from Maemo community</description>
        <link>http://maemo.org/news/planet-maemo/</link>
        <lastBuildDate>Tue, 09 Jun 2026 03:05:33 +0000</lastBuildDate>
        <generator>FeedCreator 1.7.6(BH)</generator>
        <language>en</language>
        <managingEditor>planet@maemo.org</managingEditor>
        <item>
            <title>Sorting package version strings</title>
            <link>http://madabar.com/techblog/2008/03/06/sorting-package-version-strings/</link>
            <description><![CDATA[
<p>Interesting less trivial than expected problem (solved): sorting package version numbers:</p>
<blockquote><pre>import re
import rpm

def get_package_version(name):
    """Return version string of installed package."""

    # note: ts can take an argument that is the root of the installation
    #       typically with a var/lib/rpm directory underneath it.
    transaction_set = rpm.ts()

    versions = [header['provideversion'][0]
                for header in transaction_set.dbMatch('name', name)]
    versions.sort(cmp_versions)
    return versions

def version2sortable(version):

    parts = re.split(r'(d+)', version)
    fields = []
    for part in parts:
        try:
            part = int(part)
        except ValueError:
            pass
        fields.append(part)
    return tuple(fields)

def cmp_versions(a, b):

    return cmp(version2sortable(a), version2sortable(b))

if __name__ == '__main__':
    print get_package_version('kernel')
</pre>
</blockquote>
<p>Output:<br />
<code><br />
['2.6.23.8-63.fc8', '2.6.23.9-85.fc8', '2.6.23.14-107.fc8', '2.6.23.14-115.fc8', '2.6.23.15-137.fc8']<br />
</code></p>
<p>Note: Wordpress is screwing up the markup on the code blocks above. If you have any tips on how to fix this please drop me a line.<br />
<strong>Update:</strong> Using pre/blockquote hack for now and will try out a code highlighter plug-in when I get the chance. Thanks Tim and Lindsay! <img src='http://madabar.com/techblog/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /></p>
<span class="net_nemein_favourites">0 <a href="http://maemo.org/news/?net_nemein_favourites_execute=fav&net_nemein_favourites_execute_for=812f1d78eb8111dc8f2d4bdd882592d092d0&net_nemein_favourites_url=https://maemo.org/news/favorites//json/fav/midgard_article/812f1d78eb8111dc8f2d4bdd882592d092d0/" class="net_nemein_favourites_create"><img src="http://static.maemo.org:81/net.nemein.favourites/not-favorite.png" style="border: none;" alt="Add to favourites" title="Add to favourites" /></a>1 <a href="http://maemo.org/news/?net_nemein_favourites_execute=bury&net_nemein_favourites_execute_for=812f1d78eb8111dc8f2d4bdd882592d092d0&net_nemein_favourites_url=https://maemo.org/news/favorites//json/bury/midgard_article/812f1d78eb8111dc8f2d4bdd882592d092d0/" class="net_nemein_favourites_create"><img src="http://static.maemo.org:81/net.nemein.favourites/not-buried.png" style="border: none;" alt="Bury" title="Bury" /></a></span>]]></description>
            <author>Tim Wegener &lt;twegener@madabar.com&gt;</author>
            <category>feed:d657281da8f1046af5c5fb58128972cc</category>
            <pubDate>Thu, 06 Mar 2008 12:34:34 +0000</pubDate>
            <guid>http://maemo.org/midcom-permalink-812f1d78eb8111dc8f2d4bdd882592d092d0</guid>
        </item>
        <item>
            <title>Updating to Fedora 8</title>
            <link>http://madabar.com/techblog/2007/11/30/updating-to-fedora-8/</link>
            <description><![CDATA[
<p>A few weekends ago I updated my system from Fedora 6 to Fedora 8. I did a fresh install, as opposed to doing an upgrade. Here are a few of the problems I encountered, along with solutions:</p>
<h3>Wireless networking wasn&#8217;t working</h3>
<p>Fedora 8 detected my Atheros-based wifi card, since it now includes the new freedomware ath5k driver. However I couldn&#8217;t get it to associate with my access point. The workaround was to install the proprietary madwifi package from livna: On a machine with Internet access, go to livna.org and download madwifi and the kmod-madwifi package corresponding to the installed kernel (do uname -r to find out). Then do:<br />
<code>su -<br />
rpm -ihv madwiki kmod-wifi<br />
modprobe -r ath5k<br />
modprobe ath_pci<br />
</code><br />
Go to Administration->Services and start/turn on NetworkManager and NetworkManagerDispatcher services. The NetworkManager applet should appear in the system tray. Click on this to configure a wireless connection. </p>
<h3>1280&#215;1024 resolution was not available</h3>
<p>This resolution was working on my Fedora 6 setup, with an nVidia gforce2 MX 440 and Viewsonic E771 monitor.<br />
To fix, add the following line to /etc/X11/xorg.conf in the &#8220;Display&#8221;/&#8221;Screen&#8221; section:<br />
<code>               Modes    "1280x1024" "1280x1024" "1280x960" "1280x960" "1280x800" "1280x800" "1152x864" "1152x864" "1152x768" "1152x768" "1024x768" "1024x768" "800x600" "800x600" "640x480" "640x480"</code></p>
<h3>Setting up the livna repository</h3>
<p>The livna.org repository is a separate repo containing packages that aren&#8217;t included in the main Fedora repo for various legal, technical and ethical reasons. I need it for the madwifi driver and the gspca webcam driver among other things. Set it up like so:<br />
<code>su -<br />
rpm -ihv http://rpm.livna.org/livna-release-8.rpm<br />
</code></p>
<h3>Installing the webcam driver</h3>
<p>The driver for my Logitech Quickcam IM webcam is freedomware, however apparently it does yucky things like JPEG decoding inside the kernel, so is not included in the mainline kernel. It can be installed from livna like so:<br />
<code>su -<br />
yum install gspca<br />
modprobe gspca</code><br />
Alternatively, you can install it from the GUI by going to System->Add/Remove Software and searching for gspca.<br />
You can test that the webcam is working by running Ekiga (strangely filed under Internet->IP Telephony blah blah) and setting up video.</p>
<h3>Using a home directory on a separate partition</h3>
<p>I have my home directory stored on a separate &#8216;data&#8217; partition. I was not able to log in when I configured my account to use this as my home directory. To fix this, I had to change the SELinux context on the root directory of the file-system on the data partition like so:<br />
<code>chcon system_u:object_r:home_root_t:s0 /data</code></p>
<h3>Fixing broken icons in Evolution</h3>
<p>It appears that the necessary dependency isn&#8217;t installed by default for a KDE install. Fix the icons like so:<br />
<code>su -c 'yum install nodoka-theme-gnome'</code></p>
<h3>Installing Adobe Flash Player</h3>
<p>To install the proprietary Adobe Flash player do:<br />
<code>su -<br />
rpm -ihv http://linuxdownload.adobe.com/adobe-release/adobe-release-i386-1.0-1.noarch.rpm<br />
yum install flash-plugin<br />
</code></p>
<p>Note that a freedomware flash player, gnash, is in the works, but it only supports a subset of Flash v7 functionality.</p>
<h3>Other issues</h3>
<p>I&#8217;ve had problems with sound not being available upon booting from time to time. This seems to be due to the coexistence of the webcam&#8217;s internal microphone sound device, and my main soundcard sound device. I also get &#8216;artsd&#8217; crash messages upon logging into KDE from time to time. </p>
<p>I hope to cover my impressions of the various Fedora 8 components in subquent posts, but we&#8217;ll see how we go. </p>
<span class="net_nemein_favourites">0 <a href="http://maemo.org/news/?net_nemein_favourites_execute=fav&net_nemein_favourites_execute_for=230b06e29f4811dcbc193f7205a3709c709c&net_nemein_favourites_url=https://maemo.org/news/favorites//json/fav/midgard_article/230b06e29f4811dcbc193f7205a3709c709c/" class="net_nemein_favourites_create"><img src="http://static.maemo.org:81/net.nemein.favourites/not-favorite.png" style="border: none;" alt="Add to favourites" title="Add to favourites" /></a>7 <a href="http://maemo.org/news/?net_nemein_favourites_execute=bury&net_nemein_favourites_execute_for=230b06e29f4811dcbc193f7205a3709c709c&net_nemein_favourites_url=https://maemo.org/news/favorites//json/bury/midgard_article/230b06e29f4811dcbc193f7205a3709c709c/" class="net_nemein_favourites_create"><img src="http://static.maemo.org:81/net.nemein.favourites/not-buried.png" style="border: none;" alt="Bury" title="Bury" /></a></span>]]></description>
            <author>Tim Wegener &lt;twegener@madabar.com&gt;</author>
            <category>feed:d657281da8f1046af5c5fb58128972cc</category>
            <pubDate>Fri, 30 Nov 2007 12:57:56 +0000</pubDate>
            <guid>http://maemo.org/midcom-permalink-230b06e29f4811dcbc193f7205a3709c709c</guid>
        </item>
    </channel>
</rss>
