diff --git a/contrib/pg_dumplo/main.c b/contrib/pg_dumplo/main.c
index 5a192ea96cff5d08ad5e211563db8c6c83010da0..e0758f3544313afb8b46510e4efc2df2099eab10 100644
--- a/contrib/pg_dumplo/main.c
+++ b/contrib/pg_dumplo/main.c
@@ -1,7 +1,7 @@
 /* -------------------------------------------------------------------------
  * pg_dumplo
  *
- * $Header: /cvsroot/pgsql/contrib/pg_dumplo/Attic/main.c,v 1.14 2003/01/07 21:42:38 tgl Exp $
+ * $Header: /cvsroot/pgsql/contrib/pg_dumplo/Attic/main.c,v 1.15 2003/01/09 18:27:39 tgl Exp $
  *
  *					Karel Zak 1999-2000
  * -------------------------------------------------------------------------
@@ -11,6 +11,9 @@
 
 #include <errno.h>
 #include <unistd.h>
+#ifdef HAVE_GETOPT_H
+#include <getopt.h>
+#endif
 
 #include "libpq-fe.h"
 #include "libpq/libpq-fs.h"