delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2020/08/23/19:27:06

X-Recipient: archive-cygwin AT delorie DOT com
X-Original-To: cygwin AT cygwin DOT com
Delivered-To: cygwin AT cygwin DOT com
DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org A47173858D37
Authentication-Results: sourceware.org; dmarc=none (p=none dis=none)
header.from=SystematicSw.ab.ca
Authentication-Results: sourceware.org;
spf=none smtp.mailfrom=brian DOT inglis AT systematicsw DOT ab DOT ca
X-Authority-Analysis: v=2.3 cv=fZA2N3YF c=1 sm=1 tr=0
a=kiZT5GMN3KAWqtYcXc+/4Q==:117 a=kiZT5GMN3KAWqtYcXc+/4Q==:17
a=IkcTkHD0fZMA:10 a=w_pzkKWiAAAA:8 a=rbJLjxrgrjFch_WrZYoA:9 a=QEXdDO2ut3YA:10
a=Lz48L_9qCwoA:10 a=sRI3_1zDfAgwuvI8zelB:22
Subject: Re: Download source for cygwin.dll?
To: cygwin AT cygwin DOT com
References: <c86f8d76-f7ab-b102-600b-4e20fdd902b1 AT gmx DOT com>
<125d59e1-6bb1-756c-fd4b-4894127d2f3f AT gmx DOT com>
<311fbf20-4642-e0d9-d104-e470d714b6e4 AT SystematicSw DOT ab DOT ca>
From: Brian Inglis <Brian DOT Inglis AT SystematicSw DOT ab DOT ca>
Autocrypt: addr=Brian DOT Inglis AT SystematicSw DOT ab DOT ca; prefer-encrypt=mutual;
keydata=
mDMEXopx8xYJKwYBBAHaRw8BAQdAnCK0qv/xwUCCZQoA9BHRYpstERrspfT0NkUWQVuoePa0
LkJyaWFuIEluZ2xpcyA8QnJpYW4uSW5nbGlzQFN5c3RlbWF0aWNTdy5hYi5jYT6IlgQTFggA
PhYhBMM5/lbU970GBS2bZB62lxu92I8YBQJeinHzAhsDBQkJZgGABQsJCAcCBhUKCQgLAgQW
AgMBAh4BAheAAAoJEB62lxu92I8Y0ioBAI8xrggNxziAVmr+Xm6nnyjoujMqWcq3oEhlYGAO
WacZAQDFtdDx2koSVSoOmfaOyRTbIWSf9/Cjai29060fsmdsDLg4BF6KcfMSCisGAQQBl1UB
BQEBB0Awv8kHI2PaEgViDqzbnoe8B9KMHoBZLS92HdC7ZPh8HQMBCAeIfgQYFggAJhYhBMM5
/lbU970GBS2bZB62lxu92I8YBQJeinHzAhsMBQkJZgGAAAoJEB62lxu92I8YZwUBAJw/74rF
IyaSsGI7ewCdCy88Lce/kdwX7zGwid+f8NZ3AQC/ezTFFi5obXnyMxZJN464nPXiggtT9gN5
RSyTY8X+AQ==
Organization: Systematic Software
Message-ID: <9bfea3a3-4457-b04f-328c-ac5f20021d80@SystematicSw.ab.ca>
Date: Sun, 23 Aug 2020 17:26:14 -0600
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101
Thunderbird/68.11.0
MIME-Version: 1.0
In-Reply-To: <311fbf20-4642-e0d9-d104-e470d714b6e4@SystematicSw.ab.ca>
X-CMAE-Envelope: MS4wfJIu1jHe8wvk/YU8BvhoKcfLPJhbW45PrgmK8H8H0Z7tqxV7Be7t370x4j6LYyY+YP+d2QpFVGyQ3QQv2sJdf9t/irMMuUxCIGg7br7O9t+hI+5fx8Ty
tQSRRetGk18CnJoJ2cpKKuNgIJxMmP7MKSu/LFApG4QLBV6sjCN81G4ImwOefr6qQzuQGM6TaJPX6A==
X-Spam-Status: No, score=-8.0 required=5.0 tests=BAYES_00, KAM_DMARC_STATUS,
KAM_LAZY_DOMAIN_SECURITY, NICE_REPLY_A, RCVD_IN_DNSWL_LOW, SPF_HELO_NONE,
SPF_NONE, TXREP autolearn=ham autolearn_force=no version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on
server2.sourceware.org
X-BeenThere: cygwin AT cygwin DOT com
X-Mailman-Version: 2.1.29
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>
List-Unsubscribe: <https://cygwin.com/mailman/options/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=unsubscribe>
List-Archive: <https://cygwin.com/pipermail/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-request AT cygwin DOT com?subject=help>
List-Subscribe: <https://cygwin.com/mailman/listinfo/cygwin>,
<mailto:cygwin-request AT cygwin DOT com?subject=subscribe>
Reply-To: cygwin AT cygwin DOT com
Errors-To: cygwin-bounces AT cygwin DOT com
Sender: "Cygwin" <cygwin-bounces AT cygwin DOT com>

On 2020-08-22 15:31, Brian Inglis wrote:
> On 2020-08-22 14:52, The Tick wrote:
>> On 8/22/2020 3:43 PM, The Tick wrote:
>>> I've been trying to find out how 'ls -l' returns the target of a symlink
>>> on windows:
>>>
>>> $ ls -l
>>> lrwxrwxrwx 1 user None     1 Aug 22 15:16 a -> b
>>> lrwxrwxrwx 1 user None     5 Aug 22 15:16 b -> final
>>> -rw-r--r-- 1 user None    29 Aug 22 15:16 final
> 
> First, read the docs, padawan, to understand the concepts and use, then the
> sources:
> 
> https://cygwin.com/cygwin-ug-net/using.html#pathnames-symlinks
> 
>>> My google searches have pointed me to the windows
>>> GetFinalPathNameByHandle() function but that does get me the
>>> intermediate links -- just the final path (which, of course, is what is
>>> implied by the name of the library call).
>>>
>>> I'm running Msys2 on win7x64. I've looked thru the coreutils for msys2
>>> and cannot find how it is done. That lead me to cygwin coreutils and,
>>> again, there does not seem to be anything specific there. Both rely on a
>>> working lstat().
>>>
>>> This leads me to believe that the guts of the lstat() for windows is
>>> implemented in the cygwin.dll.
> 
>> Sorry, I meant readlink()
> 
>>> I'm sure this is a no-brainer for those in the know, but could someone
>>> point me to where I could download the source for the cygwin dll so I
>>> could examine it? Thank you.
> 
> Check on the Cygwin home page left nav bar Contributing page link and the links
> under those.
> 
> All Windows interfaces are implemented in the DLL, which also includes those
> parts of libc which use Windows interfaces, but the non-Windows and libc
> interfaces are mainly in newlib; all available online via git:
> 
> https://cygwin.com/git?p=newlib-cygwin.git;a=blob;f=winsup/utils/path.cc#l184

Sorry wrong path.cc and readlink function link^, correct link:

https://cygwin.com/git/?p=newlib-cygwin.git;a=blob;f=winsup/cygwin/path.cc#l3405

> and the git clone URLs are on the summary page:
> 
> https://cygwin.com/git/?p=newlib-cygwin.git;a=summary
> 
> All the core Cygwin components, apps, docs, and the web site itself, are also
> available under that git subsite.
> 
> You can also run the Cygwin Setup program (see home page) to download the cygwin
> source package by checking the Src [X] checkbox beside the cygwin package name.

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
[Data in IEC units and prefixes, physical quantities in SI.]
--
Problem reports:      https://cygwin.com/problems.html
FAQ:                  https://cygwin.com/faq/
Documentation:        https://cygwin.com/docs.html
Unsubscribe info:     https://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019