summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnthony G. Basile <blueness@gentoo.org>2013-05-15 22:51:42 +0000
committerAnthony G. Basile <blueness@gentoo.org>2013-05-15 22:51:42 +0000
commit7faa0be767deb50109df835d6c16ff97d0dbba76 (patch)
tree7506ae1d6d4e463dfa575e7c36b9d34af052acab /sys-apps/rng-tools
parentwhitespace (diff)
downloadhistorical-7faa0be767deb50109df835d6c16ff97d0dbba76.tar.gz
historical-7faa0be767deb50109df835d6c16ff97d0dbba76.tar.bz2
historical-7faa0be767deb50109df835d6c16ff97d0dbba76.zip
Fix assemby textrels on rdrand_asm.S on PIC x86, bug #469962
Package-Manager: portage-2.1.11.62/cvs/Linux x86_64 Manifest-Sign-Key: 0xF52D4BBA
Diffstat (limited to 'sys-apps/rng-tools')
-rw-r--r--sys-apps/rng-tools/ChangeLog8
-rw-r--r--sys-apps/rng-tools/Manifest32
-rw-r--r--sys-apps/rng-tools/files/fix-textrels-on-PIC-x86.patch71
-rw-r--r--sys-apps/rng-tools/rng-tools-4-r6.ebuild32
4 files changed, 127 insertions, 16 deletions
diff --git a/sys-apps/rng-tools/ChangeLog b/sys-apps/rng-tools/ChangeLog
index a29f8714a7aa..a651000cd002 100644
--- a/sys-apps/rng-tools/ChangeLog
+++ b/sys-apps/rng-tools/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for sys-apps/rng-tools
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/sys-apps/rng-tools/ChangeLog,v 1.45 2013/05/14 09:39:04 ago Exp $
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/rng-tools/ChangeLog,v 1.46 2013/05/15 22:51:23 blueness Exp $
+
+*rng-tools-4-r6 (15 May 2013)
+
+ 15 May 2013; Anthony G. Basile <blueness@gentoo.org>
+ +files/fix-textrels-on-PIC-x86.patch, +rng-tools-4-r6.ebuild:
+ Fix assemby textrels on rdrand_asm.S on PIC x86, bug #469962
14 May 2013; Agostino Sarubbo <ago@gentoo.org> rng-tools-4-r5.ebuild:
Stable for x86, wrt bug #458826
diff --git a/sys-apps/rng-tools/Manifest b/sys-apps/rng-tools/Manifest
index 4b27b3d6dfc4..717515f718ae 100644
--- a/sys-apps/rng-tools/Manifest
+++ b/sys-apps/rng-tools/Manifest
@@ -1,8 +1,9 @@
-----BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA512
+Hash: SHA256
AUX 2/rngd 1488 SHA256 00f8d05292565feb750d20af4ff6ff8ee20a14ae09c0164ec7b6b4b1ee67028d SHA512 8cd36378028c8e62e8e0b3f8afac155b65a0751c62f69f939f8273958eed6d53e450ae71ab4c400d41efdba3b76c1f08247560e8cc798d6d0e4175bdb4398464 WHIRLPOOL 1bbe2c0f47a66534b40d3ed12896d569774f4d3fa4d1fdd0a36fe91c34bdc51efb71603eb4030ee6b464c50acd51792f97b08e77d84ebdf4698d6770e3775a39
AUX 2/rngd-conf 259 SHA256 4dff7a0c8406f5344f71d236e755877388e93ff6728eedfdfe6921b3de41d137 SHA512 68e08ff2dbcbb6b4dc6235ba86070b296aa6439f17dbf61d8d992e08790a57d52cece0fc2c3b384b10df66868676ae2202621eb2fc18154eb2c7ba2cd8f74ee5 WHIRLPOOL 58f6e9e8975bf8abee0ef944ce48e4eced5c0d06e157b3e3fafdb55dee218399a47d2f7bbd04376e6d4d20e426ec7d2f75e1729f854e8062c997b3a972d801e8
+AUX fix-textrels-on-PIC-x86.patch 1971 SHA256 55d277a1b4dfed429bf82ca430371f2487e47948630203969bb66fc63fad39cb SHA512 201300211d322ca36e945f5adf225d072881f285b4d4a8710baf1416a532386befa91eec6da7131278fb1fbcecbf67d47742e563deecfd6d363f60b477462d09 WHIRLPOOL 92f189ee66e35f4242d2d4e7b6fc7d314775cfe1c211a900a5442f82fa3c18cbb8d375d8c7b80229ee21e8ff5fa4617c56d10a787b6b08831d7ae72cca9d0c35
AUX rngd-confd-3 714 SHA256 542ef931152a71888b8d1ebb2c1f5d43edefcd2902d616d635e1d15a0e742519 SHA512 398c31775d10e8f54717c05228bfc9166d260ae51e90c9819109ffd6086d41c7b48236e3c56dd71e0dacb6f10a881349bb14cf02e942933093fd15ca0068bd0a WHIRLPOOL 0e2d71c005452c865dee38bded6a9ddea048e28c09ee17160fd7da51913987d38e7a96d4ff517105b567e6f25783441834ca4621f590227747a4b55e29519b85
AUX rngd-confd-4 625 SHA256 f2d91a9a3ae1d765bf705a5498cbb201427f9ef475e3eb31aa43b1eb8b88af42 SHA512 9a0f938e7df70a4dbc5eaed48fe6f7713fae17b32993da500bc3066e9b55e9e59b646eb2c730e5cd57ce7f966d90c4a91a046d070c456f0dcb7f7032ef61ef80 WHIRLPOOL 2b8e9a9a157a922837e525fdca398f0c5de63e9fe3dfe7673320731d5bf359ada4b47cfb05f37b3e7fdb3099c334101a9fb0147a46cb7e4f6d11955b076a2ef1
AUX rngd-confd-4.1 562 SHA256 cdbd39f7446f12a9b78e87e9f135cfd0f6f364c4fa4ade0c96084b85c32afc38 SHA512 45e0e9cbe0180162f659bf05c15ee99fb8c1b80274cd8744384ba7f791b1c9a46a63e81eea665b4f492c13b7d5cc1fdb6e524a49a25af77f3791f527b31f688b WHIRLPOOL 87634cea70a1c8ffa7598cc8b0d93c79578433cc21b58bb13bc9144502b9502e2c4f151bcf282ad4ccef44a931f1be5d1e87ff7b9b6d07cfa0a4c288b4172ec3
@@ -18,22 +19,23 @@ EBUILD rng-tools-3-r1.ebuild 812 SHA256 2dfc702529144467a9c468fc82c9c4dc95dd5cd7
EBUILD rng-tools-3.ebuild 760 SHA256 643394e8733c3004af0326658d6a0795f69d9fa65b39ee9e63ed0ce19a472206 SHA512 254406e4647b4ea176bc12e822916e2b807852731c7ab932181e7c65dbb447b827840fe7f8bdf79f450cb261d6e1a3226e923110ea20c547d1907e2ff21ba21b WHIRLPOOL 08e6099eb5194ab5e28ba7ac8af7ed5907bb8c374fd9a28b53e2c42c64c2a20d9814d3c50b44a858827fc8fc8d52b3e6551353ac992cba657a7a3f3868c02105
EBUILD rng-tools-4-r1.ebuild 792 SHA256 38f15cf03a21bf6360a66fcdb346767d361f5f1f6dafdf517f168e0310294324 SHA512 ab99f62ca397099fa2953759e4528729cf78e5c701d8689a9fbe41f3015f5c2d35196e2729e77916bef376f6b2697458b196a4b5dac240e590fadeff6d7c28f4 WHIRLPOOL 66e403e660ef5a144698237c27da8f5a16ca700898080cd285ef99ab4ac9e83b97ca873d7c4ad9479ce1e6d715be1da7bc2482782a8fff19e0d98043ffc8ec99
EBUILD rng-tools-4-r5.ebuild 788 SHA256 5bc2ab8e5ef7b7ea7f3a47c02beeddc79c59b53247447d57ad90cf1a9fe576bf SHA512 f232c70d4efc31d26d09200d8e0ef7a201adbb3b18056828c3aba2d68f9017484a6f8fa47dd81f19531970f9978c34bdaf1aeb3dd7a5d0e2f568098a933510ca WHIRLPOOL 139c0157afa1c8cfe480e866b763b5f7ca5063c58e4bdbcb013cbcc15b348e9a7a666cc0939e26fd5ec5427a901095cb3bd7ae74d7e006ac5659367dd3026c90
-MISC ChangeLog 7368 SHA256 6e6ba4d9ef9e3ea8749b34046d00d8ec664e680c16bd8c884e9e2bfab904b6b9 SHA512 2391cbd6a866199e4db555f46546007cc17ed511dca18e98d13cd7f0329c4229f5f4b61a7a71849b7f117c138999773d7b44e623a33bb2cbcb90e01572db321b WHIRLPOOL a46bf93d67b217d29603edc250d9927ee101c3af64328c81a3e0d65caecb9d0cf85763335bde548d5ea4eaf01f4a0dd670fa90b0e00a7936d970bcfdf2d9762e
+EBUILD rng-tools-4-r6.ebuild 850 SHA256 97b1780acbe08962aa61a3df713f72f913a6caa1a01af6e389137b273e893ddd SHA512 b53e65a2079d67c5d40366b43315860939feb691293aab3d469271ee924ae4a5a9bb519c85c8f9d1e646249f2433b075f961296b83f1454d75b2b0171896c14f WHIRLPOOL 10406ad82a806cfe8146e519e4781c86110f739784805b4f913d8daf66ea561562b53a8ad8fac3b810e3813c50ed507c5c3a286d76f7b4cc7ccb6a37f5b2b638
+MISC ChangeLog 7587 SHA256 9e941a0d87d593421c03110db682dce1d03226fdb90c66e6056b662e57254ea1 SHA512 d7a295dd80b6b83d2bda3ecb4a8ce42e65dfa7bfb56fe93da5b559a11dd512f67cf716a588a13ccdaa88a5866b793bd0e357a4cb30861e252d6a12056d7942d4 WHIRLPOOL 30f56c7efea051cbbdcc25792f450a1fb2a291eba142421039111ef8c05143e83151313be4235cfa88d2534a69571eb7e597a9f6c23aaf8b2d94e76c418d8869
MISC metadata.xml 165 SHA256 23a8851c12bd4cf7cf0528250ad5605be6b0780bbec0c51331d6d2c618c13f6a SHA512 3f1bee5d098a4e5874df3af56169397cc3ed526f9c56004b9ccaa4c5cf02d4affd894400b88f50f3c19bf5ba3ae06f3d4d2cfa5c15e97b7d4c33053e5f0f63c5 WHIRLPOOL 070ba3ff0b1ea000c90d8af13cdac14693dc5d9dcc8d8ba89cf9bdbe91196e3cf9e72bd2f01cd5efc1ddab63b83184159298d1ee891bc123107ea6891ad612d2
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.19 (GNU/Linux)
-iQIcBAEBCgAGBQJRkgYyAAoJELp701BxlEWfVQEP/02FHcZfJz+9QvoW/ORZRWJ1
-Z6vAcAJz7t2zfftQIXPwTVi+r6hVsfCLeB06UDWlP+OgjVyDJqV6HrTJnNUq2d3P
-3NrLhsFRqKiHUutpqbta9Skf3VnyuQjVIl+d7oA67owRHuZ0nh8vY+KfHmV8jKVb
-fLM01N/3gqEKmshT5c3YoaVcpg7oaUHmcF4s0A2I1iBEMVfs+z+/g1eByC4gr25z
-Vo3koUQVBWRgqvrbLrDSjCmLDmu/F2KLNxRbhyO1KHo+mpTikl9Z3DOi8UXhPx5W
-ZGWNvhwyJ9JaFBUdGpFEqwRjJBO186nkC82EUS1fVCoG5pXi+choMiwVMkTAUwVA
-OOtOKUi5GgPMwI4t1CMPgOsRXODlf9+OH7URMpB1bKi3wvB9h1Zug3QzQFpffRHK
-aGqKWopIX1zipHUnd76K++tdS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x86.patch b/sys-apps/rng-tools/files/fix-textrels-on-PIC-x86.patch
new file mode 100644
index 000000000000..5ff34da861b4
--- /dev/null
+++ b/sys-apps/rng-tools/files/fix-textrels-on-PIC-x86.patch
@@ -0,0 +1,71 @@
+From: Francisco Blas Izquierdo Riera (klondike) <klondike@gentoo.org>
+Subject: [PATCH] Fix assemby textrels on rdrand_asm.S on PIC x86
+
+This patch fixes the assembly in rdrand_asm.S so it won't generate textrels on PIC systems.
+The main fixes are in the use of leal in SETPTR for such systems, the rest is the usual PIC
+support stuff.
+
+This should fix Gentoo bug #469962
+
+This patch is released under the GPLv2 or a higher version license as is the original file
+as long as reference to the author and the tester are included in the final code.
+
+Gentoo-bug-url: https://bugs.gentoo.org/show_bug.cgi?id=469962
+Upstream-status: Not sent yet
+Signed-off-by: Francisco Blas Izquierdo Riera (klondike) <klondike@gentoo.org>
+Reported-by: cilly <cilly@cilly.mine.nu>
+Tested-by: Anthony Basile <blueness@gentoo.org>
+
+--- rng-tools/rdrand_asm.S
++++ rng-tools/rdrand_asm.S
+@@ -49,6 +49,7 @@
+ ret
+ ENDPROC(x86_rdrand_nlong)
+
++#define INIT_PIC()
+ #define SETPTR(var,ptr) leaq var(%rip),ptr
+ #define PTR0 %rdi
+ #define PTR1 %rsi
+@@ -84,7 +85,16 @@
+ ret
+ ENDPROC(x86_rdrand_nlong)
+
++#if defined(__PIC__)
++#undef __i686 /* gcc builtin define gets in our way */
++#define INIT_PIC() \
++ call __i686.get_pc_thunk.bx ; \
++ addl $_GLOBAL_OFFSET_TABLE_, %ebx
++#define SETPTR(var,ptr) leal (var)@GOTOFF(%ebx),ptr
++#else
++#define INIT_PIC()
+ #define SETPTR(var,ptr) movl $(var),ptr
++#endif
+ #define PTR0 %eax
+ #define PTR1 %edx
+ #define PTR2 %ecx
+@@ -101,6 +111,7 @@
+ movl 8(%ebp), %eax
+ movl 12(%ebp), %edx
+ #endif
++ INIT_PIC()
+
+ SETPTR(aes_round_keys, PTR2)
+
+@@ -166,6 +177,17 @@
+ #endif
+ ret
+ ENDPROC(x86_aes_mangle)
++
++#if defined(__i386__) && defined(__PIC__)
++ .section .gnu.linkonce.t.__i686.get_pc_thunk.bx,"ax",@progbits
++.globl __i686.get_pc_thunk.bx
++ .hidden __i686.get_pc_thunk.bx
++ .type __i686.get_pc_thunk.bx,@function
++__i686.get_pc_thunk.bx:
++ movl (%esp), %ebx
++ ret
++#endif
++
+ /*
+ * AES round keys for an arbitrary key:
+ * 00102030405060708090A0B0C0D0E0F0
diff --git a/sys-apps/rng-tools/rng-tools-4-r6.ebuild b/sys-apps/rng-tools/rng-tools-4-r6.ebuild
new file mode 100644
index 000000000000..47a0d696147d
--- /dev/null
+++ b/sys-apps/rng-tools/rng-tools-4-r6.ebuild
@@ -0,0 +1,32 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/sys-apps/rng-tools/rng-tools-4-r6.ebuild,v 1.1 2013/05/15 22:51:23 blueness Exp $
+
+EAPI="4"
+
+inherit eutils autotools toolchain-funcs
+
+DESCRIPTION="Daemon to use hardware random number generators"
+HOMEPAGE="http://gkernel.sourceforge.net/"
+SRC_URI="mirror://sourceforge/gkernel/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~x86"
+IUSE=""
+
+src_prepare() {
+ echo 'bin_PROGRAMS = randstat' >> contrib/Makefile.am
+ epatch "${FILESDIR}"/test-for-argp.patch
+ epatch "${FILESDIR}"/fix-textrels-on-PIC-x86.patch
+ eautoreconf
+
+ sed -i '/^AR /d' Makefile.in
+ tc-export AR
+}
+
+src_install() {
+ default
+ newinitd "${FILESDIR}"/rngd-initd-4.1 rngd
+ newconfd "${FILESDIR}"/rngd-confd-4.1 rngd
+}