[PD-dev] path for embedded examples

Roman Haefeli reduzierer at yahoo.de
Mon Apr 12 09:43:12 CEST 2010


On Mon, 2010-04-12 at 09:33 +0200, Frank Barknecht wrote:
> On Sat, Apr 10, 2010 at 11:01:22PM +0200, Roman Haefeli wrote:
> > On Sat, 2010-04-10 at 13:25 -0400, Hans-Christoph Steiner wrote:
> > > Part of the idea of a libdir is to also include examples.  Currently,  
> > > this is done using an 'examples' subfolder.  The problem with that is  
> > > the example patches won't automatically find the objects from the  
> > > libdir that they are embedded in. So I'm wondering what the best way  
> > > to handle this is.  Here are a couple ideas:
> > > 
> > > - require [declare -path ..] for all example patches (works on any  
> > > branch of Pd)
> > > 
> > > - instead of 'examples' folder, use mypatch-example.pd in the main dir  
> > > of the libdir (works without extra tricks)
> > > 
> > > - use [import mylib] for all example patches (works even when the  
> > > example patch is saved elsewhere)
> > 
> > - use [declare -stdpath extra/mylib] for all example patches (works on
> > any branch of Pd and works even when the example patch is saved
> > elsewhere)
> 
> I think, this doesn't work if "mylib" isn't installed or isn't installed in
> "extra". 

True. But since we're talking about example patches _coming with_
certain libraries, I think it does make sense to assume that the
original library is installed, and installed in "extra". 
Or am I missing something here?

Roman






More information about the Pd-dev mailing list