<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Eugeni&#039;s blog &#187; programming</title>
	<atom:link href="http://dodonov.net/blog/category/programming/feed/" rel="self" type="application/rss+xml" />
	<link>http://dodonov.net/blog</link>
	<description>My view on technology, open-source, Linux and other cool things.</description>
	<lastBuildDate>Sun, 29 Jan 2012 15:11:34 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
		<item>
		<title>And now, on your favorite Intel Linux Graphics news station&#8230;</title>
		<link>http://dodonov.net/blog/2011/11/08/and-now-on-your-favorite-intel-linux-graphics-news-station/</link>
		<comments>http://dodonov.net/blog/2011/11/08/and-now-on-your-favorite-intel-linux-graphics-news-station/#comments</comments>
		<pubDate>Tue, 08 Nov 2011 22:08:04 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[intel]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mageia]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[mesa]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[x.org]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=1161</guid>
		<description><![CDATA[After some period of silence, this blog returns in bringing you the latest and greatest news from the Intel Linux Graphics world. So if you were sad, depressed and crying in despair without having a chance of reading about what was going on with the Intel Graphics for the past days, rejoice! Those past few <a href='http://dodonov.net/blog/2011/11/08/and-now-on-your-favorite-intel-linux-graphics-news-station/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>After some period of silence, this blog returns in bringing you the latest and greatest news from the Intel Linux Graphics world.</p>

<p>So if you were sad, depressed and crying in despair without having a chance of reading about what was going on with the Intel Graphics for the past days, rejoice! <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>

<p>Those past few days were quite busy on all the projects, and with thousands of emails to keep track of it is hard to select the most relevant news &#8211; all of them are! But I&#8217;ll try to summarize the most interesting stuff that happened for the past few days.</p>

<p>Starting with kernel, as you all already know, we are living in the post-3.1 era now, with the release of <a href="https://plus.google.com/109995262342451767357/posts/jALV6z8SnC7" onclick="urchinTracker('/outgoing/plus.google.com/109995262342451767357/posts/jALV6z8SnC7?referer=');">Linux 3.2-rc1</a>. It brings lots and lots of fixes and improvements all around, and much more are yet to come.</p>

<p>On Intel Graphics side, the following items caught my attention for the past days:</p>

<ul>
<li>Keith Packard sent yet more <strong>eDP</strong>-related patches, allowing eDP displays connected to the PCH to, well, work <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> . The main issue came from the fact that the driver incorrectly was treating a PCH-connected eDP panel like a CPU-connected one, setting the wrong bits in the wrong places.</li>
<li>Daniel Vetter has sent out a series of patches for <strong>simulating GPU hangs</strong>. As you all know, GPU hangs are an (unfortunate) part of a GPU driver life, and there are many factors which could cause them, ranging from incorrect GL instructions to out-of-bounds variables somewhere in the stream of commands and down to hardware failures. Prior to Daniel&#8217;s patches, the only way to see a GPU hang was by having a hung GPU, so most of them were not easy to reproduce and investigate. Now, it is possible to stop the GPU at will, and see the effects. This is particularly interesting at least for me, because I was working on some tools for doing <a href="http://permalink.gmane.org/gmane.comp.freedesktop.xorg.drivers.intel/6408" onclick="urchinTracker('/outgoing/permalink.gmane.org/gmane.comp.freedesktop.xorg.drivers.intel/6408?referer=');">heuristics analysis</a> of the root-causes of GPU hangs. Now, I can do this task with much more ease.</li>
<li>Jesse Barnes sent out a new round of <strong>planes</strong> support, and support for SNB and IVB <strong>video sprites</strong>. The video sprites support different video formats natively and can do scaling as well, and their support was added to the DRM overlay code with this patchset.</li>
<li>Ken and Daniel did a bit of <strong>cleanup</strong> of code specific to some pre-production SNB systems. Now that Sandy Bridge is out there, those bits are not necessary anymore, so they were wiped out.</li>
<li>Daniel has sent a 13-patch series of <strong>pwrite/pread</strong> reworking. This patchset fixes some spurious -EFAULTS issues which could lead to kernel issues, improves the performance of pread/pwrite calls on LLC machines and cleanups unused code, replacing them with faster execution paths.</li>
<li>Also on kernel,  I&#8217;ve found an issue which can cause <strong>division-by-zero</strong> in kernel when accessing power-related registers from userspace, and sent a small patch fixing it. Apparently, the very same issue was already found back in July by <a href="http://lists.freedesktop.org/archives/intel-gfx/2011-July/011380.html" onclick="urchinTracker('/outgoing/lists.freedesktop.org/archives/intel-gfx/2011-July/011380.html?referer=');">Konstantin Belousov</a>. It is a small fix for a potential kernel crashing issue, and let&#8217;s hope it will be picked up in one of the next kernel pull requests.</li>
<li>And Jesse Barnes sent out some documentation and cleanup patches for the <strong>drm</strong> subsystem.</li>
<li>Still on kernel, but outside of our team&#8217;s area, one big news for Linux Graphics will certainly make some people out there happy. Yes, I am speaking about Alan Cox moving of basic <strong>GMA500</strong> driver out of staging. This driver support accelerated console and non-accelerated KMS on Poulsbo, Oaktrail, Cedarview and Medfield hardware. Note that medfield support in this initial patchset is left out on purpose, as it needs considerable rework to be ready to enter main kernel.</li>
</ul>

<p>One particular issue worth highlighting is that a <strong>long-standing issue</strong> on GL-based applications (among which Unigine Tropics and Sanctuary are probably the most notable examples, among many others) was finally fixed, thanks to an amazing work by Eric Anholt, Kenneth Graunke and Keith Packard. This issue can be described as &#8216;small moving ants on top of image edges&#8217; or &#8216;<strong>flickering pixels</strong>&#8216;. So if you have had this issue, make sure to check out the <a href="http://lkml.indiana.edu/hypermail/linux/kernel/1111.0/02876.html" onclick="urchinTracker('/outgoing/lkml.indiana.edu/hypermail/linux/kernel/1111.0/02876.html?referer=');">patches</a>!</p>

<p>Going to Mesa, out of hundreds of emails and commits, it is hard to choose the most interesting ones. Work on <strong>GL 3.0</strong> support proceeds quickly, and new mesa stability release, <strong>7.11.1</strong> is almost out of the door. Our Q&amp;A team did a full testing of this bugfixing release, and haven&#8217;t found much issues. So prepare yourself, as in few weeks we&#8217;ll have <strong>MESA 7.11.1</strong> out there. Stay tuned for Ian&#8217;s announcement in nearby future.</p>

<p>But as for mesa master branch, the following patches called my attention the most:</p>

<ul>
<li>Eric sent a patch series to add support for GL_EXT_texture_integer on i965 driver.</li>
<li>More work towards EXT_transform_feedback was done by Dan McCabe and Paul Berry, and Marek from the community side.</li>
<li>And we had lots of fixes for potential segmentation faults, safety checks, better hardware specification compatibility, piglit-based fixes and other issues from Yuanhan, Eric, Ken, Chad and Ian.</li>
</ul>

<p>On Wayland side of the force, lots of patches went in those days. Among those, there was an interesting proposal for the screen locking protocol by Pekka Paalanen, and some bugfixing patches from Juan Zhao.</p>

<p>Going to the other components, we had a release of <strong>xorg-xserver</strong> 1.11.2 RC2, with several crashes and correctness fixes; and new stable <strong>pixman</strong> 0.24.0 which brings many performance improvements and usage of architecture-specific instructions to improve overall performance over a number of different operations (such as bilinear scaling for example).</p>

<p>And finally, for the <strong>intel-gpu-tools</strong>, I was working on a new <strong>intel_gpu_analyze</strong> application, which I was using to tracing and analyzing CPU and GPU performance data during workloads, and also checking on the corresponding power consumption. This is a very experimental code yet, and it lives at <a href="http://cgit.freedesktop.org/~eugeni/intel-gpu-tools" onclick="urchinTracker('/outgoing/cgit.freedesktop.org/_eugeni/intel-gpu-tools?referer=');">my freedesktop.org git</a> for now. But still, I can already do some nice performance analysis like <a href="http://eugeni.dodonov.net/webgl_firefox_lasso/" onclick="urchinTracker('/outgoing/eugeni.dodonov.net/webgl_firefox_lasso/?referer=');">this one</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/11/08/and-now-on-your-favorite-intel-linux-graphics-news-station/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>So, what&#8217;ve been up to at linux graphics lately?</title>
		<link>http://dodonov.net/blog/2011/10/18/so-whatve-been-up-to-at-linux-graphics-lately/</link>
		<comments>http://dodonov.net/blog/2011/10/18/so-whatve-been-up-to-at-linux-graphics-lately/#comments</comments>
		<pubDate>Tue, 18 Oct 2011 20:12:05 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[intel]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mageia]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[mesa]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[x.org]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=1115</guid>
		<description><![CDATA[So far, it turned out that the semi-periodic write-ups turned up to be much more frequent that I originally thought. Let&#8217;s see if I&#8217;ll be able to keep this pace &#8211; lots of interesting things are happening all around, so I think that it is not worth waiting weeks just to write a summary of <a href='http://dodonov.net/blog/2011/10/18/so-whatve-been-up-to-at-linux-graphics-lately/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>So far, it turned out that the semi-periodic write-ups turned up to be much more frequent that I originally thought. Let&#8217;s see if I&#8217;ll be able to keep this pace &#8211; lots of interesting things are happening all around, so I think that it is not worth waiting weeks just to write a summary of most important points.</p>

<p>Since last update, we had a very productive weekend <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> , and 2 days of work on all the projects. In this time span, on <a href="http://cgit.freedesktop.org/xorg/app/intel-gpu-tools/" onclick="urchinTracker('/outgoing/cgit.freedesktop.org/xorg/app/intel-gpu-tools/?referer=');">intel-gpu-tools</a> front, we had some interesting commits:</p>

<ul>
<li>One from myself, to add <strong>non-interactive logging</strong> of GPU activity, parseable by other scripts and applications</li>
<li>Several from Daniel, improving the <strong>debugging</strong> facilities of the tools</li>
<li>A new <strong>intel_reg_checker</strong> application from Eric Anholt, which attempts to discover possibly incorrect settings which could lead to the crash/hang/issue.</li>
<li>And I&#8217;ve sent some <strong>heuristics</strong> patches for intel_error_decode and intel_decode which attempt to identify the root cause of the problem (e.g., if it came through mesa codepath, or 2D driver, or VA). After discussion on both mail and IRC with Chris and Daniel, we came to the conclusion that this approach should be better approaches from a separate script or app, which would do the analysis of the trace.</li>
</ul>

<p>On <strong>Kernel</strong>, we had some nice news too:</p>

<ul>
<li>QA has carried out the performance and functionality testing for my <strong>edid</strong> patch, and it gave a really nice performance boost in all cases. After sending the final version of the patch, we had some comments from Jean Delvare and Alex Deucher about possible issues this could bring to radeon-based cards, if the fix would be implemented inside DRM. So I am still not sure about what to do here &#8211; I have two versions of the same fix, both are working, but I don&#8217;t know which one will be the final one.</li>
<li>Lots of activity and discussion on <strong>SNA, VA and RC6</strong>-related issues took place from Daniel, Ben, Chris and myself. Some of the reported issues have been isolated (well.. mostly <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> ), and some have some patching attempts. The root cause of the problems is not clear yet. But on the bright side, apparently, we don&#8217;t have any crash or hang-related issues coming via RC6, only some rendering corruptions. So hopefully RC6-by-default will see the light of day again in some point in the future <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</li>
<li>Some (possibly) final patches from Ben Widawsky and David Woodhouse arrived, attempting to fix the <strong>VTd-related</strong> problem on Ironlake chipsets.</li>
</ul>

<p>Meanwhile, Mesa has had lots of activity too:</p>

<ul>
<li>Chad Versace sent out some dozens of patches which added support for <strong>HiZ</strong> infrastructure in core mesa, adding new driver hooks and small changes all around. Note that HiZ is supposed to be supported by i965 family of the chips (e.g., 5th (Ironlake) generation onward).</li>
<li>Lots of <strong>piglit</strong> and conformance patches arrived from Eric, Yuanhan and Chad.</li>
<li><strong>Stencil buffer</strong> support has received some updates from Chad as well.</li>
<li>And an improved <strong>math performance</strong> patch was sent by Ken. It should improve math-related operations by a nice margin on <strong>Ivybridge</strong>, and also allows it to work in a workaround-free way <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</li>
</ul>

<p>On DDX front, as usually, we had an impressive number of patches from Chris for <strong>SNA</strong>. On a related note, past weeks had given us lots and lots of feedback about SNA and how people are using it. This is great &#8211; it means that it works (despite some issues, many of which are already filed as bugs, or being investigated right now)! I&#8217;ve been using SNA by default on all my machines for a couple of months, and it works just fine for me. Only faster <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p>And finally, on Xserver-related work, we had a new <strong>Glamor</strong> pull request from Zhigang Gong, lots of man and documentation-related patches, Xinput and evdev development, and a small patch which drops support for the <strong>bsdi</strong>. I am actually quite curious about this one &#8211; it has been a really, <em>really</em> long time since I&#8217;ve seen a bsdi system out there. Does anyone still has one around? It would be nice to play with it those days&#8230; <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>

<p><strong>EDIT:</strong> Update from Daniel Vetter &#8211; HiZ is available in hardware starting from Ironlake. I updated the post accordingly.</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/10/18/so-whatve-been-up-to-at-linux-graphics-lately/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>So, what&#8217;s been up with Intel Linux Graphics this week?</title>
		<link>http://dodonov.net/blog/2011/10/14/so-whats-been-up-with-intel-linux-graphics-this-week/</link>
		<comments>http://dodonov.net/blog/2011/10/14/so-whats-been-up-with-intel-linux-graphics-this-week/#comments</comments>
		<pubDate>Fri, 14 Oct 2011 17:19:09 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[intel]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mageia]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[mesa]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[x.org]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=1108</guid>
		<description><![CDATA[As a Friday gift for you readers, I have another round of updates about the Intel Linux Graphics development during this week. There was much activity all around those days, so I decided not to wait until next week and do this update earlier. Certainly until next week lots of things will still happen. But <a href='http://dodonov.net/blog/2011/10/14/so-whats-been-up-with-intel-linux-graphics-this-week/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>As a Friday gift for you readers, I have another round of updates about the Intel Linux Graphics development during this week.</p>

<p>There was much activity all around those days, so I decided not to wait until next week and do this update earlier. Certainly until next week lots of things will still happen.</p>

<p>But let&#8217;s get started. And first of all, I&#8217;d like to thank you all for the feedback I had on this blog &#8211; both by emails and comments and IRC and bugzilla &#8211; I was really and truly pleasantly surprised with your comments. Looks like this sort of information I am putting here is interesting to many people out there, so I&#8217;ll try to keep up to the task.</p>

<p>And one important reminder which somehow slipped out from the previous posts in the series &#8211; if you want to report an issue related to the Intel Graphics stack, there is a comprehensive guide on what you need to report <a href="http://intellinuxgraphics.org/how_to_report_bug.html" onclick="urchinTracker('/outgoing/intellinuxgraphics.org/how_to_report_bug.html?referer=');">here</a>. For debugging suspend-resume issues, there is a separate <a href="http://intellinuxgraphics.org/suspend-resume.html" onclick="urchinTracker('/outgoing/intellinuxgraphics.org/suspend-resume.html?referer=');">guide</a> as well. And, of course, if you want to build the latest versions of the drivers (or their snapshots) as well, there is a <a href="http://intellinuxgraphics.org/install.html" onclick="urchinTracker('/outgoing/intellinuxgraphics.org/install.html?referer=');">tutorial</a> to get you started. Those links are hidden deep in the Intel Linux Graphics web page, so they are not easy to find sometimes &#8211; so I hope they will be useful to you.</p>

<p>But let&#8217;s go to the development progress on the components of the stack for this 2nd week of October.</p>

<ul>
<li>I sent out yet another round of my <strong>EDID</strong> fixes. Thanks to the testing by <strong>Mike Lothian</strong> (thanks!!), the i915-specific fixes gave no visible regressions (however, no visible improvements improvements either), but the drm-specific fix managed to do something wrong with the Radeon adapter. So I switched the focus to the i915-specific version for now, as I don&#8217;t have non-intel hardware to do the debugging, and put it on my <a href="http://cgit.freedesktop.org/~eugeni/kernel/commit/?h=edid-i915" onclick="urchinTracker('/outgoing/cgit.freedesktop.org/_eugeni/kernel/commit/?h=edid-i915&amp;referer=');">fd.o repository</a>. Hopefully I&#8217;ll have more testing results next week, or maybe other comments on this patch. At least on all my machines, it managed to improve the monitor detection timing by a considerable margin.</li>
<li>Also on Kernel, <strong>Adam Jackson</strong> from RedHat sent out a nice patch that work around the limitations of active dp->any connectors. Quoting his patch description, &#8221; Many such (including all DP->VGA chips I can find on the market) come equipped with only 2 DP lanes, which clips your dotclock to 144MHz at8bpc.  Of the standard DMT modes, that means you lose 1600&#215;1200@60 and above.  Since these adaptors are marketed as supporting 1920&#215;1200, we might as well make that work, otherwise it&#8217;s the driver that comes out looking bad.&#8221;.</li>
<li>Still on Kernel, <strong>Jesse Barnes</strong> had sent new iterations of his 3-display-pipes patches, which have evolved into more than that by now, improving lots of display handling aspects within the driver. Also within this context, <strong>Paulo Zanoni</strong> has worked around a bug with multiple VGA outputs by using some <strong>intel_reg_dumper/intel_reg_write</strong> magic <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> , and came with a kernel patch for fixing such problems. This patch was further adapted according to <strong>Chris</strong> and <strong>Jesse&#8217;s</strong> comments, and is floating around the intel-gfx mailing lists at the moment.</li>
<li>Also on kernel, <strong>Daniel Vetter</strong> and (by a much smaller margin) myself were been doing lots of investigation for GPU hangs, corruptions, suspend-resume and rendering problems. Some of the problems has possible patches, some of them are still out in the wild. For the currently alive suspend-resume issues, looks like they happen when the Kernel Mode Setting (KMS) is being used, and go away with the <strong>nomodeset</strong> kernel parameter. So if you are affected by any of those, it would be worth trying that parameter in grub or kernel command line to see if it helps.</li>
<li>On development side of kernel, <strong>Jesse Barnes</strong> sent out a modeset verification patch, which could help identifying modeset-related problems; and <strong>Ben</strong> and <strong>Daniel Vetter</strong> did many code cleanups, sent out patches on hangcheck robustification, and overall were working on improving the debugging facilities of the driver.</li>
</ul>

<p>Moving to the <strong>DDX</strong> (a.k.a., 2D display driver, usually known by its friendly nickname of <strong>xf86-video-intel</strong>), there was quite an activity as well:</p>

<ul>
<li><strong>Chris</strong> has sent out lots of SNA-related patches.</li>
<li><strong>Daniel Vetter</strong> has sent some Sandy Bridge-specific fixes, and was also investigating SNA-related bug reports.</li>
<li>And I&#8217;ve managed to find a new GPU hang which only happens when SNA is active on an Ivy Bridge system. Somehow I suspect not many people out there besides myself are affected by it though <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</li>
</ul>

<p>On <strong>Mesa</strong> front, there were some new patches from <strong>Chad</strong> on Stencil Buffer development; lots of patch reviews by <strong>Eric Anholt</strong> and <strong>Ian</strong>, some Ivy Bridge-specific fixes from <strong>Ken</strong>, many code cleanups and refactoring by <strong>Ken</strong> again, and some patches from <strong>Yuanhan Liu</strong> for bug fixing, improved Ivy Bridge functionality, and better GL conformance. Besides Intel-specific development, there were some interesting patches from <strong>VMware</strong> developers (Thomas Hellstrom, José Fonseca and Brian Paul) which landed into master branch as well.</p>

<p>About <strong>Xserver</strong>, lots of emails on most different areas have been floating around, as usual, but not much Intel-specific activity took place. Among the discussions and patches which caught my attention the most were an interesting discussion about patches which allow X server to run without <strong>root</strong> user; a patch which adds support for running a <strong>backtracer</strong> in case of fault; a new round of <strong>Xinput</strong> fixes, a patch for setting a default <strong>DPI</strong> value from <strong>EDID</strong> data by Michal Suchanek, and more <strong>bus cleanups</strong> by Jeremy Huddleston. On a related note, Xserver <strong>1.11.2 RC1</strong> release is approaching fairly quickly.</p>

<p>Moving to <strong>Wayland</strong>, we had lots of <strong>x11</strong>-specific patches from <strong>Kristian</strong>, and some compositor bugfixes from Benjamin Franzke.</p>

<p>And finally, on <strong>LIBVA</strong> there was a one bugfixing patch from <strong>Gwenole</strong> for proper driver name detection with fglrx-powered cards.</p>

<p>Besides those news, we also have had a new <strong>pixman</strong> release, which added some nice optimizations by using <strong>SSE2</strong> instructions on x86 platforms, and <strong>iwMMXt</strong> ones on ARM.</p>

<p>So yeah, quite some changes so far.</p>

<p>So this is the end of this semi-periodic-update about the state and news from the Intel Linux Graphics (and related) world &#8211; see you in the next one.</p>

<p>P.S.: On a slightly related note &#8211; I have received some comments which say that this kind of posts, when they do not directly mention Mandriva or Mageia, should not belong to the respective planets. However, I also received some posts saying that the Graphics-related news affect pretty much all the distributions out there. So I am open for opinions &#8211; what do you suggest, should such post be excluded from the syndication to Planet Mandriva and/or Mageia feeds, or they could fit there as well?</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/10/14/so-whats-been-up-with-intel-linux-graphics-this-week/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>Another update on Intel Linux Graphics</title>
		<link>http://dodonov.net/blog/2011/10/10/another-update-on-intel-linux-graphics/</link>
		<comments>http://dodonov.net/blog/2011/10/10/another-update-on-intel-linux-graphics/#comments</comments>
		<pubDate>Mon, 10 Oct 2011 17:56:38 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[intel]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mageia]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[mesa]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=1102</guid>
		<description><![CDATA[Hi folks, another week, another update . Lots of major things happened for the past week over all the Intel Linux Graphics-related projects. Let me highlight some of them for you. On kernel side, the major feature is, certainly, the enablement of the 3rd display pipe for the Ivy Bridge architecture in the intel-gfx mailing <a href='http://dodonov.net/blog/2011/10/10/another-update-on-intel-linux-graphics/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Hi folks,</p>

<p>another week, another update <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p>Lots of major things happened for the past week over all the Intel Linux Graphics-related projects. Let me highlight some of them for you.</p>

<ul>
<li>On <strong>kernel</strong> side, the major feature is, certainly, the enablement of the <a href="http://dodonov.net/blog/2011/10/05/3-independent-displays-are-getting-really-close/">3rd display pipe for the Ivy Bridge architecture</a> in the intel-gfx mailing list, by Jesse Barnes. Lots of things were already said about Ivy Bridge, which will arrive next year to your favorite reseller, and the Open Source drivers for it will be ready by the time it gets there. The enablement of the 3rd display pipe &#8211; and, therefore, the possibility of having 3 independent displays up and running on Linux &#8211; certainly is a major step forward. And having those patches in the open-source world early, months before the hardware will arrive to the vast majority of the users, is certainly a big plus for everyone (and specially for the open-source community)!</li>
<li>Lots of work for next stable release of <strong>mesa</strong> (<strong>7.11.1</strong>) was done, resulting in cherry-picking hundreds of commits to the stable branch.</li>
<li>MRT rendering support in OpenGL ES 2.0 was added to <strong>Mesa</strong> by Ian Romanick. This change brought the GL_NV_draw_buffers and GL_NV_fbo_color_attachment OpenGL extensions to ES 2.0.</li>
<li>Lots of internal shaders cleanup was also done by Ian Romanick.</li>
<li>Paul Berry has sent yet more patches for gl_Clip_Distance and gl_ClipVertex to <strong>mesa-dev</strong> mailing list. Also, a (possibly final) version of clipping series of patches for Gen6 is floating around mesa-dev mailing list now.</li>
<li>Also on <strong>mesa</strong> side, some work on <strong>GLES 1.1</strong> conformance was done by Kenneth Graunke, together with new patches for <strong>HiZ</strong> support by Chad Versace and some <strong>GLSL 1.30</strong> fixes by Carl Worth. Speaking on GLSL 1.30, it has received lots of commits from Eric Anholt, Kenneth Graunke and Paul Berry as well. The OpenGL 3.0 and GLSL 1.30 support is getting closer and closer now.</li>
<li>On intel-gfx mailing lists, irc and bugzilla, lots of discussion and possible fixes for the <strong>RC6-related</strong> problems I mentioned in the <a href="http://dodonov.net/blog/2011/10/03/a-first-post-about-intel-linux-graphics-and-their-friends/">previous post</a> took place by myself, Daniel Vetter, Chris Wilson and many others. So far, a workaround for <a href="https://bugs.freedesktop.org/show_bug.cgi?id=38567" onclick="urchinTracker('/outgoing/bugs.freedesktop.org/show_bug.cgi?id=38567&amp;referer=');">bug 38567</a> seems to be found, while the <a href="https://bugs.freedesktop.org/show_bug.cgi?id=41266" onclick="urchinTracker('/outgoing/bugs.freedesktop.org/show_bug.cgi?id=41266&amp;referer=');">bug 41226</a> is still playing tricks with us. Those are the only rc6-related bugs we are aware of at the moment, so hopefully they will be solved pretty soon.</li>
<li>Also on kernel side, some patches from Daniel Vetter and Ben Widawsky landed in the intel-gfx mailing list, which enable more verbose per-ring information collection. This would result in a much more accurate problem diagnosis &#8211; as newer GPU hardware has multiple rendering rings, the crash dumps not always provided all the necessary information. Now they should.</li>
<li>Some more timing and display detection-related patches from Keith Packard arrived to the intel-gfx mailing list, which greatly improve the monitor detection timings and provide support for new MacBook Air displays. They should probably get into the Kernel 3.2, but can already be used to testing with the 3.1 (and, with some adaptations 3.0) kernel series.</li>
<li>And finally, I&#8217;ve finally sent my patches for fixing the <a href="http://dodonov.net/blog/2011/10/07/improving-edid-detection-timings/">long display discovery</a> issues to intel-gfx mailing list. According to the tests, they should improve the display detection timing by <strong>30%&#8211;300%</strong>, by giving up earlier on non-working output ports. The effects should be more visible on machines which has lots of such ports &#8211; which is becoming quite common those days with the DisplayPort, HDMI, VGA, S-Video, and all the others connections we have out there.</li>
</ul>

<p>On a related note, Mageia kernel was updated to <strong>3.1-rc9</strong> &#8211; so all the Mageia Cauldron users should experience a nice performance improvements with their Intel graphics cards. Mandriva kernel is at 3.1-rc9 as well, both distributions are on a similar page now.</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/10/10/another-update-on-intel-linux-graphics/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>A first post about Intel Linux Graphics and their friends</title>
		<link>http://dodonov.net/blog/2011/10/03/a-first-post-about-intel-linux-graphics-and-their-friends/</link>
		<comments>http://dodonov.net/blog/2011/10/03/a-first-post-about-intel-linux-graphics-and-their-friends/#comments</comments>
		<pubDate>Mon, 03 Oct 2011 19:50:24 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[intel]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[mesa]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[writing]]></category>
		<category><![CDATA[x.org]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=1067</guid>
		<description><![CDATA[A long time no post.. but then, it was also a long time without a home, internet and free time as well. As you already know, since August I am working at Intel, within the Intel Linux Graphics group. And, as many of you know as well, the news about Intel Linux graphics out there <a href='http://dodonov.net/blog/2011/10/03/a-first-post-about-intel-linux-graphics-and-their-friends/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>A long time no post.. but then, it was also a long time without a home, internet and free time as well.</p>

<p>As you already know, since August I am working at Intel, within the <a href="http://intellinuxgraphics.org/team.html" onclick="urchinTracker('/outgoing/intellinuxgraphics.org/team.html?referer=');">Intel Linux Graphics</a> group. And, as many of you know as well, the news about Intel Linux graphics out there vary a lot, but usually just between the &#8220;it just works&#8221; and &#8220;nothing works&#8221; states, with few intermediate points in between (many of which are usually covered by phoronix news).</p>

<p>So to fill those empty spots, I thought on getting back into the habit of semi periodic write-ups I got while at Mandriva &#8211; just giving out some insights, overviews and overall updates about what is going on with Intel Linux Graphics and related open-source projects from time to time.</p>

<p>But first of all, let me do a quick review about what Intel Linux Graphics is all about. Unlikely other drivers project, the Linux Graphics does not consists from a single and unique driver. By the contrary, it has a lot of ground to cover, working directly on the upstream projects which compose the graphical stack &#8211; ranging from the i915 driver in <strong>kernel</strong> to the entire <strong>MESA</strong> 3D/GL stack, passing through <strong>libdrm</strong> and <strong>vaapi</strong> and all the way up to <strong>x11-server</strong>, <strong>cairo</strong> and <strong>wayland</strong> &#8211; among others. So when you read about an Intel Linux Graphics release, it considers a snapshot version of each of those components.</p>

<p>Of course, each of those projects has a different release goals and timelines, different sets of features to cover, and so on. And, of course, there is a matrix of different generations of graphical hardware, different variations of the models and revisions, and a multitude of OEM platforms to cover.</p>

<p>So, in short, &#8220;it&#8217;s complicated&#8221; <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p>In this sense, the Intel Linux Graphics project so far was doing quarterly releases of the entire stack, as one could see at <a href="http://intellinuxgraphics.org/2011Q3.html" onclick="urchinTracker('/outgoing/intellinuxgraphics.org/2011Q3.html?referer=');">2011Q3</a>, <a href="http://intellinuxgraphics.org/2011Q1.html" onclick="urchinTracker('/outgoing/intellinuxgraphics.org/2011Q1.html?referer=');">2011Q1</a>, <a href="http://intellinuxgraphics.org/2010Q4.html" onclick="urchinTracker('/outgoing/intellinuxgraphics.org/2010Q4.html?referer=');">2010Q4</a> and all the previous ones. However, one of the problems with the quarterly releases, specially over such a big and varying stack, is that they don&#8217;t fit all the situations. So starting with the next release, we&#8217;ll be changing our process to carry out more specific releases, based on pre-defined release criteria for each of them. And the next release will be focused specifically on performance and stability enhancement over our current code.</p>

<p>What do I mean by performance and stability? While most of the people out there do not experience any issues with the drivers (e.g., &#8220;they just work&#8221; category I mentioned out there), we are by no means perfect, and yes, we have bugs which affect different users, operating systems and hardware components (all the way to that &#8220;nothing works&#8221; category of people &#8211; which is thankfully quite small, and of course we hope to promote it to the &#8220;just work&#8221; category of the people ASAP). And we are trying to get better and better for each release, at the same time trying to maintain the same level of openness as one would expect from open-source projects.</p>

<p>If you look at the freedesktop bugzilla, for intel graphics-specific issues, there is a quite complete list out there. Of course, many of those bugs are old, or do not apply to the current state of the code anymore, but some of those are valid &#8211; and they don&#8217;t get the level of attention they need. Specially considering the large number of reports, it is really hard to keep track of all of them, and it is specially easy to get lost among all of them. So if your bug is not getting enough attention &#8211; just go over to it, and ping us. We do not ignore you, but sometimes we lose track of specific issues out there, and we&#8217;ll be happy to be reminded either when an issue is fixed, or whether it is still out there and needs some love <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p>So, as I said previously, I&#8217;ll try to cover up the details of each part of our drivers stack, and try to keep updated the list of the current work and goals we have in mind. So I&#8217;ll start with this first post, and will try to cover a bit about the areas we&#8217;ve been focused the most for the past months &#8211; specially considering the &#8220;performance&#8221; and &#8220;stability&#8221; criteria, and the most interesting features we have out there.</p>

<p><strong>RC6</strong></p>

<p>The first feature which I&#8217;d like to mention, which is probably unknown to most of you out there, is the support for <strong>RC6</strong> technology. This is a feature which allows the GPU (in other words, the graphical adapter) to enter an extremely low power-consuming state while the graphical card is idle. This feature has drastic effects on the power usage of the system &#8211; up to 26% power usage improvements according to <a href="http://www.phoronix.com/scan.php?page=article&amp;item=intel_i915_power&amp;num=1" onclick="urchinTracker('/outgoing/www.phoronix.com/scan.php?page=article_amp_item=intel_i915_power_amp_num=1&amp;referer=');">Phoronix testing</a>. So in theory, having this feature enabled by default would allow a much better battery life for a casual system out there equipped with an Intel graphical card.</p>

<p>However, one drawback to the rc6 is that in some very rare cases, it results in different set of issues. The good part is that very few systems are affected by this bug, and none of the machines either the developers or QA team has managed to reproduce the problems, so chances are very high that it could just work for your by adding a <strong>&#8216;i915.i915_enable_rc6=1&#8242;</strong> parameter to the kernel. The bad part is.. well.. the same as the good part &#8211; we could not reproduce the issues on any of the machines we had. So by a chance, if you enable this feature and hit some unexpected behavior or issue &#8211; please, let us know! We would be really interested in fixing this for all the systems out there. But, with all the magnitude of different x86-based machines, it is virtually impossible to test them all. So we need your help to help of us fix this issue, in case it affects your machine. All the details, such as the vendor, model, installed OS, whether the issue happens with a new install from scratch, bios configuration &#8211; would help.</p>

<p><strong>FBC</strong></p>

<p>Besides <strong>RC6</strong>, one other interesting feature present in the Intel graphical drivers is the support for framebuffer compression, of <strong>fbc</strong>. This feature allows the driver to store the contents of the picture on screen in a compressed format, effectively reducing the amount of energy (and, therefore, power) required to update the screen. On some hardware revisions, however, this feature sometimes causes the GPU not to redraw the display correctly, resulting in only partial screen updates, sometimes visible only after a few suspend-resume sequences. The solution for this problem was to disable this feature by default on such machines, while having it enabled automatically on the chips which do not reproduce the problem. However, even on those chips, you can always enable it manually, by using a <strong>i915.i915_enable_fbc=1</strong> kernel parameter.</p>

<p><strong>Semaphores</strong></p>

<p>And finally, the 3rd major issue being worked on the kernel side is the usage of semaphores in the graphical driver, which allows for a big jump in performance, and also in stability in some cases. However, not everything is perfect in this world <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> , so on some hardware models this feature results in performance choppiness or GPU hangs. It is within of the nature of the bug to appear only on some selected machines, most of which are out of our reach, so chances are, like with the <strong>RC6</strong> and <strong>FBC</strong> features, it should just work out of the box. But if it does not &#8211; please, let us know!</p>

<p>Apart from those 3 big items, lots of work has been carried out on different components of the stack in the past months. I&#8217;ll try to summarize the most interesting points for each component below.</p>

<p><strong>Kernel</strong></p>

<p>The Linux kernel 3.1, which is quickly approaching its release date, brings lots of stability and performance improvements over 3.0 version. The performance results are the most notable ones, as according to the initial testing, you could expect about 25% performance improvements in 3D games and performance benchmarks (and even up to 40% in some of them). I won&#8217;t enter into the details here, as I am certain that Michal Larabel from Phoronix will do his usual round of benchmarks soon enough and provide the numbers <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p>Besides the performance fixes, the timing for detecting the different video outputs has also received lots of attention. Some of the fixes will appear in 3.1 kernel, and some of them are already being prepared to get into 3.2 as soon as its merge window will open.</p>

<p>And of course, there were lots of patches for stability and error recovery within GPU.</p>

<p>Out of the major distributions out there, as far as I know, only Mandriva Cooker has already updated its kernel to the latest 3.1 pre-released version, so its users already have most of those features with them. So if you are a brave soul and are willing to try this as soon as possible, you could either try Mandriva&#8217;s development version; or download and build the 3.1-git kernel yourself. Or just wait a few weeks and it will came to you as soon as your $FAVORITE_DISTRIBUTION would update it in the repository.</p>

<p>So, leaving kernel area, let&#8217;s move to another major component of the stack, which is well-known by its name..</p>

<p><strong>MESA</strong></p>

<p>(No, it is not the Black Mesa Research Facility, so you may put away your crowbar <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> )</p>

<p>Lots of work has been done on Mesa library, and some thousands of emails on the mesa-dev mailing list complement this statement.</p>

<p>Some initial patches for HiZ support from Chad Versace landed on the list, and Phoronix has also performed initial testing on them, obtaining very impressive <a href="http://www.phoronix.com/scan.php?page=article&amp;item=intel_mesa_hiz&amp;num=1" onclick="urchinTracker('/outgoing/www.phoronix.com/scan.php?page=article_amp_item=intel_mesa_hiz_amp_num=1&amp;referer=');">results</a>.</p>

<p>Also, a huge cleanup of old drivers, together with the removal of old DRI1 code and overall refactoring of the code in preparation for the GL 3.0 was done by Ian Romanick. Kenneth Graunke provided lots of patches for both performance and stability improvements for a large number of cases, together with the IvyBridge-specific optimizations. New Vertex Shader backend, lots of TextureImage development by Eric Anholt, work on gl_ClipDistance and the layout of vertex attributes by Paul Berry, lots of GLSL 1.30 development and overall bugfixing complement the picture of what happened with Mesa for the past month or so.</p>

<p>As mesa-dev list, and the git source tree, are quite busy places, there were lots of other development and updates all around which I haven&#8217;t covered here. Mesa 7.11.1 and 7.12 are really going to be amazing releases when they will come out!</p>

<p>But leaving mesa, the next stop in the Intel Linux Graphics stack overview leads us to..</p>

<p><strong>DDX, or xf86-video-intel X driver</strong></p>

<p>The video driver for Intel graphics cards has received lots of attention for the past weeks. Most of the patches came from Chris Wilson, and were related to further improvements in the SNA backend, and a fix for a non-SNA-related X crash. Besides those, we also had some IvyBridge-specific fixes from Kenneth Graunke and cleanup of some warnings from Paulo Zanoni.</p>

<p><strong>Cairo</strong></p>

<p>On Cairo side, a huge work has been made on performance, stability and testing. In some workloads, the performance improved by several orders of magnitude, and in average, one could expect better performance for Cairo on most cases when comparing with the previous release.</p>

<p><strong>Wayland</strong></p>

<p>For Wayland compositor, lots of discussions took place in the wayland-devel mailing list, covering a large collection of topics, randing from the best way to process configuration events and requests, similarities and differences between the wayland protocol and X operations, window management and overall interaction between the clients and the compositor within the Wayland world. From the technical side, there were lots of patches from Tiago Vignatti and Kristian Høgsberg on both core wayland and the wayland-demos repository. One notable change was the change of the GPLv2 headers to MIT for the remaining files where such change wasn&#8217;t applied previously.</p>

<p><strong>Intel-gpu-tools</strong></p>

<p>The package for providing tools for debugging, analyzing, tracing and profiling the Intel graphical cards on Linux/Unix has received some code cleanups from Paulo Zanoni, some news tests from Daniel Vetter, and also a small series of patches from myself which allows it to work in a non-interactive way, generating a tab-separated list of performance values for each capturing points. Those events can be further analyzed with a statistical tool, or plotted with gnuplot, or dumped into openoffice calc/excel applications &#8211; you name it.</p>

<p><strong>Libdrm</strong></p>

<p>Libdrm, which is a glue between the kernel and the userspace applications that use the kernel graphical driver, has received some fixes from Daniel Vetter last week. Besides those, there was a fix to make &#8216;make check&#8217; work correctly, and a support for using xf86drm.h from C++ applications.</p>

<p><strong>Xserver</strong></p>

<p>X.org X server has received lots of updates and merges since the 1.11.0 release in the past weeks. Among the most notable ones, there were some enhancements to the DRI2, XRANDR and DAMAGE extensions, documentation, comments and scripts fixes, besides the changes in the input framework.</p>

<p><strong>VAAPI</strong></p>

<p>And finally, as for VAAPI, not much activities happened in the git repo for the past weeks besides some refinements on the API and the vatrace tool.</p>

<p>So, as this post has already grown past the size I originally expected, I think that I&#8217;ll stop about here this time.</p>

<p>I&#8217;ll try to continue with the semi-regular blogging about the news in the graphics land of Intel world on a weekly basis.</p>

<p>See you!
Eugeni</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/10/03/a-first-post-about-intel-linux-graphics-and-their-friends/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Stability is a strange word.. :)</title>
		<link>http://dodonov.net/blog/2011/08/10/stability-is-a-strange-word/</link>
		<comments>http://dodonov.net/blog/2011/08/10/stability-is-a-strange-word/#comments</comments>
		<pubDate>Wed, 10 Aug 2011 17:33:04 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[x.org]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=1063</guid>
		<description><![CDATA[[eugeni@acergeni-x86_64 14:26:49 ~] $ pacman -Q &#124; grep -- -git intel-dri-git 20110809-1 libdrm-git 20110809-1 libglapi-git 20110809-1 libgl-git 20110809-1 libwayland-git 20110809-1 wayland-demos-git 20110810-1 wayland-mesa-git 20110809-1 xf86-input-evdev-git 20110810-1 xf86-input-synaptics-git 20110810-1 xf86-video-intel-git 20110810-1 xorg-server-common-git 20110810-1 xorg-server-devel-git 20110810-1 xorg-server-git 20110810-1 xorg-server-xdmx-git 20110810-1 xorg-server-xephyr-git 20110810-1 xorg-server-xnest-git 20110810-1 xorg-server-xvfb-git 20110810-1 (Yeah, by the way, I am back to arch+xfce4 now.. )]]></description>
			<content:encoded><![CDATA[<pre><code>[eugeni@acergeni-x86_64 14:26:49 ~] $ pacman -Q | grep -- -git
intel-dri-git 20110809-1
libdrm-git 20110809-1
libglapi-git 20110809-1
libgl-git 20110809-1
libwayland-git 20110809-1
wayland-demos-git 20110810-1
wayland-mesa-git 20110809-1
xf86-input-evdev-git 20110810-1
xf86-input-synaptics-git 20110810-1
xf86-video-intel-git 20110810-1
xorg-server-common-git 20110810-1
xorg-server-devel-git 20110810-1
xorg-server-git 20110810-1
xorg-server-xdmx-git 20110810-1
xorg-server-xephyr-git 20110810-1
xorg-server-xnest-git 20110810-1
xorg-server-xvfb-git 20110810-1
</code></pre>

<p>(Yeah, by the way, I am back to arch+xfce4 now.. <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> )</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/08/10/stability-is-a-strange-word/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Macdriva experience</title>
		<link>http://dodonov.net/blog/2011/06/26/macdriva-experience/</link>
		<comments>http://dodonov.net/blog/2011/06/26/macdriva-experience/#comments</comments>
		<pubDate>Sun, 26 Jun 2011 18:01:45 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[review]]></category>
		<category><![CDATA[tutorial]]></category>
		<category><![CDATA[writing]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=912</guid>
		<description><![CDATA[&#8230;or, &#8220;when you have a hammer, everything looks like a nail&#8221;. To do a more fair comparison between Mac and Linux approaches on same hardware, I took a shot and installed Mandriva 2011 beta3 (x86-64 version) alongside Mac OS X on the same Macbook air. The process is nowhere simple nor straight, but it is <a href='http://dodonov.net/blog/2011/06/26/macdriva-experience/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>&#8230;or, &#8220;when you have a hammer, everything looks like a nail&#8221;.</p>

<div id="attachment_913" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2011/06/mdv.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2011/06/mdv-300x168.jpg" alt="" title="mdv" width="300" height="168" class="size-medium wp-image-913" /></a><p class="wp-caption-text">Mandriva 2011 beta3 running on macbook air</p></div>

<p>To do a more fair comparison between Mac and Linux approaches on same hardware, I took a shot and installed Mandriva 2011 beta3 (x86-64 version) alongside Mac OS X on the same Macbook air. The process is nowhere simple nor straight, but it is certainly possible. So in case someone wants to repeat the feat, here is a <em>quick</em> step-by-step instruction how to do so (alternatively, for the impatient ones, you could skip till the end of this post for a simple one-step solution).</p>

<ul>
<li>Download Mandriva 2011b3 from your favorite mirror. The architecture should not matter, but to get the most from the hardware I&#8217;d recommend 64bits edition (but it is solely up to you to decide).</li>
<li>Run <strong>hdiutil convert -format UDRW -o mdv2011.img Mandriva.2011-beta3.x86_64.iso</strong> to convert the image to mac-compatible format</li>
<li>Now comes the tricky part. In order to make the system boot from this image, it is not enough to create a bootable usb disk or create a local disk partition for the installation. You actually have to create <strong>2</strong> local disk partitions &#8211; one where the Linux will be installed, and another roughly equal to the size of the installable image (1.6GB as of mdv2011 beta3), where you should put the copy of the installation image using dd. In other words, you must do the following:</li>
<li>Open <strong>disk utility</strong> from <strong>Dock->Utilities</strong>.</li>
<li>Create a new partition with roughly <strong>2GB</strong> in size.</li>
<li>Create another partition with the space you want for your Linux install (about <strong>10GB</strong> should be enough).</li>
<li>Format both partitions as MSDOS FAT.</li>
<li>Plug your pendrive which will be used for installation.</li>
<li>Open a terminal, become root and run <strong>diskutil list</strong>, it should show you the partitions you have created and the pendrive. E.g., it should show something like:</li>
</ul>

<p><code></p>

<pre><code>  sh-3.2# diskutil list
  /dev/disk0
     #:                       TYPE NAME                    SIZE       IDENTIFIER
     0:      GUID_partition_scheme                        *121.3 GB   disk0
     1:                        EFI                         209.7 MB   disk0s1
     2:                  Apple_HFS Macintosh HD            89.9 GB    disk0s2
     3:       Microsoft Basic Data                         29.2 GB    disk0s3
     4:       Microsoft Basic Data                         2.0 GB     disk0s4
  /dev/disk1
     #:                       TYPE NAME                    SIZE       IDENTIFIER
     0:     FDisk_partition_scheme                        *8.0 GB     disk1
     1:                       0x17                         1.7 GB     disk1s1
</code></pre>

<p></code></p>

<p>Here, <strong>disk0s3</strong> is the partition where the Linux system will live after the installation, <strong>disk0s4</strong> is the partition for the installer, and <strong>disk1</strong> is the disk currently located inside the pendrive.</p>

<ul>
<li>Now we have to transfer the installation image <strong>both</strong> to the pendrive and local partition. For this, first run <strong>diskutil unmountDisk /dev/disk0s4</strong> and <strong>diskutil unmountDisk /dev/disk1</strong> to unmount the partitions, and then transfer the image to them with <strong>dd if=mdv2011.img of=/dev/disk1</strong> and <strong>dd if=mdv2011.img of=/dev/disk0s4</strong>.</li>
<li>!! <strong>AS ALWAYS, make sure you know what you are doing, because dd command does not likes newcomers and non-careful people</strong> !!. If you are not careful, this is the step you have the most possibility of losing all your data for good. You&#8217;ve been warned.</li>
<li>After it is done, the installation procedure is mostly prepared, but you still need to prepare your mac for multi-booting. Luckily for you, this is easy &#8211; just install <a href="http://refit.sourceforge.net" onclick="urchinTracker('/outgoing/refit.sourceforge.net?referer=');">refit</a> and it should work without any configuration.</li>
<li>Now, with the pendrive still plugged, reboot your machine. On boot prompt, there will be a new nice refit menu, where you should choose <strong>partition tool</strong> and allow it to syncronize the GPT partition table with MBR. This is necessary because grub1 and low-level system utilities used in Mandriva 2011 do not support GPT partition tables.</li>
<li>Now you can try booting from your pendrive. If you receive a <strong>Non-system disk</strong> or <strong>Unable to find isolinux.bin</strong>, make sure that you have followed the steps of having the same image on both pendrive and local partition. What (apparently) happens in this case is that Mac gets confused about the local disks namings (e.g., it confuses the USB partitions with local disk ones), and isolinux gets lost trying to figure what to do and usually gets stuck. There is probably a more clean way to make this work, but as I am lazy sometimes, I just settled with this solution.</li>
<li>If you got to the grub splashscreen, congratulations, you have almost reached half of the procedure <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> . Now press <strong>TAB</strong> to edit kernel parameters, and change the <strong>root=LIVE:LABEL=&#8230;</strong> to <strong>root=LIVE:/dev/sdb</strong>. This way, you are telling kernel that the partition you are booting from is in fact the pendrive, and it won&#8217;t get lost trying to solve the puzzle of GPT+MBR+multiple disks mappings (more on this later). Just make sure you select <strong>Live system</strong> instead of <strong>Installation</strong> to prevent needless reboots and problems.</li>
<li>If everything goes OK, you should be able to boot to KDE with 800&#215;600 resolution. If you reached this point, open the <strong>konsole</strong> terminal, become root, run <strong>draklive-install</strong> and proceed with the installation until the partitioning step. At this point, the Mandriva installer gets confused by the GPT+MBR partition table as well, and gets lost about what to do. What you should do is <strong>remove</strong> the partition you dedicated for Mandriva installation (the big one, not the 2GB one), create a new one with your favorite Linux file system (I suggest ext4) and format it. Just name it as <strong>/</strong> partition and create no swap &#8211; we could always create a swap file later.</li>
<li>Now the installer will tell you that the machine must be rebooted to update partition layout and will quit. Instead of rebooting, however, just run <strong>partprobe</strong> command as root and it will re-sync in-memory partition table with the new disk content, and restart <strong>draklive-install</strong>. Now it should allow you to proceed with the installation, so just sit back and relax while Mandriva gets installed on your system. Or go make a tea or drink a beer, cause it will take a somewhat long time.</li>
<li>When the install finishes, in the bootloader installation step, <strong>make sure to install it to the root of the partition</strong> &#8211; in my case, it was <strong>/dev/sda3</strong>, but your mileage may vary.</li>
<li>The install should finish, but in case grub-install command output in the terminal gave you an error message, you must install grub manually because somehow, surprisingly, it gets confused with the GPT+MBR layout as well. So just run <strong>grub-install /dev/sda3</strong> and it should work. If it does not, try running just <strong>grub</strong> so it would recreate the device mapping, and install the bootloader manually (this is a bit technical and tedious procedure so I&#8217;ll skip it on behalf of clarity &#8211; feel free to ask in comments if you have questions about this point).</li>
<li>Finally, run <strong>fdisk /dev/sda</strong>, unmark the <strong>/dev/sda4</strong> (old installation partition) as active, and mark <strong>/dev/sda3</strong> as active. Basically, <strong>fdisk /dev/sda &#8211; press &#8211; a &#8211; press &#8211; 3 &#8211; press -a &#8211; press &#8211; 4 &#8211; w</strong> should do it (/me feels like describing Mortal Kombat fatalities with this explanation <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> ).</li>
<li>Reboot, and a new <strong>Linux</strong> entry should appear within refit menu. However, when you try to boot it, grub will fail, saying that it is unable to locate kernel and initrd files at correct location. This, once again, is due to mismatch between GPT and MBR partition table, and a quick fix is to change <strong>(hd0,3)</strong> to <strong>(hd0,2)</strong> for both kernel and initrd lines. Once again, I am not describing the right fix, but the quickest one.</li>
<li>When the system boots, everything should work automatically, including wifi and everything else. As Mandriva 2011 comes pre-loaded with firmware for most closed cards and devices, it all should just work out of the box.</li>
<li>Just remember to edit <strong>/boot/grub/menu.lst</strong> file and make the change from <strong>(hd0,3)</strong> to <strong>(hd0,2)</strong> there to have it permanently remembered.</li>
</ul>

<p>So, that&#8217;s it, and if you have got through this quick tutorial to this point and managed to get Mandriva 2011 installed on your Mac machine, you can consider yourself a true geek. Of course, most of this tutorial applies to Macbook Air, because it does not has a <strong>CD/DVD</strong> port &#8211; if it had, most of those steps wouldn&#8217;t be necessary at all. But.. we do not seek easy routes, are we? <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>

<p>And of course, I mentioned in the beginning of this post that there is a way to install Mandriva on OSX in just 1 simple step. This step is very simple &#8211; just ask me to send you a .dd.img copy of my Mandriva partition to you, so you could simple copy it into one of your own partitions, and it will just work. Somehow it feels a more natural way of distributing and packaging anything on Mac platform (I mean, within a .dmg file) &#8211; so I am unsure if it is more a hack than the complete tutorial I described above <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p><strong>P.S.:</strong> Just to update you with some timings on the same hardware. Mac OS X 10.6.8 takes approximately <strong>10</strong> seconds from refit boot menu towards desktop. Stock Mandriva 2011 beta3 takes approximately <strong>12</strong> seconds from grub menu to kdm, and approximately another <em>12</em>* seconds from kdm to full-featured desktop. After some optimizations, I could decrease this time to <strong>7</strong> seconds from grub to kdm, and <strong>6</strong> seconds from kdm to full-featured desktop. With auto-login they are tied in this comparison, which is really amazing!</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/06/26/macdriva-experience/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>X.org, wayland and all that awesome low-level stuff</title>
		<link>http://dodonov.net/blog/2011/06/11/x-org-wayland-and-all-that-awesome-low-level-stuff/</link>
		<comments>http://dodonov.net/blog/2011/06/11/x-org-wayland-and-all-that-awesome-low-level-stuff/#comments</comments>
		<pubDate>Sat, 11 Jun 2011 01:37:35 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[mesa]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[x.org]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=887</guid>
		<description><![CDATA[So, I was looking at the famous Mandriva bug #63085 this days, and looking and all that X.org packages assigned to that nomaintainer guy.. and decided to grab them for myself, and see how really difficult is to update/maintain/ fix X.org stack on Mandriva. I had some previous XFree86/X.org development/hacking knowledge already, but it had <a href='http://dodonov.net/blog/2011/06/11/x-org-wayland-and-all-that-awesome-low-level-stuff/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>So, I was looking at the famous <a href="https://qa.mandriva.com/show_bug.cgi?id=63085" onclick="urchinTracker('/outgoing/qa.mandriva.com/show_bug.cgi?id=63085&amp;referer=');">Mandriva bug  #63085</a> this days, and looking and all that X.org packages assigned to that nomaintainer guy.. and decided to grab them for myself, and see how really difficult is to update/maintain/ fix X.org stack on Mandriva. I had some previous XFree86/X.org development/hacking knowledge already, but it had been some 5 years or so since I last touched that codebase, so&#8230; I took a shot.</p>

<p>Surprisingly, it was really not that hard. X11 protocol, even being insanely over-engineered and complex, is very well-thought (I&#8217;d say &#8216;overthought&#8217; actually). The biggest problem came with the X.org modularization, which make me miss <strong>a lot</strong> the good old xfree86-based way of packaging and running X on Linux. The modularization is certainly easier to maintain and develop individual pieces of X stack, yes; but if you consider that instead of one big XFree86 tarball you have to check on hundreds (or better, dozens <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> ) individual packages, some of which require specific libraries, some of which do not compile anymore with the latest &#8220;stable&#8221; version and require grabbing patches from git or even complete checkouts &#8211; it is a bit close to nightmare from packaging point of view.</p>

<p>But luckily, Paulo Zanoni (previous X.org maintainer on Mandriva) did a truly amazing job keeping those packages well-commented, updated and maintainable. So it took me about 4 hours to update/fix/upgrade them all locally, and also update X.org server to the latest <strong>1.10.2</strong> version, Mesa stack to <strong>7.10.2</strong> and libdrm to <strong>2.4.26</strong>. The final piece was the change in X server parameters (from <strong>-nr</strong> to <strong>-background none</strong>) which break the default kdm configuration, but it was fixed today as well thanks to Neoclust, our unreplaceable KDE maintainer <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p>So, as of today, I am proud to announce that Mandriva 2011 is powered by the latest, shiniest and greatest <strong>X.org server 1.10.2</strong> and <strong>Mesa 7.10.2</strong>, with all the awesomeness which comes with that. I had to write some small patches to fix some Intel Sandy Bridge crashes here and there, but I think that Mandriva today has probably the most up-to-date X.org stack out there.</p>

<p>So, when I finished this, I wondered about another toy I haven&#8217;t touched since 2008, which is the hot topic out there these days. Or, namely, <strong>wayland</strong> <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> . It was a bit harder to get ready because I needed to update or import lots of complex packages, but nothing impossible.</p>

<p>So, as a picture says more than 1000 words (at this point, wordpress was nice enough to remind me that this post is at 400 word count already), here is a picture to illustrate my today&#8217;s progress on it:</p>

<div id="attachment_891" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2011/06/waylandmdv.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2011/06/waylandmdv-300x168.jpg" alt="" title="waylandmdv" width="300" height="168" class="size-medium wp-image-891" /></a><p class="wp-caption-text">Wayland server running with Mandriva 2011 X.org with git-based mesa, drm, cairo and intel driver <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p></div>

<p>For the brave souls out there, here is the full list of packages needed to make it work:</p>

<pre><code>lib64xkbcommon0-0.1-1.20110610-mdv2011.0.x86_64
lib64xkbcommon-devel-0.1-1.20110610-mdv2011.0.x86_64
libxkbcommon-debug-0.1-1.20110610-mdv2011.0.x86_64
lib64pixman1_0-20110610-1-mdv2011.0.x86_64
lib64pixman-devel-20110610-1-mdv2011.0.x86_64
pixman-debug-20110610-1-mdv2011.0.x86_64
lib64cairo2-20110610-4-mdv2011.0.x86_64
lib64cairo-devel-20110610-4-mdv2011.0.x86_64
cairo-debug-20110610-4-mdv2011.0.x86_64
lib64cairo-static-devel-20110610-4-mdv2011.0.x86_64
lib64wayland-server0-0.1-1.20110610-mdv2011.0.x86_64
lib64wayland-client0-0.1-1.20110610-mdv2011.0.x86_64
wayland-0.1-1.20110610-mdv2011.0.x86_64
lib64wayland-server-devel-0.1-1.20110610-mdv2011.0.x86_64
lib64wayland-client-devel-0.1-1.20110610-mdv2011.0.x86_64
wayland-debug-0.1-1.20110610-mdv2011.0.x86_64
lib64mesaglapi_0-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaopenvg1-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64dri-drivers-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesawayland_1-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
mesa-modesetting_drv-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglapi_0-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglesv2_2-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglesv1_1-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaegl1-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaopenvg1-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesagl1-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64dri-drivers-experimental-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesawayland_1-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglesv2_2-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglesv1_1-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaegl1-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesagl1-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglu1-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglw1-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
mesa-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglut3-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglu1-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglw1-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
mesa-debug-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
lib64mesaglut3-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
mesa-common-devel-7.10.2.99-0.git20110610.1-mdv2011.0.x86_64
wayland-demos-0.1-1.20110610-mdv2011.0.x86_64
wayland-demos-debug-0.1-1.20110610-mdv2011.0.x86_64
</code></pre>

<p>Of course, all this awesomeness lives only on my notebook for now, I am not crazy enough to commit it to cooker. But if anyone out there is interested in taking a look, drop me a note; I&#8217;ll be more than happy to share it with you.</p>

<p>To sum it up, it was really nice to relearn the x.org and mesa packaging/development which I have to confess I&#8217;ve been missing during those past years. This was certainly fun <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/06/11/x-org-wayland-and-all-that-awesome-low-level-stuff/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>News from the front(s)</title>
		<link>http://dodonov.net/blog/2011/06/01/news-from-the-fronts/</link>
		<comments>http://dodonov.net/blog/2011/06/01/news-from-the-fronts/#comments</comments>
		<pubDate>Wed, 01 Jun 2011 02:09:23 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=878</guid>
		<description><![CDATA[Well, long time no post, no? But better late than never. Lots of things are happening on all fronts. On Mandriva side, Mandriva 2011 beta3 was just released, as promised, bringing lots of changes and bugfixes. One particularly amazing items I&#8217;d like to highlight is the TimeFrame feature, developed by ROSA Labs. It brings the <a href='http://dodonov.net/blog/2011/06/01/news-from-the-fronts/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Well, long time no post, no? But better late than never.</p>

<p>Lots of things are happening on all fronts.</p>

<p>On Mandriva side, <a href="http://blog.mandriva.com/en/2011/06/01/mandriva-2011-beta3/" onclick="urchinTracker('/outgoing/blog.mandriva.com/en/2011/06/01/mandriva-2011-beta3/?referer=');">Mandriva 2011 beta3 was just released</a>, as promised, bringing lots of changes and bugfixes. One particularly amazing items I&#8217;d like to highlight is the TimeFrame feature, developed by ROSA Labs. It brings the power of nepomuk-powered annotations and tags to your desktop in an amazingly easy yet powerful fashion, allowing you to browse and access your files by date unlike any other software I know. Think about it as about zeitgeist and visualizing-your-stuff-according-to-the-timeline from Mandriva/ROSA. Totally awesome (IMHO) and extremely useful application of nepomuk technologies!</p>

<div id="attachment_879" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2011/06/timeframe.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2011/06/timeframe-300x168.jpg" alt="" title="timeframe" width="300" height="168" class="size-medium wp-image-879" /></a><p class="wp-caption-text">Timeframe example</p></div>

<p>On <a href="http://openclass.dodonov.net" onclick="urchinTracker('/outgoing/openclass.dodonov.net?referer=');">OpenClass</a> side, the software has reached 0.2 version, and the development is by no means slowing down. Lots of new features and improvements are coming along daily. I guess I have never worked so easily on any piece of software, and it is amazing. And now, being present in Mandriva repos, having its own <a href="https://launchpad.net/~eugeni/+archive/openclass" onclick="urchinTracker('/outgoing/launchpad.net/_eugeni/+archive/openclass?referer=');">Ubuntu ppa repositories</a> and <a href="http://openclass.dodonov.net/download/" onclick="urchinTracker('/outgoing/openclass.dodonov.net/download/?referer=');">Windows-compatible installer</a>, it looks better than ever. Thanks for all your comments and feedback, I truly appreciate it a lot!</p>

<div id="attachment_882" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2011/06/openclass_win.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2011/06/openclass_win-300x225.jpg" alt="" title="openclass_win" width="300" height="225" class="size-medium wp-image-882" /></a><p class="wp-caption-text">OpenClass on the-one-OS-whose-name-cannot-be-spoken</p></div>

<p>And finally, on personal side, I&#8217;ve got engaged last week <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p>So, in summary, life is going on fast. And that&#8217;s great!</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/06/01/news-from-the-fronts/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>OpenClass development goes on..</title>
		<link>http://dodonov.net/blog/2011/05/26/openclass-development-goes-on/</link>
		<comments>http://dodonov.net/blog/2011/05/26/openclass-development-goes-on/#comments</comments>
		<pubDate>Thu, 26 May 2011 00:41:47 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=868</guid>
		<description><![CDATA[About a week after initial announcement of my hobby project &#8211; OpenClass, I am pleased to announce that the project instead of fading to limbo managed to mature a lot in this time. And now with all its features and enhancement, I felt that it got ready for version 0.1. For those of you who <a href='http://dodonov.net/blog/2011/05/26/openclass-development-goes-on/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>About a week after initial announcement of my hobby project &#8211; <a href="http://openclass.dodonov.net" onclick="urchinTracker('/outgoing/openclass.dodonov.net?referer=');">OpenClass</a>, I am pleased to announce that the project instead of fading to limbo managed to mature a lot in this time. And now with all its features and enhancement, I felt that it got ready for version 0.1.</p>

<p>For those of you who haven&#8217;t got a chance to look at it yet &#8211; OpenClass is an open-source class control solution which I develop in my <strong>free</strong> time, which helps teacher to control his activities in the classroom. Among such activities, the ones most notable ones are:</p>

<p><strong>(From teacher to student)</strong></p>

<ul>
<li>screen projection (send content of teacher screen to all the students)</li>
<li>full-screen resolution-independent screen projection</li>
<li>student attention request (blocking student activities and asking them to look at teacher)</li>
<li>viewing contents of all students screens at once</li>
<li>direct messaging to students</li>
<li>file sharing and URL sharing to enrich class activities</li>
<li>shutting down student computers from teacher</li>
<li>allow and reject students from a specific class</li>
<li>allow to block students from attempting to connect to a class</li>
<li>support for multi-seat configurations and multiple clients per machine (for example, xdmcp-based environments)</li>
</ul>

<p><strong>(From student to teacher)</strong></p>

<ul>
<li>automatic teacher discovery via broadcast</li>
<li>receiving of teacher screen projection via multicasting protocol, suitable for both wired and wireless environments</li>
<li>&#8220;raise hand&#8221; functionality to call teacher attention</li>
<li>possibility to select teacher to connect to</li>
<li>automatic handling of network saturation and disconnection events</li>
</ul>

<p>And, of course, the best part. This application is open-source, and distributed under the GPLv2 license.</p>

<p>Of course, one could wonder &#8211; why should we need another class control solution, specially if we have <a href="http://italc.sourceforge.net" onclick="urchinTracker('/outgoing/italc.sourceforge.net?referer=');">ITALC</a>?</p>

<p>Well, as most things in Linux and open-source world… <strong>just for fun</strong>!</p>

<p>But speaking seriously, I’ve been working on developing a closed-source multi-platform class control application called Bluelab at mstech from 2005 to 2008, until I left the company. However, most of this time since then, I felt that while there are many powerful, big, premium, advanced and full-featured classroom control solutions, some things were still missing in all of them..</p>

<p>So I decided to write one new solution, which would look like I think it should. Small. Efficient. Fast. Open-sourced. And real.</p>

<p>For this, I took some hours of my free time for some of the past weeks, and wrote it entirely from scratch, based on some lose ideas I had for the past years.</p>

<p>So, if you are interested &#8211; please, feel free to access the <a href="http://openclass.dodonov.net" onclick="urchinTracker('/outgoing/openclass.dodonov.net?referer=');">project page</a>, look at the <a href="http://openclass.dodonov.net/screenshots/" onclick="urchinTracker('/outgoing/openclass.dodonov.net/screenshots/?referer=');">screenshots</a>, grab the <a href="https://github.com/eugeni/openclass" onclick="urchinTracker('/outgoing/github.com/eugeni/openclass?referer=');">code from github</a>, or grab the <a href="https://github.com/eugeni/openclass/downloads" onclick="urchinTracker('/outgoing/github.com/eugeni/openclass/downloads?referer=');">mandriva 2011-ready packages</a> directly.</p>

<p>And &#8211; of course &#8211; if you have ideas, comments, suggestions, critics and contributions, please, say <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2011/05/26/openclass-development-goes-on/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Know thy packagers..</title>
		<link>http://dodonov.net/blog/2010/10/11/know-thy-packagers/</link>
		<comments>http://dodonov.net/blog/2010/10/11/know-thy-packagers/#comments</comments>
		<pubDate>Mon, 11 Oct 2010 22:01:39 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=782</guid>
		<description><![CDATA[On a nice Monday evening, I had the idea of checking out who actually releases the most packages for Mandriva, tooking cooker repository as the base. So I did a simples script which grabbed the latest 50.000 commits to Mandriva packages subversion repository, and did some graphs out of it. Note that this only counts <a href='http://dodonov.net/blog/2010/10/11/know-thy-packagers/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>On a nice Monday evening, I had the idea of checking out who actually releases the most packages for Mandriva, tooking cooker repository as the base. So I did a simples script which grabbed the latest 50.000 commits to Mandriva packages subversion repository, and did some graphs out of it. Note that this only counts the commits into the packages repo &#8211; and this number can very loosely be mapped into the number of package releases. Of course, it is not a definitive metric, because most committers do multiple commits before releasing a package, and some use only the &#8216;mdvsys update&#8217; command, so it is not a quite fair comparison between them. But I thought that it is better to have some metrics than no metrics at all <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  .</p>

<p>So, in April, Funda Wang managed an impressive number of 600+ commits. He was followed by jquelin and goetz, with almost 200 commits each, then <strong>neoclust</strong> and <strong>cfergeau</strong> (I&#8217;ll mark Mandriva current/former employees with bold marks for the sake of clarity) with a bit more than 100 commits, and then by many others.</p>

<div id="attachment_783" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2010/10/04.png"><img src="http://dodonov.net/blog/wp-content/uploads/2010/10/04-300x300.png" alt="" title="April" width="300" height="300" class="size-medium wp-image-783" /></a><p class="wp-caption-text">Committers for April 2010</p></div>

<p>In May, <strong>neoclust</strong> got his revenge and ranked at number 1 with almost 300 commits. Funda came second with approximately 150 commits, and then we had thomas, tpg, <strong>fcrozat</strong> and guillomovitch.</p>

<div id="attachment_784" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2010/10/05.png"><img src="http://dodonov.net/blog/wp-content/uploads/2010/10/05-300x300.png" alt="" title="May" width="300" height="300" class="size-medium wp-image-784" /></a><p class="wp-caption-text">Commits history for May/2010</p></div>

<p>In June, <strong>fcrozat</strong> beat the competition with his almost 100 commits. Thomas, goetz, ahmadsamir, <strong>neoclust</strong>, fwang, <strong>oden</strong> and <strong>me</strong> were the ones to do more than 20 package commits. Note that during this month cooker was frozen, so only the approved and highly-trusted fixes were accepted into it.</p>

<div id="attachment_785" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2010/10/06.png"><img src="http://dodonov.net/blog/wp-content/uploads/2010/10/06-300x300.png" alt="" title="June" width="300" height="300" class="size-medium wp-image-785" /></a><p class="wp-caption-text">Commits for June/2010</p></div>

<p>July was the month of jquelin to be the king of the hill, he did an insane number of 800+ package rebuilds for perl. Funda came second with 500+ updates, then goetz, tpg and kharec.</p>

<div id="attachment_786" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2010/10/07.png"><img src="http://dodonov.net/blog/wp-content/uploads/2010/10/07-300x300.png" alt="" title="July" width="300" height="300" class="size-medium wp-image-786" /></a><p class="wp-caption-text">Commits for July/2010</p></div>

<p>Funda regain the leadership in August, handling over 600 packages. Goetz got the second place with 400+, and jquelin &#8211; still on the perl rampage &#8211; did another 200+ packages. <strong>Neoclust</strong> was forth, with a bit more than 100 packages.</p>

<div id="attachment_787" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2010/10/08.png"><img src="http://dodonov.net/blog/wp-content/uploads/2010/10/08-300x300.png" alt="" title="August" width="300" height="300" class="size-medium wp-image-787" /></a><p class="wp-caption-text">Commits history for August/2010</p></div>

<p>Goetz was the master-packager in September, delivering over 400 commits. Funda Wang got the silver medal with 300+ packages, and peroyvind delivered more than 100 packages as well. Jquelin, tpg, <strong>neoclust</strong> and <strong>oden</strong> were not far behind either.</p>

<div id="attachment_788" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2010/10/09.png"><img src="http://dodonov.net/blog/wp-content/uploads/2010/10/09-300x300.png" alt="" title="September" width="300" height="300" class="size-medium wp-image-788" /></a><p class="wp-caption-text">September/2010 commits</p></div>

<p>And finally, now, in the first few days of October, Funda already managed to leave all the competition way behind, already being responsible for almost 200 commits. He is being followed by tv with about 60 packages, the thomas and goetz who almost got to 50 packages each, and peroyvind and <strong>oden</strong>, with about 40 and 30 packages each one.</p>

<div id="attachment_789" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2010/10/10.png"><img src="http://dodonov.net/blog/wp-content/uploads/2010/10/10-300x300.png" alt="" title="October" width="300" height="300" class="size-medium wp-image-789" /></a><p class="wp-caption-text">October/2010 commits</p></div>

<p>So, considering the period from March 30rd to October 11th, the top-10 commiters in Mandriva Linux community are:</p>

<ul>
<li>fwang: <strong>2492</strong></li>
<li>goetz: <strong>1511</strong></li>
<li>jquelin: <strong>1375</strong></li>
<li><strong>neoclust: 739</strong></li>
<li>tpg: <strong>416</strong></li>
<li>guillomovitch: <strong>414</strong></li>
<li>thomas: <strong>374</strong></li>
<li>peroyvind: <strong>363</strong></li>
<li>ahmadsamir: <strong>339</strong></li>
<li><strong>oden: 320</strong></li>
</ul>

<p>In this list, Oden is working at Mandriva, and Neoclust was working on kde packages until the last month. But besides them, I guess it can be safely assumed that Mandriva community contribution to the distribution is far from inexistent <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  .</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2010/10/11/know-thy-packagers/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Gnome hacking</title>
		<link>http://dodonov.net/blog/2010/05/06/gnome-hacking/</link>
		<comments>http://dodonov.net/blog/2010/05/06/gnome-hacking/#comments</comments>
		<pubDate>Thu, 06 May 2010 21:10:45 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=749</guid>
		<description><![CDATA[Every time I try to switch to a different desktop environment/window manager, there is just one simple feature which always make me go back to xfce &#8211; the possibility to quickly switch back to previous virtual desktop. A simple but extremely addictive feature, which only xfwm4 was offering&#8230; &#8230;until yesterday! I became tired on metacity <a href='http://dodonov.net/blog/2010/05/06/gnome-hacking/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Every time I try to switch to a different desktop environment/window manager, there is just one simple feature which always make me go back to <strong>xfce</strong> &#8211; the possibility to quickly switch back to previous virtual desktop. A simple but extremely addictive feature, which only xfwm4 was offering&#8230;</p>

<p>&#8230;until yesterday! I became tired on metacity not offering this feature, so I just went ahead and implemented it overnight (learning a lot about gnome development during the process).</p>

<p>So, if anyone out there was missing this feature &#8211; feel free to grab this patch and apply it to the metacity source. Basically, it will add one new gconf entry (<strong>switch_to_previous_workspace</strong>), and will make metacity remember the last workspace. So you can press <strong>ctrl-f2</strong> to switch to from workspace 1 workspace 2, and when you press <strong>ctrl-f2</strong> again metacity will recognize that you want switch back, to whatever workspace you were before, and will do it.</p>

<p>Once again, this is the beauty of the open source. If there is something you need, but nobody implemented it, you always have the possibility of just doing it yourself. At least, sometimes <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<pre><code>diff -p -up metacity-2.30.1/src/core/prefs.c.switch metacity-2.30.1/src/core/prefs.c
--- metacity-2.30.1/src/core/prefs.c.switch 2010-03-30 11:35:40.000000000 -0300
+++ metacity-2.30.1/src/core/prefs.c    2010-05-06 17:47:14.000000000 -0300
@@ -97,6 +97,7 @@ static char *cursor_theme = NULL;
 static int   cursor_size = 24;
 static gboolean compositing_manager = FALSE;
 static gboolean resize_with_right_button = FALSE;
+static gboolean switch_to_previous_workspace = TRUE;
 static gboolean force_fullscreen = TRUE;

 static MetaVisualBellType visual_bell_type = META_VISUAL_BELL_FULLSCREEN_FLASH;
@@ -412,6 +413,11 @@ static MetaBoolPreference preferences_bo
       &amp;resize_with_right_button,
       FALSE,
     },
+    { "/apps/metacity/general/switch_to_previous_workspace",
+      META_PREF_SWITCH_TO_PREVIOUS_WORKSPACE,
+      &amp;switch_to_previous_workspace,
+      FALSE,
+    },
     { NULL, 0, NULL, FALSE },
   };

@@ -1757,6 +1763,9 @@ meta_preference_to_string (MetaPreferenc

     case META_PREF_FORCE_FULLSCREEN:
       return "FORCE_FULLSCREEN";
+
+    case META_PREF_SWITCH_TO_PREVIOUS_WORKSPACE:
+      return "SWITCH_TO_PREVIOUS_WORKSPACE";
     }

   return "(unknown)";
@@ -2719,6 +2728,12 @@ meta_prefs_get_mouse_button_menu (void)
   return resize_with_right_button ? 2: 3;
 }

+guint
+meta_prefs_switch_to_previous_workspace (void)
+{
+  return switch_to_previous_workspace;
+}
+
 gboolean
 meta_prefs_get_force_fullscreen (void)
 {
diff -p -up metacity-2.30.1/src/core/screen-private.h.switch metacity-2.30.1/src/core/screen-private.h
--- metacity-2.30.1/src/core/screen-private.h.switch    2010-01-14 22:31:32.000000000 -0200
+++ metacity-2.30.1/src/core/screen-private.h   2010-05-06 17:47:14.000000000 -0300
@@ -80,7 +80,7 @@ struct _MetaScreen
   MetaUI *ui;
   MetaTabPopup *tab_popup;

-  MetaWorkspace *active_workspace;
+  MetaWorkspace *active_workspace, *last_workspace;

   /* This window holds the focus when we don't want to focus
    * any actual clients
diff -p -up metacity-2.30.1/src/core/workspace.c.switch metacity-2.30.1/src/core/workspace.c
--- metacity-2.30.1/src/core/workspace.c.switch 2010-01-14 22:31:32.000000000 -0200
+++ metacity-2.30.1/src/core/workspace.c    2010-05-06 18:00:39.000000000 -0300
@@ -377,7 +377,31 @@ meta_workspace_activate_with_focus (Meta
                 meta_workspace_index (workspace));

   if (workspace-&gt;screen-&gt;active_workspace == workspace)
-    return;
+  {
+      meta_verbose("Switching to same workspace detected, going back to previous one!!\n");
+      if (meta_prefs_switch_to_previous_workspace()) {
+          if (workspace-&gt;screen-&gt;last_workspace) {
+              meta_verbose("Going to desktop %d\n", meta_workspace_index(workspace));
+              meta_workspace_activate_with_focus(workspace-&gt;screen-&gt;last_workspace,
+                      NULL, timestamp);
+              return;
+          } else {
+              meta_verbose("No old workspace..\n");
+              return;
+          }
+      } else {
+          meta_verbose("Last workspace switching disabled..\n");
+          return;
+      }
+  }
+  else
+  {
+      if (workspace-&gt;screen-&gt;active_workspace)
+          meta_verbose("Updating last workspace.. current: %d, new: %d\n",
+                  meta_workspace_index(workspace-&gt;screen-&gt;active_workspace),
+                  meta_workspace_index(workspace));
+      workspace-&gt;screen-&gt;last_workspace = workspace-&gt;screen-&gt;active_workspace;
+  }

   if (workspace-&gt;screen-&gt;active_workspace)
     workspace_switch_sound(workspace-&gt;screen-&gt;active_workspace, workspace);
diff -p -up metacity-2.30.1/src/include/prefs.h.switch metacity-2.30.1/src/include/prefs.h
--- metacity-2.30.1/src/include/prefs.h.switch  2010-01-14 22:31:32.000000000 -0200
+++ metacity-2.30.1/src/include/prefs.h 2010-05-06 17:47:14.000000000 -0300
@@ -60,7 +60,8 @@ typedef enum
   META_PREF_CURSOR_SIZE,
   META_PREF_COMPOSITING_MANAGER,
   META_PREF_RESIZE_WITH_RIGHT_BUTTON,
-  META_PREF_FORCE_FULLSCREEN
+  META_PREF_FORCE_FULLSCREEN,
+  META_PREF_SWITCH_TO_PREVIOUS_WORKSPACE
 } MetaPreference;

 typedef void (* MetaPrefsChangedFunc) (MetaPreference pref,
diff -p -up metacity-2.30.1/src/metacity.schemas.in.in.switch metacity-2.30.1/src/metacity.schemas.in.in
--- metacity-2.30.1/src/metacity.schemas.in.in.switch   2010-05-06 17:47:14.000000000 -0300
+++ metacity-2.30.1/src/metacity.schemas.in.in  2010-05-06 18:01:16.000000000 -0300
@@ -4,6 +4,24 @@
     &lt;!-- General preferences --&gt;        

     &lt;schema&gt;
+      &lt;key&gt;/schemas/apps/metacity/general/switch_to_previous_workspace&lt;/key&gt;
+      &lt;applyto&gt;/apps/metacity/general/switch_to_previous_workspace&lt;/applyto&gt;
+      &lt;owner&gt;metacity&lt;/owner&gt;
+      &lt;type&gt;bool&lt;/type&gt;
+      &lt;default&gt;false&lt;/default&gt;
+      &lt;locale name="C"&gt;
+         &lt;short&gt;Remember and recall previous workspace when switching via keyboard shortcuts&lt;/short&gt;
+         &lt;long&gt;
+           Set this to true to allow to switch to previous workspace when
+           using the current workspace keybinding. For example, if you switched
+           from workspace 2 to workspace 1 by pressing keyboard shortcut for
+           workspace 1, pressing the same shortcut again while on workspace 1
+           will switch to workspace 2.
+         &lt;/long&gt;
+      &lt;/locale&gt;
+    &lt;/schema&gt;
+
+    &lt;schema&gt;
       &lt;key&gt;/schemas/apps/metacity/general/mouse_button_modifier&lt;/key&gt;
       &lt;applyto&gt;/apps/metacity/general/mouse_button_modifier&lt;/applyto&gt;
       &lt;owner&gt;metacity&lt;/owner&gt;
diff -p -up metacity-2.30.1/src/metacity.schemas.in.switch metacity-2.30.1/src/metacity.schemas.in
--- metacity-2.30.1/src/metacity.schemas.in.switch  2010-04-06 07:10:38.000000000 -0300
+++ metacity-2.30.1/src/metacity.schemas.in 2010-05-06 18:01:06.000000000 -0300
@@ -4,6 +4,24 @@
     &lt;!-- General preferences --&gt;        

     &lt;schema&gt;
+      &lt;key&gt;/schemas/apps/metacity/general/switch_to_previous_workspace&lt;/key&gt;
+      &lt;applyto&gt;/apps/metacity/general/switch_to_previous_workspace&lt;/applyto&gt;
+      &lt;owner&gt;metacity&lt;/owner&gt;
+      &lt;type&gt;bool&lt;/type&gt;
+      &lt;default&gt;false&lt;/default&gt;
+      &lt;locale name="C"&gt;
+         &lt;short&gt;Remember and recall previous workspace when switching via keyboard shortcuts&lt;/short&gt;
+         &lt;long&gt;
+           Set this to true to allow to switch to previous workspace when
+           using the current workspace keybinding. For example, if you switched
+           from workspace 2 to workspace 1 by pressing keyboard shortcut for
+           workspace 1, pressing the same shortcut again while on workspace 1
+           will switch to workspace 2.
+         &lt;/long&gt;
+      &lt;/locale&gt;
+    &lt;/schema&gt;
+
+    &lt;schema&gt;
       &lt;key&gt;/schemas/apps/metacity/general/mouse_button_modifier&lt;/key&gt;
       &lt;applyto&gt;/apps/metacity/general/mouse_button_modifier&lt;/applyto&gt;
       &lt;owner&gt;metacity&lt;/owner&gt;
@@ -247,7 +265,7 @@
       &lt;applyto&gt;/apps/metacity/general/theme&lt;/applyto&gt;
       &lt;owner&gt;metacity&lt;/owner&gt;
       &lt;type&gt;string&lt;/type&gt;
-      &lt;default&gt;Clearlooks&lt;/default&gt;
+      &lt;default&gt;Ia Ora Steel&lt;/default&gt;
       &lt;locale name="C"&gt;
          &lt;short&gt;Current theme&lt;/short&gt;
          &lt;long&gt;
</code></pre>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2010/05/06/gnome-hacking/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>net_monitor lives again</title>
		<link>http://dodonov.net/blog/2009/09/25/net_monitor-lives-again/</link>
		<comments>http://dodonov.net/blog/2009/09/25/net_monitor-lives-again/#comments</comments>
		<pubDate>Fri, 25 Sep 2009 12:52:55 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[english]]></category>
		<category><![CDATA[Linux-Planet]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=581</guid>
		<description><![CDATA[Working on Mandriva network tools, I looked on one of the most essential ones the network monitor (net_monitor). It was introduced a couple of releases before, and was mostly doing its job. However, it has a number of flaws and lack of features that motivated us to look closer at it. The net_monitor currently used <a href='http://dodonov.net/blog/2009/09/25/net_monitor-lives-again/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Working on Mandriva network tools, I looked on one of the most essential ones the network monitor (<strong>net_monitor</strong>). It was introduced a couple of releases before, and was mostly doing its job. However, it has a number of flaws and lack of features that motivated us to look closer at it.</p>

<div id="attachment_588" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2009/09/old.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2009/09/old-300x194.jpg" alt="Our old friend net_monitor, present in your favorite Mandriva distro!" title="old net_monitor" width="300" height="194" class="size-medium wp-image-588" /></a><p class="wp-caption-text">Our old friend net_monitor, present in your favorite Mandriva distro!</p></div>

<p>The <strong>net_monitor</strong> currently used in all Mandriva versions is written in <strong>perl</strong>, is using internal drakx-net api (and is, therefore, only usable on Mandriva), and also have some issues such as memory leaks and non-usual interface. After a few thoughts and discussions we came to conclusion that it would be more adequate to project and rewrite it from scratch, turning it more modular, expansible and focused on common use cases.</p>

<p>Initially, I thought on using perl to write it, so it would still be part of <strong>drakx-net</strong> suite. However, after thinking on the code and the way it should work I felt that my brain was going to melt down <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  (perl is a nice language, but it is certainly not that compatible with <strong>me</strong>). So I ended up with python, which is my language of choice (together with <strong>C</strong>). Also, I&#8217;ve received many comments saying that the <strong>net_monitor</strong> is no more relevant, as every desktop environment provides its own network monitoring tool, and it should be dropped from <strong>drakx-net</strong>. By combining those issues, we came to decision that it would be more proper to separate <strong>net_monitor</strong> into a different package &#8211; this way, it won&#8217;t depend on any <strong>drakx-net</strong> internal functionalities, and user could uninstall it if required and use his own network monitoring tool if he wants to. And, at the same time, users would still have a cute little network monitoring application on their machines.</p>

<p>So, as a picture says more than a thousand words, I guess I&#8217;ll just add some pictures here than additional KBs of text <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  (<b>EDIT:</b> please note that the look and features of net_monitor have changed significantly in Mandriva since this post):</p>

<div id="attachment_582" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor1.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor1-300x214.jpg" alt="net_monitor monitoring a wireless connection" title="net_monitor1" width="300" height="214" class="size-medium wp-image-582" /></a><p class="wp-caption-text">net_monitor monitoring a wireless connection</p></div>

<div id="attachment_583" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor2.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor2-300x214.jpg" alt="net_monitor monitoring a connection for which network accounting was not enabled" title="net_monitor2" width="300" height="214" class="size-medium wp-image-583" /></a><p class="wp-caption-text">net_monitor monitoring a connection for which network accounting was not enabled</p></div>

<div id="attachment_584" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor3.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor3-300x224.jpg" alt="net_monitor displaying some statistics about your network usage (provided by vnstat)" title="net_monitor3" width="300" height="224" class="size-medium wp-image-584" /></a><p class="wp-caption-text">net_monitor displaying some statistics about your network usage (provided by vnstat)</p></div>

<div id="attachment_585" class="wp-caption aligncenter" style="width: 249px"><a href="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor4.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor4-239x300.jpg" alt="looking at daily traffic statistics on my notebook for the past month" title="net_monitor4" width="239" height="300" class="size-medium wp-image-585" /></a><p class="wp-caption-text">looking at daily traffic statistics on my notebook for the past month</p></div>

<div id="attachment_586" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor5.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor5-300x228.jpg" alt="...and hourly statistics..." title="net_monitor5" width="300" height="228" class="size-medium wp-image-586" /></a><p class="wp-caption-text">...and hourly statistics...</p></div>

<div id="attachment_587" class="wp-caption aligncenter" style="width: 310px"><a href="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor6.jpg"><img src="http://dodonov.net/blog/wp-content/uploads/2009/09/net_monitor6-300x228.jpg" alt="...and finding our when I killed my bandwidth.." title="net_monitor6" width="300" height="228" class="size-medium wp-image-587" /></a><p class="wp-caption-text">...and finding our when I killed my bandwidth..</p></div>

<p>Surely, this is just an early and preliminary version, with many missing features and such. If you want to give it a try, just install <strong>net_monitor</strong> package, and it will create <strong>/usr/bin/net_monitor</strong> executable for you. It won&#8217;t conflict with existent <strong>net_monitor</strong> from <strong>drakx-net</strong> which is installed in /usr/sbin, so both of them may coexist on your system. If you look at <strong>/usr/share/doc/net_monitor/TODO</strong>, you&#8217;ll see some of the ideas that I intend to add to it, but the idea is to keep it simple and not transform it into an <strong>emacs</strong> of network monitoring <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  . And, of course, feel free to add your comments and suggestions (and bug reports) here!</p>

<p>P.S.: Just to prevent comments like &#8216;you should focus on fixing bugs instead of wasting time writing new things&#8217;. <strong>Net_monitor</strong> is present in Mandriva for years now, and if you look at <a href="https://qa.mandriva.com/buglist.cgi?quicksearch=net_monitor" onclick="urchinTracker('/outgoing/qa.mandriva.com/buglist.cgi?quicksearch=net_monitor&amp;referer=');">bugzilla list</a> it has a number of bugs and issues. So I am not creating a new app &#8211; I am bringing back from the land of the dead an old one <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  .</p>

<p>P.P.S.: Answering in advance to another question &#8211; yes, it would work on any Linux distro which has python and pygtk. You&#8217;ll just have to add some tricks into your network startup scripts to enable vnstat integration, but it will work just fine even without that.</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2009/09/25/net_monitor-lives-again/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>msec updates</title>
		<link>http://dodonov.net/blog/2009/06/26/msec-updates/</link>
		<comments>http://dodonov.net/blog/2009/06/26/msec-updates/#comments</comments>
		<pubDate>Fri, 26 Jun 2009 20:02:56 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=450</guid>
		<description><![CDATA[Time has come for the first msec release since Mandriva 2009.1! This time we have several improvements, such as: support for audit plugins more msec auditing checks improved auditing logging and, of course, bugfixes. So let me introduce some details about each one of them. Support for audit plugins You may remember that msec shipped <a href='http://dodonov.net/blog/2009/06/26/msec-updates/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Time has come for the first msec release since Mandriva 2009.1!</p>

<p>This time we have several improvements, such as:</p>

<ul>
<li>support for audit plugins</li>
<li>more msec auditing checks</li>
<li>improved auditing logging</li>
<li>and, of course, bugfixes.</li>
</ul>

<p>So let me introduce some details about each one of them.</p>

<h2>Support for audit plugins</h2>

<p>You may remember that msec shipped with Mandriva 2009.1 introduced support for plugins infrastructure (take a look at your <strong>/usr/share/msec/plugins/</strong> directory to see some examples). This new msec, which will be shipped with Mandriva 2010, also introduces auditing plugins.</p>

<p>Well, you might be asking <strong>what the ..? what is the difference between those plugins?</strong>, so let me clarify it a bit.</p>

<p>Msec has two main functionalities:</p>

<ul>
<li>Security configuration</li>
<li>Security auditing</li>
</ul>

<p>The security <strong>configuration</strong> is what you configure using msecgui or using security levels &#8211; basically, you say what settings should be used on your machine for ssh, user logins, and all kind of system configuration. The security <strong>auditing</strong> are those background checks that run daily on your machine, to determine what has changed since the last run and let you know about that.</p>

<p>In old msec, this security <strong>auditing</strong> was performed by <strong>security.sh</strong>, <strong>security_check.sh</strong> and <strong>diff_check.sh</strong>, so we had just three large and complex files with a lot of duplicated code. With new msec version, everything was split to reduce code duplication, improve readability and simplify plugins creation.</p>

<p>Let me show you a sample plugin which checks for changes in system users:</p>

<pre><code>    #!/bin/bash
    # msec: check for changes in local users

    # check if we are run from main script
    if [ -z "$MSEC_TMP" -o -z "$INFOS" -o -z "$SECURITY" -o -z "$DIFF" ]; then
            # variables are set in security.sh and propagated to the subscripts
            echo "Error: this check should be run by the main msec security check!"
            echo "       do not run it directly unless you know what you are doing."
            return 1
    fi

    # files to log the list of today's and yesterday's, and difference between them
    USERS_LIST_TODAY="/var/log/security/users_list.today"
    USERS_LIST_YESTERDAY="/var/log/security/users_list.yesterday"
    USERS_LIST_DIFF="/var/log/security/users_list.diff"

    # update yesterday's list
    if [[ -f ${USERS_LIST_TODAY} ]]; then
        mv ${USERS_LIST_TODAY} ${USERS_LIST_YESTERDAY};
    fi

    # check for changes in users
    if [[ ${CHECK_USERS} == yes ]]; then
        getent passwd | cut -f 1 -d : | sort &gt; ${USERS_LIST_TODAY}
        Diffcheck ${USERS_LIST_TODAY} ${USERS_LIST_YESTERDAY} ${USERS_LIST_DIFF} "local users"
    fi
</code></pre>

<p>that&#8217;s it. You just drop this file into <strong>/usr/share/msec/scripts/01_check_for_users.sh</strong> and this check will be executed every time msec security checks are run. The security log will be updated, the diff check mail will be created and mailed (along with all other checks), and it will be working automatically from now on.</p>

<h2>More msec auditing checks</h2>

<p>A few additional msec auditing checks were added:</p>

<ul>
<li><strong>CHECK_FIREWALL</strong> &#8212; checks for changes in iptables configuration</li>
<li><strong>CHECK_USERS</strong> &#8212; checks for changes in local users (most of its code was shown above actually)</li>
<li><strong>CHECK_GROUPS</strong> &#8212; checks for changes in local groups</li>
<li><strong>FIX_OWNER</strong> &#8212; if unowned files are found on the system, this check gives the opportunity to change their ownership to nobody/nogroup, instead of blindly doing it automatically</li>
<li><strong>CHECK_RPM_PACKAGES</strong> &#8212; checks for changes in installed RPM packages</li>
<li><strong>CHECK_RPM_INTEGRITY</strong> &#8212; checks all the installed packages for changed files. Both those checks were run before under the CHECK_RPM check, but, as they are quite expensive, these two new checks were introduced instead</li>
</ul>

<p>If you are using cooker or 2010 alpha, these options will not be added automatically to your <strong>/etc/security/msec/security.conf</strong> configuration file. The best way to experiment with them is by using <strong>msecgui</strong>, or running <strong>msec -f standard</strong> or <strong>msec -f secure</strong> to install default configuration for <strong>standard</strong> and <strong>secure</strong> levels.</p>

<p>Besides those items, I was thinking on an option to check for changes in <strong>PAM</strong> authentication, check for failed login attempts and support for rkhunter. And, as always, if you have any idea on some other functionality that should be interesting to have in msec, feel free to comment!</p>

<h2>Improved auditing logging</h2>

<p>The logging format of <strong>/var/log/security.log</strong> was changed to be compatible with syslog-based logging. This should make it easier for system applications to parse it, and for administrator to examine its contents. Now it is way easier to find information by date, kind of message and check type.</p>

<h2>Other ideas</h2>

<p>Among other ideas for msec I thought on the following:</p>

<ul>
<li>msec supports an arbitrary number of custom security levels, but msecgui only supports two basic ones (<strong>standard</strong> and <strong>secure</strong>). It could be nice to have a combobox to select a custom profile..</li>
<li>gui for <strong>TOMOYO</strong> security framework, since the <strong>AppArmor</strong> project looks quite stone-cold dead. This is already a work in progress, so probably I&#8217;ll post some update on this later.</li>
<li>Support for administrator-supplied rules for security and diff checks. For example, to exclude everything matching &#8216;/var/tmp&#8217; from any kind of checks and reports, or excluding network ports from 3000 to 5000 from open port checks.</li>
</ul>

<p>Besides that, there is a number of bugfixes (which are going to be backported to 2009.1 shortly).</p>

<p>So msec is definitely is alive and getting better and better. Stay tuned for more news! <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2009/06/26/msec-updates/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>The power of git gc</title>
		<link>http://dodonov.net/blog/2009/05/06/the-power-of-git-gc/</link>
		<comments>http://dodonov.net/blog/2009/05/06/the-power-of-git-gc/#comments</comments>
		<pubDate>Wed, 06 May 2009 18:03:38 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[mandriva]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=401</guid>
		<description><![CDATA[I wondered why my .git directory of drakx-net was using about 70MB of disk space (I am accessing the SVN repository using git svn). Of course, I have read that periodic git repository clean could drastically save space and speed, but &#8211; what the heck &#8211; it is just a bunch of text files. So <a href='http://dodonov.net/blog/2009/05/06/the-power-of-git-gc/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>I wondered why my .git directory of drakx-net was using about <strong>70MB</strong> of disk space (I am accessing the SVN repository using git svn). Of course, I have read that periodic git repository clean could drastically save space and speed, but &#8211; what the heck &#8211; it is just a bunch of text files. So I never bothered with it.</p>

<p>However, after running <strong>git gc</strong> on top of drakx-net directory, the .git directory size went from <strong>70MB</strong> down to <strong>4MB</strong>. A <strong>17.5x</strong> improvement! Unbelievable!</p>

<p>So I did the same to msec repository, with quite similar results &#8212; from <strong>21MB</strong> down to <strong>3MB</strong>!</p>

<p>So a mental note to myself &#8211; run <strong>git gc</strong> always. It rocks.</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2009/05/06/the-power-of-git-gc/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>quick-n-dirty fr-en translator</title>
		<link>http://dodonov.net/blog/2009/01/22/quick-n-dirty-fr-en-translator-2/</link>
		<comments>http://dodonov.net/blog/2009/01/22/quick-n-dirty-fr-en-translator-2/#comments</comments>
		<pubDate>Thu, 22 Jan 2009 15:58:50 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=247</guid>
		<description><![CDATA[Trabalhando com mandriva, vira e mexe encontro gente falando em francês. Como já faz quase 14 que não falo essa língua , decidi apelar pro meu querido python e google translator. Nada como uns 10 minutos de programação voltada a gambiarras . #!/usr/bin/python # # quick and dirty french2english translator # import urllib import urllib2 <a href='http://dodonov.net/blog/2009/01/22/quick-n-dirty-fr-en-translator-2/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Trabalhando com mandriva, vira e mexe encontro gente falando em francês. Como já faz quase 14 que não falo essa língua <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> , decidi apelar pro meu querido python e google translator.</p>

<p>Nada como uns 10 minutos de programação voltada a gambiarras <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  .</p>

<pre><code>#!/usr/bin/python
#
# quick and dirty french2english translator
#

import urllib
import urllib2
from subprocess import Popen, PIPE

URL='http://translate.google.com/translate_t#fr|en|'

print "Paste your message"
msg = []
while 1:
    try:
        line = raw_input('&gt;&gt; ')
        msg.append(line)
    except:
        break

s = "&gt;&gt;" + "\n&gt;&gt;".join(msg)

data = "http://translate.google.com/translate_a/t?client=t&amp;%s&amp;fr&amp;tl=en" % urllib.urlencode({'text':s})
req = urllib2.Request('http://translate.google.com/translate_t', data, {'User-Agent':'Mozilla/5.0'})
resp = urllib2.urlopen(req).read()
p = Popen("lynx -dump -stdin | grep -- '&gt;&gt;'", shell=True, stdin=PIPE, stdout=PIPE)
p.stdin.write(resp)
p.stdin.close()
trans = p.stdout.read()
print trans
</code></pre>

<p>Agora é só dar ctrl-c no texto, depois rodar o programinha e dar ctrl-v seguido por ctrl-d <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  .</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2009/01/22/quick-n-dirty-fr-en-translator-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Aegisub: If programming languages were religions&#8230;</title>
		<link>http://dodonov.net/blog/2008/12/18/aegisub-if-programming-languages-were-religions/</link>
		<comments>http://dodonov.net/blog/2008/12/18/aegisub-if-programming-languages-were-religions/#comments</comments>
		<pubDate>Thu, 18 Dec 2008 11:57:25 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[fun]]></category>
		<category><![CDATA[programming]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=220</guid>
		<description><![CDATA[Perl would be Voodoo &#8211; An incomprehensible series of arcane incantations that involve the blood of goats and permanently corrupt your soul. Often used when your boss requires you to do an urgent task at 21:00 on friday night. huauhahahahaha via Aegisub: If programming languages were religions&#8230;.]]></description>
			<content:encoded><![CDATA[<p><em>Perl would be Voodoo &#8211; An incomprehensible series of arcane incantations that involve the blood of goats and permanently corrupt your soul. Often used when your boss requires you to do an urgent task at 21:00 on friday night.</em></p>

<p>huauhahahahaha</p>

<p>via <a href='http://www.aegisub.net/2008/12/if-programming-languages-were-religions.html' onclick="urchinTracker('/outgoing/www.aegisub.net/2008/12/if-programming-languages-were-religions.html?referer=');">Aegisub: If programming languages were religions&#8230;</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/12/18/aegisub-if-programming-languages-were-religions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>python performance</title>
		<link>http://dodonov.net/blog/2008/12/09/python-performance/</link>
		<comments>http://dodonov.net/blog/2008/12/09/python-performance/#comments</comments>
		<pubDate>Tue, 09 Dec 2008 16:24:41 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/?p=211</guid>
		<description><![CDATA[Ultimamente eu uso bastante programação funcional em python para tudo. Entretanto, fiquei brincando hoje e descobri que nem sempre ela oferece os melhores resultados. Por exemplo, vamos imaginar a função que vai fazer todas as combinações entre os elementos de uma lista. Ela pode ser escrita de forma funcional: # permutate-func def permutate(l): '''Returns all <a href='http://dodonov.net/blog/2008/12/09/python-performance/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Ultimamente eu uso bastante programação funcional em python para tudo. Entretanto, fiquei brincando hoje e descobri que nem sempre ela oferece os melhores resultados.</p>

<p>Por exemplo, vamos imaginar a função que vai fazer todas as combinações entre os elementos de uma lista. Ela pode ser escrita de forma funcional:</p>

<pre><code># permutate-func
def permutate(l):
    '''Returns all possible combinations of list values'''
    return reduce(lambda x, y: y + x, [ [(x, y) for y in l if x != y] for x in l ])
</code></pre>

<p>ou de forma iterativa:</p>

<pre><code># permutate-iter
def permutate(l):
    '''Returns all possible combinations of list values'''
    res = []
    for x in l:
        for y in l:
            if x != y:
                res.append((x, y))
    return res
</code></pre>

<p>Para listas pequenas não temos muita diferença de desempenho. Agora para listas maiores (por exemplo, com 1000 strings):</p>

<pre><code>dups=['string%d' % x for x in range(1000)]
permutate(dups)
</code></pre>

<p>temos os seguintes resultados para programação funcional:</p>

<pre><code># time permutate-func
real    0m24.494s
user    0m20.763s
sys 0m1.698s
</code></pre>

<p>e os seguintes para o algoritmo iterativo:</p>

<pre><code># time permutate-iter
real    0m1.191s
user    0m1.150s
sys 0m0.036s
</code></pre>

<p>O tempo de <strong>24</strong> segundos caiu para apenas <strong>1</strong> segundo!</p>

<p>Qual conclusão tiramos disso? Embora programação funcional é extremamente poderosa, em alguns casos é melhor usar outras soluções para o problema <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  .</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/12/09/python-performance/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Como tirar screenshot em 4 linhas de código</title>
		<link>http://dodonov.net/blog/2008/10/16/como-tirar-screenshot-em-4-linhas-de-codigo/</link>
		<comments>http://dodonov.net/blog/2008/10/16/como-tirar-screenshot-em-4-linhas-de-codigo/#comments</comments>
		<pubDate>Thu, 16 Oct 2008 15:41:40 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/2008/10/16/como-tirar-screenshot-em-4-linhas-de-codigo/</guid>
		<description><![CDATA[Mais um exemplo do poder de python + gtk. Para tirar um screenshot da tela, salvando-o em formato JPEG, o seguinte código é suficiente: from gtk.gdk import * screenshot = Pixbuf(COLORSPACE_RGB, False, 8, screen_width(), screen_height()) screenshot.get_from_drawable(get_default_root_window(), colormap_get_system(), \ 0, 0, 0, 0, screen_width(), screen_height()) screenshot.save("tela.jpg", "jpeg", {"quality": "75"}) (Tá certo, dividi em 5 linhas para <a href='http://dodonov.net/blog/2008/10/16/como-tirar-screenshot-em-4-linhas-de-codigo/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Mais um exemplo do poder de python + gtk. Para tirar um screenshot da tela, salvando-o em formato JPEG, o seguinte código é suficiente:</p>

<pre><code>from gtk.gdk import *
screenshot = Pixbuf(COLORSPACE_RGB, False, 8, screen_width(), screen_height())
screenshot.get_from_drawable(get_default_root_window(), colormap_get_system(), \
    0, 0, 0, 0, screen_width(), screen_height())
screenshot.save("tela.jpg", "jpeg", {"quality": "75"})
</code></pre>

<p>(Tá certo, dividi em 5 linhas para melhorar a legibilidade, mas no fundo são só 4 linhas mesmo).</p>

<p>Uma das maiores vantagens do python para mim é a legibilidade do código, facilidade de programação, e eficiência. Com quantas linhas de código seria possível fazer esse exemplo em qualquer outra linguagem? (Não vale apelar para <code>import -window root tela.jpg</code> porque aí é ImageMagick que faz toda a mágica!) <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/10/16/como-tirar-screenshot-em-4-linhas-de-codigo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>O poder de programação funcional em Python</title>
		<link>http://dodonov.net/blog/2008/10/04/o-poder-de-programacao-funcional-em-python/</link>
		<comments>http://dodonov.net/blog/2008/10/04/o-poder-de-programacao-funcional-em-python/#comments</comments>
		<pubDate>Sat, 04 Oct 2008 16:00:27 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/2008/10/04/o-poder-de-programacao-funcional-em-python/</guid>
		<description><![CDATA[Cada vez mais e mais eu gosto dos recursos de programação funcional em python. E, como eu uso essa linguagem para resolver tarefas mais variáveis, não dá para não perceber que a velocidade de desenvolvimento e eficiência do código tornam-se cada vez melhores, por simplesmente aplicar técnicas de programação funcional. Por exemplo, sem a programação <a href='http://dodonov.net/blog/2008/10/04/o-poder-de-programacao-funcional-em-python/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Cada vez mais e mais eu gosto dos recursos de programação funcional em python. E, como eu uso essa linguagem para resolver tarefas mais variáveis, não dá para não perceber que a velocidade de desenvolvimento e eficiência do código tornam-se cada vez melhores, por simplesmente aplicar técnicas de programação funcional.</p>

<p>Por exemplo, sem a programação funcional, eu usava o seguinte código antes para ler um arquivo com uma série de números, e determinar a média dos valores:</p>

<p><pre>
fd = open("data.log")
data = fd.readlines()
valores = []</p>

<h1>le os dados</h1>

<p>for line in data:
    line_val = float(line.strip())
    valores.append(line_val)</p>

<h1>calcula a media</h1>

<p>media = 0
for item in valores:
    media += item
media /= len(media)
</pre></p>

<p>Re-escrevendo isso com técnicas de programação funcional, temos o seguinte:</p>

<p><pre></p>

<h1>le os valores do arquivo, transformando-os para floats, e ignorando strings vazias</h1>

<p>valores = [float(val) for val in open("data.log").readlines() if len(val) > 1]</p>

<h1>calcula a media, somando todos os valores e dividindo pelo número de elementos no vetor</h1>

<p>media = reduce(lambda x, y: x+y, valores) / len(valores)
</pre></p>

<p>(É óbvio que é só um exemplo rápido, não estou tratando as excessões aqui, mas para resolver problemas simples do dia-a-dia é mais de que suficiente!)</p>

<p>O essencial são as funções <b>lambda</b>, <b>map</b>, <b>reduce</b> e <b>filter</b>. Todos os detalhes interessantes sobre esse estilo de programação eu achei <a href="http://www.slideshare.net/adambyrtek/functional-programming-with-python" onclick="urchinTracker('/outgoing/www.slideshare.net/adambyrtek/functional-programming-with-python?referer=');">aqui</a>, e recomendo essa apresentação para todos!</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/10/04/o-poder-de-programacao-funcional-em-python/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Functional Programming with Python (RuPy 2008)</title>
		<link>http://dodonov.net/blog/2008/08/05/functional-programming-with-python-rupy-2008/</link>
		<comments>http://dodonov.net/blog/2008/08/05/functional-programming-with-python-rupy-2008/#comments</comments>
		<pubDate>Tue, 05 Aug 2008 02:49:07 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/2008/08/05/functional-programming-with-python-rupy-2008/</guid>
		<description><![CDATA[Uma apresentação excellente sobre programação funcional em python. Recomendo! Functional Programming with Python (RuPy 2008)]]></description>
			<content:encoded><![CDATA[<p>Uma apresentação excellente sobre programação funcional em python. Recomendo!</p>

<p><a href="http://www.slideshare.net/adambyrtek/functional-programming-with-python" onclick="urchinTracker('/outgoing/www.slideshare.net/adambyrtek/functional-programming-with-python?referer=');">Functional Programming with Python (RuPy 2008)</a></p>

<p><hints id="hah_hints"></hints></p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/08/05/functional-programming-with-python-rupy-2008/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Slashdot &#124; World&#8217;s Shortest P2P App: 15 Lines</title>
		<link>http://dodonov.net/blog/2008/07/29/slashdot-worlds-shortest-p2p-app-15-lines/</link>
		<comments>http://dodonov.net/blog/2008/07/29/slashdot-worlds-shortest-p2p-app-15-lines/#comments</comments>
		<pubDate>Tue, 29 Jul 2008 22:34:18 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[devel]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/2008/07/29/slashdot-worlds-shortest-p2p-app-15-lines/</guid>
		<description><![CDATA[Pois é &#8211; é possível fazer uma implementação completa de rede peer-to-peer usando somente 15 linhas de python (com um pouco de gambiarras envolvendo lambdas ). Slashdot &#124; World&#8217;s Shortest P2P App: 15 Lines Impressionante.. como tudo em python!]]></description>
			<content:encoded><![CDATA[<p>Pois é &#8211; é possível fazer uma implementação completa de rede peer-to-peer usando somente 15 linhas de python (com um pouco de gambiarras envolvendo lambdas <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  ).</p>

<p><a href="http://yro.slashdot.org/article.pl?sid=05/01/06/2324211&#038;from=rss" onclick="urchinTracker('/outgoing/yro.slashdot.org/article.pl?sid=05/01/06/2324211_038_from=rss&amp;referer=');">Slashdot | World&#8217;s Shortest P2P App: 15 Lines</a></p>

<p>Impressionante.. como tudo em python!</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/07/29/slashdot-worlds-shortest-p2p-app-15-lines/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Python scripting</title>
		<link>http://dodonov.net/blog/2008/06/27/python-scripting/</link>
		<comments>http://dodonov.net/blog/2008/06/27/python-scripting/#comments</comments>
		<pubDate>Fri, 27 Jun 2008 17:27:50 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[music]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/2008/06/27/python-scripting/</guid>
		<description><![CDATA[Talvez pode ser útil para alguém . Este script pega a lista de músicas do mpd, seleciona um playlist aleatório, e coloca no ipod shuffle. !/usr/bin/python import os,random ipod mountpoint - must be mounted! MOUNTPOINT="/mnt/ipod" def get_files(): '''Reads the list of mp3 files from mpd database''' data = open(".mpd.db").readlines() files = [] for l in <a href='http://dodonov.net/blog/2008/06/27/python-scripting/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Talvez pode ser útil para alguém <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>

<p>Este script pega a lista de músicas do mpd, seleciona um playlist aleatório, e coloca no ipod shuffle.</p>

<p><pre>
<code></p>

<h1>!/usr/bin/python</h1>

<p>import os,random</p>

<h1>ipod mountpoint - must be mounted!</h1>

<p>MOUNTPOINT="/mnt/ipod"</p>

<p>def get_files():
    '''Reads the list of mp3 files from mpd database'''
    data = open(".mpd.db").readlines()
    files = []
    for l in data:
        fields = l.strip().split(":",2)
        if len(fields) &lt; 2:
            continue
        if fields[0] == "file":
            files.append(fields[1].strip())
    return files</p>

<p>def get_free_space():
    '''Gets available space from IPOD partition'''
    line = os.popen("df -k %s | awk '{print $4}'" % MOUNTPOINT).readlines()[-1]
    return int(line)</p>

<p>def fullcp(file, target):
    '''copies file and directory structure'''
    os.system('tar cf - "%s" | (cd %s &amp;&amp; tar xf -)' % (file, target))</p>

<p>if <strong>name</strong> == "<strong>main</strong>":
    try:
        os.mkdir("%s/mp3" % MOUNTPOINT)
    except:
        print "Not creating %s/mp3!" % MOUNTPOINT
    files = get_files()
    freespace = get_free_space()
    while 1:
        # pega arquivo aleatorio
        pos = random.randint(0, len(files))
        curfile = files[pos]
        del files[pos]
        # determina o tamanho
        res = os.stat(curfile)
        size = res[6] / 1000
        if freespace - size &lt; 1:
            break
        freespace -= size
        # copia
        print "Copying [%8dK left]: %s" % (freespace, curfile)
        fullcp(curfile, "%s/mp3/" % MOUNTPOINT)
</code>
</pre></p>

<p>É melhor usar ele junto com <a href="http://shuffle-db.sourceforge.net/" onclick="urchinTracker('/outgoing/shuffle-db.sourceforge.net/?referer=');">Shuffle-DB</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/06/27/python-scripting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>office.open(3)</title>
		<link>http://dodonov.net/blog/2008/05/08/officeopen3/</link>
		<comments>http://dodonov.net/blog/2008/05/08/officeopen3/#comments</comments>
		<pubDate>Thu, 08 May 2008 03:14:17 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[office]]></category>
		<category><![CDATA[portuguese]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[writing]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/2008/05/08/officeopen3/</guid>
		<description><![CDATA[Acabou de sair a versão beta do OpenOffice 3. Muita gente já escreveu sobre isso, com opiniões variando entre &#8220;é a salvação do universo&#8221; e &#8220;e daí??&#8221;; agora eu queria falar a minha opinião, que não é nenhuma das duas. Primeiro, vamos relembrar um pouco a situação como ela estava a alguns poucos anos atrás <a href='http://dodonov.net/blog/2008/05/08/officeopen3/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Acabou de sair a versão <a href="http://marketing.openoffice.org/3.0/featurelistbeta.html" onclick="urchinTracker('/outgoing/marketing.openoffice.org/3.0/featurelistbeta.html?referer=');">beta do OpenOffice 3</a>.</p>

<p>Muita gente já escreveu sobre isso, com opiniões variando entre &#8220;é a salvação do universo&#8221; e &#8220;e daí??&#8221;; agora eu queria falar a minha opinião, que não é nenhuma das duas.</p>

<p>Primeiro, vamos relembrar um pouco a situação como ela estava a alguns poucos anos atrás (vou comparar a evolução do OpenOffice com o Microsoft Office&#8230; porque todos os outros pacotes de Office, seja de IBM, de Corel, da SUN, ou de qualquer outra empresa perdem significativamente para o próprio OpenOffice. Temos o Google Docs, mas, obviamente, é um caso a parte!).</p>

<p>Na época que não tinha OpenOffice 1.0, e só tinha os <em>milestones</em> que &#8211; com muita sorte &#8211; até funcionavam e abriam alguns (poucos e seletos) arquivos do office. Você acha que o OpenOffice hoje em dia é lento?? Ha-ha. Instale algum dos milestones antigos &#8211; ou o 1.0 mesmo para ver a diferença. A maior vantagem dessas primeiras versões é que era <strong>possível</strong> abrir e editar uma grande parte dos arquivos de Microsoft Office. Obviamente, não todos, mas muitos. Nem isso não era possível antes (abiword? koffice? staroffice, siagoffice? prefiro não comentar).</p>

<p>A versão 1.0 foi um marco gigante &#8211; foi uma versão estável (na medida do possível), multi-plataforma, completamente livre e que abria a maior parte dos documentos existentes. Mais uma vez &#8211; não absolutamente todos, mas a <strong>grande</strong> maioria. Abrir lentamente, com interface diferente, com diversos problemas de <em>layout</em>, posicionamento e funcionamento, mas.. ela funcionava!</p>

<p>A versão 1.1 melhorou significamente o problema de desempenho, e essas melhorias continuaram com todas as versões posteriores. Versão 2 (e suas sub-versões) introduziu nova interface, suporte a ODF e desempenho muito melhor. E logo-logo vamos ter a versão 3.0.</p>

<p>O que é possível notar nessa evolução das versões?? Primeiramente, o número de reclamações caiu significativamente! Vejamos:</p>

<ul>
    <li><strong>Interface diferente:</strong> com o lançamento de Microsoft Office 2007 esta reclamação perdeu completamente o sentido. OpenOffice é muito mais parecido com as versões antigas do Office de que o próprio software de microsoft&#8230;</li>
    <li><strong>Suporte incompleto a documentos de office:</strong> por mais reclamações que é possível encontrar sobre isso, tem que aceitar que o número de problemas de compatibilidade decresceu absurdamente nos últimos anos. Antes era sorte ter um documento .doc(.ppt, .xls) que abriria corretamente no OpenOffice. Hoje, em contra-partida, é difícil achar um documento com problemas. Chega a casos curiosos, onde OpenOffice consegue abrir documentos que travam o próprio Microsoft Office <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> , e a própria Microsoft assume isso (obviamente, não publicamente <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  ).</li>
    <li><strong>Desempenho inadequado:</strong> esta afirmação também perdeu o sentido ao <a href="http://www.infoworld.com/article/08/04/14/16TC-winoffice-performance_1.html" onclick="urchinTracker('/outgoing/www.infoworld.com/article/08/04/14/16TC-winoffice-performance_1.html?referer=');">avaliarmos o Microsoft Office 2007</a>.</li>
    <li><strong>Falta de funcionalidades:</strong> o OpenOffice ainda não implementa todas as 100% das funcionalidades que o Microsoft Office oferece. Porém&#8230; você conhece alguém que usa <strong>TODOS</strong> os recursos do Word?? Pois é, as funcionalidades <strong>já</strong> presentes são mais de que adequadas&#8230;</li>
    <li>e assim por diante..</li>
</ul>

<p>Qual é a conclusão que dá para tirar, avaliando as versões atuais de OpenOffice??</p>

<p>Elas <strong>já</strong> oferecem todas as funcionalidade que a absoluta maioria dos usuários precisam. Nem sempre do jeito idéntico ao Microsoft Office; nem sempre com a mesma interface; e nem sempre com todas as variações, mas oferecem!</p>

<p>E quanto a desempenho.. Seguindo os conselhos básicos localizaveis facilmente no google (desligar java, diminuir o cache, diminuir o uso de memória; otimizar o carregamento; desativar funcionalidades avançadas, etc) é possível melhorar o tempo de execução inicial em mais de <strong>10x</strong>, e uso de memória em mais de <strong>4x</strong> (eu comprovei isso com projetos que fizemos com Intel e Ardence em 2004-2005; inclusive tem até publicações da Intel sobre isso &#8211; as de Ardence continuam sendo sob n.d.a. até onde eu sei <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> ). Mas, se alguém tiver curiosidade, fiquem a vontade para perguntar por aqui mesmo!</p>

<p>Bem.. passando por esta introdução pequena <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> , o que vamos ver na nova versão de OpenOffice?</p>

<ul>
    <li><strong>Suporte a Mac OS X</strong> &#8211; bastante interessante, porque vai ser possível rodar o OpenOffice em cima de MAC sem precisar de servidor X.</li>
    <li><strong>Suporte a ODF 1.2 e OOXML</strong> &#8211; preciso falar alguma coisa?? <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </li>
    <li><strong>Suporte a PDFs editáveis</strong> &#8211; conhece algum outro escritório que permite isso?</li>
    <li><strong>Suporte a macros em VBA</strong> &#8211; uma das maiores limitações atuais foi a execução de macros voltados para Microsoft Office. Não mais.</li>
    <li><strong>Suporte a extensions</strong> &#8211; <em>extensions</em> fizeram do firefox o browser tão popular o quanto ele é hoje em dia. Enquanto plugins para OpenOffice existem já faz alguns anos, nunca foi simples ou intuitivo instalar e usar eles. Acredito que agora isso vai ser resolvido definitivamente.</li>
    <li><strong>Melhor suporte a multi-midia</strong> &#8211; suporte a reprodução de sons em <em>background</em>, suporte a múltiplos monitores, melhor suporte para CSV, HTML, melhor na renderização de fontes; melhorias na edição de imagens, e assim por diante. A lista é grande.</li>
    <li><strong>Novas funcionalidades</strong> &#8211; novas possibilidades relacionadas a planilhas, formulas, gráficos, renderização de páginas WEB, etc</li>
    <li>e muitos outras melhorias menos significativas</li>
</ul>

<p>O que dá para extrair de tudo disso? É simples &#8211; o desenvolvimento do OpenOffice é feito de forma <strong>evolucionária</strong>, e não <strong>revolucionária</strong>. O que acontece é que ele fica melhor e melhor <strong>gradativamente</strong>, e não visa fazer milagres de uma hora para outra. É bom isso? Sim, porque é possível ver o que podemos esperar das próximas versões. Isso tem lados negativos? Claro, porque sempre vamos ver comentários do tipo &#8220;office não está evoluindo&#8221;, &#8220;versão 2 é parecida com 1&#8243;, &#8220;microsoft é mais diferente&#8221;&#8230;</p>

<p>O resto vamos ver logo, na versão 3.0 do OpenOffice <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/05/08/officeopen3/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Distributed Version Control</title>
		<link>http://dodonov.net/blog/2008/05/02/distributed-version-control/</link>
		<comments>http://dodonov.net/blog/2008/05/02/distributed-version-control/#comments</comments>
		<pubDate>Fri, 02 May 2008 17:08:07 +0000</pubDate>
		<dc:creator>eugeni</dc:creator>
				<category><![CDATA[cvs]]></category>
		<category><![CDATA[devel]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[writing]]></category>

		<guid isPermaLink="false">http://dodonov.net/blog/2008/05/02/distributed-version-control/</guid>
		<description><![CDATA[Só um pequeno resumo de vantagens e desvantagens de sistemas de controle de versões distribuídos que eu já cheguei a usar. SVN + SVK &#8211; parecido com SVN, tem os mesmos problemas que ele (cria um monte de diretórios, etc). Na minha opinião, não tem muito uso prático &#8211; é melhor usar soluções distribuídas mesmo <a href='http://dodonov.net/blog/2008/05/02/distributed-version-control/'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Só um pequeno resumo de vantagens e desvantagens de sistemas de controle de versões distribuídos que eu já cheguei a usar.</p>

<ul>
    <li><strong>SVN + SVK</strong> &#8211; parecido com SVN, tem os mesmos problemas que ele (cria um monte de diretórios, etc). Na minha opinião, não tem muito uso prático &#8211; é melhor usar soluções distribuídas mesmo (bzr, git ou mercurial), porque todas elas tem gateways para SVN propriamente dito.</li>
    <li><strong>BZR</strong> &#8211; acho que é o meu favorito para a maioria das coisas. Facil de usar (o mais fácil de todos, na minha opinião), rápido &#8211; principalmente nas últimas versões, extensível. Os meus maiores problemas com ele foi o desempenho (que foi resolvido na versão 1.0), e o tratamento de arquivos binários grandes &#8211; ele fazia questão de colocar o commit inteiro na memória, em formato ASCII ainda. Ou seja, para fazer commit de 100MB ele usava 2GB de RAM. Mas aparentemente, isso foi arrumado recentemente.</li>
    <li><strong>GIT</strong> &#8211; extremamente poderoso, rápido e eficiente.Em contra-partida, ele tem milhares de comandos, sub-comandos, parâmetros e opções. Se você aprender tudo com ele, ele é o melhor. Entretanto, eu vivo me perdendo na hora de fazer coisas mais complexas (tipo, fazer um cherry-pick de um repositório remoto em um branch diferente). Por outro lado, só ele que permite fazer cherry-pick de forma fácil (para quem está por fora &#8211; cherry-pick permite você pegar um commit independente e embutir ele em outro branch. Se isso não fez sentido para você, provavelmente você não precisa dele <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> ). A melhor coisa do GIT para mim é o suporte dele para multiplos branches locais, no mesmo diretório. E a velocidade, é claro. Porém, a complexidade dele acaba complicando demais a vida as vezes.</li>
    <li><strong>Mercurial</strong> &#8211; parecido com o BZR e GIT. Atualmente suporta branches e cherry-picks também (de forma diferente). Ele suporta queues de patches também nativamente &#8211; mas, como nunca precisei disso, não posso falar muito detalhes. Fora isso, nunca cheguei a mexer muito com ele (mas, para quem tiver interesse, tem um tutorial interessante <a href="http://devlog.waltercruz.com/micro-tutorial-de-mercurial" onclick="urchinTracker('/outgoing/devlog.waltercruz.com/micro-tutorial-de-mercurial?referer=');">aqui</a>). A escolha entre ele, bzr e git muitas vezes é questão de religião mesmo <img src='http://dodonov.net/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> .</li>
    <li><strong>DARCS</strong> &#8211; bastante interessante, e diferente de todos os outros sistemas. Basicamente, todo o mecanismo de commits e diferenças entre versões dele é baseado em filas de patches, aplicados em determinada ordem. A filosofia dele também é parecida com GIT &#8211; ele visa manter controle do conteúdo, e não da estrutura de versões. Isso tem lados bons (o mesmo conteúdo pode migrar de um lugar para outro &#8211; arquivo, diretório, etc) e ruins (se alguém fez essa migração, você não vai ter controle exato sobre o que foi feito).</li>
    <li><strong>GNU ARCH</strong> &#8211; acredito que hoje em dia ele tem mais interesse histórico de que prático. Muito mais complexo de usar (se bem que, comparando com GIT, acho que dá uma briga boa). As ideias dele são utilizadas em outros sistemas de controle de versões distribuídas, mas ele em si &#8211; pelo que eu sei &#8211; está parado. Eu cheguei a usar ele faz alguns anos, mas desisti logo devido à complexidade dele.</li>
    <li><strong>MONOTONE</strong> &#8211; também em desuso nos últimos tempos, o MONOTONE serviu como inspiração para GIT. Fora isso, nunca vi ninguém usar ele, então não tenho opinião formada sobre ele.</li>
</ul>

<p>Além disso, tem diversas outras soluções caseiras (com svn, cvs (eca..), etc) que fazem a mesma coisa que DRCS&#8217;es usando algumas gambiarras (hehehe). Mas eu fico entre BZR e GIT na maioria dos casos.</p>
]]></content:encoded>
			<wfw:commentRss>http://dodonov.net/blog/2008/05/02/distributed-version-control/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Served from: dodonov.net @ 2012-02-07 13:29:14 -->
