public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Re: [mingw32] Re: [RFC] changing gcc default output executable name  (a.exe now)
@ 2000-01-14  9:42 Earnie Boyd
  0 siblings, 0 replies; 12+ messages in thread
From: Earnie Boyd @ 2000-01-14  9:42 UTC (permalink / raw)
  To: cygwin

--- Corinna Vinschen <corinna@vinschen.de> wrote:
> Andre Oliveira da Costa wrote:
> > [...]
> > I don't think tweaking all these applications to look for "foo.exe" if they
> > can't find "foo" would be the right thing. But I would really like to be
> > able to install the applications I compile without having to tweak all the
> > makefiles. Maybe the solution would be not to add the .exe suffix...
> 
> I agree. It would be nice if gcc would not add .exe automatically.
> Maybe it's not a 'modern' solution but it's the way, cc produces
> executables since french revolution:
> 
> 	No output name given: 	a.out is created,
> 	-o foo:			foo is created.
> 
> That's it and it's ok.
> IMHO.
> Corinna
> 

BTW, ld already has a switch named --force-exe-suffix.  Wonder why it's not
supported on Win32?


=====
Earnie Boyd < mailto:earnie_boyd@yahoo.com >
Cygwin Newbies, please visit
< http://www.freeyellow.com/members5/gw32/index.html >
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
  2000-01-13  7:04 TOMMY REYNOLDS
  2000-01-13 10:52 ` Andre Oliveira da Costa
@ 2000-01-15 10:26 ` Terry Lincoln
  1 sibling, 0 replies; 12+ messages in thread
From: Terry Lincoln @ 2000-01-15 10:26 UTC (permalink / raw)
  To: TOMMY REYNOLDS, mingw32, Todd Bandrowsky; +Cc: cygwin

All,

I fully agree with all 4 points.  I also feel it important to this: if we
*really* want another M$-LoseDoze compiler clone, then someone (Mumit
maybe?) can/should submit a "wgcc" variation;  something built from GCC but
does everything the M$-LoseDoze way.  Since it shouldn't then be expected to
be UNIX-y you can change most of the defaults without breaking existing code
that makes assumptions about gcc's workings.

Regards,

----- Original Message -----
From: TOMMY REYNOLDS <tommy.reynolds@adtran.com>
To: <mingw32@egroups.com>; Todd Bandrowsky <tbandrowsky@del.net>
Cc: <cygwin@sourceware.cygnus.com>
Sent: Thursday, January 13, 2000 10:03 AM
Subject: RE: [mingw32] Re: [RFC] changing gcc default output executable name
(a.exe now)


> I'd vote just the opposite: make an "a.out" file in both instances,
because:
> 1) that's what
> UNIX does, it's expected; 2) that's what UNIX does, it's documented; 3)
> typing "a.out"
> under WinDo$e will run the file any - we don' need no steekin' suffixes
> anymore; and 4) it
> doesn't break anything we're trying to port from UNIX anyway..
>
> This is just one more "exactly the same as UNIX but with one subtle
> difference" nuisance.
>
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com
>
>


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
  2000-01-13 10:52 ` Andre Oliveira da Costa
  2000-01-13 11:45   ` Matthew Brown
@ 2000-01-14  9:36   ` Corinna Vinschen
  1 sibling, 0 replies; 12+ messages in thread
From: Corinna Vinschen @ 2000-01-14  9:36 UTC (permalink / raw)
  To: Andre Oliveira da Costa; +Cc: cygwin

Andre Oliveira da Costa wrote:
> [...]
> I don't think tweaking all these applications to look for "foo.exe" if they
> can't find "foo" would be the right thing. But I would really like to be
> able to install the applications I compile without having to tweak all the
> makefiles. Maybe the solution would be not to add the .exe suffix...

I agree. It would be nice if gcc would not add .exe automatically.
Maybe it's not a 'modern' solution but it's the way, cc produces
executables since french revolution:

	No output name given: 	a.out is created,
	-o foo:			foo is created.

That's it and it's ok.
IMHO.
Corinna

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
  2000-01-13 12:31 Earnie Boyd
@ 2000-01-13 12:41 ` Matthew Brown
  0 siblings, 0 replies; 12+ messages in thread
From: Matthew Brown @ 2000-01-13 12:41 UTC (permalink / raw)
  To: earnie_boyd, cygwin

But, of course. Just define EXEEXT to be empty. This is how it works on UNIX flavors.

-- Matthew Brown

----- Original Message ----- 
From: "Earnie Boyd" <earnie_boyd@yahoo.com>
To: "Matthew Brown" <mbrown@mediadb.net>; <cygwin@sourceware.cygnus.com>
Sent: Thursday, January 13, 2000 3:31 PM
Subject: Re: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)


> Matthew,
> 
> Your process would still work if gcc didn't append the .exe to the executable
> name.  You would just do gcc -o myprog$(EXEEXT) instead of gcc -o myprog.
> 
> Earnie.



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
@ 2000-01-13 12:31 Earnie Boyd
  2000-01-13 12:41 ` Matthew Brown
  0 siblings, 1 reply; 12+ messages in thread
From: Earnie Boyd @ 2000-01-13 12:31 UTC (permalink / raw)
  To: Matthew Brown, cygwin

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2811 bytes --]

Matthew,

Your process would still work if gcc didn't append the .exe to the executable
name.  You would just do gcc -o myprog$(EXEEXT) instead of gcc -o myprog.

Earnie.

--- Matthew Brown <mbrown@mediadb.net> wrote:
> The process I (and others that I am familiar with) use is to define macros
> for common file extensions such as: EXEEXT, OBJEXT, and LIBEXT. You can
> conditionally define these in the makefile (or in a makefile that is included
> everywhere) to be the proper values for the target platform.
> 
> Example using gmake syntax:
> ifeq ($(TARGET_OS), win32)
>   EXEEXT=.exe
>   OBJEXT=.obj
>   LIBEXT=.lib
> else
>   ifeq ($(TARGET_OS), cygwin)
>     EXEEXT=.exe
>     OBJEXT=.o
>     LIBEXT=.a
>   else
>     EXEEXT=
>     OBJEXT=.o
>     LIBEXT=.a
>   endif
> endif
> 
> Then when you define your targets:
> foo$(EXEEXT) :
> 
> -- Matthew Brown
> 
> ----- Original Message ----- 
> From: "Andre Oliveira da Costa" <costa@cade.com.br>
> To: <cygwin@sourceware.cygnus.com>
> Sent: Thursday, January 13, 2000 1:44 PM
> Subject: RE: [mingw32] Re: [RFC] changing gcc default output executable name
> (a.exe now)
> 
> 
> > I'd like to ask for comments on another issue related to portability from
> > UNIX --> cygwin, compilation etc.: the way it is now, the linker
> > automagically appends a .exe suffix to the executable filename. If you do
> > 
> > gcc -o foo foo.o
> > 
> > ld will create foo.exe . I wouldn't complain about it except for the fact
> > that this imposes a serious restriction to portability. For example,
> usually
> > when I try to install a just-compiled application through "make install",
> > all the cp, mv, chmod, strip and install rules refer to "foo" and not
> > "foo.exe", and therefore they (rightfully) complain about missing files.
> So,
> > even if the compilation goes out well,  there's always some makefile
> > tweaking involved.
> > 
> > I don't think tweaking all these applications to look for "foo.exe" if they
> > can't find "foo" would be the right thing. But I would really like to be
> > able to install the applications I compile without having to tweak all the
> > makefiles. Maybe the solution would be not to add the .exe suffix...
> > 
> > Am I missing something or is this a real problem?
> > 
> > Andre
> > --
> > André Oliveira da Costa
> > (costa@cade.com.br)
> > 
> > 
> > --
> > Want to unsubscribe from this list?
> > Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> > 
> > 
> 
> 
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> 
> 
__________________________________________________
Do You Yahoo!?
Talk to your friends online with Yahoo! Messenger.
http://im.yahoo.com

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
  2000-01-13 11:45   ` Matthew Brown
@ 2000-01-13 11:59     ` Andre Oliveira da Costa
  0 siblings, 0 replies; 12+ messages in thread
From: Andre Oliveira da Costa @ 2000-01-13 11:59 UTC (permalink / raw)
  To: Matthew Brown, cygwin

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 857 bytes --]

> The process I (and others that I am familiar with) use is to
> define macros for common file extensions such as: EXEEXT, OBJEXT,
> and LIBEXT. You can conditionally define these in the makefile
> (or in a makefile that is included everywhere) to be the proper
> values for the target platform.
[...]

What I do when I have to tweak a makefile is pretty close to what you
described -- except for the fact that I didn't put things in a separate
makefile to be included everywhere, which is definitely a GoodThing(TM). I
just started this thread to see if there was an alternative which didn't
imply in tweaking the makefiles (e.g. an environment variable).

Thanks for your attention.

Best regards,

Andre
--
André Oliveira da Costa
(costa@cade.com.br)


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
  2000-01-13 10:52 ` Andre Oliveira da Costa
@ 2000-01-13 11:45   ` Matthew Brown
  2000-01-13 11:59     ` Andre Oliveira da Costa
  2000-01-14  9:36   ` Corinna Vinschen
  1 sibling, 1 reply; 12+ messages in thread
From: Matthew Brown @ 2000-01-13 11:45 UTC (permalink / raw)
  To: Andre Oliveira da Costa, cygwin

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 2203 bytes --]

The process I (and others that I am familiar with) use is to define macros for common file extensions such as: EXEEXT, OBJEXT, and LIBEXT. You can conditionally define these in the makefile (or in a makefile that is included everywhere) to be the proper values for the target platform.

Example using gmake syntax:
ifeq ($(TARGET_OS), win32)
  EXEEXT=.exe
  OBJEXT=.obj
  LIBEXT=.lib
else
  ifeq ($(TARGET_OS), cygwin)
    EXEEXT=.exe
    OBJEXT=.o
    LIBEXT=.a
  else
    EXEEXT=
    OBJEXT=.o
    LIBEXT=.a
  endif
endif

Then when you define your targets:
foo$(EXEEXT) :

-- Matthew Brown

----- Original Message ----- 
From: "Andre Oliveira da Costa" <costa@cade.com.br>
To: <cygwin@sourceware.cygnus.com>
Sent: Thursday, January 13, 2000 1:44 PM
Subject: RE: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)


> I'd like to ask for comments on another issue related to portability from
> UNIX --> cygwin, compilation etc.: the way it is now, the linker
> automagically appends a .exe suffix to the executable filename. If you do
> 
> gcc -o foo foo.o
> 
> ld will create foo.exe . I wouldn't complain about it except for the fact
> that this imposes a serious restriction to portability. For example, usually
> when I try to install a just-compiled application through "make install",
> all the cp, mv, chmod, strip and install rules refer to "foo" and not
> "foo.exe", and therefore they (rightfully) complain about missing files. So,
> even if the compilation goes out well,  there's always some makefile
> tweaking involved.
> 
> I don't think tweaking all these applications to look for "foo.exe" if they
> can't find "foo" would be the right thing. But I would really like to be
> able to install the applications I compile without having to tweak all the
> makefiles. Maybe the solution would be not to add the .exe suffix...
> 
> Am I missing something or is this a real problem?
> 
> Andre
> --
> André Oliveira da Costa
> (costa@cade.com.br)
> 
> 
> --
> Want to unsubscribe from this list?
> Send a message to cygwin-unsubscribe@sourceware.cygnus.com
> 
> 


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
  2000-01-13  7:04 TOMMY REYNOLDS
@ 2000-01-13 10:52 ` Andre Oliveira da Costa
  2000-01-13 11:45   ` Matthew Brown
  2000-01-14  9:36   ` Corinna Vinschen
  2000-01-15 10:26 ` Terry Lincoln
  1 sibling, 2 replies; 12+ messages in thread
From: Andre Oliveira da Costa @ 2000-01-13 10:52 UTC (permalink / raw)
  To: cygwin

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1194 bytes --]

I'd like to ask for comments on another issue related to portability from
UNIX --> cygwin, compilation etc.: the way it is now, the linker
automagically appends a .exe suffix to the executable filename. If you do

gcc -o foo foo.o

ld will create foo.exe . I wouldn't complain about it except for the fact
that this imposes a serious restriction to portability. For example, usually
when I try to install a just-compiled application through "make install",
all the cp, mv, chmod, strip and install rules refer to "foo" and not
"foo.exe", and therefore they (rightfully) complain about missing files. So,
even if the compilation goes out well,  there's always some makefile
tweaking involved.

I don't think tweaking all these applications to look for "foo.exe" if they
can't find "foo" would be the right thing. But I would really like to be
able to install the applications I compile without having to tweak all the
makefiles. Maybe the solution would be not to add the .exe suffix...

Am I missing something or is this a real problem?

Andre
--
André Oliveira da Costa
(costa@cade.com.br)


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
  2000-01-12 21:31 ` Brendan J Simon
  2000-01-13  6:00   ` [mingw32] Re: [RFC] changing gcc default output executable name(a.exe now) Brent Williams
  2000-01-13  6:51   ` [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now) Todd Bandrowsky
@ 2000-01-13 10:26   ` Kai Ruottu
  2 siblings, 0 replies; 12+ messages in thread
From: Kai Ruottu @ 2000-01-13 10:26 UTC (permalink / raw)
  To: mingw32; +Cc: cygwin

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1708 bytes --]

Brendan J Simon wrote:
> 
> Mumit Khan wrote:
> 
> > Are people happy/ok with the fact that gcc on win32 produces a program
> > called a.exe by default? For example,
> >
> >   $ gcc foo.c
> >
> > will create a.exe. This is of course not really expected on DOS/Windows
> > world, and causes all sorts of confusion. Also, this is simply lame even
> > on Unix, and this historical bit should've disappeared long ago, but
> > won't since it's a convention now.
> >
> > I'd like to move to creating <name>.exe, where <name> is the first file
> > on the list you provided to gcc.
> >
> >   $ gcc foo1.c foo2.c foo3.c
> >
> > will produce foo1.exe, not a.exe as it does now.
> >
> > Is this something we should change??
> 
> Yep.  I agree entirely.
> An output of <name> or even <name>.exe would be justified on Unix boxes
> also in my opinion.  I don't know why Unix people still insist on making
> things harder and more cryptic then they have to be.  I think it's an ego
> powertrip thing or something.

 The stuff before the '.exe' may be ok, but the '.exe' isn't. It simply hints
it to be a DOS/Windows/OS/2 executable (VAX/VMS too) :

	E:\usr\local\samples>gcc-linux-gnu -o hello hello.c

	E:\usr\local\samples>dir/o-d/p
	 Volume in drive E is NTFS_3
	 Volume Serial Number is E86F-81C3

	 Directory of E:\usr\local\samples

	13.01.00  20:05                  4 734 hello.exe
	<clip>

Producing something else for other targets than Win32, when using no
extension in 'name' with '-o name', is absolutely wrong...  The '.exe'
should be tied to the Win32-target, not to the Win32-host for GCC...

Cheers, Kai


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
@ 2000-01-13  7:04 TOMMY REYNOLDS
  2000-01-13 10:52 ` Andre Oliveira da Costa
  2000-01-15 10:26 ` Terry Lincoln
  0 siblings, 2 replies; 12+ messages in thread
From: TOMMY REYNOLDS @ 2000-01-13  7:04 UTC (permalink / raw)
  To: mingw32, Todd Bandrowsky; +Cc: cygwin

I'd vote just the opposite: make an "a.out" file in both instances, because:
1) that's what
UNIX does, it's expected; 2) that's what UNIX does, it's documented; 3)
typing "a.out"
under WinDo$e will run the file any - we don' need no steekin' suffixes
anymore; and 4) it
doesn't break anything we're trying to port from UNIX anyway..

This is just one more "exactly the same as UNIX but with one subtle
difference" nuisance.

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now)
  2000-01-12 21:31 ` Brendan J Simon
  2000-01-13  6:00   ` [mingw32] Re: [RFC] changing gcc default output executable name(a.exe now) Brent Williams
@ 2000-01-13  6:51   ` Todd Bandrowsky
  2000-01-13 10:26   ` Kai Ruottu
  2 siblings, 0 replies; 12+ messages in thread
From: Todd Bandrowsky @ 2000-01-13  6:51 UTC (permalink / raw)
  To: mingw32; +Cc: cygwin

I think that a .exe should be created on Windows and a.out created on Unix.


> -----Original Message-----
> From: brendan@k9.prophecy.com.au [ mailto:brendan@k9.prophecy.com.au]On
> Behalf Of Brendan J Simon
> Sent: Wednesday, January 12, 2000 11:33 PM
> Cc: Mingw32 discussion list at eGroups; cygwin@sourceware.cygnus.com
> Subject: [mingw32] Re: [RFC] changing gcc default output executable name
> (a.exe now)
>
>
> Mumit Khan wrote:
>
> > Are people happy/ok with the fact that gcc on win32 produces a program
> > called a.exe by default? For example,
> >
> >   $ gcc foo.c
> >
> > will create a.exe. This is of course not really expected on DOS/Windows
> > world, and causes all sorts of confusion. Also, this is simply lame even
> > on Unix, and this historical bit should've disappeared long ago, but
> > won't since it's a convention now.
> >
> > I'd like to move to creating <name>.exe, where <name> is the first file
> > on the list you provided to gcc.
> >
> >   $ gcc foo1.c foo2.c foo3.c
> >
> > will produce foo1.exe, not a.exe as it does now.
> >
> > Is this something we should change??
>
> Yep.  I agree entirely.
> An output of <name> or even <name>.exe would be justified on Unix boxes
> also in my opinion.  I don't know why Unix people still insist on making
> things harder and more cryptic then they have to be.  I think it's an ego
> powertrip thing or something.
>
> Brendan Simon.
>
>
>
> ------------------------------------------------------------------------
> For the fastest and easiest way to backup your files and, access them from
>
> anywhere. Try @backup Free for 30 days.  Click here for a chance to win a
>
> digital camera.
> http://click.egroups.com/1/337/5/_/13107/_/947766525/
>
> -- Create a poll/survey for your group!
> -- http://www.egroups.com/vote?listname=mingw32&m=1
>
>


--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: [mingw32] Re: [RFC] changing gcc default output executable name(a.exe now)
  2000-01-12 21:31 ` Brendan J Simon
@ 2000-01-13  6:00   ` Brent Williams
  2000-01-13  6:51   ` [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now) Todd Bandrowsky
  2000-01-13 10:26   ` Kai Ruottu
  2 siblings, 0 replies; 12+ messages in thread
From: Brent Williams @ 2000-01-13  6:00 UTC (permalink / raw)
  To: mingw32; +Cc: cygwin

>
>Yep.  I agree entirely.
>An output of <name> or even <name>.exe would be justified on Unix boxes
>also in my opinion.  I don't know why Unix people still insist on making
>things harder and more cryptic then they have to be.  I think it's an ego
>powertrip thing or something.

I think the a.out was a carryover from the original compiler Dennis
Ritchie wrote. Unix is cryptic at first, but once you get used to all
those little commands, you can type faster. Typing 'cp' is a lot faster
than typing 'copy'. It's rumored that Unix was never intended to be used
outside of a lab environment.

As far as cryptic goes, the WinAPI/Registry is about a cryptic as it
gets. (or complicated may be a better word). Probably a result of having
too many hands in the pie.



--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2000-01-15 10:26 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-01-14  9:42 [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now) Earnie Boyd
  -- strict thread matches above, loose matches on Subject: below --
2000-01-13 12:31 Earnie Boyd
2000-01-13 12:41 ` Matthew Brown
2000-01-13  7:04 TOMMY REYNOLDS
2000-01-13 10:52 ` Andre Oliveira da Costa
2000-01-13 11:45   ` Matthew Brown
2000-01-13 11:59     ` Andre Oliveira da Costa
2000-01-14  9:36   ` Corinna Vinschen
2000-01-15 10:26 ` Terry Lincoln
2000-01-12 21:07 Mumit Khan
2000-01-12 21:31 ` Brendan J Simon
2000-01-13  6:00   ` [mingw32] Re: [RFC] changing gcc default output executable name(a.exe now) Brent Williams
2000-01-13  6:51   ` [mingw32] Re: [RFC] changing gcc default output executable name (a.exe now) Todd Bandrowsky
2000-01-13 10:26   ` Kai Ruottu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).