develooper Front page | perl.perl5.porters | Postings from June 2022

Re: Which versions of Windows are still supported ?

Thread Previous
From:
Tony Cook
Date:
June 1, 2022 03:32
Subject:
Re: Which versions of Windows are still supported ?
Message ID:
Ypbdy7lP7wKkCwV2@venus.tony.develop-help.com
On Tue, May 31, 2022 at 09:00:48PM -0500, Craig A. Berry wrote:
> On Tue, May 31, 2022 at 1:10 AM Nicholas Clark <nick@ccl4.org> wrote:
> > From what I remember (as a complete outsider) there are at least two
> > significant API gains from raising this to Vista. One was something to do
> > with files or maybe simlinks. The other is that (I believe) it's technically
> > just possible to really fork in Vista. (Whether this is actually like saying
> > that 'perl 5.6 is "Marketing Compatible" Unicode', or actually something
> > you'd use in anger, I don't know.)
> 
> I'm mostly an outsider too, but I think these things don't, in the
> Princess Bride sense, mean what we think they mean.  I have a vague
> memory that symlinks have very limited use cases and didn't really
> have a prayer of working in a way that could pass the Perl test suite.
> I would be delighted to discover that I am wrong or out-of-date about
> that.

There's a couple of changes that made symlinks more usable on Windows:

- Vista introduced CreateSymbolicLink() which made creating links
  simpler from a code point of view.  At that point you still needed a
  privileged process to create them.

- Windows 10 build 1703 allowed non-privileged processes to create
  symlinks, but only if: a) the system has Developer Mode enabled, and
  b) an extra flags is passed to CreateSymbolicLink()

With that, implementing readlink()[1] and a win32_stat() rewrite
symlinks became fairly usable, assuming your process had privilege, or
Developer Mode was enabled.

In terms of the test suite, IIRC the main problems was tests assuming
that symlink() being available meant it would succeed, and other code
not accounting for / vs \ separators.

Tony

[1] which alas doesn't have a simple API function

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About