You forget something : faust2 deals with an intermediated FIR representation 
that is later translated to C, C++, LLVM, asm.js…etc.. This kind of code 
generation decision has to be done at FIR level and has later to "make sense" 
for each backend with its own logic. So adding this « static » if not the right 
way to do that, and this patch cannot be applied in this form.

Sorry for that ((-;

Stéphane 



> Le 14 juin 2016 à 16:19, Kjetil Matheussen <k.s.matheus...@gmail.com> a écrit 
> :
> 
> It works for my use. Unless this patch brakes anything, it would
> be practical if it was applied so that I don't have to do it manually
> every time I upgrade faust2. I guess it's better than nothing?
> 
> 
> On Tue, Jun 14, 2016 at 4:13 PM, Stéphane Letz <l...@grame.fr> wrote:
> This «  multilple definitions of linker errors »   is a problem we are aware 
> of, but that is a bit more complex to solve in a clean way that this simple 
> patch….
> 
> Stéphane
> 
> 
> > Le 14 juin 2016 à 16:08, Kjetil Matheussen <k.s.matheus...@gmail.com> a 
> > écrit :
> >
> > The autogenerated "faustpowerN_f" functions in faust2 must
> > be declared static to avoid "multilple definitions of"
> > linker errors when linking several faust files.
> >
> > This solution seem to work:
> >
> > --- compiler/generator/code_container.cpp~    2016-06-08 13:36:37.000000000 
> > +0200
> > +++ compiler/generator/code_container.cpp    2016-06-14 16:00:43.959935889 
> > +0200
> > @@ -286,7 +286,7 @@
> >              }
> >          }
> >
> > -        pushGlobalDeclare(InstBuilder::genDeclareFunInst(faust_power_name, 
> > InstBuilder::genFunTyped(named_args, result_type), block));
> > +        pushGlobalDeclare(InstBuilder::genDeclareFunInst("static " + 
> > faust_power_name, InstBuilder::genFunTyped(named_args, result_type), 
> > block));
> >
> >          list<ValueInst*> truncated_args;
> >          truncated_args.push_back((*args.begin()));
> >
> >
> > ...but I don't know if it's the best one.
> >
> > http://users.notam02.no/~kjetism/code_container.cpp.diff
> >
> > ------------------------------------------------------------------------------
> > What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
> > patterns at an interface-level. Reveals which users, apps, and protocols are
> > consuming the most bandwidth. Provides multi-vendor support for NetFlow,
> > J-Flow, sFlow and other flows. Make informed decisions using capacity
> > planning reports. 
> > https://ad.doubleclick.net/ddm/clk/305295220;132659582;e_______________________________________________
> > Faudiostream-devel mailing list
> > Faudiostream-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/faudiostream-devel
> 
> 


------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity 
planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e
_______________________________________________
Faudiostream-devel mailing list
Faudiostream-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-devel

Reply via email to