Since this C code is mixed with C++ class, extern "C" should be added in bayer.h like this:
#ifdef __cplusplus
extern "C" {
#endif
extern void bayer2rgb24(unsigned char *dst, unsigned char *src, long int WIDTH, long int HEIGHT);
#ifdef __cplusplus
}
#endif
After applying this, still compiles fine.
server/drivers/camera/v4l2/bayer.h
The changes have been made in SVN trunk.
Thank you for your contribution.