xref: /illumos-gate/usr/src/lib/libficl/Makefile.com (revision d48be21240dfd051b689384ce2b23479d757f2d8)
1#
2# This file and its contents are supplied under the terms of the
3# Common Development and Distribution License ("CDDL"), version 1.0.
4# You may only use this file in accordance with the terms of version
5# 1.0 of the CDDL.
6#
7# A full copy of the text of the CDDL should have accompanied this
8# source.  A copy of the CDDL is also available via the Internet at
9# http://www.illumos.org/license/CDDL.
10#
11
12#
13# Copyright 2016 Toomas Soome <tsoome@me.com>
14#
15# Copyright 2020 Joyent, Inc.
16# Copyright 2023 OmniOS Community Edition (OmniOSce) Association.
17
18LIBRARY=libficl-sys.a
19MAJOR = 4
20MINOR = 1.0
21VERS=.$(MAJOR).$(MINOR)
22
23OBJECTS= dictionary.o system.o fileaccess.o float.o double.o prefix.o search.o \
24	softcore.o stack.o tools.o vm.o primitives.o unix.o utility.o \
25	hash.o callback.o word.o loader.o pager.o extras.o \
26	loader_emu.o gfx_fb.o pnglite.o lz4.o
27
28include $(SRC)/lib/Makefile.lib
29
30LIBS=	$(DYNLIB)
31CSTD=	$(CSTD_GNU99)
32
33FICLDIR=	$(SRC)/common/ficl
34LZ4=		$(SRC)/common/lz4
35PNGLITE=	$(SRC)/common/pnglite
36CPPFLAGS +=	-I.. -I$(FICLDIR) -I$(FICLDIR)/emu -D_LARGEFILE64_SOURCE=1
37# These in-gate headers must take precedence over any that may appear in an
38# adjunct.
39CPPFLAGS.first +=	-I$(PNGLITE) -I$(LZ4)
40CFLAGS += $(C_BIGPICFLAGS)
41CFLAGS64 += $(C_BIGPICFLAGS64)
42
43LDLIBS +=	-lumem -luuid -lz -lc -lm
44NATIVE_LIBS +=	libz.so
45
46HEADERS= $(FICLDIR)/ficl.h $(FICLDIR)/ficltokens.h ../ficllocal.h \
47	$(FICLDIR)/ficlplatform/unix.h $(PNGLITE)/pnglite.h
48
49pics/%.o:	../softcore/%.c $(HEADERS)
50	$(COMPILE.c) -o $@ $<
51	$(POST_PROCESS_O)
52
53pics/%.o:	$(FICLDIR)/%.c $(HEADERS)
54	$(COMPILE.c) -o $@ $<
55	$(POST_PROCESS_O)
56
57pics/%.o:	$(FICLDIR)/ficlplatform/%.c $(HEADERS)
58	$(COMPILE.c) -o $@ $<
59	$(POST_PROCESS_O)
60
61pics/%.o:	$(FICLDIR)/emu/%.c $(HEADERS)
62	$(COMPILE.c) -o $@ $<
63	$(POST_PROCESS_O)
64
65pics/%.o:	$(LZ4)/%.c $(HEADERS)
66	$(COMPILE.c) -o $@ $<
67	$(POST_PROCESS_O)
68
69pics/%.o:	$(PNGLITE)/%.c $(HEADERS)
70	$(COMPILE.c) -o $@ $<
71	$(POST_PROCESS_O)
72
73all: $(LIBS)
74
75include $(SRC)/lib/Makefile.targ
76