This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Beginnings of a patch: /etc/hosts


Paul Johnston wrote:
Are you sure that "CYGWIN_9*)" correctly catches Windows ME?
You might take a look at my alternate patch in the patches list. It doesn't rely on that sort of thing -- it relies instead on well-known environment variables: $SYSTEMROOT and $WINDIR. It still has some OS-specific knowledge in it, in that it knows that only NT-derived OSes define SYSTEMROOT and uses WINDIR as a fallback for 9x systems. I don't know which approach is superior.

However, I think adding this belt-and-braces check might be a good idea:
I'm not a fan of the "if X, scream and die" bit in this original script or the one you've proposed. Postinstall scripts shouldn't fail. I think they should give best effort, and if they can't do what you want, they should simply quietly skip that bit. Besides, this patch may be put into some other postinstall script, and you don't want to avoid doing the other tasks in that script just because the /etc/hosts part can't find the Windows system directory.


--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]