[sr-dev] git:master:373e99fd: db_berkeley: removed inline declaration that break the linking

Daniel-Constantin Mierla miconda at gmail.com
Sun Dec 10 16:36:22 CET 2017


Hello,


On 10.12.17 09:40, Henning Westerholt wrote:
> Am Sonntag, 10. Dezember 2017, 09:31:20 CET schrieb Daniel-Constantin Mierla:
>> [...]
>> Commit: 373e99fd593814b55b307d0dc4a29e0c53f34850
>> URL:
>> https://github.com/kamailio/kamailio/commit/373e99fd593814b55b307d0dc4a29e0
>> c53f34850
>>
>> Author: Daniel-Constantin Mierla <miconda at gmail.com>
>> Committer: Daniel-Constantin Mierla <miconda at gmail.com>
>> Date: 2017-12-10T09:21:52+01:00
>>
>> db_berkeley: removed inline declaration that break the linking
> [..]
>
> Good morning Daniel,
>
> can you elaborate about this changes? This functions in the end were inline by 
> a reason, they are small conversion functions and can (and maybe should) be 
> inlined for performance reasons.
>
> Is this something related to new linker or compiler warnings?
>
>
the commits from this weekend that removed inline for several functions
were done because loading the modules on debian stretch threw undefined
symbol errors, like:

 0(28818) ERROR: <core> [core/sr_module.c:582]: load_module(): could not
open module <src/modules/ims_usrloc_scscf/ims_usrloc_scscf.so>:
src/modules/ims_usrloc_scscf/ims_usrloc_scscf.so: undefined symbol:
aor_to_contact
 0(28818) CRITICAL: <core> [core/cfg.y:3446]: yyerror_at(): parse error
in config file
/home/porto/work/sip/esr/kamailio-dev/../etc/kamailio-allmods.cfg, line
93, column 12-32: failed to load module

These messages I saved, but for the rest of the modules were similar errors.

The gcc version was:

gcc --version
gcc (Debian 6.3.0-18) 6.3.0 20170516

Probably I could have investigated more and see if doing static inline
would be ok in these cases -- I did many conversions in the past few
years of the inline functions, adding static didn't work always because
the functions were used in other files and I tried to avoid playing with
external inline declarations. Apart of the ims modules which I don't
have a clear picture about the use of this functions, the rest were
module used rarely these days (berkeley db and diameter) -- I tested in
preparation of kamailio v5.1.0 to be sure there are no missing symbols
and I took the fastest path for a fix, but if anyone wants to test with
static inline or do external inline whenever is the case, I am fine with.

Cheers,
Daniel

-- 
Daniel-Constantin Mierla
www.twitter.com/miconda -- www.linkedin.com/in/miconda
Kamailio Advanced Training - www.asipto.com
Kamailio World Conference - May 14-16, 2018 - www.kamailioworld.com




More information about the sr-dev mailing list