[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [cdt-dev] extending the toolchain

Hi Thomas,

The first part of your message looks like a bug.  Would you create a
bugzilla entry?  Please raise the priority to "major" if you would like
to see it addressed in 3.0 - the MBS has a lot of bugzillas and they
won't all get addressed in 3.0.

The second part of your question also looks like a bug, but I think we
will be addressing it in our 3.0 work.  The MBS currently has a lot of
special case code around the handling of the linker/librarian step.  I
will be posting a "Multiple Inputs & Outputs" design soon that I think
will address your problem in 3.0.  Please review it when it appears.

Thanks,
Leo

-----Original Message-----
From: cdt-dev-admin@xxxxxxxxxxx [mailto:cdt-dev-admin@xxxxxxxxxxx] On
Behalf Of thomas strehl
Sent: Tuesday, March 08, 2005 1:01 PM
To: cdt-dev@xxxxxxxxxxx
Subject: [cdt-dev] extending the toolchain

Hi,

I extended the toolchain and added my own tool. The tool is called
properly when building a project, so this works. However, I run into
quite some trouble when the target of the makefile is build. The rule
there says that it should simply add all objects. Nothing wrong with
that, but objects generated with my tool are not recognized properly.
The problem is that my tool generates a file with a prefix (output
prefix). However, the objects pulled in the target rule do not reflect
this prefix.

If I have a source file "foo.b", my tool generates "prefix_foo.u". I.e.
that the target step tries to pull in "foo.u" which does of course not
exists.

The stuff which breaks it is in GnuMakefileGenerator. You generate a
rule:

 * Create the pattern rule in the format:
 * <relative_path>/%.<outputExtension>:
$(ROOT)/<relative_path>/%.<inputExtension>

instead it should be:
 * <relative_path>/<outputPrefix>%.<outputExtension>:
$(ROOT)/<relative_path>/%.<inputExtension>

So, in the objects.mk file we should get something like:

OBJS := ... $(B_SRCS:$(ROOT)/%.b=prefix_%.u)

and in the subdir.mk file:

prefix_%.u: $(ROOT)/%.b
	@echo 'Building file: $<'
         ....


Another question: Is it possible to add a tool/compiler which generates
something which should not be linked to the target, because the compiler
does not generate any object code?



Kind regards,

Thomas



______________________________________________________________
Verschicken Sie romantische, coole und witzige Bilder per SMS!
Jetzt bei WEB.DE FreeMail: http://f.web.de/?mc=021193

_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/cdt-dev