ltib -c and get syntax error in dts file

以前能编译过的ltib,这几天编译时,试了好几遍总是遇到同样的错误无法编译过:

coolyu@coolyu-desktop:~/ltib-mpc8315erdb-20080630$: ltib -c

...

+ [ mpc8315erdb_default mpc8315erdb_1588 mpc8315erdb_otg mpc8315erdb_ulpi = %dtc_name ]
+ basename mpc8315erdb_default.dtb
+ dtc -f -b 0 -I dts -O dtb -R 8 -S 0x3000 -o /home/coolyu/ltib-mpc8315erdb-20080630/tmp/kernel//opt/freescale/rootfs/ppc/boot/mpc8315erdb_default.dtb arch/powerpc/boot/dts/mpc8315erdb_default.dts
DTC: Use of "-S" is deprecated; it will be removed soon, use "-p" instead
DTC: dts->dtb  on file "arch/powerpc/boot/dts/mpc8315erdb_default.dts"
Error: arch/powerpc/boot/dts/mpc8315erdb_default.dts 12:0 - 1:0 syntax error
FATAL ERROR: Unable to parse input tree
error: Bad exit status from /home/coolyu/ltib-mpc8315erdb-20080630/tmp/rpm-tmp.733 (%install)


RPM build errors:
    Bad exit status from /home/coolyu/ltib-mpc8315erdb-20080630/tmp/rpm-tmp.733 (%install)
Build time for kernel-2.6.24.3-mpc8315erdb: 363 seconds

Failed building kernel-2.6.24.3-mpc8315erdb


f_buildrpms() returned an error, exiting
traceback:
 main:501


Started: Sat May 28 21:53:09 2011
Ended:   Sat May 28 21:59:36 2011
Elapsed: 387 seconds

These packages failed to build:
kernel-2.6.24.3-mpc8315erdb

Build Failed

Exiting on error or interrupt
coolyu@coolyu-desktop:~/ltib-mpc8315erdb-20080630$ cd ..

Freescale提供的解决办法:

http://forums.freescale.com/t5/8-Bit-Microcontrollers/building-with-ltib-c-and-get-syntax-error-in-dts-file/td-p/59936

 

Re: building with ltib -c and get syntax error in dts file

Options

2011-02-25 01:04 PM

Ok, managed to sort this.

 

Apparently the .dts files for the mpc8313erdb are in dts-v0 format. The vrsion of the DTC (Device Tree Compiler)  I have installed does not support this format any longer.

 

To fix it I downloaded the source and built it, which includes a utility called convert-dtsv0

(下载该目录下的所有源码,编译出可执行程序convert-dtsv0,放到host-linux系统的/usr/local/bin目录下。进入mpc8313erdb.dts所在目录,执行命令:convert-dtsv0 mpc8313erdb.dts,可以看到新生成了mpc8313erdb.dtsv1,再将mpc8313erdb.dtsv1改成文件名mpc8313erdb.dts,替换掉原来的mpc8313erdb.dts文件)

>git clone http://git.jdl.com/software/dtc.git

>cd dtc

>make

 

This should build the convert-dtsv0 utiltity

 

Copy it to your /usr/local/bin directory (or wherever you think is suitable in your PATH)

 

>cd /ltib-mpc8313erdb-20081222/config/platform/mpc8313erdb/dts/

(or wherever you have the BSP installed)

 

>convert-dtsv0 mpc8313erdb.dts

>convert-dtsv0 mpc8313erdb-revc-tsec1-marvell.dts

>convert-dtsv0 mpc8313erdb-usb-internal-client.dts

 

This will produce three files of the same names, but with the extension .dtsv1

You will need to delete or rename the original files to something else (I renamed them with an extra .orig extension), then rename the .dtsv1 files to .dts

 

The build should now work. (hopefully)

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值