4
0
mirror of git://sourceware.org/git/newlib-cygwin.git synced 2025-02-13 20:49:08 +08:00
Johannes Schindelin 6183ff9dd5 Cygwin: Treat Windows Store's "app execution aliases" as symbolic links
When the Windows Store version of Python is installed, so-called "app
execution aliases" are put into the `PATH`. These are reparse points
under the hood, with an undocumented format.

We do know a bit about this format, though, as per the excellent analysis:
https://www.tiraniddo.dev/2019/09/overview-of-windows-execution-aliases.html

	The first 4 bytes is the reparse tag, in this case it's
	0x8000001B which is documented in the Windows SDK as
	IO_REPARSE_TAG_APPEXECLINK. Unfortunately there doesn't seem to
	be a corresponding structure, but with a bit of reverse
	engineering we can work out the format is as follows:

	Version: <4 byte integer>
	Package ID: <NUL Terminated Unicode String>
	Entry Point: <NUL Terminated Unicode String>
	Executable: <NUL Terminated Unicode String>
	Application Type: <NUL Terminated Unicode String>

Let's treat them as symbolic links. For example, in this developer's
setup, this will result in the following nice output:

	$ cd $LOCALAPPDATA/Microsoft/WindowsApps/

	$ ls -l python3.exe
	lrwxrwxrwx 1 me 4096 105 Aug 23  2020 python3.exe -> '/c/Program Files/WindowsApps/PythonSoftwareFoundation.Python.3.7_3.7.2544.0_x64__qbz5n2kfra8p0/python.exe'

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2021-03-31 11:09:42 -04:00
..
2020-10-14 10:54:21 -04:00
2020-10-14 10:54:29 -04:00
2016-06-25 00:43:01 +02:00
2020-10-14 10:54:03 -04:00
2020-10-14 10:54:03 -04:00
2021-02-01 12:16:54 -05:00
2018-02-20 17:59:53 +01:00
2021-02-01 12:16:54 -05:00
2020-10-14 10:54:29 -04:00
2020-10-19 17:54:55 -04:00
2017-03-27 22:03:58 +01:00
2015-08-17 11:05:43 +02:00
2020-12-07 14:08:38 -05:00
2020-10-14 10:54:29 -04:00
2018-04-16 22:46:11 -05:00
2020-10-14 10:54:29 -04:00
2020-10-14 10:53:55 -04:00
2020-10-14 10:53:55 -04:00