| |

VerySource

 Forgot password?
 Register
Search
View: 1427|Reply: 3

How to use makefile to compile programs in VC ++ 6.0

[Copy link]

1

Threads

2

Posts

3.00

Credits

Newbie

Rank: 1

Credits
3.00

 China

Post time: 2020-1-2 16:40:01
| Show all posts |Read mode
NMAKE -f "test.mak" CFG = "test-Debug"
That ’s it, there is relevant information there
Reply

Use magic Report

1

Threads

27

Posts

24.00

Credits

Newbie

Rank: 1

Credits
24.00

 China

Post time: 2020-1-2 16:42:01
| Show all posts
Ok
Reply

Use magic Report

0

Threads

30

Posts

22.00

Credits

Newbie

Rank: 1

Credits
22.00

 China

Post time: 2020-1-2 23:15:01
| Show all posts
Refers to MSDN:
=================
Create a Project in the Development Environment That Can Be Built with NMAKE
There are two ways to export a makefile from the development environment. You can choose to export a makefile whenever you save a project, or export a makefile only for specific projects. Note that creating an export makefile increases project save time, and you should only do it when necessary.

The export makefile stores all the information required to build the project and can be used from the command line. The makefile specifies the same project build settings you set in the development environment. If you use NMAKE on the command line to build the project, the NMAKE syntax needed is given in the makefile as a comment that begins! MESSAGE NMAKE. For example, for a file test.mak the NMAKE syntax line is:

! MESSAGE NMAKE / f "test.mak" CFG = "test-Win32 Debug"
To export an NMAKE makefile whenever you save a project

From the Tools menu, click Options.
The Options dialog box appears.

On the Options dialog box, click the Build tab.


Select the Always export makefile when saving project option.


Click OK.
To export an NMAKE makefile for a particular project

Open the project.


From the Project menu, click Export Makefile.
A .MAK file with the project name is immediately created and saved to the project directory.
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-9-4 22:45:01
| Show all posts
In doubt...
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list