Function: mh-checksum-choose
mh-checksum-choose is a byte-compiled function defined in
mh-search.el.gz.
Signature
(mh-checksum-choose)
Documentation
Check if a program to create a checksum is present.
Source Code
;; Defined in /usr/src/emacs/lisp/mh-e/mh-search.el.gz
(defun mh-checksum-choose ()
"Check if a program to create a checksum is present."
(unless (boundp 'mh-checksum-cmd)
(let ((exec-path (append '("/sbin" "/usr/sbin") exec-path)))
(cond ((executable-find "md5sum")
(setq mh-checksum-cmd (list (executable-find "md5sum")))
(setq mh-checksum-parser #'mh-md5sum-parser))
((executable-find "openssl")
(setq mh-checksum-cmd (list (executable-find "openssl") "md5"))
(setq mh-checksum-parser #'mh-openssl-parser))
((executable-find "md5")
(setq mh-checksum-cmd (list (executable-find "md5")))
(setq mh-checksum-parser #'mh-md5-parser))
(t (error "No suitable checksum program"))))))