<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=iso-8859-2">
</head>
<body text="#000000" bgcolor="#FFFFFF">
muze mi nekdo vysvetlit, v cem je rozdil techto dvou prikazovych
radku pro linker? <br>
<br>
arm-none-eabi-gcc.exe -mfloat-abi=soft -fdata-sections
-ffunction-sections -Os -DUSE_HAL_DRIVER -DSTM32F051x8
-D__weak=__attribute__((weak))
-D__packed=__attribute__((__packed__)) -mthumb -mcpu=cortex-m0
-march=armv6-m -MMD -MP -fmessage-length=0 -Wall -g3 -o
bin\Debug\Demo32F051.elf
obj\debug\drivers\cmsis\device\st\stm32f0xx\source\templates\gcc\startup_stm32f051x8.o
obj\debug\drivers\cmsis\device\st\stm32f0xx\source\templates\system_stm32f0xx.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_adc.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_adc_ex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_cortex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_dma.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_flash.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_flash_ex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_gpio.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_pwr.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_pwr_ex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_rcc.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_rcc_ex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_uart.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_uart_ex.o
obj\debug\src\main.o obj\debug\src\stm32f0xx_hal_msp.o
obj\debug\src\stm32f0xx_it.o<br>
-Wl,-Map=bin\Debug\Demo32F051.map -specs=nano.specs
-Wl,--gc-sections -lm -ffunction-sections -fdata-sections
-mcpu=cortex-m0 -march=armv6-m <font color="#ff0000">-T"SW4STM32\Demo32F051
Configuration\STM32F051K6Ux_FLASH.ld"</font><br>
<br>
Program size (bytes): 8632<br>
Data size (bytes): 112<br>
BSS size (bytes): 1776<br>
<br>
------------- a tohoto:<br>
<br>
arm-none-eabi-gcc.exe -mfloat-abi=soft -fdata-sections
-ffunction-sections -Os -DUSE_HAL_DRIVER -DSTM32F051x8
-D__weak=__attribute__((weak))
-D__packed=__attribute__((__packed__)) -mthumb -mcpu=cortex-m0
-march=armv6-m -MMD -MP -fmessage-length=0 -Wall -g3 <br>
<font color="#ff0000">-Wl,-script="SW4STM32\Demo32F051
Configuration\STM32F051K6Ux_FLASH.ld" <br>
</font>-o bin\Debug\Demo32F051.elf
obj\debug\drivers\cmsis\device\st\stm32f0xx\source\templates\gcc\startup_stm32f051x8.o
obj\debug\drivers\cmsis\device\st\stm32f0xx\source\templates\system_stm32f0xx.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_adc.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_adc_ex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_cortex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_dma.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_flash.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_flash_ex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_gpio.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_pwr.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_pwr_ex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_rcc.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_rcc_ex.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_uart.o
obj\debug\drivers\stm32f0xx_hal_driver\src\stm32f0xx_hal_uart_ex.o
obj\debug\src\main.o obj\debug\src\stm32f0xx_hal_msp.o
obj\debug\src\stm32f0xx_it.o <br>
-Wl,-Map=bin\Debug\Demo32F051.map -specs=nano.specs
-Wl,--gc-sections -lm -ffunction-sections -fdata-sections
-mcpu=cortex-m0 -march=armv6-m<br>
<br>
Program size (bytes): 8916<br>
Data size (bytes): 1084<br>
BSS size (bytes): 1776<br>
<br>
-----------------------<br>
Myslim, ze se to lisi jen ve zvyraznenem textu, v prvnim pripade do
option pridano rucne, ve druhem si to tam prida EmBlocks
automaticky. Mel jsem od oka za to, ze by to melo fungovat stejne,
ale k -Wl,-script jsem nenasel nic... zdrojaky a ostatni nastaveni
jsou stejna (doufam)<br>
Tollchain je EmBlock bare metal ale nejnovejsi newlib to dela taky
podobne... V druhem pripade sezere pamet nejvic tohle:<br>
<br>
*(.data*)<br>
.data.impure_data<br>
0x20000000 0x428 c:/program files
(x86)/emblocks/2.30/share/em_armgcc/bin/../lib/gcc/arm-none-eabi/4.7.3/../../../../arm-none-eabi/lib/armv6-m\libc.a(lib_a-impure.o)<br>
.data._impure_ptr<br>
0x20000428 0x4 c:/program files
(x86)/emblocks/2.30/share/em_armgcc/bin/../lib/gcc/arm-none-eabi/4.7.3/../../../../arm-none-eabi/lib/armv6-m\libc.a(lib_a-impure.o)<br>
0x20000428 _impure_ptr<br>
.data.SystemCoreClock<br>
0x2000042c 0x4
obj\debug\drivers\cmsis\device\st\stm32f0xx\source\templates\system_stm32f0xx.o<br>
0x2000042c SystemCoreClock<br>
0x20000430 . = ALIGN (0x4)<br>
0x20000430 _edata = .<br>
<br>
.jcr 0x20000430 0x0 load address 0x08002710<br>
.jcr 0x20000430 0x0 c:/program files
(x86)/emblocks/2.30/share/em_armgcc/bin/../lib/gcc/arm-none-eabi/4.7.3/armv6-m/crtbegin.o<br>
<br>
.igot.plt 0x20000430 0x0 load address 0x08002710<br>
.igot.plt 0x00000000 0x0 c:/program files
(x86)/emblocks/2.30/share/em_armgcc/bin/../lib/gcc/arm-none-eabi/4.7.3/armv6-m/crtbegin.o<br>
0x20000430 . = ALIGN (0x4)<br>
<br>
<br>
v prvnim pripade vypada datova sekce takto, evidentne se pouzije
jina knihovna. Proc?<br>
<br>
*(.data*)<br>
.data.SystemCoreClock<br>
0x20000000 0x4
obj\debug\drivers\cmsis\device\st\stm32f0xx\source\templates\system_stm32f0xx.o<br>
0x20000000 SystemCoreClock<br>
.data.impure_data<br>
0x20000004 0x60 c:/program files
(x86)/emblocks/2.30/share/em_armgcc/bin/../lib/gcc/arm-none-eabi/4.7.3/../../../../arm-none-eabi/lib/armv6-m\libc_n.a(lib_a-impure.o)<br>
.data._impure_ptr<br>
0x20000064 0x4 c:/program files
(x86)/emblocks/2.30/share/em_armgcc/bin/../lib/gcc/arm-none-eabi/4.7.3/../../../../arm-none-eabi/lib/armv6-m\libc_n.a(lib_a-impure.o)<br>
0x20000064 _impure_ptr<br>
0x20000068 . = ALIGN (0x4)<br>
0x20000068 _edata = .<br>
<br>
<br>
<br /><br />
<hr style='border:none; color:#909090; background-color:#B0B0B0; height: 1px; width: 99%;' />
<table style='border-collapse:collapse;border:none;'>
<tr>
<td style='border:none;padding:0px 15px 0px 8px'>
<a href="https://www.avast.com/antivirus">
<img border=0 src="http://static.avast.com/emails/avast-mail-stamp.png" alt="Avast logo" />
</a>
</td>
<td>
<p style='color:#3d4d5a; font-family:"Calibri","Verdana","Arial","Helvetica"; font-size:12pt;'>
Tato zpráva byla zkontrolována na viry programem Avast Antivirus.
<br><a href="https://www.avast.com/antivirus">www.avast.com</a>
</p>
</td>
</tr>
</table>
<br />
</body>
</html>