diff options
author | kwm <kwm@FreeBSD.org> | 2017-09-26 03:27:04 +0800 |
---|---|---|
committer | kwm <kwm@FreeBSD.org> | 2017-09-26 03:27:04 +0800 |
commit | 65135ffc0033645121362f36ec7e817efaeca3cd (patch) | |
tree | e106bb394a4809a6f837240220a3d16159f282c8 | |
parent | c3484296fea0b3b0cb382f2ed0bfafe38c9f1987 (diff) | |
download | freebsd-ports-gnome-65135ffc0033645121362f36ec7e817efaeca3cd.tar.gz freebsd-ports-gnome-65135ffc0033645121362f36ec7e817efaeca3cd.tar.zst freebsd-ports-gnome-65135ffc0033645121362f36ec7e817efaeca3cd.zip |
Allow to build on arm64 and riscv by removing the usage of sbrk(2), which
doesn't exist on arm64 and riscv.
PR: 221751
Submitted by: brooks@
-rw-r--r-- | devel/libgtop/files/patch-examples_mountlist.c | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/devel/libgtop/files/patch-examples_mountlist.c b/devel/libgtop/files/patch-examples_mountlist.c new file mode 100644 index 000000000000..bf01f6b34c86 --- /dev/null +++ b/devel/libgtop/files/patch-examples_mountlist.c @@ -0,0 +1,33 @@ +Remove unreliable and non-portable way to demonstrate memory utilization +with sbrk(2). + +https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221751 + +--- examples/mountlist.c.orig ++++ examples/mountlist.c +@@ -71,16 +71,12 @@ + + printf ("Host = '%s' - %u\n\n", buffer, port); + +- printf ("sbrk (0) = %p\n\n", sbrk (0)); +- + for (c = 0; c < PROFILE_COUNT; c++) { + mount_entries = glibtop_get_mountlist (&mount_list, 1); + + g_free (mount_entries); + } + +- printf ("sbrk (0) = %p\n\n", sbrk (0)); +- + mount_entries = glibtop_get_mountlist (&mount_list, 1); + + if (mount_entries == NULL) +@@ -108,8 +104,6 @@ + + g_free (mount_entries); + +- printf ("\nsbrk (0) = %p\n\n", sbrk (0)); +- + glibtop_close (); + + exit (0); |