Gentoo Archives: gentoo-commits

From: Justin Lecher <jlec@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-block/thin-provisioning-tools/files/, sys-block/thin-provisioning-tools/
Date: Wed, 28 Dec 2016 10:47:09
Message-Id: 1482922022.a121971a2a828064776d338ed771bdfc5b852052.jlec@gentoo
1 commit: a121971a2a828064776d338ed771bdfc5b852052
2 Author: Justin Lecher <jlec <AT> gentoo <DOT> org>
3 AuthorDate: Wed Dec 28 10:45:36 2016 +0000
4 Commit: Justin Lecher <jlec <AT> gentoo <DOT> org>
5 CommitDate: Wed Dec 28 10:47:02 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a121971a
7
8 sys-block/thin-provisioning-tools: Version Bump and Fixes for gcc-6
9
10 Thanks Jon for the ebuild and patch
11
12 Gentoo-Bug: https://bugs.gentoo.org/show_bug.cgi?id=598424
13
14 Package-Manager: Portage-2.3.3, Repoman-2.3.1
15 Signed-off-by: Justin Lecher <jlec <AT> gentoo.org>
16
17 sys-block/thin-provisioning-tools/Manifest | 1 +
18 ...thin-provisioning-tools-0.6.3-build-fixes.patch | 57 ++++++++++++++++++++
19 sys-block/thin-provisioning-tools/metadata.xml | 22 ++++----
20 .../thin-provisioning-tools-0.6.3.ebuild | 60 ++++++++++++++++++++++
21 4 files changed, 129 insertions(+), 11 deletions(-)
22
23 diff --git a/sys-block/thin-provisioning-tools/Manifest b/sys-block/thin-provisioning-tools/Manifest
24 index 5ab8254..037df3a 100644
25 --- a/sys-block/thin-provisioning-tools/Manifest
26 +++ b/sys-block/thin-provisioning-tools/Manifest
27 @@ -1,3 +1,4 @@
28 DIST thin-provisioning-tools-0.4.1.tar.gz 186979 SHA256 59c8a787df8d4828bf9ca1b6310584f2b7723068901e20aa609015ce85df1d46 SHA512 e148296b55f7ff4ab85dc3b4679c7eab0ee8d56e61415397fc2e46f17bcc16a6a582c17343381320f8582bc4f12311af622d43aabe60e7abb25a882446016b7e WHIRLPOOL a7e5da6879dfdc64d5e60e9072d43db21fb8f328d268366a6e4892cad9b2d55e907d564240f9bd67da0d726d80eab9d45e151bbe6d89272887703a8ae8b66c8c
29 DIST thin-provisioning-tools-0.5.3.tar.gz 191431 SHA256 6d6856dbca2f0fcf23ece171a8e68a4a7054350a3810958da37615358695597e SHA512 c36f85fc59b98195b7b6fa635b0d18da06b5798d735887dfa3af96bf6fa88bac0d353968ceae00de5960eb5360db70bc166fdd254a88b2246c36f6868c190e6d WHIRLPOOL cc85ff4c0bd0a9f7010bbbdfb9e9dd08d9dd1370ce5ca6ebc60626e05a2bfc52dec187dca546a8e6f4d9eb5dc786ea7063322b1b2bbfaec7cd022022fe428c3f
30 DIST thin-provisioning-tools-0.6.1.tar.gz 197190 SHA256 4e7bf95e05176660250b63a5b26245d199a8510e1fede7287612c95aa54cc3f0 SHA512 7db37ac325fdecf69157896333fdd1b48b33c1a0bcf6b810b68be1ea2eb4dcd658db7ad668c3920ffb958527a5f75bd742f9fc0bc408a0858a8c5cb96ccde9d5 WHIRLPOOL d5fe4ae278bc9552259b628566505e145eed8ece77809986fff1f01be2d96240649f7f142537ff2217ac11e9470380cfa461f1cc44d5e5120c8584c4299c3b59
31 +DIST thin-provisioning-tools-0.6.3.tar.gz 198697 SHA256 52d808c29dcaa83c142ceb2b418d01e9423811b082eff63fa0336bb7f0590c45 SHA512 ccebf5bb1ac2da56a3dab5b7ce8d61f6a71f84b5168c2680618d724340bbf8cf97c935c1bce966a296331d9dc048a855d81775d2a39f10b4096ab3ee835286d9 WHIRLPOOL b83c0aa081a27bfd0652d3d2d9786849e998487ce70864b8996b1e5f780b56753e52fa6a3243f62183692d9393643a0a30978069672fd4272e692dea98b93d88
32
33 diff --git a/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-0.6.3-build-fixes.patch b/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-0.6.3-build-fixes.patch
34 new file mode 100644
35 index 00000000..ae1148a
36 --- /dev/null
37 +++ b/sys-block/thin-provisioning-tools/files/thin-provisioning-tools-0.6.3-build-fixes.patch
38 @@ -0,0 +1,57 @@
39 +diff -purN a/Makefile.in b/Makefile.in
40 +--- a/Makefile.in 2016-07-21 15:42:52.000000000 +0100
41 ++++ b/Makefile.in 2016-10-28 22:45:54.292931031 +0100
42 +@@ -108,7 +108,7 @@ CFLAGS?=@CFLAGS@
43 + CFLAGS+=-Wall
44 + CFLAGS+=@LFS_FLAGS@
45 + CXXFLAGS?=@CXXFLAGS@
46 +-CXXFLAGS+=-Wall -fno-strict-aliasing -std=gnu++98
47 ++CXXFLAGS+=-Wall -fno-strict-aliasing
48 + CXXFLAGS+=@CXXOPTIMISE_FLAG@
49 + CXXFLAGS+=@CXXDEBUG_FLAG@
50 + CXXFLAGS+=@CXX_STRERROR_FLAG@
51 +diff -purN a/thin-provisioning/restore_emitter.cc b/thin-provisioning/restore_emitter.cc
52 +--- a/thin-provisioning/restore_emitter.cc 2016-07-21 15:42:52.000000000 +0100
53 ++++ b/thin-provisioning/restore_emitter.cc 2016-10-28 22:49:32.662189111 +0100
54 +@@ -142,7 +142,7 @@ namespace {
55 + bool device_exists(thin_dev_t dev) const {
56 + uint64_t key[1] = {dev};
57 + device_tree::maybe_value v = md_->details_->lookup(key);
58 +- return v;
59 ++ return v.is_initialized();
60 + }
61 +
62 + metadata::ptr md_;
63 +diff -purN a/thin-provisioning/thin_pool.cc b/thin-provisioning/thin_pool.cc
64 +--- a/thin-provisioning/thin_pool.cc 2016-07-21 15:42:52.000000000 +0100
65 ++++ b/thin-provisioning/thin_pool.cc 2016-10-28 22:50:26.999256645 +0100
66 +@@ -232,7 +232,7 @@ bool
67 + thin_pool::device_exists(thin_dev_t dev) const
68 + {
69 + uint64_t key[1] = {dev};
70 +- return md_->details_->lookup(key);
71 ++ return md_->details_->lookup(key).is_initialized();
72 + }
73 +
74 + //----------------------------------------------------------------
75 +diff -purN a/unit-tests/Makefile.in b/unit-tests/Makefile.in
76 +--- a/unit-tests/Makefile.in 2016-07-21 15:42:52.000000000 +0100
77 ++++ b/unit-tests/Makefile.in 2016-10-28 22:45:20.985893955 +0100
78 +@@ -25,7 +25,7 @@ GMOCK_FLAGS=\
79 + -Wno-unused-local-typedefs
80 +
81 + GMOCK_LIBS=\
82 +- -Llib -lpdata -lgmock -lpthread -laio
83 ++ -Llib -lpdata -lgmock -lpthread -laio -lgtest
84 +
85 + GMOCK_DEPS=\
86 + $(wildcard $(GMOCK_DIR)/include/*.h) \
87 +@@ -80,7 +80,7 @@ TEST_OBJECTS=$(subst .cc,.gmo,$(TEST_SOU
88 + sed 's,\([^ :]*\)\.o[ :]*,\1.o \1.gmo $* : Makefile ,g' < $*.$$$$ > $*.d; \
89 + $(RM) $*.$$$$
90 +
91 +-unit-tests/unit_tests: $(TEST_OBJECTS) lib/libgmock.a lib/libpdata.a
92 ++unit-tests/unit_tests: $(TEST_OBJECTS) lib/libpdata.a
93 + @echo " [LD] $<"
94 + $(V)g++ $(CXXFLAGS) $(LDFLAGS) -o $@ $(TEST_OBJECTS) $(LIBS) $(GMOCK_LIBS) $(LIBEXPAT)
95 +
96
97 diff --git a/sys-block/thin-provisioning-tools/metadata.xml b/sys-block/thin-provisioning-tools/metadata.xml
98 index dafa005..24ce9f1 100644
99 --- a/sys-block/thin-provisioning-tools/metadata.xml
100 +++ b/sys-block/thin-provisioning-tools/metadata.xml
101 @@ -1,17 +1,17 @@
102 <?xml version="1.0" encoding="UTF-8"?>
103 <!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
104 <pkgmetadata>
105 -<maintainer type="person">
106 - <email>robbat2@g.o</email>
107 -</maintainer>
108 -<maintainer type="project">
109 - <email>base-system@g.o</email>
110 - <name>Gentoo Base System</name>
111 -</maintainer>
112 -<longdescription lang="en">
113 + <maintainer type="person">
114 + <email>robbat2@g.o</email>
115 + </maintainer>
116 + <maintainer type="project">
117 + <email>base-system@g.o</email>
118 + <name>Gentoo Base System</name>
119 + </maintainer>
120 + <longdescription lang="en">
121 A suite of tools for thin provisioning on Linux.
122 </longdescription>
123 -<upstream>
124 - <remote-id type="github">jthornber/thin-provisioning-tools</remote-id>
125 -</upstream>
126 + <upstream>
127 + <remote-id type="github">jthornber/thin-provisioning-tools</remote-id>
128 + </upstream>
129 </pkgmetadata>
130
131 diff --git a/sys-block/thin-provisioning-tools/thin-provisioning-tools-0.6.3.ebuild b/sys-block/thin-provisioning-tools/thin-provisioning-tools-0.6.3.ebuild
132 new file mode 100644
133 index 00000000..2945158
134 --- /dev/null
135 +++ b/sys-block/thin-provisioning-tools/thin-provisioning-tools-0.6.3.ebuild
136 @@ -0,0 +1,60 @@
137 +# Copyright 1999-2016 Gentoo Foundation
138 +# Distributed under the terms of the GNU General Public License v2
139 +
140 +EAPI=6
141 +
142 +inherit autotools flag-o-matic
143 +
144 +DESCRIPTION="A suite of tools for thin provisioning on Linux"
145 +HOMEPAGE="https://github.com/jthornber/thin-provisioning-tools"
146 +SRC_URI="https://github.com/jthornber/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
147 +
148 +LICENSE="GPL-3"
149 +SLOT="0"
150 +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux"
151 +IUSE="static test"
152 +
153 +LIB_DEPEND="dev-libs/expat[static-libs(+)]
154 + dev-libs/libaio[static-libs(+)]"
155 +RDEPEND="!static? ( ${LIB_DEPEND//\[static-libs(+)]} )"
156 +# || ( ) is a non-future proof workaround for Portage unefficiency wrt #477050
157 +DEPEND="${RDEPEND}
158 + static? ( ${LIB_DEPEND} )
159 + test? (
160 + || ( dev-lang/ruby:2.9 dev-lang/ruby:2.8 dev-lang/ruby:2.7 dev-lang/ruby:2.6 dev-lang/ruby:2.5 dev-lang/ruby:2.4 dev-lang/ruby:2.3 dev-lang/ruby:2.2 dev-lang/ruby:2.1 dev-lang/ruby:2.0 )
161 + >=dev-cpp/gmock-1.6
162 + >=dev-cpp/gtest-1.6
163 + dev-util/cucumber
164 + dev-util/aruba
165 + )
166 + dev-libs/boost"
167 +
168 +PATCHES=( "${FILESDIR}"/${P}-build-fixes.patch )
169 +
170 +src_prepare() {
171 + default
172 + eautoreconf
173 +}
174 +
175 +src_configure() {
176 + use static && append-ldflags -static
177 + STRIP=true econf \
178 + --prefix="${EPREFIX}"/ \
179 + --bindir="${EPREFIX}"/sbin \
180 + --with-optimisation='' \
181 + $(use_enable test testing)
182 +}
183 +
184 +src_compile() {
185 + MAKEOPTS+=" V="
186 + default
187 +}
188 +
189 +src_test() {
190 + emake unit-test
191 +}
192 +
193 +src_install() {
194 + emake DESTDIR="${D}" DATADIR="${ED}/usr/share" install
195 + dodoc README.md TODO.org
196 +}