1c5c4113dSnw141292# 2c5c4113dSnw141292# CDDL HEADER START 3c5c4113dSnw141292# 4c5c4113dSnw141292# The contents of this file are subject to the terms of the 5c5c4113dSnw141292# Common Development and Distribution License (the "License"). 6c5c4113dSnw141292# You may not use this file except in compliance with the License. 7c5c4113dSnw141292# 8c5c4113dSnw141292# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9c5c4113dSnw141292# or http://www.opensolaris.org/os/licensing. 10c5c4113dSnw141292# See the License for the specific language governing permissions 11c5c4113dSnw141292# and limitations under the License. 12c5c4113dSnw141292# 13c5c4113dSnw141292# When distributing Covered Code, include this CDDL HEADER in each 14c5c4113dSnw141292# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15c5c4113dSnw141292# If applicable, add the following below this CDDL HEADER, with the 16c5c4113dSnw141292# fields enclosed by brackets "[]" replaced with your own identifying 17c5c4113dSnw141292# information: Portions Copyright [yyyy] [name of copyright owner] 18c5c4113dSnw141292# 19c5c4113dSnw141292# CDDL HEADER END 20c5c4113dSnw141292# 21c5c4113dSnw141292# 22c5c4113dSnw141292# Copyright 2007 Sun Microsystems, Inc. All rights reserved. 23c5c4113dSnw141292# Use is subject to license terms. 24c5c4113dSnw141292# 25c5c4113dSnw141292 26c5c4113dSnw141292PROG= sqlite 27c5c4113dSnw141292 28c5c4113dSnw141292include ../Makefile.cmd 29c5c4113dSnw141292 30c5c4113dSnw141292include $(SRC)/lib/Makefile.lib 31c5c4113dSnw141292 32*91d7f85eSGordon RossSQLITEHDRDIR= $(ROOTHDRDIR)/sqlite-sys 33c5c4113dSnw141292 34c5c4113dSnw141292ROOTLIBSVCBIN= $(ROOT)/lib/svc/bin 35c5c4113dSnw141292ROOTSQLITE= $(PROG:%=$(ROOTLIBSVCBIN)/%) 36c5c4113dSnw141292 37c5c4113dSnw141292OBJS= shell.o 38c5c4113dSnw141292$(OBJS) := CFLAGS += $(CTF_FLAGS) 39c5c4113dSnw141292$(OBJS) := CTFCONVERT_POST = $(CTFCONVERT_O) 40c5c4113dSnw141292 417014882cSRichard LoweCERRWARN += -_gcc=-Wno-empty-body 427014882cSRichard Lowe 43*91d7f85eSGordon RossLDLIBS += -lsqlite-sys 44*91d7f85eSGordon Ross 45c5c4113dSnw141292.KEEP_STATE: 46c5c4113dSnw141292 47c5c4113dSnw141292$(ROOTSQLITE) := FILEMODE= 555 48c5c4113dSnw141292 49c5c4113dSnw141292$(ROOTLIBSVCBIN)/%: % 50c5c4113dSnw141292 $(INS.file) 51c5c4113dSnw141292 52c5c4113dSnw141292CPPFLAGS += -D_REENTRANT -DTHREADSAFE=1 -DHAVE_USLEEP=1 \ 53c5c4113dSnw141292 -I$(SQLITEHDRDIR) 54c5c4113dSnw141292 55c5c4113dSnw141292$(PROG): $(OBJS) $(SQLITEHDRDIR)/sqlite.h 56c5c4113dSnw141292 $(LINK.c) -o $@ $(OBJS) \ 57*91d7f85eSGordon Ross $(MAPFILE.NES:%=-M%) $(MAPFILE.NED:%=-M%) $(LDLIBS) 58*91d7f85eSGordon Ross $(CTFMERGE) -t -L VERSION -o $@ $(OBJS) 59c5c4113dSnw141292 $(POST_PROCESS) 60c5c4113dSnw141292 61c5c4113dSnw141292all: $(PROG) 62c5c4113dSnw141292 63c5c4113dSnw141292install: all $(ROOTSQLITE) 64c5c4113dSnw141292 65c5c4113dSnw141292clean: 66c5c4113dSnw141292 $(RM) $(OBJS) 67c5c4113dSnw141292 68c5c4113dSnw141292lint: 69c5c4113dSnw141292 70c5c4113dSnw141292include ../Makefile.targ 71