From: Christoph Hellwig <hch@infradead.org>
To: Sam Ravnborg <sam@ravnborg.org>
Cc: Jan Engelhardt <jengelh@linux01.gwdg.de>,
Paulo Marques <pmarques@grupopie.com>,
dmitry.torokhov@gmail.com, Christoph Hellwig <hch@infradead.org>,
Deepak Saxena <dsaxena@plexity.net>,
Andrew Morton <akpm@linux-foundation.org>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] Fix building kernel under Solaris 11_snv
Date: Sat, 10 Mar 2007 09:37:12 +0000 [thread overview]
Message-ID: <20070310093712.GC22182@infradead.org> (raw)
In-Reply-To: <20070309222332.GA19615@uranus.ravnborg.org>
On Fri, Mar 09, 2007 at 11:23:32PM +0100, Sam Ravnborg wrote:
> > >> ===================================================================
> > >> --- linux-2.6.21-rc3.orig/scripts/kallsyms.c 2007-03-07 05:41:20.000000000 +0100
> > >> +++ linux-2.6.21-rc3/scripts/kallsyms.c 2007-03-07 23:46:46.249005000 +0100
> > >> @@ -378,6 +378,40 @@
> > >> table_cnt = pos;
> > >> }
> > >>
> > >> +#ifdef __sun__
> > >> +/* Return the first occurrence of NEEDLE in HAYSTACK. */
> > >> +void *
> > >> +memmem (haystack, haystack_len, needle, needle_len)
> > >> + const void *haystack;
> > >> + return (void *) begin;
> > >> +
> > >> + return NULL;
> > >> +}
> > >> +#endif
> > >> +
> > >> /* replace a given token in all the valid symbols. Use the sampled symbols
> > >> * to update the counts */
> > >> static void compress_symbols(unsigned char *str, int idx)
> >
> > This one, I am just waiting for someone to object to the extra #if-#endif.
> I was planning to ask Paulo if strstr could not be used - Paulo?
Yeah. And if we can't use something else all the missing functions
should be in a compat-solaris.c files, similarly to how sparse handles
missing functions on various systems instead of polluting implementation
files with ifdefs and duplicates of library code.
> > >> -HOST_EXTRACFLAGS += -DLOCALE
> > >> +HOST_EXTRACFLAGS += -DLOCALE -std=c99 -D__EXTENSIONS__
> > >>
> > >> PHONY += $(obj)/dochecklxdialog
> > >> $(obj)/dochecklxdialog:
> >
> > The error message for this one was: <stdbool.h> only valid in C99 mode.
> > Linux GCC 4.1.2 does not print that, Solaris GCC 3.4.3 does. I do not
> > know offhand who is right.
> The -std= looks safe.
It's not though. It's a gccisms, and I'm not sure we want to mandate
gcc for the host copiler, given that the only way you'd build a working
kernel on a foreign system would be a cross compilation anyway.
> > >> #define M_EVENT (KEY_MAX+1)
> > >> +
> > >> +#ifndef KEY_RESIZE
> > >> +# define KEY_RESIZE 0632
> > >> +#endif
> >
> > Solaris only has curses, not ncurses. Consider this a supreme hack.
> > In fact, menuconfig has some weird display errors still.
> This hack looks OK to me.
Except that solaris curses doesn't actually understand this random
value for KEY_RESIZE. Either we mandate that ncurses is installed on
the host for menuconfig to work (and ncurses at least used to work
on most unix variants), or some needs to do a proper curses port.
prev parent reply other threads:[~2007-03-10 9:37 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-06 18:09 [PATCH] Fix building kernel under Solaris Deepak Saxena
2007-03-06 18:22 ` Deepak Saxena
2007-03-06 19:23 ` Sam Ravnborg
2007-03-07 9:42 ` Christoph Hellwig
2007-03-07 22:45 ` Jan Engelhardt
2007-03-08 8:35 ` Christoph Hellwig
2007-03-08 20:43 ` Jan Engelhardt
2007-03-08 21:25 ` Sam Ravnborg
2007-03-08 22:01 ` [PATCH] Fix building kernel under Solaris 11_snv Jan Engelhardt
2007-03-09 19:00 ` Sam Ravnborg
2007-03-09 20:16 ` Jan Engelhardt
2007-03-09 22:23 ` Sam Ravnborg
2007-03-09 22:55 ` Jan Engelhardt
2007-03-10 9:37 ` Christoph Hellwig [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=20070310093712.GC22182@infradead.org \
--to=hch@infradead.org \
--cc=akpm@linux-foundation.org \
--cc=dmitry.torokhov@gmail.com \
--cc=dsaxena@plexity.net \
--cc=jengelh@linux01.gwdg.de \
--cc=linux-kernel@vger.kernel.org \
--cc=pmarques@grupopie.com \
--cc=sam@ravnborg.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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome