* [gentoo-commits] repo/gentoo:master commit in: net-misc/taylor-uucp/files/, net-misc/taylor-uucp/
@ 2016-03-05 11:09 Jeroen Roovers
0 siblings, 0 replies; 3+ messages in thread
From: Jeroen Roovers @ 2016-03-05 11:09 UTC (permalink / raw
To: gentoo-commits
commit: faeeb6bae0c48353f06c8d7216b46447078e484d
Author: Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Sat Mar 5 11:08:40 2016 +0000
Commit: Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Sat Mar 5 11:09:20 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=faeeb6ba
net-misc/taylor-uucp: Fix compiler warning (bug #520628).
Package-Manager: portage-2.2.27
.../files/taylor-uucp-1.07-fprintf.patch | 11 ++++
net-misc/taylor-uucp/taylor-uucp-1.07-r3.ebuild | 58 ++++++++++++++++++++++
2 files changed, 69 insertions(+)
diff --git a/net-misc/taylor-uucp/files/taylor-uucp-1.07-fprintf.patch b/net-misc/taylor-uucp/files/taylor-uucp-1.07-fprintf.patch
new file mode 100644
index 0000000..5ac0304
--- /dev/null
+++ b/net-misc/taylor-uucp/files/taylor-uucp-1.07-fprintf.patch
@@ -0,0 +1,11 @@
+--- a/uuconv.c
++++ b/uuconv.c
+@@ -676,7 +676,7 @@
+ {
+ if ((*pz)[0] != '-' && pz != pzarg)
+ fprintf (e, " ");
+- fprintf (e, *pz);
++ fprintf (e, "%s", *pz);
+ }
+ }
+
diff --git a/net-misc/taylor-uucp/taylor-uucp-1.07-r3.ebuild b/net-misc/taylor-uucp/taylor-uucp-1.07-r3.ebuild
new file mode 100644
index 0000000..4e66a43
--- /dev/null
+++ b/net-misc/taylor-uucp/taylor-uucp-1.07-r3.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="5"
+
+inherit eutils flag-o-matic autotools
+
+DESCRIPTION="Taylor UUCP"
+HOMEPAGE="http://www.airs.com/ian/uucp.html"
+SRC_URI="mirror://gnu/uucp/uucp-${PV}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~sparc ~x86"
+
+S="${WORKDIR}/uucp-${PV}"
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}-gentoo.patch
+ epatch "${FILESDIR}"/${P}-fprintf.patch
+ mv configure.{in,ac} || die
+ sed -i 's:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:' configure.ac || die
+ eautoreconf
+}
+
+src_configure() {
+ append-cppflags -D_GNU_SOURCE -fno-strict-aliasing
+ econf --with-newconfigdir=/etc/uucp
+}
+
+src_install() {
+ dodir /usr/share/man/man{1,8}
+ dodir /usr/share/info
+ dodir /etc/uucp
+ dodir /usr/bin /usr/sbin
+ diropts -o uucp -g uucp -m 0750
+ keepdir /var/log/uucp /var/spool/uucp
+ diropts -o uucp -g uucp -m 0775
+ keepdir /var/spool/uucppublic
+
+ emake \
+ "prefix=${D}/usr" \
+ "sbindir=${D}/usr/sbin" \
+ "bindir=${D}/usr/bin" \
+ "man1dir=${D}/usr/share/man/man1" \
+ "man8dir=${D}/usr/share/man/man8" \
+ "newconfigdir=${D}/etc/uucp" \
+ "infodir=${D}/usr/share/info" \
+ install install-info
+ sed -i -e 's:/usr/spool:/var/spool:g' sample/config
+ cp sample/* "${ED}/etc/uucp" || die
+ dodoc ChangeLog NEWS README TODO
+}
+
+pkg_preinst() {
+ usermod -s /bin/bash uucp
+}
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-misc/taylor-uucp/files/, net-misc/taylor-uucp/
@ 2020-09-14 23:53 Sam James
0 siblings, 0 replies; 3+ messages in thread
From: Sam James @ 2020-09-14 23:53 UTC (permalink / raw
To: gentoo-commits
commit: bb2ff02e237f6b77ca3624c7a371e6dd3a4daa38
Author: Nicolas Boichat <drinkcat <AT> chromium <DOT> org>
AuthorDate: Fri Sep 11 05:34:17 2020 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Sep 14 23:45:29 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=bb2ff02e
net-misc/taylor-uucp: Remove external function declarations in unix/init.c
That makes the code compile with fewer warnings, and gets rid of this error
with recent Chrome OS toolchains:
init.c:100:14: error: redeclaration of 'getcwd' must have the 'overloadable' attribute
extern char *getcwd ();
^
/build/amd64-generic/usr/include/bits/unistd.h:158:8: note: previous overload of function is here
__NTH (getcwd (char *const __clang_pass_object_size __buf, size_t __size))
^
Signed-off-by: Nicolas Boichat <drinkcat <AT> chromium.org>
Closes: https://github.com/gentoo/gentoo/pull/17497
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../files/taylor-uucp-1.07-remove-extern.patch | 67 ++++++++++++++++++++++
...p-1.07-r3.ebuild => taylor-uucp-1.07-r4.ebuild} | 1 +
2 files changed, 68 insertions(+)
diff --git a/net-misc/taylor-uucp/files/taylor-uucp-1.07-remove-extern.patch b/net-misc/taylor-uucp/files/taylor-uucp-1.07-remove-extern.patch
new file mode 100644
index 00000000000..4a8efeeb83f
--- /dev/null
+++ b/net-misc/taylor-uucp/files/taylor-uucp-1.07-remove-extern.patch
@@ -0,0 +1,67 @@
+From 84b5bf1e6b8cfad657b88f8b061e172e327ef970 Mon Sep 17 00:00:00 2001
+From: Nicolas Boichat <drinkcat@chromium.org>
+Date: Thu, 10 Sep 2020 17:06:37 +0800
+Subject: [PATCH] Remove external function declarations
+
+We need to redeclare functions that we already have.
+
+This causes issues with recent toolchains:
+init.c:100:14: error: redeclaration of 'getcwd' must have the 'overloadable' attribute
+extern char *getcwd ();
+ ^
+/build/amd64-generic/usr/include/bits/unistd.h:158:8: note: previous overload of function is here
+__NTH (getcwd (char *const __clang_pass_object_size __buf, size_t __size))
+ ^
+
+And also reduces the number of build warnings.
+
+This forked repo does the same thing in this (large) cleanup patch:
+https://github.com/quinot/taylor-uucp/commit/b599665ae1e085df0f96de5f50a738fceee02150
+---
+ unix/init.c | 30 ------------------------------
+ 1 file changed, 30 deletions(-)
+
+diff --git a/unix/init.c b/unix/init.c
+index d9d2147edd93..a9b7135be9f4 100644
+--- a/unix/init.c
++++ b/unix/init.c
+@@ -81,36 +81,6 @@
+ #endif /* ! defined (MAXPATHLEN) */
+ #endif /* HAVE_GETWD */
+
+-/* External functions. */
+-#ifndef getlogin
+-extern char *getlogin ();
+-#endif
+-#if GETPWNAM_DECLARATION_OK
+-#ifndef getpwnam
+-extern struct passwd *getpwnam ();
+-#endif
+-#endif
+-#if GETPWUID_DECLARATION_OK
+-#ifndef getpwuid
+-extern struct passwd *getpwuid ();
+-#endif
+-#endif
+-#if HAVE_GETCWD
+-#ifndef getcwd
+-extern char *getcwd ();
+-#endif
+-#endif
+-#if HAVE_GETWD
+-#ifndef getwd
+-extern char *getwd ();
+-#endif
+-#endif
+-#if HAVE_SYSCONF
+-#ifndef sysconf
+-extern long sysconf ();
+-#endif
+-#endif
+-\f
+ /* Initialize the system dependent routines. We will probably be running
+ suid to uucp, so we make sure that nothing is obviously wrong. We
+ save the login name since we will be losing the real uid. */
+--
+2.28.0.526.ge36021eeef-goog
+
diff --git a/net-misc/taylor-uucp/taylor-uucp-1.07-r3.ebuild b/net-misc/taylor-uucp/taylor-uucp-1.07-r4.ebuild
similarity index 96%
rename from net-misc/taylor-uucp/taylor-uucp-1.07-r3.ebuild
rename to net-misc/taylor-uucp/taylor-uucp-1.07-r4.ebuild
index c32b453cdee..1f216fb1763 100644
--- a/net-misc/taylor-uucp/taylor-uucp-1.07-r3.ebuild
+++ b/net-misc/taylor-uucp/taylor-uucp-1.07-r4.ebuild
@@ -18,6 +18,7 @@ S="${WORKDIR}/uucp-${PV}"
src_prepare() {
epatch "${FILESDIR}"/${P}-gentoo.patch
epatch "${FILESDIR}"/${P}-fprintf.patch
+ epatch "${FILESDIR}"/${P}-remove-extern.patch
mv configure.{in,ac} || die
sed -i 's:AM_CONFIG_HEADER:AC_CONFIG_HEADERS:' configure.ac || die
eautoreconf
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: net-misc/taylor-uucp/files/, net-misc/taylor-uucp/
@ 2024-10-21 2:55 Eli Schwartz
0 siblings, 0 replies; 3+ messages in thread
From: Eli Schwartz @ 2024-10-21 2:55 UTC (permalink / raw
To: gentoo-commits
commit: 8e2534d312fe1f7218d75428f3204180429b30a5
Author: Eli Schwartz <eschwartz <AT> gentoo <DOT> org>
AuthorDate: Mon Oct 21 02:52:02 2024 +0000
Commit: Eli Schwartz <eschwartz <AT> gentoo <DOT> org>
CommitDate: Mon Oct 21 02:54:45 2024 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8e2534d3
net-misc/taylor-uucp: fix modern C code defects
The software is unmaintained since 2002 so it's actually, for once,
almost plausible that it still uses code constructs made illegal barely
3 years before. Huh, how about that.
Closes: https://bugs.gentoo.org/874705
Closes: https://bugs.gentoo.org/900260
Signed-off-by: Eli Schwartz <eschwartz <AT> gentoo.org>
.../files/taylor-uucp-1.07-modernc.patch | 98 ++++++++++++++++++++++
net-misc/taylor-uucp/taylor-uucp-1.07-r7.ebuild | 1 +
2 files changed, 99 insertions(+)
diff --git a/net-misc/taylor-uucp/files/taylor-uucp-1.07-modernc.patch b/net-misc/taylor-uucp/files/taylor-uucp-1.07-modernc.patch
new file mode 100644
index 000000000000..b4d510e7b264
--- /dev/null
+++ b/net-misc/taylor-uucp/files/taylor-uucp-1.07-modernc.patch
@@ -0,0 +1,98 @@
+From df33893e32c12317a4617982a768dc33d8110365 Mon Sep 17 00:00:00 2001
+From: Eli Schwartz <eschwartz@gentoo.org>
+Date: Sun, 20 Oct 2024 22:38:13 -0400
+Subject: [PATCH] fix various Modern C issues
+
+These mostly encompass configure checks for missing headers (and one
+missing return type for main) that result in compile checks failing.
+
+There are also a couple issues in the codebase itself. Not all numbers
+are the same (type)...
+
+https://bugs.gentoo.org/874705
+https://bugs.gentoo.org/900260
+---
+ configure.in | 11 ++++++-----
+ unix/portnm.c | 2 +-
+ unix/tcp.c | 2 +-
+ 3 files changed, 8 insertions(+), 7 deletions(-)
+
+diff --git a/configure.in b/configure.in
+index 4087ec4..317affc 100644
+--- a/configure.in
++++ b/configure.in
+@@ -278,7 +278,7 @@ fi
+ dnl
+ AC_MSG_CHECKING(for void)
+ AC_CACHE_VAL(uucp_cv_c_void,
+-[AC_TRY_COMPILE([], [extern void foo (); (void) exit (0);],
++[AC_TRY_COMPILE([#include <stdlib.h>], [extern void foo (); (void) exit (0);],
+ uucp_cv_c_void=yes, uucp_cv_c_void=no)])
+ AC_MSG_RESULT($uucp_cv_c_void)
+ if test $uucp_cv_c_void = yes; then
+@@ -318,7 +318,7 @@ dnl On some systems, memset, memcmp, and memcpy must be called with
+ dnl the right number of arguments.
+ AC_MSG_CHECKING(for memset)
+ AC_CACHE_VAL(ac_cv_func_memset,
+-[AC_TRY_LINK([], [ char *i; int j, k; memset(i, j, k); ],
++[AC_TRY_LINK([#include <string.h>], [ char *i; int j, k; memset(i, j, k); ],
+ ac_cv_func_memset=yes, ac_cv_func_memset=no)])
+ AC_MSG_RESULT($ac_cv_func_memset)
+ if test $ac_cv_func_memset = yes; then
+@@ -327,7 +327,7 @@ fi
+ dnl
+ AC_MSG_CHECKING(for memcmp)
+ AC_CACHE_VAL(ac_cv_func_memcmp,
+-[AC_TRY_LINK([], [ char *i, *j; int k; memcmp(i, j, k); ],
++[AC_TRY_LINK([#include <string.h>], [ char *i, *j; int k; memcmp(i, j, k); ],
+ ac_cv_func_memcmp=yes, ac_cv_func_memcmp=no)])
+ AC_MSG_RESULT($ac_cv_func_memcmp)
+ if test $ac_cv_func_memcmp = yes; then
+@@ -336,7 +336,7 @@ fi
+ dnl
+ AC_MSG_CHECKING(for memcpy)
+ AC_CACHE_VAL(ac_cv_func_memcpy,
+-[AC_TRY_LINK([], [ char *i, *j; int k; memcpy(i, j, k); ],
++[AC_TRY_LINK([#include <string.h>], [ char *i, *j; int k; memcpy(i, j, k); ],
+ ac_cv_func_memcpy=yes, ac_cv_func_memcpy=no)])
+ AC_MSG_RESULT($ac_cv_func_memcpy)
+ if test $ac_cv_func_memcpy = yes; then
+@@ -373,7 +373,8 @@ AC_CACHE_VAL(uucp_cv_sys_ftime_ok,
+ [AC_TRY_RUN([
+ #include <sys/types.h>
+ #include <sys/timeb.h>
+-main ()
++#include <stdlib.h>
++int main ()
+ {
+ struct timeb s, slast;
+ int c = 0;
+diff --git a/unix/portnm.c b/unix/portnm.c
+index 9eda4ab..019337c 100644
+--- a/unix/portnm.c
++++ b/unix/portnm.c
+@@ -32,7 +32,7 @@ zsysdep_port_name (ftcp_port)
+
+ #if HAVE_TCP
+ {
+- size_t clen;
++ socklen_t clen;
+ struct sockaddr s;
+
+ clen = sizeof (struct sockaddr);
+diff --git a/unix/tcp.c b/unix/tcp.c
+index 1bbcec7..af52cab 100644
+--- a/unix/tcp.c
++++ b/unix/tcp.c
+@@ -395,7 +395,7 @@ ftcp_open (qconn, ibaud, fwait, fuser)
+ while (! FGOT_SIGNAL ())
+ {
+ sockaddr_storage speer;
+- size_t clen;
++ socklen_t clen;
+ int onew;
+ pid_t ipid;
+
+--
+2.45.2
+
diff --git a/net-misc/taylor-uucp/taylor-uucp-1.07-r7.ebuild b/net-misc/taylor-uucp/taylor-uucp-1.07-r7.ebuild
index 9b97bf770435..0a13b69be1fa 100644
--- a/net-misc/taylor-uucp/taylor-uucp-1.07-r7.ebuild
+++ b/net-misc/taylor-uucp/taylor-uucp-1.07-r7.ebuild
@@ -18,6 +18,7 @@ PATCHES=(
"${FILESDIR}"/${P}-gentoo.patch
"${FILESDIR}"/${P}-fprintf.patch
"${FILESDIR}"/${P}-remove-extern.patch
+ "${FILESDIR}"/${P}-modernc.patch
)
src_prepare() {
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-10-21 2:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-05 11:09 [gentoo-commits] repo/gentoo:master commit in: net-misc/taylor-uucp/files/, net-misc/taylor-uucp/ Jeroen Roovers
-- strict thread matches above, loose matches on Subject: below --
2020-09-14 23:53 Sam James
2024-10-21 2:55 Eli Schwartz
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox