10008. Nuclear compilation rational steps

xiaoxiao2021-03-06  85

Welcome to, but please indicate the source. 1. Backup Important Document Backup The following files can recover the original state in the system when errors or crashes in the system. 1. Backup kernel and launch file # cd / # tar cvzf boot.tar.gz boot 2, backup system function number header file # cd / usr / include # tar cvzf linux.tar.gz Linux 3, library file in the backup module # CD / lib / modules # tar cvzf 2.4.7-10.tar.gz 2.4.7-10 # tar cvzf 2.4.7-10debug.tar.gz 2.4.7-10Debug 4, backup Linux source # CD / USR / SRC # TAR CVZF Linux-2.4.7-10.tar.gz Linux-2.4.7-10 # tar cvzf Linux-2.4.7-10debug.tar.gz Linux-2.4.7-10debug 5, Backup Important Configuration Directory # CD / # TAR CVZF etc. Trip 2, modify core parameters (PGC2000 required) 1. Modify the core parameters related to shared memory # CD / usr / include / Linux # Vi Shm.h Put #define SHMMAX 0x2000000 / * Max Shared seg size (bytes) * / change to #define shmmax 0xa0000000 / * max shared seg size (bytes) * / 2, modify and signal related core parameters # cd / usr / include / linux # vi sem.h put # Define Semopm 32 / * <= 1 100 Max Num of Ops Per Semop Call * / Change to #define Semopm 900 / * <= 1 100 Max Num of Ops Per Semop Call * / 3, Modify Core Parameters related to Message Queense # CD / usr / include / linux # vi msg.h found the following three lines (Note ignore): #define msgmni 16 #define msgmax 8192 #define msgmnb 16384 modified to: #define msgmni 128 #define msgmax 131072 #define msgmnb 20000000 4, according to the above method, the same modification /usr/src/linux-2.4.7-10/include/ SHM.H, Sem.h and Msg.h files under Linux. Third, download release core source code If it is only modified compiled kernel, this step can be saved. This step is necessary when we download new kernel files (such as Linux-2.4.7-12.tar.gz) from the Internet site. 1. Release the kernel source code # CD / USR / SRC # TAR ZXVF Linux-2.4.7-12.tar.gz file release, a Linux subdirectory is generated in the / usr / src directory. These include source code. 2, link / usr / include / asm, / usr / inLude / Linux, / usr / include / scsi to the corresponding directory in the / usr / src / linux / incrude directory. # CD / usr / include # rm -rf asm Linux # ln -s / usr / src / linux / include / asm-i386 ASM # ln -s / usr / src / linux / include / linux linux # ln -s / usr / src / linux / include / SCSI SCSI 4, configure the kernel 1, delete the .o file and other dependent files in the source code directory.

转载请注明原文地址:https://www.9cbs.com/read-106048.html

New Post(0)