<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: Bad AnyEvent Install</title>
	<atom:link href="http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/feed/" rel="self" type="application/rss+xml" />
	<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/</link>
	<description>Leveraging Perl and Emacs</description>
	<lastBuildDate>Tue, 07 May 2013 11:25:25 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
	<item>
		<title>By: schmorp</title>
		<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/#comment-8688</link>
		<dc:creator><![CDATA[schmorp]]></dc:creator>
		<pubDate>Tue, 14 Dec 2010 15:47:59 +0000</pubDate>
		<guid isPermaLink="false">http://curiousprogrammer.wordpress.com/?p=836#comment-8688</guid>
		<description><![CDATA[Indeed, this is not a bug in AnyEvent - compiling a module on a different operating only works by pure chance. A module doesn&#039;t need to contain any C code to be architecture-dependent.

While there are ways to redefine WIN32 so that AnyEvent sees it, this does nothing to the other constants, which are likely to be very different.

The only correct method is to not share arch-dependent modules between operating systems (you wouldn&#039;t expect the perl binary from unix to run under windows, either...)]]></description>
		<content:encoded><![CDATA[<p>Indeed, this is not a bug in AnyEvent &#8211; compiling a module on a different operating only works by pure chance. A module doesn&#8217;t need to contain any C code to be architecture-dependent.</p>
<p>While there are ways to redefine WIN32 so that AnyEvent sees it, this does nothing to the other constants, which are likely to be very different.</p>
<p>The only correct method is to not share arch-dependent modules between operating systems (you wouldn&#8217;t expect the perl binary from unix to run under windows, either&#8230;)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jared</title>
		<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/#comment-7896</link>
		<dc:creator><![CDATA[Jared]]></dc:creator>
		<pubDate>Wed, 28 Apr 2010 21:47:08 +0000</pubDate>
		<guid isPermaLink="false">http://curiousprogrammer.wordpress.com/?p=836#comment-7896</guid>
		<description><![CDATA[@zloyrusskiy - thanks for the solution it looks good.  I still don&#039;t think I would say there is a bug in AnyEvent despite the fact it is solvable.  Installing on one Perl on Unix and expecting it to work on a Windows Perl is a little unreasonable.  What do you think?

Anyway, I&#039;ll get your solution off to Marc and see if he wants to incorporate it into a later version.

@juster - gosh, that solution looks complicated.  First good chance to use require hooks eh? :)  I&#039;ll have to look at it in detail to understand it.]]></description>
		<content:encoded><![CDATA[<p>@zloyrusskiy &#8211; thanks for the solution it looks good.  I still don&#8217;t think I would say there is a bug in AnyEvent despite the fact it is solvable.  Installing on one Perl on Unix and expecting it to work on a Windows Perl is a little unreasonable.  What do you think?</p>
<p>Anyway, I&#8217;ll get your solution off to Marc and see if he wants to incorporate it into a later version.</p>
<p>@juster &#8211; gosh, that solution looks complicated.  First good chance to use require hooks eh? <img src='http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />   I&#8217;ll have to look at it in detail to understand it.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: zloyrusskiy</title>
		<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/#comment-7895</link>
		<dc:creator><![CDATA[zloyrusskiy]]></dc:creator>
		<pubDate>Wed, 28 Apr 2010 16:52:38 +0000</pubDate>
		<guid isPermaLink="false">http://curiousprogrammer.wordpress.com/?p=836#comment-7895</guid>
		<description><![CDATA[I checked my example, it works.

Your example is good, but hard.

use lib qw(author_path_to_AnyEvent\constants.pl);
use AnyEvent;
no lib qw(author_path_to_AnyEvent\constants.pl);

I was checked this it works.]]></description>
		<content:encoded><![CDATA[<p>I checked my example, it works.</p>
<p>Your example is good, but hard.</p>
<p>use lib qw(author_path_to_AnyEvent\constants.pl);<br />
use AnyEvent;<br />
no lib qw(author_path_to_AnyEvent\constants.pl);</p>
<p>I was checked this it works.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: juster</title>
		<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/#comment-7894</link>
		<dc:creator><![CDATA[juster]]></dc:creator>
		<pubDate>Wed, 28 Apr 2010 16:38:59 +0000</pubDate>
		<guid isPermaLink="false">http://curiousprogrammer.wordpress.com/?p=836#comment-7894</guid>
		<description><![CDATA[Oh whoops I see now that AnyEvent isn&#039;t using constant.pm so my code isn&#039;t very helpful!  :D

I find require hooks fascinating.  I have updated my gist so it would actually help you... But copy/paste is more straightforward and it&#039;s good to keep things simple!

re: zloyrusskiy
You forgot the constant prototype ie: sub WIN32 () { ... }

I&#039;m guessing this is why the constant.pl is generated in the first place.  If there is an if statement inside sub WIN32 () {} it will not be inlined.  Hence the if statement is converted to its result when creating the constant function.]]></description>
		<content:encoded><![CDATA[<p>Oh whoops I see now that AnyEvent isn&#8217;t using constant.pm so my code isn&#8217;t very helpful!  <img src='http://s0.wp.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
<p>I find require hooks fascinating.  I have updated my gist so it would actually help you&#8230; But copy/paste is more straightforward and it&#8217;s good to keep things simple!</p>
<p>re: zloyrusskiy<br />
You forgot the constant prototype ie: sub WIN32 () { &#8230; }</p>
<p>I&#8217;m guessing this is why the constant.pl is generated in the first place.  If there is an if statement inside sub WIN32 () {} it will not be inlined.  Hence the if statement is converted to its result when creating the constant function.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: zloyrusskiy</title>
		<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/#comment-7893</link>
		<dc:creator><![CDATA[zloyrusskiy]]></dc:creator>
		<pubDate>Wed, 28 Apr 2010 08:27:36 +0000</pubDate>
		<guid isPermaLink="false">http://curiousprogrammer.wordpress.com/?p=836#comment-7893</guid>
		<description><![CDATA[I think constant.pl must define WIN32 sub like:

eval sprintf &#039;sub WIN32 { %s }&#039;,$^O eq &#039;MSWin32&#039;;
sub WIN32;

and there is no error in your case and no performance penalty to AnyEvent]]></description>
		<content:encoded><![CDATA[<p>I think constant.pl must define WIN32 sub like:</p>
<p>eval sprintf &#8216;sub WIN32 { %s }&#8217;,$^O eq &#8216;MSWin32&#8242;;<br />
sub WIN32;</p>
<p>and there is no error in your case and no performance penalty to AnyEvent</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jared</title>
		<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/#comment-7892</link>
		<dc:creator><![CDATA[Jared]]></dc:creator>
		<pubDate>Wed, 28 Apr 2010 06:38:05 +0000</pubDate>
		<guid isPermaLink="false">http://curiousprogrammer.wordpress.com/?p=836#comment-7892</guid>
		<description><![CDATA[Hi  zloyrusskiy,

I don&#039;t think this is a bug, at least not in AnyEvent.  It is an artefact that results from the slightly whacky way my firm installs perl modules.

And I don&#039;t have write access to the constants.pl file unfortunately.

Hi juster,

That is a cool solution.  My thought was the slightly more boring generate my own constants.pl file and make sure it was ahead of the real constant.pl in @INC (although I haven&#039;t tried that yet).]]></description>
		<content:encoded><![CDATA[<p>Hi  zloyrusskiy,</p>
<p>I don&#8217;t think this is a bug, at least not in AnyEvent.  It is an artefact that results from the slightly whacky way my firm installs perl modules.</p>
<p>And I don&#8217;t have write access to the constants.pl file unfortunately.</p>
<p>Hi juster,</p>
<p>That is a cool solution.  My thought was the slightly more boring generate my own constants.pl file and make sure it was ahead of the real constant.pl in @INC (although I haven&#8217;t tried that yet).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: juster</title>
		<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/#comment-7891</link>
		<dc:creator><![CDATA[juster]]></dc:creator>
		<pubDate>Wed, 28 Apr 2010 06:19:51 +0000</pubDate>
		<guid isPermaLink="false">http://curiousprogrammer.wordpress.com/?p=836#comment-7891</guid>
		<description><![CDATA[This problem intrigued me.  I always found it magical how you can override another module&#039;s symbol table entry, but the only module it will affect is your own!  I mean you only notice a difference if you call that changed symbol table entry (subroutine) from your module.

Anyways, the only way I could think of to bypass constants was for you to make a YOUR OWN constant.pm file and have it act as a proxy between the real constant.pm and everyone else.

Check out my gist: http://gist.github.com/381788
I finally got to use @INC hooks... the horror!  It&#039;s really funky but it works!]]></description>
		<content:encoded><![CDATA[<p>This problem intrigued me.  I always found it magical how you can override another module&#8217;s symbol table entry, but the only module it will affect is your own!  I mean you only notice a difference if you call that changed symbol table entry (subroutine) from your module.</p>
<p>Anyways, the only way I could think of to bypass constants was for you to make a YOUR OWN constant.pm file and have it act as a proxy between the real constant.pm and everyone else.</p>
<p>Check out my gist: <a href="http://gist.github.com/381788" rel="nofollow">http://gist.github.com/381788</a><br />
I finally got to use @INC hooks&#8230; the horror!  It&#8217;s really funky but it works!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: zloyrusskiy</title>
		<link>http://curiousprogrammer.wordpress.com/2010/04/27/bad-anyevent-install/#comment-7890</link>
		<dc:creator><![CDATA[zloyrusskiy]]></dc:creator>
		<pubDate>Wed, 28 Apr 2010 05:39:52 +0000</pubDate>
		<guid isPermaLink="false">http://curiousprogrammer.wordpress.com/?p=836#comment-7890</guid>
		<description><![CDATA[1. send bug report to developer
2. patch constants.pl]]></description>
		<content:encoded><![CDATA[<p>1. send bug report to developer<br />
2. patch constants.pl</p>
]]></content:encoded>
	</item>
</channel>
</rss>
