Index: devel/libgtop/files/patch-config.h.in =================================================================== --- devel/libgtop/files/patch-config.h.in +++ devel/libgtop/files/patch-config.h.in @@ -1,6 +1,6 @@ ---- config.h.in.orig 2015-08-13 20:06:02.824731000 +0200 -+++ config.h.in 2015-08-13 20:07:06.011319000 +0200 -@@ -115,6 +115,9 @@ +--- config.h.in.orig 2019-03-11 08:56:47 UTC ++++ config.h.in +@@ -119,6 +119,9 @@ /* defined if you have linux/isdn.h */ #undef HAVE_ISDN_H Index: devel/libgtop/files/patch-configure =================================================================== --- devel/libgtop/files/patch-configure +++ devel/libgtop/files/patch-configure @@ -1,6 +1,78 @@ ---- configure.orig 2015-08-13 20:06:09.161030000 +0200 -+++ configure 2015-08-13 20:07:04.020683000 +0200 -@@ -14503,6 +14503,57 @@ +--- configure.orig 2021-03-03 22:56:17 UTC ++++ configure +@@ -10770,7 +10770,7 @@ $as_echo_n "checking whether the $compiler linker ($LD + hardcode_minus_L=no + hardcode_shlibpath_var=unsupported + inherit_rpath=no +- link_all_deplibs=unknown ++ link_all_deplibs=no + module_cmds= + module_expsym_cmds= + old_archive_from_new_cmds= +@@ -11069,7 +11069,7 @@ _LT_EOF + wlarc= + else + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' +- archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ++ archive_expsym_cmds='echo "{ global:" > $lib-ver~ sed -e "s|$|;|" < $export_symbols >> $lib-ver~ echo "local: *; };" >> $lib-ver~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$lib-ver -o $lib' + fi + ;; + +@@ -11088,7 +11088,7 @@ _LT_EOF + _LT_EOF + elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' +- archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ++ archive_expsym_cmds='echo "{ global:" > $lib-ver~ sed -e "s|$|;|" < $export_symbols >> $lib-ver~ echo "local: *; };" >> $lib-ver~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$lib-ver -o $lib' + else + ld_shlibs=no + fi +@@ -11117,7 +11117,7 @@ _LT_EOF + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + hardcode_libdir_flag_spec='$wl-rpath $wl$libdir' + archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' +- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ++ archive_expsym_cmds='echo "{ global:" > $lib-ver~ sed -e "s|$|;|" < $export_symbols >> $lib-ver~ echo "local: *; };" >> $lib-ver~$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$lib-ver -o $lib' + else + ld_shlibs=no + fi +@@ -11135,7 +11135,7 @@ _LT_EOF + *) + if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then + archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' +- archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ++ archive_expsym_cmds='echo "{ global:" > $lib-ver~ sed -e "s|$|;|" < $export_symbols >> $lib-ver~ echo "local: *; };" >> $lib-ver~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$lib-ver -o $lib' + else + ld_shlibs=no + fi +@@ -11783,7 +11783,7 @@ $as_echo "$lt_cv_irix_exported_symbol" >&6; } + hardcode_direct_absolute=yes + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' +- archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' ++ archive_expsym_cmds='echo "{ global:" > $lib-ver~ sed -e "s|$|;|" < $export_symbols >> $lib-ver~ echo "local: *; };" >> $lib-ver~$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-version-script,$lib-ver' + hardcode_libdir_flag_spec='$wl-rpath,$libdir' + export_dynamic_flag_spec='$wl-E' + else +@@ -12632,7 +12632,7 @@ freebsd* | dragonfly*) + version_type=freebsd-$objformat + case $version_type in + freebsd-elf*) +- library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ++ library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' soname_spec='$libname$release$shared_ext$major' + soname_spec='$libname$release$shared_ext$major' + need_version=no + need_lib_prefix=no +@@ -13767,7 +13767,7 @@ striplib= + old_striplib= + { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 + $as_echo_n "checking whether stripping libraries is possible... " >&6; } +-if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then ++if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "strip" >/dev/null; then + test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" + test -z "$striplib" && striplib="$STRIP --strip-unneeded" + { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 +@@ -14462,6 +14462,57 @@ $as_echo "#define HAVE_IFADDRS_H 1" >>confdefs.h fi @@ -58,3 +130,12 @@ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 $as_echo_n "checking for an ANSI C-conforming const... " >&6; } if ${ac_cv_c_const+:} false; then : +@@ -18806,7 +18857,7 @@ if test x$cross_compiling = xyes ; then + sunos*) + fu_cv_sys_stat_statfs4=yes + ;; +- freebsd*) ++dragonfly* | freebsd*) + fu_cv_sys_stat_statfs2_bsize=yes + ;; + osf*) Index: devel/libgtop/files/patch-examples_mountlist.c =================================================================== --- devel/libgtop/files/patch-examples_mountlist.c +++ devel/libgtop/files/patch-examples_mountlist.c @@ -3,9 +3,9 @@ https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=221751 ---- examples/mountlist.c.orig +--- examples/mountlist.c.orig 2019-02-04 20:15:22 UTC +++ examples/mountlist.c -@@ -71,16 +71,12 @@ +@@ -71,16 +71,12 @@ main (int argc, char *argv []) printf ("Host = '%s' - %u\n\n", buffer, port); @@ -22,12 +22,12 @@ mount_entries = glibtop_get_mountlist (&mount_list, 1); if (mount_entries == NULL) -@@ -108,8 +104,6 @@ +@@ -107,8 +103,6 @@ main (int argc, char *argv []) + } g_free (mount_entries); - -- printf ("\nsbrk (0) = %p\n\n", sbrk (0)); - +- printf ("\nsbrk (0) = %p\n\n", sbrk (0)); + glibtop_close (); - exit (0); Index: devel/libgtop/files/patch-sysdeps_freebsd_procmap.c =================================================================== --- devel/libgtop/files/patch-sysdeps_freebsd_procmap.c +++ devel/libgtop/files/patch-sysdeps_freebsd_procmap.c @@ -1,15 +1,26 @@ ---- sysdeps/freebsd/procmap.c.orig 2017-08-07 22:43:41 UTC +--- sysdeps/freebsd/procmap.c.orig 2019-02-04 20:15:22 UTC +++ sysdeps/freebsd/procmap.c -@@ -52,6 +52,8 @@ +@@ -51,12 +51,19 @@ + #define _KERNEL #include #include ++#if (__FreeBSD_version < 1300115) #include ++#endif /* __FreeBSD_version < 1300115 */ +#include +#include #include #if (__FreeBSD_version >= 600006) || defined(__FreeBSD_kernel__) #include -@@ -95,12 +97,14 @@ _glibtop_sysdeps_freebsd_dev_inode (glibtop *server, s + #endif + #undef _KERNEL ++#if (__FreeBSD_version >= 1300115) ++#include ++#endif + + + #if (__FreeBSD_version >= 1101001) +@@ -95,12 +102,14 @@ _glibtop_sysdeps_freebsd_dev_inode (glibtop *server, s struct cdev_priv priv; #if __FreeBSD_version < 800039 struct cdev si; @@ -25,7 +36,7 @@ (char *) &tagptr, sizeof (tagptr)) != sizeof (tagptr) || kvm_read (server->machine->kd, (gulong) tagptr, (char *) tagstr, sizeof (tagstr)) != sizeof (tagstr)) -@@ -231,6 +235,32 @@ _glibtop_init_proc_map_p (glibtop *server) +@@ -231,6 +240,32 @@ _glibtop_init_proc_map_p (glibtop *server) server->sysdeps.proc_map = _glibtop_sysdeps_proc_map; } @@ -58,7 +69,7 @@ /* Provides detailed information about a process. */ glibtop_map_entry * -@@ -238,13 +268,12 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_ +@@ -238,13 +273,12 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_ pid_t pid) { struct kinfo_proc *pinfo; @@ -74,7 +85,7 @@ memset (buf, 0, sizeof (glibtop_proc_map)); -@@ -273,16 +302,6 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_ +@@ -273,16 +307,6 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_ return NULL; } @@ -91,7 +102,7 @@ /* Walk through the `vm_map_entry' list ... */ /* I tested this a few times with `mmap'; as soon as you write -@@ -292,21 +311,17 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_ +@@ -292,21 +316,17 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_ maps = g_array_sized_new(FALSE, FALSE, sizeof(glibtop_map_entry), vmspace.vm_map.nentries); @@ -120,7 +131,7 @@ if (entry.eflags & (MAP_ENTRY_IS_SUB_MAP)) continue; -@@ -377,7 +392,7 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_ +@@ -377,7 +397,7 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_ if (entry.protection & VM_PROT_EXECUTE) mentry->perm |= GLIBTOP_MAP_PERM_EXECUTE;