From: Frank Mehnert <frank.mehnert(a)kernkonzept.com>
As the condition for terminating the loop compares the loop variable
against an ElfW() variable which is, depending on the platform, either
uint32_t or uint64_t, use 'unsigned int' rather than 'int' for the loop
variable to prevent corresponding compiler warnings.
Note that it would not make sense to use 'unsigned long' because the
number of program headers will never exceed 32-bit.
Signed-off-by: Marcus Haehnel <marcus.haehnel(a)kernkonzept.com>
---
ldso/ldso/ldso.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/ldso/ldso/ldso.c b/ldso/ldso/ldso.c
index 435bd43bc..e866d6418 100755
--- a/ldso/ldso/ldso.c
+++ b/ldso/ldso/ldso.c
@@ -682,7 +682,7 @@ of this helper program; chances are you did not intend to run this program.\n\
*/
/* Now cover the application program. */
if (app_tpnt->dynamic_info[DT_TEXTREL]) {
- int j;
+ unsigned int j;
ElfW(Phdr) *ppnt_outer = ppnt;
_dl_debug_early("calling mprotect on the application program\n");
ppnt = (ElfW(Phdr) *) _dl_auxvt[AT_PHDR].a_un.a_val;
--
2.45.2
For architectures without ucontext implementation it is possible
to use libucontext with this small adaptation.
Signed-off-by: Waldemar Brodkorb <wbx(a)openadk.org>
---
include/ucontext.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/include/ucontext.h b/include/ucontext.h
index 4ce114ef1..76b4f375e 100644
--- a/include/ucontext.h
+++ b/include/ucontext.h
@@ -23,11 +23,11 @@
#include <features.h>
-#ifdef __UCLIBC_HAS_CONTEXT_FUNCS__
-
/* Get machine dependent definition of data structures. */
#include <sys/ucontext.h>
+#ifdef __UCLIBC_HAS_CONTEXT_FUNCS__
+
__BEGIN_DECLS
/* Get user context and store it in variable pointed to by UCP. */
--
2.30.2
The parameters are not used in the function variant without vdso
support, so tell this to the compiler to avoid a warning. Also fix the
indentation to be in-line with other functions in the file.
Signed-off-by: Marcus Haehnel <marcus.haehnel(a)kernkonzept.com>
---
ldso/ldso/dl-vdso.c | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/ldso/ldso/dl-vdso.c b/ldso/ldso/dl-vdso.c
index 196cbbb3b..01309011d 100755
--- a/ldso/ldso/dl-vdso.c
+++ b/ldso/ldso/dl-vdso.c
@@ -28,14 +28,14 @@
#ifndef __VDSO_SUPPORT__
- void load_vdso(void *sys_info_ehdr, char **envp ){
+void load_vdso( void *sys_info_ehdr attribute_unused,
+ char **envp attribute_unused ){
#ifdef __SUPPORT_LD_DEBUG__
- if ( _dl_debug_vdso != 0 ){
- _dl_dprintf(2,"_dl_vdso support not enabled\n" );
- }
-
-#endif
+ if ( _dl_debug_vdso != 0 ){
+ _dl_dprintf(2,"_dl_vdso support not enabled\n" );
}
+#endif
+}
#else
void *_dl__vdso_gettimeofday = 0;
--
2.45.2
GCC-14 requires all functions to have an explicit return type.
An implicit return type is no longer supported. main() in the ncurses
link check was declared without return type. Add it to make this work
on GCC-14.
See also: https://gcc.gnu.org/gcc-14/porting_to.html
Signed-off-by: Marcus Haehnel <marcus.haehnel(a)kernkonzept.com>
---
extra/config/lxdialog/check-lxdialog.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/extra/config/lxdialog/check-lxdialog.sh b/extra/config/lxdialog/check-lxdialog.sh
index 9d2a4c585..66bfcb549 100644
--- a/extra/config/lxdialog/check-lxdialog.sh
+++ b/extra/config/lxdialog/check-lxdialog.sh
@@ -43,7 +43,7 @@ trap "rm -f $tmp" 0 1 2 3 15
check() {
$cc -x c - -o $tmp 2>/dev/null <<'EOF'
#include CURSES_LOC
-main() {}
+int main() {}
EOF
if [ $? != 0 ]; then
echo " *** Unable to find the ncurses libraries or the" 1>&2
--
2.45.2