mailing list of musl libc
 help / color / mirror / code / Atom feed
From: "Luka Marčetić" <paxcoder@gmail.com>
To: musl@lists.openwall.com
Subject: Re: cluts makefiles
Date: Tue, 09 Aug 2011 17:48:42 +0200	[thread overview]
Message-ID: <4E4156DA.1060107@gmail.com> (raw)
In-Reply-To: <20110809113045.GA12614@albatros>

On 08/09/2011 01:30 PM, Vasiliy Kulikov wrote:
> Hi,
>
> This is a patch to enhance musl building things.
>
> 1) Divided a single Makefile to the cluts, tests/, compile flags.
>
> 2) Used gcc's ability to identify dependencies.

Do others free compilers support nr 2?

> Unrelated things:
>
> include "sequence.c" is weird :)  It's better to use .h with
> declarations and .c files which build into .o.

It's an ad-hoc dir structure, therefore suboptimal. I'll add prototypes 
and other declarations into .h some day.

> With glibc:
>
> a) _SVID_SOURCE is needed for alphasort.

Maybe older glibc needed it (I get no warnings). I'm not sure it 
warrants an inclusion (it's SUSv4).

> b) SA_NODEFER is undefined in all .c.

It should be defined in signal.h. Alexander had problems with this. 
Trying to apply the patch that you wrote told me you're missing an 
_XOPEN_SOURCE flag I've relatively recently added to the Make-file on 
Rich's incentive, so perhaps you could should try that. If it's an old 
kernel version instead, necessary modifications would be more extensive, 
involving unblocking when entering the handler (sigprocmask?), removing 
SA_NODEFERs, using sig*jmp, and perhaps more in some cases.

> diff --git a/Makefile b/Makefile

Having made dirs a and b (both from the same repo dir), I tried `patch 
-p0 < yourpatch`, and got:

Hunk #1 FAILED at 7.
1 out of 1 hunk FAILED -- saving rejects to file a/Makefile.rej
patching file b/defines.mk
patching file b/tests/Makefile

I tried to replace the offending line with:

-CFLAGS = -std=c99 -D_XOPEN_SOURCE=700 -D_POSIX_C_SOURCE=200809L -Wall 
-Wextra -O2

but somehow the error message persists. Is there something I'm missing?

Thanks,
Luka


  reply	other threads:[~2011-08-09 15:48 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-09 11:30 Vasiliy Kulikov
2011-08-09 15:48 ` Luka Marčetić [this message]
2011-08-09 16:11   ` Vasiliy Kulikov
2011-08-09 20:20     ` Luka Marčetić
2011-08-10  3:06       ` Solar Designer
2011-08-10 11:29         ` Luka Marčetić
2011-08-10 11:49           ` Solar Designer

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=4E4156DA.1060107@gmail.com \
    --to=paxcoder@gmail.com \
    --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).