[PD] missing link
geiger at epy.co.at
Wed May 16 09:13:22 CEST 2001
with Windows, it isn't sufficient for a function to not be static in order
to be called from within a dxnamic library. You have to declare the
function as extern, (see all the EXTERN keywords in m_pd.h).
So you need something like
EXTERN sigsqrt_perfom(..) in m_pd.h and recompile pd, otherwise pd won't
export the function to your external .. (I would rather copy paste
sigsqrt_perfomr into my external .. this way everyone could use it
without recompiling pd).
On Tue, 15 May 2001, Iain Mott wrote:
> Hello all
> Im trying to compile some of my linux externals in windows Im having
> linking troubles with some of my code that uses sigsqrt_perform (a
> non-static function from d_math.c) keep getting an unresolved external
> Im trying to compile & link the externals in a single library and Im using
> the following in my makefile:
> cl $(PDNTCFLAGS) $(PDNTINCLUDE) /c $*.c
> link /dll /export:$*_setup $*.obj $(PDNTLIB)
> where PDNTLIB = $(PDNTLDIR)\libc.lib \
> $(PDNTLDIR)\oldnames.lib \
> $(PDNTLDIR)\kernel32.lib \
> Have been using the extern specifier in the main setup function (the one
> that calls all the other *_setups for the individual objects) but still
> no luck.
> Any suggestions?
> Cheers, iain
> Iain Mott
> phone: +61 3 9639 2959
> email: mott at reverberant.com
More information about the Pd-list