xref: /titanic_52/usr/src/test/libc-tests/tests/random/Makefile (revision a17dff0dc9d07cb9734943b1f593b856d17776b4)
19d12795fSRobert Mustacchi#
29d12795fSRobert Mustacchi# This file and its contents are supplied under the terms of the
39d12795fSRobert Mustacchi# Common Development and Distribution License ("CDDL"), version 1.0.
49d12795fSRobert Mustacchi# You may only use this file in accordance with the terms of version
59d12795fSRobert Mustacchi# 1.0 of the CDDL.
69d12795fSRobert Mustacchi#
79d12795fSRobert Mustacchi# A full copy of the text of the CDDL should have accompanied this
89d12795fSRobert Mustacchi# source.  A copy of the CDDL is also available via the Internet at
99d12795fSRobert Mustacchi# http://www.illumos.org/license/CDDL.
109d12795fSRobert Mustacchi#
119d12795fSRobert Mustacchi
129d12795fSRobert Mustacchi#
139d12795fSRobert Mustacchi# Copyright (c) 2015 Joyent, Inc.
149d12795fSRobert Mustacchi#
159d12795fSRobert Mustacchi
169d12795fSRobert Mustacchiinclude $(SRC)/Makefile.master
179d12795fSRobert Mustacchi
189d12795fSRobert MustacchiROOTOPTPKG = $(ROOT)/opt/libc-tests
199d12795fSRobert MustacchiTESTDIR = $(ROOTOPTPKG)/tests/random
209d12795fSRobert MustacchiROOTBINDIR = $(ROOTOPTPKG)/bin
219d12795fSRobert Mustacchi
229d12795fSRobert MustacchiPROGS = arc4random 		\
239d12795fSRobert Mustacchi	arc4random_prefork 	\
249d12795fSRobert Mustacchi	arc4random_fork 	\
259d12795fSRobert Mustacchi	arc4random_preforkall 	\
269d12795fSRobert Mustacchi	arc4random_forkall 	\
279d12795fSRobert Mustacchi	arc4random_preforksig	\
289d12795fSRobert Mustacchi	arc4random_forksig	\
299d12795fSRobert Mustacchi	arc4random_rekey 	\
309d12795fSRobert Mustacchi	chacha 			\
319d12795fSRobert Mustacchi	getentropy 		\
329d12795fSRobert Mustacchi	getrandom 		\
33*a17dff0dSRobert Mustacchi	getrandred		\
349d12795fSRobert Mustacchi	inz_child		\
359d12795fSRobert Mustacchi	inz_inval		\
369d12795fSRobert Mustacchi	inz_mlock		\
379d12795fSRobert Mustacchi	inz_region 		\
389d12795fSRobert Mustacchi	inz_split		\
399d12795fSRobert Mustacchi	inz_split_vpp		\
409d12795fSRobert Mustacchi	inz_vpp
419d12795fSRobert Mustacchi
429d12795fSRobert MustacchiSCRIPTS = arc4key.ksh
439d12795fSRobert Mustacchi
449d12795fSRobert Mustacchiinclude $(SRC)/cmd/Makefile.cmd
459d12795fSRobert Mustacchiinclude $(SRC)/test/Makefile.com
469d12795fSRobert Mustacchi
479d12795fSRobert MustacchiCMDS = $(PROGS:%=$(TESTDIR)/%) $(SCRIPTS:%=$(TESTDIR)/%)
489d12795fSRobert Mustacchi$(CMDS) := FILEMODE = 0555
499d12795fSRobert Mustacchi
509d12795fSRobert Mustacchiall: $(PROGS)
519d12795fSRobert Mustacchi
529d12795fSRobert Mustacchiinstall: all $(CMDS)
539d12795fSRobert Mustacchi
549d12795fSRobert Mustacchilint:
559d12795fSRobert Mustacchi
569d12795fSRobert Mustacchiclobber: clean
579d12795fSRobert Mustacchi	-$(RM) $(PROGS)
589d12795fSRobert Mustacchi
599d12795fSRobert Mustacchiclean:
609d12795fSRobert Mustacchi	-$(RM) *.o
619d12795fSRobert Mustacchi
629d12795fSRobert Mustacchi$(CMDS): $(TESTDIR) $(PROGS)
639d12795fSRobert Mustacchi
649d12795fSRobert Mustacchiarc4random_prefork: arc4random_fork.c
659d12795fSRobert Mustacchi	$(LINK.c) -o $@ -DARC4_PREINIT=1 arc4random_fork.c $(LDLIBS)
669d12795fSRobert Mustacchi	$(POST_PROCESS)
679d12795fSRobert Mustacchi
689d12795fSRobert Mustacchiarc4random_preforkall: arc4random_forkall.c
699d12795fSRobert Mustacchi	$(LINK.c) -o $@ -DARC4_PREINIT=1 arc4random_forkall.c $(LDLIBS)
709d12795fSRobert Mustacchi	$(POST_PROCESS)
719d12795fSRobert Mustacchi
729d12795fSRobert Mustacchiarc4random_preforksig: arc4random_forksig.c
739d12795fSRobert Mustacchi	$(LINK.c) -o $@ -DARC4_PREINIT=1 arc4random_forksig.c $(LDLIBS)
749d12795fSRobert Mustacchi	$(POST_PROCESS)
759d12795fSRobert Mustacchi
769d12795fSRobert Mustacchichacha: chacha_tv.c
779d12795fSRobert Mustacchi	$(COMPILE.c) -DKEYSTREAM_ONLY -I$(SRC)/common/crypto/chacha -o chacha.o -c $(SRC)/common/crypto/chacha/chacha.c
789d12795fSRobert Mustacchi	$(COMPILE.c) -I$(SRC)/common/crypto/chacha -o chacha_tv.o -c chacha_tv.c
799d12795fSRobert Mustacchi	$(LINK.c) -o $@ chacha_tv.o chacha.o $(LDLIBS)
809d12795fSRobert Mustacchi	$(POST_PROCESS)
819d12795fSRobert Mustacchi
829d12795fSRobert Mustacchi$(ROOTBINDIR):
839d12795fSRobert Mustacchi	$(INS.dir)
849d12795fSRobert Mustacchi
859d12795fSRobert Mustacchi$(ROOTBINDIR)/%: %
869d12795fSRobert Mustacchi	$(INS.file)
879d12795fSRobert Mustacchi
889d12795fSRobert Mustacchi$(TESTDIR):
899d12795fSRobert Mustacchi	$(INS.dir)
909d12795fSRobert Mustacchi
919d12795fSRobert Mustacchi$(TESTDIR)/%: %
929d12795fSRobert Mustacchi	$(INS.file)
939d12795fSRobert Mustacchi
949d12795fSRobert Mustacchi$(TESTDIR)/%: %
959d12795fSRobert Mustacchi	$(INS.file)
96