|make install-gaia| becoming device aware

Some devices require some environment variables. For example, 
GAIA_DEV_PIXELS_PER_PX for hidpi devices (and you have to remember which 
value) or GAIA_MEMORY_PROFILE=low for Tarako.

I'd like to introduce a shortcut environment variable (probably 
DEVICE=foo) that would pre-fill those other variables.

And if you have a device connected, the DEVICE variable would also be 
autofilled.
So with no thinking, you'd get a Gaia build tailored to the device 
you're working with by default. Sane defaults.

What do you think?

Cheers,
Anthony.
0
Anthony
5/25/2014 4:37:37 PM
mozilla.dev.gaia 3196 articles. 0 followers. Post Follow

3 Replies
341 Views

Similar Articles

[PageSpeed] 14
Get it on Google Play
Get it on Apple App Store

--047d7bb048145e466404fa3e591e
Content-Type: text/plain; charset=UTF-8

2014-05-25 21:00 GMT+02:00 <dev-gaia-request@lists.mozilla.org>:

> Date: Sun, 25 May 2014 18:37:37 +0200
> From: Anthony Ricaud <anthony@ricaud.me>
>


> Some devices require some environment variables. For example,
> GAIA_DEV_PIXELS_PER_PX for hidpi devices (and you have to remember which
> value) or GAIA_MEMORY_PROFILE=low for Tarako.
>
> I'd like to introduce a shortcut environment variable (probably
> DEVICE=foo) that would pre-fill those other variables.
>
> And if you have a device connected, the DEVICE variable would also be
> autofilled.
> So with no thinking, you'd get a Gaia build tailored to the device
> you're working with by default. Sane defaults.
>
> What do you think?
>

Anthony seems a good idea.
+1

Cheers,
Sergio

--047d7bb048145e466404fa3e591e
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr"><div class=3D"gmail_extra"><div class=3D"gmail_quote">2014=
-05-25 21:00 GMT+02:00  <span dir=3D"ltr">&lt;<a href=3D"mailto:dev-gaia-re=
quest@lists.mozilla.org" target=3D"_blank">dev-gaia-request@lists.mozilla.o=
rg</a>&gt;</span>:<br>
<blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8ex;border-=
left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;p=
adding-left:1ex">Date: Sun, 25 May 2014 18:37:37 +0200<br>
From: Anthony Ricaud &lt;<a href=3D"mailto:anthony@ricaud.me">anthony@ricau=
d.me</a>&gt;<br></blockquote><div>=C2=A0</div><blockquote class=3D"gmail_qu=
ote" style=3D"margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-co=
lor:rgb(204,204,204);border-left-style:solid;padding-left:1ex">

Some devices require some environment variables. For example,<br>
GAIA_DEV_PIXELS_PER_PX for hidpi devices (and you have to remember which<br=
>
value) or GAIA_MEMORY_PROFILE=3Dlow for Tarako.<br>
<br>
I&#39;d like to introduce a shortcut environment variable (probably<br>
DEVICE=3Dfoo) that would pre-fill those other variables.<br>
<br>
And if you have a device connected, the DEVICE variable would also be<br>
autofilled.<br>
So with no thinking, you&#39;d get a Gaia build tailored to the device<br>
you&#39;re working with by default. Sane defaults.<br>
<br>
What do you think?<br></blockquote><div>=C2=A0</div><div>Anthony seems a go=
od idea.</div><div>+1</div><div><br></div><div>Cheers,</div><div>Sergio</di=
v></div></div></div>

--047d7bb048145e466404fa3e591e--
0
Sergio
5/25/2014 7:20:01 PM
On 05/25/2014 09:37 AM, Anthony Ricaud wrote:
> I'd like to introduce a shortcut environment variable (probably DEVICE=foo)
> that would pre-fill those other variables.

I think this is already done by the repo tool which is used to choose which
manifest.xml file it needs to use for which device.

see $B2G_DIR/.config, which is produced by running "./config.sh <device>"

> And if you have a device connected, the DEVICE variable would also be
> autofilled.
> So with no thinking, you'd get a Gaia build tailored to the device you're
> working with by default. Sane defaults.

I have unagis and flames constantly plugged to the same computer, what 
should I expect Gaia to do in such case?  Can this be used only if Gaia is 
pulled as a standalone project?

-- 
Nicolas B. Pierron

0
Nicolas
5/26/2014 1:00:25 PM
+1

We can definitely use this for Camera to load a device-specific camera conf=
iguration instead of sniffing the device name at runtime. Unfortunately, th=
ere is a lot of variance in the camera hardware behaviors between devices t=
hat cannot otherwise be detected. In many cases (such as 'zoom') we need to=
 know which device we're dealing with to handle the discrepancies appropria=
tely.
0
jdarcangelo
5/26/2014 2:38:12 PM
Reply: