Hi i am new with Keil and it my question. I use u8g2 library with nRF52832. This library has a file with fonts in which there are many arrays of very large sizes but only one is used depending on the selected font. When I try to compile my project Keil is an error that the controller does not have enough space for the project is larger than 40MB which is logical since nRF52832 has only 65KB RAM and 512KB ROM. What can I do to Keil use only the currently used arrays and buffers and not all that are in the library's file?
when a library contains something that is called the whole library is loaded.
That's wrong, and I'm reasonably sure you know it. You may have mixed up "library" with "object file." And even for those this is no longer universally true, and hasn't been for quite a while. Linkers have become a good deal better at picking apart object files to use only pieces of them, and compilers have been extended to help linkers with that.