Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 521426 - media-libs/speex - Cross-compile fix
Summary: media-libs/speex - Cross-compile fix
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Library (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo Sound Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-08-28 20:28 UTC by James Le Cuirot
Modified: 2017-03-04 13:50 UTC (History)
0 users

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


Attachments
ebuild patch (speex-ogg-prefix.patch,476 bytes, patch)
2014-08-28 20:28 UTC, James Le Cuirot
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description James Le Cuirot gentoo-dev 2014-08-28 20:28:05 UTC
Created attachment 383880 [details, diff]
ebuild patch

Please see the attached patch. Simpler than your average cross-compile fix. If you don't specify an OGG prefix using --with-ogg then speex assumes -I/usr/include and -L/usr/lib, which is bad news when you're cross-compiling. Specifying --with-ogg=${EROOT}usr results in -I/foo/usr/include and -L/foo/usr/lib instead. Giving this option together with --disable-ogg has no effect so no extra logic is needed there.
Comment 1 James Le Cuirot gentoo-dev 2014-08-28 21:48:51 UTC
Also see bug #521446 for a very similar fix for media-libs/flac.
Comment 2 James Le Cuirot gentoo-dev 2014-12-03 09:39:20 UTC
The flac fix has been now applied so this probably should be applied too.
Comment 3 Michael Palimaka (kensington) gentoo-dev 2017-03-03 23:16:57 UTC
If this is still an issue with speex-1.2.0 please feel free to apply it.
Comment 4 James Le Cuirot gentoo-dev 2017-03-04 13:15:43 UTC
I was going to say this is still required but then I tried 1.2.0 (as opposed to 1.2rc3) and it isn't a problem any more because it now uses pkg-config.

For the record, if it had still been necessary, I wouldn't have used the proposed fix because it's since been pointed out to me that this violates PMS. ${ROOT} in src_* is not okay but ${SYSROOT} potentially is. There are pending discussions around how Portage deals with SYSROOT. It wouldn't have been necessary to use either variable as I found that --with-ogg==/usr also worked. A leading = is replaced with the SYSROOT.
Comment 5 Alexis Ballier gentoo-dev 2017-03-04 13:34:24 UTC
(In reply to James Le Cuirot from comment #4)
> It wouldn't have
> been necessary to use either variable as I found that --with-ogg==/usr also
> worked. A leading = is replaced with the SYSROOT.

FTR: Last I checked this breaks when gcc is not configured with a sysroot, aka the standard case.
Comment 6 James Le Cuirot gentoo-dev 2017-03-04 13:50:26 UTC
(In reply to Alexis Ballier from comment #5)
> (In reply to James Le Cuirot from comment #4)
> > It wouldn't have
> > been necessary to use either variable as I found that --with-ogg==/usr also
> > worked. A leading = is replaced with the SYSROOT.
> 
> FTR: Last I checked this breaks when gcc is not configured with a sysroot,
> aka the standard case.

Yeah, I was gonna do a non-cross test before I tried 1.2.0. Just tried it anyway out of curiosity and it worked fine. The --sysroot option also didn't work with native gcc before but now it does.