xref: /freebsd/contrib/bsddialog/Makefile (revision d4ca001544347e217e2ab023cca88b30637def98)
1# PUBLIC DOMAIN - NO WARRANTY, see:
2#     <http://creativecommons.org/publicdomain/zero/1.0/>
3#
4# Written in 2023 by Alfonso Sabato Siciliano
5
6OUTPUT = bsddialog
7export VERSION=1.0.4
8.CURDIR ?= ${CURDIR}
9LIBPATH = ${.CURDIR}/lib
10LIBBSDDIALOG = ${LIBPATH}/libbsddialog.so
11UTILITYPATH = ${.CURDIR}/utility
12
13RM= rm -f
14LN = ln -s -f
15
16### command-line options ###
17# FreeBSD port Makefile: 'MAKE_ARGS = -DNORPATH'
18NORPATH ?=
19export DISABLERPATH=${NORPATH}
20# Debug: `make -DDEBUG` or `gmake DEBUG=1`
21DEBUG ?=
22export ENABLEDEBUG=${DEBUG}
23###################
24
25all : ${OUTPUT}
26
27${OUTPUT}: ${LIBBSDDIALOG}
28	${MAKE} -C ${UTILITYPATH} LIBPATH=${LIBPATH}
29	${LN} ${UTILITYPATH}/${OUTPUT} ${.CURDIR}/${OUTPUT}
30
31${LIBBSDDIALOG}:
32	${MAKE} -C ${LIBPATH}
33
34clean:
35	${MAKE} -C ${LIBPATH} clean
36	${MAKE} -C ${UTILITYPATH} clean
37	${RM} ${OUTPUT} *.core
38
39