1# 2# CDDL HEADER START 3# 4# The contents of this file are subject to the terms of the 5# Common Development and Distribution License, Version 1.0 only 6# (the "License"). You may not use this file except in compliance 7# with the License. 8# 9# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 10# or http://www.opensolaris.org/os/licensing. 11# See the License for the specific language governing permissions 12# and limitations under the License. 13# 14# When distributing Covered Code, include this CDDL HEADER in each 15# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16# If applicable, add the following below this CDDL HEADER, with the 17# fields enclosed by brackets "[]" replaced with your own identifying 18# information: Portions Copyright [yyyy] [name of copyright owner] 19# 20# CDDL HEADER END 21# 22# 23# Copyright 2004 Sun Microsystems, Inc. All rights reserved. 24# Use is subject to license terms. 25# 26#ident "%Z%%M% %I% %E% SMI" 27 28include ../../Makefile.cmd 29 30common_DCNAMES = \ 31 FMD \ 32 SMF \ 33 SUNOS \ 34 PCI 35 36sparc_DCNAMES = \ 37 SUN4U 38 39DCNAMES = \ 40 $(common_DCNAMES) \ 41 $($(MACH)_DCNAMES) 42 43ALLDCNAMES = \ 44 $(common_DCNAMES) \ 45 $(sparc_DCNAMES) 46 47DCFILES = $(DCNAMES:%=%.dict) 48POFILES = $(DCNAMES:%=%.po) 49MOFILES = $(DCNAMES:%=%.mo) 50 51ROOTDCDIR = $(ROOTLIB)/fm/dict 52ROOTLCDIR = $(ROOTLIB)/locale/C/LC_MESSAGES 53 54ROOTDCFILES = $(DCNAMES:%=$(ROOTDCDIR)/%.dict) 55ROOTPOFILES = $(DCNAMES:%=$(ROOTLCDIR)/%.po) 56ROOTMOFILES = $(DCNAMES:%=$(ROOTLCDIR)/%.mo) 57ROOTALLPOFILES = $(ALLDCNAMES:%=$(ROOTLCDIR)/%.po) 58 59FILEMODE = 0444 60$(ROOTALLPOFILES) := FILEMODE = 0644 61 62DICTCK = ../scripts/dictck 63DICTCKFLAGS = -b ../scripts/buildcode 64 65all: $(MOFILES) 66 67_msg: $(ROOTALLPOFILES) 68 69$(ROOTDCDIR): 70 $(INS.dir) 71 72$(ROOTLIB)/locale: 73 $(INS.dir) 74 75$(ROOTLIB)/locale/C: $(ROOTLIB)/locale 76 $(INS.dir) 77 78$(ROOTLCDIR): $(ROOTLIB)/locale/C 79 $(INS.dir) 80 81$(ROOTDCDIR)/%: % 82 $(INS.file) 83 84$(ROOTLCDIR)/%: % 85 $(INS.file) 86 87%.mo: %.po 88 msgfmt -s -o $@ $< 89 90lint: 91 @for name in $(DCNAMES); do\ 92 $(DICTCK) $(DICTCKFLAGS) $$name.dict $$name.po;\ 93 done 94 95clean install_h lint: 96 97clobber: 98 $(RM) $(MOFILES) 99 100install: all $(ROOTDCDIR) $(ROOTLCDIR) \ 101 $(ROOTDCFILES) $(ROOTALLPOFILES) $(ROOTMOFILES) 102