[PD] undefined symbol

IOhannes m zmoelnig zmoelnig at iem.at
Mon Nov 7 12:16:54 CET 2022


On 11/7/22 10:13, Alexandros wrote:
> I'm trying to make an external with the source being split in five 
> files, where all are included in the main file that creates the object. 
> This is someone else's code (given freely), not aimed at Pd, and I would 
> like to maintain this structure, rather than write everything in the 
> main file.
> 
> I'm using pdlibbuilder's Makefile and the compilation process succeeds 
> with a few warnings about unused parameters, but when I try to create 
> the object in Pd, I get the following error:
> 
> undefined symbol: set_char_to_indx
> 
> set_char_to_indx is a function defined in one of the files included in 
> the main file and it is used in one place in the main file. How can it 
> be solved?

hard to tell without more info.
if you write "included in the main file", what exactly does this mean?
is it only the header-file you are "#include"ing?
if so, you must also compile the C file where 'set_char_to_indx' is 
implemented and then link it into the final binary (external).

the simplest way to do that is using pd-lib-builders 'common.sources' 
variable (which will statically link the given files to all externals 
built by the project).

gfmadsr
IOhannes

-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 840 bytes
Desc: OpenPGP digital signature
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20221107/c766921a/attachment.sig>


More information about the Pd-list mailing list