469,909 Members | 1,757 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,909 developers. It's quick & easy.

Building a Single Assembly EXE or DLL with C# and C++ Code

Building a Single Assembly DLL with C# and C++ Code

I am trying to create a single assembly composed of managed C++
and C# code, and I want to do this on the command line.

I have confirmed that I can do this in Visual Studio 2005 using
the steps described here:
http://blogs.msdn.com/frankpr/archiv...27/198918.aspx

Question: How can I do this on the command line? What is Visual
Studio doing behind the scenes to create a single file assembly?

Here is what I have done so far:

1. Create a C# netmodule.

2. Compile managed C++ using cl.exe and reference the netmodule
to it using the "using" directive in the code, and the /AI
option.

However, this creates a multi-file assembly. I end up with an exe
and a netmodule, and I need to deploy both, for the exe to
function.

What does Visual Studio do to create a single assembly out of
this?

Any ideas?
Asim
Jul 21 '05 #1
1 2573
why not try using Module for doing that. Compile your code in Module and then
add this module to other assembky written in different language. Module are
the best way to create a single file assembly comprising of codes from
multiple languages..

regards
Nishith Pathak

"Asim Jalis" wrote:
Building a Single Assembly DLL with C# and C++ Code

I am trying to create a single assembly composed of managed C++
and C# code, and I want to do this on the command line.

I have confirmed that I can do this in Visual Studio 2005 using
the steps described here:
http://blogs.msdn.com/frankpr/archiv...27/198918.aspx

Question: How can I do this on the command line? What is Visual
Studio doing behind the scenes to create a single file assembly?

Here is what I have done so far:

1. Create a C# netmodule.

2. Compile managed C++ using cl.exe and reference the netmodule
to it using the "using" directive in the code, and the /AI
option.

However, this creates a multi-file assembly. I end up with an exe
and a netmodule, and I need to deploy both, for the exe to
function.

What does Visual Studio do to create a single assembly out of
this?

Any ideas?
Asim

Jul 21 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by John | last post: by
3 posts views Thread by DrSarang | last post: by
5 posts views Thread by Peter Rilling | last post: by
5 posts views Thread by wl | last post: by
reply views Thread by roger23 | last post: by
12 posts views Thread by Ludwig | last post: by
1 post views Thread by Waqarahmed | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.