I've noticed while compiling gdbm-1.8.0-5 that RPM_OPT_FLAGS stuff doesn't appear in autoconf managed Makefile (to tell simple, it is ignored). Attached patch fixes that behaviour.
Created attachment 13004 [details] Patch to fix gdbm-1.8.0 autoconf stuff
Fixed in gdbm-1.8.0-6 - thanks for your patch!