summaryrefslogtreecommitdiffstats
path: root/Makefile.am
AgeCommit message (Collapse)Author
2022-01-13Add config.h dependency for keymap_defs.h generation.Kevin McCarthy
Ensure the header is regenerated if configure is re-run. The $(OPS) list might change as a result of re-configure, but the timestamps of those files won't. However, config.h will change so we can check that as a dependency.
2021-12-27Merge branch 'stable'Kevin McCarthy
2021-12-27Include <term.h> before invoking tigetstr() and tigetflag().Kevin McCarthy
On NetBSD, a segv was occurring in mutt_ts_capability() because tigetstr() was implicitly declared and thus defaulted to return type int. The 8-byte (char *) actually returned was being converted to a 4-byte int before being assigned to the (char *) variable. This resulted in a corrupted pointer, causing a segv when dereferenced. I thought C99+ should warn about implicit declarations. Although configure.ac AC_PROG_CC_C99 asserts the compiler can handle C99, perhaps it doesn't put the compiler in the mode to strictly enforce it. (Thanks to rkta on IRC for the input). The solution, as the man page notes, is to include <term.h> before invoking those functions. Unfortunately term.h pollutes the namespace with all sorts of defines. Currently that include columns and lines, which are used inside Mutt. To help prevent issues, create Mutt wrappers for the functions and split them into a separate file, curs_ti_lib.c, that #include <term.h>, rather than just adding #include <term.h> to mutt_curses.h Apparently on some older platforms, #include <curses.h> would also include term.h, so make sure columns in undef'ed in mutt_curses.h. (I think we would have heard about that problem already, but just in case.) A huge thank you to rahl on IRC for debugging this issue, and working with me over IRC to test various suggestions until the issue was found. I didn't have access to a NetBSD instance, so rahl saved me much time and effort, and was crucial to fixing this bug.
2021-12-23Add GNU SASL support for authentication.Kevin McCarthy
It turns out Cyrus SASL's license may not be compatible with GPL programs, see Debian Bug 999672. So, add support for the GNU SASL library, using configure option --with-gsasl. I haven't touched the Cyrus SASL code in Mutt all that much in the past, but I've done my best to keep the gsasl code clean and simple. There are likely mistakes to be fixed and additions to be made, though. I queried the gsasl mailing list about the need for a socket wrapper (as is done for the cyrus code), and it seems this should no longer be needed. As long as GSASL_QOP is left at the default (qop-auth), the client should ask for authentication, and not negotiate integrity or confidentiality. (Thanks to Phil Pennock and Simon Josefsson for their reponses - although the blame is fully on *me* if this turns out to be incorrect). Therefore there is no CONNECTION wrapping in this implementation. Add multiline response support for SMTP authentication (which is probably not actually needed). Also add arbitrary line length for the SASL server responses (the RFCs note that for SASL, the protocol line lengths don't apply).
2021-08-24Improve conststrings.c generation, mainly for GNU Autoconf 2.71.Vincent Lefevre
With GNU Autoconf 2.71, the "ac_cs_config=" line in config.status may contain sequences like '\'' when a configure argument has spaces in it, for instance CFLAGS with several options. Thus it is not sufficient to get this line with grep; one needs to eval it and output the result. GNU Autoconf 2.69 was including the whole $ac_cs_config value inside double quotes, and the previous code also had issues with configure arguments containing special characters (but spaces were fine).
2021-04-15Use bkgrndset() as ATTRSET() backend if available.Kevin McCarthy
This function allows more usable color pairs, because it passes the pair parameter separately. The COLOR_PAIR() macro only returns 8-bits for a pair, limiting the total pairs used to 256 despite many systems having much larger COLOR_PAIRS values. In order to do this, separate out the pair and attrs values, instead of combining attr + COLOR_PAIR(pair) into a single value and storing that inside Mutt. For the older calls, bkgdset() and attrset(), we call COLOR_PAIR() at the last minute. Add COLOR_ATTR to header cache sum calculation, since it is used in the HEADER now.
2021-02-21Fix gettext update problems.Kevin McCarthy
The keymap_alldefs.h file was previously generated and scanned inside po/Makefile.in.in as an additional POTFILES files build dependency and step. The file can't be scanned by just adding it to po/POTFILES.in because it's a generated file that will be in the build directory. The next commit will instead add the OPS* files directly to POTFILES.in to be scanned. For this commit, remove the generation of keymap_alldefs.h. Remove the redundant ALL_LINGUAS setting from configure.ac. Reformat the LINGUAS file to be on one line, as the documentation shows. I think it was okay before, but just to be safe. Fix L10N scanning by adding '--add-comments=L10N' to XGETTEXT_OPTIONS in po/Makevars. Set MSGID_BUGS_ADDRESS to silence a warning. Add gettext.h to the Makefile.am EXTRA_DIST list. Remove -Iintl flags from all Makefile.am files, since the intl directory is no longer bundled in Mutt.
2021-02-18Update gettext to version 0.21.Kevin McCarthy
Run 'gettextize -f --no-changelog' to update to 0.21. This removes the entire intl directory, and relies on an external libintl only. $(INTLLIBS) should now be referred to as $(LIBINTL), so change all references. Unfortunately, some of the gettext m4 files were modified and "mutt customized" in the past. I'm trying to keep them in a pristine state after this upgrade. glibc21.m4, lcmessage.m4, codeset.m4 have also been removed. Manually call AM_ICONV in configure.ac. This was previously called in the modified "MUTT_AM_GNU_GETTEXT" but the result $am_cv_func_iconv is tested just below. locale.h is a standard library defined by C99. The gpgme and pgp code wrapped those includes in HAVE_LOCALE_H checks, but that check was performed inside of gettext.m4. Remove the check inside those files (locale.h is already included unconditionally elsewhere in Mutt). Copy the sample gettext.h file and include that instead, as suggested by the gettext documentation. unistd.h is also a standard posix header, so remove HAVE_UNISTD_H checks inside mutt too. Create po/LINGUAS file listing available languages. Create po/Makevars from the template and customize for Mutt. Set PO_DEPENDS_ON_POT to no to prevent po file rebuilds. According to the gettext manual, with this set, "PO files can be accidentally updated even if a POT file is not updated" when using git.
2021-01-17Move mutt_gen_msgid() over to messageid.c.Kevin McCarthy
2021-01-14Remove snprintf and vsnprintf configure checks.Kevin McCarthy
There was a period of time where C99 was standardized but some systems still didn't include a correctly working version of those two functions. But I think we are long past that point now. Remove the checks and replacement code.
2020-12-06abstract some List-* header processingdgc
List-Post parsing is inline in the List-Post header handler. This moves it to some separate functions so that we can use it for other purposes.
2020-11-07Add missing new header files to EXTRA_mutt_SOURCES.Kevin McCarthy
I forgot to add the mutt_lisp.h and mutt_random.h files there.
2020-10-29Adjust Makefile.am to exclude BEWARE fileRemco Rijnders
2020-09-14Implement LFRS113 PRNG functionsRemco Rijnders
- Instead of relying on random() implementations which can be of questionable quality or relying on the presence of /dev/urandom, we implement our own PRNG implementation that uses the LFRS113 PRNG algorithm by Pierre L'Ecuyer. We seed this PRNG with values based on time, pid and ppid. It is OK if not all seeds are of the highest quality as all four seeds would have to be known to predict the numbers generated. In addition to this, we also use /dev/urandom values (if available) that we mix into our four seeds. In case we are reseeding we will also reuse our existing state information for setting the new seed values. - Add a function to Base64 encode 96 random bits
2020-08-25ci: enable shellcheckWilliam Yardley
2020-07-19Add first version of MuttLisp.Kevin McCarthy
This is somewhat simple enhancement to muttrc processing, not a full-blown embedded scripting language. There are no variables, functions, types, or abilities that compete with macros. MuttLisp can be invoked using the "run" command. If $muttlisp_inline_eval is set, it can also be invoked with a bare parenthesis expression as a command argument. $muttlisp_inline_eval defaults unset, to avoid breaking existing configurations, which might have bare parenthesis arguments for regexps.
2020-05-09Fix update-changelog rule (missing blank line in generated ChangeLog).Vincent Lefevre
2020-05-09Set AM_DISTCHECK_CONFIGURE_FLAGS to allow make distcheck to run.Kevin McCarthy
Add the '--with-homespool' flag, to allow it to run as non-root.
2020-03-31Add buffer.h as a dependency of hcversion.h.Kevin McCarthy
The recent BUFFER change needs to force a regeneration of hcversion.h.
2020-02-29Enable backgrounding a single <mail> function.Kevin McCarthy
Backgrounding exits to the index menu. Re-invoking <mail> will resume the backgrounded session, if one exists, otherwise start a new session. This is just to get basic support going. Multiple background edits, a landing page, a background compose menu list will be added next.
2020-02-28Create send.h header.Kevin McCarthy
This will hold the send context, so we may as well pull the prototypes into the header file too.
2020-01-09Convert hcachever.sh.in to hcachever.pl.Kevin McCarthy
Use Digest::MD5 to remove build-time dependency on mutt_md5, for cross-compilation support.
2019-11-30imap: add support for COMPRESS=DEFLATE, RFC 4978Fabian Groffen
- added mutt_zstrm which allows wrapping an existing connection with deflate/inflate (zlib compression) - call mutt_zstrm_wrap_conn when setting up an IMAP connection if the server supports COMPRESSION=DEFLATE and imap_deflate evaluates to yes - add config quad-option imap_deflate enable/disable use of (de)compression for IMAP connections, defaulting to yes - add configure check for zlib, --with-zlib to detect if mutt_zstrm can (or should) be built Tested against a Dovecot IMAP server, observed easily 7x compression rates on received data, and 5x on sent data for a normal session. Rates can be observed when the connection is closed on debug level 4 and higher. Bug: https://gitlab.com/muttmua/mutt/issues/92
2019-08-11Move LIBAUTOCRYPT before MUTTLIBS to fix building issues.Kevin McCarthy
2019-08-03Initial autoconf and makefile setup for autocrypt.Kevin McCarthy
2019-06-06Check for GNU Make to allow version.h FORCE target.Kevin McCarthy
If we're using GNU Make, the FORCE target allows automatically updating the version number after each commit. See commit 22c6df82
2019-06-03Change --disable-doc to only skip manual generation.Kevin McCarthy
Instead of skipping the entire doc directory building, just skip the manual.html, manual.txt, and mutt.info generation. Generate and install the other files in the doc directory, which don't have the same involved dependencies as the DocBook generated files.
2019-05-31Remove FORCE prerequisite on version.h.Kevin McCarthy
This is causing package build issues on OpenBSD because of a difference in make behavior. In GNU make, it always invoke the 'version.h' target, but then checks to see if version.h changed before retriggering targets with that prerequisite. On OpenBSD, invoking the version.h target always retriggers targets with that prerequisite. This means that updating the version information now requires a 'make clean' or manual removal of version.h.
2019-05-19Update gpgme and gpg-error automake checks.Kevin McCarthy
Pull updated autoconf files from the GPGME 1.13.0 release and use those new macros. Add a call to AM_PATH_GPG_ERROR() and include $(GPG_ERROR_LIBS) in the libraries. Thanks to Eike Rathke for finding the build problem, and for his patch fixing the issue. I opted for just grabbing the newest autoconf files from gpgme instead, but his fixed worked great too.
2019-04-11Generate version string during make not configureAaron Schrab
Switch to generating the version string during make process rather than at configure time. This makes it easier to keep the detailed version string accurate when doing development which doesn't require that the configure script be rerun.
2018-11-06Add monitor.h to extra_sources list.Kevin McCarthy
2018-10-06Break buffer functions into separate source file.Kevin McCarthy
2018-08-29Rename pgpring to mutt_pgpring.Kevin McCarthy
pgpring is used by another common package, signing-party. At the request of ArchLinux, I am renaming our version to be prefixed by "mutt_" in order to remove a naming conflict. This is a minor inconvenience for pgp2, pgp5, and pgp6 users, but I believe this constitutes an extremely small number of users at this point. I am keeping pgpewrap as-is because it is also used by GnuPG, and has no such naming conflict.
2018-06-03add feature file monitoring with Linux inotifyGT
2018-04-09Merge branch 'stable'Kevin McCarthy
2018-04-09Rename _regex.h to _mutt_regex.h to avoid name collision on Macs.Kevin McCarthy
On Macs, <regex.h> includes <_regex.h>. Because Mutt defines '-I .' during compilation, our bundled version of _regex.h was being used instead of the system one. I have no idea how it managed to work before, but starting in Xcode 9.3, the differences in struct size and fields started to produce a crash and other strange behavior. The real issue is our use of '-I .' during compilation, which allows our local headers to override system ones. An easier fix for now is to rename the header. Many thanks to Charles Diza, Christian Ebert, and Fabian Groffen for their help trying things out and helping to debug the problem. Also, a huge thanks to Steve Karmeinsky for allowing me to ssh in to his Mac so I could track down the underlying issue.
2018-02-06Fix document version and date for git build.Kevin McCarthy
Change mkreldate.sh to output just the date, so it can be used in the manual too.
2018-02-05Use git to generate the release date if available.Kevin McCarthy
For now, fall back to the ChangeLog. Perhaps the release date should be generated from a file, similar to VERSION, for those cases instead.
2018-02-01Add stub flea and muttbug scripts back.Kevin McCarthy
It was rightfully pointed out that the removal was too abrupt. These programs have been around for a long time, and many internet searches still say to use them for reporting bugs. Add stub versions which inform to use the gitlab url instead.
2018-01-17Remove muttbug and flea.Kevin McCarthy
We have pretty much transitioned over to gitlab.com.
2017-12-12Remove hg-commit and Makefile commit target.Kevin McCarthy
I haven't ever used this script, and we only update the ChangeLog during releases now. doc/devel-notes already mentions running check_sec.sh. Add a mention of the 'make validate' target too.
2016-11-13Compress patch from the neomutt repository.Kevin McCarthy
With the following changes: - po/de.po changes trimmed to just the compress additions. - Move the sample muttrc to contrib, and add it to the Makefile.am so it is distributed. Remove the sample vimrc. - Remove extra fluff from manual. Thanks to Roland Rosenfeld for the original patch, and to the NeoMutt team for their work cleaning up the patch.
2016-10-31Add a --disable-doc configuration option.Kevin McCarthy
This allows mutt to be built without the documentation. Thanks to Sylvain Bertrand for the original patch.
2016-07-08Fix conststrings compiler version string generation. (closes #3852)rich burridge
The Makefile.am tries compiler flags -v, --version, and -V but neglected to filter error messages if these flags aren't recognized.
2016-06-08Corrected OPS.SIDEBAR filename in EXTRA_DIST.Vincent Lefevre
2016-06-04Sidebar clean up: building and drawing logic.Kevin McCarthy
Fix the autoconf/makefile.am changes to be consistent. Create a global SidebarNeedsRedraw to indicate a redraw is needed, instead of putting sb_draw() everywhere in the code. Create a menu_redraw_sidebar() function and use the REDRAW_SIDEBAR flag instead of piggy-backing it inside the index loop. Fix curs_main.c and pager.c to be a bit cleaner by using the global and REDRAW_SIDEBAR. Start to clean up some of the buffy code, but this needs to refactored and fixed.
2016-06-04Add neomutt version of sidebar patch. (closes #3829)Richard Russon
This is the patch from neomutt; branch 'devel/win-sidebar'; commit c796fa85f9cacefb69b8f7d8545fc9ba71674180 with the following changes: - move the sample muttrc and vimrc to contrib. - remove the README.sidebar. - empty out the PATCHES file.
2016-05-09Back out wrapper sys_socket.h workaround (23334e967dd7)Kevin McCarthy
After renaming all internal macros from M_* to MUTT_*, the sys_socket.h workaround is no longer necessary.
2016-04-27Create a wrapper sys_socket.h to work around Solaris namespace issues. ↵Kevin McCarthy
(closes #3833) Solaris includes "sys/stream.h" inside their "sys/socket.h". This include file adds many non-reserved macros to Mutt's namespace, two of which conflict with existing Mutt macros. The simplest fix would be to rename those macros in Mutt, however this will cause difficulty with out-of-tree patches. This fix creates a wrapper include file that preserves those existing macros and prevents the Solaris values from entering Mutt's namespace.
2016-04-05Fix IDNA functions for systems without iconv.Kevin McCarthy
The IDNA changes for SMTPUTF8 support introduced a bug for systems without iconv. For those systems, the local<->intl functions would return an error due to the charset conversion failing. Change mutt_idna.c back to being conditionally compiled, but this time based on HAVE_ICONV. If there is no iconv, stub out the functions in mutt_idna.h.