Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / General / November 2006

Tip: Looking for answers? Try searching our database.

partial link

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Eric - 22 Nov 2006 22:24 GMT
Hello all,

This is a C++ linker question.

I'm trying to build an obj file, say foo.obj so that it is pre-linked
with its dependencies. However I do not want to generated an executable
right away. Some people call this "partial linking". Note that
packaging all dependent objs into a library is not an option. All I
want is really one obj file whose dependencies have all been pre-linked
with it, so when I link the final executable file I won't have to
provide foo.obj's dependencies at that time.

In linux I know this can be done using "ld -r -o", so I'm assuming
there's got to be an equivalent way to do this with link.exe.

Regards,

Eric
David Lowndes - 23 Nov 2006 00:26 GMT
>I'm trying to build an obj file, say foo.obj so that it is pre-linked
>with its dependencies. However I do not want to generated an executable
[quoted text clipped - 3 lines]
>with it, so when I link the final executable file I won't have to
>provide foo.obj's dependencies at that time.

Eric,

I suspect that what you're looking for is #pragma comment (lib,..)

Dave
Ben Voigt - 24 Nov 2006 15:17 GMT
> >I'm trying to build an obj file, say foo.obj so that it is pre-linked
>>with its dependencies. However I do not want to generated an executable
[quoted text clipped - 7 lines]
>
> I suspect that what you're looking for is #pragma comment (lib,..)

The final project would still need the dependent libraries available.

However, making a DLL would act in the fashion desired, unless you are
trying to avoid that when you say "I do not want to generate an executable
right away".

> Dave
David Lowndes - 24 Nov 2006 16:08 GMT
>> >I'm trying to build an obj file, say foo.obj so that it is pre-linked
>>>with its dependencies. However I do not want to generated an executable
[quoted text clipped - 9 lines]
>
>The final project would still need the dependent libraries available.

That's true. I'd read the question more as "I wouldn't have to specify
foo.obj's dependencies at that time"

Dave

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.