Re: Using Makefile rather than GreenHills (GHS) Multi .GPJ files
- From: David Brown <david@xxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 04 Apr 2008 11:14:47 +0200
Hans-Bernhard Bröker wrote:
zzmcclos@xxxxxxxxx wrote:Anyone using Make rather than gbuild/Multi? If so, have any advise
concerning doing this?
From second-hand experience I can say Green Hills' compilers don't need any special treatment by Makefiles. I.e. if you know your way around Make, there's nothing special to learn about using it with GHS. GHS even exports dependency information in a suitable format.
The trickiest aspect may be the selection of a Make tool that works well in a MS Windows surrounding, where people habitually don't care about letter case in filenames. Cygwin's port of GNU make is the usual choice, but for this application it may not be the optimal one.
The "msys" *nix tools, such as make, are often a better choice than cygwin unless you really need a full posix environment. MSys/Mingw binaries are smaller, faster, more "native" (they handle things like incorrect case better), and don't have the dreaded "cygwin1.dll" problems. On the other hand, cygwin supports things like fork(), symbolic links, and a much more complete set of tools and libraries.
Note also that Green Hill's is, I believe, a bit fussy about letter cases - they changed the ordering of files between versions (i.e., does "a" come before or after "Z" ?) which affected link ordering for a user I know.
Finally, a good idea with makefiles is to write generalised makefiles that compile *all* the ".c" files in your working directory, rather than trying to specify them individually. With a little effort you can write a makefile that will work for many different projects, and does not need updating when you add new source files or change dependant headers.
.
- Follow-Ups:
- Re: Using Makefile rather than GreenHills (GHS) Multi .GPJ files
- From: Hans-Bernhard Bröker
- Re: Using Makefile rather than GreenHills (GHS) Multi .GPJ files
- References:
- Using Makefile rather than GreenHills (GHS) Multi .GPJ files
- From: zzmcclos@xxxxxxxxx
- Re: Using Makefile rather than GreenHills (GHS) Multi .GPJ files
- From: Hans-Bernhard Bröker
- Using Makefile rather than GreenHills (GHS) Multi .GPJ files
- Prev by Date: Re: Linux serial port dropping bytes
- Next by Date: Re: How to tell how fast a car is going?
- Previous by thread: Re: Using Makefile rather than GreenHills (GHS) Multi .GPJ files
- Next by thread: Re: Using Makefile rather than GreenHills (GHS) Multi .GPJ files
- Index(es):