diff options
author | Viorel Munteanu <ceamac@gentoo.org> | 2024-05-03 09:31:24 +0300 |
---|---|---|
committer | Viorel Munteanu <ceamac@gentoo.org> | 2024-05-03 10:04:34 +0300 |
commit | e5ee5d5af56c1f2753377ee13d987c32bbd0f58c (patch) | |
tree | 53342f86301d2cc1d5c6cb707f1446044bc1f7e9 /net-ftp | |
parent | app-admin/linode-cli: add 5.49.1, drop 5.49.0 (diff) | |
download | gentoo-e5ee5d5af56c1f2753377ee13d987c32bbd0f58c.tar.gz gentoo-e5ee5d5af56c1f2753377ee13d987c32bbd0f58c.tar.bz2 gentoo-e5ee5d5af56c1f2753377ee13d987c32bbd0f58c.zip |
net-ftp/ncftp: fix implicit function declarations QA warning
Closes: https://bugs.gentoo.org/926491
Signed-off-by: Viorel Munteanu <ceamac@gentoo.org>
Diffstat (limited to 'net-ftp')
-rw-r--r-- | net-ftp/ncftp/files/ncftp-3.2.7-implicit-function-declarations.patch | 93 | ||||
-rw-r--r-- | net-ftp/ncftp/ncftp-3.2.7-r2.ebuild | 55 |
2 files changed, 148 insertions, 0 deletions
diff --git a/net-ftp/ncftp/files/ncftp-3.2.7-implicit-function-declarations.patch b/net-ftp/ncftp/files/ncftp-3.2.7-implicit-function-declarations.patch new file mode 100644 index 000000000000..a0e14a7c325d --- /dev/null +++ b/net-ftp/ncftp/files/ncftp-3.2.7-implicit-function-declarations.patch @@ -0,0 +1,93 @@ +aclocal.m4 contains code that no longer compiles: missing headers and missing +return types. + +https://bugs.gentoo.org/875458 +https://bugs.gentoo.org/921487 +https://bugs.gentoo.org/926491 + +--- a/autoconf_local/aclocal.m4 ++++ b/autoconf_local/aclocal.m4 +@@ -464,6 +464,7 @@ CFLAGS="$CFLAGS $ac_cv_ssp_flags" + changequote([, ])dnl + AC_TRY_LINK([ + #include <stdio.h> ++#include <string.h> + #ifdef HAVE_STDLIB_H + # include <stdlib.h> + #endif +@@ -1063,6 +1064,7 @@ AC_DEFUN(wi_USE_STATIC_LIBGCC, [ + # + AC_TRY_LINK([ + #include <stdio.h> ++#include <string.h> + #ifdef HAVE_STDLIB_H + # include <stdlib.h> + #endif +@@ -3057,6 +3059,7 @@ AC_TRY_LINK([ + #include <sys/uio.h> + #include <sys/socket.h> + #include <sys/un.h> ++#include <string.h> + ],[ + struct sockaddr_un uaddr; + +@@ -3285,6 +3288,7 @@ AC_TRY_LINK([ + #ifdef HAVE_RESOLV_H + # include <resolv.h> + #endif ++#include <string.h> + ],[ + /* function-body */ + int len; +@@ -3363,6 +3367,7 @@ else + #include <stdio.h> + #include <stdlib.h> + ++ int + main(int argc, char **argv) + { + /* Note: don't actually call readline, +@@ -4193,7 +4198,7 @@ AC_MSG_CHECKING([types of arguments for select()]) + #include <sys/select.h> + #endif + #include <sys/socket.h> /* MG: always incl */ +-extern select ($ac_cv_func_select_arg1,$ac_cv_func_select_arg234,$ac_cv_func_select_arg234,$ac_cv_func_select_arg234,$ac_cv_func_select_arg5);],,dnl ++extern int select ($ac_cv_func_select_arg1,$ac_cv_func_select_arg234,$ac_cv_func_select_arg234,$ac_cv_func_select_arg234,$ac_cv_func_select_arg5);],,dnl + [ac_not_found=no ; break 3],ac_not_found=yes) + done + done +@@ -5145,6 +5150,7 @@ do + #ifdef HAVE_STDLIB_H + # include <stdlib.h> + #endif ++#include <string.h> + + #ifdef HAVE_NCURSES_H + # define NCURSES_OPAQUE 0 +@@ -5176,6 +5182,7 @@ do + #endif + + ++int + main(int argc, char **argv) + { + /* Note: don't actually call curses, since it may block; +@@ -6510,7 +6517,6 @@ char *malloc(); + #endif + #endif /* MG */ + +-int + int main(void) + { + char *data, *data2, *data3; +@@ -6607,8 +6613,9 @@ else + AC_CACHE_CHECK(whether setvbuf arguments are reversed, + ac_cv_func_setvbuf_reversed, + [AC_TRY_RUN([#include <stdio.h> ++ $include <stdlib.h> + /* If setvbuf has the reversed format, exit 0. */ +- main () { ++ int main (void) { + /* This call has the arguments reversed. + A reversed system may check and see that the address of main + is not _IOLBF, _IONBF, or _IOFBF, and return nonzero. */ diff --git a/net-ftp/ncftp/ncftp-3.2.7-r2.ebuild b/net-ftp/ncftp/ncftp-3.2.7-r2.ebuild new file mode 100644 index 000000000000..48fa3dac535e --- /dev/null +++ b/net-ftp/ncftp/ncftp-3.2.7-r2.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2024 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +inherit autotools toolchain-funcs + +DESCRIPTION="An extremely configurable ftp client" +HOMEPAGE="https://www.ncftp.com/" +SRC_URI="https://www.ncftp.com/public_ftp/${PN}/${P}-src.tar.xz" + +LICENSE="Clarified-Artistic" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos" +IUSE="pch" + +DEPEND=" + sys-libs/ncurses:= +" +RDEPEND=" + ${DEPEND} +" +BDEPEND=" + virtual/pkgconfig +" + +PATCHES=( + "${FILESDIR}"/${PN}-3.2.7-implicit-function-declarations.patch +) + +src_prepare() { + default + + sed -i -e '/^AR=/d' autoconf_local/aclocal.m4 || die + # 727774 + sed -i -e 's/STRIP=".*"/STRIP=":"/' autoconf_local/aclocal.m4 || die + + AT_M4DIR=autoconf_local/ eautoreconf +} + +src_configure() { + tc-export AR CC + LC_ALL="C" \ + LIBS="$( $(tc-getPKG_CONFIG) --libs ncurses)" \ + econf \ + $(use_enable pch precomp) \ + --disable-ccdv \ + --disable-universal +} + +src_install() { + default + dodoc README.txt doc/*.txt + docinto html + dodoc doc/html/*.html +} |