Jump to content

Welcome to CyanogenMod

Welcome to our forum. Like most online communities you must register to post, but don't worry this is a simple free process that requires minimal information for you to signup. Be a part of the CyanogenMod Forum by signing in or creating an account. You can even sign in with your Facebook or Twitter account.
  • Start new topics and reply to others
  • Subscribe to topics and forums to get automatic updates
  • Get your own profile and make new friends
  • Download files attached to the forum.
  • Customize your experience here
  • Share your CyanogenMod experience!
Guest Message by DevFuse
 

[Q]undefined reference to 'openCameraHardware' on CM7

CM7

  • Please log in to reply
9 replies to this topic

#-19 Elvizz

Elvizz
  • Members
  • 3 posts
  • Country:de
  • Device Model:Google Nexus One
  • MOD Version:CM 7.1 N1
  • Recovery Image:ClockworkMod

Posted 18 February 2012 - 02:06 PM

Hi!

I am having the same problem as described above, although I precisely followed these instructions: http://wiki.cyanogen...ogenMod_(Linux)

My phone is a Google Nexus One (HTC Passion) with stock Android 2.3.6 (Build GRK39F).

Extracted files using extract-files.sh are:
AdieHWCodecSetting.csv  libcamera.so			   liboemcamera.so
akmd					libEGL_adreno200.so		libOmxVdec.so
AudioBTID.csv		   libGLESv1_CM_adreno200.so  libq3dtools_adreno200.so
bcm4329.hcd			 libGLESv2_adreno200.so	 parse_radio_log
default.acdb			libgsl.so				  vpimg
default_att.acdb		libhtc_acoustic.so		 yamato_pfp.fw
default_france.acdb	 libhtc_ril.so			  yamato_pm4.fw

Error message I get is
target SharedLib: libcameraservice (out/target/product/passion/obj/SHARED_LIBRARIES/libcameraservice_intermediates/LINKED/libcameraservice.so)
prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/passion/obj/SHARED_LIBRARIES/libcameraservice_intermediates/CameraService.o: in function HAL_openCameraHardware:frameworks/base/services/camera/libcameraservice/CameraService.cpp:1903: error: undefined reference to 'openCameraHardware'
collect2: ld returned 1 exit status
make: *** [out/target/product/passion/obj/SHARED_LIBRARIES/libcameraservice_intermediates/LINKED/libcameraservice.so] Error 1

What can I do or do I have to change to compile successfully?

Thanks,
Elvizz

Edited by Elvizz, 18 February 2012 - 02:27 PM.


#-18 Elvizz

Elvizz
  • Members
  • 3 posts
  • Country:de
  • Device Model:Google Nexus One
  • MOD Version:CM 7.1 N1
  • Recovery Image:ClockworkMod

Posted 18 February 2012 - 10:19 PM

Ok, I seem to found a solution for this:

While googling around I found this post:
http://forum.cyanoge...d-other-issues/

The provided solution to set "USE_CAMERA_STUB := false" in device/htc/passion/BoardConfig.mt did not work for me. However I found the config-file device/htc/passion-common/BoardConfigCommon.mk which contains an option BOARD_USE_FROYO_LIBCAMERA which was set to true. So I assume it expected an outdated libcamera (from FroYo release), but my libcamera.so was already updated and on GIngerbread level. So setting this option to false, running make clean and re-starting the build succeeded!

Can anyone confirm my assumption?

Edited by Elvizz, 19 February 2012 - 09:43 AM.


#-17 ZiviMagic

ZiviMagic
  • Members
  • 3 posts
  • Country:il
  • Device Model:ViewSonic GTablet
  • MOD Version:CyanogenMod-7.2.0-RCO-smb_a1002-KANG
  • Recovery Image:Cyanogen

Posted 15 March 2012 - 04:11 PM

Confirmed.
I had the same problem in my ViewSonic.

Solved by:
cd home/lior/android/system/device/malata/smb-common/
gedit BoardConfigCommon.mk
And setting:
BOARD_USE_FROYO_LIBCAMERA to false

Cheers!

#-16 pinkydoe

pinkydoe
  • Members
  • 2 posts
  • Country:sg
  • Device Model:HTC Desire S
  • MOD Version:CM 7.2 RC1
  • Recovery Image:ClockworkMod

Posted 01 June 2012 - 05:34 AM

Seemed to work for me too, thanks Elvizz and ZiviMagic

Be sure to clean before re-build ;)!

Edited by pinkydoe, 01 June 2012 - 05:36 AM.






Also tagged with one or more of these keywords: CM7