Can not build libreoffice 4.3.7.2 with autogen.sh on Oracle RHEL6

I need to build it from sources for debugging purposes – I have to implement custom extension for it and debug. When I run autogen.sh even with key --help, it prints following:

configure.ac:111: error: possibly undefined macro: AC_MSG_CHECKING
If this token and others are legitimate, please use m4_pattern_allow.
See the Autoconf documentation.
configure.ac:117: error: possibly undefined macro: AC_MSG_RESULT
configure.ac:217: error: possibly undefined macro: AC_DEFINE
configure.ac:287: error: possibly undefined macro: AC_MSG_WARN
configure.ac:3435: error: possibly undefined macro: AC_LANG_SOURCE
configure.ac:3937: error: possibly undefined macro: AC_LANG_PUSH
configure.ac:3950: error: possibly undefined macro: AC_LANG_POP
configure.ac:8172: error: possibly undefined macro: AC_RUN_IFELSE
Failed to run autoconf at ./autogen.sh line 157.

Are these macroes specific for LibreOffice or is it something with in-system settings of autotools? If former – what dependencies should I get? If latter – where and how should I define these? And also where can I find requirements to LibreOffice build environment? And are there any YUM reposes that contain dependencies for LibreOffice at Oracle RHEL6?

Thanks in advance.

System: Oracle RHEL6, GNU GCC 4.4.7, autoconf 2.6.9. If other information is required – I’ll be glad to provide it.

This is a questions-and-answers site for LibreOffice users. You will probably get much quicker answers if you ask at #libreoffice-dev at FreeNode or here.