I'm unable to compile the VGM mod MAME 200 with either GCC or Clang.
I applied the VGM and Qsound diffs and uncommented NOWERROR = 1 in the makefile.
Here are the error messages.
Clang 6.0
Code:
Done. Generated 347/347 projects.
Compiling src/lib/util/vgmwrite.cpp...
../../../../../src/lib/util/vgmwrite.cpp:189:68: error: must explicitly qualify
name of member function when taking its address
...FUNC(vgmfile_callback), this));
^ ~~~~~~~~~~~~~~~~
VGMTimer::
In file included from ../../../../../src/lib/util/vgmwrite.cpp:11:
In file included from ../../../../../src/lib/util/../../emu/emu.h:29:
../../../../../src/lib/util/../../emu/debug/../emucore.h:220:17: note: expanded
from macro 'FUNC'
#define FUNC(x) &x, #x
^~
1 error generated.
utils.make:645: recipe for target '../../../../linux_clang/obj/x64/Release/src/lib/util/vgmwrite.o' failed
make[2]: *** [../../../../linux_clang/obj/x64/Release/src/lib/util/vgmwrite.o] Error 1
Makefile:25: recipe for target 'utils' failed
make[1]: *** [utils] Error 2
makefile:1302: recipe for target 'linux_x64_clang' failed
make: *** [linux_x64_clang] Error 2
GCC 7.3.0
Code:
In file included from ../../../../../src/lib/util/../../emu/emu.h:29:0,
from ../../../../../src/lib/util/vgmwrite.cpp:11:
../../../../../src/lib/util/vgmwrite.cpp: In constructor ‘VGMTimer::VGMTimer(running_machine&)’:
../../../../../src/lib/util/vgmwrite.cpp:189:73: error: ISO C++ forbids taking the address of an unqualified or parenthesized non-static member function to form a pointer to member function. Say ‘&VGMTimer::vgmfile_callback’ [-fpermissive]
timer = machine.scheduler().timer_alloc(timer_expired_delegate(FUNC(vgmfile_callback), this));
^
../../../../../src/lib/util/../../emu/emucore.h:220:18: note: in definition of macro ‘FUNC’
#define FUNC(x) &x, #x
^
utils.make:645: recipe for target '../../../../linux_gcc/obj/x64/Release/src/lib/util/vgmwrite.o' failed
make[2]: *** [../../../../linux_gcc/obj/x64/Release/src/lib/util/vgmwrite.o] Error 1
Makefile:25: recipe for target 'utils' failed
make[1]: *** [utils] Error 2
makefile:1280: recipe for target 'linux_x64' failed
make: *** [linux_x64] Error 2
VB edit: I moved the post into the MAME topic. (Aside from that, it was out of place in the "Problems and Suggestions" forum, which is mainly for website stuff.)