Re: [gentoo-dev] How to handle x86/amd64 only packages on other arches

2012-01-25 Thread Xavier Miller

Hello,

Thank you very much for your replies :)

Doubling the timeout seems to work (no error so far, the SHDHC card is
fully useable).

I disabled the MMC debugging, and I also see that, grepping mmc in dmesg:
[2.795410] _regulator_get: omap_hsmmc.0 supply vmmc_aux not found,
using dummy regulator
[2.806335] _regulator_get: omap_hsmmc.4 supply vmmc_aux not found,
using dummy regulator

Is it normal?

Kind regards,
Xavier.

Quoting Sergei Trofimovich :


On Wed, 25 Jan 2012 10:30:26 +0100
Chí-Thanh Christopher Nguyễn  wrote:


Doug Goldstein schrieb:
> I need to be able to have ppc/arm/etc users install a package that can
> only be built on x86/amd64. The packages in question are
> sys-apps/seabios and sys-apps/vgabios. The point is that a PPC machine
> that's using qemu-system-x86_64 still needs to use seabios and
> vgabios. I was planning on building the package on my own hardware and
> posting up sys-apps/seabios-bin and sys-apps/vgabios-bin unless of
> course someone has a better suggestion.

Possibly a USE flag could be added to seabios/vgabios, similar to the
"fontforge" flag in font packages, enabled by default and masked in
profiles that don't support building from source.


+1

It's the simplest thing to maintain. It eases binary package creation
and does not need any blockers, virtuals or conditional depends.

You just patch an ebuild, run `emerge --buildkpgonly seabios`
and package is ready. All in one place.

--

  Sergei






Re: [gentoo-dev] How to handle x86/amd64 only packages on other arches

2012-01-25 Thread Sergei Trofimovich
> It's the simplest thing to maintain. It eases binary package creation
> and does not need any blockers, virtuals or conditional depends.
> 
> You just patch an ebuild, run `emerge --buildkpgonly seabios`
> and package is ready. All in one place.

Sample patch with USE=binary attached.

-- 

  Sergei
Index: seabios-1.6.3.ebuild
===
RCS file: /var/cvsroot/gentoo-x86/sys-apps/seabios/seabios-1.6.3.ebuild,v
retrieving revision 1.4
diff -u -u -2 -0 -r1.4 seabios-1.6.3.ebuild
--- seabios-1.6.3.ebuild	24 Jan 2012 01:32:19 -	1.4
+++ seabios-1.6.3.ebuild	25 Jan 2012 19:50:05 -
@@ -1,65 +1,86 @@
 # Copyright 1999-2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 # $Header: /var/cvsroot/gentoo-x86/sys-apps/seabios/seabios-1.6.3.ebuild,v 1.4 2012/01/24 01:32:19 vapier Exp $
 
 EAPI=4
 
 PYTHON_DEPEND="2"
 
 #BACKPORTS=1
 
 if [[ ${PV} = ** || ! -z "${EGIT_COMMIT}" ]]; then
 	EGIT_REPO_URI="git://git.seabios.org/seabios.git"
 	GIT_ECLASS="git-2"
 	SRC_URI=""
 else
-	SRC_URI="http://www.linuxtogo.org/~kevin/SeaBIOS/${P}.tar.gz
-	${BACKPORTS:+http://dev.gentoo.org/~cardoe/distfiles/${P}-bp-${BACKPORTS}.tar.bz2}";
+	SRC_URI="
+		binary? ( http://dev.gentoo.org/~slyfox/${PF}-bin.tbz2 )
+		!binary? (
+			http://www.linuxtogo.org/~kevin/SeaBIOS/${P}.tar.gz
+			${BACKPORTS:+http://dev.gentoo.org/~cardoe/distfiles/${P}-bp-${BACKPORTS}.tar.bz2}
+		)"
 fi
 
 inherit ${GIT_ECLASS} python
 
 if [[ ${PV} != ** ]]; then
 	KEYWORDS="amd64 ~x86"
 fi
 
 DESCRIPTION="Open Source implementation of a 16-bit x86 BIOS"
 HOMEPAGE="http://www.seabios.org";
 
 LICENSE="LGPL-3 GPL-3"
 SLOT="0"
-IUSE=""
+IUSE="binary"
 
 DEPEND=""
 RDEPEND="${DEPEND}
 	!app-emulation/qemu
 	!<=app-emulation/qemu-kvm-0.15.0"
 
 pkg_setup() {
+	use binary && return
+
 	python_set_active_version 2
 }
 
+src_unpack() {
+	use binary && mkdir -p "${S}"
+
+	default
+}
+
 src_prepare() {
+	use binary && return
+
 	if [[ -z "${EGIT_COMMIT}" ]]; then
 		sed -e "s/VERSION=.*/VERSION=${PV}/" \
 			-i "${S}/Makefile"
 	else
 		sed -e "s/VERSION=.*/VERSION=${PV}_pre${EGIT_COMMIT}/" \
 			-i "${S}/Makefile"
 	fi
 }
 
 src_configure() {
 	:
 }
 
 src_compile() {
+	use binary && return
+
 	emake out/bios.bin
 #	emake out/vgabios.bin
 }
 
 src_install() {
+	if use binary; then
+		mv "${WORKDIR}/usr" "${D}" || die
+		return
+	fi
+
 	insinto /usr/share/seabios
 	doins out/bios.bin
 #	doins out/vgabios.bin
 }


signature.asc
Description: PGP signature


Re: [gentoo-dev] How to handle x86/amd64 only packages on other arches

2012-01-25 Thread Sergei Trofimovich
On Wed, 25 Jan 2012 10:30:26 +0100
Chí-Thanh Christopher Nguyễn  wrote:

> Doug Goldstein schrieb:
> > I need to be able to have ppc/arm/etc users install a package that can
> > only be built on x86/amd64. The packages in question are
> > sys-apps/seabios and sys-apps/vgabios. The point is that a PPC machine
> > that's using qemu-system-x86_64 still needs to use seabios and
> > vgabios. I was planning on building the package on my own hardware and
> > posting up sys-apps/seabios-bin and sys-apps/vgabios-bin unless of
> > course someone has a better suggestion.
> 
> Possibly a USE flag could be added to seabios/vgabios, similar to the
> "fontforge" flag in font packages, enabled by default and masked in
> profiles that don't support building from source.

+1

It's the simplest thing to maintain. It eases binary package creation
and does not need any blockers, virtuals or conditional depends.

You just patch an ebuild, run `emerge --buildkpgonly seabios`
and package is ready. All in one place.

-- 

  Sergei


signature.asc
Description: PGP signature


Re: [gentoo-dev] How to handle x86/amd64 only packages on other arches

2012-01-25 Thread Michał Górny
On Wed, 25 Jan 2012 02:01:20 -0600
Doug Goldstein  wrote:

> I need to be able to have ppc/arm/etc users install a package that can
> only be built on x86/amd64. The packages in question are
> sys-apps/seabios and sys-apps/vgabios. The point is that a PPC machine
> that's using qemu-system-x86_64 still needs to use seabios and
> vgabios. I was planning on building the package on my own hardware and
> posting up sys-apps/seabios-bin and sys-apps/vgabios-bin unless of
> course someone has a better suggestion.

Yes, -bin seem to be the best solution. Otherwise, we'd have to require
some kind of portage-capable cross-toolchain for that package.

I'd suggest you *DEPEND on it through:
|| ( sys-apps/seabios sys-apps/seabios-bin )

so that x86 users could still choose the binary package for some reason.

-- 
Best regards,
Michał Górny


signature.asc
Description: PGP signature


Re: [gentoo-dev] How to handle x86/amd64 only packages on other arches

2012-01-25 Thread Chí-Thanh Christopher Nguyễn
Doug Goldstein schrieb:
> I need to be able to have ppc/arm/etc users install a package that can
> only be built on x86/amd64. The packages in question are
> sys-apps/seabios and sys-apps/vgabios. The point is that a PPC machine
> that's using qemu-system-x86_64 still needs to use seabios and
> vgabios. I was planning on building the package on my own hardware and
> posting up sys-apps/seabios-bin and sys-apps/vgabios-bin unless of
> course someone has a better suggestion.

Possibly a USE flag could be added to seabios/vgabios, similar to the
"fontforge" flag in font packages, enabled by default and masked in
profiles that don't support building from source.


Best regards,
Chí-Thanh Christopher Nguyễn



[gentoo-dev] How to handle x86/amd64 only packages on other arches

2012-01-25 Thread Doug Goldstein
I need to be able to have ppc/arm/etc users install a package that can
only be built on x86/amd64. The packages in question are
sys-apps/seabios and sys-apps/vgabios. The point is that a PPC machine
that's using qemu-system-x86_64 still needs to use seabios and
vgabios. I was planning on building the package on my own hardware and
posting up sys-apps/seabios-bin and sys-apps/vgabios-bin unless of
course someone has a better suggestion.

I know the list tends to devolve into the theory of foo/bar and
foo/baz but I'd like to keep this concrete to those two packages.

-- 
Doug Goldstein