xref: /illumos-gate/usr/src/lib/libsqlite/Makefile (revision 241c90a06e8d1708235651863df515a2d522a03a)
1c5c4113dSnw141292#
2c5c4113dSnw141292# Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
3c5c4113dSnw141292# Use is subject to license terms.
4c5c4113dSnw141292#
5c5c4113dSnw141292
6c5c4113dSnw141292SUBDIRS	=	$(MACH)
7c5c4113dSnw141292
8c5c4113dSnw141292SQLITE_VERSION = 2.8.15-repcached
9c5c4113dSnw141292
10c5c4113dSnw141292VERS = .1
11c5c4113dSnw141292
12c5c4113dSnw141292include $(SRC)/lib/Makefile.lib
13c5c4113dSnw141292
14c5c4113dSnw141292ENCODING  = ISO8859
15c5c4113dSnw141292
16c5c4113dSnw141292SRCDIR=	src
17c5c4113dSnw141292
18c5c4113dSnw141292HDRS=           sqlite.h sqlite-misc.h
1991d7f85eSGordon RossROOTHDRDIR=     $(ROOT)/usr/include/sqlite-sys
20c5c4113dSnw141292ROOTHDRS=       $(HDRS:%=$(ROOTHDRDIR)/%)
21c5c4113dSnw141292CHECKHDRS=      $(HDRS:%.h=%.check)
2291d7f85eSGordon RossCLOBBERFILES +=	sqlite.h
23c5c4113dSnw141292
24c5c4113dSnw141292.KEEP_STATE:
25c5c4113dSnw141292
26c5c4113dSnw141292all	:= TARGET= all
27c5c4113dSnw141292clean	:= TARGET= clean
28c5c4113dSnw141292clobber	:= TARGET= clobber
29c5c4113dSnw141292install	:= TARGET= install
30c5c4113dSnw141292
31c5c4113dSnw141292
32c5c4113dSnw141292# This is the default Makefile target.  The objects listed here
33c5c4113dSnw141292# are what get build when you type just "make" with no arguments.
34c5c4113dSnw141292#
3591d7f85eSGordon Rossall install:	sqlite.h $(SUBDIRS)
36*241c90a0SRichard Loweclobber:	$(SUBDIRS)
37c5c4113dSnw141292
38c5c4113dSnw141292$(ROOTHDRDIR):
39c5c4113dSnw141292	$(INS.dir)
40c5c4113dSnw141292
41c5c4113dSnw141292$(ROOTHDRDIR)/%: % $(ROOTHDRDIR)
42c5c4113dSnw141292	$(INS.file)
43c5c4113dSnw141292
44c5c4113dSnw141292install_h:	sqlite.h $(ROOTHDRS)
45c5c4113dSnw141292
46c5c4113dSnw141292check:
47c5c4113dSnw141292
48c5c4113dSnw141292#
49c5c4113dSnw141292# we don't want this output different every time, so we just suppress it
50c5c4113dSnw141292#
51c5c4113dSnw141292sqlite.h: $(SRCDIR)/sqlite.h.in
52c5c4113dSnw141292	@echo "Generating $@"; \
5391d7f85eSGordon Ross	 sed -e 's"--VERS--"$(SQLITE_VERSION)"' \
54c5c4113dSnw141292	    -e s/--ENCODING--/$(ENCODING)/ \
55c5c4113dSnw141292	    $(SRCDIR)/sqlite.h.in > $@
56c5c4113dSnw141292
57c5c4113dSnw141292$(SUBDIRS): FRC
58c5c4113dSnw141292	@cd $@; pwd; $(MAKE) $(TARGET)
59c5c4113dSnw141292
60c5c4113dSnw141292FRC:
61c5c4113dSnw141292
62c5c4113dSnw141292include $(SRC)/lib/Makefile.targ
63