Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

libc/elf: rename modlib to elf #2985

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion benchmarks/fio/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
config BENCHMARK_FIO
tristate "Flexible I/O Tester"
default n
depends on LIBC_MODLIB && LIBC_DLFCN
depends on LIBC_ELF && LIBC_DLFCN
---help---
https://github.com/axboe/fio Fio spawns a number of threads or processes
doing a particular type of I/O action as specified by the user.
Expand Down
2 changes: 1 addition & 1 deletion examples/module/chardev/chardev.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
#include <debug.h>

#include <nuttx/module.h>
#include <nuttx/lib/modlib.h>
#include <nuttx/lib/elf.h>
#include <nuttx/fs/fs.h>

/****************************************************************************
Expand Down
8 changes: 4 additions & 4 deletions examples/sotest/main/sotest_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ int main(int argc, FAR char *argv[])
#ifdef CONFIG_EXAMPLES_SOTEST_BUILTINFS
char devname[32];
#endif
#if CONFIG_MODLIB_MAXDEPEND > 0
#if CONFIG_LIBC_ELF_MAXDEPEND > 0
FAR void *handle1;
#endif
FAR void *handle2;
Expand Down Expand Up @@ -170,7 +170,7 @@ int main(int argc, FAR char *argv[])
}
#endif /* CONFIG_EXAMPLES_SOTEST_BUILTINFS */

#if CONFIG_MODLIB_MAXDEPEND > 0
#if CONFIG_LIBC_ELF_MAXDEPEND > 0
/* Install the first test shared library. The first shared library only
* verifies that symbols exported by one shared library can be used to
* resolve undefined symbols in a second shared library.
Expand Down Expand Up @@ -253,7 +253,7 @@ int main(int argc, FAR char *argv[])

testfunc(msg);

#if CONFIG_MODLIB_MAXDEPEND > 0
#if CONFIG_LIBC_ELF_MAXDEPEND > 0
/* This should fail because the second shared library depends on
* the first.
*/
Expand All @@ -276,7 +276,7 @@ int main(int argc, FAR char *argv[])
exit(EXIT_FAILURE);
}

#if CONFIG_MODLIB_MAXDEPEND > 0
#if CONFIG_LIBC_ELF_MAXDEPEND > 0
/* Now we should be able to close the first shared library. */

ret = dlclose(handle1);
Expand Down
2 changes: 1 addition & 1 deletion examples/sotest/modprint/modprint.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
#include <syslog.h>

#include <nuttx/symtab.h>
#include <nuttx/lib/modlib.h>
#include <nuttx/lib/elf.h>

/****************************************************************************
* Private Functions
Expand Down
6 changes: 3 additions & 3 deletions examples/sotest/sotest/sotest.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@
#include <syslog.h>

#include <nuttx/symtab.h>
#include <nuttx/lib/modlib.h>
#include <nuttx/lib/elf.h>

/****************************************************************************
* Public Function Prototypes
****************************************************************************/

#if CONFIG_MODLIB_MAXDEPEND > 0
#if CONFIG_LIBC_ELF_MAXDEPEND > 0
void modprint(FAR const char *fmt, ...) printf_like(1, 2);
#endif

Expand All @@ -62,7 +62,7 @@ visibility_default const char g_msg3[] = "Yes, don't be a stranger!";
* Name: modprint
****************************************************************************/

#if CONFIG_MODLIB_MAXDEPEND < 1
#if CONFIG_LIBC_ELF_MAXDEPEND < 1
static void modprint(FAR const char *fmt, ...)
{
va_list ap;
Expand Down
8 changes: 4 additions & 4 deletions tools/mksymtab.sh
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@ if [ -z "$prefix" ]; then
echo "const struct symtab_s CONFIG_EXECFUNCS_SYMTAB_ARRAY[] = "
echo "#elif defined(CONFIG_NSH_SYMTAB)"
echo "const struct symtab_s CONFIG_NSH_SYMTAB_ARRAYNAME[] = "
echo "#elif defined(CONFIG_MODLIB_HAVE_SYMTAB)"
echo "const struct symtab_s CONFIG_MODLIB_SYMTAB_ARRAY[] = "
echo "#elif defined(CONFIG_LIBC_ELF_HAVE_SYMTAB)"
echo "const struct symtab_s CONFIG_LIBC_ELF_SYMTAB_ARRAY[] = "
echo "#else"
echo "const struct symtab_s dummy_symtab[] = "
echo "#endif"
Expand All @@ -138,8 +138,8 @@ if [ -z "$prefix" ]; then
echo "const int CONFIG_EXECFUNCS_NSYMBOLS_VAR = sizeof(CONFIG_EXECFUNCS_SYMTAB_ARRAY) / sizeof(struct symtab_s);"
echo "#elif defined(CONFIG_NSH_SYMTAB)"
echo "const int CONFIG_NSH_SYMTAB_COUNTNAME = sizeof(CONFIG_NSH_SYMTAB_ARRAYNAME) / sizeof(struct symtab_s);"
echo "#elif defined(CONFIG_MODLIB_HAVE_SYMTAB)"
echo "const int CONFIG_MODLIB_NSYMBOLS_VAR = sizeof(CONFIG_MODLIB_SYMTAB_ARRAY) / sizeof(struct symtab_s);"
echo "#elif defined(CONFIG_LIBC_ELF_HAVE_SYMTAB)"
echo "const int CONFIG_LIBC_ELF_NSYMBOLS_VAR = sizeof(CONFIG_LIBC_ELF_SYMTAB_ARRAY) / sizeof(struct symtab_s);"
echo "#else"
echo "const int dummy_nsymtabs = sizeof(dummy_symtab) / sizeof(struct symtab_s);"
echo "#endif"
Expand Down
Loading