9
0
Fork 0

Don' depend on uname -o working

git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@3281 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
patacongo 2011-02-11 01:30:40 +00:00
parent e4ff91b8c7
commit f2081952db
17 changed files with 55 additions and 50 deletions

View File

@ -1444,3 +1444,9 @@
- Lost SYNACK causes connection reset - Lost SYNACK causes connection reset
- Fix missing UDP stats for sent/received packets - Fix missing UDP stats for sent/received packets
- Added support for Cygwin as development/test platform. - Added support for Cygwin as development/test platform.
* configs/demo9s12ne64 - Integrate new buildroot-1.9 m8s12x toolchain.
* 'uname -o' is used throughout the build logic in bash scripts and also in
Make.defs files in order to distinguish between Cygwin and Linux. However,
the -o option is not standard and is not supported under, for example, OS-X or
Solaris. This was solved by changing all 'uname -o' references to the more
complex: 'uname -o 2>/dev/null || echo "Other"'

View File

@ -8,7 +8,7 @@
<tr align="center" bgcolor="#e4e4e4"> <tr align="center" bgcolor="#e4e4e4">
<td> <td>
<h1><big><font color="#3c34ec"><i>NuttX RTOS</i></font></big></h1> <h1><big><font color="#3c34ec"><i>NuttX RTOS</i></font></big></h1>
<p>Last Updated: January 23, 2011</p> <p>Last Updated: February 10, 2011</p>
</td> </td>
</tr> </tr>
</table> </table>
@ -1992,17 +1992,18 @@ pascal-2.0 2009-12-21 Gregory Nutt &lt;spudmonkey@racsa.co.cr&gt;
stdbool.h. This change was necessary for compatibility stdbool.h. This change was necessary for compatibility
with NuttX-5.0 (any beyond). with NuttX-5.0 (any beyond).
buildroot-1.8 2009-12-21 &lt;spudmonkey@racsa.co.cr&gt; buildroot-1.9 2011-02-10 &lt;spudmonkey@racsa.co.cr&gt;
* configs/cortexm3-defconfig-4.3.3: Added support for NuttX NXFLAT * configs/arm926t-defconfig-4.3.3: update arm926t-defconfig-4.2.4
tools. * configs/arm926t-defconfig-nxflat: NXFLAT-only configuration for
* configs/arm7tdmi-defconfig-4.3.3: Update to arm7tdmi-defconfig-4.2.4. arm926
Also builds NuttX NXFLAT tools. * toolchain/gdb/gdb.mk - Remove ncurses dependency from gdb_target target.
* configs/m68hc12-defconfig-4.3.3: Update to m68ch11-defconfig. * toolchain/gdb/gdb.mk - Added --disable-werror to GDB configuration line.
* configs/m68hc12-defconfig-3.4.6: There are problems building GCC GDB 6.8 won't build because the tarbal was released with -Werror enabled and
4.3.3 for the hc12. the build stops on the first warning.
* configs/m32c-defconfig-4.2.4: Added genromfs * Add support for Freescale m9s12x using binutils 2.18 and gcc 3.3.6 and
* configs/m32c-defconfig-4.3.3: Update to m32c-defconfig-4.2.4 patches available from http://www.msextra.com/tools courtesy of James
Cortina. Add configs/m9x12x-defconfig-3.3.6.
</pre></ul> </pre></ul>
<table width ="100%"> <table width ="100%">
@ -2020,18 +2021,16 @@ nuttx-5.18 2011-xx-xx Gregory Nutt &lt;spudmonkey@racsa.co.cr&gt;
- Lost SYNACK causes connection reset - Lost SYNACK causes connection reset
- Fix missing UDP stats for sent/received packets - Fix missing UDP stats for sent/received packets
- Added support for Cygwin as development/test platform. - Added support for Cygwin as development/test platform.
* configs/demo9s12ne64 - Integrate new buildroot-1.9 m8s12x toolchain.
* 'uname -o' is used throughout the build logic in bash scripts and also in
Make.defs files in order to distinguish between Cygwin and Linux. However,
the -o option is not standard and is not supported under, for example, OS-X or
Solaris. This was solved by changing all 'uname -o' references to the more
complex: 'uname -o 2>/dev/null || echo &quot;Other&quot;'
pascal-2.1 2010-xx-xx Gregory Nutt &lt;spudmonkey@racsa.co.cr&gt; pascal-2.1 2011-xx-xx Gregory Nutt &lt;spudmonkey@racsa.co.cr&gt;
buildroot-1.9 2010-xx-xx <spudmonkey@racsa.co.cr> buildroot-1.10 2011-xx-xx <spudmonkey@racsa.co.cr>
* configs/arm926t-defconfig-4.3.3: update arm926t-defconfig-4.2.4
* configs/arm926t-defconfig-nxflat: NXFLAT-only configuration for
arm926
* toolchain/gdb/gdb.mk - Remove ncurses dependency from gdb_target target.
* toolchain/gdb/gdb.mk - Added --disable-werror to GDB configuration line.
GDB 6.8 won't build because the tarball was released with -Werror enabled and
the build stops on the first warning.
</pre></ul> </pre></ul>

View File

@ -1,7 +1,7 @@
############################################################################## ##############################################################################
# configs/mcu123-lpc214x/nsh/Make.defs # configs/mcu123-lpc214x/nsh/Make.defs
# #
# Copyright (C) 2008-2009 Gregory Nutt. All rights reserved. # Copyright (C) 2008-2009, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -51,7 +51,7 @@ NM = $(CROSSDEV)nm
OBJCOPY = $(CROSSDEV)objcopy OBJCOPY = $(CROSSDEV)objcopy
OBJDUMP = $(CROSSDEV)objdump OBJDUMP = $(CROSSDEV)objdump
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'} ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'}
ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1} ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1}

View File

@ -1,7 +1,7 @@
############################################################################## ##############################################################################
# configs/mcu123-lpc214x/ostest/Make.defs # configs/mcu123-lpc214x/ostest/Make.defs
# #
# Copyright (C) 2007-2009 Gregory Nutt. All rights reserved. # Copyright (C) 2007-2009, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -51,7 +51,7 @@ NM = $(CROSSDEV)nm
OBJCOPY = $(CROSSDEV)objcopy OBJCOPY = $(CROSSDEV)objcopy
OBJDUMP = $(CROSSDEV)objdump OBJDUMP = $(CROSSDEV)objdump
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'} ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'}
ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1} ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1}

View File

@ -1,7 +1,7 @@
############################################################################## ##############################################################################
# configs/mcu123-lpc214x/usbserial/Make.defs # configs/mcu123-lpc214x/usbserial/Make.defs
# #
# Copyright (C) 2008-2009 Gregory Nutt. All rights reserved. # Copyright (C) 2008-2009, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -51,7 +51,7 @@ NM = $(CROSSDEV)nm
OBJCOPY = $(CROSSDEV)objcopy OBJCOPY = $(CROSSDEV)objcopy
OBJDUMP = $(CROSSDEV)objdump OBJDUMP = $(CROSSDEV)objdump
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'} ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'}
ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1} ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1}

View File

@ -1,7 +1,7 @@
############################################################################## ##############################################################################
# configs/mcu123-lpc214x/usbstorage/Make.defs # configs/mcu123-lpc214x/usbstorage/Make.defs
# #
# Copyright (C) 2008-2009 Gregory Nutt. All rights reserved. # Copyright (C) 2008-2009, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -51,7 +51,7 @@ NM = $(CROSSDEV)nm
OBJCOPY = $(CROSSDEV)objcopy OBJCOPY = $(CROSSDEV)objcopy
OBJDUMP = $(CROSSDEV)objdump OBJDUMP = $(CROSSDEV)objdump
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'} ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'}
ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1} ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1}

View File

@ -1,7 +1,7 @@
############################################################################## ##############################################################################
# configs/olimex-strp711/nettest/Make.defs # configs/olimex-strp711/nettest/Make.defs
# #
# Copyright (C) 2010 Gregory Nutt. All rights reserved. # Copyright (C) 2010-2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -51,7 +51,7 @@ NM = $(CROSSDEV)nm
OBJCOPY = $(CROSSDEV)objcopy OBJCOPY = $(CROSSDEV)objcopy
OBJDUMP = $(CROSSDEV)objdump OBJDUMP = $(CROSSDEV)objdump
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'} ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'}
ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1} ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1}

View File

@ -1,7 +1,7 @@
############################################################################## ##############################################################################
# configs/olimex-strp711/nsh/Make.defs # configs/olimex-strp711/nsh/Make.defs
# #
# Copyright (C) 2008-2009 Gregory Nutt. All rights reserved. # Copyright (C) 2008-2009, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -51,7 +51,7 @@ NM = $(CROSSDEV)nm
OBJCOPY = $(CROSSDEV)objcopy OBJCOPY = $(CROSSDEV)objcopy
OBJDUMP = $(CROSSDEV)objdump OBJDUMP = $(CROSSDEV)objdump
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'} ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'}
ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1} ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1}

View File

@ -1,7 +1,7 @@
############################################################################## ##############################################################################
# configs/olimex-strp711/ostest/Make.defs # configs/olimex-strp711/ostest/Make.defs
# #
# Copyright (C) 2008-2009 Gregory Nutt. All rights reserved. # Copyright (C) 2008-2009, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -51,7 +51,7 @@ NM = $(CROSSDEV)nm
OBJCOPY = $(CROSSDEV)objcopy OBJCOPY = $(CROSSDEV)objcopy
OBJDUMP = $(CROSSDEV)objdump OBJDUMP = $(CROSSDEV)objdump
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'} ARCHCCVERSION = ${shell $(CC) -v 2>&1 | sed -n '/^gcc version/p' | sed -e 's/^gcc version \([0-9\.]\)/\1/g' -e 's/[-\ ].*//g' -e '1q'}
ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1} ARCHCCMAJOR = ${shell echo $(ARCHCCVERSION) | cut -d'.' -f1}

View File

@ -2,7 +2,7 @@
# Set up pathes to binaries, scripts, configuration files # Set up pathes to binaries, scripts, configuration files
hostos=`uname -o` hostos=`uname -o 2>/dev/null || echo "Other"`
if [ "X${hostos}" = "XCygwin" ]; then if [ "X${hostos}" = "XCygwin" ]; then
installdir=/cygdrive/c/gccfd/openocd/bin installdir=/cygdrive/c/gccfd/openocd/bin
ft2exe=$installdir/openocd-ftd2xx.exe ft2exe=$installdir/openocd-ftd2xx.exe

View File

@ -1,7 +1,7 @@
############################################################################ ############################################################################
# configs/sim/mount/Make.defs # configs/sim/mount/Make.defs
# #
# Copyright (C) 2008 Gregory Nutt. All rights reserved. # Copyright (C) 2008, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -35,7 +35,7 @@
include ${TOPDIR}/.config include ${TOPDIR}/.config
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION = -g ARCHOPTIMIZATION = -g

View File

@ -1,7 +1,7 @@
############################################################################ ############################################################################
# configs/sim/Make.defs # configs/sim/Make.defs
# #
# Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved. # Copyright (C) 2007-2008, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -35,7 +35,7 @@
include ${TOPDIR}/.config include ${TOPDIR}/.config
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION = -g ARCHOPTIMIZATION = -g

View File

@ -1,7 +1,7 @@
############################################################################ ############################################################################
# configs/sim/nsh/Make.defs # configs/sim/nsh/Make.defs
# #
# Copyright (C) 2008 Gregory Nutt. All rights reserved. # Copyright (C) 2008, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -35,7 +35,7 @@
include ${TOPDIR}/.config include ${TOPDIR}/.config
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION = -g ARCHOPTIMIZATION = -g

View File

@ -1,7 +1,7 @@
############################################################################ ############################################################################
# configs/sim/nx/Make.defs # configs/sim/nx/Make.defs
# #
# Copyright (C) 2008 Gregory Nutt. All rights reserved. # Copyright (C) 2008, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -35,7 +35,7 @@
include ${TOPDIR}/.config include ${TOPDIR}/.config
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION = -g ARCHOPTIMIZATION = -g

View File

@ -1,7 +1,7 @@
############################################################################ ############################################################################
# configs/sim/Make.defs # configs/sim/Make.defs
# #
# Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved. # Copyright (C) 2007-2008, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -35,7 +35,7 @@
include ${TOPDIR}/.config include ${TOPDIR}/.config
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION = -g ARCHOPTIMIZATION = -g

View File

@ -1,7 +1,7 @@
############################################################################ ############################################################################
# configs/sim/pashello/Make.defs # configs/sim/pashello/Make.defs
# #
# Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved. # Copyright (C) 2007-2008, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -35,7 +35,7 @@
include ${TOPDIR}/.config include ${TOPDIR}/.config
HOSTOS = ${shell uname -o} HOSTOS = ${shell uname -o 2>/dev/null || echo "Other"}
ifeq ($(CONFIG_DEBUG_SYMBOLS),y) ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
ARCHOPTIMIZATION = -g ARCHOPTIMIZATION = -g

View File

@ -1,7 +1,7 @@
#!/bin/bash #!/bin/bash
# tools/incdir.sh # tools/incdir.sh
# #
# Copyright (C) 2008-2009 Gregory Nutt. All rights reserved. # Copyright (C) 2008-2009, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr> # Author: Gregory Nutt <spudmonkey@racsa.co.cr>
# #
# Redistribution and use in source and binary forms, with or without # Redistribution and use in source and binary forms, with or without
@ -109,7 +109,7 @@ fi
# toolchains, we have to use the full windows-style paths to the header # toolchains, we have to use the full windows-style paths to the header
# files. # files.
os=`uname -o` os=`uname -o 2>/dev/null || echo "Other"`
# Let's assume that all GCC compiler paths contain the string gcc and # Let's assume that all GCC compiler paths contain the string gcc and
# no non-GCC compiler pathes include this substring # no non-GCC compiler pathes include this substring