View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0002075 | SOGo | SOPE | public | 2012-10-26 10:32 | 2012-11-18 13:06 |
Reporter | buzzdee | Assigned To | |||
Priority | normal | Severity | minor | Reproducibility | always |
Status | closed | Resolution | fixed | ||
Product Version | 2.0.2 | ||||
Target Version | 2.0.3 | Fixed in Version | 2.0.3 | ||
Summary | 0002075: fix for bug reports 0001615 and 0001616 break building on OpenBSD | ||||
Description | Hi, the fixes to the bugs mentioned above contradict somehow my work ;) ifeq ($(findstring openbsd, $(GNUSTEP_HOST_OS)), openbsd) so the -ldl could be added to the line in the else part, not disturbing OpenBSD. further all patches add unconditional linking against -lobjc. In bug 2030 On OpenBSD, the libobjc.so.X.X is installed as libobjc2.so.X.X I don't know how to go on with that. Either remove this -lobjc again, what I would prefer, or have using a variable i.e. OBJCLIB=-lobjc which goes into the then its easy for me, and maybe others to override for me on the command line: make OBCLIB=-lobjc2 and I should get it right for me Let me know how to proceed here. | ||||
Tags | No tags attached. | ||||
Well, the act of linking against libobj should definitely be performed by gcc and from gnustep-make (at worse). And you are right: they have been put back. Let me get back to you. |
|
Even when I don't have the -lobjc in the GNUmakefiles, I see when it comes to the linking stage the -lobjc2 automatically added. The same should be true for others having the -lobjc as default. gnustep-make should take care of that automagically. Also, running ldd on the libraries, I see them being linked against libobjc2 in my case. Sebastian |
|
I don't really understand why libobjc is installed as libobjc2, because the whole point of the version number at the end of the filename of libraries is that you can install for example libobjc.so.1 and libobjc.so.2 at the same time... With regards to whether or not to link with libobjc: if I run objdump on libSOGo.so I see that it uses at least three methods from libobjc directly (objc_get_class, objc_msg_lookup, objc_msg_lookup_super), so it should link with libobjc. Whether this linking is specified by gcc, gnustep or directly in the makefile doesn't really matter much, but if a library uses symbols from a different library it needs to link against it. With regards to -ldl we should only link to that for the platforms that need it, that should be an easy fix. |
|
Dekkers: (as mentionned on irc) It should not beneeded to specify it from the makefiles, because gcc "knows" which runtime library it uses. A makefile should not bother with this. the same way that issuing "gcc test.c -o test" will automatically link your program with the right libc. |
|
Buzzdee: which version of gnustep-make are you using? |
|
Latest release: 2.6.2 @Dekkers: why its installed as libobjc? reason is just that it was decided that way when the libobjc2 port was introduced, to for example not clash at some point in time with system libobjc (in /usr/lib), or libobjc from a gcc port in /usr/local/lib. gnustep-make is configured with parameter: --with-objc-lib-flag=-lobjc2 So whenever it links something, it automatically adds -lobjc2 instead of adding -lobjc, which is the default. I think with the current GMakefiles, you see the -lobjc two times in the gcc parameters? Since GNUstep Make takes care to link against the right runtime, there should be no need to tinker in GNUmakefiles with it. |
|
I just tested on Ubuntu 12.10 and I only see it once when linking libSOGo.so, somehow gnustep-make doesn't care of it on Debian/Ubuntu... |
|
Then, maybe in configure stage, the libraries needed could be determined automatically and saved in a variable. I remembered, Richard did the something similar for gnustep-base. In gnustep-base there was also -lobjc hardcoded, he changed it to use gnustep-config --objc-libs. For me on OpenBSD this prints out: or on an older system, linking against -lobjc from gcc, it prints: This could be saved in a variable, and used all over the place, instead of the hardcoded information. This way SOPE/SOGo should get it always right. So how about that one then? |
|
I don't have any problem with replacing the explicit linking with the output of gnustep-config --base-libs. |
|
This has now been done. |
|
Hi, I found a similar issue with gnustep's SQLClient library. They just fixed it after my report with exchanging: Those two variables are defined in makefiles that get installed with gnustep-make and gnustep-base. I wasn't aware of those variables before, but I think now this would be the cleanest way to link against gnustep base and libobjc, when desired. |
|
With the changes from comment 0004788, are we now all set with that bug and can close it? |
|
From my side, yes, even given I did not checked what you have done when you said its fixed. A link to the git was missing ;) |
|
We now use "gnustep-config --base-libs" in both SOGo and SOPE's configure scripts. |
|
Date Modified | Username | Field | Change |
---|---|---|---|
2012-10-26 10:32 | buzzdee | New Issue | |
2012-10-26 17:29 |
|
Note Added: 0004717 | |
2012-10-26 17:29 |
|
Status | new => confirmed |
2012-10-26 17:29 |
|
Status | confirmed => assigned |
2012-10-26 17:29 |
|
Assigned To | => wsourdeau |
2012-10-26 17:56 | buzzdee | Note Added: 0004718 | |
2012-10-26 18:06 | dekkers | Note Added: 0004720 | |
2012-10-26 18:08 |
|
Note Added: 0004721 | |
2012-10-26 18:09 |
|
Note Added: 0004722 | |
2012-10-26 22:09 | buzzdee | Note Added: 0004724 | |
2012-10-26 23:17 | dekkers | Note Added: 0004725 | |
2012-10-28 09:03 | buzzdee | Note Added: 0004728 | |
2012-10-29 15:47 |
|
Target Version | => 2.0.3 |
2012-11-01 16:26 | dekkers | Note Added: 0004766 | |
2012-11-07 15:14 |
|
Note Added: 0004788 | |
2012-11-07 15:14 |
|
Status | assigned => resolved |
2012-11-07 15:14 |
|
Fixed in Version | => 2.0.3 |
2012-11-07 15:14 |
|
Resolution | open => fixed |
2012-11-10 15:10 | buzzdee | Note Added: 0004821 | |
2012-11-10 15:10 | buzzdee | Status | resolved => feedback |
2012-11-10 15:10 | buzzdee | Resolution | fixed => reopened |
2012-11-17 21:28 | ludovic | Note Added: 0004872 | |
2012-11-18 07:11 | buzzdee | Note Added: 0004877 | |
2012-11-18 13:06 | ludovic | Note Added: 0004879 | |
2012-11-18 13:06 | ludovic | Status | feedback => closed |
2012-11-18 13:06 | ludovic | Resolution | reopened => fixed |