opnsense-ports/devel/py-p4python/files/patch-tools_PlatformInfo.py
Franco Fichtner bc9fc2848c */*: sync with upstream
Taken from: FreeBSD
2023-04-11 09:42:51 +02:00

13 lines
572 B
Python

--- tools/PlatformInfo.py.orig 2023-04-05 20:18:00 UTC
+++ tools/PlatformInfo.py
@@ -131,9 +131,7 @@ class PlatformInfo:
arch = self.architecture(unameOut[4])
elif unameOut[0] == 'FreeBSD':
unix = "FREEBSD"
- release = unameOut[2][0]
- if release == '5':
- release += unameOut[2][2]
+ release = re.match("(\d+.\d)", unameOut[2]).group(1).replace(".","")
arch = self.architecture(unameOut[4])
elif unameOut[0] == 'CYGWIN_NT-5.1':