Problem when compile the Android For OMAP3_with Gstreamer Integration source

Dear Experts,

I am new to the BeagleBoard, and I am now having fun in the linux
kernel hacking.

Anyway, I am following the page:
http://labs.embinux.org/index.php/Android_For_OMAP3_with_Gstreamer_Integration

and I am trying to compile the Android source. However I got an error
in the sound library. I tried to follow every step in that web page,
what am I missing?

Here is the log of the error:
  CC sound/soc/codecs/tlv320aic3x.o
  CC sound/soc/codecs/twl4030.o
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:583: error:
expected ')' before '-' token
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:590: error:
expected ')' before numeric constant
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:596: error:
expected ')' before '-' token
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:602: error:
expected ')' before '-' token
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:608: error:
expected ')' before numeric constant
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:614: error:
expected ')' before numeric constant
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:618: error:
'digital_fine_tlv' undeclared here (not in a function)
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:625: error:
'digital_coarse_tlv' undeclared here (not in a function)
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:632: error:
'analog_tlv' undeclared here (not in a function)
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:646: error:
'output_tvl' undeclared here (not in a function)
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:661: error:
'digital_capture_tlv' undeclared here (not in a function)
/home/james/omap3droid/kernel/sound/soc/codecs/twl4030.c:668: error:
'input_gain_tlv' undeclared here (not in a function)
make[5]: *** [sound/soc/codecs/twl4030.o] Error 1
make[4]: *** [sound/soc/codecs] Error 2
make[3]: *** [sound/soc] Error 2
make[2]: *** [sound] Error 2
make[1]: *** [sub-make] Error 2
make[1]: Leaving directory `/home/james/omap3droid/kernel'
make: *** [out/target/product/beagle/obj/KERNEL_OBJ/arch/arm/boot/
uImage] Error 2

I am lost and don't know how to fix the problem.

Thank You,
James

It seems like the alsa fix broke this. I haven't investigated further,
but I went for a quick solution myself, by stepping back the kernel to
the previous commit until it's fixed.
# cd kernel
# git checkout 6e9442f9d823285f63b8e2b19b0265d696fa0f49

/Rob

hi,

add “#include <sound/tlv.h>” to twl4030.c

Thanks and Regards,
HarishKumar.V

Thank You, HarishKumar and Rob,

I tried to fix the problem by adding "#include <sound/tlv.h>" to
twl4030.c, it works, but it come to another problem:

target arm C: libasound <= external/alsa-lib/src/alisp/alisp.c
external/alsa-lib/src/alisp/alisp.c: In function 'obj_type_str':
external/alsa-lib/src/alisp/alisp.c:1024: error: control reaches end
of non-void function
make: *** [out/target/product/beagle/obj/STATIC_LIBRARIES/
libasound_intermediates/src/alisp/alisp.o] Error 1

Do you have any idea how can I fix it? or just simply use the kernel
mentioned by Rob?

Thanks,
James

Hi,

this has nothing to do with the kernel.

add “return nil” to last line of the fucntion,

static const char *obj_type_str(struct alisp_object * p)
{
switch (alisp_get_type§) {
case ALISP_OBJ_NIL: return “nil”;
case ALISP_OBJ_T: return “t”;
case ALISP_OBJ_INTEGER: return “integer”;
case ALISP_OBJ_FLOAT: return “float”;
case ALISP_OBJ_IDENTIFIER: return “identifier”;
case ALISP_OBJ_STRING: return “string”;
case ALISP_OBJ_POINTER: return “pointer”;
case ALISP_OBJ_CONS: return “cons”;
default: assert(0);
}
return “nil”;
}

This is due to control reaches to end of the function and not returned.

Thanks and Regards,
HarishKumar.V

Dear HarishKumar,

Thank you so much, got it compiled .

Thanks,
James