forked from Alexpux/Cygwin
-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow native symlinks to non-existing targets in 'nativestrict' mode #10
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Windows native symlinks must match the type of their target (file or directory), otherwise native Windows tools will fail. Creating symlinks in 'nativestrict' mode currently requires the target to exist in order to check its type. However, the target of a symlink can change at any time after the symlink has been created. Thus users of native symlinks must be prepared to deal with type mismatches anyway. Checking the target type at symlink creation time is not a good reason to violate the symlink() API specification. In 'nativestrict' mode, always create native symlinks. Choose the symlink type according to the target if it exists. Otherwise check the target path for a trailing '/' as hint to create a directory symlink. This allows callers to explicitly specify the expected target type, e.g.: $ ln -s test/ link-to-test $ mkdir test Signed-off-by: Karsten Blees <[email protected]>
dscho
added a commit
that referenced
this pull request
May 21, 2015
Allow native symlinks to non-existing targets in 'nativestrict' mode
Thank you very much! |
dscho
added a commit
that referenced
this pull request
May 24, 2015
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Jun 28, 2015
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Aug 28, 2015
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Sep 16, 2015
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Nov 25, 2015
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Nov 27, 2015
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Jan 7, 2016
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 15, 2016
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 18, 2016
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Mar 14, 2016
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Mar 20, 2016
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Apr 5, 2016
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Apr 5, 2016
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Sep 9, 2016
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 6, 2017
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Feb 14, 2017
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Mar 21, 2017
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Apr 2, 2017
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
May 19, 2017
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jul 3, 2017
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Jul 12, 2017
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Sep 7, 2017
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Feb 12, 2018
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Nov 9, 2018
Allow native symlinks to non-existing targets in 'nativestrict' mode
git-for-windows-ci
pushed a commit
that referenced
this pull request
Jul 9, 2020
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Aug 14, 2020
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
Aug 24, 2020
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Mar 30, 2021
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Apr 8, 2021
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Nov 11, 2021
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Dec 3, 2021
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Feb 1, 2022
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
May 3, 2022
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
May 6, 2022
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
May 8, 2022
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
that referenced
this pull request
May 8, 2022
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
May 13, 2022
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Sep 5, 2022
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
May 12, 2023
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jun 16, 2023
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jun 19, 2023
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Sep 6, 2023
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Nov 29, 2023
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
pushed a commit
to dscho/msys2-runtime
that referenced
this pull request
Feb 25, 2024
gcc-14 will default to c99 and as a result a fair amount of old code in newlib (particularly libgloss) is failing to build. I don't offhand know how many patches will be necessary to fix the various failures. I'll just pick them off one by one from my tree. This particular patch works around the return-mismatch problem syscalls.c for fr30. That file is a bit odd in that most functions are declared as returning an integer, but the implementations look like: > int > _read (file, ptr, len) > int file; > char * ptr; > int len; > { > asm ("ldi:8 %0, r0" :: "i" (SYS_read) : "r0"); > asm ("int git-for-windows#10"); > > return; > } Note the lack of a value on the "return" statement. The assumption is that the interrupt handler implementing syscalls will put the return value into the proper register, so falling off the end of the C function or returning with no value works in the expected way. It's not good code, but it probably works. Working from that assumption I decided to just use a pragma to disable the upgraded diagnostic from GCC -- essentially preserving existing behavior. This is the only fr30 specific issue that needs to be resolved and the only issue (so far) I've seen of this specific nature.
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Aug 30, 2024
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Sep 5, 2024
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Sep 18, 2024
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Dec 24, 2024
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 26, 2025
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 26, 2025
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 26, 2025
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 27, 2025
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 28, 2025
Allow native symlinks to non-existing targets in 'nativestrict' mode
dscho
added a commit
to dscho/msys2-runtime
that referenced
this pull request
Jan 30, 2025
Allow native symlinks to non-existing targets in 'nativestrict' mode
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Prerequisite for issue git-for-windows/git#117
Required to run the test suite with prereq SYMLINKS (with
export MSYS=winsymlinks:nativestrict
).