Hi all,
I've been looking into upgrading our copy of talloc.[ch] in libosmocore, but unlike 7 years ago, it is not that easy anymore. The build system integration is quite heavy, and it might be a good point to simply drop talloc from libosmocore.
Also contrary to 7 years ago, distributions tend to ship libtalloc these days. So there's not really any reason to continue shiping it.
Right now I'm making it optional, and have sorted out how to make this source compatible. But this generates runtime incompabilities, due to the ABI incompabibilities between our ancient talloc and current talloc :(
While the API of our talloc and current talloc seems compatible, the ABI is not. For example, they changed talloc_free() into an inline function resulting in calls to _talloc_free(), while our code links directly against talloc_free().
So We'd have to move from libosmocore-6.0.0 to 7.0.0 as part of the transition and cannot really keep both options without causing additional compatibility issues to our users.
So the question is: Why bother? does anyone have objections to removing the built-in talloc?
On 21 Nov 2015, at 14:02, Harald Welte laforge@gnumonks.org wrote:
So the question is: Why bother? does anyone have objections to removing the built-in talloc?
no, have you seen Jan Engelhardt's changes? They are still in our patchwork and serve as reminder that we need to do something about it. I think we should remove <osmocom/core/talloc.h> at the same time.
holger
Hi Holger,
On Sat, Nov 21, 2015 at 03:50:24PM +0000, Holger Freyther wrote:
no, have you seen Jan Engelhardt's changes?
I didn't remember them, no :/
But in any case, your mail was not a response to my question. What do you think about it?
I think we should remove <osmocom/core/talloc.h> at the same time.
I think we should keep it as a convenience wrapper just containing a single line of "#include <talloc.h>". _maybe_ with a #warning together.
This makes sense for people wanting to build e.g. older branches with new libosmocore. That wrapper-header doesn't hurt and helps people avoid broken builds.
On 21 Nov 2015, at 19:18, Harald Welte laforge@gnumonks.org wrote:
But in any case, your mail was not a response to my question. What do you think about it?
Was there another question than if we object? I do not object and I think using the system talloc is the right thing to do. I was surprised that the Fedora package didn't raise this issue.
I think we should remove <osmocom/core/talloc.h> at the same time.
I think we should keep it as a convenience wrapper just containing a single line of "#include <talloc.h>". _maybe_ with a #warning together.
This makes sense for people wanting to build e.g. older branches with new libosmocore. That wrapper-header doesn't hurt and helps people avoid broken builds.
hmm. okay. But new code should use talloc.h directly then?
holger