search
HomeOperation and MaintenanceWindows Operation and MaintenanceWin32 SDK Basics (1) Detailed explanation of Windows program classification and directories where libraries and header files are located

1. Windows program classification

1. Console program

Windows Dos program does not have its own window and needs to use the Dos window for user interaction. The main function

int main()
{
    return 0;
}

2. Windows window program

Visible programs under the windows system basically belong to this kind, including word, excel, etc., main function :

int APIENTRY wWinMain(_In_ HINSTANCE hInstance,
                     _In_opt_ HINSTANCE hPrevInstance,
                     _In_ LPWSTR    lpCmdLine,
                     _In_ int       nCmdShow)
{...}

depends on the host program to call and execute, and cannot be executed by itself. The host program will only enter the memory after calling the interface. Function:

BOOL APIENTRY DllMain( HMODULE hModule,
                       DWORD  ul_reason_for_call,
                       LPVOID lpReserved
					 )
{...}

4, staticLibrary program lib

has no entry function and cannot be executed, so it cannot be entered into the memory. The host function reads the code directly from the hard disk. Then copy a copy of the code into your own process.

2. Classification of compilation tools under VC

1. Compiler CL.exe

is used to translate the source code into the directory where the target code

is located:

C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\CL.exe

2. Connector LINK.exe

is used to connect the target code and library to generate the final file.

Directory:

C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\LINK.exe

3. Resource compiler RC.exe

The function is to compile the resources and finally save them into the final file through the connector

Directory (under vs2015)::

C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\Bin\x64\RC.exe

3. Common VC libraries

1, kernel32.dll

provides thread, process, and memory management etc. Core API

2, user32.dll

provides window, message and other API

3, gdi32.dll

provides API of drawing

The path of the above three libraries:

C:\Windows\System32

4. Under VC Standard header file

1, windef.h

windows’data type

2, winbase.h

contains kernel32 .dll all API declarations

3, wingdi.h

contains all gdi32.dll API declarations

4, winuser.h

contains The API declarations of all user32.dll

5, winnt.h

contain support for UNICODE character set

6, windows.h

A collection of all windows header files

The directory where all the above header files are located (under vs2015):

C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\Include\

The above is the detailed content of Win32 SDK Basics (1) Detailed explanation of Windows program classification and directories where libraries and header files are located. For more information, please follow other related articles on the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
3 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
3 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
3 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
WWE 2K25: How To Unlock Everything In MyRise
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Atom editor mac version download

Atom editor mac version download

The most popular open source editor

SAP NetWeaver Server Adapter for Eclipse

SAP NetWeaver Server Adapter for Eclipse

Integrate Eclipse with SAP NetWeaver application server.

PhpStorm Mac version

PhpStorm Mac version

The latest (2018.2.1) professional PHP integrated development tool

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

mPDF

mPDF

mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),