This is the mail archive of the cygwin 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: May g++ output windows-style paths instead of cygwin-style one?


Brian Dessent wrote:
Angel Tsankov wrote:

Is there any way I can force the cygwin build of g++ to output folders
using windows style (e.g. c:\folder\file) instead of cygwin style
(/cygdrive/c/folder/file) when writing dependency files (-MM option)?

No, there's no way to do that.

Actually, there is: if the input path names to gcc/g++ are windows-style, it will happily emit windows-style paths to the -M output:


% gcc -M /cygdrive/c/Shankar/foo.c
foo.o: /cygdrive/c/Shankar/foo.c

% gcc -M c:/Shankar/foo.c
foo.o: c:/Shankar/foo.c

And just to remind the OP: "c:/Shankar" *IS* a windows-style name (the underlying Win32 API happily takes both \ and / as directory separators).

So you just have to define the directories in your Makefile using Windows-style paths, and preferably use "/" to avoid escape-related problems..


-- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/


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