On 01/15/2016 11:12 AM, Roman Haefeli wrote: > On Wed, 2016-01-13 at 00:54 +0100, IOhannes m zmölnig wrote: >> On 01/12/2016 11:56 PM, IOhannes m zmölnig wrote: >>> On 01/12/2016 11:34 PM, IOhannes m zmölnig wrote: >>>> i will check this immediately. >>> >>> actually it turns out that loading anything via it's absolute path is >>> broken (and [declare -stdlib] uses this): >>> >>> e.g. [/usr/lib/pd/extra/zexy/zexy] fails now. >> >> which means that the culprit is really in the new loader code (unrelated >> to [declare]). >> >> anyhow, attached you find two patches that supposedly fix this problem. >> >> 0001: does special handling for absolute paths (which was stripped out >> in my loader rewrite - on purpose, but accidentally no replacement was >> provided), by trying to load them first (if applicable). >> >> 0002: fixes the extra/ stripping/appending when generating the absolute >> pathnames for stdlib/stdpath. > > Thanks for the fix(es). [declare -stdlib] works again for me. > > Unlike specified in the help, -lib now searches both, relative to the > patch _and_ standard paths, while -stdlib only searches standard paths > and is in accordance to the documentation. Is that intended?
i think so. i cannot think of a reason why it should be different. > > The immediate effect of [declare] is a great advancement. Thanks for > working on that! great that you like it. > > [declare] used to add a line to the beginning of the patch file, like: > > #X declare -stdlib zexy; > > I assumed this was added so that on next load of the patch it takes > effect before the rest of the patch was loaded. yes. > Now that [declare] has > immediate effect, is that line still necessary? yes. when you do interactive patching, you don't expect a [declare -lib zexy] that you haven't created yet to take an effect. but when loading an abstraction containing [declare -lib zexy] you want it to be able to use the zexy objects, regardless of when the [declare] object gets instantiated. (imagine: you have added "-lib zexy" to your startup flags, so *you* don't really need [declare -lib zexy]; now you create an abstraction that uses [list2sybmol]; then you remember that you should declare a dependency (for other users) and add the [declare] object) the "line at the beginning of the patch" takes care of this. > It seems it is (when > removing it, the loading doesn't happen anymore), but why? because you don't want to load the library multiple times. > I'm asking > because when using [declare] in abstractions, those lines "pollute" the > parent patch. do they? afaict d76b2e (or my original 2nd part of the patch, which was somehow forgotten) has fixed this. gfmsdr IOhannes
signature.asc
Description: OpenPGP digital signature
_______________________________________________ Pd-dev mailing list [email protected] http://lists.puredata.info/listinfo/pd-dev
