I am working on a library that is used in a piece of firmware by a customer, but is precompiled so it is not exposed to the customer. The customer needs to provide some settings for the firmware in a header file that is used by the library. When I compile the library and run the firmware, the library sometimes uses values from the header file that was used in the compilation of the library, rather than the header file of the same name that is in the firmware folder. This is not conistent, some values are taken from the right header file (#defines usually), while a set of arrays that contain measurement values from the customer come from the wrong header file.
For example, I have in the header file that is used for the firmware:
Code:
static const float scaling[5][5] = {     {0.2, 0.2, 0.2, 0.2, 0.2 },
    {0.2, 0.2, 0.2, 0.2, 0.2 },
    {0.2, 0.2, 0.2, 0.2, 0.2 },
    {0.2, 0.2, 0.2, 0.2, 0.2 },
    {0.2, 0.2, 0.2, 0.2, 0.2 },
   
};
and in the header file used to compile the library:
Code:
static const float scaling[5][5] = {     {1, 1, 1, 1, 1 },
    {1, 1, 1, 1, 1 },
    {1, 1, 1, 1, 1 },
    {1, 1, 1, 1, 1 },
    {1, 1, 1, 1, 1 },
   
};
and in the c file of the library:
Code:
float scale_output=scaling[2][2];
this gives a scale_output value of 1, instead of 0.2.

What is causing this issue and how do I get around it while still allowing the customer to change these values without exposing the library?