[fpc-pascal] libsndfile library

Tiziano_mk tizzziano at tiscali.it
Tue May 8 09:51:27 CEST 2007


Marco van de Voort wrote:

>> Ok, I'll try that, thanks. But the same problem could happen in other 
>> PCs where my program could be deployed...
> 
> Yes and no.
> 
> No: It will probably add a dependancy to libsndfile.so.1  (not .so
> or .so.1.0.12). And that is installed.
> 
> Yes: the library must be present, and  under that name, and there is no
> guarantee. But that at least will be ok for Ubuntu.
> 
> The only way around it is to enter the complex package building and add a
> dependancy on the file, a system that varies from distro to distro, unix
> variant to unix variant (iow, to package your app as a package for each
> (family of) distribution(s)).
>  
>> So I turn back to the inital question: there is a more affordable way to 
>> play a sound file on a Linux Machine?
> 
> No. This is a general library and packaging problematic. No library is 100%
> guaranteed on Linux, even glibc can be replaced by some embedded variant.

ok, then I'll drive on the simpler way:

...
with myprocess do
  begin
    commandline:= 'aplay x1.wav';
    execute;
  end;
...

(with a section in a file .ini in order to change the command on 
distributions where aplay has another name)


Anyway:
simply creating the symlink libsndfile.so did not solve the matter:

sfplay.o: In function `PLAYFILE':sfplay.pp:57: undefined reference to 
`sf_open_read'
sound.pas(45,1) Error: Error while linking


------
for bartek:
the main reason of my problem is that my PC is not connected to Internet

SDL is great but the problem is the same, not all Linux distributions 
have it installed.

for mark:
I am not a Linux user, sorry. All that seems too complex to me, but I'll 
try to investigate :-)

thanks to all
tiziano






More information about the fpc-pascal mailing list