mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-15 21:43:33 +08:00
Fixes for l3s, USB composite, nfsmount, apps context build problems
git-svn-id: http://svn.code.sf.net/p/nuttx/code/trunk@5458 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
+14
-2
@@ -77,18 +77,30 @@ $(COBJS): %$(OBJEXT): %.c
|
||||
|
||||
builtin_list.h: registry/.updated
|
||||
$(call DELFILE, builtin_list.h)
|
||||
$(Q) touch builtin_list.h
|
||||
ifeq ($(CONFIG_WINDOWS_NATIVE),y)
|
||||
$(Q) for /f %%G in ('dir /b registry\*.bdat`) do ( type registry\%%G >> builtin_list.h )
|
||||
else
|
||||
$(Q) for file in `ls registry/*.bdat`; do cat $$file >> builtin_list.h; done
|
||||
$(Q) ( \
|
||||
filelist=`ls registry/*.bdat 2>/dev/null || echo ""`; \
|
||||
for file in $$filelist; \
|
||||
do cat $$file >> builtin_list.h; \
|
||||
done; \
|
||||
)
|
||||
endif
|
||||
|
||||
builtin_proto.h: registry/.updated
|
||||
$(call DELFILE, builtin_proto.h)
|
||||
$(Q) touch builtin_proto.h
|
||||
ifeq ($(CONFIG_WINDOWS_NATIVE),y)
|
||||
$(Q) for /f %%G in ('dir /b registry\*.pdat`) do ( type registry\%%G >> builtin_proto.h )
|
||||
else
|
||||
$(Q) for file in `ls registry/*.pdat`; do cat $$file >> builtin_proto.h; done
|
||||
$(Q) ( \
|
||||
filelist=`ls registry/*.pdat 2>/dev/null || echo ""`; \
|
||||
for file in $$filelist; \
|
||||
do cat $$file >> builtin_proto.h; \
|
||||
done; \
|
||||
)
|
||||
endif
|
||||
|
||||
.built: builtin_list.h builtin_proto.h $(OBJS)
|
||||
|
||||
@@ -45,10 +45,13 @@
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
#include <debug.h>
|
||||
|
||||
#include <nuttx/fs/nfs.h>
|
||||
|
||||
#include "nsh.h"
|
||||
#include "nsh_console.h"
|
||||
|
||||
|
||||
@@ -67,6 +67,7 @@
|
||||
#if defined(CONFIG_NET_ICMP) && defined(CONFIG_NET_ICMP_PING) && \
|
||||
!defined(CONFIG_DISABLE_CLOCK) && !defined(CONFIG_DISABLE_SIGNALS)
|
||||
# include <apps/netutils/uiplib.h>
|
||||
# include <apps/netutils/resolv.h>
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_NET_UDP) && CONFIG_NFILE_DESCRIPTORS > 0
|
||||
|
||||
@@ -48,12 +48,16 @@ if [ -z "${PATH_ORIG}" ]; then
|
||||
export PATH_ORIG="${PATH}"
|
||||
fi
|
||||
|
||||
# TOOLCHAIN_BIN must be defined to the full path to the location where you
|
||||
# have installed the toolchain of your choice. Modify the following:
|
||||
# This is the Cygwin path to the location where I installed the CodeSourcery
|
||||
# toolchain under windows. You will also have to edit this if you install
|
||||
# the CodeSourcery toolchain in any other location
|
||||
# export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/CodeSourcery/Sourcery G++ Lite/bin"
|
||||
|
||||
# This is the Cygwin path to the location where I build the buildroot
|
||||
# toolchain.
|
||||
export TOOLCHAIN_BIN="${WD}/../misc/buildroot/build_arm_nofpu/staging_dir/bin"
|
||||
|
||||
# Andd add the toolchain path to the PATH variable
|
||||
|
||||
# Add the path to the toolchain to the PATH varialble
|
||||
export PATH="${TOOLCHAIN_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||
|
||||
echo "PATH : ${PATH}"
|
||||
|
||||
@@ -48,12 +48,16 @@ if [ -z "${PATH_ORIG}" ]; then
|
||||
export PATH_ORIG="${PATH}"
|
||||
fi
|
||||
|
||||
# TOOLCHAIN_BIN must be defined to the full path to the location where you
|
||||
# have installed the toolchain of your choice. Modify the following:
|
||||
# This is the Cygwin path to the location where I installed the CodeSourcery
|
||||
# toolchain under windows. You will also have to edit this if you install
|
||||
# the CodeSourcery toolchain in any other location
|
||||
# export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/CodeSourcery/Sourcery G++ Lite/bin"
|
||||
|
||||
# This is the Cygwin path to the location where I build the buildroot
|
||||
# toolchain.
|
||||
export TOOLCHAIN_BIN="${WD}/../misc/buildroot/build_arm_nofpu/staging_dir/bin"
|
||||
|
||||
# Andd add the toolchain path to the PATH variable
|
||||
|
||||
# Add the path to the toolchain to the PATH varialble
|
||||
export PATH="${TOOLCHAIN_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||
|
||||
echo "PATH : ${PATH}"
|
||||
|
||||
@@ -40,7 +40,7 @@ CONFIGURED_APPS += examples/nsh
|
||||
# NSH library
|
||||
|
||||
CONFIGURED_APPS += system/readline
|
||||
CONFIGURED_APPS += nshlibO
|
||||
CONFIGURED_APPS += nshlib
|
||||
|
||||
# Networking support
|
||||
|
||||
|
||||
@@ -32,15 +32,31 @@
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
|
||||
if [ "$(basename $0)" = "setenv.sh" ] ; then
|
||||
if [ "$_" = "$0" ] ; then
|
||||
echo "You must source this script, not run it!" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "${PATH_ORIG}" ]; then export PATH_ORIG="${PATH}"; fi
|
||||
|
||||
WD=`pwd`
|
||||
export BUILDROOT_BIN="${WD}/../misc/buildroot/build_arm_nofpu/staging_dir/bin"
|
||||
export PATH="${BUILDROOT_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||
if [ ! -x "setenv.sh" ]; then
|
||||
echo "This script must be executed from the top-level NuttX build directory"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "${PATH_ORIG}" ]; then
|
||||
export PATH_ORIG="${PATH}"
|
||||
fi
|
||||
|
||||
# This is the Cygwin path to the location where I installed the CodeSourcery
|
||||
# toolchain under windows. You will also have to edit this if you install
|
||||
# the CodeSourcery toolchain in any other location
|
||||
# export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/CodeSourcery/Sourcery G++ Lite/bin"
|
||||
|
||||
# This is the Cygwin path to the location where I build the buildroot
|
||||
# toolchain.
|
||||
export TOOLCHAIN_BIN="${WD}/../misc/buildroot/build_arm_nofpu/staging_dir/bin"
|
||||
|
||||
# Add the path to the toolchain to the PATH varialble
|
||||
export PATH="${TOOLCHAIN_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||
|
||||
echo "PATH : ${PATH}"
|
||||
|
||||
@@ -32,15 +32,31 @@
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
|
||||
if [ "$(basename $0)" = "setenv.sh" ] ; then
|
||||
if [ "$_" = "$0" ] ; then
|
||||
echo "You must source this script, not run it!" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "${PATH_ORIG}" ]; then export PATH_ORIG="${PATH}"; fi
|
||||
|
||||
WD=`pwd`
|
||||
export BUILDROOT_BIN="${WD}/../misc/buildroot/build_arm_nofpu/staging_dir/bin"
|
||||
export PATH="${BUILDROOT_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||
if [ ! -x "setenv.sh" ]; then
|
||||
echo "This script must be executed from the top-level NuttX build directory"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "${PATH_ORIG}" ]; then
|
||||
export PATH_ORIG="${PATH}"
|
||||
fi
|
||||
|
||||
# This is the Cygwin path to the location where I installed the CodeSourcery
|
||||
# toolchain under windows. You will also have to edit this if you install
|
||||
# the CodeSourcery toolchain in any other location
|
||||
# export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/CodeSourcery/Sourcery G++ Lite/bin"
|
||||
|
||||
# This is the Cygwin path to the location where I build the buildroot
|
||||
# toolchain.
|
||||
export TOOLCHAIN_BIN="${WD}/../misc/buildroot/build_arm_nofpu/staging_dir/bin"
|
||||
|
||||
# Add the path to the toolchain to the PATH varialble
|
||||
export PATH="${TOOLCHAIN_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||
|
||||
echo "PATH : ${PATH}"
|
||||
|
||||
@@ -32,15 +32,31 @@
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
|
||||
if [ "$(basename $0)" = "setenv.sh" ] ; then
|
||||
if [ "$_" = "$0" ] ; then
|
||||
echo "You must source this script, not run it!" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "${PATH_ORIG}" ]; then export PATH_ORIG="${PATH}"; fi
|
||||
|
||||
WD=`pwd`
|
||||
export BUILDROOT_BIN="${WD}/../misc/buildroot/build_arm_nofpu/staging_dir/bin"
|
||||
export PATH="${BUILDROOT_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||
if [ ! -x "setenv.sh" ]; then
|
||||
echo "This script must be executed from the top-level NuttX build directory"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "${PATH_ORIG}" ]; then
|
||||
export PATH_ORIG="${PATH}"
|
||||
fi
|
||||
|
||||
# This is the Cygwin path to the location where I installed the CodeSourcery
|
||||
# toolchain under windows. You will also have to edit this if you install
|
||||
# the CodeSourcery toolchain in any other location
|
||||
# export TOOLCHAIN_BIN="/cygdrive/c/Program Files (x86)/CodeSourcery/Sourcery G++ Lite/bin"
|
||||
|
||||
# This is the Cygwin path to the location where I build the buildroot
|
||||
# toolchain.
|
||||
export TOOLCHAIN_BIN="${WD}/../misc/buildroot/build_arm_nofpu/staging_dir/bin"
|
||||
|
||||
# Add the path to the toolchain to the PATH varialble
|
||||
export PATH="${TOOLCHAIN_BIN}:/sbin:/usr/sbin:${PATH_ORIG}"
|
||||
|
||||
echo "PATH : ${PATH}"
|
||||
|
||||
@@ -169,7 +169,7 @@ CONFIG_RAW_BINARY=n
|
||||
#
|
||||
# General OS setup
|
||||
#
|
||||
#CONFIG_USER_ENTRYPOINT=
|
||||
CONFIG_USER_ENTRYPOINT="null_main"
|
||||
CONFIG_DEBUG=n
|
||||
CONFIG_DEBUG_VERBOSE=n
|
||||
CONFIG_DEBUG_SYMBOLS=n
|
||||
|
||||
@@ -523,12 +523,12 @@ static int composite_setup(FAR struct usbdevclass_driver_s *driver,
|
||||
{
|
||||
/* Save the configuration and inform the constituent classes */
|
||||
|
||||
ret = CLASS_SETUP(priv->dev1, dev, ctrl);
|
||||
ret = CLASS_SETUP(priv->dev1, dev, ctrl, dataout, outlen);
|
||||
dispatched = true;
|
||||
|
||||
if (ret >= 0)
|
||||
{
|
||||
ret = CLASS_SETUP(priv->dev2, dev, ctrl);
|
||||
ret = CLASS_SETUP(priv->dev2, dev, ctrl, dataout, outlen);
|
||||
if (ret >= 0)
|
||||
{
|
||||
priv->config = value;
|
||||
|
||||
@@ -113,7 +113,7 @@
|
||||
#define USEC2TICK(usec) (((usec)+(USEC_PER_TICK/2))/USEC_PER_TICK) /* Rounds */
|
||||
#define MSEC2TICK(msec) (((msec)+(MSEC_PER_TICK/2))/MSEC_PER_TICK) /* Rounds */
|
||||
#define DSEC2TICK(dsec) MSEC2TICK((dsec)*MSEC_PER_DSEC)
|
||||
#define SEC2TICK(sec) MSEC2TICK((sec)*MSEC_PER_SEC)
|
||||
#define SEC2TICK(sec) MSEC2TICK((sec)*MSEC_PER_SEC) /* Exact */
|
||||
|
||||
#define TICK2NSEC(tick) ((tick)*NSEC_PER_TICK) /* Exact */
|
||||
#define TICK2USEC(tick) ((tick)*USEC_PER_TICK) /* Exact */
|
||||
|
||||
@@ -38,6 +38,7 @@
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
#include <nuttx/compiler.h>
|
||||
|
||||
#include <stdint.h>
|
||||
#include <string.h>
|
||||
@@ -244,8 +245,8 @@ int sigtimedwait(FAR const sigset_t *set, FAR struct siginfo *info,
|
||||
*/
|
||||
|
||||
#ifdef CONFIG_HAVE_LONG_LONG
|
||||
uint64_t waitticks64 = (timeout->tv_sec * NSEC_PER_SEC +
|
||||
timeout->tv_nsec + NSEC_PER_TICK - 1) /
|
||||
uint64_t waitticks64 = ((uint64_t)timeout->tv_sec * NSEC_PER_SEC +
|
||||
(uint64_t)timeout->tv_nsec + NSEC_PER_TICK - 1) /
|
||||
NSEC_PER_TICK;
|
||||
DEBUGASSERT(waitticks64 <= UINT32_MAX);
|
||||
waitticks = (uint32_t)waitticks64;
|
||||
|
||||
Reference in New Issue
Block a user