diff --git a/usr.bin/ee/Makefile b/usr.bin/ee/Makefile index 0edddc00a6d8..7a7041d48fb2 100644 --- a/usr.bin/ee/Makefile +++ b/usr.bin/ee/Makefile @@ -2,22 +2,26 @@ CFLAGS+= -DCAP -DHAS_NCURSES -DHAS_UNISTD -DHAS_STDARG -DHAS_STDLIB \ -DHAS_CTYPE -DHAS_SYS_IOCTL -DHAS_SYS_WAIT -DSLCT_HDR PROG= ee -SRCS= ee.c LINKS= ${BINDIR}/ee ${BINDIR}/ree -MLINKS= ee.1 ree.1 +MLINKS= ee.1 ree.1 DPADD= ${LIBNCURSES} ${LIBMYTINFO} LDADD= -lncurses -lmytinfo LANGS= en_US.ISO_8859-1 fr_FR.ISO_8859-1 de_DE.ISO_8859-1 +FILES= ${LANGS:S/$/.ee.cat/} +CLEANFILES+= ${FILES} -afterinstall: -.for l in ${LANGS} - @${ECHO} "Install ${DESTDIR}${NLSDIR}/${l}/ee.cat" - @rm -f ${DESTDIR}${NLSDIR}/${l}/ee.cat - @gencat -new ${DESTDIR}${NLSDIR}/${l}/ee.cat ${.CURDIR}/nls/${l}/ee.msg - @chown ${BINOWN}.${BINGRP} ${DESTDIR}${NLSDIR}/${l}/ee.cat - @chmod 444 ${DESTDIR}${NLSDIR}/${l}/ee.cat +all: ${FILES} + +.for lang in ${LANGS} +${lang}.ee.cat: ${.CURDIR}/nls/${lang}/ee.msg + gencat -new ${.TARGET} ${.ALLSRC} .endfor +beforeinstall: +.for lang in ${LANGS} + ${INSTALL} -o ${BINOWN} -g ${BINGRP} -m ${NOBINMODE} \ + ${lang}.ee.cat ${DESTDIR}${NLSDIR}/${lang}/ee.cat +.endfor .include