Cygwin path craziness
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@529 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
parent
d1169000ca
commit
721747d49b
@ -35,10 +35,21 @@
|
|||||||
|
|
||||||
include ${TOPDIR}/.config
|
include ${TOPDIR}/.config
|
||||||
|
|
||||||
|
# These are the directories where the ZNeo-II toolchain is installed
|
||||||
|
|
||||||
ZDSINSTALLDIR = C:/Program\ Files/ZiLOG/ZDSII_ZNEO_4.10.2
|
ZDSINSTALLDIR = C:/Program\ Files/ZiLOG/ZDSII_ZNEO_4.10.2
|
||||||
ZDSBINDIR = $(ZDSINSTALLDIR)/bin
|
ZDSBINDIR = $(ZDSINSTALLDIR)/bin
|
||||||
ZDSLIBDIR = $(ZDSINSTALLDIR)/lib/std
|
ZDSSTDINCDIR = $(ZDSINSTALLDIR)/include/std
|
||||||
ZDSINCDIR = $(ZDSINSTALLDIR)/include
|
ZDSZILOGINCDIR = $(ZDSINSTALLDIR)/include/zilog
|
||||||
|
|
||||||
|
# These are the same directories but with the directory separator
|
||||||
|
# character swapped as needed by the ZNeo-II compiler
|
||||||
|
|
||||||
|
WTOPDIR := ${shell cygpath -w $(TOPDIR)}
|
||||||
|
WZDSSTDINCDIR := ${shell cygpath -w $(ZDSSTDINCDIR)}
|
||||||
|
WZDSZILOGINCDIR := ${shell cygpath -w $(ZDSZILOGINCDIR)}
|
||||||
|
|
||||||
|
# Assembler definitions
|
||||||
|
|
||||||
ifeq ("${CONFIG_DEBUG}","y")
|
ifeq ("${CONFIG_DEBUG}","y")
|
||||||
ARCHASMOPTIMIZATION = -debug
|
ARCHASMOPTIMIZATION = -debug
|
||||||
@ -50,9 +61,11 @@ ARCHASMCPUFLAGS = -cpu:Z16F2811AL -NOigcase
|
|||||||
ARCHASMLIST = -NOlistmac -name -pagelen:56 -pagewidth:80 -quiet
|
ARCHASMLIST = -NOlistmac -name -pagelen:56 -pagewidth:80 -quiet
|
||||||
ARCHASMWARNINGS = -warn
|
ARCHASMWARNINGS = -warn
|
||||||
ARCHASMDEFINES = -define:_Z16F2811AL=1 -define:_Z16K_SERIES=1 -define:_Z16F_SERIES=1 \ -define:__ASSEMBLY__
|
ARCHASMDEFINES = -define:_Z16F2811AL=1 -define:_Z16K_SERIES=1 -define:_Z16F_SERIES=1 \ -define:__ASSEMBLY__
|
||||||
ARCHASMINCLUDES = -include:$(ZDSINCDIR)/std;$(ZDSINCDIR)/zilog
|
ARCHASMINCLUDES = -include:'$(WTOPDIR)\include;$(WZDSSTDINCDIR);$(WZDSZILOGINCDIR)'
|
||||||
AFLAGS = $(ARCHASMCPUFLAGS) $(ARCHASMINCLUDES) $(ARCHASMLIST) \
|
AFLAGS = $(ARCHASMCPUFLAGS) $(ARCHASMINCLUDES) $(ARCHASMLIST) \
|
||||||
$(ARCHASMWARN) $(ARCHASMOPTIMIZATION)
|
$(ARCHASMWARNINGS) $(ARCHASMOPTIMIZATION)
|
||||||
|
|
||||||
|
# Compiler definitions
|
||||||
|
|
||||||
ifeq ("${CONFIG_DEBUG}","y")
|
ifeq ("${CONFIG_DEBUG}","y")
|
||||||
ARCHOPTIMIZATION = -debug -NOregvar -reduceopt
|
ARCHOPTIMIZATION = -debug -NOregvar -reduceopt
|
||||||
@ -61,19 +74,24 @@ else
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
ARCHCPUFLAGS = -chartype:S -model:L -NOmodsect -cpu:Z16F2811AL \
|
ARCHCPUFLAGS = -chartype:S -model:L -NOmodsect -cpu:Z16F2811AL \
|
||||||
-asmsw:" $(ARCHASMCPUFLAGS) $(ARCHASMINCLUDES) (ARCHASMWARN) $(ARCHASMOPTIMIZATION)"
|
-asmsw:" $(ARCHASMCPUFLAGS) $(ARCHASMINCLUDES) $(ARCHASMWARNINGS) $(ARCHASMOPTIMIZATION)"
|
||||||
ARCHLIST = -NOgenprint -keeplst -NOlist -NOlistinc -NOkeepasm
|
ARCHLIST = -NOgenprint -keeplst -NOlist -NOlistinc -NOkeepasm
|
||||||
ARCHPICFLAGS =
|
ARCHPICFLAGS =
|
||||||
ARCHWARNINGS = -warn
|
ARCHWARNINGS = -warn
|
||||||
ARCHDEFINES = -define:_Z16F2811AL -define:_Z16K_SERIES \
|
ARCHDEFINES = -define:_Z16F2811AL -define:_Z16K_SERIES \
|
||||||
-define:_Z16F_SERIES -define:
|
-define:_Z16F_SERIES
|
||||||
ARCHSTDINCLUDES = -stdinc:"$(TOPDIR)/include;$(ZDSINCDIR)/std;$(ZDSINCDIR)/zilog"
|
ARCHSTDINCLUDES = -stdinc:'$(WTOPDIR)\include;$(WZDSSTDINCDIR);$(WZDSZILOGINCDIR)'
|
||||||
ARCHUSRINCLUDES = -userinc:"."
|
ARCHUSRINCLUDES = -usrinc:'.'
|
||||||
ARCHINCLUDES = $(ARCHSTDINCLUDES) $(ARCHUSRINCLUDES)
|
ARCHINCLUDES = $(ARCHSTDINCLUDES) $(ARCHUSRINCLUDES)
|
||||||
CCFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) \
|
CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) \
|
||||||
$(ARCHCPUFLAGS) $(ARCHINCLUDES) $(ARCHDEFINES)
|
$(ARCHCPUFLAGS) $(ARCHINCLUDES) $(ARCHDEFINES)
|
||||||
|
|
||||||
|
# Librarian definitions
|
||||||
|
|
||||||
ARFLAGS = -quiet -warn
|
ARFLAGS = -quiet -warn
|
||||||
|
|
||||||
|
# Tool names/pathes
|
||||||
|
|
||||||
CROSSDEV =
|
CROSSDEV =
|
||||||
CC = $(ZDSBINDIR)/zneocc.exe
|
CC = $(ZDSBINDIR)/zneocc.exe
|
||||||
CPP = $(ZDSBINDIR)/zneoasm.exe
|
CPP = $(ZDSBINDIR)/zneoasm.exe
|
||||||
@ -81,11 +99,17 @@ LD = $(ZDSBINDIR)/zneolink.exe
|
|||||||
AS = $(ZDSBINDIR)/zneoasm.exe
|
AS = $(ZDSBINDIR)/zneoasm.exe
|
||||||
AR = $(ZDSBINDIR)/zneolib.exe
|
AR = $(ZDSBINDIR)/zneolib.exe
|
||||||
|
|
||||||
|
# File extensions
|
||||||
|
|
||||||
ASMEXT = .asm
|
ASMEXT = .asm
|
||||||
OBJEXT = .obj
|
OBJEXT = .obj
|
||||||
LIBEXT = .lib
|
LIBEXT = .lib
|
||||||
EXEEXT = .hex
|
EXEEXT = .hex
|
||||||
|
|
||||||
|
# These are the macros that will be used in the NuttX make system
|
||||||
|
# to compile and assembly source files and to insert the resulting
|
||||||
|
# object files into an archive
|
||||||
|
|
||||||
define COMPILE
|
define COMPILE
|
||||||
@echo "CC: $1"
|
@echo "CC: $1"
|
||||||
@$(CC) $(CFLAGS) $1
|
@$(CC) $(CFLAGS) $1
|
||||||
@ -97,12 +121,16 @@ define ASSEMBLE
|
|||||||
endef
|
endef
|
||||||
|
|
||||||
define ARCHIVE
|
define ARCHIVE
|
||||||
echo "AR: $2"; \
|
@echo "AR: $2"; \
|
||||||
$(AR) $(ARFLAGS) $1=-+$2 || { echo "$(AR) $1=-+$2 FAILED!" ; exit 1 ; }
|
@$(AR) $(ARFLAGS) $1=-+$2 || { echo "$(AR) $1=-+$2 FAILED!" ; exit 1 ; }
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
# This is the tool to use for dependencies (i.e., none)
|
||||||
|
|
||||||
MKDEP = $(TOPDIR)/tools/mknulldeps.sh
|
MKDEP = $(TOPDIR)/tools/mknulldeps.sh
|
||||||
|
|
||||||
|
# Linux/Cygwin host tool definitions
|
||||||
|
|
||||||
HOSTCC = gcc
|
HOSTCC = gcc
|
||||||
HOSTINCLUDES = -I.
|
HOSTINCLUDES = -I.
|
||||||
HOSTCFLAGS = -Wall -wstrict-prototypes -Wshadow -g -pipe
|
HOSTCFLAGS = -Wall -wstrict-prototypes -Wshadow -g -pipe
|
||||||
|
@ -37,7 +37,7 @@ if [ "$(basename $0)" = "setenv.sh" ] ; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z ${PATH_ORIG} ]; then export PATH_ORIG=${PATH}; fi
|
if [ -z "${PATH_ORIG}" ]; then export PATH_ORIG="${PATH}"; fi
|
||||||
|
|
||||||
WD=`pwd`
|
WD=`pwd`
|
||||||
ZDSINSTALLDIR="C:/Program\ Files/ZiLOG/ZDSII_ZNEO_4.10.2"
|
ZDSINSTALLDIR="C:/Program\ Files/ZiLOG/ZDSII_ZNEO_4.10.2"
|
||||||
|
@ -35,8 +35,9 @@
|
|||||||
|
|
||||||
-include $(TOPDIR)/Make.defs
|
-include $(TOPDIR)/Make.defs
|
||||||
|
|
||||||
ARCH_SRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
|
ARCHSRCDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src
|
||||||
USRINCLUDES = -userinc:".;$(TOPDIR)/sched;$(ARCH_SRCDIR)/chip;$(ARCH_SRCDIR)/common"
|
WARCHSRCDIR = ${shell cygpath -w $(ARCHSRCDIR)}
|
||||||
|
USRINCLUDES = -usrinc:'.;$(WTOPDIR)\sched;$(WARCHSRCDIR)\chip;$(WARCHSRCDIR)\common'
|
||||||
INCLUDES = $(ARCHSTDINCLUDES) $(USRINCLUDES)
|
INCLUDES = $(ARCHSTDINCLUDES) $(USRINCLUDES)
|
||||||
CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHCPUFLAGS) $(INCLUDES) $(ARCHDEFINES)
|
CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHCPUFLAGS) $(INCLUDES) $(ARCHDEFINES)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user