After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 591436 - Add -avoid-version to LDFLAGS
Add -avoid-version to LDFLAGS
Status: RESOLVED FIXED
Product: evolution
Classification: Applications
Component: general
2.28.x (obsolete)
Other Linux
: Normal normal
: ---
Assigned To: Evolution Shell Maintainers Team
Evolution QA team
Depends on:
Blocks:
 
 
Reported: 2009-08-11 11:48 UTC by H.Habighorst
Modified: 2017-05-05 20:58 UTC
See Also:
GNOME target: ---
GNOME version: 2.27/2.28


Attachments
Adds -avoid-version to Makefile.am's (10.86 KB, patch)
2009-08-11 11:48 UTC, H.Habighorst
accepted-commit_now Details | Review
Updated patch against current master (12.70 KB, patch)
2010-01-09 11:27 UTC, H.Habighorst
none Details | Review
Updated the patch again [changes to em-filter-i18n.h?!] (9.61 KB, patch)
2010-01-09 11:32 UTC, H.Habighorst
committed Details | Review

Description H.Habighorst 2009-08-11 11:48:08 UTC
As I've read bug #591414, I was wondering why we needed 0 versions on the .so files.

We don't use it in plugins, we don't use it for the test components, but for the libraries, although they are shipped in a directory that's versioned with the base_number.

This patch adds -avoid-version to the libraries evolution builds.
Comment 1 H.Habighorst 2009-08-11 11:48:34 UTC
Created attachment 140423 [details] [review]
Adds -avoid-version to Makefile.am's
Comment 2 Matthew Barnes 2009-08-11 11:59:44 UTC
You're probably right, but let's hold off on this until after 2.29.1.  There's quite a few libraries that need not be installed in the first place (e.g. the a11y and importer libraries).

I plan to discontinue the versioned directories for 3.0, and the libraries are going to shift around a bit when the kill-bonobo branch lands.
Comment 3 Daniel Macks 2009-08-11 22:33:55 UTC
As a downstream packager, I'm concerned about the public status (and interface stability, if public) of these libs...I don't know the release plans, so I'll just state my thoughts while the topic of renaming and relocating shared libs is fresh.

I see lots of headers are installed, so I assume they are for public libs, so the libs need to be interface-versioned *somehow*. Obviously easiest for others if they follow normal libtool -version-info and try to maintain backward-compatibility (okay add public symbols but not remove or change prototypes or struct declarations of existing public ones) to make upgrades not break things for users. Second best is to declare that there should be no expectation of stability between different base_versions, and so keep them named/segregated by release version. In that case, don't need -version-info (and can use -no-version or maybe -release) because the directory name serves the same public purpose. By changing directory name, the SONAME (or rpath...different platforms do those different) changes, so it's clear that the interface is different in an upgrade because it's not the same lib pathname. Finally, if a shared lib is private (used among components of the evolution package itself but not linked by public shared libs), then name is irrelevant because it's invisible outside of evo itself.
Comment 4 Milan Crha 2009-12-16 20:38:01 UTC
Matt, is it ready to go now?
Comment 5 Matthew Barnes 2009-12-16 21:55:37 UTC
Yeah, I think so.

These libraries have no stability or backward-compatibility guarantees, and I don't even want to attempt the losing battle that libtool versioning would surely be.  Daniel makes a good point about the versioned directories being the only means of identifying the interface version, so I'll back off my wanting to kill it for $(libdir) and $(includedir).  But I'm still going after $(datadir).

Need to verify this isn't going to cause linking issues in extension packages (exchange, mapi, rss, etc.) before commiting.
Comment 6 Milan Crha 2010-01-07 12:21:37 UTC
(In reply to comment #5)
> Need to verify this isn't going to cause linking issues in extension packages
> (exchange, mapi, rss, etc.) before commiting.

H.Habighorst, could you take care of it and commit after Monday release? (There is no enough time for testing it before the release, I'm afraid.)
Comment 7 Milan Crha 2010-01-07 12:23:50 UTC
Comment on attachment 140423 [details] [review]
Adds -avoid-version to Makefile.am's


Matt, I hope I got your comment properly, as the patch can be used as is, without any change.
Comment 8 H.Habighorst 2010-01-09 11:27:24 UTC
Created attachment 151085 [details] [review]
Updated patch against current master

This is an updated patch - as the old patch was 4 month old, it didn't apply.

I didn't found any *.so.0(.0.0) files afterwards, guess I've catched all the occurrences.

The patch shouldn't produce build errors in other software - we had no version set and the versioning applies afaik only to the shared object files...
Comment 9 H.Habighorst 2010-01-09 11:32:32 UTC
Created attachment 151086 [details] [review]
Updated the patch again [changes to em-filter-i18n.h?!]

This is an updated patch again, in the other patch were changes to em-filter-i18n.h... I didn't change it - maybe a candidate for .gitignore?!
Comment 10 André Klapper 2012-02-14 14:30:55 UTC
ping - can this patch get a review?
Matt / Milan?
Comment 11 Milan Crha 2012-02-15 10:19:20 UTC
Works for me, I'm committing it.
Comment 12 Milan Crha 2012-02-15 10:24:26 UTC
Created commit 1600064 in evo master (3.3.90+)
Comment 13 Antoine Jacoutot 2012-03-28 13:22:03 UTC
Just a small comment on this. Isn't it bad practice to remove the version from the shared lib when other things may link to it? (e.g. evolution-rss wants to link against: eutil, eshell, email-engine, email-utils, evolution-utils...).

Side note, I will have to locally revert this patch in our ports tree to build the OpenBSD package since we can only link against versioned libs (dlopen'ing is fine of course, it's just linking that fails).
Comment 14 Matthew Barnes 2012-03-28 14:09:33 UTC
We don't version Evolution libraries because we offer absolutely no API/ABI stability guarantees from one release to the next, so I'd rather they not have misleading names like libfoo-0.0.0.so.  We only version Evolution-Data-Server libraries.  But patch around it if you must.
Comment 15 Antoine Jacoutot 2012-03-28 14:29:37 UTC
Sure I understand the intent. That say if external software need to link to these libs, wouldn't it be better to crank the so number each time there is a new release?
Anyway, that's not a big deal... I will keep patching locally as there is no other choice anyway.
Thanks.
Comment 16 Matthew Barnes 2012-03-28 15:33:57 UTC
At present the versioned install directory kinda fills that role... so 3.2 libs go in $(libdir)/evolution/3.2, 3.4 libs in $(libdir)/evolution/3.4, and so on.  Still, not a bad idea if it could be fully automated, which seems doable.
Comment 18 Antoine Jacoutot 2015-05-15 14:04:12 UTC
Re-adding a comment to that BZ since evolution is now installing un-versioned solibs under an un-versionned directory...
Comment 19 Milan Crha 2015-05-18 06:59:17 UTC
Evolution really never supported installing two different versions being installed at the same time at the same prefix. Consider 'evolution' in the 'bin' folder, the utilities in /usr/libexec/ or the D-Bus services.
Comment 20 Antoine Jacoutot 2015-05-18 07:09:03 UTC
(In reply to Milan Crha from comment #19)
> Evolution really never supported installing two different versions being
> installed at the same time at the same prefix. Consider 'evolution' in the
> 'bin' folder, the utilities in /usr/libexec/ or the D-Bus services.

Hi Milan.

Thanks for your answer. Sure my goal was never to install two different versions of evolution at the same time.
In fact, my "problem" is that we have tools on OpenBSD that declare automatic dependencies on libraries but there's a strict rule for that to work: libraries must be versioned.
For e.x. evolution-rss will detect automatically and tell you that it depends on evolution -- that will not work with unversioned solibs.

That's not a huge issue, merely a convenience for *us*.
Currently I am just doing what Debian does as well and locally patch evolution in our ports tree to remove -avoid-version. I just though it would cost nothing to ask whether it would be possible to do that by default since I am not aware of any other GNOME project that does that (except for gnome-builder which I also opened a BZ for).
That's all :-)
Comment 21 Michael Catanzaro 2017-05-05 20:58:21 UTC
Just found this. FWIW epiphany does this too now, because versioning private internal libraries is pointless.