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 2023 Oxide Computer Company 14# 15 16PROG = ktest 17OBJS = ktest.o 18SRCS = $(OBJS:%.o=%.c) 19 20CLEANFILES += $(OBJS) 21 22include ../Makefile.cmd 23$(BUILD64) include ../Makefile.cmd.64 24include ../Makefile.ctf 25 26CFLAGS += $(CCVERBOSE) 27CFLAGS64 += $(CCVERBOSE) 28 29LDLIBS += -L$(ROOT)/lib -lumem -lgen -lnvpair -lofmt -lcmdutils 30 31CSTD = $(CSTD_GNU99) 32 33all: $(PROG) 34 35$(PROG): $(OBJS) 36 $(LINK.c) -o $@ $(OBJS) $(LDLIBS) 37 $(POST_PROCESS) 38 39%.o: %.c 40 $(COMPILE.c) $< 41 $(POST_PROCESS_O) 42 43install: all $(ROOTPROG) 44 45clean: 46 -$(RM) $(CLEANFILES) 47 48include ../Makefile.targ 49