Giter Site home page Giter Site logo

Comments (1)

klew avatar klew commented on August 16, 2024 1

It looks like there are two sections: .flash.text and .flash.rodata which "start" should be in different 64 KB flash region.
Disabling asserts is reducing text section to very small one ( < 64 KB) and it causes above linking error.
For some reason, it is not a problem for linker if text and rodata share the same sector when text length is > 64 KB.

Anyway linking problem can be resolved by adding ALIGN(64K) to text section, as follows:

diff --git a/components/esp8266/ld/esp8266.project.ld.in b/components/esp8266/ld/esp8266.project.ld.in
index 54d7bb48..ce1decc2 100644
--- a/components/esp8266/ld/esp8266.project.ld.in
+++ b/components/esp8266/ld/esp8266.project.ld.in
@@ -175,6 +175,7 @@ SECTIONS
     *(.fini.literal)
     *(.fini)
     *(.gnu.version)
+    . = ALIGN (64K);
     _text_end = ABSOLUTE(.);
     _etext = .;

It fixes linking but it make binary file a little bit bigger. I'm not very familiar with ldgen, so if there is away to add this align conditionally, then it would be better solution.

from esp8266_rtos_sdk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.