EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

Does IAR Embedded Workbench IDE Support Command-Line Compile ?

Started by Steven Woody January 6, 2006
Hi,

we have a IAR EWB C/C++ IDE.  i want to know if the product support
command line compile a c project? and, does it support something like
compile using Makefile ?

thanks.

-
woody

"Steven Woody" <narkewoody@gmail.com> wrote in message
news:1136534155.877403.222760@f14g2000cwb.googlegroups.com...
> Hi, > > we have a IAR EWB C/C++ IDE. i want to know if the product support > command line compile a c project? and, does it support something like > compile using Makefile ? >
Opening a command prompt, going to the IAR bin directory and typing "iccarm" I get a whole lot of command line options. Creating a simple C file and typing "iccarm main.c" I get some output - so the answer appears to be Yes. Maybe it would have been quicker for you to try this yourself than write your post? Regards, Richard. http://www.FreeRTOS.org
Steven Woody wrote:
> > we have a IAR EWB C/C++ IDE. i want to know if the product > support command line compile a c project? and, does it support > something like compile using Makefile ?
Any compiler for any language on any system supports using a makefile. If the compiler doesn't return success/failure status the interaction with the make program will not be good. You need only read the documentation of your make program. -- Some informative links: news:news.announce.newusers http://www.geocities.com/nnqweb/ http://www.catb.org/~esr/faqs/smart-questions.html http://www.caliburn.nl/topposting.html http://www.netmeister.org/news/learn2quote.html
Chuck F.  wrote:

> Any compiler for any language on any system supports using a > makefile. If the compiler doesn't return success/failure status
Not if it's a Windows IDE which requires GUI interaction to perform the compile operation.
On 6 Jan 2006 04:58:21 -0800 in comp.arch.embedded, "larwe"
<zwsdotcom@gmail.com> wrote:

> >Chuck F. wrote: > >> Any compiler for any language on any system supports using a >> makefile. If the compiler doesn't return success/failure status > >Not if it's a Windows IDE which requires GUI interaction to perform the >compile operation.
I haven't seen Chuck's post on my newsreader yet, but as an example... CodeVisionAVR, a C compiler targeting Atmel AVR microcontrollers most emphatically does not support usage by make. You load all your C files into a "project" in the GUI, and hit the "build" button. Every C file is compiled every time. Rather than object files, a big honkin ASM file is generated and passed to an assembler. The application is "linked" at the ASM level. There is _no_ command line interface whatsoever. Many users have been begging for one for some time, but the architecture of the system apparently makes this difficult. Even if there was, it would probably take the form of "build the project" rather than "compile the file." Regards, -=Dave -- Change is inevitable, progress is not.
larwe wrote:
> Chuck F. wrote: > >> Any compiler for any language on any system supports using a >> makefile. If the compiler doesn't return success/failure >> status > > Not if it's a Windows IDE which requires GUI interaction to > perform the compile operation. >
Even there. There is an underlying set of command line driven programs, including the compiler and linker. I am thinking of Microsofts own stuff (Visual Studio etc.) here. I doubt that anybody elses stuff is fundamentally different. -- "If you want to post a followup via groups.google.com, don't use the broken "Reply" link at the bottom of the article. Click on "show options" at the top of the article, then click on the "Reply" at the bottom of the article headers." - Keith Thompson More details at: <http://cfaj.freeshell.org/google/>
Dave Hansen wrote:
> "larwe" <zwsdotcom@gmail.com> wrote: >> Chuck F. wrote: >> >>> Any compiler for any language on any system supports using a >>> makefile. If the compiler doesn't return success/failure >> >> Not if it's a Windows IDE which requires GUI interaction to >> perform the compile operation. > > I haven't seen Chuck's post on my newsreader yet, but as an > example... > > CodeVisionAVR, a C compiler targeting Atmel AVR microcontrollers > most emphatically does not support usage by make. You load all > your C files into a "project" in the GUI, and hit the "build" > button. Every C file is compiled every time. Rather than > object files, a big honkin ASM file is generated and passed to > an assembler. The application is "linked" at the ASM level. > > There is _no_ command line interface whatsoever. Many users > have been begging for one for some time, but the architecture of > the system apparently makes this difficult. Even if there was, > it would probably take the form of "build the project" rather > than "compile the file."
Hmm - ridiculous. I guess I stand corrected. Don't buy such silly systems. -- "If you want to post a followup via groups.google.com, don't use the broken "Reply" link at the bottom of the article. Click on "show options" at the top of the article, then click on the "Reply" at the bottom of the article headers." - Keith Thompson More details at: <http://cfaj.freeshell.org/google/>
Chuck F.  wrote:


> > Not if it's a Windows IDE which requires GUI interaction to > > perform the compile operation. > > > Even there. There is an underlying set of command line driven > programs, including the compiler and linker. I am thinking of
Like I said: "not if it's a Windows IDE which requires GUI interaction". If an IDE simply calls external command-line programs, then good - but there are unfortunately some that are totally "integrated" in the real monolithic single-executable sense of the word.
Chuck F.  wrote:
> Steven Woody wrote: > > > > we have a IAR EWB C/C++ IDE. i want to know if the product > > support command line compile a c project? and, does it support > > something like compile using Makefile ? > > Any compiler for any language on any system supports using a > makefile. If the compiler doesn't return success/failure status > the interaction with the make program will not be good. You need > only read the documentation of your make program. >
i believe it is right in theory. but finding out how to properly pass many options to compiler and linker without a simple example is very hard as i think. especiall, beside the object files, IAR's linker has a command file as it's parameter, i don't know how to use or generate it. so i like to know, is there anyone successfully do a Makefile for a IAR embeded project ? if so, i just want an example. thanks. - woody
Steven Woody wrote:

> so i like to know, is there anyone successfully do a Makefile for a IAR > embeded project ? if so, i just want an example. thanks.
By the way - just so you know, the answer to this is yes - we have built MSP430 and NEC 78K0 projects with makefiles using MAKE from the free command-line edition of Borland C++ 5.5. I can't pull the files to tell you how it was done, but this is more to tell you that it IS possible (note that these were old versions of IAR). Note that we despise IAR and have successfully migrated away from them.

The 2024 Embedded Online Conference