xref: /netbsd-src/usr.bin/make/trace.h (revision 85aee7a6f7ea7ce71e85a9986f1cdb4b61ece72d)
1*85aee7a6Srillig /*	$NetBSD: trace.h,v 1.6 2021/01/19 20:51:46 rillig Exp $	*/
2694b899bSsommerfeld 
3*85aee7a6Srillig /*
4694b899bSsommerfeld  * Copyright (c) 2000 The NetBSD Foundation, Inc.
5694b899bSsommerfeld  * All rights reserved.
6694b899bSsommerfeld  *
7694b899bSsommerfeld  * This code is derived from software contributed to The NetBSD Foundation
8694b899bSsommerfeld  * by Bill Sommerfeld
9694b899bSsommerfeld  *
10694b899bSsommerfeld  * Redistribution and use in source and binary forms, with or without
11694b899bSsommerfeld  * modification, are permitted provided that the following conditions
12694b899bSsommerfeld  * are met:
13694b899bSsommerfeld  * 1. Redistributions of source code must retain the above copyright
14694b899bSsommerfeld  *    notice, this list of conditions and the following disclaimer.
15694b899bSsommerfeld  * 2. Redistributions in binary form must reproduce the above copyright
16694b899bSsommerfeld  *    notice, this list of conditions and the following disclaimer in the
17694b899bSsommerfeld  *    documentation and/or other materials provided with the distribution.
18694b899bSsommerfeld  *
19694b899bSsommerfeld  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
20694b899bSsommerfeld  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
21694b899bSsommerfeld  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
22694b899bSsommerfeld  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
23694b899bSsommerfeld  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
24694b899bSsommerfeld  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
25694b899bSsommerfeld  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
26694b899bSsommerfeld  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
27694b899bSsommerfeld  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28694b899bSsommerfeld  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29694b899bSsommerfeld  * POSSIBILITY OF SUCH DAMAGE.
30694b899bSsommerfeld  */
31694b899bSsommerfeld 
32*85aee7a6Srillig /*
33694b899bSsommerfeld  * trace.h --
34694b899bSsommerfeld  *	Definitions pertaining to the tracing of jobs in parallel mode.
35694b899bSsommerfeld  */
36694b899bSsommerfeld 
37153e6e1aSrillig #ifndef MAKE_TRACE_H
38153e6e1aSrillig #define MAKE_TRACE_H
39153e6e1aSrillig 
402e62f9c8Srillig typedef enum TrEvent {
41694b899bSsommerfeld 	MAKESTART,
42694b899bSsommerfeld 	MAKEEND,
43694b899bSsommerfeld 	MAKEERROR,
44694b899bSsommerfeld 	JOBSTART,
45694b899bSsommerfeld 	JOBEND,
46555fff31Ssjg 	MAKEINTR
47694b899bSsommerfeld } TrEvent;
48694b899bSsommerfeld 
49694b899bSsommerfeld void Trace_Init(const char *);
50694b899bSsommerfeld void Trace_Log(TrEvent, Job *);
51694b899bSsommerfeld void Trace_End(void);
52694b899bSsommerfeld 
53153e6e1aSrillig #endif
54