* [Buildroot] alsa for arm compile options & svn 20557
@ 2008-02-11 17:27 Andrew Dyer
2008-02-11 18:01 ` Bernhard Fischer
0 siblings, 1 reply; 2+ messages in thread
From: Andrew Dyer @ 2008-02-11 17:27 UTC (permalink / raw)
To: buildroot
I believe a change introduced in SVN 20557 is incorrect for some arm
kernel builds with alsa. Here is the 20557 change:
--- trunk/buildroot/package/alsa-lib/alsa-lib.mk 2007/10/01 16:15:31 20163
+++ trunk/buildroot/package/alsa-lib/alsa-lib.mk 2007/11/28 07:09:57 20557
@@ -24,7 +24,7 @@
(cd $(ALSA_LIB_DIR); rm -rf config.cache; \
$(TARGET_CONFIGURE_ARGS) \
$(TARGET_CONFIGURE_OPTS) \
- CFLAGS="$(TARGET_CFLAGS)" \
+ CFLAGS="$(TARGET_CFLAGS) -mabi=aapcs-linux" \
LDFLAGS="$(TARGET_LDFLAGS)" \
./configure \
--target=$(GNU_TARGET_NAME) \
The root problem is that the kernel and the alsa libraries must be
compiled such that certain structure sizes work out the same, else the
ioctls used by alsa in communicating between userland and kernel will
fail. The bug manifests itself on the target like so:
# alsamixer
alsamixer: function snd_mixer_load failed: Inappropriate ioctl for device
The problem with the 20557 change is that depending on the kernel
config used the -mabi switch can be different. The kernel option that
controls this is CONFIG_AEABI - both settings for this seem to be used
for varying platforms defconfigs. My platform happens to use the
wrong one :-(
Looking in linux-2.6/arch/arm/Makefile, the value of the -mabi option
can be either -maapcs-linux or -mapcs-gnu. I am not enough of a arm
gcc guru to know if any of the other command line switches will affect
the generated structure size.
confirmed experimentally on my target by redefining aapcs-linux to
apcs-gnu, recompiling, and alsamixer does not error out any more.
--
Hardware, n.:
The parts of a computer system that can be kicked.
^ permalink raw reply [flat|nested] 2+ messages in thread
* [Buildroot] alsa for arm compile options & svn 20557
2008-02-11 17:27 [Buildroot] alsa for arm compile options & svn 20557 Andrew Dyer
@ 2008-02-11 18:01 ` Bernhard Fischer
0 siblings, 0 replies; 2+ messages in thread
From: Bernhard Fischer @ 2008-02-11 18:01 UTC (permalink / raw)
To: buildroot
On Mon, Feb 11, 2008 at 11:27:11AM -0600, Andrew Dyer wrote:
>I believe a change introduced in SVN 20557 is incorrect for some arm
>kernel builds with alsa. Here is the 20557 change:
>
>--- trunk/buildroot/package/alsa-lib/alsa-lib.mk 2007/10/01 16:15:31 20163
>+++ trunk/buildroot/package/alsa-lib/alsa-lib.mk 2007/11/28 07:09:57 20557
>@@ -24,7 +24,7 @@
> (cd $(ALSA_LIB_DIR); rm -rf config.cache; \
> $(TARGET_CONFIGURE_ARGS) \
> $(TARGET_CONFIGURE_OPTS) \
>- CFLAGS="$(TARGET_CFLAGS)" \
>+ CFLAGS="$(TARGET_CFLAGS) -mabi=aapcs-linux" \
> LDFLAGS="$(TARGET_LDFLAGS)" \
> ./configure \
> --target=$(GNU_TARGET_NAME) \
Yes, that is pretty broken, too. I think that this works like it should
in my tree.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-02-11 18:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-11 17:27 [Buildroot] alsa for arm compile options & svn 20557 Andrew Dyer
2008-02-11 18:01 ` Bernhard Fischer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox