git: e04f3b551fd0 - main - x11/autorandr: update to 1.15
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Sat, 15 Nov 2025 07:40:35 UTC
The branch main has been updated by 0mp:
URL: https://cgit.FreeBSD.org/ports/commit/?id=e04f3b551fd0016840e32740a5a58f9272e56031
commit e04f3b551fd0016840e32740a5a58f9272e56031
Author: Benjamin Takacs <nimaje+fbz@bureaucracy.de>
AuthorDate: 2025-11-14 15:16:21 +0000
Commit: Mateusz Piotrowski <0mp@FreeBSD.org>
CommitDate: 2025-11-15 07:39:53 +0000
x11/autorandr: update to 1.15
* contrib/autorandr_launcher patch was superseded by compiler define
PR: 291016
---
x11/autorandr/Makefile | 10 ++++------
x11/autorandr/distinfo | 6 +++---
x11/autorandr/files/patch-autorandr.py | 14 +++++++-------
...patch-contrib_autorandr__launcher_autorandr__launcher.c | 11 -----------
4 files changed, 14 insertions(+), 27 deletions(-)
diff --git a/x11/autorandr/Makefile b/x11/autorandr/Makefile
index a52479a478a9..e0f955d18d88 100644
--- a/x11/autorandr/Makefile
+++ b/x11/autorandr/Makefile
@@ -1,9 +1,6 @@
PORTNAME= autorandr
-DISTVERSION= 1.12.1
-PORTREVISION= 1
+DISTVERSION= 1.15
CATEGORIES= x11
-PATCH_SITES= https://github.com/phillipberndt/autorandr/commit/
-PATCHFILES= 2bc71d562765e2023b26a31c485769612e3eb91e.patch:-p1 # PR 282
MAINTAINER= 0mp@FreeBSD.org
COMMENT= Auto-detect displays and configure them with xrandr
@@ -15,7 +12,7 @@ LICENSE_FILE= ${WRKSRC}/gpl-3.0.txt
BUILD_DEPENDS= gsed:textproc/gsed
RUN_DEPENDS= xrandr:x11/xrandr
-USES= gmake pkgconfig python:3.10 shebangfix xorg
+USES= gmake pkgconfig python shebangfix xorg
# Use GitHub instead of MASTER_SITES=PYPI to get additional files like
# the manual page and the license.
USE_GITHUB= yes
@@ -37,12 +34,13 @@ _EXTRA_BUILD_TARGETS= contrib/autorandr_launcher/autorandr-launcher
_EXTRA_INSTALL_TARGETS= install_bash_completion install_launcher \
install_manpage
+CFLAGS+= -DAUTORANDR_PATH=${PREFIX}/bin/autorandr
+
# Regenerate the patches with:
# make clean extract do-patch PATCHFILES=
post-patch:
${REINPLACE_CMD} 's|%%PREFIX%%|${PREFIX}|g' \
${WRKSRC}/${PORTNAME}.py \
- ${WRKSRC}/contrib/autorandr_launcher/autorandr_launcher.c
post-build:
${SETENV} ${MAKE_ENV} ${MAKE_CMD} -C ${BUILD_WRKSRC} ${MAKE_ARGS} \
diff --git a/x11/autorandr/distinfo b/x11/autorandr/distinfo
index f0accfab318b..e91ca36c7a80 100644
--- a/x11/autorandr/distinfo
+++ b/x11/autorandr/distinfo
@@ -1,5 +1,5 @@
-TIMESTAMP = 1647355348
-SHA256 (phillipberndt-autorandr-1.12.1_GH0.tar.gz) = 2fa2fa6e76a208dc6e2f3a5c743aef14b8b3fd0ed18132e25f79cde3a00b0309
-SIZE (phillipberndt-autorandr-1.12.1_GH0.tar.gz) = 45550
+TIMESTAMP = 1761161416
+SHA256 (phillipberndt-autorandr-1.15_GH0.tar.gz) = 1579b6b4d44669a0db22268524ea512f60da02eeecffddf81f7327aaf56485f5
+SIZE (phillipberndt-autorandr-1.15_GH0.tar.gz) = 49352
SHA256 (2bc71d562765e2023b26a31c485769612e3eb91e.patch) = e3e7335d2cd2aebe9fe8b633f570bbd22ecf0b82ada392ee5c8da1a2e41f6b34
SIZE (2bc71d562765e2023b26a31c485769612e3eb91e.patch) = 3801
diff --git a/x11/autorandr/files/patch-autorandr.py b/x11/autorandr/files/patch-autorandr.py
index c5b6286c6762..716ce45e37c6 100644
--- a/x11/autorandr/files/patch-autorandr.py
+++ b/x11/autorandr/files/patch-autorandr.py
@@ -1,6 +1,6 @@
---- autorandr.py.orig 2021-12-22 12:28:03 UTC
+--- autorandr.py.orig 2024-03-03 12:37:50 UTC
+++ autorandr.py
-@@ -121,6 +121,8 @@ Usage: autorandr [options]
+@@ -150,6 +150,8 @@ def is_closed_lid(output):
def is_closed_lid(output):
if not re.match(r'(eDP(-?[0-9]\+)*|LVDS(-?[0-9]\+)*)', output):
return False
@@ -9,7 +9,7 @@
lids = glob.glob("/proc/acpi/button/lid/*/state")
if len(lids) == 1:
state_file = lids[0]
-@@ -1114,7 +1116,7 @@ def exec_scripts(profile_path, script_name, meta_infor
+@@ -1212,7 +1214,7 @@ def exec_scripts(profile_path, script_name, meta_infor
if profile_path:
candidate_directories.append(profile_path)
candidate_directories.append(user_profile_path)
@@ -18,16 +18,16 @@
candidate_directories.append(os.path.join(config_dir, "autorandr"))
for folder in candidate_directories:
-@@ -1191,6 +1193,8 @@ def dispatch_call_to_sessions(argv):
- sys.exit(1)
- os.waitpid(child_pid, 0)
+@@ -1299,6 +1301,8 @@ def dispatch_call_to_sessions(argv):
+ if 'AUTORANDR_UID_MIN' in os.environ:
+ uid_min = int(os.environ['AUTORANDR_UID_MIN'])
+ print("/proc is not supported on FreeBSD; aborting.", file=sys.stderr)
+ sys.exit(1)
for directory in os.listdir("/proc"):
directory = os.path.join("/proc/", directory)
if not os.path.isdir(directory):
-@@ -1321,7 +1325,7 @@ def main(argv):
+@@ -1453,7 +1457,7 @@ def main(argv):
try:
# Load profiles from each XDG config directory
# The XDG spec says that earlier entries should take precedence, so reverse the order
diff --git a/x11/autorandr/files/patch-contrib_autorandr__launcher_autorandr__launcher.c b/x11/autorandr/files/patch-contrib_autorandr__launcher_autorandr__launcher.c
deleted file mode 100644
index a759cdaef292..000000000000
--- a/x11/autorandr/files/patch-contrib_autorandr__launcher_autorandr__launcher.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- contrib/autorandr_launcher/autorandr_launcher.c.orig 2022-03-15 15:02:37 UTC
-+++ contrib/autorandr_launcher/autorandr_launcher.c
-@@ -38,7 +38,7 @@ static int ar_launch()
- pid_t pid = fork();
- if (pid == 0) {
- static char *argv[] =
-- { "/usr/bin/autorandr", "--change", "--default", "default", NULL };
-+ { "%%PREFIX%%/bin/autorandr", "--change", "--default", "default", NULL };
- execve(argv[0], argv, environ);
- exit(127);
- } else {