Thread (22 messages) flat view 22 messages, 5 authors, 2016-06-15

Re: [PATCH] Replace hard-coded path with one from <paths.h>

From: Tait <hidden>
Date: 2016-06-15 22:48:35

quoted
quoted
+#include <paths.h>
This breaks on Windows due to missing paths.h. I guess you need some
guard to detect if the header is present or not.
Is this true of all WIN32, or just __MINGW32__ / __CYGWIN__? Presumably
/usr/local/bin:/usr/bin:/bin is the wrong default PATH on windows too, so
perhaps I should sort that at the same point---what would a canonical
default PATH be for Windows?
Paths.h is not found on my version of mingw/msys.

The "canonical" Windows path is usually the system directory, and system32
and system32\Wbem under the system directory. The system directory could
be anywhere. C:\WINDOWS is common, but the WINDOWS (or even the C:) are
subject to change on any given installation. So for example on my computer,
	C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem

is the path before adding in PowerShell, Resource Kits, GTK, etc. Windows
also assumes '.' is part of your path, even though it's not explicitly
present in %PATH%.

My version of mingw seems to prepend to the above,
	.:/usr/local/bin:/mingw/bin:/bin

besides also using : instead of ; as a separator.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help