diff --git a/nuttx/arch/arm/src/stm32/stm32_usbdev.c b/nuttx/arch/arm/src/stm32/stm32_usbdev.c index 54148b230..85a0b6400 100644 --- a/nuttx/arch/arm/src/stm32/stm32_usbdev.c +++ b/nuttx/arch/arm/src/stm32/stm32_usbdev.c @@ -2,7 +2,7 @@ * arch/arm/src/stm32/stm32_usbdev.c * * Copyright (C) 2009-2011 Gregory Nutt. All rights reserved. - * Author: Gregory Nutt + * Author: Gregory Nutt * * References: * - RM0008 Reference manual, STMicro document ID 13902 @@ -148,7 +148,7 @@ #define REQRECIPIENT_MASK (USB_REQ_TYPE_MASK | USB_REQ_RECIPIENT_MASK) -/* Endpoint rister masks (handling toggle fields) */ +/* Endpoint register masks (handling toggle fields) */ #define EPR_NOTOG_MASK (USB_EPR_CTR_RX | USB_EPR_SETUP | USB_EPR_EPTYPE_MASK |\ USB_EPR_EP_KIND | USB_EPR_CTR_TX | USB_EPR_EA_MASK) diff --git a/nuttx/arch/mips/src/pic32mx/Make.defs b/nuttx/arch/mips/src/pic32mx/Make.defs index a021dcb83..3aee3179f 100644 --- a/nuttx/arch/mips/src/pic32mx/Make.defs +++ b/nuttx/arch/mips/src/pic32mx/Make.defs @@ -67,5 +67,9 @@ CHIP_CSRCS = pic32mx-irq.c pic32mx-decodeirq.c pic32mx-exception.c pic32mx-gpio. # Configuration-dependent PIC32MX files ifeq ($(CONFIG_GPIO_IRQ),y) -CHIP_CSRCS += up_gpioirq.c +CHIP_CSRCS += pic32mx_gpioirq.c +endif + +ifeq ($(CONFIG_PIC32MX_USBDEV),y) +CHIP_CSRCS += pic32mx-usbdev.c endif diff --git a/nuttx/tools/Makefile.export b/nuttx/tools/Makefile.export index 650dc7241..fa2909972 100644 --- a/nuttx/tools/Makefile.export +++ b/nuttx/tools/Makefile.export @@ -60,6 +60,7 @@ ifdef ARCHSCRIPT endif @echo "ARCHCFLAGS=\"$(ARCHCFLAGS) $(ARCHCPUFLAGS)\"" >> $(EXPORTDIR)/makeinfo.sh @echo "ARCHCXXFLAGS=\"$(ARCHCXXFLAGS) $(ARCHCPUFLAGS)\"" >> $(EXPORTDIR)/makeinfo.sh + @echo "CROSSDEV=\"$(CROSSDEV)\"" >> $(EXPORTDIR)/makeinfo.sh @chmod 755 $(EXPORTDIR)/makeinfo.sh clean: diff --git a/nuttx/tools/configure.sh b/nuttx/tools/configure.sh index 1174534fe..a13e288be 100755 --- a/nuttx/tools/configure.sh +++ b/nuttx/tools/configure.sh @@ -142,12 +142,12 @@ fi # Okay... setup the configuration -cp -f "${configpath}/Make.defs" "${TOPDIR}/." || \ +install -C "${configpath}/Make.defs" "${TOPDIR}/." || \ { echo "Failed to copy ${configpath}/Make.defs" ; exit 7 ; } -cp -f "${configpath}/setenv.sh" "${TOPDIR}/." || \ +install -C "${configpath}/setenv.sh" "${TOPDIR}/." || \ { echo "Failed to copy ${configpath}/setenv.sh" ; exit 8 ; } chmod 755 "${TOPDIR}/setenv.sh" -cp -f "${configpath}/defconfig" "${TOPDIR}/.config" || \ +install -C "${configpath}/defconfig" "${TOPDIR}/.configX" || \ { echo "Failed to copy ${configpath}/defconfig" ; exit 9 ; } # Copy option appconfig @@ -156,13 +156,13 @@ if [ ! -z "${appdir}" ]; then if [ ! -r "${configpath}/appconfig" ]; then echo "NOTE: No readable appconfig file found in ${configpath}" else - cp -f "${configpath}/appconfig" "${TOPDIR}/${appdir}/.config" || \ + install -C "${configpath}/appconfig" "${TOPDIR}/${appdir}/.configX" || \ { echo "Failed to copy ${configpath}/appconfig" ; exit 10 ; } - echo "" >> "${TOPDIR}/.config" - echo "# Application configuration" >> "${TOPDIR}/.config" - echo "" >> "${TOPDIR}/.config" - echo "CONFIG_APPS_DIR=\"$appdir\"" >> "${TOPDIR}/.config" + echo "" >> "${TOPDIR}/.configX" + echo "# Application configuration" >> "${TOPDIR}/.configX" + echo "" >> "${TOPDIR}/.configX" + echo "CONFIG_APPS_DIR=\"$appdir\"" >> "${TOPDIR}/.configX" fi fi - +install -C "${TOPDIR}/.configX" "${TOPDIR}/.config" diff --git a/nuttx/tools/mkexport.sh b/nuttx/tools/mkexport.sh index 7da6d19eb..a65c7894d 100755 --- a/nuttx/tools/mkexport.sh +++ b/nuttx/tools/mkexport.sh @@ -169,7 +169,7 @@ if [ ! -z "${LDPATH}" ]; then # Copy the linker script - cp --preserve=all "${LDPATH}" "${EXPORTDIR}/build/." || \ + cp -p "${LDPATH}" "${EXPORTDIR}/build/." || \ { echo "MK: cp ${LDPATH} failed"; exit 1; } fi @@ -180,7 +180,7 @@ echo "ARCHCXXFLAGS = ${ARCHCXXFLAGS}" >>"${EXPORTDIR}/build/Make.defs" # Copy the NuttX include directory (retaining attributes and following symbolic links) -cp -LR --preserve=all "${TOPDIR}/include" "${EXPORTDIR}/." || \ +cp -LR -p "${TOPDIR}/include" "${EXPORTDIR}/." || \ { echo "MK: 'cp ${TOPDIR}/include' failed"; exit 1; } find "${EXPORTDIR}/include" -name .svn | xargs rm -rf @@ -251,6 +251,7 @@ fi # Then process each library +AR=${CROSSDEV}ar for lib in ${LIBLIST}; do if [ ! -f "${TOPDIR}/${lib}" ]; then echo "MK: Library ${TOPDIR}/${lib} does not exist" @@ -265,7 +266,7 @@ for lib in ${LIBLIST}; do # Copy the application library unmodified if [ "X${libname}" = "Xlibapps" ]; then - cp --preserve=all "${TOPDIR}/${lib}" "${EXPORTDIR}/libs/." || \ + cp -p "${TOPDIR}/${lib}" "${EXPORTDIR}/libs/." || \ { echo "MK: cp ${TOPDIR}/${lib} failed"; exit 1; } else @@ -276,14 +277,14 @@ for lib in ${LIBLIST}; do { echo "MK: 'mkdir ${EXPORTDIR}/tmp' failed"; exit 1; } cd "${EXPORTDIR}/tmp" || \ { echo "MK: 'cd ${EXPORTDIR}/tmp' failed"; exit 1; } - ar x "${TOPDIR}/${lib}" + ${AR} x "${TOPDIR}/${lib}" # Rename each object file (to avoid collision when they are combined) # and add the file to libnuttx for file in `ls`; do mv "${file}" "${shortname}-${file}" - ar rcs "${EXPORTDIR}/libs/libnuttx${LIBEXT}" "${shortname}-${file}" + ${AR} rcs "${EXPORTDIR}/libs/libnuttx${LIBEXT}" "${shortname}-${file}" done cd "${TOPDIR}" || \