0

I'm a Pascal programmer but i need to compile a C library for Windows.

That library is espeak (a voice synthesizer) which uses portaudio lib to access audio port. I have translated the C header into Pascal and have no problem using that library in Linux with the Pascal header.. Also, no problem compiling that lib in Linux (some Make,... and it is done...).

But i want to use it for Windows too... So i have installed Microsoft Visual Studio and loaded the project.

When I compile the lib, I get messages like:

wavegen.obj : error LNK2019: unresolved external symbol _Pa_Initialize referenced in function "int __cdecl WavegenInitSound(void)" (?WavegenInitSound@@YAHXZ)

It seems that the link to the library is not found. How can i declare what and where that library is (portaudio.dll).

In the code there is #include "portaudio.h" so I think the link to the function is defined. But I cannot find where it is defined which library (portaudio.dll) to use.

PS : I do not speak great C so some code is very welcome...

Many thanks

1 Answers1

0

You need to make sure that the version of portaudio you are linking to is the same as the version of portaaudio.h that eSpeak compiles to.

The eSpeak sources contain both a v18 and v19 header for portaudio. It also has a portaudio.h which IIRC is a copy of the v18 header.

reece
  • 7,945
  • 1
  • 26
  • 28
  • Many thanks for answer. Yes, i have use portaudio19.h (rename to portaudio.h). – user2418856 May 26 '13 at 11:30
  • Have somebody luck with compilation of espeak-portaudio in Windows ? With Visual Studio ? – user2418856 May 26 '13 at 17:25
  • I am not sure what the issue is. You can try emailing espeak-general@lists.sourceforge.net and asking Jonathan for help as he builds Windows versions for the espeak releases. – reece May 30 '13 at 23:23