blob: c7e19d5c9f392bd8592a50157070891a815627e4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
# $NetBSD: buildlink2.mk,v 1.2 2002/08/25 19:22:30 jlam Exp $
.if !defined(GETOPT_BUILDLINK2_MK)
GETOPT_BUILDLINK2_MK= # defined
BUILDLINK_DEPENDS.getopt?= libgetopt>=1.3
BUILDLINK_PKGSRCDIR.getopt?= ../../devel/libgetopt
.if exists(/usr/include/getopt.h)
_NEED_GETOPT= NO
.else
_NEED_GETOPT= YES
.endif
.if ${_NEED_GETOPT} == "NO"
BUILDLINK_PREFIX.getopt= /usr
BUILDLINK_FILES.getopt= include/getopt.h
LIBGETOPT= # empty
.else
BUILDLINK_PACKAGES+= getopt
EVAL_PREFIX+= BUILDLINK_PREFIX.getopt=libgetopt
BUILDLINK_PREFIX.getopt_DEFAULT= ${LOCALBASE}
BUILDLINK_FILES.getopt= include/getopt.h
BUILDLINK_FILES.getopt+= lib/libgetopt.*
BUILDLINK_FILES.getopt+= lib/libgetopt_pic.a
LIBGETOPT= -lgetopt
.endif
CONFIGURE_ENV+= LIBGETOPT="${LIBGETOPT}"
MAKE_ENV+= LIBGETOPT="${LIBGETOPT}"
BUILDLINK_TARGETS+= getopt-buildlink
getopt-buildlink: _BUILDLINK_USE
.endif # GETOPT_BUILDLINK2_MK
|