new package: ircd-irc2 (#8176)

This commit is contained in:
xtkoba 2021-12-20 18:36:17 +09:00 committed by GitHub
parent b0db448429
commit 85a1bf5469
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 95 additions and 0 deletions

View File

@ -0,0 +1,21 @@
TERMUX_PKG_HOMEPAGE=http://www.irc.org/
TERMUX_PKG_DESCRIPTION="An Internet Relay Chat (IRC) daemon"
TERMUX_PKG_LICENSE="GPL-2.0" # GPL-1.0-or-later
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION=2.11.2p3
TERMUX_PKG_SRCURL=http://www.irc.org/ftp/irc/server/irc${TERMUX_PKG_VERSION}.tgz
TERMUX_PKG_SHA256=be94051845f9be7da0e558699c4af7963af7e647745d339351985a697eca2c81
TERMUX_PKG_DEPENDS="libcrypt, resolv-conf, zlib"
TERMUX_PKG_BUILD_IN_SRC=true
TERMUX_PKG_EXTRA_CONFIGURE_ARGS="
--with-resconf=$TERMUX_PREFIX/etc/resolv.conf
ac_cv_func_setpgrp_void=yes
irc_cv_non_blocking_system=posix
"
TERMUX_PKG_EXTRA_MAKE_ARGS="-C build"
termux_step_pre_configure() {
CFLAGS+=" $CPPFLAGS"
LDFLAGS+=" -lcrypt"
}

View File

@ -0,0 +1,11 @@
--- a/configure
+++ b/configure
@@ -19,7 +19,7 @@
support/configure $*
else
echo "retrieving the system name, type and OS release..."
- rev=`support/config.guess`
+ rev=build
if test "${rev}" # test for no output
then
echo " your system seems to be ${rev}."

View File

@ -0,0 +1,11 @@
--- a/contrib/ircdwatch/ircdwatch.c
+++ b/contrib/ircdwatch/ircdwatch.c
@@ -205,7 +205,7 @@
}
if (pid == 0) {
- execl("/bin/sh", "sh", "-c", cmd, (char *) NULL);
+ execl("@TERMUX_PREFIX@/bin/sh", "sh", "-c", cmd, (char *) NULL);
_exit(127);
}
return(0);

View File

@ -0,0 +1,12 @@
--- a/contrib/mkpasswd/mkpasswd.c
+++ b/contrib/mkpasswd/mkpasswd.c
@@ -27,8 +27,7 @@
#define FLAG_ROUNDS 0x00000040
#define FLAG_EXT 0x00000080
-extern char *getpass(const char * prompt);
-extern char *crypt(const char *key, const char *salt);
+#include <crypt.h>
char *make_des_salt(void);
char *make_ext_salt(int);

View File

@ -0,0 +1,20 @@
--- a/ircd/s_bsd.c
+++ b/ircd/s_bsd.c
@@ -809,7 +809,7 @@ void daemonize(void)
#if defined(HPUX) || defined(SVR4) || defined(DYNIXPTX) || \
defined(_POSIX_SOURCE) || defined(SGI)
(void)setsid();
-#elif defined (__CYGWIN32__) || defined(__APPLE__)
+#elif defined (__CYGWIN32__) || defined(__APPLE__) || defined(__ANDROID__)
(void)setpgrp();
#else
(void)setpgrp(0, (int)getpid());
@@ -3159,7 +3159,7 @@ int setup_ping(aConfItem *aconf)
(void)close(udpfd);
return udpfd = -1;
}
- if (fcntl(udpfd, F_SETFL, FNDELAY)==-1)
+ if (fcntl(udpfd, F_SETFL, O_NONBLOCK)==-1)
{
Debug((DEBUG_ERROR, "fcntl fndelay : %s", strerror(errno)));
(void)close(udpfd);

View File

@ -0,0 +1,20 @@
--- a/support/Makefile.in
+++ b/support/Makefile.in
@@ -169,6 +169,8 @@
CHKCONF_OBJS = chkconf.o
CHKCONF = chkconf
+all: server
+
help:
@echo "Choose one of the following:"
@echo " all : build everything"
@@ -184,8 +186,6 @@
@echo " install-server : build and install server programs"
@echo " install-tkserv : build and install tkserv"
-all: server
-
server: $(IRCD_BIN) $(IAUTH) $(CHKCONF) ircd-mkpasswd $(IRCDWATCH)
$(IRCD_BIN): $(IRCD_COMMON_OBJS) $(IRCD_OBJS)