update Thu Feb 25 12:37:00 PST 2010
[pkgsrc.git] / www / lynx / options.mk
1 # $NetBSD: options.mk,v 1.12 2010/02/25 18:50:21 drochner Exp $
2
3 PKG_OPTIONS_VAR=        PKG_OPTIONS.lynx
4 PKG_SUPPORTED_OPTIONS=  inet6
5 PKG_SUGGESTED_OPTIONS=  curses
6
7 PKG_OPTIONS_OPTIONAL_GROUPS=    socksproxy
8 PKG_OPTIONS_GROUP.socksproxy=   socks5 socks4
9
10 PKG_OPTIONS_REQUIRED_GROUPS=    screen
11 PKG_OPTIONS_GROUP.screen=       ncurses ncursesw slang curses
12
13 .include "../../mk/bsd.options.mk"
14
15 ###
16 ### We can't compile support for both the "slang" screen library and
17 ### SOCKS support.
18 ###
19 .if !empty(PKG_OPTIONS:Mslang) && !empty(PKG_OPTIONS:Msocks*)
20 PKG_FAIL_REASON+=       "SOCKS may not be enabled together with the \"slang\"" \
21                         "screen library.  If SOCKS support is desired," \
22                         "please change ${PKG_OPTIONS_VAR} to include" \
23                         "\"curses\" or \"ncurses\" instead."
24 .endif
25
26 ###
27 ### Set the screen library to "slang", "ncurses", or plain "curses".
28 ###
29 .if !empty(PKG_OPTIONS:Mslang)
30 SCREENTYPE=             slang
31 .  include "../../devel/libslang/buildlink3.mk"
32 post-install:
33         ${INSTALL_DATA} ${WRKSRC}/samples/lynx.lss \
34                 ${DESTDIR}${PREFIX}/share/examples/lynx/lynx.lss
35 .endif
36 .if !empty(PKG_OPTIONS:Mncurses)
37 SCREENTYPE=             ncurses
38 USE_NCURSES=            YES # color
39 .  include "../../devel/ncurses/buildlink3.mk"
40 CONFIGURE_ARGS+=        --enable-color-style
41 .endif
42 .if !empty(PKG_OPTIONS:Mncursesw)
43 SCREENTYPE=             ncurses
44 LIBS+=                  -lncursesw
45 .  include "../../devel/ncursesw/buildlink3.mk"
46 CONFIGURE_ARGS+=        --enable-color-style
47 .endif
48 .if !empty(PKG_OPTIONS:Mcurses)
49 SCREENTYPE=             curses
50 .  include "../../mk/curses.buildlink3.mk"
51 .  if !empty(MACHINE_PLATFORM:MNetBSD-1.[56]*-i386)
52 CONFIGURE_ARGS+=        --enable-color-style
53 .  endif
54 .endif
55
56 ###
57 ### SOCKS support
58 ###
59 .if !empty(PKG_OPTIONS:Msocks4)
60 CONFIGURE_ARGS+=        --with-socks
61 .  include "../../net/socks4/buildlink3.mk"
62 .endif
63 .if !empty(PKG_OPTIONS:Msocks5)
64 CONFIGURE_ARGS+=        --with-socks5
65 .  include "../../net/socks5/buildlink3.mk"
66 .endif
67
68 ###
69 ### IPv6 support
70 ###
71 .if !empty(PKG_OPTIONS:Minet6)
72 CONFIGURE_ARGS+=       --enable-ipv6
73 .endif