Bug 140369 - LO operating system info doesn't match macOS version info
Summary: LO operating system info doesn't match macOS version info
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
7.1.0.3 release
Hardware: x86-64 (AMD64) macOS (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: macOS-UI-polish
  Show dependency treegraph
 
Reported: 2021-02-12 10:13 UTC by Rob
Modified: 2022-09-08 11:12 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
macOS 11.2.1 vs 10.16 (104.28 KB, image/png)
2021-02-15 10:21 UTC, steve
Details
macOS 12.5.1, LO 7.4.0.3 worksforme (248.26 KB, image/png)
2022-09-06 11:02 UTC, steve
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rob 2021-02-12 10:13:34 UTC
Description:
Reported MacOS version in LibreOffice not correct.

Steps to Reproduce:
1. Open "About Libreoffice"
2. Note MacOS version info
3. Open "About this Mac"
4. Verify real OS version.

Actual Results:
LO "about LibreOffice" reports "... OS: Mac OS X 10.16; ..."

Expected Results:
LO should report "MacOS 11.2.1"


Reproducible: Always


User Profile Reset: No



Additional Info:
Version: 7.1.0.3 / LibreOffice Community
Build ID: f6099ecf3d29644b5008cc8f48f42f4a40986e4c
CPU threads: 4; OS: Mac OS X 10.16; UI render: default; VCL: osx
Locale: nl-NL (nl_NL.UTF-8); UI: en-US
Calc: threaded
Comment 1 Rob 2021-02-12 10:17:43 UTC
Info provided by Mike Kaganski:

Haven't found a report in bug tracker.
Code pointer: AquaSalInstance::getOSVersion() in vcl/osx/salinst.cxx.
A similar problem was fixed for Windows some time ago in commit 0dd2e602e5c1b46e82abc6051677aeaab1d265b8.
Comment 2 steve 2021-02-15 10:21:32 UTC
Created attachment 169755 [details]
macOS 11.2.1 vs 10.16

Confirming, reason is https://eclecticlight.co/2020/07/21/big-sur-is-both-10-16-and-11-0-its-official/

Mozilla has the same problem with Firefox crash reporting: https://bugzilla.mozilla.org/show_bug.cgi?id=1690604

Should this be addressed would be nice to rename "Mac OS X" to "macOS" in about dialog as that is the correct name for that operating system.
Comment 3 steve 2022-09-06 11:02:28 UTC
Created attachment 182252 [details]
macOS 12.5.1, LO 7.4.0.3 worksforme

macOS 12.5.1
LibreOffice 7.4.0.3
worksforme
Comment 4 Sierk Bornemann 2022-09-06 12:40:26 UTC
(In reply to steve from comment #3)
> Created attachment 182252 [details]
> macOS 12.5.1, LO 7.4.0.3 worksforme
> 
> macOS 12.5.1
> LibreOffice 7.4.0.3
> worksforme

What about the second part of your #2 comment above

> …
> Should this be addressed would be nice to rename "Mac OS X" to "macOS" in
> about dialog as that is the correct name for that operating system.

?

LO's About window still says "Mac OS X" rather than "macOS".

I guess, it still comes from reading the ProductName key value of /System/Library/CoreServices/SystemVersionCompat.plist (<key>ProductName</key><string>Mac OS X</string>) rather than that in /System/Library/CoreServices/SystemVersion.plist (<key>ProductName</key><string>macOS</string>)?

Short explanation concerning these two files and which one to choose or to prefer, see https://eclecticlight.co/2020/08/13/macos-version-numbering-isnt-so-simple/, section "Interpreted and JIT languages" and especially the last sentence of the last paragraph of that section.

Following that – maybe it would be better anyway, to determine and extracting that info based on

/usr/sbin/system_profiler SPSoftwareDataType resp. /usr/sbin/system_profiler SPSoftwareDataType -detailLevel mini ?
Comment 5 Sierk Bornemann 2022-09-06 13:12:24 UTC
(In reply to Sierk Bornemann from comment #4)

> …
> Following that – maybe it would be better anyway, to determine and
> extracting that info based on
> 
> /usr/sbin/system_profiler SPSoftwareDataType resp. /usr/sbin/system_profiler
> SPSoftwareDataType -detailLevel mini ?

or simpler getting it via

/usr/bin/sw_vers -productName
/usr/bin/sw_vers -productVersion

?

/usr/bin/sw_vers seems to read /System/Library/CoreServices/SystemVersion.plist, if I interpret its manpage correctly.
Comment 6 steve 2022-09-08 10:54:10 UTC
Thanks for raising that remaining issue which would be https://bugs.documentfoundation.org/show_bug.cgi?id=148071 as per the one problem per bug rule.

Feel free to add yourself to cc: and copy your comments to that bug.