Annotation of src/share/mk/bsd.nls.mk, Revision 1.1
1.1 ! deraadt 1: # $NetBSD: bsd.nls.mk,v 1.2 1995/04/27 18:05:38 jtc Exp $
! 2:
! 3: .if !target(.MAIN)
! 4: .if exists(${.CURDIR}/../Makefile.inc)
! 5: .include "${.CURDIR}/../Makefile.inc"
! 6: .endif
! 7:
! 8: .MAIN: all
! 9: .endif
! 10:
! 11: .SUFFIXES: .cat .msg
! 12:
! 13: .msg.cat:
! 14: @rm -f ${.TARGET}
! 15: gencat ${.TARGET} ${.IMPSRC}
! 16:
! 17: .if defined(NLS) && !empty(NLS)
! 18: NLSALL= ${NLS:.msg=.cat}
! 19: .endif
! 20:
! 21: .if !defined(NLSNAME)
! 22: .if defined(PROG)
! 23: NLSNAME=${PROG}
! 24: .else
! 25: NLSNAME=lib${LIB}
! 26: .endif
! 27: .endif
! 28:
! 29: nlsinstall:
! 30: .if defined(NLSALL)
! 31: @for msg in ${NLSALL}; do \
! 32: NLSLANG=`basename $$msg .cat`; \
! 33: dir=${DESTDIR}${NLSDIR}/$${NLSLANG}; \
! 34: install -d $$dir; \
! 35: install ${COPY} -o ${NLSOWN} -g ${NLSGRP} -m ${NLSMODE} $$msg $$dir/${NLSNAME}.cat; \
! 36: done
! 37: .endif
! 38:
! 39: .if defined(NLSALL)
! 40: all: ${NLSALL}
! 41:
! 42: install: nlsinstall
! 43:
! 44: cleandir: cleannls
! 45: cleannls:
! 46: rm -f ${NLSALL}
! 47: .endif