summaryrefslogtreecommitdiff
path: root/shells/zsh/options.mk
blob: 4238285e73d39945535243507fa2368d234bb756 (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
# $NetBSD: options.mk,v 1.6 2019/03/16 14:01:45 wiz Exp $

PKG_OPTIONS_VAR=		PKG_OPTIONS.zsh
PKG_SUPPORTED_OPTIONS=		debug static

.include "../../mk/bsd.options.mk"

.if !empty(PKG_OPTIONS:Mdebug)
CONFIGURE_ARGS+=	--enable-zsh-debug
CONFIGURE_ARGS+=	--enable-zsh-hash-debug
CONFIGURE_ARGS+=	--enable-zsh-heap-debug
CONFIGURE_ARGS+=	--enable-zsh-mem-debug
CONFIGURE_ARGS+=	--enable-zsh-mem-warning
CONFIGURE_ARGS+=	--enable-zsh-secure-free
CONFIGURE_ARGS+=	--enable-zsh-mem
.endif

PLIST_VARS+=		dynamic
.if !empty(PKG_OPTIONS:Mstatic)
CONFIGURE_ARGS+=	--disable-dynamic
.  if ${OPSYS} != "Darwin" && ${OPSYS} != "SunOS"
LDFLAGS+=		-static
.  endif
.else
PLIST.dynamic=		yes
.endif
PRINT_PLIST_AWK+=	{if ($$0 ~ /\.so$$/) {$$0 = "$${PLIST.dynamic}" $$0;}}
PRINT_PLIST_AWK+=	{if ($$0 ~ /functions\/tcp/) {$$0 = "$${PLIST.dynamic}" $$0;}}
PRINT_PLIST_AWK+=	{if ($$0 ~ /functions\/zf/) {$$0 = "$${PLIST.dynamic}" $$0;}}
PRINT_PLIST_AWK+=	{if ($$0 ~ /functions\/zsh-newuser/) {$$0 = "$${PLIST.dynamic}" $$0;}}
PRINT_PLIST_AWK+=	{if ($$0 ~ /scripts\/newuser/) {$$0 = "$${PLIST.dynamic}" $$0;}}