www-client/w3mmee: fix build
authorAkinori Hattori <hattya@gentoo.org>
Sat, 31 Mar 2018 14:01:54 +0000 (23:01 +0900)
committerAkinori Hattori <hattya@gentoo.org>
Sat, 31 Mar 2018 14:01:54 +0000 (23:01 +0900)
Closes: https://bugs.gentoo.org/586258
Package-Manager: Portage-2.3.24, Repoman-2.3.6

www-client/w3mmee/files/w3mmee-time.patch [new file with mode: 0644]
www-client/w3mmee/w3mmee-0.3.2_p24-r10.ebuild

diff --git a/www-client/w3mmee/files/w3mmee-time.patch b/www-client/w3mmee/files/w3mmee-time.patch
new file mode 100644 (file)
index 0000000..c63d654
--- /dev/null
@@ -0,0 +1,32 @@
+https://bugs.gentoo.org/586258
+
+Author: kouyu <ckyoog@gmail.com>
+
+--- a/terms.c
++++ b/terms.c
+@@ -305,11 +305,7 @@
+                    struct timeval *tout)
+ {
+     static struct timeval polltv = {
+-#if CLOCKS_PER_SEC > 1
+-      0, 1000000 / CLOCKS_PER_SEC
+-#else
+-      0, 10000
+-#endif
++      0, CLOCKS_PER_SEC > 1 ? 1000000 / CLOCKS_PER_SEC : 10000
+     };
+     int m;
+     struct timeval tv;
+@@ -779,11 +775,7 @@
+ #endif
+ static struct timeval display_delta = {
+-#if CLOCKS_PER_SEC > 1
+-    0, 1000000 / CLOCKS_PER_SEC,
+-#else
+-    0, 10000
+-#endif
++    0, CLOCKS_PER_SEC > 1 ? 1000000 / CLOCKS_PER_SEC : 10000
+ };
+ static int
index f96eff96014761975a224ea637eae9995569ac2b..b08f0b4a39897a48858b8a7ee40caf9fd6e4c44d 100644 (file)
@@ -40,6 +40,7 @@ PATCHES=(
        "${FILESDIR}"/${PN}-gcc-4.4.patch
        "${FILESDIR}"/${PN}-gcc-4.5.patch
        "${FILESDIR}"/${PN}-glibc-2.14.patch
+       "${FILESDIR}"/${PN}-time.patch
        "${FILESDIR}"/${PN}-tinfo.patch
        "${FILESDIR}"/${PN}-w3mman-gentoo.patch
 )