473,379 Members | 1,253 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

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

partial link

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

Nov 22 '06 #1
3 1437
>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.
Eric,

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

Dave
Nov 23 '06 #2

"David Lowndes" <Da****@example.invalidwrote in message
news:ki********************************@4ax.com...
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.

Eric,

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

Nov 24 '06 #3
>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.

Eric,

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

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
Nov 24 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: nospam | last post by:
I just read on Slash Dot about partial types. Now, is it possible to have a code behind split over two pages but still referencing the same .aspx file??? If so, that would be really nice as...
9
by: Gomaw Beoyr | last post by:
Two question about the "partial classes" (in the next wersion of ..NET). Question 1 ========== Will partial classes (in the next version of C#) have to be declared "partial" in ALL places. ...
16
by: pawel.pabich | last post by:
Hajo, I would like to have 2 my own partial classes. For example: Default.aspx.cs Default2.aspx.cs and they both will relate to Default.aspx page.
10
by: ptass | last post by:
Hi In asp.net 2.0 an aspx files .cs file is a partial class and all works fine, however, I thought I’d be able to create another class file, call it a partial class and have that compile and...
2
by: dexterbot | last post by:
Hi... I need help in finding a way to capture a partial URL link and then store that as a variable so that I can use it as part of a hyperlink. I was hoping Javascripting would allow me to do...
2
by: Steeler | last post by:
This is the weirdest thing I've ever come across but I assume I'm missing something simple. I have an Access application. I update the front end (FE) occasionally and then have an automatic...
3
by: Eric | last post by:
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...
2
by: SQL Learner | last post by:
Hi All, I need to link two tables using partial word match. How can I write a SQL statement to do so? (I am using MS-Access.) Table One: 123 ABC Street 124 ABC Street 125 ABC Street
5
by: SQL Learner | last post by:
Hi Alex (Kuznetsov) and All, This is to follow up with my last post, "Link two tables using partial word match". How can I UPDATE table using partial word match? How can I write a SQL statement...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.