[U-Boot] [PATCH][RFC] Add native win32 mkimage support

Wolfgang Denk wd at denx.de
Fri Feb 6 20:06:22 CET 2009


Dear Peter Tyser,

In message <1233941433-7943-1-git-send-email-ptyser at xes-inc.com> you wrote:
> Add a mkimage_win32.exe build target which can produce a native
> win32 mkimage executable using the MinGW toolchain.  The
> mkimage_win32.exe binary is generated when the MINGW_COMPILE
> environment variable is defined.  The mkimage_win32.exe binary
> can be used by those who use Windows as an OS build environment
> but don't use cygwin.

Why do we need a new envrironment variable? Can we not follow the
standard pattern ansd use CROSS_COMPILE instead?

> +Note: If you wish to generate a WIN32 version of the mkimage tool
> +      using the MinGW toolchain (see http://www.mingw.org) you must
> +      also set the MINGW_COMPILE environment variable, for example:
> +
> +	$ export MINGW_COMPILE=i586-mingw32msvc-

Why cannot we use CROSS_COMPILE=i586-mingw32msvc- ?
YOu can test for *mingw* easily, I think.

>  #if USE_HOSTCC
> +#ifndef __MINGW32__
>  #include <endian.h>
> +#endif

How does MinGW handle byte order issues, then?

> --- a/include/libfdt_env.h
> +++ b/include/libfdt_env.h
> @@ -24,8 +24,10 @@
>  #ifdef USE_HOSTCC
>  #include <stdint.h>
>  #include <string.h>
> +#ifndef __MINGW32__
>  #include <endian.h>
>  #include <byteswap.h>
> +#endif /* __MINGW32__ */

Ditto - how is byte order handled?

> +# Build native win32 mkimage if mingw compiler is specified
> +ifneq ($(MINGW_COMPILE),)

You can test the content of CROSS_COMPILE here, too?

> +/*
> + * Copyright 2008 Extreme Engrineering Solutions, Inc.

Is this really the name of that company?

> diff --git a/tools/mingw_support.h b/tools/mingw_support.h
> new file mode 100644
> index 0000000..568d54d
> --- /dev/null
> +++ b/tools/mingw_support.h
> @@ -0,0 +1,48 @@
> +/*
> + * Copyright 2008 Extreme Engrineering Solutions, Inc.

Ditto?

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Extended Epstein-Heisenberg Principle: In an R & D orbit, only  2  of
the  existing 3 parameters can be defined simultaneously. The parame-
ters are: task, time and resources ($).


More information about the U-Boot mailing list