$OpenBSD: patch-src_Makefile_in,v 1.1 2002/03/26 17:49:58 espie Exp $
--- src/Makefile.in.orig	Sat Sep 15 02:47:52 2001
+++ src/Makefile.in	Mon Mar 25 01:35:24 2002
@@ -156,10 +156,17 @@ bin_PROGRAMS =  gettext$(EXEEXT) ngettex
 msgfmt$(EXEEXT) msgmerge$(EXEEXT) msgunfmt$(EXEEXT) xgettext$(EXEEXT) \
 msgcomm$(EXEEXT)
 PROGRAMS =  $(bin_PROGRAMS)
+bin_PROGRAMS = wrapper
 
 CPPFLAGS = @CPPFLAGS@
 LDFLAGS = @LDFLAGS@
 LIBS = @LIBS@
+wrapper_OBJECTS= gettext.o ngettext.o msgcmp.o message.o msgfmt.o msgmerge.o msgunfmt.o xgettext.o msgcomm.o open-po.o po-gram-gen.o po-hash-gen.o po-lex.o po.o str-list.o dir-list.o write-po.o wrapper.o xget-lex.o
+
+wrapper_LDADD = $(LDADD)
+wrapper_DEPENDENCIES = ../lib/libnlsut.a
+wrapper_LDFLAGS = 
+
 gettext_OBJECTS =  gettext.$(OBJEXT)
 gettext_LDADD = $(LDADD)
 gettext_DEPENDENCIES =  ../lib/libnlsut.a
@@ -240,6 +247,11 @@ distclean-binPROGRAMS:
 maintainer-clean-binPROGRAMS:
 
 install-binPROGRAMS: $(bin_PROGRAMS)
+	$(LIBTOOL)  --mode=install $(INSTALL_PROGRAM) wrapper $(DESTDIR)$(bindir)/gettext
+	for i in ngettext msgcmp msgfmt msgmerge msgunfmt xgettext \
+	msgcomm; do ln ${DESTDIR}$(bindir)/gettext ${DESTDIR}$(bindir)/$$i; done
+
+oinstall-binPROGRAMS: $(bin_PROGRAMS)
 	@$(NORMAL_INSTALL)
 	$(mkinstalldirs) $(DESTDIR)$(bindir)
 	@list='$(bin_PROGRAMS)'; for p in $$list; do \
@@ -298,6 +310,10 @@ clean-libtool:
 distclean-libtool:
 
 maintainer-clean-libtool:
+
+wrapper: $(wrapper_OBJECTS) $(wrapper_DEPENDENCIES)
+	@rm -f wrapper
+	$(LINK) $(wrapper_LDFLAGS) $(wrapper_OBJECTS) $(wrapper_LDADD) $(LIBS)
 
 gettext$(EXEEXT): $(gettext_OBJECTS) $(gettext_DEPENDENCIES)
 	@rm -f gettext$(EXEEXT)
