Changeset View
Changeset View
Standalone View
Standalone View
head/mail/alpine/Makefile
# $FreeBSD$ | # $FreeBSD$ | ||||
PORTNAME?= alpine | PORTNAME?= alpine | ||||
PORTVERSION= 2.21 | PORTVERSION= 2.21 | ||||
PORTREVISION?= 0 | PORTREVISION?= 1 | ||||
CATEGORIES?= mail news ipv6 | CATEGORIES?= mail news ipv6 | ||||
MASTER_SITES= http://alpine.freeiz.com/alpine/release/src/ | MASTER_SITES= http://alpine.freeiz.com/alpine/release/src/ | ||||
DIST_SUBDIR= alpine-${PORTVERSION} | DIST_SUBDIR= alpine-${PORTVERSION} | ||||
MAINTAINER= mbeis@xs4all.nl | MAINTAINER= mbeis@xs4all.nl | ||||
COMMENT?= Mail and news client descended from Pine | COMMENT?= Mail and news client descended from Pine | ||||
LICENSE= APACHE20 | LICENSE= APACHE20 | ||||
OPTIONS_DEFINE= DOCS SSL THREADS MOUSE NLS ISPELL NOSPELL | USES+= ssl libtool ncurses tar:xz gettext-runtime | ||||
OPTIONS_DEFAULT+= SSL THREADS MOUSE | GNU_CONFIGURE= yes | ||||
SSL_DESC= Build with SSL (installs: security/openssl if pre 10.x) | MAKE_JOBS_UNSAFE= yes | ||||
MOUSE_DESC= Enable mouse support for xterm | CONFIGURE_ARGS+= --with-debug-level=2 \ | ||||
ISPELL_DESC= Use ispell instead of aspell as default speller | --enable-background-post \ | ||||
NOSPELL_DESC= Use no default speller (overrides both) | --without-krb5 \ | ||||
--without-tcl \ | |||||
--with-system-pinerc=${PREFIX}/etc/alpine.conf \ | |||||
--with-system-fixed-pinerc=${PREFIX}/etc/alpine.conf.fixed \ | |||||
--with-password-prog=/usr/bin/passwd \ | |||||
--with-system-mail-directory=/var/mail \ | |||||
--with-ssl-dir=${OPENSSLDIR} \ | |||||
--with-ssl-include-dir=${OPENSSLINC} \ | |||||
--with-ssl-lib-dir=${OPENSSLLIB} \ | |||||
--with-ssl-certs-dir=${OPENSSLDIR}/certs | |||||
MAKE_ARGS+= CC="${CC}" CXX="${CXX}" GCCCFLAGS="${CFLAGS}" | |||||
.if !defined(PICO_ALPINE_SLAVE) | OPTIONS_DEFINE= ASPELL CONS25 DOCS IPV6 LDAP MAILDIR MOUSE PASSFILE NLS THREADS | ||||
OPTIONS_DEFAULT= ASPELL MOUSE THREADS | |||||
.if defined(PICO_ALPINE_SLAVE) | |||||
OPTIONS_EXCLUDE= CONS25 IPV6 LDAP MAILDIR PASSFILE | |||||
.endif | |||||
OPTIONS_DEFINE+= PICO IPV6 LDAP PASSFILE CONS25 MAILDIR SSL | |||||
OPTIONS_DEFAULT+= PICO SSL | |||||
PICO_DESC= Build and install pico, the default editor | |||||
PASSFILE_DESC= Support for a stored password file (DANGEROUS) | |||||
CONS25_DESC= Add a patch to support color for default console | CONS25_DESC= Add a patch to support color for default console | ||||
MAILDIR_DESC= Add a patch for maildir support | MAILDIR_DESC= Add a patch for maildir support | ||||
.endif | PASSFILE_DESC= Support for a stored password file | ||||
USES+= libtool ncurses tar:xz gettext-runtime | # Option ASPELL | ||||
ASPELL_CONFIGURE_ON= --with-interactive-spellcheck=${LOCALBASE}/bin/aspell | |||||
ASPELL_CONFIGURE_OFF= --with-simple-spellcheck | |||||
ASPELL_BUILD_DEPENDS= aspell:textproc/aspell | |||||
ASPELL_RUN_DEPENDS= aspell:textproc/aspell | |||||
MAKE_JOBS_UNSAFE= yes | # Option CONS25 | ||||
CONS25_EXTRA_PATCHES= ${FILESDIR}/cons25-alpine_keymenu.c | |||||
GNU_CONFIGURE= yes | # Option IPV6 | ||||
IPV6_CONFIGURE_WITH= ipv6 | |||||
THREADS_CONFIGURE_WITH= pthread | # Option LDAP | ||||
LDAP_USE= openldap=yes | |||||
LDAP_CONFIGURE_WITH= ldap | |||||
LDAP_CONFIGURE_ON= --with-ldap-dir=${LOCALBASE} | |||||
# Option MAILDIR | |||||
MAILDIR_PATCH_SITES= http://alpine.freeiz.com/alpine/patches/alpine-${PORTVERSION}/ | |||||
MAILDIR_PATCHFILES+= maildir.patch.gz:-p1 | |||||
# Option MOUSE | |||||
MOUSE_CONFIGURE_ENABLE= mouse | MOUSE_CONFIGURE_ENABLE= mouse | ||||
# Option NLS | |||||
NLS_CONFIGURE_ENABLE= nls | NLS_CONFIGURE_ENABLE= nls | ||||
IPV6_CONFIGURE_WITH= ipv6 | |||||
SSL_USES= ssl | |||||
.if !defined(PICO_ALPINE_SLAVE) | # Option PASSFILE | ||||
PASSFILE_CONFIGURE_WITH= passfile | |||||
PASSFILE_CONFIGURE_ON= --with-passfile=.alpine.pwd | |||||
# Option THREADS | |||||
THREADS_CONFIGURE_WITH= pthread | |||||
.if !defined(PICO_ALPINE_SLAVE) | |||||
PORTDOCSbase= LICENSE NOTICE README | PORTDOCSbase= LICENSE NOTICE README | ||||
PORTDOCSdoc= brochure.txt | PORTDOCSdoc= brochure.txt | ||||
PORTDOCShtml= tech-notes/background.html tech-notes/cmd-line.html \ | PORTDOCShtml= tech-notes/background.html tech-notes/cmd-line.html \ | ||||
tech-notes/config-notes.html tech-notes/config.html \ | tech-notes/config-notes.html tech-notes/config.html \ | ||||
tech-notes/index.html tech-notes/installation.html \ | tech-notes/index.html tech-notes/installation.html \ | ||||
tech-notes/introduction.html tech-notes/low-level.html \ | tech-notes/introduction.html tech-notes/low-level.html \ | ||||
tech-notes/tech-notes.txt | tech-notes/tech-notes.txt | ||||
PORTDOCS= ${PORTDOCSbase} ${PORTDOCSdoc} ${PORTDOCShtml} | PORTDOCS= ${PORTDOCSbase} ${PORTDOCSdoc} ${PORTDOCShtml} | ||||
CONFIGURE_ARGS+=--with-system-pinerc=${PREFIX}/etc/alpine.conf \ | |||||
--with-system-fixed-pinerc=${PREFIX}/etc/alpine.conf.fixed \ | |||||
--with-password-prog=/usr/bin/passwd \ | |||||
--with-system-mail-directory=/var/mail | |||||
.endif | |||||
CONFIGURE_ARGS+=--with-debug-level=2 \ | |||||
--enable-background-post --without-krb5 --without-tcl | |||||
MAKE_ARGS+= CC="${CC}" CXX="${CXX}" GCCCFLAGS="${CFLAGS}" | |||||
.include <bsd.port.options.mk> | |||||
.if ${PORT_OPTIONS:MSSL} | |||||
CONFIGURE_ARGS+= --with-ssl-dir=${OPENSSLDIR} \ | |||||
--with-ssl-include-dir=${OPENSSLINC} \ | |||||
--with-ssl-lib-dir=${OPENSSLLIB} \ | |||||
--with-ssl-certs-dir=${OPENSSLDIR}/certs | |||||
.else | |||||
CONFIGURE_ARGS+= --without-ssl | |||||
.endif | |||||
.include <bsd.port.pre.mk> | |||||
.if ${PORT_OPTIONS:MSSL} && ${SSL_DEFAULT:Mopenssl-devel} | |||||
BROKEN= Does not build with openssl-devel | |||||
.endif | |||||
.if ! ${PORT_OPTIONS:MNOSPELL} | |||||
.if ! ${PORT_OPTIONS:MISPELL} | |||||
CONFIGURE_ARGS+=--with-interactive-spellcheck=${LOCALBASE}/bin/aspell | |||||
BUILD_DEPENDS+= aspell:textproc/aspell | |||||
RUN_DEPENDS+= aspell:textproc/aspell | |||||
.else | |||||
CONFIGURE_ARGS+= --with-interactive-spellcheck=${LOCALBASE}/bin/ispell | |||||
BUILD_DEPENDS+= ispell:textproc/aspell-ispell | |||||
RUN_DEPENDS+= ispell:textproc/aspell-ispell | |||||
.endif | |||||
.else | |||||
CONFIGURE_ARGS+=--without-simple-spellcheck --without-interactive-spellcheck | |||||
.endif | |||||
.if !defined(PICO_ALPINE_SLAVE) | |||||
.if ${PORT_OPTIONS:MPICO} | |||||
RUN_DEPENDS+= pico:editors/pico-alpine | |||||
.endif | |||||
.if ${PORT_OPTIONS:MLDAP} | |||||
USE_OPENLDAP= yes | |||||
CONFIGURE_ARGS+= --with-ldap-dir=${LOCALBASE} | |||||
.else | |||||
CONFIGURE_ARGS+= --without-ldap | |||||
.endif | |||||
.if ${PORT_OPTIONS:MPASSFILE} | |||||
ALPINE_PASSFILE?= .alpine.pwd | |||||
CONFIGURE_ARGS+= --with-passfile=.alpine.pwd | |||||
.endif | |||||
.if ${PORT_OPTIONS:MMAILDIR} | |||||
PATCH_SITES= http://alpine.freeiz.com/alpine/patches/alpine-${PORTVERSION}/ | |||||
PATCHFILES+= maildir.patch.gz:-p1 | |||||
.endif | |||||
.if ${PORT_OPTIONS:MCONS25} | |||||
EXTRA_PATCHES= ${FILESDIR}/cons25-alpine_keymenu.c | |||||
.endif | |||||
post-patch: | post-patch: | ||||
@${CP} ${WRKSRC}/imap/Makefile ${WRKSRC}/imap/Makefile.presed | @${CP} ${WRKSRC}/imap/Makefile ${WRKSRC}/imap/Makefile.presed | ||||
@${SED} -e "s#^\(all:.*\) bundled\$$#\1#" \ | @${SED} -e "s#^\(all:.*\) bundled\$$#\1#" \ | ||||
${WRKSRC}/imap/Makefile.presed > ${WRKSRC}/imap/Makefile | ${WRKSRC}/imap/Makefile.presed > ${WRKSRC}/imap/Makefile | ||||
@${CP} ${WRKSRC}/pico/Makefile.in ${WRKSRC}/pico/Makefile.in.presed | @${CP} ${WRKSRC}/pico/Makefile.in ${WRKSRC}/pico/Makefile.in.presed | ||||
@${SED} -e "s#^bin_PROGRAMS = pico.*#bin_PROGRAMS =#" \ | @${SED} -e "s#^bin_PROGRAMS = pico.*#bin_PROGRAMS =#" \ | ||||
-e "s#\$$(pico_SOURCES) \$$(pilot_SOURCES)##" \ | -e "s#\$$(pico_SOURCES) \$$(pilot_SOURCES)##" \ | ||||
${WRKSRC}/pico/Makefile.in.presed > ${WRKSRC}/pico/Makefile.in | ${WRKSRC}/pico/Makefile.in.presed > ${WRKSRC}/pico/Makefile.in | ||||
Show All 16 Lines | ${SED} -e "s:/usr/local/lib/:${PREFIX}/etc/:g" \ | ||||
-e "s:pine\.conf:alpine.conf:g" \ | -e "s:pine\.conf:alpine.conf:g" \ | ||||
-e "s:/usr/local:${PREFIX}:g" \ | -e "s:/usr/local:${PREFIX}:g" \ | ||||
-e "s:@@PREFIX@@:${PREFIX}:g" \ | -e "s:@@PREFIX@@:${PREFIX}:g" \ | ||||
$$i.presed > $$i ; \ | $$i.presed > $$i ; \ | ||||
done | done | ||||
post-install: | post-install: | ||||
${STAGEDIR}${PREFIX}/bin/alpine -conf > ${STAGEDIR}${PREFIX}/etc/alpine.conf.sample | ${STAGEDIR}${PREFIX}/bin/alpine -conf > ${STAGEDIR}${PREFIX}/etc/alpine.conf.sample | ||||
.if ${PORT_OPTIONS:MDOCS} | |||||
post-install-DOCS-on: | |||||
${INSTALL} -d ${STAGEDIR}${DOCSDIR} ${STAGEDIR}${DOCSDIR}/tech-notes | ${INSTALL} -d ${STAGEDIR}${DOCSDIR} ${STAGEDIR}${DOCSDIR}/tech-notes | ||||
.for f in ${PORTDOCSbase} | .for f in ${PORTDOCSbase} | ||||
${INSTALL_MAN} ${WRKSRC}/$f ${STAGEDIR}${DOCSDIR} | ${INSTALL_MAN} ${WRKSRC}/$f ${STAGEDIR}${DOCSDIR} | ||||
.endfor | .endfor | ||||
.for f in ${PORTDOCSdoc} | .for f in ${PORTDOCSdoc} | ||||
${INSTALL_MAN} ${WRKSRC}/doc/$f ${STAGEDIR}${DOCSDIR} | ${INSTALL_MAN} ${WRKSRC}/doc/$f ${STAGEDIR}${DOCSDIR} | ||||
.endfor | .endfor | ||||
.for f in ${PORTDOCShtml} | .for f in ${PORTDOCShtml} | ||||
${INSTALL_MAN} ${WRKSRC}/doc/$f ${STAGEDIR}${DOCSDIR}/tech-notes | ${INSTALL_MAN} ${WRKSRC}/doc/$f ${STAGEDIR}${DOCSDIR}/tech-notes | ||||
.endfor | .endfor | ||||
.endif | |||||
# PKG_PREFIX=${STAGEDIR}${PREFIX} ${SH} ${PKGINSTALL} ${PKGNAME} POST-INSTALL | |||||
# @${CAT} ${PKGMESSAGE} | |||||
.endif # !defined(PICO_ALPINE_SLAVE) | .endif # !defined(PICO_ALPINE_SLAVE) | ||||
.include <bsd.port.post.mk> | .include <bsd.port.mk> |