Hi,
getenv(..) comes from stdlib.h and belongs to the ANSI C standard functions. It will work on every system that has a C runtime library, not just on Windows machines.
The Microsoft help page about the function (
here) states it will work on: Windows 95, Windows 98, Windows 98 Second Edition, Windows Millennium Edition, Windows NT 4.0, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 .. and I am pretty sure they just forgot to mention their newer systems.
They also mention that the function is deprecated and that getenv_s should be used instead.
I hope that helps.
Cheerio!