Boost logo

Boost-Build :

From: muchacho_30 (aachkar_at_[hidden])
Date: 2004-12-14 15:15:16


Thank you Vladimir,

This was quite helpful. I was finding it difficult to interpret the
error messages with the {} and % syntax, but I think I understand them
better now.

v2 was correctly reporting that I have 2 generators generating the
same file (main.lis) which was my mistake. Only the compiler
generates a .lis file but the linker generates a .lst file.

I don't know how to read/post this group using NNTP. Does it exist?
What is the NNTP address?

I am currently using the Yahoo web interface which does not allow me
to send attachments. I would love to use my news reader to read/post
messages if you can tell me how.

Finally, I did not mean to have you only send replies to me without
posting them here. I have no problem with replies being posted here,
as long as it's ok to cc my other address. This way I can get
notified as soon as an answer is posted.

I understand that this is a community effort and I definitely
encourage sharing questions & replies with all the community.

Thanks again!
Alain.

--- In jamboost_at_[hidden], Vladimir Prus <ghost_at_c...> wrote:
> On Friday 10 December 2004 02:32, muchacho_30 wrote:
>
> Hi Alain,
>
> > error: Duplicate name of actual target:
> > <p../../../generic/apps/rf/bin/icc/debug/link-static>main.lis
> > error: previous virtual target { icc%icc.link-main.LIS {
> > icc%icc.compile.c-vectors.OBJ { vectors.C } } {
> .......
> > error: created from ../../../generic/apps/rf/Jamfile:93
> > error: another virtual target { icc%icc.compile.c-main.LIS {
main.C } }
> > error: created from ../../../generic/apps/rf/Jamfile:93
> > error: added properties: none
> > error: removed properties: <find-static-library>os&&c12&&c12p
>
> The message says there's a conflict between two targets. Both are
named "main"
> and have type "LIS", but one is created from main.C by compiling and
another
> is created from many object files by linking.
>
> > ### Target Binary File ###
>
> FWIW, it's much more convenient if you sent testcases as archive,
that I can
> unpack in no time.
>
> > exe main : # Sources
> >
> > vectors.c
> > reset.c
> > hook.c
> > cpu_stop.c
> > ../../hc12_e128/sys_timer.c
> > main.c
>
> Here's main.c which causes the problem.
>
> > generators.register-c-compiler icc.compile.c : C : OBJ LIS
> >
> > : <toolset>icc ;
>
> This informs V2 that compiling main.c produces main.obj and main.lis.
>
> > # The librarian needs libraries to start with the prefix 'lib'
> >
> > generators.register-composing icc.archive : OBJ :
> > STATIC_LIB(lib%) : <toolset>icc ;
> >
> > generators.register-linker icc.link : LIB OBJ : EXE LIS DBG
> > LST MAP MP : <toolset>icc ;
>
> This says that when linking main.EXE the linker also produces main.lis.
>
> I believe that V2 correctly informs you that a file with the same
name will be
> created twice -- during compiling main.c and during linking main.exe.
>
> If you can convince either linker or compiler to use a different
name for LIS
> file, you can use the same trick that you are using for icc.archive:
>
> generators.register-linker icc.link : LIB OBJ : EXE
LIS(link%) DBG
> LST MAP MP : <toolset>icc ;
>
> would tell V2 that the name of lis file has "link" prepended. If you
can't
> change the name, you can either:
>
> - avoid using the same name for main target and a source file
> - don't tell V2 that LIS file is created. That however, will mean that
> main.lis is silently overwritten by the linker and won't be deleted
during
> "bjam clean".
>
> You choose ;-)
>
> > Please reply to:
> >
> > js at simplytech dot com
>
> I cc this address, but please not that we strongly prefer to keep
all general
> discussion on this list. Discussion on list will help other users,
and it can
> be considered a non-monetary price for using Boost.Build ;-)
>
> Especially given NNTP interface, reading the list is not that hard.
>
> - Volodya

 


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk