Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [cdt-dev] Re: generateCommandLineInfo()ofIManagedCommandLineGenerator

Delicia,
    I have a couple of questions:
    1. Which version of CDT are you using?  
    2.  Which makefile generator are you using?
 
    I looked into the GNUMakefileGererator, and it does not seem to generate the @echo commands.
 
    If you are using some other generator, it would be trivial to remove the excess lines:
 
Note that
 
target:
    @echo <cmd>
    @<cmd>
 
seems a bit odd anyway.  The gnu generator has
 
target:
    <cmd>
 
Which should work much better for your example.
 
    - Dave
 


From: cdt-dev-bounces@xxxxxxxxxxx [mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Delicia
Sent: Tuesday, September 05, 2006 6:06 AM
To: cdt-dev@xxxxxxxxxxx
Subject: [cdt-dev] Re: generateCommandLineInfo()ofIManagedCommandLineGenerator

Thanks for the suggestion, Wieant!.
For the time being, I'll have to stick to the shell script workaround as I don't have much time.
 
Regards,
Delicia.
------------------------------
Message: 5
Date: Tue, 5 Sep 2006 10:33:22 +0200
From: wieant@xxxxxxxxx (Wieant Nielander)
Subject: Re: [cdt-dev] Re: generateCommandLineInfo() ofIManagedCommandLineGenerator
To: "CDT General developers list." <cdt-dev@xxxxxxxxxxx>
Message-ID: <20060905083322.GA21114@xxxxxxxxx>
Content-Type: text/plain; charset=us-ascii

>     I tried using a semicolon as a command separator, so now my makefile has:
> @echo exe1 $< $(<:.b=.es); sed 's/.type fr/.type f/g' $(<:.b=.es) > $(<:.b=.ei); exe2 -Dopo $(<:.b=.ei) > $(<:.b=.eo); exe3 --binary --pin-info  $@ $(<:.b=.eo)
> @exe1 $< $(<:.b=.es); sed 's/.type fr/.type f/g' $(<:.b=.es) > $(<:.b=.ei); exe2 -Dopo $(<:.b=.ei) > $(<:.b=.eo); exe3 --binary --pin-info  $@ $(<:.b=.eo)
>
> But yet, for the 'echo' part, the semicolon is reached, 'make' knows it's
> the end of that command, and tries to execute the 'sed...' command.
>
> Any other way out?

Another way out could be to use your own makefile generator. This
can be specified in 'buildfileGenerator' attribute of the 'builder'
element. Your makefile generator can be derived from the
GnuMakefileGenerator in the org.eclipse.cdt.managedbuilder.makegen.gnu
package. Please note that this class is not really intended to be
subclassed, we finally ended up with a full copy of it.

> Another related question: Since I have a fixed rule for this tool, how
> can I 'disable/make non-editable' certain fields that I don't want the
> user to modify?

For each option you can specify an 'applicabilityCalculator' attribute. This
class has to implement 'isOptionVisible' and 'isOptionEnabled' methods that
allows you to disable or hide an option.

Regards,
Wieant

Back to the top