kdb: avoid duplicated ifdef