* cross-compiling under cygwin?
@ 2005-04-08 14:13 Robert P. J. Day
2005-04-08 14:46 ` Tom Rini
` (3 more replies)
0 siblings, 4 replies; 12+ messages in thread
From: Robert P. J. Day @ 2005-04-08 14:13 UTC (permalink / raw)
To: Embedded PPC Linux list
i've just had a request from a colleague who wants to do all the
cross-compilation for our 8xx board on a windows box, rather than
linux.
there was talk of cygwin, and kdevelop as well. i'm still parsing
the rest of the email but is there a canonical URL that discusses
working in the windows environment?
i'm just about to head over to denx.de to see what i can find.
thanks for any pointers.
rday
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: cross-compiling under cygwin?
2005-04-08 14:13 Robert P. J. Day
@ 2005-04-08 14:46 ` Tom Rini
2005-04-08 16:49 ` Wolfgang Denk
` (2 subsequent siblings)
3 siblings, 0 replies; 12+ messages in thread
From: Tom Rini @ 2005-04-08 14:46 UTC (permalink / raw)
To: Robert P. J. Day; +Cc: Embedded PPC Linux list
On Fri, Apr 08, 2005 at 10:13:09AM -0400, Robert P. J. Day wrote:
> i've just had a request from a colleague who wants to do all the
> cross-compilation for our 8xx board on a windows box, rather than
> linux.
>
> there was talk of cygwin, and kdevelop as well. i'm still parsing
> the rest of the email but is there a canonical URL that discusses
> working in the windows environment?
>
> i'm just about to head over to denx.de to see what i can find.
> thanks for any pointers.
The cross-tool list has had some of this. As of 2.6.10 at least, the
following was still needed, and too ugly and/or cygwin version specific
to be submitted to the kernel proper (still applies cleanly to
2.6.12-rc2, but untested in Cygwin env):
Source: MontaVista Software, Inc.
MR: 8836
Type: Defect Fix
Disposition: local
Signed-off-by: Tom Rini <trini@mvista.com>
Description:
A collection of unmergeable Cygwin fixes:
- Cygwin doesn't have <inttypes.h> nor <stdint.h>, but doesn't
need them for certain values anyhow.
- For certain ELF things, we rely on libelf being provided by
the MVL environment.
- /usr/include/asm/byteorder.h provided ntohl/htonl.
- <limits.h> defines PATH_MAX as an expression, which means
it cannot be used in some places.
Index: linux-2.6.11.2/arch/ppc/boot/utils/mktree.c
===================================================================
--- linux-2.6.11.2.orig/arch/ppc/boot/utils/mktree.c
+++ linux-2.6.11.2/arch/ppc/boot/utils/mktree.c
@@ -15,9 +15,9 @@
#include <sys/stat.h>
#include <unistd.h>
#include <netinet/in.h>
-#ifdef __sun__
+#if defined(__sun__)
#include <inttypes.h>
-#else
+#elif !defined(__CYGWIN__)
#include <stdint.h>
#endif
Index: linux-2.6.11.2/scripts/mod/modpost.h
===================================================================
--- linux-2.6.11.2.orig/scripts/mod/modpost.h
+++ linux-2.6.11.2/scripts/mod/modpost.h
@@ -7,7 +7,11 @@
#include <sys/mman.h>
#include <fcntl.h>
#include <unistd.h>
+#ifdef __CYGWIN__
+#include <libelf/libelf.h>
+#else
#include <elf.h>
+#endif
#include "elfconfig.h"
Index: linux-2.6.11.2/scripts/mod/mk_elfconfig.c
===================================================================
--- linux-2.6.11.2.orig/scripts/mod/mk_elfconfig.c
+++ linux-2.6.11.2/scripts/mod/mk_elfconfig.c
@@ -1,7 +1,11 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#ifdef __CYGWIN__
+#include <libelf/libelf.h>
+#else
#include <elf.h>
+#endif
int
main(int argc, char **argv)
Index: linux-2.6.11.2/scripts/mod/sumversion.c
===================================================================
--- linux-2.6.11.2.orig/scripts/mod/sumversion.c
+++ linux-2.6.11.2/scripts/mod/sumversion.c
@@ -1,7 +1,10 @@
+#if defined(__sun__)
#include <netinet/in.h>
-#ifdef __sun__
#include <inttypes.h>
+#elif defined(__CYGWIN__)
+#include <asm/byteorder.h> /* For ntohl/htonl */
#else
+#include <netinet/in.h>
#include <stdint.h>
#endif
#include <ctype.h>
Index: linux-2.6.11.2/scripts/mod/file2alias.c
===================================================================
--- linux-2.6.11.2.orig/scripts/mod/file2alias.c
+++ linux-2.6.11.2/scripts/mod/file2alias.c
@@ -19,9 +19,9 @@ typedef Elf32_Addr kernel_ulong_t;
#else
typedef Elf64_Addr kernel_ulong_t;
#endif
-#ifdef __sun__
+#if defined(__sun__)
#include <inttypes.h>
-#else
+#elif !defined(__CYGWIN__)
#include <stdint.h>
#endif
Index: linux-2.6.11.2/arch/ppc/boot/utils/mkbugboot.c
===================================================================
--- linux-2.6.11.2.orig/arch/ppc/boot/utils/mkbugboot.c
+++ linux-2.6.11.2/arch/ppc/boot/utils/mkbugboot.c
@@ -21,9 +21,9 @@
#include <stdlib.h>
#include <errno.h>
#include <fcntl.h>
-#ifdef __sun__
+#if defined(__sun__)
#include <inttypes.h>
-#else
+#elif !defined(__CYGWIN__)
#include <stdint.h>
#endif
Index: linux-2.6.11.2/lib/gen_crc32table.c
===================================================================
--- linux-2.6.11.2.orig/lib/gen_crc32table.c
+++ linux-2.6.11.2/lib/gen_crc32table.c
@@ -1,6 +1,8 @@
#include <stdio.h>
#include "crc32defs.h"
+#ifndef __CYGWIN__
#include <inttypes.h>
+#endif
#define ENTRIES_PER_LINE 4
Index: linux-2.6.11.2/usr/gen_init_cpio.c
===================================================================
--- linux-2.6.11.2.orig/usr/gen_init_cpio.c
+++ linux-2.6.11.2/usr/gen_init_cpio.c
@@ -10,6 +10,12 @@
#include <ctype.h>
#include <limits.h>
+/* Cygwin's <limits.h> defines PATH_MAX as (260 - 1) which just won't do. */
+#ifdef __CYGWIN__
+#undef PATH_MAX
+#define PATH_MAX 259
+#endif
+
/*
* Original work by Jeff Garzik
*
--
Tom Rini
http://gate.crashing.org/~trini/
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: cross-compiling under cygwin?
@ 2005-04-08 15:24 Steven Blakeslee
0 siblings, 0 replies; 12+ messages in thread
From: Steven Blakeslee @ 2005-04-08 15:24 UTC (permalink / raw)
To: Tom Rini, Robert P. J. Day; +Cc: Embedded PPC Linux list
> >=20
> > there was talk of cygwin, and kdevelop as well. i'm=20
> still parsing=20
> > the rest of the email but is there a canonical URL that discusses=20
> > working in the windows environment?
> >=20
> > i'm just about to head over to denx.de to see what i can find.
> > thanks for any pointers.
>=20
I do my work inside of vmware. You will have all the tools you need
within linux but it runs on different windows systems. Just make sure
you have a beefy computer.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: cross-compiling under cygwin?
2005-04-08 14:13 Robert P. J. Day
2005-04-08 14:46 ` Tom Rini
@ 2005-04-08 16:49 ` Wolfgang Denk
2005-04-08 16:52 ` Robert P. J. Day
2005-04-08 17:57 ` Patrick Huesmann
2005-04-08 18:32 ` Dan Malek
3 siblings, 1 reply; 12+ messages in thread
From: Wolfgang Denk @ 2005-04-08 16:49 UTC (permalink / raw)
To: Robert P. J. Day; +Cc: Embedded PPC Linux list
In message <Pine.LNX.4.61.0504081010330.14089@localhost.localdomain> you wrote:
>
> i'm just about to head over to denx.de to see what i can find.
You won't find any Cygwin stuff. We're a 100% Micro$oft-free company
:-) We don't use any windoze. Instead, we show our customers how to
integrate a Linux server into their existing network environment.
This is MUCH more efficient.
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
The use of Microsoft crippleware systems is a sin that carries with
it its own punishment.
-- Tom Christiansen in <6bo3fr$pj8$5@csnews.cs.colorado.edu>
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: cross-compiling under cygwin?
2005-04-08 16:49 ` Wolfgang Denk
@ 2005-04-08 16:52 ` Robert P. J. Day
0 siblings, 0 replies; 12+ messages in thread
From: Robert P. J. Day @ 2005-04-08 16:52 UTC (permalink / raw)
To: Wolfgang Denk; +Cc: Embedded PPC Linux list
On Fri, 8 Apr 2005, Wolfgang Denk wrote:
> In message <Pine.LNX.4.61.0504081010330.14089@localhost.localdomain> you wrote:
> >
> > i'm just about to head over to denx.de to see what i can find.
>
> You won't find any Cygwin stuff. We're a 100% Micro$oft-free company
> :-) We don't use any windoze. Instead, we show our customers how to
> integrate a Linux server into their existing network environment.
> This is MUCH more efficient.
trust me, i'm working hard to talk them out of this approach. on a
related issue, though, are there any IDEs that stand out for embedded
system development? more than one person has recommended i look at
eclipse, so it's downloading as we speak.
and, related to the original issue, during a conference call this
morn, when the client's tech folks asked me what development
environment i use, i said, "ELDK 3.1.1 and 'vi'". there was a
noticeable silence ... :-)
rday
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: cross-compiling under cygwin?
2005-04-08 14:13 Robert P. J. Day
2005-04-08 14:46 ` Tom Rini
2005-04-08 16:49 ` Wolfgang Denk
@ 2005-04-08 17:57 ` Patrick Huesmann
2005-04-08 18:32 ` Dan Malek
3 siblings, 0 replies; 12+ messages in thread
From: Patrick Huesmann @ 2005-04-08 17:57 UTC (permalink / raw)
To: Robert P. J. Day; +Cc: Embedded PPC Linux list
Hi,
Robert P. J. Day wrote:
> i've just had a request from a colleague who wants to do all the
>cross-compilation for our 8xx board on a windows box, rather than
>linux.
>
> there was talk of cygwin, and kdevelop as well. i'm still parsing
>the rest of the email but is there a canonical URL that discusses
>working in the windows environment?
>
>
We use colinux (http://www.colinux.org) for that. It's a Linux kernel
that runs as application under windows. It shares networking with the
windows system so you can operate it via telnet or ssh. You can even run
IDEs like kdevelop as remote X application and use the cygwin's X window
system to use the Linux apps under windows.
Before that, we used VMware, but coLinux is free and IMO, it has better
performance because it doesn't have to simulate a whole computer (but
only a small hardware abstraction layer).
It comes with a pre-patched Debian image which gives you a minimal Linux
installation. From there you set up the networking, and simply apt-get
install your apps like you would do with a native Linux box.
HTH,
Patrick
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: cross-compiling under cygwin?
2005-04-08 14:13 Robert P. J. Day
` (2 preceding siblings ...)
2005-04-08 17:57 ` Patrick Huesmann
@ 2005-04-08 18:32 ` Dan Malek
2005-04-08 18:35 ` Robert P. J. Day
3 siblings, 1 reply; 12+ messages in thread
From: Dan Malek @ 2005-04-08 18:32 UTC (permalink / raw)
To: Robert P. J. Day; +Cc: Embedded PPC Linux list
On Apr 8, 2005, at 10:13 AM, Robert P. J. Day wrote:
> i've just had a request from a colleague who wants to do all the
> cross-compilation for our 8xx board on a windows box, rather than
> linux.
Just remember there is lots more to building and developing
than compiling a kernel. In addition to the compiler, you need
lots of support tools. Once you get a kernel, you have to create
some kind of file system, of course NFS won't work on Windows,
creating a ramdisk without a loopback device and file system
support is quite a challenge, too.
I don't understand why you wouldn't want to develop on a
Linux (or at least Unix) host, since you need those skills
and environment for the target. Do they just like impossible
challenges in their way to getting real work done? :-)
-- Dan
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: cross-compiling under cygwin?
2005-04-08 18:32 ` Dan Malek
@ 2005-04-08 18:35 ` Robert P. J. Day
0 siblings, 0 replies; 12+ messages in thread
From: Robert P. J. Day @ 2005-04-08 18:35 UTC (permalink / raw)
To: Dan Malek; +Cc: Embedded PPC Linux list
On Fri, 8 Apr 2005, Dan Malek wrote:
>
> On Apr 8, 2005, at 10:13 AM, Robert P. J. Day wrote:
>
> > i've just had a request from a colleague who wants to do all the
> > cross-compilation for our 8xx board on a windows box, rather than
> > linux.
> Just remember there is lots more to building and developing than
> compiling a kernel. In addition to the compiler, you need lots of
> support tools. Once you get a kernel, you have to create some kind
> of file system, of course NFS won't work on Windows, creating a
> ramdisk without a loopback device and file system support is quite a
> challenge, too.
a lot of that was part of the conversation. i suspect i may have to
be more persuasive. something involving a blunt instrument, perhaps.
> I don't understand why you wouldn't want to develop on a Linux (or
> at least Unix) host, since you need those skills and environment for
> the target. Do they just like impossible challenges in their way to
> getting real work done? :-)
i'm going to assume that was rhetorical. :-)
rday
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: cross-compiling under cygwin?
@ 2005-04-08 18:48 Howard, Marc
2005-04-08 21:17 ` Dan Malek
2005-04-10 16:59 ` Wolfgang Denk
0 siblings, 2 replies; 12+ messages in thread
From: Howard, Marc @ 2005-04-08 18:48 UTC (permalink / raw)
To: Embedded PPC Linux list
> -----Original Message-----
> From: linuxppc-embedded-bounces@ozlabs.org=20
> [mailto:linuxppc-embedded-bounces@ozlabs.org] On Behalf Of Dan Malek
> Sent: Friday, April 08, 2005 11:33 AM
> To: Robert P. J. Day
> Cc: Embedded PPC Linux list
> Subject: Re: cross-compiling under cygwin?
>=20
>=20
> On Apr 8, 2005, at 10:13 AM, Robert P. J. Day wrote:
>=20
> > i've just had a request from a colleague who wants to do all the
> > cross-compilation for our 8xx board on a windows box, rather than
> > linux.
>=20
> Just remember there is lots more to building and developing
> than compiling a kernel. In addition to the compiler, you need
> lots of support tools. Once you get a kernel, you have to create
> some kind of file system, of course NFS won't work on Windows,
If I were Catholic I'd have to say a bunch of Hail Mary's for mentioning
this but...
Yes you can run NFS on Windows. The systems we ship inside our
equipment have a Win2k Server host and the embedded boards hang off of
it. File exchange is done via NFS. Micro$oft has a huge free package
called "Windows Services for Unix". It only runs on Win2k and XP Pro
however. The other gotcha is that it can only export NTFS file systems,
not FAT32.
It is basically a better cygwin port than cygwin itself. I say this
because its compiler can compile and run some RPC apps I normally use
natively on the embedded systems. Cygwin couldn't (missing include
files, etc.).
Now I'm going to wash my mouth out with soap...
Marc W. Howard
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: cross-compiling under cygwin?
2005-04-08 18:48 cross-compiling under cygwin? Howard, Marc
@ 2005-04-08 21:17 ` Dan Malek
2005-04-10 16:59 ` Wolfgang Denk
1 sibling, 0 replies; 12+ messages in thread
From: Dan Malek @ 2005-04-08 21:17 UTC (permalink / raw)
To: Howard, Marc; +Cc: Embedded PPC Linux list
On Apr 8, 2005, at 2:48 PM, Howard, Marc wrote:
> If I were Catholic I'd have to say a bunch of Hail Mary's for
> mentioning
> this but...
I've already said plenty. :-)
> Yes you can run NFS on Windows.
Oh geeze, no wonder the Pope died. He probably heard this!
(I think that sealed my fate .... )
> The other gotcha is that it can only export NTFS file systems,
> not FAT32.
So, how do I export a root file system with /dev nodes?
-- Dan
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: cross-compiling under cygwin?
2005-04-08 18:48 cross-compiling under cygwin? Howard, Marc
2005-04-08 21:17 ` Dan Malek
@ 2005-04-10 16:59 ` Wolfgang Denk
1 sibling, 0 replies; 12+ messages in thread
From: Wolfgang Denk @ 2005-04-10 16:59 UTC (permalink / raw)
To: Howard, Marc; +Cc: Embedded PPC Linux list
In message <91B22F93A880FA48879475E134D6F0BEB9C02A@CA1EXCLV02.adcorp.kla-tencor.com> you wrote:
>
> Yes you can run NFS on Windows. The systems we ship inside our
> equipment have a Win2k Server host and the embedded boards hang off of
And this really supports things like special files, user and group
id's, permissions including set-uid and hardlinks and all that?
Best regards,
Wolfgang Denk
--
Software Engineering: Embedded and Realtime Systems, Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
Hello! I'm from outer space, and I've made myself look like a signa-
ture. While you are reading this, I'm having sex with your eyes. I
know it feels good to you, because you're smiling. I'm very horny, so
send me to someone else when you've had enough. Thanks!
Sincerely, A Stranger in a Strange Land
^ permalink raw reply [flat|nested] 12+ messages in thread
* RE: cross-compiling under cygwin?
@ 2005-04-11 18:30 Howard, Marc
0 siblings, 0 replies; 12+ messages in thread
From: Howard, Marc @ 2005-04-11 18:30 UTC (permalink / raw)
To: Embedded PPC Linux list
Wolfgang,
It has a /dev filesystem but exporting it doesn't work. Yes, user and
group ids are supported and it can either be from group/passwd files or
NIS. It does have hard and soft links. It is a pretty extensive port
(formerly known as Internix).
It is a solution for environments that have IT departments full of
Micro$soft trained robots located an ocean away who will only allow
installation of Redmond-blessed add-ons.
I'm not pushing it as a solution but it is a free way to have a mount a
NFS-style filesystem on an embedded linux board. I believe I did
mention that I disliked recommending it but to deny it exists would be
censorship.
Marc W. Howard
> -----Original Message-----
> From: wd@denx.de [mailto:wd@denx.de]=20
> Sent: Sunday, April 10, 2005 9:59 AM
> To: Howard, Marc
> Cc: Embedded PPC Linux list
> Subject: Re: cross-compiling under cygwin?=20
>=20
> In message=20
> <91B22F93A880FA48879475E134D6F0BEB9C02A@CA1EXCLV02.adcorp.kla-
> tencor.com> you wrote:
> >=20
> > Yes you can run NFS on Windows. The systems we ship inside our
> > equipment have a Win2k Server host and the embedded boards=20
> hang off of
>=20
> And this really supports things like special files, user and group
> id's, permissions including set-uid and hardlinks and all that?
>=20
> Best regards,
>=20
> Wolfgang Denk
>=20
> --=20
> Software Engineering: Embedded and Realtime Systems, Embedded Linux
> Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd@denx.de
> Hello! I'm from outer space, and I've made myself look like a signa-
> ture. While you are reading this, I'm having sex with your eyes. I
> know it feels good to you, because you're smiling. I'm very horny, so
> send me to someone else when you've had enough. Thanks!
> Sincerely, A Stranger in a Strange Land
>=20
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2005-04-11 18:30 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-04-08 18:48 cross-compiling under cygwin? Howard, Marc
2005-04-08 21:17 ` Dan Malek
2005-04-10 16:59 ` Wolfgang Denk
-- strict thread matches above, loose matches on Subject: below --
2005-04-11 18:30 Howard, Marc
2005-04-08 15:24 Steven Blakeslee
2005-04-08 14:13 Robert P. J. Day
2005-04-08 14:46 ` Tom Rini
2005-04-08 16:49 ` Wolfgang Denk
2005-04-08 16:52 ` Robert P. J. Day
2005-04-08 17:57 ` Patrick Huesmann
2005-04-08 18:32 ` Dan Malek
2005-04-08 18:35 ` Robert P. J. Day
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).