<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"></head><body ><div><br></div><div>I dont see the point of getting pd dir since we can run several instances of same bin with the shell.</div><div><br></div><div><br></div><div><br></div><div><br></div><div><div style="font-size:100%">Patrice Colet&nbsp;</div></div> <br><br><br>-------- Message d'origine --------<br>De : Jonathan Wilkes &lt;jancsika@yahoo.com&gt; <br>Date : 30/07/2013  19:43  (GMT+00:00) <br>A : pd-list@iem.at <br>Objet : Re: [PD] get dir of current pd <br> <br><br>On 07/30/2013 07:48 AM, yvan volochine wrote:<br>&gt; On 30/07/13 08:41, Jonathan Wilkes wrote:<br>&gt;&gt; Ok, I figured out how to do this<br>&gt;<br>&gt; and how do you do?<br><br>In GNU/Linux on some _distros_ you can check the symlink<br>/proc/self/exe<br><br>If you do a readink from within C in Pd you'll get the absolute<br>path and name of the executable.<br><br>However, if you use the command "readlink" to [shell] I imagine<br>the readlink binary will look in the mirror and give you its own<br>name back.<br><br>I don't think /proc/self/exe is a requirement of all Linux flavors,<br>and I don't know what the BSD OSes do, or OSX.&nbsp; So I'm reluctant<br>to add this to [pdinfo].<br><br>Windows has its own function accessible from C to return the full<br>path and name of the executable.<br><br>-Jonathan<br><br>&gt;<br>&gt; y<br>&gt;<br><br><br>_______________________________________________<br>Pd-list@iem.at mailing list<br>UNSUBSCRIBE and account-management -&gt; http://lists.puredata.info/listinfo/pd-list<br></body>