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 (the "License"). 6# You may not use this file except in compliance with the License. 7# 8# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9# or http://www.opensolaris.org/os/licensing. 10# See the License for the specific language governing permissions 11# and limitations under the License. 12# 13# When distributing Covered Code, include this CDDL HEADER in each 14# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15# If applicable, add the following below this CDDL HEADER, with the 16# fields enclosed by brackets "[]" replaced with your own identifying 17# information: Portions Copyright [yyyy] [name of copyright owner] 18# 19# CDDL HEADER END 20# 21# 22# Copyright 2009 Sun Microsystems, Inc. All rights reserved. 23# Use is subject to license terms. 24# 25 26include $(SRC)/Makefile.psm 27 28LIBRARY= libfcal_leds.a 29VERS= .1 30 31OBJECTS= fcal_leds.o fc_led_parse.o fcal_leds_thread.o 32 33# include library definitions 34include $(SRC)/lib/Makefile.lib 35 36ROOT_PLATFORM = $(USR_PLAT_DIR)/SUNW,Netra-T4 37 38include $(SRC)/cmd/picl/plugins/Makefile.com 39 40SRCS= $(OBJECTS:%.o=%.c) 41 42LIBS = $(DYNLIB) 43 44ROOTLIBDIR = $(ROOT_PLAT_PLUGINDIR) 45 46CONF= fcal_leds.conf 47ROOTCONF= $(CONF:%=$(ROOTLIBDIR)/%) 48$(ROOTCONF) := FILEMODE = 0644 49 50CPPFLAGS += -I$(SRC)/uts/sun4u/ -I$(SRC)/uts/common/ 51CPPFLAGS += -D_POSIX_PTHREAD_SEMANTICS 52CPPFLAGS += -D_REENTRANT 53 54# Components of load time linker path. 55# These paths start at / on the target machine, so don't use $(ROOT). 56# However, to silence makestyle use empty string $(RUNTIMEROOT) 57RUNTIMEROOT = 58PICLPLATDYN = $(RUNTIMEROOT)/usr/platform/\$$PLATFORM/lib/picl/plugins 59PICLARCHDYN = $(RUNTIMEROOT)/usr/platform/sun4u/lib/picl/plugins 60PICLGENDYN = $(RUNTIMEROOT)/usr/lib/picl/plugins 61 62DYNFLAGS += -R$(PICLPLATDYN):$(PICLARCHDYN):$(PICLGENDYN) 63LDLIBS += -L$(SRC)/lib/libpicltree/$(MACH) 64LDLIBS += -L$(SRC)/cmd/picl/plugins/common/devtree 65LDLIBS += -L$(SRC)/cmd/picl/plugins/common/piclevent 66LDLIBS += -L$(SRC)/cmd/picl/plugins/common/frutree 67LDLIBS += -L$(SRC)/cmd/picl/plugins/common/memcfg 68LDLIBS += -lpicltree -lpicldevtree -lpiclfrutree -lnvpair 69LDLIBS += -ldevinfo -lc 70 71.KEEP_STATE: 72 73SUBDIRS= 74 75all := TARGET= all 76install := TARGET= install 77clean := TARGET= clean 78clobber := TARGET= clobber 79_msg := TARGET= _msg 80 81POFILE = piclfcal_leds_lw2plus.po 82POFILES = $(SRCS:%.c=%.po) 83 84all: $(LIBS) $(LIBLINKS) 85 86install: $(ROOTLIBDIR) all $(ROOTLIBS) $(ROOTLINKS) $(ROOTCONF) 87 88$(POFILE): $(POFILES) 89 $(CAT) $(POFILES) > $(POFILE) 90 91_msg: $(MSGDOMAIN) $(POFILE) 92 $(RM) $(MSGDOMAIN)/$(POFILE) 93 $(CP) $(POFILE) $(MSGDOMAIN)/$(POFILE) 94 95$(MSGDOMAIN): 96 $(INS.dir) 97 98 99$(LIBLINKS): FRC 100 $(RM) $@; $(SYMLINK) $(DYNLIB) $@ 101 102# include library targets 103include $(SRC)/lib/Makefile.targ 104include $(SRC)/cmd/picl/plugins/Makefile.targ 105 106lint: 107 108$(SUBDIRS): FRC 109 @cd $@; pwd; $(MAKE) $(TARGET) 110 111FRC: 112