[CalendarServer] #322: On Linux, 'run -s' tries to use 'md5' instead of 'md5sum'
#322: On Linux, 'run -s' tries to use 'md5' instead of 'md5sum' --------------------------------+------------------------------------------- Reporter: jacobg23@… | Owner: wsanchez@… Type: Defect | Status: new Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Keywords: | --------------------------------+------------------------------------------- If you try to build on Linux you'll get warnings about the 'md5' executable not existing. The following patch fixes it. This is, admittedly, rather low-priority but I thought I'd send you the patch: Index: run =================================================================== --- run (revision 3652) +++ run (working copy) @@ -48,6 +48,12 @@ cache_deps="${CALENDARSERVER_CACHE_DEPS}"; fi; +if [ "$(uname -s)" == "Darwin" ]; then + md5="md5" +else + md5="md5sum" +fi + usage () { program="$(basename "$0")"; @@ -318,7 +324,7 @@ if [ -n "${cache_deps}" ]; then mkdir -p "${cache_deps}"; - cache_file="${cache_deps}/${name}-$(echo "${url}" | md5)-$(basename "${url}")"; + cache_file="${cache_deps}/${name}-$(echo "${url}" | ${md5})-$(basename "${url}")"; if [ ! -f "${cache_file}" ]; then echo "Downloading ${name}..."; @@ -401,7 +407,7 @@ } if [ "${revision}" != "HEAD" ] && [ -n "${cache_deps}" ]; then - local cache_file="${cache_deps}/${name}-$(echo "${uri}" | md5)@r${revision}.tgz"; + local cache_file="${cache_deps}/${name}-$(echo "${uri}" | ${md5})@r${revision}.tgz"; mkdir -p "${cache_deps}"; -- Ticket URL: <http://trac.calendarserver.org/ticket/322> CalendarServer </> HTTP/WebDAV/CalDAV Server
#322: On Linux, 'run -s' tries to use 'md5' instead of 'md5sum' ---------------------------------+------------------------------------------ Reporter: jacobg23@… | Owner: wsanchez@… Type: Defect | Status: closed Priority: 5: Not set | Milestone: Component: Calendar Server | Severity: Other Resolution: Software changed | Keywords: ---------------------------------+------------------------------------------ Changes (by wsanchez@…): * status: new => closed * resolution: => Software changed Comment: Fair point. Try r3679 and see if that works for you. I tried to just check for any of a number of possible hashing command rather than trying to guess based on platform name. -- Ticket URL: <http://trac.calendarserver.org/ticket/322#comment:1> CalendarServer </> HTTP/WebDAV/CalDAV Server
participants (1)
-
CalendarServer