4
0
mirror of git://sourceware.org/git/newlib-cygwin.git synced 2025-02-02 04:20:28 +08:00

Cygwin: 3.4-only: uname: drop dot from external release info

Right now, the dot between the version and the machine info in
the release field is expected to come in from CYGPORT_RELEASE_INFO.
But that's just confusing and doesn't match what we now do in 3.5
since commit 97eb64b909bc ("Cygwin: uname: generate default release
string from git as well")

Add the dot when attaching the machine info.

Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
This commit is contained in:
Corinna Vinschen 2022-12-08 18:48:45 +01:00
parent 3baeb898ee
commit b5eba8e972

View File

@ -45,7 +45,7 @@ uname_x (struct utsname *name)
#ifdef CYGPORT_RELEASE_INFO #ifdef CYGPORT_RELEASE_INFO
stpcpy (name->release, __XSTRING (CYGPORT_RELEASE_INFO)); stpcpy (name->release, __XSTRING (CYGPORT_RELEASE_INFO));
#else #else
__small_sprintf (name->release, "%d.%d.%d-0.%d.local.", __small_sprintf (name->release, "%d.%d.%d-0.%d.local",
cygwin_version.dll_major / 1000, cygwin_version.dll_major / 1000,
cygwin_version.dll_major % 1000, cygwin_version.dll_major % 1000,
cygwin_version.dll_minor, cygwin_version.dll_minor,
@ -58,10 +58,10 @@ uname_x (struct utsname *name)
switch (wincap.cpu_arch ()) switch (wincap.cpu_arch ())
{ {
case PROCESSOR_ARCHITECTURE_AMD64: case PROCESSOR_ARCHITECTURE_AMD64:
strcat (name->release, strcpy (name->machine, "x86_64")); strcat (name->release, strcpy (name->machine, ".x86_64"));
break; break;
default: default:
strcpy (name->machine, "unknown"); strcpy (name->machine, ".unknown");
break; break;
} }
/* domainame */ /* domainame */