From 651b1d12b55cf895c75d31601a6171a90506c9c0 Mon Sep 17 00:00:00 2001 From: Maxim Sobolev Date: Wed, 19 Dec 2001 09:28:05 +0000 Subject: Add nspr 4.1.2, a platform-neutral API for system level and libc like functions. I bet Java folks would like it - because this port is required for Mozilla's Java plugin. --- devel/nspr/Makefile | 38 ++++++++ devel/nspr/distinfo | 1 + devel/nspr/files/patch-..::config::FreeBSD.mk | 51 ++++++++++ devel/nspr/files/patch-..::config::autoconf.mk.in | 14 +++ devel/nspr/files/patch-..::configure | 43 +++++++++ .../files/patch-..::pr::include::md::_freebsd.h | 22 +++++ devel/nspr/files/patch-..::pr::include::md::_pth.h | 23 +++++ devel/nspr/pkg-comment | 1 + devel/nspr/pkg-descr | 5 + devel/nspr/pkg-plist | 103 +++++++++++++++++++++ 10 files changed, 301 insertions(+) create mode 100644 devel/nspr/Makefile create mode 100644 devel/nspr/distinfo create mode 100644 devel/nspr/files/patch-..::config::FreeBSD.mk create mode 100644 devel/nspr/files/patch-..::config::autoconf.mk.in create mode 100644 devel/nspr/files/patch-..::configure create mode 100644 devel/nspr/files/patch-..::pr::include::md::_freebsd.h create mode 100644 devel/nspr/files/patch-..::pr::include::md::_pth.h create mode 100644 devel/nspr/pkg-comment create mode 100644 devel/nspr/pkg-descr create mode 100644 devel/nspr/pkg-plist (limited to 'devel/nspr') diff --git a/devel/nspr/Makefile b/devel/nspr/Makefile new file mode 100644 index 000000000000..a58f6de8a28a --- /dev/null +++ b/devel/nspr/Makefile @@ -0,0 +1,38 @@ +# Ports collection Makefile for: nspr +# Date created: 18 December 2001 +# Whom: Maxim Sobolev +# +# $FreeBSD$ +# + +PORTNAME= nspr +PORTVERSION= 4.1.2 +CATEGORIES= devel +MASTER_SITES= ftp://ftp.mozilla.org/pub/nspr/releases/v${PORTVERSION}/src/ + +MAINTAINER= gnome@FreeBSD.org + +WRKSRC= ${WRKDIR}/${DISTNAME}/mozilla/nsprpub/build + +INSTALLS_SHLIB= yes +USE_GMAKE= yes +GNU_CONFIGURE= yes +CONFIGURE_SCRIPT= ../configure +CONFIGURE_ARGS= --disable-debug \ + --with-pthreads +CONFIGURE_ENV= BSD_PTHREAD_LIBS=${PTHREAD_LIBS} +MAKE_ENV= DIST=${WRKSRC}/dist + +LIBS= libnspr4.so.1 libplc4.so.1 libplds4.so.1 + +do-install: + ${MKDIR} ${PREFIX}/include/nspr + ${TAR} -C ${WRKSRC}/dist/include --dereference -cf - . | \ + ${TAR} -C ${PREFIX}/include/nspr -xf - + ${TAR} -C ${WRKSRC}/dist/lib --dereference -cf - . | \ + ${TAR} -C ${PREFIX}/lib -xf - +.for lib in ${LIBS} + ${LN} -sf ${lib} ${PREFIX}/lib/${lib:S/.1$//} +.endfor + +.include diff --git a/devel/nspr/distinfo b/devel/nspr/distinfo new file mode 100644 index 000000000000..92437467828b --- /dev/null +++ b/devel/nspr/distinfo @@ -0,0 +1 @@ +MD5 (nspr-4.1.2.tar.gz) = cdbfa573242fa678766d19401f424567 diff --git a/devel/nspr/files/patch-..::config::FreeBSD.mk b/devel/nspr/files/patch-..::config::FreeBSD.mk new file mode 100644 index 000000000000..4d81665b8aa4 --- /dev/null +++ b/devel/nspr/files/patch-..::config::FreeBSD.mk @@ -0,0 +1,51 @@ + +$FreeBSD$ + +--- ../config/FreeBSD.mk.orig Sat Jul 29 03:50:35 2000 ++++ ../config/FreeBSD.mk Tue Dec 18 11:43:06 2001 +@@ -37,19 +37,21 @@ + + include $(MOD_DEPTH)/config/UNIX.mk + +-CC = gcc +-CCC = g++ ++CCC = $(CXX) + RANLIB = ranlib + ++# During FreeBSD port build, CFLAGS contains all of the optimizations ++# flags desired... ++OPTIMIZER = $(MOZ_OPTIMIZE_FLAGS) ++ + ifeq ($(OS_TEST),alpha) + CPU_ARCH = alpha + else +-OS_REL_CFLAGS = -Di386 + CPU_ARCH = x86 + endif + CPU_ARCH_TAG = _$(CPU_ARCH) + +-OS_CFLAGS = $(DSO_CFLAGS) $(OS_REL_CFLAGS) -ansi -Wall -pipe $(THREAD_FLAG) -DFREEBSD -DHAVE_STRERROR -DHAVE_BSD_FLOCK ++OS_CFLAGS = $(DSO_CFLAGS) $(OS_REL_CFLAGS) -ansi -Wall -pipe -DFREEBSD -DHAVE_STRERROR -DHAVE_BSD_FLOCK + + # + # The default implementation strategy for FreeBSD is pthreads. +@@ -60,8 +62,8 @@ + else + USE_PTHREADS = 1 + IMPL_STRATEGY = _PTH +-DEFINES += -D_THREAD_SAFE +-THREAD_FLAG += -pthread ++DEFINES += -D_THREAD_SAFE -D_REENTRANT ++DSO_LDOPTS += -pthread + endif + + ARCH = freebsd +@@ -75,7 +77,7 @@ + endif + + DSO_CFLAGS = -fPIC +-DSO_LDOPTS = -Bshareable ++DSO_LDOPTS += -Bshareable + + MKSHLIB = $(LD) $(DSO_LDOPTS) + diff --git a/devel/nspr/files/patch-..::config::autoconf.mk.in b/devel/nspr/files/patch-..::config::autoconf.mk.in new file mode 100644 index 000000000000..f35630a74f81 --- /dev/null +++ b/devel/nspr/files/patch-..::config::autoconf.mk.in @@ -0,0 +1,14 @@ + +$FreeBSD$ + +--- ../config/autoconf.mk.in.orig Thu Feb 24 01:37:44 2000 ++++ ../config/autoconf.mk.in Tue Dec 18 11:24:06 2001 +@@ -1,7 +1,7 @@ + + USE_AUTOCONF = 1 + MOZILLA_CLIENT = @MOZILLA_CLIENT@ +-DIST = @prefix@ ++DIST ?= @prefix@ + OBJDIR_NAME = . + OBJDIR = . + OBJ_SUFFIX = @OBJ_SUFFIX@ diff --git a/devel/nspr/files/patch-..::configure b/devel/nspr/files/patch-..::configure new file mode 100644 index 000000000000..1ba08707ebdd --- /dev/null +++ b/devel/nspr/files/patch-..::configure @@ -0,0 +1,43 @@ + +$FreeBSD$ + +--- ../configure.orig Sat Jul 8 14:25:25 2000 ++++ ../configure Tue Dec 18 11:54:54 2001 +@@ -2547,15 +2547,16 @@ + #define HAVE_BSD_FLOCK 1 + EOF + +- CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall -pipe" ++ CFLAGS="$CFLAGS $DSO_CFLAGS -ansi -Wall -pipe -DXP_UNIX" + MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo aout` + if test "$MOZ_OBJFORMAT" = "elf"; then +- DLL_SUFFIX=so ++ DLL_SUFFIX=so.1 + else + DLL_SUFFIX=so.1.0 + fi ++ MKSHLIB='$(CC) $(DSO_LDOPTS) -o $@' + DSO_CFLAGS=-fPIC +- DSO_LDOPTS=-Bshareable ++ DSO_LDOPTS="-shared $BSD_PTHREAD_LIBS" + MDCPUCFG_H=_freebsd.cfg + PR_MD_CSRCS=freebsd.c + ;; +@@ -3516,8 +3517,6 @@ + if test $? -eq 0; then + if test -z "`egrep -i '(unrecognize|unknown)' conftest.out | grep pthread`" && test -z "`egrep -i '(error|incorrect)' conftest.out`" ; then + ac_cv_have_dash_pthread=yes +- CFLAGS="$CFLAGS -pthread" +- CXXFLAGS="$CXXFLAGS -pthread" + fi + fi + rm -f conftest* +@@ -3542,7 +3541,7 @@ + EOF + + if test "$ac_cv_have_dash_pthread" = "yes"; then +- PTHREAD_LDFLAGS= ++ PTHREAD_LDFLAGS="-pthread" + fi + ;; + *-hpuxB.10.10*) diff --git a/devel/nspr/files/patch-..::pr::include::md::_freebsd.h b/devel/nspr/files/patch-..::pr::include::md::_freebsd.h new file mode 100644 index 000000000000..10e3b37b6a59 --- /dev/null +++ b/devel/nspr/files/patch-..::pr::include::md::_freebsd.h @@ -0,0 +1,22 @@ + +$FreeBSD$ + +--- ../pr/include/md/_freebsd.h.orig Wed Jun 21 00:22:19 2000 ++++ ../pr/include/md/_freebsd.h Tue Dec 18 11:24:06 2001 +@@ -37,6 +37,7 @@ + + #include "prthread.h" + ++#include + #include + + #define PR_LINKER_ARCH "freebsd" +@@ -65,7 +66,7 @@ + #define _PR_HAVE_SOCKADDR_LEN + #define _PR_STAT_HAS_ST_ATIMESPEC + #define _PR_NO_LARGE_FILES +-#if ( __FreeBSD__ > 2 ) ++#if ( __FreeBSD_version >= 220000 ) && ( __FreeBSD_version < 400008 ) + #if !defined(_PR_PTHREADS) + /* + * libc_r doesn't have poll(). Although libc has poll(), it is not diff --git a/devel/nspr/files/patch-..::pr::include::md::_pth.h b/devel/nspr/files/patch-..::pr::include::md::_pth.h new file mode 100644 index 000000000000..eb035367a56b --- /dev/null +++ b/devel/nspr/files/patch-..::pr::include::md::_pth.h @@ -0,0 +1,23 @@ + +$FreeBSD$ + +--- ../pr/include/md/_pth.h.orig Wed Jun 21 00:23:43 2000 ++++ ../pr/include/md/_pth.h Tue Dec 18 11:24:06 2001 +@@ -199,7 +199,7 @@ + #define PT_PRIO_MAX sched_get_priority_max(SCHED_OTHER) + #endif /* defined(_PR_DCETHREADS) */ + +-#elif defined(LINUX) ++#elif defined(LINUX) || defined(FREEBSD) + #define PT_PRIO_MIN sched_get_priority_min(SCHED_OTHER) + #define PT_PRIO_MAX sched_get_priority_max(SCHED_OTHER) + #elif defined(NTO) +@@ -219,7 +219,7 @@ + */ + #define PT_PRIO_MIN 1 + #define PT_PRIO_MAX 127 +-#elif defined(FREEBSD) || defined(NETBSD) || defined(OPENBSD) \ ++#elif defined(NETBSD) || defined(OPENBSD) \ + || defined(BSDI) || defined(RHAPSODY) /* XXX */ + #define PT_PRIO_MIN 0 + #define PT_PRIO_MAX 126 diff --git a/devel/nspr/pkg-comment b/devel/nspr/pkg-comment new file mode 100644 index 000000000000..dcd7e8191984 --- /dev/null +++ b/devel/nspr/pkg-comment @@ -0,0 +1 @@ +A platform-neutral API for system level and libc like functions diff --git a/devel/nspr/pkg-descr b/devel/nspr/pkg-descr new file mode 100644 index 000000000000..938c027015f5 --- /dev/null +++ b/devel/nspr/pkg-descr @@ -0,0 +1,5 @@ +Netscape Portable Runtime (NSPR) provides a platform-neutral API for system +level and libc like functions. The API is used in the Mozilla client, many of +Netscape/AOL/iPlanet's and other software offerings. + +WWW: http://www.mozilla.org/projects/nspr/index.html diff --git a/devel/nspr/pkg-plist b/devel/nspr/pkg-plist new file mode 100644 index 000000000000..ed3a1d00dce9 --- /dev/null +++ b/devel/nspr/pkg-plist @@ -0,0 +1,103 @@ +include/nspr/md/_aix32.cfg +include/nspr/md/_aix32in6.cfg +include/nspr/md/_aix64.cfg +include/nspr/md/_beos.cfg +include/nspr/md/_bsdi.cfg +include/nspr/md/_dgux.cfg +include/nspr/md/_freebsd.cfg +include/nspr/md/_hpux32.cfg +include/nspr/md/_hpux64.cfg +include/nspr/md/_irix32.cfg +include/nspr/md/_irix64.cfg +include/nspr/md/_linux.cfg +include/nspr/md/_ncr.cfg +include/nspr/md/_nec.cfg +include/nspr/md/_netbsd.cfg +include/nspr/md/_nextstep.cfg +include/nspr/md/_nto.cfg +include/nspr/md/_openbsd.cfg +include/nspr/md/_openvms.cfg +include/nspr/md/_os2.cfg +include/nspr/md/_osf1.cfg +include/nspr/md/_qnx.cfg +include/nspr/md/_reliantunix.cfg +include/nspr/md/_rhapsody.cfg +include/nspr/md/_scoos.cfg +include/nspr/md/_solaris32.cfg +include/nspr/md/_solaris64.cfg +include/nspr/md/_sony.cfg +include/nspr/md/_sunos4.cfg +include/nspr/md/_unixware.cfg +include/nspr/md/_unixware7.cfg +include/nspr/md/_win16.cfg +include/nspr/md/_win95.cfg +include/nspr/md/_winnt.cfg +include/nspr/nspr.h +include/nspr/obsolete/pralarm.h +include/nspr/obsolete/probslet.h +include/nspr/obsolete/protypes.h +include/nspr/obsolete/prsem.h +include/nspr/plarena.h +include/nspr/plarenas.h +include/nspr/plbase64.h +include/nspr/plerror.h +include/nspr/plgetopt.h +include/nspr/plhash.h +include/nspr/plresolv.h +include/nspr/plstr.h +include/nspr/pratom.h +include/nspr/prbit.h +include/nspr/prclist.h +include/nspr/prcmon.h +include/nspr/prcountr.h +include/nspr/prcpucfg.h +include/nspr/prcvar.h +include/nspr/prdtoa.h +include/nspr/prenv.h +include/nspr/prerr.h +include/nspr/prerror.h +include/nspr/prinet.h +include/nspr/prinit.h +include/nspr/prinrval.h +include/nspr/prio.h +include/nspr/pripcsem.h +include/nspr/private/pprio.h +include/nspr/private/pprthred.h +include/nspr/private/prpriv.h +include/nspr/prlink.h +include/nspr/prlock.h +include/nspr/prlog.h +include/nspr/prlong.h +include/nspr/prmem.h +include/nspr/prmon.h +include/nspr/prmwait.h +include/nspr/prnetdb.h +include/nspr/prolock.h +include/nspr/prpdce.h +include/nspr/prprf.h +include/nspr/prproces.h +include/nspr/prrng.h +include/nspr/prrwlock.h +include/nspr/prshm.h +include/nspr/prshma.h +include/nspr/prsystem.h +include/nspr/prthread.h +include/nspr/prtime.h +include/nspr/prtpool.h +include/nspr/prtrace.h +include/nspr/prtypes.h +include/nspr/prvrsion.h +include/nspr/prwin16.h +lib/libnspr4.a +lib/libnspr4.so +lib/libnspr4.so.1 +lib/libplc4.a +lib/libplc4.so +lib/libplc4.so.1 +lib/libplds4.a +lib/libplds4.so +lib/libplds4.so.1 +@dirrm include/nspr/private +@dirrm include/nspr/obsolete +@dirrm include/nspr/md +@dirrm include/nspr -- cgit v1.2.3