471,349 Members | 1,247 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,349 software developers and data experts.

Strong name assignment to a circular reference

How can I compile two projects with a circular reference while giving them a
strong name?

There is a project that we have that has two components that reference each
other e.g. A<->B thus creating A.dll and B.dll. I have a project (e.g. R
with an assembly name of Com.MyCompany.R.dll) that has to use this mess and
access A. So, R->A. Well, Com.MyCompany.R.dll is going in the GAC. It is
set for strong name (entry in the assembly pointing to my sn.exe -k
generated file). However, projects A and B are not strong named, thus R
won't compile until A and B are strong named.

So, I have given them a strong assembly name (e.g. Com.MyCompany.A.dll and
Com.MyCompany.B.dll). I have added the assembly reference to the key file,
and generated an sn.exe -k key for each, also. However, neither A nor B
will compile since each depend on the other to be already compiled with a
strong name. Other than commenting out all the references to each other (if
that would even work), what might I do to get R in the GAC?

Any help would be greatly appreciated.

Thanks,

-John
Jul 21 '05 #1
2 1755
Unwind the circular reference.

Your post inspired a blog entry... see the solution at the link below:
http://blogs.msdn.com/nickmalik/arch...18/398601.aspx

Hope this helps,

--
--- Nick Malik [Microsoft]
MCSD, CFPS, Certified Scrummaster
http://blogs.msdn.com/nickmalik

Disclaimer: Opinions expressed in this forum are my own, and not
representative of my employer.
I do not answer questions on behalf of my employer. I'm just a
programmer helping programmers.
--
"John E." <PleaseReply@usenet> wrote in message
news:eQ**************@TK2MSFTNGP09.phx.gbl...
How can I compile two projects with a circular reference while giving them
a
strong name?

There is a project that we have that has two components that reference
each
other e.g. A<->B thus creating A.dll and B.dll. I have a project (e.g. R
with an assembly name of Com.MyCompany.R.dll) that has to use this mess
and
access A. So, R->A. Well, Com.MyCompany.R.dll is going in the GAC. It
is
set for strong name (entry in the assembly pointing to my sn.exe -k
generated file). However, projects A and B are not strong named, thus R
won't compile until A and B are strong named.

So, I have given them a strong assembly name (e.g. Com.MyCompany.A.dll and
Com.MyCompany.B.dll). I have added the assembly reference to the key
file,
and generated an sn.exe -k key for each, also. However, neither A nor B
will compile since each depend on the other to be already compiled with a
strong name. Other than commenting out all the references to each other
(if
that would even work), what might I do to get R in the GAC?

Any help would be greatly appreciated.

Thanks,

-John

Jul 21 '05 #2
Thanks!

A funny note is that your blog was the exact issue... My mystical Project A
was our configuration library and and Project B was our logging library ;)

-John
"Nick Malik [Microsoft]" <ni*******@hotmail.nospam.com> wrote in message
news:SO********************@comcast.com...
Unwind the circular reference.

Your post inspired a blog entry... see the solution at the link below:
http://blogs.msdn.com/nickmalik/arch...18/398601.aspx

Hope this helps,

--
--- Nick Malik [Microsoft]
MCSD, CFPS, Certified Scrummaster
http://blogs.msdn.com/nickmalik

Disclaimer: Opinions expressed in this forum are my own, and not
representative of my employer.
I do not answer questions on behalf of my employer. I'm just a
programmer helping programmers.
--
"John E." <PleaseReply@usenet> wrote in message
news:eQ**************@TK2MSFTNGP09.phx.gbl...
How can I compile two projects with a circular reference while giving them a
strong name?

There is a project that we have that has two components that reference
each
other e.g. A<->B thus creating A.dll and B.dll. I have a project (e.g. R with an assembly name of Com.MyCompany.R.dll) that has to use this mess
and
access A. So, R->A. Well, Com.MyCompany.R.dll is going in the GAC. It
is
set for strong name (entry in the assembly pointing to my sn.exe -k
generated file). However, projects A and B are not strong named, thus R
won't compile until A and B are strong named.

So, I have given them a strong assembly name (e.g. Com.MyCompany.A.dll and Com.MyCompany.B.dll). I have added the assembly reference to the key
file,
and generated an sn.exe -k key for each, also. However, neither A nor B
will compile since each depend on the other to be already compiled with a strong name. Other than commenting out all the references to each other
(if
that would even work), what might I do to get R in the GAC?

Any help would be greatly appreciated.

Thanks,

-John


Jul 21 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

16 posts views Thread by Robert Mark Bram | last post: by
2 posts views Thread by Vera | last post: by
10 posts views Thread by Tony Jones | last post: by
6 posts views Thread by Manuel Lopez | last post: by
6 posts views Thread by Stephen Robertson | last post: by
6 posts views Thread by raylopez99 | last post: by
reply views Thread by XIAOLAOHU | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.