diff options
-rw-r--r-- | devel/nspr/Makefile | 1 | ||||
-rw-r--r-- | devel/nspr/files/patch-bug1350414 | 55 | ||||
-rw-r--r-- | devel/nspr/files/patch-bug1350966 | 17 |
3 files changed, 73 insertions, 0 deletions
diff --git a/devel/nspr/Makefile b/devel/nspr/Makefile index cf5823d..a112413 100644 --- a/devel/nspr/Makefile +++ b/devel/nspr/Makefile @@ -3,6 +3,7 @@ PORTNAME= nspr DISTVERSION= 4.14 +PORTREVISION= 1 CATEGORIES= devel MASTER_SITES= MOZILLA/${PORTNAME}/releases/v${PORTVERSION}/src diff --git a/devel/nspr/files/patch-bug1350414 b/devel/nspr/files/patch-bug1350414 new file mode 100644 index 0000000..3af6134 --- /dev/null +++ b/devel/nspr/files/patch-bug1350414 @@ -0,0 +1,55 @@ +--- configure~ ++++ configure +@@ -6730,6 +6730,8 @@ tools are selected during the Xcode/Developer Tools installation." "$LINENO" 5 + + $as_echo "#define HAVE_SOCKLEN_T 1" >>confdefs.h + ++ $as_echo "#define HAVE_POINTER_LOCALTIME_R 1" >>confdefs.h ++ + CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall" + MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo elf` + if test "$MOZ_OBJFORMAT" = "elf"; then +@@ -7340,6 +7342,8 @@ $as_echo "$as_me: WARNING: Unknown version of the Microsoft (R) Manifest Tool." + + $as_echo "#define HAVE_SOCKLEN_T 1" >>confdefs.h + ++ $as_echo "#define HAVE_POINTER_LOCALTIME_R 1" >>confdefs.h ++ + if test -z "$USE_NSPR_THREADS"; then + USE_PTHREADS=1 + fi +@@ -7396,6 +7400,8 @@ $as_echo "$as_me: WARNING: Unknown version of the Microsoft (R) Manifest Tool." + + $as_echo "#define HAVE_SOCKLEN_T 1" >>confdefs.h + ++ $as_echo "#define HAVE_POINTER_LOCALTIME_R 1" >>confdefs.h ++ + CFLAGS="$CFLAGS -ansi -Wall" + CXXFLAGS="$CXXFLAGS -ansi -Wall" + DLL_SUFFIX=so.1.0 +--- configure.in~ ++++ configure.in +@@ -1554,6 +1554,7 @@ tools are selected during the Xcode/Developer Tools installation.]) + AC_DEFINE(FREEBSD) + AC_DEFINE(HAVE_BSD_FLOCK) + AC_DEFINE(HAVE_SOCKLEN_T) ++ AC_DEFINE(HAVE_POINTER_LOCALTIME_R) + CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall" + MOZ_OBJFORMAT=`test -x /usr/bin/objformat && /usr/bin/objformat || echo elf` + if test "$MOZ_OBJFORMAT" = "elf"; then +@@ -2114,6 +2115,7 @@ tools are selected during the Xcode/Developer Tools installation.]) + AC_DEFINE(NETBSD) + AC_DEFINE(HAVE_BSD_FLOCK) + AC_DEFINE(HAVE_SOCKLEN_T) ++ AC_DEFINE(HAVE_POINTER_LOCALTIME_R) + if test -z "$USE_NSPR_THREADS"; then + USE_PTHREADS=1 + fi +@@ -2162,6 +2164,7 @@ tools are selected during the Xcode/Developer Tools installation.]) + AC_DEFINE(OPENBSD) + AC_DEFINE(HAVE_BSD_FLOCK) + AC_DEFINE(HAVE_SOCKLEN_T) ++ AC_DEFINE(HAVE_POINTER_LOCALTIME_R) + CFLAGS="$CFLAGS -ansi -Wall" + CXXFLAGS="$CXXFLAGS -ansi -Wall" + DLL_SUFFIX=so.1.0 diff --git a/devel/nspr/files/patch-bug1350966 b/devel/nspr/files/patch-bug1350966 new file mode 100644 index 0000000..62748ab --- /dev/null +++ b/devel/nspr/files/patch-bug1350966 @@ -0,0 +1,17 @@ +--- pr/src/pthreads/ptsynch.c~ ++++ pr/src/pthreads/ptsynch.c +@@ -55,12 +55,11 @@ void _PR_InitLocks(void) + rv = _PT_PTHREAD_MUTEXATTR_INIT(&_pt_mattr); + PR_ASSERT(0 == rv); + +-#ifdef LINUX +-#if (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) ++#if (defined(LINUX) && (__GLIBC__ > 2) || (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2)) || \ ++ (defined(FREEBSD) && __FreeBSD_version > 700055) + rv = pthread_mutexattr_settype(&_pt_mattr, PTHREAD_MUTEX_ADAPTIVE_NP); + PR_ASSERT(0 == rv); + #endif +-#endif + + rv = _PT_PTHREAD_CONDATTR_INIT(&_pt_cvar_attr); + PR_ASSERT(0 == rv); |