Bug 18996 - Build fails on FreesBSD 8.1
Summary: Build fails on FreesBSD 8.1
Status: ASSIGNED
Alias: None
Product: gdb
Classification: Unclassified
Component: build (show other bugs)
Version: 7.10
: P2 normal
Target Milestone: ---
Assignee: jhb
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-23 20:53 UTC by Philip B
Modified: 2017-06-21 17:42 UTC (History)
3 users (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments
config.log from my build attempt (5.39 KB, text/plain)
2015-09-23 20:53 UTC, Philip B
Details
nocoredump.patch (321 bytes, patch)
2017-06-21 17:42 UTC, jhb
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Philip B 2015-09-23 20:53:21 UTC
Created attachment 8627 [details]
config.log from my build attempt

Attaching config.log.

Here were my build steps:

[bash_prompt]  export CC=/usr/local/bin/gcc
[bash_prompt]  ./configure 
[bash_prompt] make


Here's what I saw:
 Many things....then:

/usr/local/bin/gcc -g -O2    -I. -I. -I./common -I./config  -DLOCALEDIR="\"/usr/local/share/locale\"" -DHAVE_CONFIG_H -I./../include/opcode -I./../opcodes/.. -I./../readline/.. -I./../zlib  -I../bfd -I./../bfd -I./../include -I../libdecnumber -I./../libdecnumber   -I./gnulib/import -Ibuild-gnulib/import   -DTUI=1  -I/usr/local/include  -I/usr/local/include/python2.6 -I/usr/local/include/python2.6 -Wall -Wpointer-arith -Wno-unused -Wunused-value -Wunused-function -Wno-switch -Wno-char-subscripts -Wempty-body -Wpointer-sign -Wmissing-prototypes -Wdeclaration-after-statement -Wmissing-parameter-type -Wold-style-declaration -Wold-style-definition -Wformat-nonliteral  -c -o fbsd-nat.o fbsd-nat.c
fbsd-nat.c: In function 'fbsd_pid_to_exec_file':
fbsd-nat.c:56:3: warning: pointer targets in passing argument 4 of 'sysctl' differ in signedness [-Wpointer-sign]
In file included from fbsd-nat.c:30:0:
/usr/include/sys/sysctl.h:717:5: note: expected 'size_t *' but argument is of type 'ssize_t *'
fbsd-nat.c: In function 'fbsd_find_memory_regions':
fbsd-nat.c:97:24: error: 'KVME_FLAG_NOCOREDUMP' undeclared (first use in this function)
fbsd-nat.c:97:24: note: each undeclared identifier is reported only once for each function it appears in
*** Error code 1

Some info about my system:
[bash prompt]uname -a
FreeBSD pb-dev.ssimicro.com 8.1-RELEASE FreeBSD 8.1-RELEASE #0: Mon Feb 27 15:54:55 MST 2012     i386

Some info about my toolchain:
[bash prompt] gcc --version
gcc (GCC) 4.7.1

---
Happy to answer any questions you might have.
Comment 1 Keith Seitz 2016-05-17 17:31:36 UTC
Reclassifying to build/.
Comment 2 jhb 2017-06-21 17:42:46 UTC
Created attachment 10210 [details]
nocoredump.patch

Please try this patch.  I see that the NOCOREDUMP flag was added later in 8.x.  The upshot of this is that 'gcore' in gdb won't honor MAP_NOCORE flags passed to mmap().