17c478bd9Sstevel@tonic-gate# 27c478bd9Sstevel@tonic-gate# CDDL HEADER START 37c478bd9Sstevel@tonic-gate# 47c478bd9Sstevel@tonic-gate# The contents of this file are subject to the terms of the 57c478bd9Sstevel@tonic-gate# Common Development and Distribution License, Version 1.0 only 67c478bd9Sstevel@tonic-gate# (the "License"). You may not use this file except in compliance 77c478bd9Sstevel@tonic-gate# with the License. 87c478bd9Sstevel@tonic-gate# 97c478bd9Sstevel@tonic-gate# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 107c478bd9Sstevel@tonic-gate# or http://www.opensolaris.org/os/licensing. 117c478bd9Sstevel@tonic-gate# See the License for the specific language governing permissions 127c478bd9Sstevel@tonic-gate# and limitations under the License. 137c478bd9Sstevel@tonic-gate# 147c478bd9Sstevel@tonic-gate# When distributing Covered Code, include this CDDL HEADER in each 157c478bd9Sstevel@tonic-gate# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 167c478bd9Sstevel@tonic-gate# If applicable, add the following below this CDDL HEADER, with the 177c478bd9Sstevel@tonic-gate# fields enclosed by brackets "[]" replaced with your own identifying 187c478bd9Sstevel@tonic-gate# information: Portions Copyright [yyyy] [name of copyright owner] 197c478bd9Sstevel@tonic-gate# 207c478bd9Sstevel@tonic-gate# CDDL HEADER END 217c478bd9Sstevel@tonic-gate# 227c478bd9Sstevel@tonic-gate# 237c478bd9Sstevel@tonic-gate# Copyright 2005 Sun Microsystems, Inc. All rights reserved. 247c478bd9Sstevel@tonic-gate# Use is subject to license terms. 257c478bd9Sstevel@tonic-gate# 267c478bd9Sstevel@tonic-gate# ident "%Z%%M% %I% %E% SMI" 277c478bd9Sstevel@tonic-gate# 287c478bd9Sstevel@tonic-gate 29*a7872406SmeemDEFAULTFILES = cron.dfl 30*a7872406Smeem 317c478bd9Sstevel@tonic-gateinclude ../Makefile.cmd 327c478bd9Sstevel@tonic-gate 337c478bd9Sstevel@tonic-gateMANIFEST = cron.xml 347c478bd9Sstevel@tonic-gate 357c478bd9Sstevel@tonic-gateROOTMANIFESTDIR = $(ROOTSVCSYSTEM) 367c478bd9Sstevel@tonic-gateROOTMETHOD = $(ROOTLIBSVCMETHOD)/svc-cron 377c478bd9Sstevel@tonic-gate 387c478bd9Sstevel@tonic-gateCPPFLAGS += -D_FILE_OFFSET_BITS=64 397c478bd9Sstevel@tonic-gate 407c478bd9Sstevel@tonic-gateROOTVAR = $(ROOT)/var 417c478bd9Sstevel@tonic-gate 427c478bd9Sstevel@tonic-gateROOTSPCRON = $(ROOTVAR)/spool/cron 437c478bd9Sstevel@tonic-gateROOTCROND = $(ROOTETC)/cron.d 447c478bd9Sstevel@tonic-gateROOTCRONTABS = $(ROOTSPCRON)/crontabs 457c478bd9Sstevel@tonic-gateROOTATJOBS = $(ROOTSPCRON)/atjobs 467c478bd9Sstevel@tonic-gateROOTLIBCRON = $(ROOTLIB)/cron 477c478bd9Sstevel@tonic-gate 487c478bd9Sstevel@tonic-gatePROG1 = cron 497c478bd9Sstevel@tonic-gatePROG2 = at atq atrm crontab 507c478bd9Sstevel@tonic-gateXPG4PROG = at 517c478bd9Sstevel@tonic-gatePROG = $(PROG1) $(PROG2) 527c478bd9Sstevel@tonic-gate 537c478bd9Sstevel@tonic-gateSCRIPT = batch 547c478bd9Sstevel@tonic-gateXPG4SCRIPT = batch.xpg4 557c478bd9Sstevel@tonic-gate 567c478bd9Sstevel@tonic-gatePOFILE= $(PROG1)_cmd.po 577c478bd9Sstevel@tonic-gatePOFILES= at.po crontab.po funcs.po batch.po 587c478bd9Sstevel@tonic-gateXGETFLAGS= -a -x $(PROG1).xcl 597c478bd9Sstevel@tonic-gate 60*a7872406SmeemROOTDIRS = $(ROOTSPCRON) $(ROOTCROND) \ 617c478bd9Sstevel@tonic-gate $(ROOTCRONTABS) $(ROOTATJOBS) 627c478bd9Sstevel@tonic-gate 637c478bd9Sstevel@tonic-gateROOTPROG = $(PROG1:%=$(ROOTUSRSBIN)/%) $(PROG2:%=$(ROOTBIN)/%) \ 64*a7872406Smeem $(SCRIPT:%=$(ROOTBIN)/%) \ 657c478bd9Sstevel@tonic-gate $(XPG4PROG:%=$(ROOTXPG4BIN)/%) \ 667c478bd9Sstevel@tonic-gate $(XPG4SCRIPT:%.xpg4=$(ROOTXPG4BIN)/%) 677c478bd9Sstevel@tonic-gate 687c478bd9Sstevel@tonic-gateROOTSYMLINK = $(ROOTLIBCRON) $(ROOTETC)/cron 697c478bd9Sstevel@tonic-gate 707c478bd9Sstevel@tonic-gateCOMMONOBJ1= permit.o 717c478bd9Sstevel@tonic-gateCOMMONOBJ2= funcs.o 727c478bd9Sstevel@tonic-gateCOMMONOBJS= $(COMMONOBJ1) $(COMMONOBJ2) 737c478bd9Sstevel@tonic-gateCRONOBJS= cron.o elm.o 747c478bd9Sstevel@tonic-gateATOBJS= at.o att1.o att2.o 757c478bd9Sstevel@tonic-gateXPG4OBJS= values-xpg4.o 767c478bd9Sstevel@tonic-gateATRMOBJS= atrm.o 777c478bd9Sstevel@tonic-gateATQOBJS= atq.o 787c478bd9Sstevel@tonic-gateCRONTABOBJS= crontab.o 797c478bd9Sstevel@tonic-gate 807c478bd9Sstevel@tonic-gateXPG4ATOBJS= $(ATOBJS:%=atobjs.xpg4/%) $(COMMONOBJS:%=atobjs.xpg4/%) \ 817c478bd9Sstevel@tonic-gate $(XPG4OBJS:%=atobjs.xpg4/%) 827c478bd9Sstevel@tonic-gate 837c478bd9Sstevel@tonic-gatecron := POBJS = $(CRONOBJS) $(COMMONOBJ2) 847c478bd9Sstevel@tonic-gateat := POBJS = $(ATOBJS) $(COMMONOBJS) 857c478bd9Sstevel@tonic-gateat.xpg4 := POBJS = $(XPG4ATOBJS) 867c478bd9Sstevel@tonic-gateatrm := POBJS = $(ATRMOBJS) $(COMMONOBJS) 877c478bd9Sstevel@tonic-gateatq := POBJS = $(ATQOBJS) $(COMMONOBJS) 887c478bd9Sstevel@tonic-gatecrontab := POBJS = crontab.o $(COMMONOBJS) 897c478bd9Sstevel@tonic-gate 907c478bd9Sstevel@tonic-gateat.o atobjs.xpg4/at.o funcs.o permit.o crontab.o elm.o := CFLAGS += $(CCVERBOSE) 917c478bd9Sstevel@tonic-gate 927c478bd9Sstevel@tonic-gateXPG4POBJS = atobjs.xpg4/at.o atobjs.xpg4/att1.o \ 937c478bd9Sstevel@tonic-gate atobjs.xpg4/att2.o atobjs.xpg4/funcs.o \ 947c478bd9Sstevel@tonic-gate atobjs.xpg4/permit.o atobjs.xpg4/values-xpg4.o 957c478bd9Sstevel@tonic-gateNOBJS= $(CRONOBJS) $(ATOBJS) $(ATRMOBJS) $(ATQOBJS) $(CRONTABOBJS) \ 967c478bd9Sstevel@tonic-gate $(COMMONOBJS) 977c478bd9Sstevel@tonic-gateOBJS = $(NOBJS) $(XPG4ATOBJS) 987c478bd9Sstevel@tonic-gateSRCS = $(NOBJS:%.o=%.c) 997c478bd9Sstevel@tonic-gate 1007c478bd9Sstevel@tonic-gateCLOBBERFILES += $(SCRIPT) $(XPG4SCRIPT) 1017c478bd9Sstevel@tonic-gate 1027c478bd9Sstevel@tonic-gate$(ROOTLIBCRON) := SYMLNKDEST = ../../etc/cron.d 1037c478bd9Sstevel@tonic-gate$(ROOTETC)/cron := SYMLNKDEST = ../usr/sbin/cron 1047c478bd9Sstevel@tonic-gate 1057c478bd9Sstevel@tonic-gate$(ROOTBIN)/at := FILEMODE = 04755 1067c478bd9Sstevel@tonic-gate$(ROOTBIN)/at := OWNER = root 1077c478bd9Sstevel@tonic-gate$(ROOTBIN)/at := GROUP = sys 1087c478bd9Sstevel@tonic-gate$(ROOTXPG4BIN)/at := FILEMODE = 04755 1097c478bd9Sstevel@tonic-gate$(ROOTXPG4BIN)/at := OWNER = root 1107c478bd9Sstevel@tonic-gate$(ROOTXPG4BIN)/at := GROUP = sys 1117c478bd9Sstevel@tonic-gate$(ROOTBIN)/atrm := FILEMODE = 04755 1127c478bd9Sstevel@tonic-gate$(ROOTBIN)/atrm := OWNER = root 1137c478bd9Sstevel@tonic-gate$(ROOTBIN)/atrm := GROUP = sys 1147c478bd9Sstevel@tonic-gate$(ROOTBIN)/atq := FILEMODE = 04755 1157c478bd9Sstevel@tonic-gate$(ROOTBIN)/atq := OWNER = root 1167c478bd9Sstevel@tonic-gate$(ROOTBIN)/atq := GROUP = sys 1177c478bd9Sstevel@tonic-gate$(ROOTBIN)/crontab := FILEMODE = 04555 1187c478bd9Sstevel@tonic-gate$(ROOTBIN)/crontab := OWNER = root 1197c478bd9Sstevel@tonic-gate$(ROOTUSRSBIN)/cron := FILEMODE = 0555 1207c478bd9Sstevel@tonic-gate$(ROOTUSRSBIN)/cron := OWNER = root 1217c478bd9Sstevel@tonic-gate$(ROOTUSRSBIN)/cron := GROUP = sys 1227c478bd9Sstevel@tonic-gate 1237c478bd9Sstevel@tonic-gateLDLIBS += -lbsm 1247c478bd9Sstevel@tonic-gate 1257c478bd9Sstevel@tonic-gateat := LDLIBS += -lproject -lsecdb 1267c478bd9Sstevel@tonic-gateat.xpg4 := LDLIBS += -lproject -lsecdb 1277c478bd9Sstevel@tonic-gateatq := LDLIBS += -lsecdb 1287c478bd9Sstevel@tonic-gateatrm := LDLIBS += -lsecdb 1297c478bd9Sstevel@tonic-gatecron := LDLIBS += -lcmd -lpam -lproject -lcontract 1307c478bd9Sstevel@tonic-gatecrontab := LDLIBS += -lsecdb -lpam 1317c478bd9Sstevel@tonic-gate 1327c478bd9Sstevel@tonic-gatelint := LDLIBS += -lproject -lsecdb -lcontract -lpam 1337c478bd9Sstevel@tonic-gate 1347c478bd9Sstevel@tonic-gate$(XPG4) := CFLAGS += -DXPG4 1357c478bd9Sstevel@tonic-gate 1367c478bd9Sstevel@tonic-gate$(ROOTSVCSYSTEM)/cron.xml := OWNER = root 1377c478bd9Sstevel@tonic-gate$(ROOTSVCSYSTEM)/cron.xml := GROUP = sys 1387c478bd9Sstevel@tonic-gate$(ROOTSVCSYSTEM)/cron.xml := FILEMODE = 0444 1397c478bd9Sstevel@tonic-gate 1407c478bd9Sstevel@tonic-gate$(ROOTLIBSVCMETHOD)/svc-cron := OWNER = root 1417c478bd9Sstevel@tonic-gate$(ROOTLIBSVCMETHOD)/svc-cron := GROUP = bin 1427c478bd9Sstevel@tonic-gate$(ROOTLIBSVCMETHOD)/svc-cron := FILEMODE = 0555 1437c478bd9Sstevel@tonic-gate 1447c478bd9Sstevel@tonic-gate 1457c478bd9Sstevel@tonic-gate.KEEP_STATE: 1467c478bd9Sstevel@tonic-gate 1477c478bd9Sstevel@tonic-gateall : $(PROG) $(XPG4) $(SCRIPT) $(XPG4SCRIPT) $(FILES) 1487c478bd9Sstevel@tonic-gate 149*a7872406Smeeminstall : all $(ROOTPROG) $(ROOTETCDEFAULTFILES) $(ROOTSYMLINK) \ 1507c478bd9Sstevel@tonic-gate $(ROOTMANIFEST) $(ROOTMETHOD) 1517c478bd9Sstevel@tonic-gate 1527c478bd9Sstevel@tonic-gate$(PROG) : $$(POBJS) 1537c478bd9Sstevel@tonic-gate $(LINK.c) $(POBJS) -o $@ $(LDLIBS) 1547c478bd9Sstevel@tonic-gate $(POST_PROCESS) 1557c478bd9Sstevel@tonic-gate 1567c478bd9Sstevel@tonic-gate$(XPG4) : atobjs.xpg4 $(XPG4POBJS) 1577c478bd9Sstevel@tonic-gate $(LINK.c) $(XPG4POBJS) -o $@ $(LDLIBS) 1587c478bd9Sstevel@tonic-gate $(POST_PROCESS) 1597c478bd9Sstevel@tonic-gate 1607c478bd9Sstevel@tonic-gateatobjs.xpg4/%.o: %.c 1617c478bd9Sstevel@tonic-gate $(COMPILE.c) -o $@ $< 1627c478bd9Sstevel@tonic-gate 1637c478bd9Sstevel@tonic-gateatobjs.xpg4: 1647c478bd9Sstevel@tonic-gate -@mkdir -p $@ 1657c478bd9Sstevel@tonic-gate 1667c478bd9Sstevel@tonic-gateatobjs.xpg4/values-xpg4.o: ../../lib/common/common/values-xpg4.c 1677c478bd9Sstevel@tonic-gate $(COMPILE.c) -o $@ ../../lib/common/common/values-xpg4.c 1687c478bd9Sstevel@tonic-gate 1697c478bd9Sstevel@tonic-gateatt1.c : att1.y 1707c478bd9Sstevel@tonic-gate $(YACC.y) -d att1.y 1717c478bd9Sstevel@tonic-gate $(MV) y.tab.c att1.c 1727c478bd9Sstevel@tonic-gate $(MV) y.tab.h att1.h 1737c478bd9Sstevel@tonic-gate 1747c478bd9Sstevel@tonic-gateatt2.c : att2.l att2.ed att1.c 1757c478bd9Sstevel@tonic-gate $(LEX) att2.l 1767c478bd9Sstevel@tonic-gate ed - lex.yy.c < att2.ed 1777c478bd9Sstevel@tonic-gate $(MV) lex.yy.c att2.c 1787c478bd9Sstevel@tonic-gate 1797c478bd9Sstevel@tonic-gate# Don't re-install direcories installed by Targetdirs 1807c478bd9Sstevel@tonic-gate#$(ROOTDIRS): 1817c478bd9Sstevel@tonic-gate# $(INS.dir) 1827c478bd9Sstevel@tonic-gate 1837c478bd9Sstevel@tonic-gate$(ROOTSYMLINK) : 1847c478bd9Sstevel@tonic-gate $(RM) $@; $(SYMLINK) $(SYMLNKDEST) $@ 1857c478bd9Sstevel@tonic-gate 1867c478bd9Sstevel@tonic-gatecheck: $(CHKMANIFEST) 1877c478bd9Sstevel@tonic-gate 1887c478bd9Sstevel@tonic-gate$(POFILE): $(POFILES) 1897c478bd9Sstevel@tonic-gate $(RM) $@; cat $(POFILES) > $@ 1907c478bd9Sstevel@tonic-gate 1917c478bd9Sstevel@tonic-gateclean : 1927c478bd9Sstevel@tonic-gate $(RM) $(OBJS) att1.h att1.c att2.c 1937c478bd9Sstevel@tonic-gate 1947c478bd9Sstevel@tonic-gatelint : lint_SRCS 1957c478bd9Sstevel@tonic-gate 1967c478bd9Sstevel@tonic-gatestrip : 1977c478bd9Sstevel@tonic-gate $(STRIP) $(PROG) $(XPG4) 1987c478bd9Sstevel@tonic-gate 1997c478bd9Sstevel@tonic-gateinclude ../Makefile.targ 200