--- a/src/port/Makefile
+++ b/src/port/Makefile
@@ -49,6 +49,7 @@
 
 libpgport.a: $(OBJS)
 	$(AR) $(AROPT) $@ $^
+	$(RANLIB) libpgport.a
 
 # thread.o needs PTHREAD_CFLAGS (but thread_srv.o does not)
 thread.o: thread.c
