mirror of
https://github.com/apache/nuttx.git
synced 2026-06-02 01:21:26 +08:00
Don't build libc/pthread if pthreasa are disable. Fix a warning in dirent logic if mountpoints are disabled.
This commit is contained in:
@@ -227,7 +227,9 @@ FAR DIR *opendir(FAR const char *path)
|
|||||||
FAR struct inode *inode = NULL;
|
FAR struct inode *inode = NULL;
|
||||||
FAR struct fs_dirent_s *dir;
|
FAR struct fs_dirent_s *dir;
|
||||||
struct inode_search_s desc;
|
struct inode_search_s desc;
|
||||||
|
#ifndef CONFIG_DISABLE_MOUNTPOINT
|
||||||
FAR const char *relpath = NULL;
|
FAR const char *relpath = NULL;
|
||||||
|
#endif
|
||||||
bool isroot = false;
|
bool isroot = false;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
@@ -260,7 +262,9 @@ FAR DIR *opendir(FAR const char *path)
|
|||||||
{
|
{
|
||||||
inode = desc.node;
|
inode = desc.node;
|
||||||
DEBUGASSERT(inode != NULL);
|
DEBUGASSERT(inode != NULL);
|
||||||
|
#ifndef CONFIG_DISABLE_MOUNTPOINT
|
||||||
relpath = desc.relpath;
|
relpath = desc.relpath;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -33,6 +33,8 @@
|
|||||||
#
|
#
|
||||||
############################################################################
|
############################################################################
|
||||||
|
|
||||||
|
ifneq ($(CONFIG_DISABLE_PTHREAD),y)
|
||||||
|
|
||||||
# Add the pthread C files to the build
|
# Add the pthread C files to the build
|
||||||
|
|
||||||
CSRCS += pthread_attr_init.c pthread_attr_destroy.c
|
CSRCS += pthread_attr_init.c pthread_attr_destroy.c
|
||||||
@@ -54,9 +56,6 @@ ifeq ($(CONFIG_SMP),y)
|
|||||||
CSRCS += pthread_attr_getaffinity.c pthread_attr_setaffinity.c
|
CSRCS += pthread_attr_getaffinity.c pthread_attr_setaffinity.c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_MUTEX_TYPES),y)
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_BUILD_PROTECTED),y)
|
ifeq ($(CONFIG_BUILD_PROTECTED),y)
|
||||||
CSRCS += pthread_startup.c
|
CSRCS += pthread_startup.c
|
||||||
endif
|
endif
|
||||||
@@ -65,3 +64,5 @@ endif
|
|||||||
|
|
||||||
DEPPATH += --dep-path pthread
|
DEPPATH += --dep-path pthread
|
||||||
VPATH += :pthread
|
VPATH += :pthread
|
||||||
|
|
||||||
|
endif
|
||||||
|
|||||||
Reference in New Issue
Block a user