[alsa-devel] Errors in application building
Paul Kavan
pkavan at gmail.com
Tue Jul 3 20:29:40 CEST 2007
Hello all:
I am working on my first bit of application code for ALSA and am not sure
how to properly compile it against the libs. I have to cross compile the
application on my host machine i686 PC for use on a ARM development board. I
copied the alsa include directory into my staging include directory (this is
where the cross-compiler works from), which allowed the program to find
alsa/asoundlib.h However, I am still getting some errors that indicate to me
it cannot find everything it needs.
I am getting the following errors:
grhuser at pcL7:$ arm-linux-gcc -Wall -o grh_audio grh_audio.c
grh_audio.c: In function 'grh_capture':
grh_audio.c:113: warning: pointer targets in passing argument 3 of
'snd_pcm_hw_params_set_rate_near' differ in signedness
grh_audio.c: In function 'grh_playback':
grh_audio.c:208: warning: pointer targets in passing argument 3 of
'snd_pcm_hw_params_set_rate_near' differ in signedness
/tmp/ccMn48zN.o: In function `grh_capture':
grh_audio.c:(.text+0x16c): undefined reference to `snd_pcm_open'
grh_audio.c:(.text+0x198): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x1c0): undefined reference to `snd_pcm_hw_params_malloc'
grh_audio.c:(.text+0x1e4): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x214): undefined reference to `snd_pcm_hw_params_any'
grh_audio.c:(.text+0x238): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x26c): undefined reference to
`snd_pcm_hw_params_set_access'
grh_audio.c:(.text+0x290): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x2c4): undefined reference to
`snd_pcm_hw_params_set_format'
grh_audio.c:(.text+0x2e8): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x324): undefined reference to
`snd_pcm_hw_params_set_rate_near'
grh_audio.c:(.text+0x348): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x380): undefined reference to
`snd_pcm_hw_params_set_channels'
grh_audio.c:(.text+0x3a4): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x3d4): undefined reference to `snd_pcm_hw_params'
grh_audio.c:(.text+0x3f8): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x420): undefined reference to `snd_pcm_hw_params_free'
grh_audio.c:(.text+0x42c): undefined reference to `snd_pcm_prepare'
grh_audio.c:(.text+0x450): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x494): undefined reference to `snd_pcm_readi'
grh_audio.c:(.text+0x4c0): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x500): undefined reference to `snd_pcm_close'
/tmp/ccMn48zN.o: In function `grh_playback':
grh_audio.c:(.text+0x5b8): undefined reference to `snd_pcm_open'
grh_audio.c:(.text+0x5e4): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x60c): undefined reference to `snd_pcm_hw_params_malloc'
grh_audio.c:(.text+0x630): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x660): undefined reference to `snd_pcm_hw_params_any'
grh_audio.c:(.text+0x684): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x6b8): undefined reference to
`snd_pcm_hw_params_set_access'
grh_audio.c:(.text+0x6dc): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x710): undefined reference to
`snd_pcm_hw_params_set_format'
grh_audio.c:(.text+0x734): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x770): undefined reference to
`snd_pcm_hw_params_set_rate_near'
grh_audio.c:(.text+0x794): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x7cc): undefined reference to
`snd_pcm_hw_params_set_channels'
grh_audio.c:(.text+0x7f0): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x820): undefined reference to `snd_pcm_hw_params'
grh_audio.c:(.text+0x844): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x86c): undefined reference to `snd_pcm_hw_params_free'
grh_audio.c:(.text+0x878): undefined reference to `snd_pcm_prepare'
grh_audio.c:(.text+0x89c): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x8e0): undefined reference to `snd_pcm_writei'
grh_audio.c:(.text+0x90c): undefined reference to `snd_strerror'
grh_audio.c:(.text+0x94c): undefined reference to `snd_pcm_close'
collect2: ld returned 1 exit status
My application code is attached. If anyone could give me some pointers as to
why these errors are occurring, I would appreciate it greatly.
Thanks.
Paul
--
***************************************
Paul David Kavan
Project Engineer
GRH Electronics, Inc.
402-734-4900
pkavan at gmail.com
***************************************
-------------- next part --------------
A non-text attachment was scrubbed...
Name: grh_audio.c
Type: text/x-csrc
Size: 7221 bytes
Desc: not available
Url : http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20070703/b5398515/attachment.c
More information about the Alsa-devel
mailing list