Merge lp:~racb/ubuntu/oneiric/uw-imap/831228 into lp:ubuntu/oneiric/uw-imap

Proposed by Robie Basak
Status: Work in progress
Proposed branch: lp:~racb/ubuntu/oneiric/uw-imap/831228
Merge into: lp:ubuntu/oneiric/uw-imap
Diff against target: 157 lines (+42/-29) (has conflicts)
2 files modified
debian/changelog (+10/-0)
debian/patches/1001_shlibs.patch (+32/-29)
Text conflict in debian/changelog
To merge this branch: bzr merge lp:~racb/ubuntu/oneiric/uw-imap/831228
Reviewer Review Type Date Requested Status
Dave Walker Pending
Review via email: mp+74589@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Dave Walker (davewalker) wrote :

Looks good.

Ideally, we'd like to introduce a new patch incase the edited patch isn't accepted by debian, it makes merging easier next cycle.

You probably don't need to quote http://wiki.debian.org/ToolChain/DSOLinking, as it's understood --as-needed is enough.

I need to build test this first, but generally happy. If you are confident this is a good fix, do you want to use the "submittodebian" tool?

Thanks

16. By Robie Basak

Fix libc-client.so.2007e.0 dependencies to build correctly with
-Wl,--as-needed. (LP: #831228)

Revision history for this message
Robie Basak (racb) wrote :

Upstream doesn't appear to support the creation of shared objects in its build system.

The build system does allow a platform specific "ar" call to create static objects by setting a variable. This assumes that the output filename is goes after the contents of the variable.

The Debian package hacks the build system by using a call to gcc as the "ar" call for a new shared object platform type. This ends in "-o" to fulfil the requirement that the output filename will go after it.

This makes it necessary to modify this hack further to move the "-o output_filename" further back to fix the --as-needed bug, so it makes sense to modify the existing Debian patch rather than create a new one. Given that the existing patch is a hack already, I can't see a cleaner way of fixing this except to change more of the upstream build system which would be too invasive. Hopefully Debian will find this acceptable.

Revision history for this message
Colin Watson (cjwatson) wrote :

FWIW it doesn't matter where '-o output_filename' goes; what matters is
the relative positioning of input objects and the libraries they depend
on.

Unmerged revisions

16. By Robie Basak

Fix libc-client.so.2007e.0 dependencies to build correctly with
-Wl,--as-needed. (LP: #831228)

15. By Robie Basak

Fix libc-client.so.2007e.0 dependencies as caused by Ubuntu's
-Wl,--as-needed default.
See: http://wiki.debian.org/ToolChain/DSOLinking (LP: #831228)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2011-09-13 22:53:14 +0000
3+++ debian/changelog 2011-09-16 12:21:25 +0000
4@@ -1,3 +1,4 @@
5+<<<<<<< TREE
6 uw-imap (8:2007e~dfsg-3.1ubuntu4) oneiric; urgency=low
7
8 * Resolve unresolved symbols in shared libraries. Closes: #558968.
9@@ -5,6 +6,15 @@
10
11 -- Matthias Klose <doko@ubuntu.com> Tue, 13 Sep 2011 22:53:14 +0000
12
13+=======
14+uw-imap (8:2007e~dfsg-3.1ubuntu4) oneiric; urgency=low
15+
16+ * Fix libc-client.so.2007e.0 dependencies to build correctly with
17+ -Wl,--as-needed. (LP: #831228)
18+
19+ -- Robie Basak <robie.basak@ubuntu.com> Tue, 13 Sep 2011 13:38:07 +0100
20+
21+>>>>>>> MERGE-SOURCE
22 uw-imap (8:2007e~dfsg-3.1ubuntu3) oneiric; urgency=low
23
24 * Apply patch from Vladimir Kolesnikov to properly zero out len
25
26=== modified file 'debian/patches/1001_shlibs.patch'
27--- debian/patches/1001_shlibs.patch 2008-08-22 09:57:49 +0000
28+++ debian/patches/1001_shlibs.patch 2011-09-16 12:21:25 +0000
29@@ -1,6 +1,5 @@
30-diff -ruN uw-imap-2006k~dfsg.orig/Makefile uw-imap-2006k~dfsg/Makefile
31---- uw-imap-2006k~dfsg.orig/Makefile 2007-11-08 00:16:50.000000000 +0100
32-+++ uw-imap-2006k~dfsg/Makefile 2007-12-10 15:58:39.000000000 +0100
33+--- a/Makefile
34++++ b/Makefile
35 @@ -78,11 +78,13 @@
36 # hxd HP-UX 10.x with DCE security (see shp)
37 # isc Interactive Systems
38@@ -35,9 +34,8 @@
39 lmd: an
40 $(BUILD) BUILDTYPE=lnp IP=$(IP6) \
41 SPECIALS="SSLINCLUDE=/usr/include/openssl SSLLIB=/usr/lib SSLCERTS=/usr/lib/ssl/certs SSLKEYS=/usr/lib/ssl/private GSSINCLUDE=/usr/include GSSLIB=/usr/lib"
42-diff -ruN uw-imap-2006k~dfsg.orig/src/dmail/Makefile uw-imap-2006k~dfsg/src/dmail/Makefile
43---- uw-imap-2006k~dfsg.orig/src/dmail/Makefile 2007-09-11 01:56:35.000000000 +0200
44-+++ uw-imap-2006k~dfsg/src/dmail/Makefile 2007-12-10 16:00:26.000000000 +0100
45+--- a/src/dmail/Makefile
46++++ b/src/dmail/Makefile
47 @@ -26,7 +26,7 @@
48
49
50@@ -65,9 +63,8 @@
51 clean:
52 rm -f *.o dmail
53
54-diff -ruN uw-imap-2006d.dfsg.orig/src/imapd/Makefile uw-imap-2006d.dfsg/src/imapd/Makefile
55---- uw-imap-2006d.dfsg.orig/src/imapd/Makefile 2006-08-31 02:10:44.000000000 +0200
56-+++ uw-imap-2006d.dfsg/src/imapd/Makefile 2006-12-19 22:11:49.000000000 +0100
57+--- a/src/imapd/Makefile
58++++ b/src/imapd/Makefile
59 @@ -43,12 +43,12 @@
60 # Get local definitions from c-client directory
61
62@@ -83,9 +80,8 @@
63
64 all: imapd
65
66-diff -ruN uw-imap-2006d.dfsg.orig/src/ipopd/Makefile uw-imap-2006d.dfsg/src/ipopd/Makefile
67---- uw-imap-2006d.dfsg.orig/src/ipopd/Makefile 2006-08-31 02:17:30.000000000 +0200
68-+++ uw-imap-2006d.dfsg/src/ipopd/Makefile 2006-12-19 22:11:49.000000000 +0100
69+--- a/src/ipopd/Makefile
70++++ b/src/ipopd/Makefile
71 @@ -26,14 +26,14 @@
72
73
74@@ -103,9 +99,8 @@
75
76 ipopd: ipop2d ipop3d
77
78-diff -ruN uw-imap-2006d.dfsg.orig/src/mailutil/Makefile uw-imap-2006d.dfsg/src/mailutil/Makefile
79---- uw-imap-2006d.dfsg.orig/src/mailutil/Makefile 2006-08-31 02:21:20.000000000 +0200
80-+++ uw-imap-2006d.dfsg/src/mailutil/Makefile 2006-12-19 22:11:49.000000000 +0100
81+--- a/src/mailutil/Makefile
82++++ b/src/mailutil/Makefile
83 @@ -26,7 +26,7 @@
84
85
86@@ -131,9 +126,8 @@
87 clean:
88 rm -f *.o mailutil
89
90-diff -ruN uw-imap-2006d.dfsg.orig/src/mtest/Makefile uw-imap-2006d.dfsg/src/mtest/Makefile
91---- uw-imap-2006d.dfsg.orig/src/mtest/Makefile 2006-08-31 02:25:07.000000000 +0200
92-+++ uw-imap-2006d.dfsg/src/mtest/Makefile 2006-12-19 22:11:49.000000000 +0100
93+--- a/src/mtest/Makefile
94++++ b/src/mtest/Makefile
95 @@ -26,7 +26,7 @@
96
97
98@@ -159,10 +153,17 @@
99 clean:
100 rm -f *.o mtest || true
101
102-diff -ruN uw-imap-2006d.dfsg.orig/src/osdep/unix/Makefile uw-imap-2006d.dfsg/src/osdep/unix/Makefile
103---- uw-imap-2006d.dfsg.orig/src/osdep/unix/Makefile 2006-12-08 02:24:54.000000000 +0100
104-+++ uw-imap-2006d.dfsg/src/osdep/unix/Makefile 2006-12-19 22:13:10.000000000 +0100
105-@@ -490,7 +490,19 @@
106+--- a/src/osdep/unix/Makefile
107++++ b/src/osdep/unix/Makefile
108+@@ -130,6 +130,7 @@
109+ # Commands possibly overriden by the individual port
110+
111+ ARRC=ar rc
112++ARRC_POST_FLAGS=
113+ CC=cc
114+ LN=ln -s
115+ RANLIB=ranlib
116+@@ -490,7 +491,20 @@
117 ACTIVEFILE=/var/lib/news/active \
118 RSHPATH=/usr/bin/rsh \
119 BASECFLAGS="$(GCCCFLAGS)" \
120@@ -178,12 +179,13 @@
121 + BASECFLAGS="-fPIC $(GCCCFLAGS)" \
122 + ARCHIVE="libc-client.so" \
123 + BASELDFLAGS="-L../c-client -lc-client $(PAMLDFLAGS) -lc" \
124-+ ARRC="gcc --shared -Wl,-soname,libc-client.so.$(VERSION) $(PAMLDFLAGS) -lc $(EXTRALDFLAGS) $(SSLLDFLAGS) -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -o" \
125++ ARRC="gcc --shared -Wl,-soname,libc-client.so.$(VERSION) -o" \
126++ ARRC_POST_FLAGS="$(PAMLDFLAGS) -lc $(EXTRALDFLAGS) $(SSLLDFLAGS) -lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err" \
127 + RANLIB=true
128
129 lnx: # Linux non-shadow passwords
130 @echo You are building for traditional Linux *without* shadow
131-@@ -861,7 +873,7 @@
132+@@ -861,7 +875,7 @@
133 # Cleanup
134
135 clean:
136@@ -192,17 +194,18 @@
137
138
139 # Dependencies
140-@@ -969,6 +981,7 @@
141+@@ -968,7 +982,8 @@
142+ -DLOCKPGM1=\"$(LOCKPGM1)\" -DLOCKPGM2=\"$(LOCKPGM2)\" \
143 -DLOCKPGM3=\"$(LOCKPGM3)\" > OSCFLAGS
144 echo $(BASELDFLAGS) $(EXTRALDFLAGS) > LDFLAGS
145- echo "$(ARRC) $(ARCHIVE) $(BINARIES);$(RANLIB) $(ARCHIVE)" > ARCHIVE
146+- echo "$(ARRC) $(ARCHIVE) $(BINARIES);$(RANLIB) $(ARCHIVE)" > ARCHIVE
147++ echo "$(ARRC) $(ARCHIVE) $(BINARIES) $(ARRC_POST_FLAGS);$(RANLIB) $(ARCHIVE)" > ARCHIVE
148 + echo $(ARCHIVE) > ARCHIVENAME
149 echo $(OS) > OSTYPE
150 ./drivers $(EXTRADRIVERS) $(DEFAULTDRIVERS) dummy
151 ./mkauths $(EXTRAAUTHENTICATORS) $(DEFAULTAUTHENTICATORS)
152-diff -ruN uw-imap-2006k~dfsg.orig/src/tmail/Makefile uw-imap-2006k~dfsg/src/tmail/Makefile
153---- uw-imap-2006k~dfsg.orig/src/tmail/Makefile 2007-12-10 16:26:58.000000000 +0100
154-+++ uw-imap-2006k~dfsg/src/tmail/Makefile 2007-12-10 16:28:07.000000000 +0100
155+--- a/src/tmail/Makefile
156++++ b/src/tmail/Makefile
157 @@ -26,7 +26,7 @@
158
159

Subscribers

People subscribed via source and target branches

to all changes: