unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: Ralph Seichter <abbot@monksofcool.net>
To: notmuch@notmuchmail.org
Subject: Ye olde Apple mktemp
Date: Mon, 10 Jun 2019 20:27:37 +0200	[thread overview]
Message-ID: <87a7epz46e.fsf@ra.horus-it.com> (raw)

Another quirk that occurs during the configuration phase on older macOS
versions (when they were still called OS X, actually) in the MacPorts
build farm:

  Checking for GMime session key extraction support...
  usage: mktemp [-d] [-q] [-t prefix] [-u] template ...
         mktemp [-d] [-q] [-u] -t prefix
  No.

Hooray for that ancient mktemp binary. :-/ The following local patch
solves the issue for me:

diff --git a/configure b/configure
index 8b80f0e0..fa715946 100755
--- a/configure
+++ b/configure
@@ -529,7 +529,7 @@ int main () {
     return 0;
 }
 EOF
-    if ! TEMP_GPG=$(mktemp -d); then
+    if ! TEMP_GPG=$(mktemp -d -t /tmp); then
         printf 'No.\nCould not make tempdir for testing session-key support.\n'
         errors=$((errors + 1))
     elif ${CC} ${CFLAGS} ${gmime_cflags} _check_session_keys.c ${gmime_ldflags} -o _check_session_keys \

Alas, "mktemp -d -t /tmp" is incompatible with GNU coreutils' mktemp,
while "mktemp -d -p /tmp" is not understood by Apple's variant because
of the "-p". I don't know what syntax would be universally acceptable.

Is there a way to pass platform-dependent parameters to mktemp with the
current build mechanics?

-Ralph

             reply	other threads:[~2019-06-10 18:27 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-10 18:27 Ralph Seichter [this message]
2019-06-10 18:59 ` Ye olde Apple mktemp Tomi Ollila
2019-06-10 21:55 ` Ralph Seichter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a7epz46e.fsf@ra.horus-it.com \
    --to=abbot@monksofcool.net \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).