Hello, Thanks to recent py-sphinx update, here is the diff to update polybar.
On the old version of the port, i3 support was explicitly disabled, don't know why. I re-enabled it and it works fine. Works on amd64. OK? Le 17/02/2021 à 11:37, Stuart Henderson a écrit : > Hold off on the update, or disable doc generation, or try to patch > around it. >
? maildiff Index: Makefile =================================================================== RCS file: /cvs/ports/x11/polybar/Makefile,v retrieving revision 1.11 diff -u -p -r1.11 Makefile --- Makefile 10 Dec 2020 02:20:31 -0000 1.11 +++ Makefile 23 Feb 2021 09:36:42 -0000 @@ -1,10 +1,9 @@ # $OpenBSD: Makefile,v 1.11 2020/12/10 02:20:31 daniel Exp $ COMMENT = fast and easy-to-use status bar -V = 3.4.3 +V = 3.5.4 DISTNAME = polybar-$V CATEGORIES = x11 -REVISION = 1 HOMEPAGE = https://polybar.github.io/ MAINTAINER = Jasper Lievisse Adriaanse <jas...@openbsd.org> @@ -18,7 +17,7 @@ WANTLIB += pulse xcb xcb-composite xcb-c WANTLIB += xcb-image xcb-randr xcb-util xcb-xkb xcb-xrm z MASTER_SITES = https://github.com/polybar/polybar/releases/download/$V/ -EXTRACT_SUFX = .tar +EXTRACT_SUFX = .tar.gz # C++14 COMPILER = base-clang ports-gcc @@ -30,7 +29,7 @@ DEBUG_PACKAGES =${BUILD_PACKAGES} MODPY_VERSION = ${MODPY_DEFAULT_VERSION_3} BUILD_DEPENDS = ${RUN_DEPENDS} \ - textproc/py-sphinx${MODPY_FLAVOR}>=1.5 + textproc/py-sphinx${MODPY_FLAVOR}>=2.4.3 LIB_DEPENDS = audio/libmpdclient \ audio/pulseaudio \ @@ -43,12 +42,11 @@ RUN_DEPENDS = x11/py-xcbgen${MODPY_FLAVO fonts/unifont CONFIGURE_ARGS = -DENABLE_CCACHE=OFF \ - -DCMAKE_EXE_LINKER_FLAGS="-L${LOCALBASE}/lib -lintl -L${LOCALBASE}/lib/inotify -linotify -Wl,-rpath,${LOCALBASE}/lib/inotify" \ - -DENABLE_I3=OFF + -DCMAKE_EXE_LINKER_FLAGS="-L${LOCALBASE}/lib -lintl -L${LOCALBASE}/lib/inotify -linotify -Wl,-rpath,${LOCALBASE}/lib/inotify" NO_TEST = Yes -WRKDIST = ${WRKDIR}/polybar +WRKDIST = ${WRKDIR}/polybar-$V pre-configure: ${SUBST_CMD} ${WRKSRC}/cmake/02-opts.cmake \ Index: distinfo =================================================================== RCS file: /cvs/ports/x11/polybar/distinfo,v retrieving revision 1.4 diff -u -p -r1.4 distinfo --- distinfo 15 May 2020 08:07:55 -0000 1.4 +++ distinfo 23 Feb 2021 09:36:42 -0000 @@ -1,2 +1,2 @@ -SHA256 (polybar-3.4.3.tar) = 1O0SHB05YEk/gmj5ZtZalNlMRkakq7ExaH43tjYWgi8= -SIZE (polybar-3.4.3.tar) = 2713600 +SHA256 (polybar-3.5.4.tar.gz) = Ezr06LKfQmWVrTt3OUju4nJ1IwiHhERzhT55QMeVnCs= +SIZE (polybar-3.5.4.tar.gz) = 409258 Index: patches/patch-cmake_02-opts_cmake =================================================================== RCS file: patches/patch-cmake_02-opts_cmake diff -N patches/patch-cmake_02-opts_cmake --- patches/patch-cmake_02-opts_cmake 4 Nov 2019 19:14:00 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,14 +0,0 @@ -$OpenBSD: patch-cmake_02-opts_cmake,v 1.1 2019/11/04 19:14:00 jasper Exp $ - -Index: cmake/02-opts.cmake ---- cmake/02-opts.cmake.orig -+++ cmake/02-opts.cmake -@@ -1,7 +1,7 @@ - # - # Build options - # --checklib(BUILD_DOC "binary" sphinx-build) -+checklib(BUILD_DOC "binary" sphinx-build${MODPY_BIN_SUFFIX}) - - checklib(ENABLE_ALSA "pkg-config" alsa) - checklib(ENABLE_CURL "pkg-config" libcurl) Index: patches/patch-doc_CMakeLists_txt =================================================================== RCS file: patches/patch-doc_CMakeLists_txt diff -N patches/patch-doc_CMakeLists_txt --- patches/patch-doc_CMakeLists_txt 4 Nov 2019 19:14:00 -0000 1.1 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,14 +0,0 @@ -$OpenBSD: patch-doc_CMakeLists_txt,v 1.1 2019/11/04 19:14:00 jasper Exp $ - -Index: doc/CMakeLists.txt ---- doc/CMakeLists.txt.orig -+++ doc/CMakeLists.txt -@@ -4,7 +4,7 @@ cmake_minimum_required(VERSION 3.1.0 FATAL_ERROR) - project(polybar-doc NONE) - - find_program(SPHINX_EXECUTABLE -- NAMES sphinx-build -+ NAMES sphinx-build${MODPY_BIN_SUFFIX} - DOC "Sphinx Documentation Builder") - - if(NOT SPHINX_EXECUTABLE) Index: patches/patch-include_modules_cpu_hpp =================================================================== RCS file: /cvs/ports/x11/polybar/patches/patch-include_modules_cpu_hpp,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 patch-include_modules_cpu_hpp --- patches/patch-include_modules_cpu_hpp 20 Sep 2019 08:18:42 -0000 1.1.1.1 +++ patches/patch-include_modules_cpu_hpp 23 Feb 2021 09:36:42 -0000 @@ -3,23 +3,17 @@ $OpenBSD: patch-include_modules_cpu_hpp, Index: include/modules/cpu.hpp --- include/modules/cpu.hpp.orig +++ include/modules/cpu.hpp -@@ -7,10 +7,19 @@ POLYBAR_NS - - namespace modules { +@@ -9,7 +9,13 @@ namespace modules { struct cpu_time { -+#ifdef __OpenBSD__ unsigned long long user; unsigned long long nice; ++#ifdef __OpenBSD__ + unsigned long long sys; + unsigned long long spin; + unsigned long long intr; -+ unsigned long long idle; +#else -+ unsigned long long user; -+ unsigned long long nice; unsigned long long system; - unsigned long long idle; +#endif + unsigned long long idle; + unsigned long long steal; unsigned long long total; - }; - Index: patches/patch-lib_i3ipcpp_CMakeLists_txt =================================================================== RCS file: patches/patch-lib_i3ipcpp_CMakeLists_txt diff -N patches/patch-lib_i3ipcpp_CMakeLists_txt --- patches/patch-lib_i3ipcpp_CMakeLists_txt 11 Nov 2019 20:16:59 -0000 1.2 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,16 +0,0 @@ -$OpenBSD: patch-lib_i3ipcpp_CMakeLists_txt,v 1.2 2019/11/11 20:16:59 jasper Exp $ - -https://github.com/polybar/i3ipcpp/pull/8 - -Index: lib/i3ipcpp/CMakeLists.txt ---- lib/i3ipcpp/CMakeLists.txt.orig -+++ lib/i3ipcpp/CMakeLists.txt -@@ -33,6 +33,8 @@ if(NOT JSONCPP_FOUND) - set(JSONCPP_INCLUDEDIR ${PROJECT_SOURCE_DIR}/libs/jsoncpp-1.7.7/include) - elseif(NOT JSONCPP_LIBRARIES AND JSONCPP_LIBS) - set(JSONCPP_LIBRARIES "${JSONCPP_LIBS}") -+else() -+ set(JSONCPP_INCLUDEDIR "${JSONCPP_INCLUDE_DIRS}") - endif() - - target_link_libraries(${PROJECT_NAME} PUBLIC ${JSONCPP_LIBRARIES}) Index: patches/patch-src_modules_cpu_cpp =================================================================== RCS file: /cvs/ports/x11/polybar/patches/patch-src_modules_cpu_cpp,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 patch-src_modules_cpu_cpp --- patches/patch-src_modules_cpu_cpp 20 Sep 2019 08:18:42 -0000 1.1.1.1 +++ patches/patch-src_modules_cpu_cpp 23 Feb 2021 09:36:42 -0000 @@ -52,7 +52,7 @@ Index: src/modules/cpu.cpp try { std::ifstream in(PATH_CPU_INFO); string str; -@@ -129,7 +164,7 @@ namespace modules { +@@ -130,7 +165,7 @@ namespace modules { } catch (const std::ios_base::failure& e) { m_log.err("Failed to read CPU values (what: %s)", e.what()); } Index: patches/patch-src_modules_temperature_cpp =================================================================== RCS file: patches/patch-src_modules_temperature_cpp diff -N patches/patch-src_modules_temperature_cpp --- patches/patch-src_modules_temperature_cpp 12 Dec 2019 17:09:47 -0000 1.2 +++ /dev/null 1 Jan 1970 00:00:00 -0000 @@ -1,91 +0,0 @@ -$OpenBSD: patch-src_modules_temperature_cpp,v 1.2 2019/12/12 17:09:47 jasper Exp $ - -Index: src/modules/temperature.cpp ---- src/modules/temperature.cpp.orig -+++ src/modules/temperature.cpp -@@ -8,6 +8,17 @@ - - #include "modules/meta/base.inl" - -+#ifdef __OpenBSD__ -+#include <sys/param.h> -+#include <sys/types.h> -+#include <sys/sysctl.h> -+#include <sys/sensors.h> -+#include <errno.h> -+#include <err.h> -+ -+#define MUKTOC(v) ((v - 273150000) / 1000000.0) -+#endif -+ - POLYBAR_NS - - namespace modules { -@@ -26,9 +37,11 @@ namespace modules { - m_path = string_util::replace(PATH_TEMPERATURE_INFO, "%zone%", to_string(m_zone)); - } - -+#ifndef __OpenBSD__ - if (!file_util::exists(m_path)) { - throw module_error("The file '" + m_path + "' does not exist"); - } -+#endif /* !__OpenBSD__ */ - - m_formatter->add(DEFAULT_FORMAT, TAG_LABEL, {TAG_LABEL, TAG_RAMP}); - m_formatter->add(FORMAT_WARN, TAG_LABEL_WARN, {TAG_LABEL_WARN, TAG_RAMP}); -@@ -51,8 +64,54 @@ namespace modules { - } - - bool temperature_module::update() { -+ int temp_f; -+#ifdef __OpenBSD__ -+ /* -+ * The following code was copied from i3status/print_cpu_temperature.c -+ */ -+ struct sensordev sensordev; -+ struct sensor sensor; -+ size_t sdlen, slen; -+ char device[16]; -+ int dev, mib[5] = {CTL_HW, HW_SENSORS, 0, 0, 0}; -+ -+ sdlen = sizeof(sensordev); -+ slen = sizeof(sensor); -+ -+ /* -+ * Construct a sensors MIB by using hwmon-path and thermal-zone such -+ * that hwmon-path represents the device (e.g. acpitz0 or ksmn0) and thermal-zone -+ * the Nth temperature sensor (e.g. temp0). -+ */ -+ strlcpy(device, m_path.c_str(), sizeof(device)); -+ -+ for (dev = 0;; dev++) { -+ mib[2] = dev; -+ if (sysctl(mib, 3, &sensordev, &sdlen, NULL, 0) == -1) { -+ if (errno == ENXIO) -+ continue; -+ if (errno == ENOENT) -+ break; -+ return false; -+ } -+ -+ if (strncmp(sensordev.xname, device, strlen(device)) == 0) { -+ mib[3] = SENSOR_TEMP; -+ mib[4] = m_zone; -+ if (sysctl(mib, 5, &sensor, &slen, NULL, 0) == -1) { -+ if (errno != ENOENT) { -+ m_log.warn("sysctl failed"); -+ continue; -+ } -+ } -+ } -+ } -+ m_temp = MUKTOC(sensor.value); -+#else - m_temp = std::strtol(file_util::contents(m_path).c_str(), nullptr, 10) / 1000.0f + 0.5f; -- int temp_f = floor(((1.8 * m_temp) + 32) + 0.5); -+#endif -+ -+ temp_f = floor(((1.8 * m_temp) + 32) + 0.5); - m_perc = math_util::cap(math_util::percentage(m_temp, m_tempbase, m_tempwarn), 0, 100); - - string temp_c_string = to_string(m_temp); Index: patches/patch-src_utils_file_cpp =================================================================== RCS file: /cvs/ports/x11/polybar/patches/patch-src_utils_file_cpp,v retrieving revision 1.1.1.1 diff -u -p -r1.1.1.1 patch-src_utils_file_cpp --- patches/patch-src_utils_file_cpp 20 Sep 2019 08:18:42 -0000 1.1.1.1 +++ patches/patch-src_utils_file_cpp 23 Feb 2021 09:36:42 -0000 @@ -6,7 +6,7 @@ It causes clang++ to blow up. Index: src/utils/file.cpp --- src/utils/file.cpp.orig +++ src/utils/file.cpp -@@ -43,6 +43,7 @@ file_ptr::operator int() { +@@ -46,6 +46,7 @@ file_ptr::operator int() { return static_cast<const file_ptr&>(*this); } file_ptr::operator int() const { Index: pkg/PLIST =================================================================== RCS file: /cvs/ports/x11/polybar/pkg/PLIST,v retrieving revision 1.2 diff -u -p -r1.2 PLIST --- pkg/PLIST 10 Dec 2020 02:20:31 -0000 1.2 +++ pkg/PLIST 23 Feb 2021 09:36:42 -0000 @@ -2,43 +2,50 @@ @bin bin/polybar @bin bin/polybar-msg @man man/man1/polybar.1 +@man man/man5/polybar.5 share/bash-completion/completions/polybar share/doc/polybar/ share/doc/polybar/.buildinfo share/doc/polybar/_sources/ +share/doc/polybar/_sources/dev/ +share/doc/polybar/_sources/dev/packaging.rst.txt +share/doc/polybar/_sources/dev/release-workflow.rst.txt share/doc/polybar/_sources/index.rst.txt share/doc/polybar/_sources/man/ share/doc/polybar/_sources/man/polybar.1.rst.txt +share/doc/polybar/_sources/man/polybar.5.rst.txt +share/doc/polybar/_sources/user/ +share/doc/polybar/_sources/user/actions.rst.txt share/doc/polybar/_static/ -share/doc/polybar/_static/ajax-loader.gif share/doc/polybar/_static/alabaster.css share/doc/polybar/_static/basic.css -share/doc/polybar/_static/comment-bright.png -share/doc/polybar/_static/comment-close.png -share/doc/polybar/_static/comment.png share/doc/polybar/_static/custom.css share/doc/polybar/_static/doctools.js -share/doc/polybar/_static/down-pressed.png -share/doc/polybar/_static/down.png +share/doc/polybar/_static/documentation_options.js share/doc/polybar/_static/file.png -share/doc/polybar/_static/jquery-3.1.0.js +share/doc/polybar/_static/jquery-3.5.1.js share/doc/polybar/_static/jquery.js +share/doc/polybar/_static/language_data.js share/doc/polybar/_static/minus.png share/doc/polybar/_static/plus.png share/doc/polybar/_static/pygments.css share/doc/polybar/_static/searchtools.js +share/doc/polybar/_static/underscore-1.12.0.js share/doc/polybar/_static/underscore.js -share/doc/polybar/_static/up-pressed.png -share/doc/polybar/_static/up.png -share/doc/polybar/_static/websupport.js share/doc/polybar/config +share/doc/polybar/dev/ +share/doc/polybar/dev/packaging.html +share/doc/polybar/dev/release-workflow.html share/doc/polybar/genindex.html share/doc/polybar/index.html share/doc/polybar/man/ share/doc/polybar/man/polybar.1.html +share/doc/polybar/man/polybar.5.html share/doc/polybar/objects.inv share/doc/polybar/search.html share/doc/polybar/searchindex.js +share/doc/polybar/user/ +share/doc/polybar/user/actions.html share/examples/polybar/ share/examples/polybar/config share/zsh/site-functions/_polybar