osm2pgsql: fix protobuf-c support

Closes #22058.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>