Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 168369 - media-sound/alsa-driver-1.0.14_rc2_p3234 agnostic of CONFIG_MCORE2
Summary: media-sound/alsa-driver-1.0.14_rc2_p3234 agnostic of CONFIG_MCORE2
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo ALSA team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: kernel-2.6.20
  Show dependency tree
 
Reported: 2007-02-25 20:04 UTC by Alexandra Parker
Modified: 2007-03-25 16:41 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch to configure.in and configure (alsa-driver-mcore2.patch,1.55 KB, patch)
2007-02-25 20:10 UTC, Alexandra Parker
Details | Diff
Working patch :) (alsa-driver-mcore2.patch,1.19 KB, patch)
2007-03-10 20:38 UTC, Alexandra Parker
Details | Diff
media-sound/alsa-driver-1.0.14_rc1.ebuild (alsa-driver-1.0.14_rc1.ebuild,6.36 KB, text/plain)
2007-03-21 14:16 UTC, Dick Marinus
Details
Patch without configure script included (mcore2.patch,613 bytes, patch)
2007-03-24 17:01 UTC, Alexandra Parker
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexandra Parker 2007-02-25 20:04:08 UTC
Kernel 2.6.20 added the new processor family CONFIG_MCORE2.  The alsa-driver autoconf scripts don't check for this value and don't understand which processor type it is being built for.  I have a patch that aliases Core 2 to the 686 architecture (just as the configure script does with all the Pentium family processors).

Reproducible: Always

Steps to Reproduce:
1. Configure kernel with CONFIG_MCORE2
2. Attempt to build alsa-driver

Actual Results:  
See http://forums.gentoo.org/viewtopic-t-537554.html

Expected Results:  
Successful compilation

Kernel is configured as described.
Comment 1 Alexandra Parker 2007-02-25 20:10:32 UTC
Created attachment 111223 [details, diff]
Patch to configure.in and configure

Candidate patch; it patches both configure.in and the actual script since I don't know if running autoconf in the ebuild is reasonable or not.  It produces some rather bad QA notices, however:

 * QA Notice: Package has poor programming practices which may compile
 *            fine but exhibit random runtime failures.
 * /var/tmp/portage/media-sound/alsa-driver-1.0.14_rc2_p3234/work/alsa-driver-1.0.14rc2_p3234/acore/memory_wrapper.c:40: warning: implicit declaration of function ‘VMALLOC_VMADDR’
[...]

 * QA Notice: Package has poor programming practices which may compile
 *            but will almost certainly crash on 64bit architectures.
 * Function `pte_offset' implicitly converted to pointer at /var/tmp/portage/media-sound/alsa-driver-1.0.14_rc2_p3234/work/alsa-driver-1.0.14rc2_p3234/acore/memory_wrapper.c:46
[...]
Comment 2 Alexandra Parker 2007-03-10 20:38:25 UTC
Created attachment 112847 [details, diff]
Working patch :)

I've actually inserted this patch into an overlay ebuild and verified that it works.  The QA warnings didn't appear this time.
Comment 3 Dick Marinus 2007-03-21 14:16:27 UTC
Created attachment 113968 [details]
media-sound/alsa-driver-1.0.14_rc1.ebuild

Great work! Could you please remove the configure(.orig) patch?

This is an updated ebuild:

--- /usr/portage/media-sound/alsa-driver/alsa-driver-1.0.14_rc1.ebuild  2007-02-12 00:36:32.000000000 +0100
+++ alsa-driver-1.0.14_rc1.ebuild       2007-03-21 15:12:35.000000000 +0100
@@ -2,7 +2,7 @@
 # Distributed under the terms of the GNU General Public License v2
 # $Header: /var/cvsroot/gentoo-x86/media-sound/alsa-driver/alsa-driver-1.0.14_rc1.ebuild,v 1.9 2007/02/11 23:33:57 blubb Exp $
 
-inherit linux-mod flag-o-matic eutils multilib
+inherit linux-mod flag-o-matic eutils multilib autotools
 
 MY_P="${P/_rc/rc}"
 S="${WORKDIR}/${MY_P}"
@@ -103,6 +103,9 @@
 
        convert_to_m "${S}/Makefile"
        sed -i -e 's:\(.*depmod\):#\1:' "${S}/Makefile"
+
+       epatch ${FILESDIR}/mcore2.patch
+       eautoreconf
 }
 
 src_compile() {
Comment 4 Alexandra Parker 2007-03-24 17:01:22 UTC
Created attachment 114260 [details, diff]
Patch without configure script included

Okay.  I need someone else to test if it works on rc1 since that version doesn't seem to compile for me.  Also, shouldn't there be quotes around "${FILESDIR}/mcore2.patch"?
Comment 5 Alexandra Parker 2007-03-24 19:19:11 UTC
Seems someone made a similar patch for 1.0.14_rc3