2011年3月17日 星期四

gitignore要好好設定

gitignore要好好設定

花了點時間才找到為啥在我的主機下compile uboot都沒問題,透過git上傳後再下戴到B資料夾,在B資料夾下compile就出現了error如下:

In file included from /home/ecs/LL/TA70U1-uboot/ecs-rtm1.0/include/common.h:112,
                 from hello_world.c:24:
/home/ecs/LL/TA70U1-uboot/ecs-rtm1.0/include/image.h:42: fatal error: asm/u-boot.h: No such file or directory
compilation terminated.
make[1]: *** [hello_world.o] Error 1
make[1]: Leaving directory `/home/ecs/LL/TA70U1-uboot/ecs-rtm1.0/examples'
make: *** [examples] Error 2


花了點時間查訊,原來是少了一些檔案:
1.  include/arm-asm/u-boot*.*
2.  include/u-boot/md5.h
3.  board/samsung/smdkc110/u-boot.lds

都是少了「u-boot」這類的字,查了一下,果然是設定 .gitignore時造成的

...
drivers/**/*.depend
drivers/**/**/*.[ao]
drivers/**/**/*.depend
...
post/*.a
tools/*.o
tools/*.depend
u-boot
u-boot*.*
...

 看來上傳時,也會依照 gitignore 設定讓特定的檔案不上傳

沒有留言:

張貼留言