Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 285305 - =sys-cluster/heartbeat-2.0.8 -Wl,--as-needed patch required
Summary: =sys-cluster/heartbeat-2.0.8 -Wl,--as-needed patch required
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High major (vote)
Assignee: Gentoo Cluster Team
URL:
Whiteboard:
Keywords: QAcanfix
Depends on:
Blocks:
 
Reported: 2009-09-17 11:25 UTC by Marcin Mirosław
Modified: 2010-09-10 18:51 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (emerge.info,4.10 KB, text/plain)
2009-09-17 11:26 UTC, Marcin Mirosław
Details
adding patches (heartbeat-2.0.8.diff,593 bytes, patch)
2009-09-17 19:20 UTC, Kacper Kowalik (Xarthisius) (RETIRED)
Details | Diff
Fixing glib issue (heartbeat-2.0.8-glib-2.10.patch,438 bytes, patch)
2009-09-17 19:21 UTC, Kacper Kowalik (Xarthisius) (RETIRED)
Details | Diff
fixing as-needed issues (heartbeat-2.0.8-as-needed.patch,2.98 KB, patch)
2009-09-17 19:23 UTC, Kacper Kowalik (Xarthisius) (RETIRED)
Details | Diff
Failed as-needed Patch (heartbeat-2.0.8-as-needed.patch-5386.out,2.92 KB, text/plain)
2009-10-15 01:08 UTC, VinnieNZ
Details
fixing as-needed issues (heartbeat-2.0.8-as-needed.patch,2.54 KB, patch)
2009-11-18 17:27 UTC, Kacper Kowalik (Xarthisius) (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marcin Mirosław 2009-09-17 11:25:20 UTC
gcc -DHAVE_CONFIG_H -I. -I. -I../../linux-ha -I../../include -I../../include -I../../include -I../../linux-ha -I../../linux-ha -I../../libltdl -I../../libltdl -D_BSD_SOURCE -D__BSD_SOURCE -D__FAVOR_BSD -DHAVE_NET_ETHERNET_H -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/libxml2 -O2 -march=prescott -mfpmath=sse -fpeel-loops -fprefetch-loop-arrays -pipe -Wall -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wdeclaration-after-statement -Wpointer-arith -Wwrite-strings -Wcast-qual -Wcast-align -Wbad-function-cast -Winline -Wmissing-format-attribute -Wformat=2 -Wformat-security -Wformat-nonliteral -Wno-long-long -Wno-strict-aliasing -ggdb3 -funsigned-char -DALIGNFUNC= -DMSGHDR_TYPE=msghdr -DHALIB=\"/usr/lib/heartbeat\" -O2 -march=prescott -mfpmath=sse -fpeel-loops -fprefetch-loop-arrays -pipe -Wall -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes -Wdeclaration-after-statement -Wpointer-arith -Wwrite-strings -Wcast-qual -Wcast-align -Wbad-function-cast -Winline -Wmissing-format-attribute -Wformat=2 -Wformat-security -Wformat-nonliteral -Wno-long-long -Wno-strict-aliasing -ggdb3 -funsigned-char -MT cl_msg.lo -MD -MP -MF .deps/cl_msg.Tpo -c cl_msg.c  -fPIC -DPIC -o .libs/cl_msg.o                  
In file included from /usr/include/fcntl.h:218,                                                                                             
                 from ../../include/ha_msg.h:35,                                                                                            
                 from cl_msg.c:33:                                                                                                          
In function 'open',
    inlined from 'cl_msg_stats_open' at cl_msg.c:149,
    inlined from 'cl_msg_stats_add' at cl_msg.c:173:
/usr/include/bits/fcntl2.h:51: error: call to '__open_missing_mode' declared with attribute error: open with O_CREAT in second argument needs 3 arguments
gmake[2]: *** [cl_msg.lo] Error 1
gmake[2]: Leaving directory `/var/tmp/portage/sys-cluster/heartbeat-2.0.8/work/heartbeat-2.0.8/lib/clplumbing'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/var/tmp/portage/sys-cluster/heartbeat-2.0.8/work/heartbeat-2.0.8/lib'
make: *** [all-recursive] Error 1
 *
 * ERROR: sys-cluster/heartbeat-2.0.8 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_compile
 *             environment, line 2536:  Called die
 * The specific snippet of code:
 *       emake -j 1 || die "compile problem"
 *  The die message:
 *   compile problem


I tried to use ebuild from bug #231291 but error is still the same.

Reproducible: Always

Steps to Reproduce:
1. emerge =sys-cluster/heartbeat-2.0.8
2.
3.

Actual Results:  
Fail to compile.

Expected Results:  
Compile and install.
Comment 1 Marcin Mirosław 2009-09-17 11:26:20 UTC
Created attachment 204409 [details]
emerge --info
Comment 2 Marcin Mirosław 2009-09-17 13:30:36 UTC
This bug is related to gcc-4.4.1
Comment 3 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2009-09-17 19:20:33 UTC
Created attachment 204459 [details, diff]
adding patches
Comment 4 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2009-09-17 19:21:26 UTC
Created attachment 204461 [details, diff]
Fixing glib issue
Comment 5 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2009-09-17 19:23:01 UTC
Created attachment 204462 [details, diff]
fixing as-needed issues
Comment 6 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2009-09-17 19:23:52 UTC
(In reply to comment #3)
> Created an attachment (id=204459) [edit]
> adding patches

It also fixes #285315

Comment 7 Marcin Mirosław 2009-09-18 08:13:33 UTC
It works for me, and fix booth bugs.
Comment 8 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2009-09-18 11:53:29 UTC
(In reply to comment #7)
> It works for me, and fix booth bugs.
I've tested this build with no USE flags, and only compilation/merge. It would be nice if somebody would test it in a working environment.

Furthermore we should bump heartbeat to 2.1.4, which AFAIK is the last version before significant changes.
(see http://linux-ha.org/NewHeartbeatDesign )

Comment 9 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2009-09-18 21:29:45 UTC
(In reply to comment #8)
> Furthermore we should bump heartbeat to 2.1.4, which AFAIK is the last version
> before significant changes.
> (see http://linux-ha.org/NewHeartbeatDesign )

Attached version bump (2.1.4) to bug #202893. All the issues (apart from as-needed) since 2.0.8 were fixed in that release.
Comment 10 Marcin Mirosław 2009-09-28 08:05:53 UTC
(In reply to comment #8)
> (In reply to comment #7)
> > It works for me, and fix booth bugs.
> I've tested this build with no USE flags, and only compilation/merge. It would
> be nice if somebody would test it in a working environment.

I've been testing HB-2.0.8 in live enviroment. I've made a simply test: restart machine A , and next restart host B. It seems to work correctly.
Comment 11 Marcin Mirosław 2009-10-10 10:48:27 UTC
Maybe fixed heartbeat-2.0.8 should be included in portage without waiting for working ebuild for heartbeat-2.1.4?
Comment 12 VinnieNZ 2009-10-15 01:08:50 UTC
Created attachment 207175 [details]
Failed as-needed Patch

I can't make the heartbeat-2.0.8-as-needed.patch work.

I've copied the heartbeat-2.0.8.ebuild file across to /usr/local/portage/sys-cluster/heartbeat and made the changes to it required.  I've created the files directory and copied the old patches across to it and stuck the new ones in there.

Whenever I compile it I get the following error:
 * Failed Patch: heartbeat-2.0.8-as-needed.patch !
 *  ( /usr/local/portage/sys-cluster/heartbeat/files/heartbeat-2.0.8-as-needed.patch )
 *
 * Include in your bugreport the contents of:
 *
 *   /var/tmp/portage/sys-cluster/heartbeat-2.0.8/temp/heartbeat-2.0.8-as-needed.patch-5386.out

 *
 * ERROR: sys-cluster/heartbeat-2.0.8 failed.
 * Call stack:
 *               ebuild.sh, line   49:  Called src_unpack
 *             environment, line 2575:  Called epatch '/usr/local/portage/sys-cluster/heartbeat/files/heartbeat-2.0.8-as-needed.patch'
 *             environment, line 1235:  Called die
 * The specific snippet of code:
 *                   die "Failed Patch: ${patchname}!";
 *  The die message:
 *   Failed Patch: heartbeat-2.0.8-as-needed.patch!
 *
 * If you need support, post the topmost build error, and the call stack if relevant.
 * A complete build log is located at '/var/tmp/portage/sys-cluster/heartbeat-2.0.8/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-cluster/heartbeat-2.0.8/temp/environment'.
 * This ebuild is from an overlay: '/usr/local/portage/'



I've attached the .out file as requested also
Comment 13 VinnieNZ 2009-10-15 02:50:29 UTC
Urgh, my bad, downloaded the same patch twice.  Please ignore the above.
Comment 14 Marcin Mirosław 2009-11-06 13:22:12 UTC
Is any reason to not commit this fixes?
Comment 15 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2009-11-06 14:16:16 UTC
(In reply to comment #14)
> Is any reason to not commit this fixes?
Problem is that HA-cluster is MIA. Simply, there is nobody to do it.
Comment 16 Marcin Mirosław 2009-11-06 14:52:49 UTC
Sometimes i regret that i chose this distribution. Sorry for spam.
Comment 17 Samuli Suominen (RETIRED) gentoo-dev 2009-11-18 16:41:11 UTC
The as-needed patch is invalid, should be patching Makefile.am instead of Makefile.in.

Once you, the maintainers, have fixed that, remove the append-ldflags (no-as-needed) hack. 

I had to step in because the current one didn't compile at all, and users came to me directly (for whatever reason).

As in, this bug is not properly fixed, only to the extend that there is something that builds.
Comment 18 Kacper Kowalik (Xarthisius) (RETIRED) gentoo-dev 2009-11-18 17:27:18 UTC
Created attachment 210581 [details, diff]
fixing as-needed issues

using autotools now
Comment 19 Samuli Suominen (RETIRED) gentoo-dev 2009-11-18 17:36:26 UTC
   18 Nov 2009; Samuli Suominen <ssuominen@gentoo.org>
+  heartbeat-2.0.8.ebuild, +files/heartbeat-2.0.8-asneeded.patch:
+  Fix building with -Wl,--as-needed wrt #285305, thanks to Kacper Kowalik.