This is the mail archive of the cygwin-developers 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: 1.7.2?


On 3/2/2010 12:52 PM, Corinna Vinschen wrote:
> On Mar  2 15:35, Christopher Faylor wrote:
>> On Tue, Mar 02, 2010 at 09:32:56PM +0100, Corinna Vinschen wrote:
>>> On Mar  2 15:17, Christopher Faylor wrote:
>>>> On Tue, Mar 02, 2010 at 01:12:47PM -0700, Eric Blake wrote:
>>>>> According to Corinna Vinschen on 3/2/2010 12:41 PM:
>>>>>>>> should create "bar.exe" only if "foo" really resolved to "foo.exe" to
>>>>>>>> begin with?  In other words, what is the use case where someone wants
>>>>>>>> "foo" to become "bar.exe", but "foo.exe" did not exist, and they called
>>>>>>>> rename("foo","bar") instead of rename("foo","bar.exe")?
>>>>>>>
>>>>>>> I thought the idea is that bar becomes bar.exe if we know that foo is
>>>>>>> really a PE-COFF binary.
>>>>>>
>>>>>> That's what `strip foo' does.  It creates a temp file, writes the
>>>>>> stripped content of the executable into the temp file, removes the
>>>>>> original and then calls rename(temp_filename, "foo").  That's the
>>>>>> most common situation which (well...) requires to append the .exe
>>>>>> suffix automatically.
>>>>>
>>>>> Would it be easier to teach strip to always append .exe, seeing as how
>>>>> that is a program that KNOWS it will be dealing with PE-COFF files?
>>>>
>>>> Sure, if we decided that this was the best way to handle this.
>>>
>>> IIUC the idea is to drop the entire .exe appending from rename, right?
>>>
>>> If so, we have to do all that .exe magic in mv(1) again, too.
>>>
>>> There's also install(1) which just "forgets" to append a .exe to
>>> installed executables if the -s option isn't given.  I think this is
>>> because install just copies and only the integrated strip call performs
>>> the rename which automagically appends the .exe suffix.  It would be
>>> nice if that could be fixed somehow as well, while we're at it.
>>
>> Right.
>>
>> So, the question is which approach solves the most problems?  It sounds
>> to me like maybe subversion is the exception rather than the rule here
>> but I could be wrong.
> 
> If I could just answer the question...  Honestly, I don't know.  I never
> had problems with the rename() function but maybe this only shows in
> which limited scenarios that function is used in my daily work.
> 
> So, maybe we should just add an cygwin_internal hook for now which allows
> to disable .exe appending?

Just a quick comment here. svn uses libapr1 to do the renaming, so I'd
probably use the cygwin_internal hook in libapr1 instead of just svn,
unless there were some major objections.

-- 
David Rothenberger  ----  daveroth@acm.org

How many Bavarian Illuminati does it take to screw in a lightbulb?

Three: one to screw it in, and one to confuse the issue.


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