linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: David Gibson <dwg@au1.ibm.com>
To: Matt Tyrlik <tyrlik@us.ibm.com>
Cc: linuxppc-dev@ozlabs.org
Subject: Re: DTC Patch for Cygwin
Date: Sat, 22 Sep 2007 10:19:56 +1000	[thread overview]
Message-ID: <20070922001956.GA28045@localhost.localdomain> (raw)
In-Reply-To: <OFF6527B59.0D9695D8-ON8525735D.006AC05C-8525735D.006C3903@us.ibm.com>

On Fri, Sep 21, 2007 at 03:42:04PM -0400, Matt Tyrlik wrote:
> >Scott Wood <scottwood@freescale.com> wrote on 09/21/2007 02:46:39 PM:
> > On Fri, Sep 21, 2007 at 11:26:04AM -0400, Matt Tyrlik wrote:
> > >
> > > Changes required to compile DTC under Cygwin

A S-o-b line will be needed before this can be applied.

> > >
> > > ===================================================================
> > > --- dtc-org.orig/tests/supernode_atdepth_offset.c
> > > +++ dtc-org/tests/supernode_atdepth_offset.c
> > > @@ -63,8 +63,11 @@ int path_prefix(const char *path, int de
> > >                 return 1;
> > >
> > >         p = path;
> > > -       for (i = 0; i < depth; i++)
> > > -               p = strchrnul(p+1, '/');
> > > +       for (i = 0; i < depth; i++) {
> > > +               p = strchr(p+1, '/');
> > > +               if (!p)
> > > +                       p = path + strlen(path);
> > > +       }
> > >
> > >         return p - path;
> > >  }
> >
> > Maybe we should define strchrnul under #ifndef GLIBC, similar to
> > strndupa?
> Since this is used only in one place David Gibson suggested that the
> change should be done in code.

Yeah, I don't actually particularly care which way we go with this one.

> > > Index: dtc-org/tests/testutils.c
> > > ===================================================================
> > > --- dtc-org.orig/tests/testutils.c
> > > +++ dtc-org/tests/testutils.c
> > > @@ -52,10 +52,9 @@ static void sigint_handler(int signum, s
> > >  void test_init(int argc, char *argv[])
> > >  {
> > >         int err;
> > > -       struct sigaction sa_int = {
> > > -               .sa_sigaction = sigint_handler,
> > > -       };
> > > +       struct sigaction sa_int;
> > >
> > > +       sa_int.sa_sigaction = sigint_handler,
> > >         test_name = argv[0];
> >
> > What version of GCC does cygwin use?  That doesn't seem like something
> > that should break due to OS differences.
> >
> > -Scott
> Currently 3.4.4. The compiler can't handle unnamed union in an
> initializer.

Or at least that's my surmise, I can't see why else it would be
breaking.

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson

      reply	other threads:[~2007-09-22  0:20 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-21 15:26 DTC Patch for Cygwin Matt Tyrlik
2007-09-21 18:46 ` Scott Wood
2007-09-21 19:42   ` Matt Tyrlik
2007-09-22  0:19     ` David Gibson [this message]

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=20070922001956.GA28045@localhost.localdomain \
    --to=dwg@au1.ibm.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=tyrlik@us.ibm.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.
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).