【问题标题】:Configuration msp430-unknown-none not supported配置 msp430-unknown-none 不支持
【发布时间】:2017-02-03 08:53:49
【问题描述】:

如何消除我在make TARGET=sky 上遇到的错误?

错误 1:(.text 不适合区域 rom

1.c: At top level:
1.c:14:57: warning: ‘last_informer’ defined but not used [-Wunused-variable]
/usr/lib/gcc/msp430/4.6.3/../../../../msp430/bin/ld: 1.sky section `.text' will not fit in region `rom'
/usr/lib/gcc/msp430/4.6.3/../../../../msp430/bin/ld: section .vectors loaded at [000000000000ffe0,000000000000ffff] overlaps section .text loaded at [0000000000004000,00000000000110eb]
/usr/lib/gcc/msp430/4.6.3/../../../../msp430/bin/ld: region `rom' overflowed by 6342 bytes
/usr/lib/gcc/msp430/4.6.3/mmpy-16/libcrt0.a(_copy_data.o): In function `__do_copy_data':
/build/buildd/gcc-msp430-4.6.3~mspgcc-20120406/./gcc-4.6.3/gcc/config/msp430/crt0.S:195: relocation truncated to fit: R_MSP430_16_BYTE against symbol `__data_load_start' defined in *ABS* section in 1.sky
obj_sky/contiki-sky-main.o: In function `main':
contiki-sky-main.c:(.init9+0x76): relocation truncated to fit: R_MSP430_16 against symbol `memset' defined in .text section in /usr/lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(memset.o)
contiki-sky-main.c:(.init9+0x82): relocation truncated to fit: R_MSP430_16 against symbol `memcpy' defined in .text section in /usr/lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(memcpy.o)
contiki-sky-main.c:(.init9+0x8c): relocation truncated to fit: R_MSP430_16_BYTE against `no symbol'
contiki-sky-main.c:(.init9+0x90): relocation truncated to fit: R_MSP430_16 against symbol `printf' defined in .text section in /usr/lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(printf.o)
contiki-sky-main.c:(.init9+0xa0): relocation truncated to fit: R_MSP430_16_BYTE against `no symbol'
contiki-sky-main.c:(.init9+0xa4): relocation truncated to fit: R_MSP430_16 against symbol `printf' defined in .text section in /usr/lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(printf.o)
contiki-sky-main.c:(.init9+0xb8): relocation truncated to fit: R_MSP430_16_BYTE against `no symbol'
contiki-sky-main.c:(.init9+0xbc): relocation truncated to fit: R_MSP430_16 against symbol `printf' defined in .text section in /usr/lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(printf.o)
contiki-sky-main.c:(.init9+0xd8): relocation truncated to fit: R_MSP430_16 against symbol `memset' defined in .text section in /usr/lib/gcc/msp430/4.6.3/../../../../msp430/lib/mmpy-16/libc.a(memset.o)
contiki-sky-main.c:(.init9+0x116): additional relocation overflows omitted from the output
collect2: ld returned 1 exit status
make: *** [1.sky] Error 1

生成文件:

dINES+=PROJECT_CONF_H=\"project-conf.h\"
CONTIKI_PROJECT = 1 2 
LIBS += node-id
all: $(CONTIKI_PROJECT)

CONTIKI = ../..

WITH_UIP6=1
UIP_CONF_IPV6=1

CFLAGS+= -DUIP_CONF_IPV6_RPL -DUIP_CONF_IPV6 -DWITH_UIP6
TARGET_LIBFILES+=-lm
ifdef PERIOD
CFLAGS=-DPERIOD=$(PERIOD)
endif

include $(CONTIKI)/Makefile.include

我使用的是 mspgcc 4.6.3 版。一些网站建议使用 mspgcc 4.7 版来摆脱ERROR 1

按照https://github.com/contiki-os/contiki/wiki/MSP430X 上的说明操作时,出现以下错误:

错误 2:(不支持配置 msp430-unknown-none)

checking whether times is declared... yes
checking whether sigaltstack is declared... yes
checking whether madvise is declared... yes
checking for struct tms... yes
checking for clock_t... yes
checking if mkdir takes one argument... no
*** Configuration msp430-unknown-none not supported
make[1]: *** [configure-gcc] Error 1
make[1]: Leaving directory `/home/taare/tmp/gcc-4.7.0-msp430'

是否正在尝试更新 mspgcc 以摆脱 ERROR 1 的正确方法?

如果是,我该如何解决ERROR 2

如果没有,我该如何解决ERROR 1

【问题讨论】:

  • 您可以在这里获得 msp430 4.6:simonduq.github.io/resources/mspgcc-4.7.2-compiled.tar.bz2
  • 这对您的问题没有帮助,您的闪存空间不足 6342 字节。您无法为 Sky 构建任何东西。选择另一个 msp430 平台。
  • 谢谢!其他的 msp430 平台是什么?还是需要程序在本地运行以满足内存限制?
  • contiki-os.org/hardware.html - 你至少需要msp430x 之一。
  • @kfx 这个问题应该不回答吗?

标签: gcc makefile contiki mspgcc


【解决方案1】:

为未来的用户回答我自己的问题。

即使在优化代码后,如果section '.text' will not fit in region rom错误仍然存​​在,那么可以通过以下方式解决:

  1. 根据所需的无线电使用任何other contiki platforms

  2. 尝试将您的 mspgcc 更新到最新版本。 [这可能并不总能解决您的问题。我在其他一些论坛上看到了这个建议,所以我在这里列出了它。]

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2014-03-01
    • 2013-07-15
    • 2019-12-16
    • 2019-01-21
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多