mailing list of musl libc
 help / color / mirror / code / Atom feed
From: Isaac Dunham <ibid.ag@gmail.com>
To: musl@lists.openwall.com, alpine-devel@lists.alpinelinux.org
Subject: what should be done with SA_INTERRUPT? (gpm 1.20.7)
Date: Tue, 15 Jul 2014 18:16:47 -0700	[thread overview]
Message-ID: <20140716011646.GA1179@newbook> (raw)

On alpine, gpm 1.20.7 doesn't build completely, so I've been poking at it.
There were numerous cases of sys/select.h being omitted, but the biggest
issue I've hit so far is the use of SA_INTERRUPT in a call to sigaction();
the purpose is to break out of select() without it getting restarted.
musl does not define or support SA_INTERRUPT, as far as I can tell (I
seem to recall that musl forces SA_RESTART).

This is in src/prog/gpm-root.y, which is the source for the "gpm-root"
utility.

Any idea what to do about this?
I could build gpm without it, but (a) I'd like to see the whole mess
build, and (b) I'm not sure how to tell make that it can skip gpm-root.

As a temporary fix, I'm using this patch:
-#if defined(__GLIBC__)
-   __sigemptyset(&childaction.sa_mask);
-#else /* __GLIBC__ */
-   childaction.sa_mask=0;
-#endif /* __GLIBC__ */
+   sigemptyset(&childaction.sa_mask);
+#ifdef SA_INTERRUPT
    childaction.sa_flags=SA_INTERRUPT; /* need to break the select() call */
+#endif


Thanks,
Isaac Dunham



             reply	other threads:[~2014-07-16  1:16 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-16  1:16 Isaac Dunham [this message]
2014-07-15 19:03 ` Rich Felker

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

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

  git send-email \
    --in-reply-to=20140716011646.GA1179@newbook \
    --to=ibid.ag@gmail.com \
    --cc=alpine-devel@lists.alpinelinux.org \
    --cc=musl@lists.openwall.com \
    /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://git.vuxu.org/mirror/musl/

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 NNTP newsgroup(s).