Merge lp:~cjwatson/gallery-app/static-exiv2 into lp:gallery-app

Proposed by Colin Watson on 2014-07-18
Status: Merged
Approved by: Oliver Grawert on 2014-07-18
Approved revision: 1014
Merged at revision: 1016
Proposed branch: lp:~cjwatson/gallery-app/static-exiv2
Merge into: lp:gallery-app
Diff against target: 140 lines (+114/-0)
3 files modified
debian/control (+3/-0)
src/medialoader/CMakeLists.txt (+8/-0)
src/medialoader/exiv2.copyright (+103/-0)
To merge this branch: bzr merge lp:~cjwatson/gallery-app/static-exiv2
Reviewer Review Type Date Requested Status
Oliver Grawert 2014-07-18 Approve on 2014-07-18
PS Jenkins bot continuous-integration Approve on 2014-07-18
Review via email: mp+227275@code.launchpad.net

Commit message

Link exiv2 statically in click mode.

Description of the change

Link exiv2 statically in click mode.

This avoids the problem of a click package trying to use a library whose SONAME is about to change on the system image, causing synchronisation problems (can't update library without updating click package, but can't update click package without risking people downloading it from the store onto older system images). Static linking is a fairly crude solution; a better longer-term approach would be for click to (automatically?) notice this situation somehow and copy the shared libraries you need into your click package. However, that's some way off, and I think this will do for now.

Incidentally, this problem is part of the reason why gallery-app has been stuck in silo 1 for a week and a half. We won't be able to shift it until we sort this out one way or another. If you approve this branch, then it would probably be best to add it to the list of MPs in silo 1 and rebuild it there.

To post a comment you must log in.
Colin Watson (cjwatson) wrote :

There are some other libraries potentially in the same situation, by the way. I haven't touched them here since I wanted to have the simplest change I could think of that would unblock us, and exiv2 is the one whose SONAME is actually trying to change in utopic.

1014. By Colin Watson on 2014-07-18

Build-depend on libexpat1-dev and zlib1g-dev to ensure that we can statically link against libexiv2 in click mode.

Oliver Grawert (ogra) wrote :

Looks good to me ...

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/control'
--- debian/control 2014-05-09 16:08:13 +0000
+++ debian/control 2014-07-18 08:20:32 +0000
@@ -16,6 +16,9 @@
16 qtbase5-dev,16 qtbase5-dev,
17 qtdeclarative5-dev,17 qtdeclarative5-dev,
18 python3-all,18 python3-all,
19# for static linking of exiv2 in click mode
20 libexpat1-dev,
21 zlib1g-dev,
19Standards-Version: 3.9.522Standards-Version: 3.9.5
20# If you don't have commit rights to lp:gallery-app but need to upload23# If you don't have commit rights to lp:gallery-app but need to upload
21# packaging changes, just go ahead. The developers will notice and sync24# packaging changes, just go ahead. The developers will notice and sync
2225
=== modified file 'src/medialoader/CMakeLists.txt'
--- src/medialoader/CMakeLists.txt 2014-03-07 17:42:35 +0000
+++ src/medialoader/CMakeLists.txt 2014-07-18 08:20:32 +0000
@@ -35,6 +35,14 @@
3535
36qt5_use_modules(${GALLERY_MEDIALOADER_LIB} Core Quick)36qt5_use_modules(${GALLERY_MEDIALOADER_LIB} Core Quick)
3737
38if(CLICK_MODE)
39 set(EXIV2_LIBRARIES
40 ${CMAKE_EXE_LINK_STATIC_CXX_FLAGS}
41 ${EXIV2_STATIC_LIBRARIES}
42 ${CMAKE_EXE_LINK_DYNAMIC_CXX_FLAGS})
43 install(FILES exiv2.copyright DESTINATION ${CMAKE_INSTALL_PREFIX})
44endif(CLICK_MODE)
45
38target_link_libraries( ${GALLERY_MEDIALOADER_LIB}46target_link_libraries( ${GALLERY_MEDIALOADER_LIB}
39 ${EXIV2_LIBRARIES}47 ${EXIV2_LIBRARIES}
40 ${GSTLIB_LDFLAGS}48 ${GSTLIB_LDFLAGS}
4149
=== added file 'src/medialoader/exiv2.copyright'
--- src/medialoader/exiv2.copyright 1970-01-01 00:00:00 +0000
+++ src/medialoader/exiv2.copyright 2014-07-18 08:20:32 +0000
@@ -0,0 +1,103 @@
1The exiv2 library is linked statically into the gallery-app click package,
2using the version of the Ubuntu libexiv2-dev package that was installed on
3the build system at build time. Its copyright and licensing information is
4reproduced below.
5
6
7Upstream Author:
8
9 Andreas HUGGEL <ahuggel@gmx.net>
10
11Copyright:
12
13 (C) 2004-2008 Andreas Huggel <ahuggel@gmx.net>
14
15Copyright for XMP sdk:
16
17 (C) 2005-2007 Adobe Systems Incorporated
18
19Copyright for MD5 algorithm tcode:
20
21 (C) 1991-2, RSA Data Security, Inc.
22
23exiv2 license:
24
25 Exiv2 is free software; you can redistribute it and/or modify it under
26 the terms of the GNU General Public License as published by the Free
27 Software Foundation; either version 2 of the License, or (at your
28 option) any later version.
29
30 Alternatively, Exiv2 is also available with a commercial license,
31 which allows it to be used in closed-source projects. Contact me for
32 more information.
33
34 Exiv2 is distributed in the hope that it will be useful, but WITHOUT
35 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
36 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
37 for more details.
38
39 You should have received a copy of the GNU General Public License
40 along with this program; if not, write to the Free Software
41 Foundation, Inc., 51 Franklin Street, 5th Floor, Boston, MA 02110-1301 USA.
42
43On Debian systems, the complete text of the GNU General
44Public License can be found in `/usr/share/common-licenses/GPL-2'.
45
46XMP sdk license:
47
48 NOTICE: Adobe permits you to use, modify, and distribute this file in
49 accordance with the terms of the Adobe license agreement accompanying it.
50
51Copyright (c) 1999 - 2007, Adobe Systems Incorporated
52
53The BSD License
54
55Redistribution and use in source and binary forms, with or without
56modification, are permitted provided that the following conditions are
57met:
58
59* Redistributions of source code must retain the above copyright
60 notice, this list of conditions and the following disclaimer.
61
62* Redistributions in binary form must reproduce the above copyright
63 notice, this list of conditions and the following disclaimer in the
64 documentation and/or other materials provided with the distribution.
65
66* Neither the name of Adobe Systems Incorporated, nor the names of its
67 contributors may be used to endorse or promote products derived from
68 this software without specific prior written permission.
69
70THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
71"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
72LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
73A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
74OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
75SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
76LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
77DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
78THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
79(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
80OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
81
82MD5 algorithm license:
83
84Copyright (C) 1991-2, RSA Data Security, Inc.
85
86License to copy and use this software is granted provided that it is
87identified as the "RSA Data Security, Inc. MD5 Message-Digest
88Algorithm" in all material mentioning or referencing this software or
89this function.
90
91License is also granted to make and use derivative works provided that
92such works are identified as "derived from the RSA Data Security,
93Inc. MD5 Message-Digest Algorithm" in all material mentioning or
94referencing the derived work.
95
96RSA Data Security, Inc. makes no representations concerning either the
97merchantability of this software or the suitability of this software
98for any particular purpose. It is provided "as is" without express or
99implied warranty of any kind.
100
101These notices must be retained in any copies of any part of this
102documentation and/or software.
103

Subscribers

People subscribed via source and target branches