libunp is the library used in W. Richard Steven's book "UNIX Network

Programming Volume 2, 2nd Edition".  It contains the library and headers
used in the examples as well as all programs from the text that compile on
FreeBSD systems.

For more information on the book, see

http://www.phptr.com/ptrbooks/ptr_013490012X.html

For more info on W. Richard Stevens, see

http://www.kohala.com/~rstevens/

PR: ports/14058
Submitted by: James FitzGibbon <james@targetnet.com>
This commit is contained in:
Dan Moschuk 1999-10-02 19:17:58 +00:00
parent c12969bb2c
commit 1f4049bf91
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=22130
10 changed files with 138 additions and 0 deletions

30
net/libunpipc/Makefile Normal file
View file

@ -0,0 +1,30 @@
# Ports collection makefile for: libunpipc
# Version required: 1.0
# Date created: Sept 28, 1999
# Whom: james@targetnet.com
#
# $FreeBSD$
#
DISTNAME= unpv22e
PKGNAME= libunpipc-1.0
CATEGORIES= net
MASTER_SITES= ftp://ftp.kohala.com/pub/rstevens/ \
http://compass.net.edu.cn:8000/programming/
MAINTAINER= james@targetnet.com
GNU_CONFIGURE= yes
USE_GMAKE= yes
.include <bsd.port.pre.mk>
post-configure:
ln -s ${WRKSRC}/config.h ${WRKSRC}/unpipc_config.h
do-install:
${INSTALL_DATA} ${WRKSRC}/libunpipc.a ${PREFIX}/lib
${INSTALL_DATA} ${WRKSRC}/lib/unpipc.h ${PREFIX}/include
${INSTALL_DATA} ${WRKSRC}/config.h ${PREFIX}/include/unpipc_config.h
.include <bsd.port.post.mk>

1
net/libunpipc/distinfo Normal file
View file

@ -0,0 +1 @@
MD5 (unpv22e.tar.gz) = 668fdb55452859c13b44a7049a40071a

View file

@ -0,0 +1,18 @@
--- Makefile.in.orig Fri Apr 11 18:42:26 1997
+++ Makefile.in Thu Sep 30 10:24:12 1999
@@ -1,8 +1,13 @@
include ./Make.defines
+SUBDIRS = lib
+
all:
- @echo "Nothing to make in this directory"
- @echo "Please read the README file"
+ PWD=`pwd`; \
+ for dir in $(SUBDIRS) ; \
+ do \
+ cd $$PWD/$$dir && $(MAKE) && cd .. ;\
+ done
clean:
rm -f $(CLEANFILES)

View file

@ -0,0 +1,13 @@
--- configure.orig Tue Sep 28 11:52:17 1999
+++ configure Tue Sep 28 11:52:24 1999
@@ -2894,10 +2894,6 @@
LIB_OBJS="$LIB_OBJS signal.o"
LIB_OBJS="$LIB_OBJS signal_intr.o"
LIB_OBJS="$LIB_OBJS sleep_us.o"
-if test $ac_cv_have_siginfo_t_struct = yes ; then
- LIB_OBJS="$LIB_OBJS signal_rt.o"
- LIB_OBJS="$LIB_OBJS signal_rt_intr.o"
-fi
if test "$ac_cv_func_snprintf" = no ; then
LIB_OBJS="$LIB_OBJS snprintf.o"
fi

View file

@ -0,0 +1,11 @@
--- lib/unpipc.h.orig Wed Aug 5 14:20:32 1998
+++ lib/unpipc.h Thu Sep 30 10:23:56 1999
@@ -4,7 +4,7 @@
#ifndef __unpipc_h
#define __unpipc_h
-#include "../config.h" /* configuration options for current OS */
+#include <unpipc_config.h> /* configuration options for current OS */
/* "../config.h" is generated by configure */
/* If anything changes in the following list of #includes, must change

View file

@ -0,0 +1,11 @@
--- lib/Makefile.orig Thu Sep 30 10:33:02 1999
+++ lib/Makefile Thu Sep 30 10:33:09 1999
@@ -1,7 +1,7 @@
include ../Make.defines
# Following required by Solaris 2.x for Posix version of sigwait().
-CFLAGS += -D_POSIX_PTHREAD_SEMANTICS
+CFLAGS += -D_POSIX_PTHREAD_SEMANTICS -I..
all: ${LIB_OBJS}
ar rv ${LIBUNPIPC_NAME} $?

View file

@ -0,0 +1,38 @@
--- lib/wrappthread.c.orig Thu Sep 30 11:03:00 1999
+++ lib/wrappthread.c Thu Sep 30 11:04:50 1999
@@ -83,17 +83,6 @@
}
void
-Pthread_kill(pthread_t tid, int signo)
-{
- int n;
-
- if ( (n = pthread_kill(tid, signo)) == 0)
- return;
- errno = n;
- err_sys("pthread_kill error");
-}
-
-void
Pthread_mutexattr_init(pthread_mutexattr_t *attr)
{
int n;
@@ -274,17 +263,6 @@
return;
errno = n;
err_sys("pthread_key_create error");
-}
-
-void
-Pthread_setcancelstate(int state, int *oldstate)
-{
- int n;
-
- if ( (n = pthread_setcancelstate(state, oldstate)) == 0)
- return;
- errno = n;
- err_sys("pthread_setcancelstate error");
}
void

View file

@ -0,0 +1 @@
The networking library used in UNIX Network Programming Volume 2 2e

12
net/libunpipc/pkg-descr Normal file
View file

@ -0,0 +1,12 @@
libunp is the library used in W. Richard Steven's book "UNIX Network
Programming Volume 2, 2nd Edition". It contains the library and headers
used in the examples as well as all programs from the text that compile on
FreeBSD systems.
For more information on the book, see
http://www.phptr.com/ptrbooks/ptr_013490012X.html
For more info on W. Richard Stevens, see
http://www.kohala.com/~rstevens/

3
net/libunpipc/pkg-plist Normal file
View file

@ -0,0 +1,3 @@
include/unpipc.h
include/unpipc_config.h
lib/libunpipc.a