补丁

来源:互联网 发布:数据etl具体工作内容 编辑:程序博客网 时间:2024/04/30 01:43

1. 制作补丁

diff -urN u-boot-2010.06/ u-boot/ > ../u-boot-just-work.patch

u-boot-2010.06/ 是原始的文件夹

u-boot/是我添加了很多修改后的文件夹

../u-boot-just-work.patch是补丁


2. 打补丁

To revert a previously applied patch, use the -R argument to patch.
So, if you applied a patch like this:

cd xxxxx/
patch -p1 < ../patch-x.y.z


You can revert (undo) it like this:

cd xxxxx/
patch -R -p1 < ../patch-x.y.z

示例

cd /development/mini2440/u-boot-2010.06/

[root@localhost u-boot-2010.06]# patch -p1 < /home/harvis/Desktop/u-boot-just-work.patch 
patching file arch/arm/cpu/arm920t/s3c24x0/speed.c
patching file arch/arm/cpu/arm920t/s3c24x0/timer.c
patching file arch/arm/cpu/arm920t/start.S
patching file arch/arm/include/asm/arch-s3c24x0/s3c24x0_cpu.h
patching file arch/arm/include/asm/arch-s3c24x0/s3c24x0.h
patching file arch/arm/lib/board.c
patching file board/samsung/mini2440/config.mk
patching file board/samsung/mini2440/flash.c
patching file board/samsung/mini2440/lowlevel_init.S
patching file board/samsung/mini2440/Makefile
patching file board/samsung/mini2440/mini2440.c
patching file include/configs/mini2440.h
patching file Makefile


0 0
原创粉丝点击