2000-01-22 22:31:00 +03:00
|
|
|
# $NetBSD: bsd.nls.mk,v 1.20 2000/01/22 19:31:02 mycroft Exp $
|
1995-04-20 09:09:34 +04:00
|
|
|
|
1998-04-03 08:40:42 +04:00
|
|
|
.if !target(__initialized__)
|
|
|
|
__initialized__:
|
1995-04-20 09:09:34 +04:00
|
|
|
.if exists(${.CURDIR}/../Makefile.inc)
|
|
|
|
.include "${.CURDIR}/../Makefile.inc"
|
|
|
|
.endif
|
|
|
|
|
1997-05-07 00:54:31 +04:00
|
|
|
.MAIN: all
|
1995-04-20 09:09:34 +04:00
|
|
|
.endif
|
1997-05-07 00:54:31 +04:00
|
|
|
.PHONY: cleannls nlsinstall
|
1999-02-12 15:38:44 +03:00
|
|
|
.if ${MKNLS} != "no"
|
1997-05-09 17:25:46 +04:00
|
|
|
realinstall: nlsinstall
|
1997-10-11 12:16:24 +04:00
|
|
|
.endif
|
1998-08-09 18:46:19 +04:00
|
|
|
cleandir distclean: cleannls
|
1995-04-20 09:09:34 +04:00
|
|
|
|
|
|
|
.SUFFIXES: .cat .msg
|
|
|
|
|
|
|
|
.msg.cat:
|
|
|
|
@rm -f ${.TARGET}
|
|
|
|
gencat ${.TARGET} ${.IMPSRC}
|
|
|
|
|
1995-04-27 22:05:38 +04:00
|
|
|
.if defined(NLS) && !empty(NLS)
|
1995-04-20 09:09:34 +04:00
|
|
|
NLSALL= ${NLS:.msg=.cat}
|
1995-04-27 22:05:38 +04:00
|
|
|
.endif
|
1995-04-20 09:09:34 +04:00
|
|
|
|
|
|
|
.if !defined(NLSNAME)
|
|
|
|
.if defined(PROG)
|
|
|
|
NLSNAME=${PROG}
|
|
|
|
.else
|
|
|
|
NLSNAME=lib${LIB}
|
|
|
|
.endif
|
|
|
|
.endif
|
|
|
|
|
|
|
|
.if defined(NLSALL)
|
1999-02-12 15:38:44 +03:00
|
|
|
.if ${MKNLS} != "no"
|
2000-01-22 22:31:00 +03:00
|
|
|
realall: ${NLSALL}
|
1997-10-11 12:16:24 +04:00
|
|
|
.endif
|
1995-04-20 09:09:34 +04:00
|
|
|
|
|
|
|
cleannls:
|
|
|
|
rm -f ${NLSALL}
|
1997-04-20 02:24:30 +04:00
|
|
|
|
|
|
|
.for F in ${NLSALL}
|
|
|
|
nlsinstall:: ${DESTDIR}${NLSDIR}/${F:T:R}/${NLSNAME}.cat
|
|
|
|
.if !defined(UPDATE)
|
|
|
|
.PHONY: ${DESTDIR}${NLSDIR}/${F:T:R}/${NLSNAME}.cat
|
1995-04-20 09:09:34 +04:00
|
|
|
.endif
|
1999-09-05 01:48:33 +04:00
|
|
|
.if !defined(BUILD) && !make(all) && !make(${F})
|
1997-04-20 02:24:30 +04:00
|
|
|
${DESTDIR}${NLSDIR}/${F:T:R}/${NLSNAME}.cat: .MADE
|
|
|
|
.endif
|
|
|
|
|
1997-05-07 01:29:33 +04:00
|
|
|
.PRECIOUS: ${DESTDIR}${NLSDIR}/${F:T:R}/${NLSNAME}.cat
|
1997-04-20 02:24:30 +04:00
|
|
|
${DESTDIR}${NLSDIR}/${F:T:R}/${NLSNAME}.cat: ${F}
|
1999-08-21 10:17:45 +04:00
|
|
|
${INSTALL} ${INSTPRIV} -d -o ${NLSOWN} -g ${NLSGRP} ${.TARGET:H}
|
|
|
|
${INSTALL} ${RENAME} ${PRESERVE} ${COPY} ${INSTPRIV} -o ${NLSOWN} \
|
|
|
|
-g ${NLSGRP} -m ${NLSMODE} ${.ALLSRC} ${.TARGET}
|
1997-04-20 02:24:30 +04:00
|
|
|
.endfor
|
1997-05-07 20:45:40 +04:00
|
|
|
.else
|
|
|
|
cleannls:
|
1997-04-20 02:24:30 +04:00
|
|
|
.endif
|
|
|
|
|
1997-05-07 19:53:28 +04:00
|
|
|
.if !target(nlsinstall)
|
|
|
|
nlsinstall::
|
|
|
|
.endif
|