www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/1997/09/12/08:37:39

From: erics AT eastman DOT com (Smith, Eric)
Subject: Native windows binary generation -vs- Unix binary generation
12 Sep 1997 08:37:39 -0700 :
Message-ID: <c=US%a=_%p=Eastman%l=NTD150-970912152848Z-10945.cygnus.gnu-win32@ntd150.kpt.emn.com>
Mime-Version: 1.0
To: "'gnu-win32 AT cygnus DOT com'" <gnu-win32 AT cygnus DOT com>

There has been a lot of arguing on the web recently about the default
behavior of gcc on win32.  Here's my 2 cents.

1. Developers expect tools to work on the platform they are using.
	When working on a platform, every tool you use should work, and
anything you build should work as well.

2. Each platform behaves differently (to varying extents).
	One Unix system (i.e. System V) is not exactly like another (i.e. BSD)
or other flavors (i.e. Linux, AIX, ...)

3. Binaries from one machine/OS (e.g.: Sun/SunOS) won't work on other
machines/OSs (e.g.: HP-UX).
	To get the code to work, you would need to recompile or Cross-Compile.

4. Commands and command lines should be similar.
	To make things easier on developers, commands should be familiar
regardless of the machine you are on.

5. Resulting programs should behave identically.
	Applications developed on one machine should behave the same way when
recompiled on another machine.

6. Subsequent actions should be similar.
	The files necessary for distribution/maintenance/documentation/etc...
should be the same (in number and name)
	from platform to platform.  To move from one platform to another should
not require additional files.  It should 
	require the same files, compiled for the destination platform.

Conclusion: A compiler should generate code native to the machine it is
resident on, using the same command syntax 
		regardless of the host platform.  To generate code usable on platforms
other than the host, the code must 
		be cross-compiled for the target platform.

The development of compilers which work this way may never happen.  Item
6 above is the main stopping point (do we use DLLs or not).  The gnu
compilers are currently very close to behaving this way, and provide
developers a wonderful tool for building applications regardless of
their destination platform.  I personally selected the compiler due to
this capability.

If the capabilities are built into a library instead of a DLL, the
resulting code will increase in size (possibly by a few M), but all
subsequent processing (such as preparing to distribute, and distributing
applications) can be simplified.  

Understandably, standards in both worlds are different (Win32, X, Motif,
etc...) and different tools are not currently portable or ported.  Even
so, I believe the above is important for the future of software
development.

Eric M. Smith
telephone               : (423) 229-2254
profs/officevision     : XGIB003
internet -- business : erics AT eastman DOT com
internet -- personal  : burnsun AT tricon DOT net

Do not meddle in the affairs of wizards, for they are quick to anger.
Do not meddle in the affairs of dragons, for you are crunchy and taste
good with ketchup.

-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request AT cygnus DOT com" with one line of text: "help".

- Raw text -


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