diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2012-04-24 20:21:16 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2012-04-24 20:21:16 (GMT) |
commit | 8a61ab56e17a17d97a2b3bda903b4276853a2c52 (patch) | |
tree | f7587ec802d28b8abaedf99e98dd2ba9084c5e6f /unix/tclUnixCompat.c | |
parent | 71acdfe5290b0ced36fe5ff4233c1f441387038b (diff) | |
parent | f7ffb38ba6d308a94ce5e44d88027430ee1c1711 (diff) | |
download | tcl-8a61ab56e17a17d97a2b3bda903b4276853a2c52.zip tcl-8a61ab56e17a17d97a2b3bda903b4276853a2c52.tar.gz tcl-8a61ab56e17a17d97a2b3bda903b4276853a2c52.tar.bz2 |
[Bug 3508771] load tclreg.dll in cygwin tclsh
Implement TclWinGetSockOpt, TclWinGetServByName
and TclWinCPUID for Cygwin
Diffstat (limited to 'unix/tclUnixCompat.c')
-rw-r--r-- | unix/tclUnixCompat.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/unix/tclUnixCompat.c b/unix/tclUnixCompat.c index 16e7a61..aad3d76 100644 --- a/unix/tclUnixCompat.c +++ b/unix/tclUnixCompat.c @@ -692,8 +692,11 @@ TclWinCPUID( { int status = TCL_ERROR; - /* There is no reason this couldn't be implemented on UNIX as well */ - return status; +#ifdef HAVE_CPUID + __asm__ __volatile__ ("cpuid":\ + "=a" (regsPtr[0]), "=b" (regsPtr[1]), "=c" (regsPtr[2]), "=d" (regsPtr[3]) : "a" (index)); + status = TCL_OK; +#endif return status; } /* |