[binutils-gdb/gdb-12-branch] Fix procfs.c compilation
Rainer Orth
ro@sourceware.org
Thu Mar 31 08:38:20 GMT 2022
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=09ab0d2eecfbcb5ac68617fd356c9f8067b07769
commit 09ab0d2eecfbcb5ac68617fd356c9f8067b07769
Author: Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
Date: Thu Mar 31 10:38:01 2022 +0200
Fix procfs.c compilation
procfs.c doesn't compile on Solaris:
/vol/src/gnu/gdb/hg/master/local/gdb/procfs.c: In member function ‘virtual bool procfs_target::info_proc(const char*, info_proc_what)’:
/vol/src/gnu/gdb/hg/master/local/gdb/procfs.c:3302:3: error: ‘gdb_argv’ was not declared in this scope
3302 | gdb_argv built_argv (args);
| ^~~~~~~~
/vol/src/gnu/gdb/hg/master/local/gdb/procfs.c:3303:20: error: ‘built_argv’ was not declared in this scope; did you mean ‘buildargv’?
3303 | for (char *arg : built_argv)
| ^~~~~~~~~~
| buildargv
Fixed by including "gdbsupport/buildargv.h".
Tested on amd64-pc-solaris2.11, sparcv9-sun-solaris2.11.
Diff:
---
gdb/procfs.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/gdb/procfs.c b/gdb/procfs.c
index 840201d1897..6b269b658e2 100644
--- a/gdb/procfs.c
+++ b/gdb/procfs.c
@@ -45,6 +45,7 @@
#include "observable.h"
#include "gdbsupport/scoped_fd.h"
#include "gdbsupport/pathstuff.h"
+#include "gdbsupport/buildargv.h"
/* This module provides the interface between GDB and the
/proc file system, which is used on many versions of Unix
More information about the Gdb-cvs
mailing list