vivi的编译

1)下载vivi
  http://download.gd-emb.org/download/id-435.html
 2
)修改Makefile
    vivi
的移植相对来说,工作量很小,只需要更改开发工具的几个宏就可以了。当然,如果想要增加功能,则改动可能会大一点。
 
只要更改如下:
LINUX_INCLUDE_DIR --
更改为交叉编译器的include文件夹
CROSS_COMPILE     --
交叉编译器的可执行文件的路径
ARM_GCC_LIBS      --
交叉编译器的lib库文件的路径
 ========== Modified Start============
#
# change this to point to the Linux include directory
#

# orginal setup
#LINUX_INCLUDE_DIR = /opt/host/armv4l/include/

# my setup
LINUX_INCLUDE_DIR = /usr/local/arm/2.95.3/include

======= Modified End ==================
 ============= Modified Start ==========
# orginal setup
#CROSS_COMPILE = /opt/host/armv4l/bin/armv4l-redhat-linux-
#CROSS_COMPILE = /opt/host/armv4l/bin/armv4l-unknown-linux-

# my setup
CROSS_COMPILE = /usr/local/arm/2.95.3/bin/arm-linux-

========= Modified End =================
 ========= Modified Start ================
#
# Location of the gcc arm libs.
#

# orginal setup
#ARM_GCC_LIBS = /opt/host/armv4l/lib/gcc-lib/armv4l-unknown-linux/2.95.2
#ARM_GCC_LIBS = /opt/host/armv4l/lib/gcc-lib/armv4l-redhat-linux/2.95.3

# my setup
ARM_GCC_LIBS = /usr/local/arm/2.95.3/lib/gcc-lib/arm-linux/2.95.3

=========== Modified End =================
3
)修改arch/s3c2410/smdk.c
   
主要是修改nand flash分区信息。
注意要与你make menuconfig 的选项相符合 要支持 nand 启动有些默认的vivi不是nand启动的
mtd
的设置与你要加载的内核的分区也要对应
#ifdef CONFIG_S3C2410_NAND_BOOT
mtd_partition_t default_mtd_partitions[] = {
        {
                name:           "vivi",         /* 128K, 1-8 sector             */
                offset:         0,
                size:           0x00020000,
                flag:           0
        }, {
                name:           "param",        /* 64K, 9-12 sector             */
                offset:         0x00020000,
                size:           0x00010000,
                flag:           0
        }, {
                name:           "kernel",       /* 2M+832K, 12-192 setctor      */
                offset:         0x00030000,
                size:           0x002d0000,
                flag:           0
        }, {
                name:           "root",         /* 29M, 193-2048 sector         */
                offset:         0x00300000,
                size:           0x01d00000,
                flag:           MF_BONFS
        }
};
  //
我用3.4.1  4.3.2 等交叉编译器编译的时候都没过,在2.95.3的时候过啦,高版本的交叉编译时
提示有些命令找不到

你可能感兴趣的:(linux,gcc,开发工具,include,makefile,编译器)