Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package headscale for openSUSE:Factory 
checked in at 2026-01-05 14:53:52
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/headscale (Old)
 and      /work/SRC/openSUSE:Factory/.headscale.new.1928 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "headscale"

Mon Jan  5 14:53:52 2026 rev:17 rq:1325290 version:0.27.1

Changes:
--------
--- /work/SRC/openSUSE:Factory/headscale/headscale.changes      2025-11-13 
17:28:51.550903421 +0100
+++ /work/SRC/openSUSE:Factory/.headscale.new.1928/headscale.changes    
2026-01-05 14:56:38.614969316 +0100
@@ -1,0 +2,6 @@
+Fri Jan  2 01:19:19 UTC 2026 - Marcus Rueckert <[email protected]>
+
+- currently setting the version and commit hash via ldflags does
+  not look functional. So we patch the values in via perl for now.
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ headscale.spec ++++++
--- /var/tmp/diff_new_pack.i0Qqcu/_old  2026-01-05 14:56:41.863104279 +0100
+++ /var/tmp/diff_new_pack.i0Qqcu/_new  2026-01-05 14:56:41.867104446 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package headscale
 #
-# Copyright (c) 2025 SUSE LLC and contributors
+# Copyright (c) 2026 SUSE LLC and contributors
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -50,7 +50,20 @@
 %autosetup -a1 -p1
 
 %build
-go build -v -buildmode=pie -mod=vendor -tags "ts2019" -ldflags "-X 
github.com/juanfont/headscale/hscontrol/types.Version=%{version} -X 
github.com/juanfont/headscale/hscontrol/types.GitCommitHash=v%{version}" 
./cmd/headscale
+# currently setting the version and commit hash via ldflags does
+# not look functional. So we patch the values in via perl for now.
+
+DATE_FMT="+%%Y-%%m-%%dT%%H:%%M:%%SZ"
+BUILD_DATE=$(date -u -d "@${SOURCE_DATE_EPOCH}" "${DATE_FMT}" 2>/dev/null || 
date -u -r "${SOURCE_DATE_EPOCH}" "${DATE_FMT}" 2>/dev/null || date -u 
"${DATE_FMT}")
+
+version_file="hscontrol/types/version.go"
+
+perl -p -i.bak -e "s|(Version:\s+)\"dev\"|\$1\"%{version}\"|g ; 
s|(Commit:\s+)\"unknown\"|\$1\"v%{version}\"|g ; 
s|(BuildTime:\s+)\"unknown\"|\$1\"${BUILD_DATE}\"|g" ${version_file}
+diff -urN ${version_file}{.bak,} ||:
+rm -f ${version_file}.bak
+
+# non_working_ldflags='-ldflags "-X main.version=%{version} -X 
${version_prefix}.Version=%{version} -X 
${version_prefix}.GitCommitHash=v%{version} -X 
${version_prefix}.BuildTime=${BUILD_DATE}"'
+go build -v -buildmode=pie -mod=vendor -o headscale ./cmd/headscale
 
 %sysusers_generate_pre %{SOURCE2} %{name} %{name}.conf
 

Reply via email to