Here's the error output from my attempted compile in Manjaro:
Linking mame...
obj/sdl/libosd.a(osdobj_common.o):(.rodata._ZTI12osd_common_t[_ZTI12osd_common_t]+0x18): undefined reference to `typeinfo for osd_interface'
collect2: error: ld returned 1 exit status
makefile:948: recipe for target 'mame' failed
make: *** [mame] Error 1
rm obj/sdl/osd/modules/debugger/qt/deviceinformationwindow.moc.c obj/sdl/osd/modules/debugger/qt/mainwindow.moc.c obj/sdl/osd/modules/debugger/qt/windowqt.moc.c obj/sdl/osd/modules/debugger/qt/dasmwindow.moc.c obj/sdl/osd/modules/debugger/qt/logwindow.moc.c obj/sdl/osd/modules/debugger/qt/deviceswindow.moc.c obj/sdl/osd/modules/debugger/qt/debuggerview.moc.c obj/sdl/osd/modules/debugger/qt/memorywindow.moc.c obj/sdl/osd/modules/debugger/qt/breakpointswindow.moc.c
EDIT: Interesting that our error outputs are different, despite Manjaro being a derivative of Arch. Due to this, I should probably provide some additional details about what dependencies I have listed, and what command I use to build SDLMAME. It's thanks to information obtained from the PKGBUILD for the sdlume package in the Arch User Repository (which I normally build, plus sdlmame has been moved to the community repository now), that I was able to find the needed dependencies and commands...
For dependencies, the following are listed as required: libxinerama, sdl2_ttf, qt4, flac, portmidi, sqlite, and expat
and the following is listed as optional: ttf-liberation
And the command I use to build:
make NOWERROR=1 PYTHON=python2 \
BUILD_EXPAT=0 BUILD_ZLIB=0 BUILD_FLAC=0 BUILD_JPEGLIB=0 BUILD_MIDILIB=0 \
BUILD_SQLITE3=0 \
SUFFIX64=
Perhaps this additional information may prove useful...