Useful error message and conversion tool when switch from textmode (cygwin) to binmode (MSYS)

RESOLVED FIXED

Status

Firefox Build System
General
RESOLVED FIXED
12 years ago
2 months ago

People

(Reporter: Benjamin Smedberg, Assigned: Benjamin Smedberg)

Tracking

Trunk
x86
Windows XP

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Assignee)

Description

12 years ago
The patch will provide a useful error message when users switch from a textmode source tree (cygwin default) to a binmode tree (MSYS default).
(Assignee)

Comment 1

12 years ago
Created attachment 250201 [details] [diff] [review]
detect problems in client.mk, and add converter script, rev. 1
Assignee: nobody → benjamin
Status: NEW → ASSIGNED
Attachment #250201 - Flags: review?(dbaron)
Comment on attachment 250201 [details] [diff] [review]
detect problems in client.mk, and add converter script, rev. 1

r=dbaron, although I can't claim to be much of a python expert, and the perlfunc definition of |binmode| doesn't make much sense to me.

One concern:  should your python script check for the conditions that make it do dos2unix rather than some other behavior?  All it really does is read in as text and write out as binary.
Attachment #250201 - Flags: review?(dbaron) → review+
(Assignee)

Comment 3

12 years ago
Since dos2unix is repeatable, I don't think there's any harm in doing it whenever we encounter a non-textmode file.

Fixed on trunk.
Status: ASSIGNED → RESOLVED
Last Resolved: 12 years ago
Resolution: --- → FIXED

Comment 4

11 years ago
Comment on attachment 250201 [details] [diff] [review]
detect problems in client.mk, and add converter script, rev. 1

>+print """This command will convert the source tree at
>+%s 
>+to an MSYS-compatible (unix mode) source tree. You can run this
>+command multiple times safely. Are you sure you want to continue (Y/N)? """ % topsrcdir,
Unfortunately you can't run this command even once safely. Excluding binary files, we have 340 files in the tree containing \r\n characters. Of those, 71 either have mixed line endings or should really be binary.

Comment 5

11 years ago
Created attachment 251443 [details]
list of suspect files

Note: this is based on MOZ_CO_MODULES=suite so there may be others.

Updated

2 months ago
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.