Ticket #4823 (closed defect: fixed)
Missing declaration of utf8_mbtowc function in utils.c
|Reported by:||mloskot||Owned by:|
I use VirtualBox 2.2.4r47978 under Windows Vista Business (64-bit) with Linux Ubuntu 9.10 (64-bit) as guest OS. The guest system uses kernel 2.6.31.
I tried to build guest additions but compilation failed with the following error:
/home/mloskot/tmp/vbox/linux/module/vboxvfs/utils.c:423: error: implicit declaration of function utf8_mbtowc
I've managed to fix this problem by adding these two lines somewhere below line 30:
extern int utf8_mbtowc(wchar_t*, const __u8*, int); extern int utf8_wctomb(__u8*, wchar_t, int);
I tried to fix it properly by including missing header file:
but it doesn't work. I did a quick research and it seems the NLS functions have been renamed in source code of recent kernel versions. Here is patch with NLS: update handling of Unicode posted by Alan Stern on Thu Apr 30 2009.
Hopefully, VirtualBox could be updated to follow the kernel changes.