Update editors/the to version 3.3.r4_2
[dports.git] / editors / the / Makefile
1 # Created by: giffunip@asme.org
2 # $FreeBSD$
3
4 PORTNAME=       the
5 PORTVERSION=    3.3.r4
6 PORTREVISION=   2
7 CATEGORIES=     editors
8 MASTER_SITES=   http://downloads.sourceforge.net/hessling-editor/
9 DISTNAME=       THE-${PORTVERSION:S/.r/RC/}
10
11 MAINTAINER=     comet.berkeley@gmail.com
12 COMMENT=        THE, The Hessling Editor, is like the vm/cms xedit editor
13
14 LICENSE=        GPLv2
15
16 BROKEN_powerpc= fails to configure
17
18 GNU_CONFIGURE=  yes
19 CONFIGURE_ARGS= --with-rexxincdir=${LOCALBASE}/include \
20                 --with-rexxlibdir=${LOCALBASE}/lib
21 ALL_TARGET=     all html
22 CPPFLAGS+=      -I${LOCALBASE}/include
23
24 OPTIONS_DEFINE=         XAW3D
25 OPTIONS_SINGLE=         Display Rexx
26 OPTIONS_SINGLE_Display= NCURSES XCURSES
27 OPTIONS_SINGLE_Rexx=    REXX_IMC REGINA
28 OPTIONS_DEFAULT=        NCURSES REGINA
29 OPTIONS_SUB=            yes
30
31 XAW3D_DESC=             Enable Xaw3D
32 NCURSES_DESC=           Build standard NCurses version
33 XCURSES_DESC=           Build XCurses (X11) version
34 REXX_IMC_DESC=          Use Rexx/imc interpreter
35 REGINA_DESC=            Use Regina Rexx interpreter
36
37 XAW3D_CONFIGURE_WITH=   xaw3d
38 XAW3D_BUILD_DEPENDS=    ${LOCALBASE}/lib/libXaw3d.a:x11-toolkits/Xaw3d
39
40 NCURSES_USES=           ncurses
41 NCURSES_CONFIGURE_ON=   --with-ncurses \
42                         --with-cursesincdir=${NCURSESINC} \
43                         --with-curseslibdir=${NCURSESLIB}
44
45 XCURSES_LIB_DEPENDS=    libXCurses.so:devel/pdcurses
46 XCURSES_CONFIGURE_ON=   --with-xcurses \
47                         --with-cursesincdir=${LOCALBASE}/include \
48                         --with-curseslibdir=${LOCALBASE}/lib
49 XCURSES_CFLAGS=         -I${LOCALBASE}/include \
50                         -I${LOCALBASE}/include/xcurses
51
52 REXX_IMC_CONFIGURE_ON=  --with-rexx=rexximc
53 REXX_IMC_BUILD_DEPENDS= rexx:lang/rexx-imc
54 REXX_IMC_RUN_DEPENDS=   rexx:lang/rexx-imc
55 REXX_IMC_BROKEN=        fails to build with REXX_IMC option
56
57 REGINA_CONFIGURE_ON=    --with-rexx=regina
58 REGINA_BUILD_DEPENDS=   regina:lang/rexx-regina
59 REGINA_RUN_DEPENDS=     regina:lang/rexx-regina
60
61 post-extract:
62         ${REINPLACE_CMD} -e 's|(datadir)/THE|(datadir)/the|g' \
63                         -e 's|/share/THE|/share/the|g' ${WRKSRC}/Makefile.in
64         ${REINPLACE_CMD} -e 's|ltermcap|lncurses|g' ${WRKSRC}/configure
65         ${REINPLACE_CMD} -e '/FUNCTION_KEY/d' ${WRKSRC}/the.c
66
67 pre-install:
68         ${MKDIR}                                ${STAGEDIR}${DOCSDIR}
69         ${INSTALL_DATA} ${WRKSRC}/*.html        ${STAGEDIR}${DOCSDIR}
70         ${INSTALL_DATA} ${WRKSRC}/the64.gif     ${STAGEDIR}${DOCSDIR}
71         ${INSTALL_DATA} ${WRKSRC}/the64.png     ${STAGEDIR}${DOCSDIR}
72
73 do-install-XCURSES-on:
74         ${STRIP_CMD}    ${STAGEDIR}${PREFIX}/bin/xthe
75         ${LN} -sf xthe  ${STAGEDIR}${PREFIX}/bin/the
76
77 do-install-NCURSES-on:
78         ${STRIP_CMD}    ${STAGEDIR}${PREFIX}/bin/nthe
79         ${LN} -sf nthe  ${STAGEDIR}${PREFIX}/bin/the
80
81 .include <bsd.port.mk>