Last Comment Bug 723418 - in function GonkCameraInputStream::Init(nsACString_internal&, nsCaptureParams*):/home/cjones/mozilla/mozilla-central/netwerk/protocol/device/GonkCaptureProvider.cpp:263: error: undefined reference to 'HAL_getNumberOfCameras'
: in function GonkCameraInputStream::Init(nsACString_internal&, nsCaptureParams...
Status: RESOLVED FIXED
[inbound]
:
Product: Core
Classification: Components
Component: DOM: Device Interfaces (show other bugs)
: Trunk
: x86_64 Linux
: -- normal (vote)
: mozilla13
Assigned To: [:fabrice] Fabrice Desré
:
Mentors:
Depends on:
Blocks: 708484
  Show dependency treegraph
 
Reported: 2012-02-01 23:38 PST by Chris Jones [:cjones] inactive; ni?/f?/r? if you need me
Modified: 2012-02-03 11:48 PST (History)
4 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Don't link against HAL_getNumberOfCameras because we don't have a camera library on the emulator (3.68 KB, patch)
2012-02-02 00:15 PST, Chris Jones [:cjones] inactive; ni?/f?/r? if you need me
gal: review+
Details | Diff | Review
followup (2.39 KB, patch)
2012-02-02 08:51 PST, [:fabrice] Fabrice Desré
cjones.bugs: review+
Details | Diff | Review

Description Chris Jones [:cjones] inactive; ni?/f?/r? if you need me 2012-02-01 23:38:48 PST
This happens when I build b2g while configured for the emulator.  Apparently the emulator doesn't have a libcamera.so to link against, at least our version of it.
Comment 1 Chris Jones [:cjones] inactive; ni?/f?/r? if you need me 2012-02-02 00:15:46 PST
Created attachment 593741 [details] [diff] [review]
Don't link against HAL_getNumberOfCameras because we don't have a camera library on the emulator
Comment 2 Chris Jones [:cjones] inactive; ni?/f?/r? if you need me 2012-02-02 00:33:44 PST
https://hg.mozilla.org/integration/mozilla-inbound/rev/558ccc18ea2c
Comment 3 [:fabrice] Fabrice Desré 2012-02-02 08:51:06 PST
Created attachment 593864 [details] [diff] [review]
followup

The previous patch will fail with devices that have only one camera and try to open the second one.

This patch dlsym() the HAL_getNumberOfCameras() instead.
Comment 4 Chris Jones [:cjones] inactive; ni?/f?/r? if you need me 2012-02-02 10:27:34 PST
So what?
Comment 5 Chris Jones [:cjones] inactive; ni?/f?/r? if you need me 2012-02-02 10:34:17 PST
Comment on attachment 593864 [details] [diff] [review]
followup

This doesn't make sense as a member method here, imho.  I hacked because I didn't want to redactor so as to share the lib handle.  I don't trust the linker.

But let's comprise.  Make this a static method and r=me.
Comment 6 [:fabrice] Fabrice Desré 2012-02-02 18:55:52 PST
pushed:
https://hg.mozilla.org/integration/mozilla-inbound/rev/b71df850fb73
Comment 7 Ed Morley [:emorley] 2012-02-03 11:04:06 PST
https://hg.mozilla.org/mozilla-central/rev/b71df850fb73
Comment 8 Ed Morley [:emorley] 2012-02-03 11:48:36 PST
and the first part:
https://hg.mozilla.org/mozilla-central/rev/558ccc18ea2c

Note You need to log in before you can comment on or make changes to this bug.