summaryrefslogtreecommitdiff
path: root/x11
diff options
context:
space:
mode:
authorgutteridge <gutteridge@pkgsrc.org>2022-11-27 04:53:23 +0000
committergutteridge <gutteridge@pkgsrc.org>2022-11-27 04:53:23 +0000
commita9e9b425213777c85b3bb0a3660d1b0ad302113d (patch)
tree0a68c6091adcbe5ac936f9e19617d5a8fcbd2a81 /x11
parent614b1dd30853c15bd83d8068430eb76d7f17f176 (diff)
downloadpkgsrc-a9e9b425213777c85b3bb0a3660d1b0ad302113d.tar.gz
mate-applets: update to 1.26.1
Remove bit-rotted/broken NetBSD cpufreq support. This doesn't seem to work, and is a burden to patch. FreeBSD has likewise removed their support, which ours was based on. If someone wants to resurrect this, they can check the source history for both projects. Change log: ### mate-applets 1.26.1 * update Translations * command: fix memory leak * charpick: fix memory leak * multiload: fix memory leak * geyes: consider the offset widget <-> window * netspeed/src/backend.c: Typo fix. * Sticky Notes applet: add documentation * stickynotes: Popup the note menu with the keyboard * stickynotes: Restore note popup menu that got lost in 37a85e35448f8 * Mate Trash applet: add accessible Atk object with proper label. * Mate Timer applet: add accessible Atk object with proper label. * Mate Sticky notes applet: enable keyboard navigation through F6 * Mate Sticky notes applet: make dialogs accessible. * Mate Sticky notes applet: fix segfault when Caja isn���t running * Mate Netspeed applet: make dialog accessible. * Mate Netspeed applet: add accessible Atk object with proper label. * Mate Multiload applet: add accessible Atk object with proper label. * Mate Cpufreq applet: enable standard keyboard navigation * Mate Command applet: add accessible Atk object with proper label. * Mate Weather applet: make dialog accessible. * Charpick-applet: use GtkInvisible widget ### mate-applets 1.26.0 * update translations ### mate-applets 1.25.3 * update translations * netspeed: avoid a NULL pointer dereference * netspeed: allow to select an interface which is down * netspeed-preferences: disconnect a signal handler on finalize * multiload: fix typo reported by translator * netspeed: fix typo * netspeed: Add NetspeedPreferences class * mateweather: Remove conversion warnings * geyes: Remove conversion warnings * trashapplet: Upgrade trashapplet-empty-progress.ui * stickynotes: improve code-style * multiload: Add properties.ui * netspeed: connect the widget signal handlers on class_init * netspeed: refactor variable names * netspeed: NetspeedApplet subclass of MatePanelApplet * netspeed: fix line indent * netspeed: Fix display of IP if no IPv4 is configured * netspeed: improve display of IPv6 addresses in device details. * netspeed: show all ipv6 addrs in device details dialog * netspeed: show all IP addresses on tooltip if enabled * mateweather: Do not update panel when upgrade process begins * mateweather: Avoid NULL pointer dereferences if there is no weather info * mateweather: set values before connecting signals on preferences dialog * multiload: use guint64 as data source for graphs * multiload: use bit rate in netload graph * multiload: compute combined network data on GetNet once * multiload: Drop scaler from GetNet * multiload: fix interval on autoscaler_init call * multiload: Use one callback for each of the spin buttons * multiload: increase refresh rate range setting * battstat: whitespace is missing * netspeed: code style * multiload: load menu from resource bundle ### mate-applets 1.25.2 * update translations * mateweather: Use common subdirs - src, data * netspeed: show ipv6 address in tooltip if ipv4 address is not used * multiload: Use common subdirs - src, data * stickynotes: Add stickynotes-applet-menu.xml into resource bundle * drivemount: Use common subdirs - data, src * geyes: Do not use dirent * geyes: define GEYES_SETTINGS_THEME_PATH_KEY & GEYES_SETTINGS_SCHEMA * geyes: Use g_clear_error * geyes: use returned value by load_theme * geyes: Remove duplicated NULL check * geyes: Use g_debug instead of printf for logging * geyes: format code * trashapplet: load menu and ui files from resource bundle * cpufreq: Remove /proc/cpufreq support (Linux 2.4) * build: Remove legacy variable MATE_ICONDIR * update issue template * update issue template * geyes: signal 'dispose' is invalid for instance 'ID' of type 'GtkBox' * remove dead function mate_panel_applet_set_background_widget * trashapplet: Remove warning about missing initializer * build: Do not define M4_FILES twice * ac-define-dir.m4: Remove execution bit * fix build warning caused by several translations * build: make maintainer-clean * drivemount: improve code-style * build: replace acinclude.m4 with original as-ac-expand.m4 * timer: i18n label * Cpufreq: improve code-style * Remove USE_MATE2_MACROS from autogen.sh (legacy) * charpick: improve code-style * timerapplet: Use common subdirs - src, data * battstat: improve code-style * mateweather: Warn about accessing an undefined property of object * accessx-status: improve code-style * multiload: improve code-style * accessx-status: array subscript 128 is above array bounds * drivemount: Load menu from resources * multiload: do not count shared memory twice on Linux * multiload: Remove legacy variable 'show_frame' * multiload: do not use a computed compound key for graph visibility * multiload: Do not get "diskload-nvme-diskstats" on GetDiskLoad * multiload: Remove dead function - GetPage * timerapplet: Use gtk_spin_button_get_value_as_int for int values ### mate-applets 1.25.1 * update translations * accessx-status: add src and data folders * accessx-status: Simplify icons installation * geyes: Use common subdirs - src, icons, data * command: Use common subdirs - src, data * Remove -Wtype-limits warnings * netspeed: Simplify icons/Makefile.am * netspeed: Load netspeed-menu.xml from resources * netspeed: move ui files to data folder * battstat: Rewrite preference dialog from scratch * battstat: invalidScanfArgType_int cppcheck warnings (/proc/apm) * cpufreq: Remove warning about unreachable code reported by scan-build * cpufreq: -1 indicates error obtaining max frequency * cpufreq: Update cpufreq-preferences.ui * cpufreq: remove builder_DATA, ui_DATA variables from EXTRA_DIST * cpufreq: avoid deprecated GtkAlignment * cpufreq: create all needed widgets only once * cpufreq: fix code-style * geyes: Load menu from resources * charpick: Load menu from resources * cpufreq: Load menu and ui file from resources * multiload: Use the id instead of the name to identify the graph type * multiload: Display the percentage used accurately on tooltip * accessx-status: Load menu from resources * battstat: Fix memory leak * battstat: Reduce the dynamically allocated memory * battstat: Free only dynamically allocated memory * netspeed: remove warning about g_object_disconnect on remove it from panel * Netspeed kernel warning (#510) * netspeed: Add netspeed-details.ui * netspeed: fix memory leaks on backend * charpick: Fix memory leak reported by clang static analyzer * mateweather: Add mateweather-dialog.ui in POTFILES.in * mateweather: Add mateweather-dialog.ui * multiload: code formatting - global.h * multiload: the initialization of the variable is not really used * multiload: set and check the ranges for all network thresholds * multiload: Do not add the same global variables within all graphs * stickynotes: Fix -Wformat-nonliteral warning * multiload: Fix memory leak * netspeed: Use a macro for setting refresh time value * netspeed: Use IEC units for transfer rates * netspeed: add netlink support * Remove warning about assigned value is never used reported by cppcheck * battstat: warning about boolean algebra reported by cppcheck * Remove unused variable warning reported by cppcheck * command: Remove runtime warning about invalid icon size 24 * battstat: bump upower required version and drop legacy code * batstatt: fix deprecated up_client_get_devices * Guard block is missing * geyes: Add themes.ui ### mate-applets 1.25.0 * update translations * timerapplet: Add timerapplet-preferences.ui * mate-cpufreq-selector: Fix example in man page * command: Add command-preferences.ui * netspeed: Add netspeed-preferences.ui * charpic-about: fix DE name in about dialog * stickynotes: Remove enum conversion warnings * build: set 'enable_polkit=yes' if not given * cpufreq: Port client of selector service to GDBus * build: Remove MATEDESKTOP_CFLAGS and MATEDESKTOP_LIBS * build: Use dbus-glib only when required * Remove unused-function warnings * build: silent build warnings for distcheck * multiload: declaration of ���screen��� shadows a previous local * Remove unused-variable warnings * stickynotes: Remove strict-prototypes warning * build: Remove --enable-more-warnings configure flag * build: Use WARN_CFLAGS variable * cpufreq: generate missing 256x256 and 64x64 icons from svg file * eyes: generate missing 256x256 and 64x64 icons from svg file * stickynotes: Use gresources for UI files * netspeed: don't define MATELOCALEDIR * build: drop unused matelocaledir variable * tx: pull with fixed translations of pt and pt_BR * drivemount: Remove global variable
Diffstat (limited to 'x11')
-rw-r--r--x11/mate-applets/Makefile8
-rw-r--r--x11/mate-applets/PLIST92
-rw-r--r--x11/mate-applets/distinfo16
-rw-r--r--x11/mate-applets/patches/patch-configure25
-rw-r--r--x11/mate-applets/patches/patch-cpufreq_src_Makefile.in51
-rw-r--r--x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-cpuinfo.c59
-rw-r--r--x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-factory.c53
-rw-r--r--x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-sysctl.c189
-rw-r--r--x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-sysctl.h55
-rw-r--r--x11/mate-applets/patches/patch-cpufreq_src_cpufreq-selector.c19
-rw-r--r--x11/mate-applets/patches/patch-cpufreq_src_cpufreq-utils.c44
11 files changed, 82 insertions, 529 deletions
diff --git a/x11/mate-applets/Makefile b/x11/mate-applets/Makefile
index 83fe8e6756d..da79b18e767 100644
--- a/x11/mate-applets/Makefile
+++ b/x11/mate-applets/Makefile
@@ -1,6 +1,5 @@
-# $NetBSD: Makefile,v 1.45 2022/11/23 16:21:26 adam Exp $
+# $NetBSD: Makefile,v 1.46 2022/11/27 04:53:23 gutteridge Exp $
-PKGREVISION= 4
.include "../../meta-pkgs/mate/Makefile.common"
DISTNAME= mate-applets-${VERSION:R}.1
@@ -10,14 +9,11 @@ COMMENT= MATE panel applets
CONFIGURE_ARGS+= --sysconfdir=${PKG_SYSCONFDIR}
CONFIGURE_ARGS+= --libexecdir=${PREFIX}/libexec/mate-applets
+CONFIGURE_ARGS+= --without-nl
.include "../../mk/bsd.prefs.mk"
PLIST_VARS= batt cpufreq
-.if ${OPSYS} == "NetBSD" && (${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64")
-CONFIGURE_ARGS+= --enable-cpufreq=yes
-PLIST.cpufreq= yes
-.endif
INSTALL_MAKE_FLAGS+= sysconfdir=${PREFIX}/share/examples/mate-applets
diff --git a/x11/mate-applets/PLIST b/x11/mate-applets/PLIST
index eb424ddf868..1e1003163ac 100644
--- a/x11/mate-applets/PLIST
+++ b/x11/mate-applets/PLIST
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.14 2021/10/09 08:13:53 nia Exp $
+@comment $NetBSD: PLIST,v 1.15 2022/11/27 04:53:23 gutteridge Exp $
${PLIST.cpufreq}bin/mate-cpufreq-selector
libexec/mate-applets/accessx-status-applet
${PLIST.batt}libexec/mate-applets/battstat-applet
@@ -2318,6 +2318,36 @@ share/help/en_GB/mateweather/figures/stock_weather-storm.png
share/help/en_GB/mateweather/figures/stock_weather-sunny.png
share/help/en_GB/mateweather/index.docbook
share/help/en_GB/mateweather/legal.xml
+share/help/en_US/mate-netspeed-applet/figures/details.png
+share/help/en_US/mate-netspeed-applet/figures/eth_sum_48.png
+share/help/en_US/mate-netspeed-applet/figures/ethernet.png
+share/help/en_US/mate-netspeed-applet/figures/loopback.png
+share/help/en_US/mate-netspeed-applet/figures/netspeed_applet.png
+share/help/en_US/mate-netspeed-applet/figures/plip.png
+share/help/en_US/mate-netspeed-applet/figures/ppp.png
+share/help/en_US/mate-netspeed-applet/figures/settings.png
+share/help/en_US/mate-netspeed-applet/figures/wavelan.png
+share/help/en_US/mate-netspeed-applet/index.docbook
+share/help/en_US/mate-netspeed-applet/legal.xml
+share/help/en_US/mate-trashapplet/figures/trash-applet.png
+share/help/en_US/mate-trashapplet/index.docbook
+share/help/en_US/mate-trashapplet/legal.xml
+share/help/en_US/mateweather/figures/mateweather-details.png
+share/help/en_US/mateweather/figures/mateweather-menu-prefs.png
+share/help/en_US/mateweather/figures/mateweather-prefs-general.png
+share/help/en_US/mateweather/figures/mateweather-prefs-locations.png
+share/help/en_US/mateweather/figures/mateweather_applet.png
+share/help/en_US/mateweather/figures/stock_weather-cloudy.png
+share/help/en_US/mateweather/figures/stock_weather-few-clouds.png
+share/help/en_US/mateweather/figures/stock_weather-fog.png
+share/help/en_US/mateweather/figures/stock_weather-night-clear.png
+share/help/en_US/mateweather/figures/stock_weather-night-few-clouds.png
+share/help/en_US/mateweather/figures/stock_weather-showers.png
+share/help/en_US/mateweather/figures/stock_weather-snow.png
+share/help/en_US/mateweather/figures/stock_weather-storm.png
+share/help/en_US/mateweather/figures/stock_weather-sunny.png
+share/help/en_US/mateweather/index.docbook
+share/help/en_US/mateweather/legal.xml
share/help/eo/mate-accessx-status/figures/accessx-status-applet.png
share/help/eo/mate-accessx-status/figures/accessx-status-disabled.png
share/help/eo/mate-accessx-status/figures/accessx_bounce-keys.png
@@ -10354,6 +10384,13 @@ share/help/zh-Hans/mate-accessx-status/figures/accessx_sticky-shift-key.png
share/help/zh-Hans/mate-accessx-status/figures/accessx_sticky-windows-key.png
share/help/zh-Hans/mate-accessx-status/index.docbook
share/help/zh-Hans/mate-accessx-status/legal.xml
+${PLIST.batt}share/help/zh-Hans/mate-battstat/figures/battstat-applet-expanded.png
+${PLIST.batt}share/help/zh-Hans/mate-battstat/figures/battstat-applet.png
+${PLIST.batt}share/help/zh-Hans/mate-battstat/figures/battstat-credits-hal.png
+${PLIST.batt}share/help/zh-Hans/mate-battstat/figures/battstat-preferences.png
+${PLIST.batt}share/help/zh-Hans/mate-battstat/figures/context-menu.png
+${PLIST.batt}share/help/zh-Hans/mate-battstat/index.docbook
+${PLIST.batt}share/help/zh-Hans/mate-battstat/legal.xml
share/help/zh-Hans/mate-char-palette/figures/charpalette_applet.png
share/help/zh-Hans/mate-char-palette/figures/charpick-preferences.png
share/help/zh-Hans/mate-char-palette/figures/charpick_characters.png
@@ -10380,9 +10417,47 @@ share/help/zh-Hans/mate-drivemount/legal.xml
share/help/zh-Hans/mate-geyes/figures/geyes_applet.png
share/help/zh-Hans/mate-geyes/index.docbook
share/help/zh-Hans/mate-geyes/legal.xml
+share/help/zh-Hans/mate-multiload/figures/multiload-preferences.png
+share/help/zh-Hans/mate-multiload/figures/system-monitor-applet_window.png
+share/help/zh-Hans/mate-multiload/index.docbook
+share/help/zh-Hans/mate-multiload/legal.xml
+share/help/zh-Hans/mate-netspeed-applet/figures/details.png
+share/help/zh-Hans/mate-netspeed-applet/figures/eth_sum_48.png
+share/help/zh-Hans/mate-netspeed-applet/figures/ethernet.png
+share/help/zh-Hans/mate-netspeed-applet/figures/loopback.png
+share/help/zh-Hans/mate-netspeed-applet/figures/netspeed_applet.png
+share/help/zh-Hans/mate-netspeed-applet/figures/plip.png
+share/help/zh-Hans/mate-netspeed-applet/figures/ppp.png
+share/help/zh-Hans/mate-netspeed-applet/figures/settings.png
+share/help/zh-Hans/mate-netspeed-applet/figures/wavelan.png
+share/help/zh-Hans/mate-netspeed-applet/index.docbook
+share/help/zh-Hans/mate-netspeed-applet/legal.xml
+share/help/zh-Hans/mate-stickynotes-applet/figures/stickynote-right-menu-lock.png
+share/help/zh-Hans/mate-stickynotes-applet/figures/stickynote-right-menu-new.png
+share/help/zh-Hans/mate-stickynotes-applet/figures/stickynotes-note-prefs.png
+share/help/zh-Hans/mate-stickynotes-applet/figures/stickynotes-prefs.png
+share/help/zh-Hans/mate-stickynotes-applet/figures/stickynotes_applet.png
+share/help/zh-Hans/mate-stickynotes-applet/index.docbook
+share/help/zh-Hans/mate-stickynotes-applet/legal.xml
share/help/zh-Hans/mate-trashapplet/figures/trash-applet.png
share/help/zh-Hans/mate-trashapplet/index.docbook
share/help/zh-Hans/mate-trashapplet/legal.xml
+share/help/zh-Hans/mateweather/figures/mateweather-details.png
+share/help/zh-Hans/mateweather/figures/mateweather-menu-prefs.png
+share/help/zh-Hans/mateweather/figures/mateweather-prefs-general.png
+share/help/zh-Hans/mateweather/figures/mateweather-prefs-locations.png
+share/help/zh-Hans/mateweather/figures/mateweather_applet.png
+share/help/zh-Hans/mateweather/figures/stock_weather-cloudy.png
+share/help/zh-Hans/mateweather/figures/stock_weather-few-clouds.png
+share/help/zh-Hans/mateweather/figures/stock_weather-fog.png
+share/help/zh-Hans/mateweather/figures/stock_weather-night-clear.png
+share/help/zh-Hans/mateweather/figures/stock_weather-night-few-clouds.png
+share/help/zh-Hans/mateweather/figures/stock_weather-showers.png
+share/help/zh-Hans/mateweather/figures/stock_weather-snow.png
+share/help/zh-Hans/mateweather/figures/stock_weather-storm.png
+share/help/zh-Hans/mateweather/figures/stock_weather-sunny.png
+share/help/zh-Hans/mateweather/index.docbook
+share/help/zh-Hans/mateweather/legal.xml
share/help/zh_CN/mate-accessx-status/figures/accessx-status-applet.png
share/help/zh_CN/mate-accessx-status/figures/accessx-status-disabled.png
share/help/zh_CN/mate-accessx-status/figures/accessx_bounce-keys.png
@@ -11030,10 +11105,6 @@ share/locale/zh_CN/LC_MESSAGES/mate-applets.mo
share/locale/zh_HK/LC_MESSAGES/mate-applets.mo
share/locale/zh_TW/LC_MESSAGES/mate-applets.mo
share/locale/zu/LC_MESSAGES/mate-applets.mo
-${PLIST.batt}share/mate-applets/builder/battstat_applet.ui
-${PLIST.cpufreq}share/mate-applets/builder/cpufreq-preferences.ui
-share/mate-applets/builder/stickynotes.ui
-share/mate-applets/builder/trashapplet-empty-progress.ui
share/mate-applets/geyes/Bizarre/Bizarre-eye.png
share/mate-applets/geyes/Bizarre/Bizarre-pupil.png
share/mate-applets/geyes/Bizarre/config
@@ -11073,17 +11144,6 @@ share/mate-panel/applets/org.mate.applets.NetspeedApplet.mate-panel-applet
share/mate-panel/applets/org.mate.applets.StickyNotesApplet.mate-panel-applet
share/mate-panel/applets/org.mate.applets.TimerApplet.mate-panel-applet
share/mate-panel/applets/org.mate.applets.TrashApplet.mate-panel-applet
-share/mate/ui/accessx-status-applet-menu.xml
-${PLIST.batt}share/mate/ui/battstat-applet-menu.xml
-share/mate/ui/charpick-applet-menu.xml
-${PLIST.cpufreq}share/mate/ui/cpufreq-applet-menu.xml
-share/mate/ui/drivemount-applet-menu.xml
-share/mate/ui/geyes-applet-menu.xml
-share/mate/ui/mateweather-applet-menu.xml
-share/mate/ui/multiload-applet-menu.xml
-share/mate/ui/netspeed-menu.xml
-share/mate/ui/stickynotes-applet-menu.xml
-share/mate/ui/trashapplet-menu.xml
${PLIST.cpufreq}share/pixmaps/mate-cpufreq-applet/cpufreq-100.png
${PLIST.cpufreq}share/pixmaps/mate-cpufreq-applet/cpufreq-25.png
${PLIST.cpufreq}share/pixmaps/mate-cpufreq-applet/cpufreq-50.png
diff --git a/x11/mate-applets/distinfo b/x11/mate-applets/distinfo
index fda6c3f44af..392ddeca398 100644
--- a/x11/mate-applets/distinfo
+++ b/x11/mate-applets/distinfo
@@ -1,13 +1,5 @@
-$NetBSD: distinfo,v 1.12 2021/10/26 11:34:13 nia Exp $
+$NetBSD: distinfo,v 1.13 2022/11/27 04:53:23 gutteridge Exp $
-BLAKE2s (mate-applets-1.24.1.tar.xz) = d1a0afbdc90e484aefe869db2dd8c9de5f5cd7bb3bc72c9394c1ee634363b35e
-SHA512 (mate-applets-1.24.1.tar.xz) = d29e39a140310fef84cb0fe631568e0177ca5faaf2bf566211a23b32613fd6aabf06dd8ecd81a16e09553c659a7feda9ba372bb62a70504a235be58e07726ed2
-Size (mate-applets-1.24.1.tar.xz) = 8222540 bytes
-SHA1 (patch-configure) = ff3425ea0960eeca617b0fbf672e10206252c92b
-SHA1 (patch-cpufreq_src_Makefile.in) = 60f1172449394e1079a38ea3242983e7fc17e491
-SHA1 (patch-cpufreq_src_cpufreq-monitor-cpuinfo.c) = f19ddbf7e6ad764ae14f0adabc3b4c689e338e1b
-SHA1 (patch-cpufreq_src_cpufreq-monitor-factory.c) = 7b5e992b4481af2376f17e7da1d0fe91f90dda0c
-SHA1 (patch-cpufreq_src_cpufreq-monitor-sysctl.c) = 430a6bf29c638d6cd4b4ce3e54a3bed747337712
-SHA1 (patch-cpufreq_src_cpufreq-monitor-sysctl.h) = b079bc3e40ce1f960096fcb1b4568b18d01a1121
-SHA1 (patch-cpufreq_src_cpufreq-selector.c) = b9aef12a3ef9703a35bfa350b44891d98a1eaa31
-SHA1 (patch-cpufreq_src_cpufreq-utils.c) = 2d420ee31fa114a397062463b6762020cbc6ece8
+BLAKE2s (mate-applets-1.26.1.tar.xz) = 089d10a1a37c8dbcdb575f5567dceb53dd38dd074b96bf8ccbf183fe95752712
+SHA512 (mate-applets-1.26.1.tar.xz) = 7243825098f9101542b9eead2f60ac7f12e044ceb685da92a29fe72b2dc1271e1fa34dbc4c47148e2331a2af79d69f787dc8856c7112b75ef0a3dea97e4ab8fd
+Size (mate-applets-1.26.1.tar.xz) = 8475672 bytes
diff --git a/x11/mate-applets/patches/patch-configure b/x11/mate-applets/patches/patch-configure
deleted file mode 100644
index 80fc641b345..00000000000
--- a/x11/mate-applets/patches/patch-configure
+++ /dev/null
@@ -1,25 +0,0 @@
-$NetBSD: patch-configure,v 1.2 2019/12/30 22:36:19 gutteridge Exp $
-
-Allow configure to enable cpufreq.
-
---- configure.orig 2019-09-19 12:20:19.000000000 +0000
-+++ configure
-@@ -16910,7 +16910,7 @@ if test "x$HAVE_POLKIT" = "xyes"; then
- fi
-
- build_cpufreq_applet=yes
--if test "x$disable_cpufreq" = "xno"; then :
-+if test "x$enable_cpufreq" = "xyes"; then :
-
- case "${host}" in
- *linux*)
-@@ -17126,6 +17126,9 @@ fi
-
-
- ;;
-+ *netbsd*)
-+ build_cpufreq_applet=yes
-+ ;;
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ${host} is not supported by cpufreq applet, not building" >&5
- $as_echo "$as_me: WARNING: ${host} is not supported by cpufreq applet, not building" >&2;}
diff --git a/x11/mate-applets/patches/patch-cpufreq_src_Makefile.in b/x11/mate-applets/patches/patch-cpufreq_src_Makefile.in
deleted file mode 100644
index 0c78b108430..00000000000
--- a/x11/mate-applets/patches/patch-cpufreq_src_Makefile.in
+++ /dev/null
@@ -1,51 +0,0 @@
-$NetBSD: patch-cpufreq_src_Makefile.in,v 1.2 2019/03/06 06:48:22 gutteridge Exp $
-
-Hook sysctl file.
-
---- cpufreq/src/Makefile.in.orig 2019-02-25 15:12:46.000000000 +0000
-+++ cpufreq/src/Makefile.in
-@@ -113,7 +113,7 @@ am__mate_cpufreq_applet_SOURCES_DIST = c
- cpufreq-monitor-procfs.h cpufreq-monitor-sysfs.c \
- cpufreq-monitor-sysfs.h cpufreq-monitor-libcpufreq.c \
- cpufreq-monitor-libcpufreq.h cpufreq-monitor-cpuinfo.c \
-- cpufreq-monitor-cpuinfo.h
-+ cpufreq-monitor-cpuinfo.h cpufreq-monitor-sysctl.h cpufreq-monitor-sysctl.c
- @HAVE_LIBCPUFREQ_TRUE@am__objects_1 = \
- @HAVE_LIBCPUFREQ_TRUE@ cpufreq-monitor-libcpufreq.$(OBJEXT)
- am_mate_cpufreq_applet_OBJECTS = cpufreq-applet.$(OBJEXT) \
-@@ -122,7 +122,8 @@ am_mate_cpufreq_applet_OBJECTS = cpufreq
- cpufreq-monitor.$(OBJEXT) cpufreq-monitor-factory.$(OBJEXT) \
- cpufreq-monitor-procfs.$(OBJEXT) \
- cpufreq-monitor-sysfs.$(OBJEXT) $(am__objects_1) \
-- cpufreq-monitor-cpuinfo.$(OBJEXT)
-+ cpufreq-monitor-cpuinfo.$(OBJEXT) \
-+ cpufreq-monitor-sysctl.$(OBJEXT)
- mate_cpufreq_applet_OBJECTS = $(am_mate_cpufreq_applet_OBJECTS)
- am__DEPENDENCIES_1 =
- mate_cpufreq_applet_DEPENDENCIES = $(am__DEPENDENCIES_1) \
-@@ -151,6 +152,7 @@ am__depfiles_remade = ./$(DEPDIR)/cpufre
- ./$(DEPDIR)/cpufreq-monitor-factory.Po \
- ./$(DEPDIR)/cpufreq-monitor-libcpufreq.Po \
- ./$(DEPDIR)/cpufreq-monitor-procfs.Po \
-+ ./$(DEPDIR)/cpufreq-monitor-sysctl.Po \
- ./$(DEPDIR)/cpufreq-monitor-sysfs.Po \
- ./$(DEPDIR)/cpufreq-monitor.Po ./$(DEPDIR)/cpufreq-popup.Po \
- ./$(DEPDIR)/cpufreq-prefs.Po ./$(DEPDIR)/cpufreq-selector.Po \
-@@ -479,7 +481,8 @@ mate_cpufreq_applet_SOURCES = \
- cpufreq-monitor-procfs.c cpufreq-monitor-procfs.h \
- cpufreq-monitor-sysfs.c cpufreq-monitor-sysfs.h \
- $(cpufreq_files) \
-- cpufreq-monitor-cpuinfo.c cpufreq-monitor-cpuinfo.h
-+ cpufreq-monitor-cpuinfo.c cpufreq-monitor-cpuinfo.h \
-+ cpufreq-monitor-sysctl.c cpufreq-monitor-sysctl.h
-
- mate_cpufreq_applet_LDADD = \
- $(MATE_APPLETS4_LIBS) \
-@@ -582,6 +585,7 @@ distclean-compile:
-
- @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpufreq-applet.Po@am__quote@ # am--include-marker
- @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpufreq-monitor-cpuinfo.Po@am__quote@ # am--include-marker
-+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpufreq-monitor-sysctl.Po@am__quote@ # am--include-marker
- @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpufreq-monitor-factory.Po@am__quote@ # am--include-marker
- @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpufreq-monitor-libcpufreq.Po@am__quote@ # am--include-marker
- @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpufreq-monitor-procfs.Po@am__quote@ # am--include-marker
diff --git a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-cpuinfo.c b/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-cpuinfo.c
deleted file mode 100644
index 65d2efdf8fd..00000000000
--- a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-cpuinfo.c
+++ /dev/null
@@ -1,59 +0,0 @@
-$NetBSD: patch-cpufreq_src_cpufreq-monitor-cpuinfo.c,v 1.1 2019/01/23 15:25:36 youri Exp $
-
-Add NetBSD support.
-
---- cpufreq/src/cpufreq-monitor-cpuinfo.c.orig 2018-01-14 14:48:43.000000000 +0000
-+++ cpufreq/src/cpufreq-monitor-cpuinfo.c
-@@ -29,6 +29,12 @@
- #include <string.h>
- #include <stdio.h>
-
-+#ifdef __NetBSD__
-+#include <sys/param.h>
-+#include <sys/sysctl.h>
-+#include <err.h>
-+#endif
-+
- #include "cpufreq-monitor-cpuinfo.h"
- #include "cpufreq-utils.h"
-
-@@ -64,15 +70,20 @@ cpufreq_monitor_cpuinfo_new (guint cpu)
- static gboolean
- cpufreq_monitor_cpuinfo_run (CPUFreqMonitor *monitor)
- {
-+#ifndef __NetBSD__
- gchar *file;
- gchar **lines;
- gchar *buffer = NULL;
- gchar *p;
-+#else
-+ size_t len;
-+#endif
- gint cpu, i;
- gint cur_freq, max_freq;
- gchar *governor;
- GError *error = NULL;
-
-+#ifndef __NetBSD__
- file = g_strdup ("/proc/cpuinfo");
- if (!cpufreq_file_get_contents (file, &buffer, NULL, &error)) {
- g_warning ("%s", error->message);
-@@ -117,9 +128,17 @@ cpufreq_monitor_cpuinfo_run (CPUFreqMoni
-
- g_strfreev (lines);
- g_free (buffer);
-+#else
-+ len = sizeof(cpu);
-+ if (sysctlbyname("kern.clockrate", &cpu, &len, NULL, 0) < 1) {
-+ errx(1, "Failed to get kern.clockrate");
-+ return FALSE;
-+ }
-+ printf("got clockrate = %d\n", cpu);
-+#endif
-
- governor = g_strdup (_("Frequency Scaling Unsupported"));
-- cur_freq = cpu * 1000;
-+ cur_freq = cpu;
- max_freq = cur_freq;
-
- g_object_set (G_OBJECT (monitor),
diff --git a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-factory.c b/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-factory.c
deleted file mode 100644
index cf6a02067b5..00000000000
--- a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-factory.c
+++ /dev/null
@@ -1,53 +0,0 @@
-$NetBSD: patch-cpufreq_src_cpufreq-monitor-factory.c,v 1.1 2019/01/23 15:25:36 youri Exp $
-
-Add NetBSD support.
-
---- cpufreq/src/cpufreq-monitor-factory.c.orig 2018-01-14 14:48:43.000000000 +0000
-+++ cpufreq/src/cpufreq-monitor-factory.c
-@@ -25,11 +25,18 @@
-
- #include <glib.h>
- #include <glib/gi18n.h>
-+#ifdef __NetBSD__
-+#include <sys/param.h>
-+#include <sys/sysctl.h>
-+#endif
-
- #include "cpufreq-applet.h"
- #include "cpufreq-utils.h"
- #include "cpufreq-monitor-sysfs.h"
- #include "cpufreq-monitor-procfs.h"
-+#ifdef __NetBSD__
-+#include "cpufreq-monitor-sysctl.h"
-+#endif
- #include "cpufreq-monitor-cpuinfo.h"
- #ifdef HAVE_LIBCPUFREQ
- #include "cpufreq-monitor-libcpufreq.h"
-@@ -40,6 +47,7 @@ CPUFreqMonitor *
- cpufreq_monitor_factory_create_monitor (guint cpu)
- {
- CPUFreqMonitor *monitor = NULL;
-+#ifndef __NetBSD__
-
- #ifdef HAVE_LIBCPUFREQ
- monitor = cpufreq_monitor_libcpufreq_new (cpu);
-@@ -63,6 +71,19 @@ cpufreq_monitor_factory_create_monitor (
-
- monitor = cpufreq_monitor_cpuinfo_new (cpu);
- }
-+#else
-+ size_t len;
-+
-+ if (sysctlbyname ("machdep.est.frequency.current", NULL, &len, NULL, 0) == 0) {
-+ monitor = cpufreq_monitor_sysctl_new (cpu);
-+ } else {
-+ cpufreq_utils_display_error (_("CPU frequency scaling unsupported"),
-+ _("You will not be able to modify the frequency of your machine. "
-+ "Your machine may be misconfigured or not have hardware support "
-+ "for CPU frequency scaling."));
-+ monitor = cpufreq_monitor_cpuinfo_new (cpu);
-+ }
-+#endif /* __NetBSD__ */
-
- return monitor;
- }
diff --git a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-sysctl.c b/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-sysctl.c
deleted file mode 100644
index 812d8667bda..00000000000
--- a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-sysctl.c
+++ /dev/null
@@ -1,189 +0,0 @@
-$NetBSD: patch-cpufreq_src_cpufreq-monitor-sysctl.c,v 1.1 2019/01/23 15:25:36 youri Exp $
-
-Add NetBSD support, adapted from freebsd ports.
-
---- cpufreq/src/cpufreq-monitor-sysctl.c.orig 2019-01-23 13:06:18.405523935 +0000
-+++ cpufreq/src/cpufreq-monitor-sysctl.c
-@@ -0,0 +1,182 @@
-+/*
-+ * Copyright (C) 2001, 2002 Free Software Foundation
-+ *
-+ * This library is free software; you can redistribute it and/or
-+ * modify it under the terms of the GNU General Public
-+ * License as published by the Free Software Foundation; either
-+ * version 2 of the License, or (at your option) any later version.
-+ *
-+ * This library is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ * General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU General Public
-+ * License along with this library; if not, write to the Free
-+ * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-+ *
-+ * Authors : Joe Marcus Clarke <marcus@FreeBSD.org>
-+ * Youri Mouton <youri@NetBSD.org>
-+ */
-+
-+#include <glib.h>
-+#include <glib/gi18n.h>
-+
-+#include <string.h>
-+
-+#ifdef __NetBSD__
-+#include <errno.h>
-+#include <sys/types.h>
-+#include <sys/sysctl.h>
-+
-+#include "cpufreq-monitor-sysctl.h"
-+
-+#define PARENT_TYPE TYPE_CPUFREQ_MONITOR
-+
-+#define CPUFREQ_MONITOR_GET_PROTECTED(obj) (G_TYPE_INSTANCE_GET_PRIVATE((obj), PARENT_TYPE, CPUFreqMonitorProtected))
-+
-+static void cpufreq_monitor_sysctl_class_init (CPUFreqMonitorSysctlClass *klass);
-+
-+static gboolean cpufreq_monitor_sysctl_run (CPUFreqMonitor *monitor);
-+static GList *cpufreq_monitor_sysctl_get_available_frequencies (CPUFreqMonitor *monitor);
-+static GList *cpufreq_monitor_sysctl_get_available_governors (CPUFreqMonitor *monitor);
-+
-+static gboolean cpufreq_monitor_sysctl_get (gpointer gdata);
-+
-+G_DEFINE_TYPE (CPUFreqMonitorSysctl, cpufreq_monitor_sysctl, CPUFREQ_TYPE_MONITOR)
-+
-+static void
-+cpufreq_monitor_sysctl_init (CPUFreqMonitorSysctl *monitor)
-+{
-+}
-+
-+static void
-+cpufreq_monitor_sysctl_class_init (CPUFreqMonitorSysctlClass *klass)
-+{
-+ CPUFreqMonitorClass *monitor_class = CPUFREQ_MONITOR_CLASS (klass);
-+
-+ monitor_class->run = cpufreq_monitor_sysctl_run;
-+ monitor_class->get_available_frequencies = cpufreq_monitor_sysctl_get_available_frequencies;
-+ monitor_class->get_available_governors = cpufreq_monitor_sysctl_get_available_governors;
-+}
-+
-+CPUFreqMonitor *
-+cpufreq_monitor_sysctl_new (guint cpu)
-+{
-+ CPUFreqMonitorSysctl *monitor;
-+
-+ monitor = g_object_new (TYPE_CPUFREQ_MONITOR_SYSCTL, "cpu", cpu, NULL);
-+
-+ return CPUFREQ_MONITOR (monitor);
-+}
-+
-+static gboolean
-+cpufreq_monitor_sysctl_run (CPUFreqMonitor *monitor)
-+{
-+ gint fmax, fmin, ifreq;
-+ gchar *governor;
-+ size_t len;
-+ gchar *freq_oid;
-+ guint mon_cpu;
-+ GList *list;
-+
-+ list = cpufreq_monitor_sysctl_get_available_frequencies (CPUFREQ_MONITOR (monitor));
-+
-+ fmax = (int)strtol(g_list_first(list), (char **)NULL, 10);
-+ if (errno)
-+ errx(1, "Failed to strtol for fmax");
-+ fmin = (int)strtol(g_list_last(list), (char **)NULL, 10);
-+ if (errno)
-+ errx(1, "Failed to strtol for fmin");
-+
-+ g_list_foreach (list, (GFunc) g_free, NULL);
-+ g_list_free (list);
-+
-+ g_object_get (G_OBJECT (monitor), "cpu", &mon_cpu, NULL);
-+ len = sizeof (ifreq);
-+ freq_oid = g_strdup_printf ("machdep.est.frequency.current", 0);
-+
-+ if (sysctlbyname (freq_oid, &ifreq, &len, NULL, 0) == -1) {
-+ errx(1, "failed to get machdep.est.frequency.current: %s\n", strerror(errno));
-+ g_free (freq_oid);
-+ return FALSE;
-+ }
-+
-+ if (ifreq == fmax)
-+ governor = g_strdup ("performance");
-+ else if (ifreq == fmin)
-+ governor = g_strdup ("economy");
-+ else
-+ governor = g_strdup ("userspace");
-+
-+ g_object_set (G_OBJECT (monitor),
-+ "online", TRUE,
-+ "governor", governor,
-+ "frequency", ifreq,
-+ "max-frequency", fmax,
-+ NULL);
-+
-+ g_free (governor);
-+
-+ return TRUE;
-+}
-+
-+static GList *
-+cpufreq_monitor_sysctl_get_available_frequencies (CPUFreqMonitor *monitor)
-+{
-+ gchar *levels_oid, *levels;
-+ gchar **levelsp, **l;
-+ GList *list = NULL;
-+ gint mib[4];
-+ guint mon_cpu;
-+ size_t len;
-+
-+ g_object_get (G_OBJECT (monitor), "cpu", &mon_cpu, NULL);
-+
-+ levels_oid = g_strdup_printf ("machdep.est.frequency.available",
-+ 0);
-+ len = 4;
-+ sysctlnametomib (levels_oid, mib, &len);
-+ len = sizeof (levels);
-+ g_free (levels_oid);
-+
-+ if (sysctl (mib, 4, NULL, &len, NULL, 0) == -1)
-+ return NULL;
-+
-+ levels = g_malloc (len);
-+ if (sysctl (mib, 4, levels, &len, NULL, 0) == -1)
-+ {
-+ g_free(levels);
-+ return NULL;
-+ }
-+
-+ levelsp = g_strsplit (levels, " ", 0);
-+ g_free (levels);
-+
-+ for (l = levelsp; l && *l; l++) {
-+ int freq = (int)strtol(*l, (char **)NULL, 0);
-+ if (errno)
-+ errx(1, "Failed to strtol freq levels");
-+ freq *= 1000;
-+ char *f = g_strdup_printf("%d", freq);
-+ list = g_list_append(list, f);
-+ }
-+
-+
-+ g_strfreev (levelsp);
-+
-+ return (list);
-+}
-+
-+static GList *
-+cpufreq_monitor_sysctl_get_available_governors (CPUFreqMonitor *monitor)
-+{
-+ GList *list = NULL;
-+
-+ list = g_list_prepend (list, g_strdup ("performance"));
-+ list = g_list_prepend (list, g_strdup ("userspace"));
-+ list = g_list_prepend (list, g_strdup ("economy"));
-+
-+ return list;
-+}
-+#endif /* __NetBSD__ */
diff --git a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-sysctl.h b/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-sysctl.h
deleted file mode 100644
index d4fbeda01e4..00000000000
--- a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-monitor-sysctl.h
+++ /dev/null
@@ -1,55 +0,0 @@
-$NetBSD: patch-cpufreq_src_cpufreq-monitor-sysctl.h,v 1.1 2019/01/23 15:25:36 youri Exp $
-
-Add NetBSD sysctl backend, adapted from freebsd ports
-
---- cpufreq/src/cpufreq-monitor-sysctl.h.orig 2019-01-23 11:12:16.438531424 +0000
-+++ cpufreq/src/cpufreq-monitor-sysctl.h
-@@ -0,0 +1,48 @@
-+/* Copyright (C) 2001, 2002 Free Software Foundation
-+ *
-+ * This library is free software; you can redistribute it and/or
-+ * modify it under the terms of the GNU General Public
-+ * License as published by the Free Software Foundation; either
-+ * version 2 of the License, or (at your option) any later version.
-+ *
-+ * This library is distributed in the hope that it will be useful,
-+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
-+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-+ * General Public License for more details.
-+ *
-+ * You should have received a copy of the GNU General Public
-+ * License along with this library; if not, write to the Free
-+ * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
-+ *
-+ * Authors : Joe Marcus Clarke <marcus@FreeBSD.org>
-+ */
-+
-+#ifndef __CPUFREQ_MONITOR_SYSCTL_H__
-+#define __CPUFREQ_MONITOR_SYSCTL_H__
-+
-+#include <glib-object.h>
-+
-+#include "cpufreq-monitor.h"
-+
-+#define TYPE_CPUFREQ_MONITOR_SYSCTL (cpufreq_monitor_sysctl_get_type ())
-+#define CPUFREQ_MONITOR_SYSCTL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CPUFREQ_MONITOR_SYSCTL, CPUFreqMonitorSysctl))
-+#define CPUFREQ_MONITOR_SYSCTL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), TYPE_CPUFREQ_MONITOR_SYSCTL, CPUFreqMonitorSysctlClass))
-+#define IS_CPUFREQ_MONITOR_SYSCTL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CPUFREQ_MONITOR_SYSCTL))
-+#define IS_CPUFREQ_MONITOR_SYSCTL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CPUFREQ_MONITOR_SYSCTL))
-+#define CPUFREQ_MONITOR_SYSCTL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CPUFREQ_MONITOR_SYSCTL, CPUFreqMonitorSysctlClass))
-+
-+typedef struct _CPUFreqMonitorSysctl CPUFreqMonitorSysctl;
-+typedef struct _CPUFreqMonitorSysctlClass CPUFreqMonitorSysctlClass;
-+
-+struct _CPUFreqMonitorSysctl {
-+ CPUFreqMonitor parent;
-+};
-+
-+struct _CPUFreqMonitorSysctlClass {
-+ CPUFreqMonitorClass parent_class;
-+};
-+
-+GType cpufreq_monitor_sysctl_get_type (void) G_GNUC_CONST;
-+CPUFreqMonitor *cpufreq_monitor_sysctl_new (guint cpu);
-+
-+#endif /* __CPUFREQ_MONITOR_SYSCTL_H__ */
diff --git a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-selector.c b/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-selector.c
deleted file mode 100644
index c06b85b8074..00000000000
--- a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-selector.c
+++ /dev/null
@@ -1,19 +0,0 @@
-$NetBSD: patch-cpufreq_src_cpufreq-selector.c,v 1.1 2019/01/23 15:25:36 youri Exp $
-
-Add NetBSD backend.
-
---- cpufreq/src/cpufreq-selector.c.orig 2019-01-23 11:23:52.583081163 +0000
-+++ cpufreq/src/cpufreq-selector.c
-@@ -18,7 +18,12 @@
- */
-
- #include <config.h>
-+#ifdef __Linux__
- #include <sys/sysinfo.h>
-+#else
-+#include "cpufreq-utils.h"
-+#define get_nprocs cpufreq_utils_get_n_cpus
-+#endif
-
- #ifdef HAVE_POLKIT
- #include <dbus/dbus-glib.h>
diff --git a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-utils.c b/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-utils.c
deleted file mode 100644
index 886ae10a1af..00000000000
--- a/x11/mate-applets/patches/patch-cpufreq_src_cpufreq-utils.c
+++ /dev/null
@@ -1,44 +0,0 @@
-$NetBSD: patch-cpufreq_src_cpufreq-utils.c,v 1.1 2019/01/23 15:25:36 youri Exp $
-
-Add NetBSD backend.
-
---- cpufreq/src/cpufreq-utils.c.orig 2018-01-14 14:48:43.000000000 +0000
-+++ cpufreq/src/cpufreq-utils.c
-@@ -29,6 +29,11 @@
- #include <unistd.h>
- #include <string.h>
- #include <errno.h>
-+#ifdef __NetBSD__
-+#include <sys/param.h>
-+#include <sys/sysctl.h>
-+#include <err.h>
-+#endif
-
- #include "cpufreq-utils.h"
-
-@@ -36,6 +41,17 @@
- #include <dbus/dbus-glib.h>
- #endif /* HAVE_POLKIT */
-
-+#ifdef __NetBSD__
-+guint
-+cpufreq_utils_get_n_cpus (void)
-+{
-+ guint ncpu = -1;
-+ size_t len = sizeof(ncpu);
-+ if (sysctlbyname("hw.ncpu", &ncpu, &len, NULL, 0) < 0)
-+ errx(1, "Failed to get hw.ncpu");
-+ return ncpu;
-+}
-+#else
- guint
- cpufreq_utils_get_n_cpus (void)
- {
-@@ -78,6 +94,7 @@ cpufreq_utils_get_n_cpus (void)
-
- return 1;
- }
-+#endif
-
- void
- cpufreq_utils_display_error (const gchar *message,