Browse Source

Include common-defs.h instead of defs.h/server.h in shared code

This commit makes 19 of the 22 shared .c files in common, nat and
target include common-defs.h instead of defs.h/server.h.  The
remaining three files need slight extra work and are dealt with
in separate commits.

gdb/ChangeLog:

	* common/agent.c: Include common-defs.h.
	Don't include defs.h or server.h.
	* common/buffer.c: Likewise.
	* common/common-debug.c: Likewise.
	* common/common-utils.c: Likewise.
	* common/errors.c: Likewise.
	* common/filestuff.c: Likewise.
	* common/format.c: Likewise.
	* common/gdb_vecs.c: Likewise.
	* common/print-utils.c: Likewise.
	* common/ptid.c: Likewise.
	* common/rsp-low.c: Likewise.
	* common/signals.c: Likewise.
	* common/vec.c: Likewise.
	* common/xml-utils.c: Likewise.
	* nat/linux-osdata.c: Likewise.
	* nat/linux-procfs.c: Likewise.
	* nat/linux-ptrace.c: Likewise.
	* nat/mips-linux-watch.c: Likewise.
	* target/waitstatus.c: Likewise.
binutils-2_25-branch
Gary Benson 12 years ago
parent
commit
727605ca75
  1. 23
      gdb/ChangeLog
  2. 6
      gdb/common/agent.c
  3. 7
      gdb/common/buffer.c
  4. 6
      gdb/common/common-debug.c
  5. 6
      gdb/common/common-utils.c
  6. 6
      gdb/common/errors.c
  7. 6
      gdb/common/filestuff.c
  8. 7
      gdb/common/format.c
  9. 7
      gdb/common/gdb_vecs.c
  10. 7
      gdb/common/print-utils.c
  11. 6
      gdb/common/ptid.c
  12. 7
      gdb/common/rsp-low.c
  13. 6
      gdb/common/signals.c
  14. 7
      gdb/common/vec.c
  15. 7
      gdb/common/xml-utils.c
  16. 7
      gdb/nat/linux-osdata.c
  17. 7
      gdb/nat/linux-procfs.c
  18. 7
      gdb/nat/linux-ptrace.c
  19. 6
      gdb/nat/mips-linux-watch.c
  20. 7
      gdb/target/waitstatus.c

23
gdb/ChangeLog

@ -1,3 +1,26 @@
2014-09-12 Gary Benson <gbenson@redhat.com>
* common/agent.c: Include common-defs.h.
Don't include defs.h or server.h.
* common/buffer.c: Likewise.
* common/common-debug.c: Likewise.
* common/common-utils.c: Likewise.
* common/errors.c: Likewise.
* common/filestuff.c: Likewise.
* common/format.c: Likewise.
* common/gdb_vecs.c: Likewise.
* common/print-utils.c: Likewise.
* common/ptid.c: Likewise.
* common/rsp-low.c: Likewise.
* common/signals.c: Likewise.
* common/vec.c: Likewise.
* common/xml-utils.c: Likewise.
* nat/linux-osdata.c: Likewise.
* nat/linux-procfs.c: Likewise.
* nat/linux-ptrace.c: Likewise.
* nat/mips-linux-watch.c: Likewise.
* target/waitstatus.c: Likewise.
2014-09-12 Tom Tromey <tromey@redhat.com>
Gary Benson <gbenson@redhat.com>

6
gdb/common/agent.c

@ -17,11 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "target/target.h"
#include "common/symbol.h"
#include <unistd.h>

7
gdb/common/buffer.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "xml-utils.h"
#include "buffer.h"
#include "inttypes.h"

6
gdb/common/common-debug.c

@ -17,11 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "common-debug.h"
/* See common/common-debug.h. */

6
gdb/common/common-utils.c

@ -17,11 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
/* The xmalloc() (libiberty.h) family of memory management routines.

6
gdb/common/errors.c

@ -17,11 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "errors.h"
/* See common/errors.h. */

6
gdb/common/filestuff.c

@ -16,11 +16,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "filestuff.h"
#include "gdb_vecs.h"
#include <fcntl.h>

7
gdb/common/format.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "format.h"
struct format_piece *

7
gdb/common/gdb_vecs.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "gdb_vecs.h"
#include "host-defs.h"

7
gdb/common/print-utils.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "print-utils.h"
#include <stdint.h>

6
gdb/common/ptid.c

@ -17,11 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "ptid.h"
/* See ptid.h for these. */

7
gdb/common/rsp-low.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "rsp-low.h"
/* See rsp-low.h. */

6
gdb/common/signals.c

@ -17,11 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#ifdef HAVE_SIGNAL_H
#include <signal.h>

7
gdb/common/vec.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "vec.h"
struct vec_prefix

7
gdb/common/xml-utils.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "xml-utils.h"
/* Return a malloc allocated string with special characters from TEXT

7
gdb/nat/linux-osdata.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "linux-osdata.h"
#include <sys/types.h>

7
gdb/nat/linux-procfs.c

@ -16,12 +16,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "linux-procfs.h"
#include "filestuff.h"

7
gdb/nat/linux-ptrace.c

@ -16,12 +16,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "linux-ptrace.h"
#include "linux-procfs.h"
#include "linux-waitpid.h"

6
gdb/nat/mips-linux-watch.c

@ -15,11 +15,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include <sys/ptrace.h>
#include "mips-linux-watch.h"

7
gdb/target/waitstatus.c

@ -17,12 +17,7 @@
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>. */
#ifdef GDBSERVER
#include "server.h"
#else
#include "defs.h"
#endif
#include "common-defs.h"
#include "waitstatus.h"
/* Return a pretty printed form of target_waitstatus.

Loading…
Cancel
Save