Gentoo Archives: gentoo-commits

From: David Seifert <soap@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-block/tgt/, sys-block/tgt/files/
Date: Fri, 01 Jan 2021 18:04:38
Message-Id: 1609524264.e547354a2545379b5cdacbd8118c866ca768559c.soap@gentoo
1 commit: e547354a2545379b5cdacbd8118c866ca768559c
2 Author: Jakov Smolic <jakov.smolic <AT> sartura <DOT> hr>
3 AuthorDate: Fri Jan 1 18:04:24 2021 +0000
4 Commit: David Seifert <soap <AT> gentoo <DOT> org>
5 CommitDate: Fri Jan 1 18:04:24 2021 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e547354a
7
8 sys-block/tgt: Fix build with gcc-10
9
10 Closes: https://bugs.gentoo.org/709638
11 Signed-off-by: Jakov Smolic <jakov.smolic <AT> sartura.hr>
12 Signed-off-by: David Seifert <soap <AT> gentoo.org>
13
14 sys-block/tgt/files/tgt-1.0.79-fno-common.patch | 22 ++++++++++++++++++++++
15 sys-block/tgt/tgt-1.0.79.ebuild | 12 +++++++-----
16 2 files changed, 29 insertions(+), 5 deletions(-)
17
18 diff --git a/sys-block/tgt/files/tgt-1.0.79-fno-common.patch b/sys-block/tgt/files/tgt-1.0.79-fno-common.patch
19 new file mode 100644
20 index 00000000000..08933df021d
21 --- /dev/null
22 +++ b/sys-block/tgt/files/tgt-1.0.79-fno-common.patch
23 @@ -0,0 +1,22 @@
24 +--- a/usr/iscsi/iscsid.c
25 ++++ b/usr/iscsi/iscsid.c
26 +@@ -1074,7 +1074,7 @@ void iscsi_rsp_set_residual(struct iscsi_cmd_rsp *rsp, struct scsi_cmd *scmd)
27 + struct iscsi_sense_data {
28 + uint16_t length;
29 + uint8_t data[0];
30 +-} __packed;
31 ++} __attribute__((__packed__));
32 +
33 + static int iscsi_cmd_rsp_build(struct iscsi_task *task)
34 + {
35 +--- a/usr/iscsi/iser.c
36 ++++ b/usr/iscsi/iser.c
37 +@@ -92,7 +92,7 @@ char *iser_portal_addr;
38 + struct iscsi_sense_data {
39 + uint16_t length;
40 + uint8_t data[0];
41 +-} __packed;
42 ++} __attribute__((__packed__));
43 +
44 + static size_t buf_pool_sz_mb = DEFAULT_POOL_SIZE_MB;
45 + static int cq_vector = -1;
46
47 diff --git a/sys-block/tgt/tgt-1.0.79.ebuild b/sys-block/tgt/tgt-1.0.79.ebuild
48 index d6261e6104c..a014556fa53 100644
49 --- a/sys-block/tgt/tgt-1.0.79.ebuild
50 +++ b/sys-block/tgt/tgt-1.0.79.ebuild
51 @@ -2,7 +2,7 @@
52 # Distributed under the terms of the GNU General Public License v2
53
54 EAPI=7
55 -inherit flag-o-matic toolchain-funcs
56 +inherit toolchain-funcs
57
58 MY_TREE="b43dbc6"
59
60 @@ -15,30 +15,32 @@ SLOT="0"
61 KEYWORDS="amd64 arm64 ~ppc x86"
62 IUSE="fcoe fcp ibmvio infiniband rbd"
63
64 -CDEPEND="dev-perl/Config-General
65 +DEPEND="
66 + app-text/docbook-xsl-stylesheets
67 dev-libs/libxslt
68 + dev-perl/Config-General
69 rbd? ( sys-cluster/ceph )
70 infiniband? (
71 sys-fabric/libibverbs:=
72 sys-fabric/librdmacm:=
73 )"
74 -DEPEND="${CDEPEND}
75 - app-text/docbook-xsl-stylesheets"
76 RDEPEND="${DEPEND}
77 dev-libs/libaio
78 sys-apps/sg3_utils"
79
80 S=${WORKDIR}/fujita-tgt-${MY_TREE}
81
82 +PATCHES=( "${FILESDIR}"/${P}-fno-common.patch )
83 +
84 pkg_setup() {
85 tc-export CC
86 }
87
88 src_prepare() {
89 + default
90 sed -i -e 's:\($(CC)\) $^:\1 $(LDFLAGS) $^:' usr/Makefile || die
91 # make sure xml docs are generated before trying to install them
92 sed -i -e "s@install: @& all @g" doc/Makefile || die
93 - eapply_user
94 }
95
96 src_compile() {