Makefile revision 260576
1179193Sjb#-
2179193Sjb# Copyright (c) 2011 Google, Inc.
3179193Sjb# All rights reserved.
4179193Sjb#
5179193Sjb# Redistribution and use in source and binary forms, with or without
6179193Sjb# modification, are permitted provided that the following conditions
7179193Sjb# are met:
8179193Sjb# 1. Redistributions of source code must retain the above copyright
9179193Sjb#    notice, this list of conditions and the following disclaimer.
10179193Sjb# 2. Redistributions in binary form must reproduce the above copyright
11179193Sjb#    notice, this list of conditions and the following disclaimer in the
12179193Sjb#    documentation and/or other materials provided with the distribution.
13179193Sjb#
14179193Sjb# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15179193Sjb# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16179193Sjb# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17179193Sjb# ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18179193Sjb# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19179193Sjb# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20211738Srpaulo# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21211738Srpaulo# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22211738Srpaulo# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23211738Srpaulo# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24179193Sjb# SUCH DAMAGE.
25179193Sjb#
26179193Sjb# $FreeBSD: head/lib/atf/libatf-c/Makefile 260576 2014-01-12 21:56:26Z jmmv $
27179198Sjb
28179193Sjb.include <bsd.init.mk>
29179193Sjb
30179193SjbLIB=		atf-c
31211738SrpauloSHLIB_MAJOR=	1
32179193Sjb
33211738SrpauloATF=		${.CURDIR:H:H:H}/contrib/atf
34179193Sjb.PATH:		${ATF}
35179193Sjb.PATH:		${ATF}/atf-c
36179193Sjb.PATH:		${ATF}/atf-c/detail
37179193Sjb
38179193SjbCFLAGS+=	-I${ATF}
39179193SjbCFLAGS+=	-I${.CURDIR}
40179193SjbCFLAGS+=	-I.
41211738Srpaulo
42179193SjbSRCS=		build.c \
43211738Srpaulo		check.c \
44179193Sjb		config.c \
45179193Sjb		dynstr.c \
46179193Sjb		env.c \
47211738Srpaulo		error.c \
48179193Sjb		fs.c \
49211738Srpaulo		list.c \
50179193Sjb		map.c \
51179193Sjb		process.c \
52179193Sjb		sanity.c \
53179193Sjb		text.c \
54179193Sjb		user.c \
55179193Sjb		utils.c \
56179193Sjb		tc.c \
57179193Sjb		tp.c \
58211738Srpaulo		tp_main.c
59179193Sjb
60211738SrpauloINCS=		build.h \
61211738Srpaulo		check.h \
62211738Srpaulo		config.h \
63211738Srpaulo		defs.h \
64211738Srpaulo		error.h \
65211738Srpaulo		error_fwd.h \
66211738Srpaulo		macros.h \
67211738Srpaulo		tc.h \
68179193Sjb		tp.h \
69179193Sjb		utils.h
70179193SjbINCSDIR=	${INCLUDEDIR}/atf-c
71179193Sjb
72179193SjbINCS+=		atf-c.h
73179193SjbINCSDIR_atf-c.h= ${INCLUDEDIR}
74179193Sjb
75179193SjbMAN=		atf-c-api.3
76179193Sjb
77179193Sjball: atf-c.pc
78179193Sjbatf-c.pc: atf-c.pc.in atf-version
79179193Sjb	sed -e 's,__CC__,${CC},g' \
80179193Sjb	    -e 's,__INCLUDEDIR__,${INCLUDEDIR},g' \
81179193Sjb	    -e 's,__LIBDIR__,${LIBDIR},g' \
82179193Sjb	    -e "s,__ATF_VERSION__,$$(cat atf-version),g" \
83179193Sjb	    <${ATF}/atf-c/atf-c.pc.in >atf-c.pc
84179193Sjb
85179193Sjbbeforeinstall:
86179193Sjb	${INSTALL} -C -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \
87179193Sjb		atf-c.pc ${DESTDIR}${LIBDATADIR}/pkgconfig
88179193Sjb
89179193Sjb.if ${MK_TESTS} != "no"
90179193SjbSUBDIR=		tests
91179193Sjb.endif
92179193Sjb
93179193Sjb.include "../common.mk"
94179193Sjb.include <bsd.lib.mk>
95179193Sjb