473,395 Members | 1,537 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,395 software developers and data experts.

Generating .lib file

105 100+
Hi all,

I want to start a project that generates .lib file.Could anypone please tell me what are settings I need to use , like what aplication I have to use .

I opened New Project->C++

Many options like win32 Console, MFC DLL and so on.I am using Visual 2005 on Windows.

Thanks.
Apr 5 '07 #1
4 2118
weaknessforcats
9,208 Expert Mod 8TB
Create a Win32 Project.

When the wizard appears DO NOT click Finish.

Instead, click Application Settings and select Static Library.

You might want to de-select Precompiled headers unless you know how they work.

Then click Finish.

When you build the product will be a .lib and a corresponding .h

Then all need do in another project is #include the header and ADD the .lib
to the linker's list of libraries:
1) Right click on project name
2) Select Properties
3) Select Linker in the left pane
4) Select Input in the left pane
5) Add your .lib in the right pane under Additional Dependencies
5) Click OK.

And off you go.
Apr 5 '07 #2
mickey22
105 100+
Thank you very much providing me with all the necessary steps.I will try to do in that way.Thanks.
Apr 5 '07 #3
dubZ
7
What is the benefit/difference to using a .lib file as opposed to using a .dll?
Apr 10 '07 #4
weaknessforcats
9,208 Expert Mod 8TB
Functions form a static library are copied to your executable and the linker points all the call to the functions it copied from the library. Hence the static.

A dynamic library is loaded at run time. Here's a case where you can pull off a software upgrade just by sending your customers a newer dll. Had you used a static library you would need to redistrinute the entire program.

Also, a statically linked program has the maximum memory footprint since everything was done by the linker. With a dll, you can unload it when you are finished and this reduces the memory requirements for your program.
Apr 10 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: skn | last post by:
Hello., Does the python compiler provide an option to generate a .pyo(optimized byte code file) from a .py (source file)? For generating .pyc I know that I only have to pass the source file...
7
by: eric.gagnon | last post by:
In a program randomly generating 10 000 000 alphanumeric codes of 16 characters in length (Ex.: "ZAZAZAZAZAZAZ156"), what would be an efficient way to ensure that I do not generate duplicates? ...
10
by: Al Christoph | last post by:
Please forgive me if this is the wrong place to post this. The last place I posted got me a fairly rude response. I guess vb.db people just don't want to think about XML as database. At any rate,...
3
by: daniele.balducci | last post by:
Hi All, I'm generating XLS files from ASP(.Net) code using the usual code chunks ... Response.ContentType = "application/vnd.ms-excel" Response.AppendHeader("Content-Disposition", "attachment;...
0
by: manas589 | last post by:
Hi Can any one tell me how to use binding.xml while generating castor bean from an xsd file. i have one xsd file where two element are conflicting. so i thought to use binding file while...
2
by: bizt | last post by:
Hi, Is it possible to obtain the width/ height of an image when that image is dyanically created using a PHP script and passing GET attributes. For example: <img...
7
by: Nathan Sokalski | last post by:
I am an ASP.NET developer, and Visual Studio 2005 seems to have stopped declaring the controls that I add in the *.designer.vb files, therefore forcing me to manually add them before I can use them...
1
by: Nathan Sokalski | last post by:
Visual Studio 2005 recently stopped generating the *.designer.vb files for my *.aspx and *.ascx files. I am using Service Pack 1, and do not believe I did anything differently than normal prior to...
1
by: csharpula csharp | last post by:
Hello, I need to generate cs files from XSD files. I would like to do it automatically. What is the best way to do it? Is it better be done with PreBuild inside VS (before compilation) or to...
2
by: veer | last post by:
hi i made program in which i am generating the report of a ms-table database it works fine only on my computer and generatin the reports but when i run this exe on any computer the whole programe...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
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
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.