Add build architecture to version on other systems with non-x86_64
This commit is contained in:
		
							parent
							
								
									c991bbc7e3
								
							
						
					
					
						commit
						b8b268c7cc
					
				
					 1 changed files with 10 additions and 4 deletions
				
			
		|  | @ -74,12 +74,18 @@ using namespace details; | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| [[nodiscard]] QString ComputeAppVersion() { | [[nodiscard]] QString ComputeAppVersion() { | ||||||
| 	return QString::fromLatin1(AppVersionStr) + ([] { | #if defined Q_OS_WIN && defined Q_PROCESSOR_X86_64 | ||||||
|  | 	const auto arch = u" x64"_q; | ||||||
|  | #elif (defined Q_OS_WIN && defined Q_PROCESSOR_X86_32) || defined Q_PROCESSOR_X86_64 | ||||||
|  | 	const auto arch = QString(); | ||||||
|  | #else | ||||||
|  | 	const auto arch = ' ' + QSysInfo::buildCpuArchitecture(); | ||||||
|  | #endif | ||||||
|  | 	return QString::fromLatin1(AppVersionStr) + arch + ([] { | ||||||
| #if defined OS_MAC_STORE | #if defined OS_MAC_STORE | ||||||
| 		return u" Mac App Store"_q; | 		return u" Mac App Store"_q; | ||||||
| #elif defined OS_WIN_STORE // OS_MAC_STORE
 | #elif defined OS_WIN_STORE // OS_MAC_STORE
 | ||||||
| 		return (Platform::IsWindows64Bit() ? u" x64"_q : QString()) | 		return u" Microsoft Store"_q; | ||||||
| 			+ u" Microsoft Store"_q; |  | ||||||
| #elif defined Q_OS_UNIX && !defined Q_OS_MAC // OS_MAC_STORE || OS_WIN_STORE
 | #elif defined Q_OS_UNIX && !defined Q_OS_MAC // OS_MAC_STORE || OS_WIN_STORE
 | ||||||
| 		return Platform::InFlatpak() | 		return Platform::InFlatpak() | ||||||
| 			? u" Flatpak"_q | 			? u" Flatpak"_q | ||||||
|  | @ -87,7 +93,7 @@ using namespace details; | ||||||
| 			? u" Snap"_q | 			? u" Snap"_q | ||||||
| 			: QString(); | 			: QString(); | ||||||
| #else // OS_MAC_STORE || OS_WIN_STORE || (defined Q_OS_UNIX && !defined Q_OS_MAC)
 | #else // OS_MAC_STORE || OS_WIN_STORE || (defined Q_OS_UNIX && !defined Q_OS_MAC)
 | ||||||
| 		return Platform::IsWindows64Bit() ? u" x64"_q : QString(); | 		return QString(); | ||||||
| #endif // OS_MAC_STORE || OS_WIN_STORE || (defined Q_OS_UNIX && !defined Q_OS_MAC)
 | #endif // OS_MAC_STORE || OS_WIN_STORE || (defined Q_OS_UNIX && !defined Q_OS_MAC)
 | ||||||
| 	})(); | 	})(); | ||||||
| } | } | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue
	
	 Ilya Fedin
						Ilya Fedin