1246149Ssjg# $NetBSD: bsd.nls.mk,v 1.3 1996/10/18 02:34:45 thorpej Exp $ 2246149Ssjg 3246149Ssjg.if !target(.MAIN) 4321964Ssjg# init.mk not included 5321964Ssjg.-include <${.CURDIR:H}/Makefile.inc> 6246149Ssjg 7246149Ssjg.MAIN: all 8246149Ssjg.endif 9246149Ssjg 10246149Ssjg.SUFFIXES: .cat .msg 11246149Ssjg 12246149Ssjg.msg.cat: 13246149Ssjg @rm -f ${.TARGET} 14246149Ssjg gencat ${.TARGET} ${.IMPSRC} 15246149Ssjg 16246149Ssjg.if defined(NLS) && !empty(NLS) 17246149SsjgNLSALL= ${NLS:.msg=.cat} 18246149Ssjg.NOPATH: ${NLSALL} 19246149Ssjg.endif 20246149Ssjg 21246149Ssjg.if !defined(NLSNAME) 22246149Ssjg.if defined(PROG) 23246149SsjgNLSNAME=${PROG} 24246149Ssjg.else 25246149SsjgNLSNAME=lib${LIB} 26246149Ssjg.endif 27246149Ssjg.endif 28246149Ssjg 29246149Ssjgnlsinstall: 30246149Ssjg.if defined(NLSALL) 31246149Ssjg @for msg in ${NLSALL}; do \ 32246149Ssjg NLSLANG=`basename $$msg .cat`; \ 33246149Ssjg dir=${DESTDIR}${NLSDIR}/$${NLSLANG}; \ 34246149Ssjg ${INSTALL} -d $$dir; \ 35246149Ssjg ${INSTALL} ${COPY} -o ${NLSOWN} -g ${NLSGRP} -m ${NLSMODE} $$msg $$dir/${NLSNAME}.cat; \ 36246149Ssjg done 37246149Ssjg.endif 38246149Ssjg 39246149Ssjg.if defined(NLSALL) 40246149Ssjgall: ${NLSALL} 41246149Ssjg 42246149Ssjginstall: nlsinstall 43246149Ssjg 44246149Ssjgcleandir: cleannls 45246149Ssjgcleannls: 46246149Ssjg rm -f ${NLSALL} 47246149Ssjg.endif 48