NetBSD/usr.bin/mail/Makefile

71 lines
1.4 KiB
Makefile
Raw Normal View History

# $NetBSD: Makefile,v 1.29 2007/01/02 03:09:13 christos Exp $
1996-12-28 10:10:57 +03:00
# @(#)Makefile 8.3 (Berkeley) 4/20/95
1993-03-21 12:45:37 +03:00
.include <bsd.own.mk>
USE_EDITLINE=yes
MIME_SUPPORT=yes # currently requires USE_EDITLINE
From Anon Ymous: 1) Statification of modules. 2) Implement the 'detach' and 'Detach' commands for extracting mime parts from messages. 3) Teach mail to output "In-Reply-To" and "References" header fields when replying so others can thread us. 4) Implement threading, sorting, and tagging, supported by the following commands: 'flatten', 'reverse', 'sort', 'thread', 'unthread', 'down', 'tset', 'up', 'expose', 'hide', 'tag', 'untag', 'invtags', 'tagbelow', 'hidetags', 'showtags'. See the manpage for details (when available - soon). 5) Implement a 'deldups' command to delete duplicate messages based on their "Message-Id" field, e.g., in replies to a mailing list that are also CCed to a subscriber. (This can also be accomplished with the threading and tagging commands.) 6) Implement 'ifdef' and 'ifndef' commands, and make the conditionals nestable (i.e., implement a conditional stack). The if/else/endif commands existed before, but they were primitive and undocumented. The 'if' command currently recognizes the "receiving", "sending", and "headersonly" mode keywords. 7) Teach the message selecting routine to understand regular expressions if "regex-search" is defined. Otherwise only case insensitive substring matches are done (as in the past). 8) Teach the message selection routine to understand boolean expressions. Improved "colon-modifier" support. See the manpage for details (when available - soon). 9) Extend paging to all commands (where relevant). 10) Add shell like piping and redirection of (standard) output (if "enable-piping" is defined). Extend completion to these contexts. 11) The manpage should follow soon!!!!
2006-11-28 21:45:32 +03:00
CHARSET_SUPPORT=yes # requires MIME_SUPPORT
THREAD_SUPPORT=yes # EXPERIMENTAL
1993-03-21 12:45:37 +03:00
PROG= mail
From Anon Ymous: 1) Statification of modules. 2) Implement the 'detach' and 'Detach' commands for extracting mime parts from messages. 3) Teach mail to output "In-Reply-To" and "References" header fields when replying so others can thread us. 4) Implement threading, sorting, and tagging, supported by the following commands: 'flatten', 'reverse', 'sort', 'thread', 'unthread', 'down', 'tset', 'up', 'expose', 'hide', 'tag', 'untag', 'invtags', 'tagbelow', 'hidetags', 'showtags'. See the manpage for details (when available - soon). 5) Implement a 'deldups' command to delete duplicate messages based on their "Message-Id" field, e.g., in replies to a mailing list that are also CCed to a subscriber. (This can also be accomplished with the threading and tagging commands.) 6) Implement 'ifdef' and 'ifndef' commands, and make the conditionals nestable (i.e., implement a conditional stack). The if/else/endif commands existed before, but they were primitive and undocumented. The 'if' command currently recognizes the "receiving", "sending", and "headersonly" mode keywords. 7) Teach the message selecting routine to understand regular expressions if "regex-search" is defined. Otherwise only case insensitive substring matches are done (as in the past). 8) Teach the message selection routine to understand boolean expressions. Improved "colon-modifier" support. See the manpage for details (when available - soon). 9) Extend paging to all commands (where relevant). 10) Add shell like piping and redirection of (standard) output (if "enable-piping" is defined). Extend completion to these contexts. 11) The manpage should follow soon!!!!
2006-11-28 21:45:32 +03:00
SRCS= version.c support.c cmd1.c cmd2.c cmd3.c cmd4.c cmdtab.c collect.c \
dotlock.c edit.c fio.c format.c getname.c head.c v7.local.c lex.c \
list.c main.c names.c popen.c quit.c send.c strings.c temp.c tty.c \
vars.c
LINKS= ${BINDIR}/mail ${BINDIR}/Mail ${BINDIR}/mail ${BINDIR}/mailx
MLINKS= mail.1 Mail.1 mail.1 mailx.1
LDADD+= -lutil
DPADD+= ${LIBUTIL}
2006-10-22 01:51:47 +04:00
.if ${USE_EDITLINE:Uno} == "yes"
Jumbo mail patch from our anonymous user: 1) Use editline [optional]: Most of this code was borrowed from src/usr.bin/ftp. It does the appropriate editing, history, and completion for all mail commands (from cmdtab[]) and also does editing on header strings ('~h' inside the mail editor). 2) '-B' flag: This will suppress the "To:" line passed to sendmail. In most configurations it will lead to sendmail adding "To: undisclosed recipients;". Currently, AFAIK mail requires at least one exposed recipient address. 3) Comments in rcfile: Currently, comments in .mailrc are only supported if the first (non-white) character on a line is '#' followed by white space, i.e., '#' is a 'nop' command. This (trivial) patch allows the more normal/expected use of '#' as a comment character. It does not respect quoting, so that might be an objection which I should fix. 4) Sendmail option editing: This adds the sendmail option string to the strings editable by the '~h' command within the mail editor. Currently, you can only set this string from the command-line, which is particularly annoying when replying to mail. 5) Reply from: When replying to a message, grab the "To:" address from the message and, if there is only one such address and it does not match a list of allowed addresses (set in the "ReplyFrom" variable), pass it to sendmail as the "From:" address for the reply (with the '-f' option). I often make aliases for myself so that my primary address is not given out; if the alias gets out, I know who to blame. Unfortunately, a reply to such a message would normally use the primary address without this patch. A warning is displayed when this is going to happen so that it can be modified with '~h'. 6) CC and BCC lists: Allow '-c' and '-b' to accept white-space or ',' delimited lists. Currently, a white-space delimited list of addresses work, but a list of aliases will not get expanded. For example, currently: mail -c "foo bar" christos will fail to send mail to 'foo' and 'bar' if these are mail aliases (in ~/.mailrc); sendmail aliases (in /etc/aliases) do work. 7) pipe command: This pipes the current message into a shell command. I use this for quick decoding of uuencoded mail, but I can imagine it might be useful for decrypting encrypted mail, too. 8) show command: This command takes a list of variables and shows their values. It is probably stupid as the 'set' command without any argument displays all variable values. Of course, if there are a lot of variables you have to sift through the list for the one(s) you want.
2006-09-18 23:46:21 +04:00
SRCS+= complete.c
CPPFLAGS+= -DUSE_EDITLINE
LDADD+= -ledit -ltermcap
DPADD+= ${LIBEDIT} ${LIBTERMCAP}
Jumbo mail patch from our anonymous user: 1) Use editline [optional]: Most of this code was borrowed from src/usr.bin/ftp. It does the appropriate editing, history, and completion for all mail commands (from cmdtab[]) and also does editing on header strings ('~h' inside the mail editor). 2) '-B' flag: This will suppress the "To:" line passed to sendmail. In most configurations it will lead to sendmail adding "To: undisclosed recipients;". Currently, AFAIK mail requires at least one exposed recipient address. 3) Comments in rcfile: Currently, comments in .mailrc are only supported if the first (non-white) character on a line is '#' followed by white space, i.e., '#' is a 'nop' command. This (trivial) patch allows the more normal/expected use of '#' as a comment character. It does not respect quoting, so that might be an objection which I should fix. 4) Sendmail option editing: This adds the sendmail option string to the strings editable by the '~h' command within the mail editor. Currently, you can only set this string from the command-line, which is particularly annoying when replying to mail. 5) Reply from: When replying to a message, grab the "To:" address from the message and, if there is only one such address and it does not match a list of allowed addresses (set in the "ReplyFrom" variable), pass it to sendmail as the "From:" address for the reply (with the '-f' option). I often make aliases for myself so that my primary address is not given out; if the alias gets out, I know who to blame. Unfortunately, a reply to such a message would normally use the primary address without this patch. A warning is displayed when this is going to happen so that it can be modified with '~h'. 6) CC and BCC lists: Allow '-c' and '-b' to accept white-space or ',' delimited lists. Currently, a white-space delimited list of addresses work, but a list of aliases will not get expanded. For example, currently: mail -c "foo bar" christos will fail to send mail to 'foo' and 'bar' if these are mail aliases (in ~/.mailrc); sendmail aliases (in /etc/aliases) do work. 7) pipe command: This pipes the current message into a shell command. I use this for quick decoding of uuencoded mail, but I can imagine it might be useful for decrypting encrypted mail, too. 8) show command: This command takes a list of variables and shows their values. It is probably stupid as the 'set' command without any argument displays all variable values. Of course, if there are a lot of variables you have to sift through the list for the one(s) you want.
2006-09-18 23:46:21 +04:00
2006-10-22 01:51:47 +04:00
.if ${MIME_SUPPORT:Uno} == "yes"
SRCS+= mime_attach.c
SRCS+= mime_child.c
SRCS+= mime_codecs.c
SRCS+= mime_decode.c
From Anon Ymous: 1) Statification of modules. 2) Implement the 'detach' and 'Detach' commands for extracting mime parts from messages. 3) Teach mail to output "In-Reply-To" and "References" header fields when replying so others can thread us. 4) Implement threading, sorting, and tagging, supported by the following commands: 'flatten', 'reverse', 'sort', 'thread', 'unthread', 'down', 'tset', 'up', 'expose', 'hide', 'tag', 'untag', 'invtags', 'tagbelow', 'hidetags', 'showtags'. See the manpage for details (when available - soon). 5) Implement a 'deldups' command to delete duplicate messages based on their "Message-Id" field, e.g., in replies to a mailing list that are also CCed to a subscriber. (This can also be accomplished with the threading and tagging commands.) 6) Implement 'ifdef' and 'ifndef' commands, and make the conditionals nestable (i.e., implement a conditional stack). The if/else/endif commands existed before, but they were primitive and undocumented. The 'if' command currently recognizes the "receiving", "sending", and "headersonly" mode keywords. 7) Teach the message selecting routine to understand regular expressions if "regex-search" is defined. Otherwise only case insensitive substring matches are done (as in the past). 8) Teach the message selection routine to understand boolean expressions. Improved "colon-modifier" support. See the manpage for details (when available - soon). 9) Extend paging to all commands (where relevant). 10) Add shell like piping and redirection of (standard) output (if "enable-piping" is defined). Extend completion to these contexts. 11) The manpage should follow soon!!!!
2006-11-28 21:45:32 +03:00
SRCS+= mime_detach.c
SRCS+= mime_header.c
CPPFLAGS+= -DMIME_SUPPORT
2006-10-22 01:51:47 +04:00
.if ${CHARSET_SUPPORT:Uno} == "yes"
CPPFLAGS+= -DCHARSET_SUPPORT
.endif
LDADD+= -lmagic -lz
DPADD+= ${LIBMAGIC} ${LIBZ}
.endif
Jumbo mail patch from our anonymous user: 1) Use editline [optional]: Most of this code was borrowed from src/usr.bin/ftp. It does the appropriate editing, history, and completion for all mail commands (from cmdtab[]) and also does editing on header strings ('~h' inside the mail editor). 2) '-B' flag: This will suppress the "To:" line passed to sendmail. In most configurations it will lead to sendmail adding "To: undisclosed recipients;". Currently, AFAIK mail requires at least one exposed recipient address. 3) Comments in rcfile: Currently, comments in .mailrc are only supported if the first (non-white) character on a line is '#' followed by white space, i.e., '#' is a 'nop' command. This (trivial) patch allows the more normal/expected use of '#' as a comment character. It does not respect quoting, so that might be an objection which I should fix. 4) Sendmail option editing: This adds the sendmail option string to the strings editable by the '~h' command within the mail editor. Currently, you can only set this string from the command-line, which is particularly annoying when replying to mail. 5) Reply from: When replying to a message, grab the "To:" address from the message and, if there is only one such address and it does not match a list of allowed addresses (set in the "ReplyFrom" variable), pass it to sendmail as the "From:" address for the reply (with the '-f' option). I often make aliases for myself so that my primary address is not given out; if the alias gets out, I know who to blame. Unfortunately, a reply to such a message would normally use the primary address without this patch. A warning is displayed when this is going to happen so that it can be modified with '~h'. 6) CC and BCC lists: Allow '-c' and '-b' to accept white-space or ',' delimited lists. Currently, a white-space delimited list of addresses work, but a list of aliases will not get expanded. For example, currently: mail -c "foo bar" christos will fail to send mail to 'foo' and 'bar' if these are mail aliases (in ~/.mailrc); sendmail aliases (in /etc/aliases) do work. 7) pipe command: This pipes the current message into a shell command. I use this for quick decoding of uuencoded mail, but I can imagine it might be useful for decrypting encrypted mail, too. 8) show command: This command takes a list of variables and shows their values. It is probably stupid as the 'set' command without any argument displays all variable values. Of course, if there are a lot of variables you have to sift through the list for the one(s) you want.
2006-09-18 23:46:21 +04:00
.endif
From Anon Ymous: 1) Statification of modules. 2) Implement the 'detach' and 'Detach' commands for extracting mime parts from messages. 3) Teach mail to output "In-Reply-To" and "References" header fields when replying so others can thread us. 4) Implement threading, sorting, and tagging, supported by the following commands: 'flatten', 'reverse', 'sort', 'thread', 'unthread', 'down', 'tset', 'up', 'expose', 'hide', 'tag', 'untag', 'invtags', 'tagbelow', 'hidetags', 'showtags'. See the manpage for details (when available - soon). 5) Implement a 'deldups' command to delete duplicate messages based on their "Message-Id" field, e.g., in replies to a mailing list that are also CCed to a subscriber. (This can also be accomplished with the threading and tagging commands.) 6) Implement 'ifdef' and 'ifndef' commands, and make the conditionals nestable (i.e., implement a conditional stack). The if/else/endif commands existed before, but they were primitive and undocumented. The 'if' command currently recognizes the "receiving", "sending", and "headersonly" mode keywords. 7) Teach the message selecting routine to understand regular expressions if "regex-search" is defined. Otherwise only case insensitive substring matches are done (as in the past). 8) Teach the message selection routine to understand boolean expressions. Improved "colon-modifier" support. See the manpage for details (when available - soon). 9) Extend paging to all commands (where relevant). 10) Add shell like piping and redirection of (standard) output (if "enable-piping" is defined). Extend completion to these contexts. 11) The manpage should follow soon!!!!
2006-11-28 21:45:32 +03:00
.if ${THREAD_SUPPORT:Uno} == "yes"
SRCS+= thread.c
CPPFLAGS+= -DTHREAD_SUPPORT
.endif
Jumbo mail patch from our anonymous user: 1) Use editline [optional]: Most of this code was borrowed from src/usr.bin/ftp. It does the appropriate editing, history, and completion for all mail commands (from cmdtab[]) and also does editing on header strings ('~h' inside the mail editor). 2) '-B' flag: This will suppress the "To:" line passed to sendmail. In most configurations it will lead to sendmail adding "To: undisclosed recipients;". Currently, AFAIK mail requires at least one exposed recipient address. 3) Comments in rcfile: Currently, comments in .mailrc are only supported if the first (non-white) character on a line is '#' followed by white space, i.e., '#' is a 'nop' command. This (trivial) patch allows the more normal/expected use of '#' as a comment character. It does not respect quoting, so that might be an objection which I should fix. 4) Sendmail option editing: This adds the sendmail option string to the strings editable by the '~h' command within the mail editor. Currently, you can only set this string from the command-line, which is particularly annoying when replying to mail. 5) Reply from: When replying to a message, grab the "To:" address from the message and, if there is only one such address and it does not match a list of allowed addresses (set in the "ReplyFrom" variable), pass it to sendmail as the "From:" address for the reply (with the '-f' option). I often make aliases for myself so that my primary address is not given out; if the alias gets out, I know who to blame. Unfortunately, a reply to such a message would normally use the primary address without this patch. A warning is displayed when this is going to happen so that it can be modified with '~h'. 6) CC and BCC lists: Allow '-c' and '-b' to accept white-space or ',' delimited lists. Currently, a white-space delimited list of addresses work, but a list of aliases will not get expanded. For example, currently: mail -c "foo bar" christos will fail to send mail to 'foo' and 'bar' if these are mail aliases (in ~/.mailrc); sendmail aliases (in /etc/aliases) do work. 7) pipe command: This pipes the current message into a shell command. I use this for quick decoding of uuencoded mail, but I can imagine it might be useful for decrypting encrypted mail, too. 8) show command: This command takes a list of variables and shows their values. It is probably stupid as the 'set' command without any argument displays all variable values. Of course, if there are a lot of variables you have to sift through the list for the one(s) you want.
2006-09-18 23:46:21 +04:00
WARNS= 4
CWARNFLAGS+= -Wextra
2002-03-02 18:29:49 +03:00
.PATH: ${.CURDIR}/misc
.if ${MKSHARE} != "no"
FILESDIR= /usr/share/misc
FILES= mail.help mail.tildehelp
1993-03-21 12:45:37 +03:00
1994-08-13 13:55:52 +04:00
.if make(install)
SUBDIR+= USD.doc
.endif
.endif
1994-08-13 13:55:52 +04:00
CONFIGFILES= mail.rc
FILESDIR_mail.rc= /etc
1993-03-21 12:45:37 +03:00
.include <bsd.prog.mk>
1997-10-11 13:34:07 +04:00
.include <bsd.subdir.mk>