james's Friends' Journals http://use.perl.org/~james/journal/friends/ james's Friends' use Perl Journals en-us use Perl; is Copyright 1998-2006, Chris Nandor. Stories, comments, journals, and other submissions posted on use Perl; are Copyright their respective owners. 2012-01-25T02:04:20+00:00 pudge pudge@perl.org Technology hourly 1 1970-01-01T00:00+00:00 james's Friends' Journals http://use.perl.org/images/topics/useperl.gif http://use.perl.org/~james/journal/friends/ use Perl; Shutting Down Indefinitely http://use.perl.org/~pudge/journal/40525?from=rss <p>See <a href="http://use.perl.org/article.pl?sid=10/09/08/2053239">here</a>.</p> pudge 2010-09-08T22:07:47+00:00 useperl Flore Louise Apolline Bruhat-Souche http://use.perl.org/~BooK/journal/40510?from=rss <p>On Thursday, August 19, 2010 at 9:30, Flore Louise Apolline Bruhat-Souche was born. She weighs 3.02 kg and measures 48 cm. </p><p> Word already spread through IRC (#perlfr and #yapc mostly) and via email and telephone. </p><p> The mother is fine, the father is slightly tired and the <a href="http://use.perl.org/~BooK/journal/33509">big sister</a> is happy. </p><p> There is <a href="http://flore.bruhat-souche.net/">one photo online</a>. </p> BooK 2010-08-20T22:17:07+00:00 journal use Perl; http://use.perl.org/~pudge/journal/40493?from=rss <p>I am no longer working for Slashdot/Geeknet as of September 30. I am actively seeking new employment. Unless you want to hire me, you don't need to care, unless you also care about <a href="http://use.perl.org/">use Perl;</a>, because it has been generously hosted by Geeknet since I started the site over 10 years ago, shortly after I was hired by Andover.Net to work on Slashdot.</p><p>Long story short, I have not done much with the site in recent years, so my options at this point are to do nothing; migrate the site to a new server and keep it running as-is; or take the data and do something with it on a new site. Or something I haven't thought of.</p><p>I am hereby accepting proposals for what to do with use Perl;. In short, I would like to donate it to someone who will give it a good home. If you're interested, give me your best pitch.</p><p>Cross-posted on <a href="http://pudge.net/glob/2010/08/use-perl.html">&lt;pudge/*&gt;</a>.</p> pudge 2010-08-11T23:34:11+00:00 journal Matt Trout, aka mst, is insane http://use.perl.org/~pudge/journal/40492?from=rss <p>Wow. I occasionally, but not too often, go into #perl. Very busy with family and life. So I go in today, and for no reason, <a href="http://www.trout.me.uk/">mst</a> bans me and tells me to not come back.</p><p>What's up with him being such an irrational dick?</p> pudge 2010-08-11T16:41:54+00:00 journal Summary of Celtics vs. Lakers NBA Finals History http://use.perl.org/~pudge/journal/40370?from=rss <p>There have been 60 NBA Finals. The Boston Celtics have won 17, and the Minneapolis/Los Angeles Lakers have won 15, which amounts to those teams winning more than half of all NBA Finals. This year, they play each other in the Finals again, making it 33 champions out of 61 being either the Lakers or the Celtics.</p><p>Additionally, 39 of the 61 Finals have included either the Lakers or the Celtics. Including this year, the Celtics and Lakers have played each other in the Finals a whopping 12 times (just under one-fifth of all Finals have been these two teams).</p><p>The Celtics have made 21 total Finals appearances, so have faced the Lakers more than half of the times they've been in the Finals. The Lakers have made 30 Finals appearances, facing the Celtics in two-fifths of those.</p><p>The Celtics won nine of those against the Lakers, which accounts for more than half of all their 17 championships. The Lakers' two victories over the Celtics came after the Celtics won their first eight encounters.</p><p>The longest streak without either team in the Finals was eight years from '92-'99. The longest streak <b>with</b> either the Lakers or Celtics in the Finals was 10 years, done twice (from '57-'66, in which the Celtics appears all 10 years, and the Lakers five of those; and '80-'89, in which the Lakers appeared eight times, the Celtics five).</p><p>The longest streak for one team appearing in the Finals was, as noted, Boston, in the 10 years from '57-'66. Boston won nine of those 10 years, including eight in a row (the longest winning streak from any one team) from '59-'66, and also won 10 in 12 years, from '57-'69.</p><p>The Lakers' longest appearance streak is "only" four, from '82-'85, winning twice; but they have also appeared three times in a row five additional times (including the current three-year streak). In two of those, they won all three years; in one, they lost all three.</p><p>The only other team to "threepeat" was the Bulls, winning three years in a row twice in eight years ('91-'98). No other team but the Celtics and Lakers have had four consecutive appearances. The only other team to have three consecutive appearances was the Knicks, losing all three from '51-'53.</p><p>The 2010 NBA Finals begin in Los Angeles on Thursday.</p><p>Cross-posted on <a href="http://pudge.net/glob/2010/05/summary-of-celtics-vs-lakers-nba-finals-history.html">&lt;pudge/*&gt;</a>.</p> pudge 2010-05-30T05:25:50+00:00 journal Unique http://use.perl.org/~pudge/journal/40329?from=rss <p>I wonder how long it will be before people start just putting together random letters for names of companies, bands, and so on, so they can be unique in Google searches.</p><blockquote><div><p>Your search - fobhwueufg8 - did not match any documents.</p></div></blockquote><p>^^ my new band name</p><p>(Hm, "Did Not Match Any Documents" would be a fun band name. Or the name of the debut album of the band fobhwueufg8.)</p><p>Cross-posted on <a href="http://pudge.net/glob/2010/04/unique.html">&lt;pudge/*&gt;</a>.</p> pudge 2010-04-26T17:45:28+00:00 journal Bob Jacobsen interview on FLOSS Weekly http://use.perl.org/~merlyn/journal/40324?from=rss Last week, I interviewed Bob Jacobsen for FLOSS Weekly. Bob used Perl's Artistic 1.0 license on some Java code to manage model trains. The code was later patented by an Oregon-based company(!) and then Bob got sued(!!) for Bob distributing the other company's patented code(!!!). The good part of the story is that this is the first test at the US Federal Appeals Court level for an open source license to be enforceable even if no money exchanges hands, and... we won! <p> Bob spent a lot of time and money on the case though. Listen to <a href="http://twit.tv/floss117">the podcast</a> and contribute to <a href="http://jmri.sourceforge.net/donations.shtml">his legal defense</a> if you care about open source.</p> merlyn 2010-04-23T03:55:11+00:00 journal My Slashroulette Videos http://use.perl.org/~pudge/journal/40290?from=rss <p>Today Slashdot did a spoof of Chatroulette, that we called Slashroulette. We prerecorded videos of ourselves and others. Here's five of the six I did (the sixth was me tuning the guitar, I didn't post that one on YouTube): <a href="http://www.youtube.com/watch?v=qHwz6sG37_Q">video 1</a>, <a href="http://www.youtube.com/watch?v=IQYgAxVo050">video 2</a>, <a href="http://www.youtube.com/watch?v=IlJBlObJnJY">video 3</a>, <a href="http://www.youtube.com/watch?v=GWxewYtRc48">video 4</a>, <a href="http://www.youtube.com/watch?v=TkVisbPXHVo">video 5</a>.</p><p>Cross-posted on <a href="http://pudge.net/glob/2010/04/my-slashroulette-videos.html">&lt;pudge/*&gt;</a>.</p> pudge 2010-04-02T05:15:16+00:00 journal Fixing Mailman with Perl http://use.perl.org/~BooK/journal/40266?from=rss <p>Mailman is useful. Mailman works. Mailman is ubiquitous. I am subscribed to over 50 mailing-lists managed by Mailman.</p><p> But Mailmand is software, and therefore <a href="http://hates-software.com/">hateful</a>. </p><p>My particular Mailman hate is the <code>nodupes</code> parameter.</p><blockquote><div><p> <i> <b>Avoid duplicate copies of messages?</b> </i> </p><p> <i>When you are listed explicitly in the To: or Cc: headers of a list message, you can opt to not receive another copy from the mailing list. Select Yes to avoid receiving copies from the mailing list; select No to receive copies.</i> </p><p> <i>If the list has member personalized messages enabled, and you elect to receive copies, every copy will have a X-Mailman-Copy: yes header added to it.</i> </p></div> </blockquote><p>I like duplicate email. Moreover, I like the <code>List-Id</code> header that makes emails sent through a list <i>special</i> (at least in the sense that they can be filtered <i>automatically</i> by more tools, and I can just delete the stuff that piles up in my Inbox). And by the way, how could Mailman be really sure that I got that other copy? Just because the headers say so? Bah.</p><p>Oh, and I also hate the fact that <i>Set globally</i> never worked for me with this option.</p><p>So, because I'm lazy, and I don't want to go clikety-click to first, get a reminder of the random password that was assigned to me years ago, and two, login and change that annoying option, and because <b>I don't want to do that fifty times, over and over again</b>...</p><p> I wrote and put on CPAN <a href="http://search.cpan.org/dist/WWW-Mailman/">WWW::Mailman</a>, designed to automate that kind of tedious task out of my life (and hopefully yours). Examples included, I know you're lazy too. </p><p><small>PS: I've been told there <i>is</i> a command-line interface to Mailman, but it is reserved to people managing Mailman on the server.</small></p> BooK 2010-03-25T01:07:02+00:00 journal My Netgear Router is Dumber Than It Thinks It Is http://use.perl.org/~pudge/journal/40163?from=rss <p>I upgraded the firmware on my Netgear router today and it wouldn't let me use the LAN IP I usually use for it, 10.0.1.1, because it thinks my ISP uses that subnet, because I set the router to read from my own internal DNS. Took me awhile to figure out <b>why</b> it thought what it did, because it didn't occur to me that it would care what DNS addresses I gave it.</p><p>Cross-posted on <a href="http://pudge.net/glob/2010/02/my-netgear-router-is-dumber-than-it-thinks-it-is.html">&lt;pudge/*&gt;</a>.</p> pudge 2010-02-07T02:09:27+00:00 journal Franchise Tag Whiners http://use.perl.org/~pudge/journal/40146?from=rss <p>There's a long line of players in the NFL who claim that it is a personal offense when their teams place the franchise tag on them.</p><p>These players are big fat babies.</p><p>The players agreed to the franchise tag for the owners, as a compromise. The players take advantage of everything available to them under the contract; why shouldn't the owners do the same?</p><p>Stop crying. Stop whining. Sure, you don't like it, but so what? Grow up. Those are the rules that you agreed to.</p> pudge 2010-01-30T18:52:27+00:00 journal ah, dreams... http://use.perl.org/~Matts/journal/40130?from=rss <p>I just woke from a dream where it was rjbs' birthday and we got him an onion cake. Only the person who made the cake misunderstood, and instead of a cake shaped like an onion he cooked it WITH onions in it.</p><p>Bizarro.</p> Matts 2010-01-26T10:31:17+00:00 journal Time::Piece test failures on Win32 http://use.perl.org/~Matts/journal/40129?from=rss <p>Can someone with Time::Piece test failures on Win32 please contact me offlist? I have a proposed patch I'd like to test, but no Win32 perl to test it on.</p> Matts 2010-01-25T23:23:53+00:00 journal note to self http://use.perl.org/~TeeJay/journal/40099?from=rss <p>note to self.. if puzzled why changes to a function/sub/method seem to have no effect make sure you don't have *any* warnings disabled, but especially the redefined sub one.. otherwise you'll never spot the accidentally pasted duplicate of the sub you want to change</p> TeeJay 2010-01-13T12:20:00+00:00 journal Moving 32-bit Intel Perl to Mac OS X 10.6 http://use.perl.org/~pudge/journal/40097?from=rss <p>Dear Google,</p><p>When you move a 32-bit x86 perl installation to a 64-bit Mac OS X 10.6 environment, you should edit $ARCH/Config_heavy.pl and add "-arch i386" to lddlflags, ldflags, and ccflags. The compiler and tools in Mac OS X 10.6 assume 64 bits unless you explicitly tell it otherwise, but some 32-bit installs don't bother putting in an -arch flag, because at the time it wasn't necessary.</p><p>Cross-posted on <a href="http://pudge.net/glob/2010/01/moving-32bit-intel-perl-to-mac-os-x-106.html">&lt;pudge/*&gt;</a>.</p> pudge 2010-01-12T17:39:58+00:00 journal Pink stinks http://use.perl.org/~BooK/journal/40076?from=rss <p>I still like wearing pink T-shirts, though. And not just at Perl conferences. (My love of pink basically comes from pushing a "joke" from the YAPC Europe 2002 auction way beyond its scope.)</p><p>Some very interesting reads:</p><ul> <li> <a href="http://www.guardian.co.uk/theguardian/2009/dec/12/pinkstinks-the-power-of-pink">http://www.guardian.co.uk/theguardian/2009/dec/12/pinkstinks-the-power-of-pink</a> </li><li> <a href="http://www.pinkstinks.co.uk/">http://www.pinkstinks.co.uk/</a> (I bought the T-shirt and buttons)</li><li> <a href="http://pinkstinks.wordpress.com/">http://pinkstinks.wordpress.com/</a> (the blog)</li></ul><p>A little more than a week ago, it was the second Christmas of my daughter... I guess it shows. Raising children brings all kinds of new interesting issues and questions to one's attention.</p> BooK 2010-01-05T00:35:05+00:00 journal Warning compiling perl stuff on Snow Leopard http://use.perl.org/~Matts/journal/40075?from=rss <p>I've searched but can't find any reference to this...</p><p>Compiling IO::KQueue on Snow Leopard I get the following warning:</p><blockquote><div><p> <tt>KQueue.xs: In function 'XS_IO__KQueue_kevent':<br>KQueue.xs:71: warning: format not a string literal and no format arguments</tt></p></div> </blockquote><p>Yet that line is just:</p><blockquote><div><p> <tt>&nbsp; &nbsp; Newxz(ke, max_events, struct kevent);</tt></p></div> </blockquote><p>Which seems to me pretty standard perl, and no format strings involved (though Newxz expands quite a few macros).</p> Matts 2010-01-04T22:13:57+00:00 journal git-move-dates http://use.perl.org/~BooK/journal/40024?from=rss <p>As a Perl programmer and Open Source enthousiast, you probably sometimes contribute to Open Source projects. Maybe even (gasp!) during work hours. If your employer is jealous of your time, you probably do not want your commits to <i>look</i> like they were done during work hours (especially in tools like the GitHub Punch Card).</p><p>On the other hand, it doesn't make sense to not commit your changes, and lose the benefits of using Git, just so that the reality of <i>when</i> you worked on these tiny changes is not made public. (At that point, it would probably also make more sense to have an open discussion with your boss...)</p><p>The way Git handles history makes it really easy to change the date of commits on a local branch. When I first thought about it, my idea was to write some date manipulation code (move a bunch of commits from a time range to another with all kinds of fancy nooks and crannies) and manipulate the Git trees and commits myself.</p><p>Then I discovered <b>git filter-branch</b>, which is all about rewriting commits. And I realized that in the situation above, moving commits a few hours in the future (like ten minutes before actually using <b>git push</b> or <b>git send-email</b>) is largely sufficient.</p><p>The problem is that the code to move a bunch of commits one hour in the future looks like this:</p><blockquote><div><p> <tt>&nbsp; &nbsp; git filter-branch --commit-filter '\<br>&nbsp; &nbsp; &nbsp; GIT_AUTHOR_DATE=`echo "$GIT_AUTHOR_DATE"|perl -pe'\''s/\d+/$&amp;+3600/e'\''`;\<br>&nbsp; &nbsp; &nbsp; GIT_COMMITTER_DATE=`echo "$GIT_COMMITTER_DATE"|perl -pe'\''s/\d+/$&amp;+3600/e'\''`;\<br>&nbsp; &nbsp; &nbsp; git commit-tree "$@"' -- &lt;rev-list&gt;</tt></p></div> </blockquote><p>Which is impossible to remember, and painful to write.</p><p>So, lazy as a Perl programmer should be, I just wrote <b>git-move-dates</b>, that writes and runs the above type of command-lines for me. Useful options include <i>--committer</i> and <i>--author</i> (to change only one of the two existing dates), and options ranging from <i>--seconds</i> to <i>--weeks</i> to define the exact timespan of your commits' time-travels.</p><p>As with my other Git gadgets, the source is available from <a href="http://github.com/book/git-gadgets">http://github.com/book/git-gadgets</a>.</p><p>And remember: there's nothing wrong with rewriting history, as long as it's <i>unpublished</i>, local history.<nobr> <wbr></nobr><code>;-)</code> </p> BooK 2009-12-15T22:22:40+00:00 journal More Git gadgets http://use.perl.org/~BooK/journal/39970?from=rss <p>Last week on p5p, after noticing that the new way to name version tags in perl5.git was to use <b>v<i>$version</i> </b>, I proposed to copy the old <b>perl-<i>$version</i> </b> tags to the new scheme, going back at least to 5.6.0 (which is when the Perl naming convention for version changed). I haven't done it yet for various reasons, but in order to do it, I developped a small <b>git-copytag</b> tool, that copies (or moves) the tag with all its annotations. Clone it from <a href="http://github.com/book/git-gadgets">http://github.com/book/git-gadgets</a>.</p><p>I also started to check if the existing tags in perl5.git point to the commit matching the published distribution, but my first attempt failed miserably (creating Git <code>tree</code> objects from the distributions and trying to find a commit pointing to the same <code>tree</code> id). I'll move on to a different approach (<code>diff -r</code>, basically).</p><p> In other news, I finally succeeded in creating the <a href="/~BooK/journal/39919">Git fractals</a> I wanted. I'll soon post more details about it on the <a href="http://philippe.bruhat.net/stuff/git-fractals/sierpinski.html">page dedicated to Sierpi&#324;ski triangles</a> on <a href="http://philippe.bruhat.net/">my personal site</a>.</p> BooK 2009-12-03T08:55:03+00:00 journal Spiteful spam http://use.perl.org/~petdance/journal/39969?from=rss <p> I know that a lot of people are moving their blogs over to <a href="http://blogs.perl.org/">http://blogs.perl.org/</a>, leaving <a href="http://use.perl.org/">http://use.perl.org/</a> behind. Part of the frustration is that Chris Nandor, Pudge, hasn't done much to modernize use.perl.org, but hey, it's Pudge's choice, and he runs the site, and we're all here by grace of him running it. Beggars and choosers, y'know. If you're frustrated with a Perl news site, you can go <a href="http://perlbuzz.com/">start your own</a>. </p><p> So certainly, I think this spam I just received is just out of line.</p><blockquote><div><p> <tt>From: GreatestColonHealth &lt;Kevin...@...by.com&gt;<br>Subject: With This Astounding Cleanser You May Eliminate Pudge</tt></p></div> </blockquote><p>That's just nasty!</p> petdance 2009-12-01T16:53:59+00:00 journal git-mtime http://use.perl.org/~BooK/journal/39932?from=rss <p>Ever complained that on a checkout Git did not reset the <code>mtime</code> of your files to the date when they were commited?</p><p> My <a href="http://philippe.bruhat.net/">home page</a> is generated with Template Toolkit but a script stored in the <tt>post-receive</tt> hook. On a checkout Git only updates the files that have changed, so normally I can trust <tt>template.modtime</tt> to be correct and use it to show a <i>Last mofidied</i> date. </p><p>But I'm a perfectionist, and I want to be extra sure. So I created this little utility, that I called <b>git-mtime</b>:</p><blockquote><div><p> <tt>&nbsp; &nbsp; #!/bin/sh<br>&nbsp; &nbsp; git log --name-only --date=iso --reverse --pretty=format:%at "$@" \<br>&nbsp; &nbsp; | perl -00ln -e '($d,@f)=split/\n/;$d{$_}=$d for grep{-e}@f' \<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;-e '}{utime undef,$d{$_},$_ for keys%d'</tt></p></div> </blockquote><p>Note that it passes all parameters to <code>git log</code>, so you can apply it on a subdirectory (using <code>--</code>), or even use the dates from another branch (though I'm not sure what use this can have).</p><p> <small>And for extra bonus points, it uses the secret eskimo greeting operator!</small> </p><p>Now that I have a few gadgets based on Git, I thought I might as well publish them somewhere. A quick look on Github ruled out <b>git-tools</b>, <b>git-utils</b> and <b>git-extras</b> (come on people, most of these things could be done with Git aliases!). <b>git-aid</b> (especially the plural) didn't seem like a good name either. So after looking around for synonyms, I settled on <b>git-gadgets</b>.</p><p>Clone it from <a href="http://github.com/book/git-gadgets">http://github.com/book/git-gadgets</a>.</p> BooK 2009-11-23T12:41:17+00:00 journal Perl 5.11.2 http://use.perl.org/~acme/journal/39925?from=rss <div><p>&#160; The streets were pretty quiet, which was nice. They&#39;re always quiet here<br>&#160; at that time: you have to be wearing a black jacket to be out on the<br> &#160; streets between seven and nine in the evening, and not many people in the<br> &#160; area have black jackets. It&#39;s just one of those things. I currently live<br> &#160; in Colour Neighbourhood, which is for people who are heavily into colour.<br> &#160; All the streets and buildings are set for instant colourmatch: as you<br> &#160; walk down the road they change hue to offset whatever you&#39;re wearing.<br> &#160; When the streets are busy it&#39;s kind of intense, and anyone prone to<br> &#160; epileptic seizures isn&#39;t allowed to live in the Neighbourhood, however<br> &#160; much they&#39;re into colour.<br> &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160; &#160;- Michael Marshall Smith, &quot;Only Forward&quot; </p><p> It gives me great pleasure to announce the release of Perl 5.11.2. </p><p> This is the third DEVELOPMENT release in the 5.11.x series leading to a stable release of Perl 5.12.0. You can find a list of high-profile changes in this release in the file &quot;perl5112delta.pod&quot; inside the distribution. </p><p> You can download the 5.11.2 release from: </p><p>&#160;&#160; <a href="http://search.cpan.org/~lbrocard/perl-5.11.2/">http://search.cpan.org/~lbrocard/perl-5.11.2/</a> </p><p> The release&#39;s SHA1 signatures are: </p><p>&#160;&#160; 2988906609ab7eb00453615e420e47ec410e0077 &#160;perl-5.11.2.tar.gz</p><div><p>&#160;&#160; 0014442fdd0492444e1102e1a80089b6a4649682 &#160;perl-5.11.2.tar.bz2<br> <br> We welcome your feedback on this release. If you discover issues with Perl 5.11.2, please use the &#39;perlbug&#39; tool included in this distribution to report them. If Perl 5.11.2 works well for you, please use the &#39;perlthanks&#39; tool included with this distribution to tell the all-volunteer development team how much you appreciate their work.<br> <br> If you write software in Perl, it is particularly important that you test your software against development releases. While we strive to maintain source compatibility with prior stable versions of Perl wherever possible, it is always possible that a well-intentioned change can have unexpected consequences. If you spot a change in a development version which breaks your code, it&#39;s much more likely that we will be able to fix it before the next stable release. If you only test your code against stable releases of Perl, it may not be possible to undo a backwards-incompatible change which breaks your code.<br> <br> Notable changes in this release:</p><ul> <li> It is now possible to overload the C operator</li><li> Extension modules can now cleanly hook into the Perl parser to define new kinds of keyword-headed expression and compound statement</li><li> The lowest layers of the lexer and parts of the pad system now have C APIs available to XS extensions</li><li> Use of C&lt;:=&gt; to mean an empty attribute list is now deprecated</li></ul><p> Perl 5.11.2 represents approximately 3 weeks development since Perl 5.11.1 and contains 29,992 lines of changes across 458 files from 38 authors and committers:<br> <br> Abhijit Menon-Sen, Abigail, Ben Morrow, Bo Borgerson, Brad Gilbert, Bram, Chris Williams, Craig A. Berry, Daniel Frederick Crisman, Dave Rolsky, David E. Wheeler, David Golden, Eric Brine, Father Chrysostomos, Frank Wiegand, Gerard Goossen, Gisle Aas, Graham Barr, Harmen, H.Merijn Brand, Jan Dubois, Jerry D. Hedden, Jesse Vincent, Karl Williamson, Kevin Ryde, Leon Brocard, Nicholas Clark, Paul Marquess, Philippe Bruhat, Rafael Garcia-Suarez, Sisyphus, Steffen Mueller, Steve Hay, Steve Peters, Vincent Pit, Yuval Kogman, Yves Orton, and Zefram.<br> <br> Many of the changes included in this version originated in the CPAN modules included in Perl&#39;s core. We&#39;re grateful to the entire CPAN community for helping Perl to flourish.<br> <br> Jesse Vincent or a delegate will release Perl 5.11.3 on December 20, 2009. Ricardo Signes will release Perl 5.11.4 on January 20, 2010. Steve Hay will release Perl 5.11.5 on February 20, 2010.<br> <br> Regards, L&#233;on</p></div></div> acme 2009-11-21T08:56:15+00:00 journal Git fractals http://use.perl.org/~BooK/journal/39919?from=rss <p> Last week (November 11) over dinner in Amsterdam, I talked with a colleague about Git as a tool for creating graphs. For some reason I started to think about a <a href="http://en.wikipedia.org/wiki/Sierpinski_triangle">Sierpir&#324;ski triangle</a>, and we started trying to create such graphs with Git. </p><p>The basic shape is a triangle (in the UTF-8 drawing below, the arrows represent the parent &#8594; child relationship):</p><p> <code>&nbsp;&nbsp;&nbsp;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;</code> </p><p>It is quite easy to create by hand. I did it using <code>git commit-tree</code>, using always the same tree object (the empty tree), as we only care about the graph that represents commit lineage, not about the content.</p><p>The next step basically repeats the same shape, attached to the low-level nodes / commits of the previous graph:</p><p> <code>&nbsp;&nbsp;&nbsp;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;</code> </p><p>I could create it in a couple of minutes, with a few more <code>git commit-tree</code> commands.</p><p>After that, it stops being interesting to do by hand, and one wants to program it. My goal has been to create the following shape, and larger ones, using a Perl program.</p><p> <code>&nbsp;&nbsp;&nbsp;A<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp;<br> &nbsp;&nbsp;B&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#215;&nbsp;&#8594;&nbsp;&#8901;&nbsp;C<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#8901;<br> &nbsp;&nbsp;&nbsp;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp;&#8595;&nbsp;&#8600;&nbsp; <br> &nbsp;&nbsp;&nbsp;&nbsp;&#8901;&nbsp;&#8594;&nbsp;&#215;&nbsp;&#8594;&nbsp;&#215;&nbsp;&#8594;&nbsp;&#215;&nbsp;&#8594;&nbsp;&#8901;</code> </p><p>Until now, I've been trying several recursive approaches, and failed miserably each time. The big issue is the merge points, showed in the graph above using &#215;.</p><p>In my recursive approaches, I usually first created the triangle (ABC), usually and then started again from B and then C. But the last merge of B (the &#215; in the middle of the bottom line) can only be created once the vertical line starting from C has been started. I should probably keep state in some way, but haven't had much time to spend on this.</p><p> I also thought about using the mapping from <a href="http://en.wikipedia.org/wiki/Pascal's_triangle">Pascal's triangle</a> (odd numbers as dots and even numbers as empty space, see both Wikipedia pages for details), but haven't actually tried it yet. </p><p> In other news, I've started to take care of my personal web site again. <a href="http://web.archive.org/web/20071217011738/http://www.bruhat.net/">It hadn't been touched since 2002</a>, so <a href="http://philippe.bruhat.net/">I gave it a facelift</a>. Surprisingly enough, the only section yet is about <a href="http://philippe.bruhat.net/stuff/git-fractals/">Git fractals</a>.<nobr> <wbr></nobr><code>;-)</code> Links to Git repositories, GraphViz images and more successful attempts with other fractals are also available there. </p> BooK 2009-11-20T00:43:58+00:00 journal www.perl.org - redesign http://use.perl.org/~Ranguard/journal/39888?from=rss <p> Well, it's taken me 6 weeks of evenings and the odd weekend, but I'm proud to say the new <a href="http://www.perl.org/">http://www.perl.org/</a> site has just gone live. </p><p> This is a complete redesign and content review. Hopefully it's cleaner and easier for people to actually get the information they are after. </p><p> Whilst I was at it I also implemented this skin for <a href="http://dbi.perl.org/">http://dbi.perl.org/</a> and <a href="http://learn.perl.org/">http://learn.perl.org/</a> (which needs a lot more loving now you can actually see what's there... not much). </p><p> My work (<a href="http://www.foxtons.co.uk/">http://www.foxtons.co.uk/</a>) have donated some of my time, and also some of the designers on my team's time, without which it would have taken even longer. </p><p> So enjoy! </p> Ranguard 2009-11-12T22:33:25+00:00 journal git-dot http://use.perl.org/~BooK/journal/39887?from=rss <p>I'm currently experimenting with creating graphs using Git... I'm not using historical data, or even data at all (I'll soon know the SHA1 of the empty tree by heart), just nodes with <code>%s</code> as their label (I have yet to find a use for the rest of the metadata).</p><p> <b>gitk</b> is nice to look at historical information, but not so good for graphs. On the other hand, GraphViz is great for showing graphs.</p><p>What's best than Perl (and a tiny wrapping of shell on top) to produce graphs?</p><blockquote><div><p> <tt>&nbsp; &nbsp; #!/bin/sh<br>&nbsp; &nbsp; # create a good looking graph with dot<br>&nbsp; &nbsp; echo "digraph G {"<br>&nbsp; &nbsp; git log --pretty=format:"%h %p" $* \<br>&nbsp; &nbsp; | perl -lna&nbsp; -e 'print qq("$F[0]";),map{qq("$_"-&gt;"$F[0]";)}@F[1..$#F]'<br>&nbsp; &nbsp; echo "}"</tt></p></div> </blockquote><p>The output of this is usually boring, so just but pipe it to <code>dot -Tpng -ograph.png</code> and watch the pretty pictures.</p><p>Also, imagine a graph that has a full filesystem attached to each node. This is exactly the kind of stuff that Git can give us.</p><p>Not that I have any idea what this could be used for...</p> BooK 2009-11-12T16:50:11+00:00 journal Maypole now Maint only http://use.perl.org/~TeeJay/journal/39877?from=rss <p>I've come to the conclusion that as I have neither the time nor inclination to spend my spare time working on Maypole, and I haven't used it for any paid work for several years, I won't be investing any more time on actively working on it.</p><p>However, I could be persuaded to work on it for a decent fee, and I would be happy to apply any patches applied and release new versions with fixes.</p><p>I'd also be happy to hand over the reins to anybody who wants to take over.</p><p>I do have a lot of ideas in this area, but family and work commitments mean that I'll more likely experiment on top of the newer frameworks that exist than try and rework Maypole beyond recognition.</p><p>I still think there is a large hole in the "market" for a more high-level app server than Catalyst, etc providing something more like Drupal in perl but I'm not entirely sure how to do it.</p><p>I guess I'll just see what happens, in the meantime I have plenty of other open source code I'm interested in and hacking on - from Autodia to Padre and Plack.</p> TeeJay 2009-11-11T10:16:27+00:00 journal nopaste http://use.perl.org/~BooK/journal/39862?from=rss <p>Just a quick post to show off a small and useful script I use whenever I need to "nopaste" some text or code:</p><blockquote><div><p> <tt>&nbsp; &nbsp; #!/usr/bin/perl -w<br>&nbsp; &nbsp; use strict;<br>&nbsp; &nbsp; use WWW::Mechanize;<br>&nbsp; &nbsp; use Getopt::Long;<br> <br>&nbsp; &nbsp; my %SITE = (<br>&nbsp; &nbsp; &nbsp; &nbsp; snit&nbsp; =&gt; 'http://nopaste.snit.ch/',<br>&nbsp; &nbsp; &nbsp; &nbsp; scsys =&gt; 'http://paste.scsys.co.uk/',<br>&nbsp; &nbsp; );<br> <br>&nbsp; &nbsp; my %CONF = (<br>&nbsp; &nbsp; &nbsp; &nbsp; channel =&gt; '',<br>&nbsp; &nbsp; &nbsp; &nbsp; nick&nbsp; &nbsp; =&gt; '',&nbsp; &nbsp; &nbsp; &nbsp;# use your own<br>&nbsp; &nbsp; &nbsp; &nbsp; summary =&gt; '',<br>&nbsp; &nbsp; &nbsp; &nbsp; paste&nbsp; &nbsp;=&gt; '',<br>&nbsp; &nbsp; &nbsp; &nbsp; site&nbsp; &nbsp; =&gt; 'snit',<br>&nbsp; &nbsp; &nbsp; &nbsp; list&nbsp; &nbsp; =&gt; '',<br>&nbsp; &nbsp; );<br> <br>&nbsp; &nbsp; GetOptions( \%CONF, 'lang=s', 'nick=s', 'summary|desc=s', 'paste|text=s',<br>&nbsp; &nbsp; &nbsp; &nbsp; 'list!', 'site=s' )<br>&nbsp; &nbsp; &nbsp; &nbsp; or die "Bad options";<br> <br>&nbsp; &nbsp; die "No such paste site: $CONF{site}\nValid choices: @{[keys %SITE]}\n"<br>&nbsp; &nbsp; &nbsp; &nbsp; if !exists $SITE{ $CONF{site} };<br> <br>&nbsp; &nbsp; my $m = WWW::Mechanize-&gt;new;<br>&nbsp; &nbsp; $m-&gt;get( $SITE{ $CONF{site} } );<br>&nbsp; &nbsp; die $m-&gt;res-&gt;status_line unless $m-&gt;success;<br> <br>&nbsp; &nbsp; if ( $CONF{list} ) {<br>&nbsp; &nbsp; &nbsp; &nbsp; print "Possible channels for $CONF{site}:\n",<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; map {"- $_\n"} grep $_,<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; $m-&gt;current_form()-&gt;find_input('channel')-&gt;possible_values;<br>&nbsp; &nbsp; &nbsp; &nbsp; exit;<br>&nbsp; &nbsp; }<br> <br>&nbsp; &nbsp; unless ( $CONF{paste} ) {<br>&nbsp; &nbsp; &nbsp; &nbsp; $CONF{summary} ||= $ARGV[0] || '-';<br>&nbsp; &nbsp; &nbsp; &nbsp; $CONF{paste} = join "", &lt;&gt;;<br>&nbsp; &nbsp; }<br> <br>&nbsp; &nbsp; delete @CONF{qw( site list )};<br>&nbsp; &nbsp; $m-&gt;set_fields(%CONF);<br>&nbsp; &nbsp; $m-&gt;submit;<br>&nbsp; &nbsp; die $m-&gt;res-&gt;status_line unless $m-&gt;success;<br> <br>&nbsp; &nbsp; print +( $m-&gt;links )[0]-&gt;url, "\n";</tt></p></div> </blockquote><p>Since it works has a filter, I can call it from vim or pipe to it. It also works with a file parameter, which is used to set the paste title.</p><p>Just before posting this, I looked again on CPAN, and found the follwing:</p><ul> <li> <p> <b>App::NoPaste</b>: Seems really complete. But does much more than I need, and I like depending only on WWW::Mechanize for such tools.</p></li><li> <p> <b>WWW::Rafb</b>: Well, in an earlier version my script worked with rafb.net, but the site itself is down.</p></li><li> <p> <b>WWW::PasteBin</b>: Such a huge collection of distributions, I wouldn't which to install first.</p></li><li> <p> <b>WebService::NoPaste</b>: Found it years ago when looking for a nopaste utility, but I preferred to write my own.</p></li></ul><p>Clearly, there is no lack of modules to nopaste stuff, so I'm not going to add my own to the list.<nobr> <wbr></nobr><code>:-)</code> </p><p>I tried publishing scripts on CPAN, but I feel the toolchain is not really targetting scripts, anyway. Anyway, I have a few utility scripts like the above lying around, and I'm thinking maybe the best way to go with them nowadays is to just publish them on GitHub. Might happen someday.</p> BooK 2009-11-08T16:34:56+00:00 journal OOPSLA 2009 http://use.perl.org/~acme/journal/39846?from=rss <div><p> <a href="http://www.oopsla.org/oopsla2009/">OOPSLA 2009</a> happened a few weeks ago. OOPSLA stands for Object-Oriented Programming, Systems, Languages &amp; Applications and I&#39;ve always been quite interested in the conference. The proceedings of the conference aren&#39;t put online, but I&#39;ve managed to find two interesting papers:</p><p> <a href="http://www.eecs.harvard.edu/~malvika/ons00025-bacon.pdf">A Market-Based Approach to Software Evolution</a> (PDF) tries to imagine an open market which is targetted around fixing bugs and improving software. It&#39;s quite interesting as it&#39;s quite similar to a proposal from Nicholas on <a href="http://www.nntp.perl.org/group/perl.perl5.porters/2009/05/msg146785.html">spending other people&#39;s money</a>. The authors point out many potential flaws.</p><p> <a href="http://dirkriehle.com/wp-content/uploads/2009/08/oni0017-arafat.pdf">The Commenting Practice of Open Source</a> (PDF) analyses projects on <a href="http://www.ohloh.net/">Ohloh</a> and tries to spot commenting trends. &quot;We find that comment density is independent of team and project size&quot;, but they find that it varies from language to language. &quot;Java has the highest mean of comment lines per source lines at.. one comment line for three source code lines&quot; and &quot;Perl has the lowest mean with.. one comment line for nine source code lines&quot;. They list as future work to find out why this might be the case.</p></div> acme 2009-11-05T08:41:53+00:00 journal buildperl.pl http://use.perl.org/~BooK/journal/39818?from=rss <p>I'm trying to compile a bunch of old perls to test my modules against them. I started with 5.8.9, and it went like this:</p><blockquote><div><p> <tt>&nbsp; &nbsp; $ git checkout -f perl-5.8.9<br>&nbsp; &nbsp; [git output]<br>&nbsp; &nbsp; $ git clean -xdf<br>&nbsp; &nbsp; [more git output]<br>&nbsp; &nbsp; $ sh Configure -Dprefix=/opt/perl/5.8.9 -des -Uinstallusrbinperl<br>&nbsp; &nbsp; [Configure output]<br>&nbsp; &nbsp; $ make &amp;&amp; make test &amp;&amp; make install<br>&nbsp; &nbsp; [make output]<br>&nbsp; &nbsp; [test output]<br>&nbsp; &nbsp; [install output]</tt></p></div> </blockquote><p>And, ta-da! After less than 15 minutes, Perl 5.8.9 was in<nobr> <wbr></nobr><i>/opt/perl/</i>, ready to be used.</p><p>Encouraged by this, I went on to compile 5.8.8. I was a bit disappointed when the same procedure (after a <code>s/5.8.8/5.8.9/g</code>) failed with:</p><blockquote><div><p> <tt>&nbsp; &nbsp; $ sh Configure -Dprefix=/opt/perl/5.8.8 -des -Uinstallusrbinperl<br>&nbsp; &nbsp; [Configure output]<br>&nbsp; &nbsp; Run make depend now? [y]<br>&nbsp; &nbsp; sh<nobr> <wbr></nobr>./makedepend MAKE=make<br>&nbsp; &nbsp; make[1]: Entering directory `/data/home/book/src/ext/perl'<br>&nbsp; &nbsp; sh writemain lib/auto/DynaLoader/DynaLoader.a&nbsp; &gt; perlmain.c<br>&nbsp; &nbsp; rm -f opmini.c<br>&nbsp; &nbsp; cp op.c opmini.c<br>&nbsp; &nbsp; echo&nbsp; av.c scope.c op.c doop.c doio.c dump.c hv.c mg.c reentr.c perl.c perly.c pp.c pp_hot.c pp_ctl.c pp_sys.c regcomp.c regexec.c utf8.c gv.c sv.c taint.c toke.c util.c deb.c run.c universal.c xsutils.c pad.c globals.c perlio.c perlapi.c numeric.c locale.c pp_pack.c pp_sort.c miniperlmain.c perlmain.c opmini.c | tr ' ' '\n' &gt;.clist<br>&nbsp; &nbsp; make[1]: Leaving directory `/data/home/book/src/ext/perl'<br>&nbsp; &nbsp;<nobr> <wbr></nobr>./makedepend: 1: Syntax error: Unterminated quoted string<br>&nbsp; &nbsp; make: *** [depend] Error 2<br> <br>&nbsp; &nbsp; If you compile perl5 on a different machine or from a different object<br>&nbsp; &nbsp; directory, copy the Policy.sh file from this object directory to the<br>&nbsp; &nbsp; new one before you run Configure -- this will help you with most of<br>&nbsp; &nbsp; the policy defaults.</tt></p></div> </blockquote><p>In the past, I had tried to compile older Perls, and S&#233;bastien Aperghis-Tramoni had pointed me to a few patches he had made to be able to compile 5.004_05 with a more recent (3.x) gcc.</p><p>So, by looking at his patch again and the output of <code>git diff perl-5.8.8 perl-5.8.9 -- makedepend.SH</code> I was able to produce a patch, that looked exactaly like S&#233;bastien's patches for 5.004_05. The <code>Configure</code> step now worked!</p><p>But then it's the compilation phase that failed:</p><blockquote><div><p> <tt>&nbsp; &nbsp; $ make<br>&nbsp; &nbsp; [make output]<br>&nbsp; &nbsp; &nbsp; &nbsp; Making IPC::SysV (dynamic)<br>&nbsp; &nbsp; Checking if your kit is complete...<br>&nbsp; &nbsp; Looks good<br>&nbsp; &nbsp; Writing Makefile for IPC::SysV<br>&nbsp; &nbsp; make[1]: Entering directory `/data/home/book/src/ext/perl/ext/IPC/SysV'<br>&nbsp; &nbsp; make[1]: Leaving directory `/data/home/book/src/ext/perl/ext/IPC/SysV'<br>&nbsp; &nbsp; make[1]: Entering directory `/data/home/book/src/ext/perl/ext/IPC/SysV'<br>&nbsp; &nbsp; cp Msg.pm<nobr> <wbr></nobr>../../../lib/IPC/Msg.pm<br>&nbsp; &nbsp; cp Semaphore.pm<nobr> <wbr></nobr>../../../lib/IPC/Semaphore.pm<br>&nbsp; &nbsp; cp SysV.pm<nobr> <wbr></nobr>../../../lib/IPC/SysV.pm<br>&nbsp; &nbsp;<nobr> <wbr></nobr>../../../miniperl "-I../../../lib" "-I../../../lib"<nobr> <wbr></nobr>../../../lib/ExtUtils/xsubpp&nbsp; -typemap<nobr> <wbr></nobr>../../../lib/ExtUtils/typemap&nbsp; SysV.xs &gt; SysV.xsc &amp;&amp; mv SysV.xsc SysV.c<br>&nbsp; &nbsp; cc -c&nbsp; &nbsp;-fno-strict-aliasing -pipe -Wdeclaration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2&nbsp; &nbsp;-DVERSION=\"1.04\" -DXS_VERSION=\"1.04\" -fpic "-I../../.."&nbsp; &nbsp;SysV.c<br>&nbsp; &nbsp; SysV.xs:7:25: error: asm/page.h: No such file or directory<br>&nbsp; &nbsp; make[1]: *** [SysV.o] Error 1<br>&nbsp; &nbsp; make[1]: Leaving directory `/data/home/book/src/ext/perl/ext/IPC/SysV'<br>&nbsp; &nbsp; make: *** [lib/auto/IPC/SysV/SysV.so] Error 2</tt></p></div> </blockquote><p>This looked a bit trickier. Luckily, Google informed me that the <i>asm/page.h</i> file had moved in the Linux tree. Using git again, I looked for changes involving <code>page.h</code>. The changes were a lot bigger, and harder for me to understand.</p><p>By chance, the first interesting diff I found was for a change in <i>ext/Devel/PPPort/devel/buildperl.pl</i>. Wow, this looked exactly like the tool I needed to, erm, <i>build perl</i>.</p><p>So instead of adding complexity to my home-made perl-building script by adding more cases where a patch was necessary, I tried my hand at patching <b>buildperl.pl</b> to make it support newer gcc versions than the ones that existed at the time the older perls were written.</p><p>Looking for the proper patches with git is extremely easy, and I was quickly able to find the necessary patches. The longer part was to actually compile all Perls from 5.6.0 to 5.9.5.<nobr> <wbr></nobr><code>:-)</code> </p><p>Since buildperl.pl works with perl archives, my test script ended up like this:</p><blockquote><div><p> <tt>&nbsp; &nbsp; #!/bin/sh<br> <br>&nbsp; &nbsp; # blead has my local patch<br>&nbsp; &nbsp; git checkout blead<br>&nbsp; &nbsp; git clean -xdf<br> <br>&nbsp; &nbsp; # setup temporary directories<br>&nbsp; &nbsp; rm<nobr> <wbr></nobr>/tmp/buildperl.log<br>&nbsp; &nbsp; rm -rf<nobr> <wbr></nobr>/tmp/perl<br>&nbsp; &nbsp; mkdir<nobr> <wbr></nobr>/tmp/perl<br>&nbsp; &nbsp; mkdir<nobr> <wbr></nobr>/tmp/perl/source<br> <br>&nbsp; &nbsp; # compile and test all the tags given on command-line<br>&nbsp; &nbsp; for tag in $* ; do<br> <br>&nbsp; &nbsp; &nbsp; &nbsp; # get the version<br>&nbsp; &nbsp; &nbsp; &nbsp; version=`echo $tag|cut -d- -f 2`<br> <br>&nbsp; &nbsp; &nbsp; &nbsp; # make a tarball<br>&nbsp; &nbsp; &nbsp; &nbsp; echo "=== creating<nobr> <wbr></nobr>/tmp/perl/source/perl-$version.tar.gz"<br>&nbsp; &nbsp; &nbsp; &nbsp; git archive --format=tar --prefix=$tag/ $tag^{tree} \<br>&nbsp; &nbsp; &nbsp; &nbsp; | gzip &gt;<nobr> <wbr></nobr>/tmp/perl/source/$tag.tar.gz<br> <br>&nbsp; &nbsp; &nbsp; &nbsp; perl cpan/Devel-PPPort/devel/buildperl.pl --config default --perl $version --test<br> <br>&nbsp; &nbsp; &nbsp; &nbsp; # check it was installed correctly<br>&nbsp; &nbsp; &nbsp; &nbsp; if [ -d<nobr> <wbr></nobr>/tmp/perl/install/default/$tag/ ] ; then<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; result="ok"<br>&nbsp; &nbsp; &nbsp; &nbsp; else<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; result="not ok"<br>&nbsp; &nbsp; &nbsp; &nbsp; fi<br>&nbsp; &nbsp; &nbsp; &nbsp; echo "$result - $version" &gt;&gt;<nobr> <wbr></nobr>/tmp/buildperl.log<br> <br>&nbsp; &nbsp; done</tt></p></div> </blockquote><p>Then I just fed it with the appropriate git tags, and let it run for a while:</p><blockquote><div><p> <tt>&nbsp; &nbsp; $<nobr> <wbr></nobr>./compile_perl `git tag -l 'perl-5.8*'`</tt></p></div> </blockquote><p>So within one and a half hour, I was able to compile, test and install all the 5.8.x versions of Perl.</p><p>I already have added the changes that allow 5.6.x, 5.8.x and 5.9.x to compile again in modern environments, and just sent the patches to P5P and Marcus Holland-Moritz.</p><p>Eventually, I'll work on adding the needed patches for versions 5.004, 5.005, and send another patch batch.</p> BooK 2009-10-29T20:44:04+00:00 journal Switching perls http://use.perl.org/~BooK/journal/39786?from=rss <p> I have a few perls compiled and installed in<nobr> <wbr></nobr><tt>/opt/perl</tt>: </p><blockquote><div><p> <tt>$ ls<nobr> <wbr></nobr>/opt/perl<br>5.10.0&nbsp; 5.6.2&nbsp; 5.8.7&nbsp; 5.8.8</tt></p></div> </blockquote><p> A long time ago, I tried to set up an environment that would setup the proper PATH to always reach the perl I wanted when typing <tt>perl</tt> on the command-line. That involved a shell script, which of course couldn't change the environment of the outer shell, so it actually started another shell, resulting in the following mess: </p><blockquote><div><p> <tt>5271 pts/2&nbsp; &nbsp; Ss&nbsp; &nbsp; &nbsp;0:01 bash<br>6182 pts/2&nbsp; &nbsp; S&nbsp; &nbsp; &nbsp; 0:00&nbsp; \_<nobr> <wbr></nobr>/bin/bash<nobr> <wbr></nobr>./perlenv 5.10.0<br>6183 pts/2&nbsp; &nbsp; S&nbsp; &nbsp; &nbsp; 0:00&nbsp; &nbsp; &nbsp; \_<nobr> <wbr></nobr>/bin/bash</tt></p></div> </blockquote><p> I could also have moved a canonical symlink around, but this had the advantage that several independent shells could run different perls. </p><p> Anyway, that was unworkable until I realized I could change the current shell environment using aliases or shell functions. So, assuming my perl binaries live in<nobr> <wbr></nobr><tt>/opt/perl/$VERSION/bin</tt>, the following bash shell function does the trick: </p><blockquote><div><p> <tt>setperl ()<br>{<br>&nbsp; &nbsp; export PATH=`echo $PATH|sed -e "s:/opt/perl/[^/]*/bin:/opt/perl/$1/bin:"`<br>}</tt></p></div> </blockquote><p> And my <tt>~/.bashrc</tt> points to the perl I want to use by default. </p> BooK 2009-10-22T08:13:55+00:00 journal