partial mozilla patches attached
Alexander Sack
asac@jwsdot.com
Fri, 03 Dec 2004 22:43:57 +0100
This is a multi-part message in MIME format.
--------------090008040909040108000808
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Hi,
attached the patches against the mozilla debian package. Just apply
those patches after the debian patches have been applied and it should
build cleanly (ok, for now you still have to regenerate the configure
scripts after applying those patches of course)
Nevertheless, it will choke when linking the main prog (mozilla-bin)
because of some weird linking behaviour. Though the -L/usr/X11R6/lib
flag is provided during linking, the linker complains because libraries
referenced by libgdk-x11.so is are not found (e.g. libXi.so).
This problem can be solved by setting the LD_LIBRARY_PATH=/usr/X11R6/lib
path for now e.g. in the debian/rules script, but should be reason
enough for further investigations.
Anyway, the resulting build will leave you with a quite disfunctional
mozilla mockup :(. It will be displayed properly. Nevertheless, all
events are somehow disfunctional and therefore mozilla cannot be said to
be in good shape. Maybe a debug build will reveal this problem. But not
now :)
Cheers,
Alexander
--
GPG messages preferred. | .''`. ** Debian GNU/Linux **
Alexander Sack | : :' : The universal
asac@jwsdot.com | `. `' Operating System
http://www.jwsdot.com/ | `- http://www.debian.org/
--------------090008040909040108000808
Content-Type: text/x-patch;
name="directory_new1.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="directory_new1.diff"
diff -uwr mozilla.orig/directory/c-sdk/config/Makefile mozilla/directory/c-sdk/config/Makefile
--- mozilla.orig/directory/c-sdk/config/Makefile 2004-02-11 05:01:16.000000000 +0100
+++ mozilla/directory/c-sdk/config/Makefile 2004-12-02 12:41:01.000000000 +0100
@@ -48,11 +48,15 @@
include $(topsrcdir)/config/config.mk
-CSRCS = nsinstall.c now.c
+ifndef MOZILLA_CLIENT
+CSRCS = nsinstall.c
+endif
+
+CSRCS += now.c
PLSRCS = nfspwd.pl
-ifneq (,$(filter WINNT OS2,$(OS_ARCH)))
+ifneq (,$(CROSS_COMPILE)$(filter WINNT OS2,$(OS_ARCH)))
PROG_SUFFIX = .exe
else
PROG_SUFFIX =
@@ -92,9 +96,9 @@
XLDOPTS += $(LDFLAGS)
endif
-ifdef XP_OS2_EMX
+ifeq ($(MOZ_OS2_TOOLS),EMX)
XCFLAGS = $(OS_EXE_CFLAGS)
-XLDOPTS = -Zlinker /PM:VIO
+XLDOPTS = -Zomf -Zlinker /PM:VIO
endif
ifeq ($(MOZ_OS2_TOOLS),VACPP)
@@ -114,8 +118,10 @@
OUTOPTION = -o # end of the line
ifeq (,$(filter-out WINNT OS2,$(OS_ARCH)))
+ifndef NS_USE_GCC
OUTOPTION = /Fe
endif
+endif
# Redefine MAKE_OBJDIR for just this directory
define MAKE_OBJDIR
--- mozilla.orig/directory/c-sdk/config/nsinstall.c 2002-03-27 11:06:18.000000000 +0100
+++ mozilla/directory/c-sdk/config/nsinstall.c 2004-11-03 18:34:32.000000000 +0100
@@ -64,7 +64,7 @@
#if defined(AIX) || defined(BSDI) || defined(HPUX) || defined(LINUX) \
|| defined(SUNOS4) || defined(SCO) || defined(UNIXWARE) \
|| defined(RHAPSODY) || defined(NEXTSTEP) || defined(QNX) \
- || defined(BEOS) || defined(VMS) || defined(DARWIN)
+ || defined(BEOS) || defined(VMS) || defined(DARWIN) || defined(GLIBC)
#undef HAVE_LCHOWN
#endif
@@ -106,7 +106,7 @@
}
#endif /* NEXTSTEP */
-#ifdef LINUX
+#if defined(LINUX) || defined(GLIBC)
#include <getopt.h>
#endif
diff -uwr mozilla.orig/directory/c-sdk/configure.in mozilla/directory/c-sdk/configure.in
--- mozilla.orig/directory/c-sdk/configure.in 2004-03-30 21:38:43.000000000 +0200
+++ mozilla/directory/c-sdk/configure.in 2004-11-13 16:20:25.000000000 +0100
@@ -1123,7 +1123,7 @@
esac
;;
-*-linux*)
+*-linux*|*-kfreebsd*)
if test -z "$USE_NSPR_THREADS"; then
USE_PTHREADS=1
IMPL_STRATEGY=_PTH
diff -uwr mozilla.orig/directory/c-sdk/ldap/include/portable.h mozilla/directory/c-sdk/ldap/include/portable.h
--- mozilla.orig/directory/c-sdk/ldap/include/portable.h 2003-09-17 05:18:10.000000000 +0200
+++ mozilla/directory/c-sdk/ldap/include/portable.h 2004-11-03 14:41:28.000000000 +0100
@@ -116,7 +116,7 @@
* some systems don't have the BSD re_comp and re_exec routines
*/
#ifndef NEED_BSDREGEX
-#if ( defined( SYSV ) || defined( NETBSD ) || defined( freebsd ) || defined( linux ) || defined( DARWIN )) && !defined(sgi)
+#if ( defined( SYSV ) || defined( NETBSD ) || defined( freebsd ) || defined( linux ) || defined(__GNU__) || defined(__GLIBC__) || defined( DARWIN )) && !defined(sgi)
#define NEED_BSDREGEX
#endif
#endif
@@ -145,7 +145,7 @@
* Is snprintf() part of the standard C runtime library?
*/
#if !defined(HAVE_SNPRINTF)
-#if defined(SOLARIS) || defined(LINUX) || defined(HPUX)
+#if defined(SOLARIS) || defined(LINUX) || defined(__GNU__) || defined(__GLIBC__) || defined(HPUX)
#define HAVE_SNPRINTF
#endif
#endif
@@ -165,7 +165,7 @@
* for select()
*/
#if !defined(WINSOCK) && !defined(_WINDOWS) && !defined(macintosh) && !defined(XP_OS2)
-#if defined(hpux) || defined(LINUX) || defined(SUNOS4) || defined(XP_BEOS)
+#if defined(hpux) || defined(LINUX) || defined(__GNU__) || defined(__GLIBC__) || defined(SUNOS4) || defined(XP_BEOS)
#include <sys/time.h>
#else
#include <sys/select.h>
@@ -252,15 +252,14 @@
#define HAVE_GETGRNAM_R
#endif
-#if defined(SNI) || defined(LINUX1_2)
+#if defined(SNI) || defined(LINUX1_2) || defined(__GNU__) || defined(__GLIBC__)
int strcasecmp(const char *, const char *);
#ifdef SNI
int strncasecmp(const char *, const char *, int);
-#endif /* SNI */
-#ifdef LINUX1_2
+#else /* SNI */
int strncasecmp(const char *, const char *, size_t);
-#endif /* LINUX1_2 */
-#endif /* SNI || LINUX1_2 */
+#endif
+#endif /* SNI || LINUX1_2 || __GNU__ || __GLIBC__ */
#if defined(_WINDOWS) || defined(macintosh) || defined(XP_OS2) || defined(DARWIN)
#define GETHOSTBYNAME( n, r, b, l, e ) gethostbyname( n )
@@ -276,7 +275,7 @@
defined(UNIXWARE) || defined(SUNOS4) || defined(SNI) || defined(BSDI) || \
defined(NCR) || defined(OSF1) || defined(NEC) || defined(VMS) || \
( defined(HPUX10) && !defined(_REENTRANT)) || defined(HPUX11) || \
- defined(UnixWare) || defined(LINUX) || defined(NETBSD) || \
+ defined(UnixWare) || defined(LINUX) || defined(__GNU__) || defined(__GLIBC__) || defined(NETBSD) || \
defined(FREEBSD) || defined(OPENBSD) || \
(defined(AIX) && !defined(USE_REENTRANT_LIBC))
#define GETHOSTBYNAME( n, r, b, l, e ) gethostbyname( n )
@@ -300,7 +299,7 @@
#define GETHOSTBYNAME( n, r, b, l, e ) gethostbyname_r( n, r, b, l, e )
#endif
#if defined(HPUX9) || defined(LINUX1_2) || defined(LINUX2_0) || \
- defined(LINUX2_1) || defined(SUNOS4) || defined(SNI) || \
+ defined(LINUX2_1) || defined(__GNU__) || defined(__GLIBC__) || defined(SUNOS4) || defined(SNI) || \
defined(SCOOS) || defined(BSDI) || defined(NCR) || \
defined(NEC) || ( defined(HPUX10) && !defined(_REENTRANT)) || \
(defined(AIX) && !defined(USE_REENTRANT_LIBC))
@@ -320,7 +319,7 @@
#endif
#if defined(hpux9) || defined(LINUX1_2) || defined(SUNOS4) || defined(SNI) || \
defined(SCOOS) || defined(BSDI) || defined(NCR) || defined(VMS) || \
- defined(NEC) || defined(LINUX) || (defined(AIX) && !defined(USE_REENTRANT_LIBC))
+ defined(NEC) || defined(LINUX) || defined(__GNU__) || defined(__GLIBC__) || (defined(AIX) && !defined(USE_REENTRANT_LIBC))
#define STRTOK( s1, s2, l ) strtok( s1, s2 )
#else
#define HAVE_STRTOK_R
diff -uwr mozilla.orig/directory/c-sdk/ldap/libraries/libldap/Makefile.in mozilla/directory/c-sdk/ldap/libraries/libldap/Makefile.in
--- mozilla.orig/directory/c-sdk/ldap/libraries/libldap/Makefile.in 2004-12-03 15:45:16.000000000 +0100
+++ mozilla/directory/c-sdk/ldap/libraries/libldap/Makefile.in 2004-11-03 15:31:39.000000000 +0100
@@ -168,7 +168,7 @@
EXTRA_LIBS = -L$(dist_libdir) -l$(LBER_LIBNAME) $(OS_LIBS) -lc
endif
-ifeq ($(OS_ARCH), Linux)
+ifneq (,$(findstring $(OS_ARCH),Linux GNU_kFreeBSD))
EXTRA_LIBS = -L$(dist_libdir) -l$(LBER_LIBNAME) -lpthread
endif
@@ -286,7 +286,7 @@
ifdef SO_FILES_TO_REMOVE
-$(RM) $(SO_FILES_TO_REMOVE)
endif
-ifneq (,$(filter AIX Linux HP-UX Darwin BeOS QNX NetBSD OSF1 OpenBSD, $(OS_ARCH)))
+ifneq (,$(findstring $(OS_ARCH),AIX Linux GNU HP-UX Darwin BeOS QNX NetBSD OSF1 OpenBSD))
$(LINK_LIB) ../liblber/$(OBJDIR_NAME)/*.a
else
ifeq ($(OS_ARCH),OS2)
diff -uwr mozilla.orig/directory/c-sdk/ldap/libraries/libldap/request.c mozilla/directory/c-sdk/ldap/libraries/libldap/request.c
--- mozilla.orig/directory/c-sdk/ldap/libraries/libldap/request.c 2002-03-26 22:53:46.000000000 +0100
+++ mozilla/directory/c-sdk/ldap/libraries/libldap/request.c 2004-11-03 18:35:33.000000000 +0100
@@ -627,7 +627,7 @@
LDAPConn *lc;
char msg[256];
/* CTIME for this platform doesn't use this. */
-#if !defined(SUNOS4) && !defined(_WIN32) && !defined(LINUX) && !defined(macintosh)
+#if !defined(SUNOS4) && !defined(_WIN32) && !defined(LINUX) && !defined(macintosh) && !defined(GLIBC)
char buf[26];
#endif
diff -uwr mozilla.orig/directory/c-sdk/ldap/libraries/libldap/tmplout.c mozilla/directory/c-sdk/ldap/libraries/libldap/tmplout.c
--- mozilla.orig/directory/c-sdk/ldap/libraries/libldap/tmplout.c 2002-03-26 22:53:52.000000000 +0100
+++ mozilla/directory/c-sdk/ldap/libraries/libldap/tmplout.c 2004-11-03 18:36:48.000000000 +0100
@@ -903,7 +903,8 @@
time_t gmttime;
/* CTIME for this platform doesn't use this. */
#if !defined(SUNOS4) && !defined(BSDI) && !defined(LINUX1_2) && \
- !defined(SNI) && !defined(_WIN32) && !defined(macintosh) && !defined(LINUX)
+ !defined(SNI) && !defined(_WIN32) && !defined(macintosh) && !defined(LINUX) && \
+ !defined(KFREEBSD)
char buf[26];
#endif
diff -uwr mozilla.orig/directory/c-sdk/ldap/libraries/libprldap/Makefile.in mozilla/directory/c-sdk/ldap/libraries/libprldap/Makefile.in
--- mozilla.orig/directory/c-sdk/ldap/libraries/libprldap/Makefile.in 2004-12-03 15:45:16.000000000 +0100
+++ mozilla/directory/c-sdk/ldap/libraries/libprldap/Makefile.in 2004-11-03 16:31:12.000000000 +0100
@@ -93,7 +93,7 @@
GENEXPARGS=$(BUILD_DEBUG) $(PRLDAPVERS_SUFFIX) $(PRLDAPVERS)
endif # USE_DLL_EXPORTS_FILE
-ifeq ($(OS_ARCH), Linux)
+ifneq (,$(findstring $(OS_ARCH),Linux GNU_kFreeBSD))
EXTRA_LIBS = -L$(dist_libdir) -l$(LDAP_LIBNAME)
EXTRA_LIBS += -L$(dist_libdir) $(DYNAMICNSPR)
endif
diff -uwr mozilla.orig/directory/c-sdk/ldap/libraries/libssldap/Makefile mozilla/directory/c-sdk/ldap/libraries/libssldap/Makefile
--- mozilla.orig/directory/c-sdk/ldap/libraries/libssldap/Makefile 2004-02-11 05:01:15.000000000 +0100
+++ mozilla/directory/c-sdk/ldap/libraries/libssldap/Makefile 2004-12-02 12:41:05.000000000 +0100
@@ -92,6 +92,15 @@
endif
ifeq ($(OS_ARCH), WINNT)
+ifdef NS_USE_GCC
+EXTRA_DLL_LIBS = -L$(dist_libdir) -l$(LDAP_LIBNAME) -l$(PRLDAP_LIBNAME) \
+ -l$(NSS_LIBNAME)
+ifeq ($(NSS_DYNAMIC_SOFTOKN),1)
+EXTRA_DLL_LIBS += -l$(SOFTOKN_LIBNAME)
+endif
+EXTRA_DLL_LIBS += -l$(SSL_LIBNAME) \
+ -l$(PLC_BASENAME) -l$(PLDS_BASENAME) -l$(NSPR_BASENAME)
+else
EXTRA_LIBS =wsock32.lib kernel32.lib user32.lib gdi32.lib winspool.lib \
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib \
rpcrt4.lib uuid.lib odbc32.lib odbccp32.lib winmm.lib
@@ -106,6 +115,7 @@
endif
EXTRA_LIBS += $(dist_libdir)/$(SSL_LIBNAME).lib
endif
+endif
ifeq ($(OS_ARCH),OS2)
EXTRA_LIBS = $(OS_LIBS)
--- mozilla.orig/directory/c-sdk/ldap/libraries/libprldap/ldappr-error.c 2003-03-25 14:57:38.000000000 +0100
+++ mozilla/directory/c-sdk/ldap/libraries/libprldap/ldappr-error.c 2004-12-03 16:11:51.000000000 +0100
@@ -218,7 +218,7 @@
#if defined(__hpux) || defined(_AIX) || defined(OSF1) || defined(DARWIN) || \
defined(BEOS) || defined(FREEBSD) || defined(BSDI) || defined(VMS) || \
- defined(OPENBSD) || defined(NETBSD)
+ defined(OPENBSD) || defined(NETBSD) || defined(__GLIBC__)
#define EDEADLOCK -1
#endif
--------------090008040909040108000808
Content-Type: text/x-patch;
name="nsprpub_new1.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="nsprpub_new1.diff"
diff -uwr mozilla.orig/nsprpub/config/nsinstall.c mozilla/nsprpub/config/nsinstall.c
--- mozilla.orig/nsprpub/config/nsinstall.c 2002-12-12 01:29:08.000000000 +0100
+++ mozilla/nsprpub/config/nsinstall.c 2004-11-23 13:29:54.000000000 +0100
@@ -95,7 +95,7 @@
}
#endif /* NEXTSTEP */
-#ifdef LINUX
+#if defined(LINUX) || defined(GLIBC)
#include <getopt.h>
#endif
diff -uwr mozilla.orig/nsprpub/configure.in mozilla/nsprpub/configure.in
--- mozilla.orig/nsprpub/configure.in 2004-04-17 00:28:02.000000000 +0200
+++ mozilla/nsprpub/configure.in 2004-11-23 13:29:54.000000000 +0100
@@ -514,6 +514,9 @@
linux*) OS_ARCH=Linux ;;
solaris*) OS_ARCH=SunOS OS_RELEASE=5 ;;
mingw*) OS_ARCH=WINNT ;;
+ kfreebsd*-gnu) OS_ARCH=GNU/kFreeBSD ;;
+ knetbsd*-gnu) OS_ARCH=GNU/kNetBSD ;;
+ gnu*) OS_ARCH=GNU ;;
esac
else
OS_ARCH=`uname -s | sed -e 's|/|_|g'`
@@ -919,6 +922,7 @@
fi
AC_DEFINE(XP_UNIX)
AC_DEFINE(FREEBSD)
+ AC_DEFINE(KFREEBSD)
AC_DEFINE(HAVE_BSD_FLOCK)
AC_DEFINE(HAVE_SOCKLEN_T)
CFLAGS="$CFLAGS $(DSO_CFLAGS) -ansi -Wall"
@@ -1174,7 +1178,7 @@
esac
;;
-*-linux*)
+*-linux* | *-gnu* | *-k*bsd*-gnu)
if test -z "$USE_NSPR_THREADS"; then
USE_PTHREADS=1
IMPL_STRATEGY=_PTH
@@ -1185,7 +1189,13 @@
AC_DEFINE(_SVID_SOURCE)
AC_DEFINE(_LARGEFILE64_SOURCE)
AC_DEFINE(HAVE_FCNTL_FILE_LOCKING)
- AC_DEFINE(LINUX)
+ AC_DEFINE(GLIBC)
+ case "$target" in
+ *-linux*) AC_DEFINE(LINUX) ;;
+ *-kfreebsd*-gnu) AC_DEFINE(KFREEBSD) ;;
+ *-knetbsd*-gnu) AC_DEFINE(KNETBSD) ;;
+ *-gnu*) AC_DEFINE(HURD) ;;
+ esac
CFLAGS="$CFLAGS -ansi -Wall"
CXXFLAGS="$CXXFLAGS -ansi -Wall"
MDCPUCFG_H=_linux.cfg
@@ -1408,6 +1418,7 @@
*-netbsd*)
AC_DEFINE(XP_UNIX)
AC_DEFINE(NETBSD)
+ AC_DEFINE(KNETBSD)
AC_DEFINE(HAVE_BSD_FLOCK)
USE_NSPR_THREADS=1
MDCPUCFG_H=_netbsd.cfg
@@ -2207,7 +2218,7 @@
_PTHREAD_LDFLAGS=-pthread
fi
;;
- *-linux*)
+ *-linux* | *-gnu* | *-k*bsd*-gnu)
AC_DEFINE(_REENTRANT)
;;
esac
@@ -2291,7 +2302,7 @@
fi
fi
;;
-*-linux*)
+*-linux* | *-gnu* | *-k*bsd*-gnu)
if test -n "$USE_NSPR_THREADS"; then
AC_DEFINE(_PR_LOCAL_THREADS_ONLY)
fi
diff -uwr mozilla.orig/nsprpub/pr/include/md/_linux.cfg mozilla/nsprpub/pr/include/md/_linux.cfg
--- mozilla.orig/nsprpub/pr/include/md/_linux.cfg 2004-12-03 15:45:15.000000000 +0100
+++ mozilla/nsprpub/pr/include/md/_linux.cfg 2004-11-23 13:29:54.000000000 +0100
@@ -39,7 +39,7 @@
#define XP_UNIX
#endif
-#ifndef LINUX
+#if !defined(LINUX) && defined(__linux__)
#define LINUX
#endif
diff -uwr mozilla.orig/nsprpub/pr/include/md/_pth.h mozilla/nsprpub/pr/include/md/_pth.h
--- mozilla.orig/nsprpub/pr/include/md/_pth.h 2003-09-16 22:44:04.000000000 +0200
+++ mozilla/nsprpub/pr/include/md/_pth.h 2004-11-23 13:29:54.000000000 +0100
@@ -136,7 +136,7 @@
(!memcmp(&(t), &pt_zero_tid, sizeof(pthread_t)))
#define _PT_PTHREAD_COPY_THR_HANDLE(st, dt) (dt) = (st)
#elif defined(IRIX) || defined(OSF1) || defined(AIX) || defined(SOLARIS) \
- || defined(HPUX) || defined(LINUX) || defined(FREEBSD) \
+ || defined(HPUX) || defined(LINUX) || defined(GLIBC) || defined(FREEBSD) \
|| defined(NETBSD) || defined(OPENBSD) || defined(BSDI) \
|| defined(VMS) || defined(NTO) || defined(DARWIN) \
|| defined(UNIXWARE)
@@ -188,7 +188,7 @@
/*
* These platforms don't have sigtimedwait()
*/
-#if (defined(AIX) && !defined(AIX4_3_PLUS)) || defined(LINUX) \
+#if (defined(AIX) && !defined(AIX4_3_PLUS)) || defined(GLIBC) \
|| defined(FREEBSD) || defined(NETBSD) || defined(OPENBSD) \
|| defined(BSDI) || defined(VMS) || defined(UNIXWARE) \
|| defined(DARWIN)
@@ -228,7 +228,7 @@
#define PT_PRIO_MAX sched_get_priority_max(SCHED_OTHER)
#endif /* defined(_PR_DCETHREADS) */
-#elif defined(LINUX) || defined(FREEBSD)
+#elif defined(LINUX) || defined(GLIBC) || 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)
@@ -283,7 +283,7 @@
onemillisec.tv_nsec = 1000000L; \
nanosleep(&onemillisec,NULL); \
PR_END_MACRO
-#elif defined(HPUX) || defined(LINUX) || defined(SOLARIS) \
+#elif defined(HPUX) || defined(LINUX) || defined(GLIBC) || defined(SOLARIS) \
|| defined(FREEBSD) || defined(NETBSD) || defined(OPENBSD) \
|| defined(BSDI) || defined(NTO) || defined(DARWIN) \
|| defined(UNIXWARE)
diff -uwr mozilla.orig/nsprpub/pr/include/md/prosdep.h mozilla/nsprpub/pr/include/md/prosdep.h
--- mozilla.orig/nsprpub/pr/include/md/prosdep.h 2001-10-26 06:54:01.000000000 +0200
+++ mozilla/nsprpub/pr/include/md/prosdep.h 2004-11-23 13:29:54.000000000 +0100
@@ -87,7 +87,7 @@
#elif defined(IRIX)
#include "md/_irix.h"
-#elif defined(LINUX)
+#elif defined(LINUX) || defined(__GNU__) || defined(__GLIBC__)
#include "md/_linux.h"
#elif defined(OSF1)
diff -uwr mozilla.orig/nsprpub/pr/src/md/unix/unix.c mozilla/nsprpub/pr/src/md/unix/unix.c
--- mozilla.orig/nsprpub/pr/src/md/unix/unix.c 2002-12-12 01:19:57.000000000 +0100
+++ mozilla/nsprpub/pr/src/md/unix/unix.c 2004-11-23 13:29:54.000000000 +0100
@@ -65,7 +65,7 @@
* PRInt32* pointer to a _PRSockLen_t* pointer.
*/
#if defined(HAVE_SOCKLEN_T) \
- || (defined(LINUX) && defined(__GLIBC__) && __GLIBC__ >= 2)
+ || ((defined(LINUX) || defined(GLIBC)) && __GLIBC__ >= 2)
#define _PRSockLen_t socklen_t
#elif defined(IRIX) || defined(HPUX) || defined(OSF1) || defined(SOLARIS) \
|| defined(AIX4_1) || defined(LINUX) || defined(SONY) \
diff -uwr mozilla.orig/nsprpub/pr/src/md/unix/uxproces.c mozilla/nsprpub/pr/src/md/unix/uxproces.c
--- mozilla.orig/nsprpub/pr/src/md/unix/uxproces.c 2002-03-15 00:20:54.000000000 +0100
+++ mozilla/nsprpub/pr/src/md/unix/uxproces.c 2004-11-23 13:29:54.000000000 +0100
@@ -89,7 +89,8 @@
* that can share the virtual address space and file descriptors.
*/
#if (defined(IRIX) && !defined(_PR_PTHREADS)) \
- || (defined(LINUX) && defined(_PR_PTHREADS))
+ || (defined(LINUX) && defined(_PR_PTHREADS)) \
+ || (defined(GLIBC) && defined(_PR_PTHREADS))
#define _PR_SHARE_CLONES
#endif
@@ -103,7 +104,7 @@
*/
#if defined(_PR_GLOBAL_THREADS_ONLY) \
- || (defined(_PR_PTHREADS) && !defined(LINUX))
+ || (defined(_PR_PTHREADS) && !(defined(LINUX) || defined(GLIBC)))
#define _PR_NATIVE_THREADS
#endif
diff -uwr mozilla.orig/nsprpub/pr/src/md/unix/uxrng.c mozilla/nsprpub/pr/src/md/unix/uxrng.c
--- mozilla.orig/nsprpub/pr/src/md/unix/uxrng.c 2002-06-14 05:22:14.000000000 +0200
+++ mozilla/nsprpub/pr/src/md/unix/uxrng.c 2004-11-23 13:29:54.000000000 +0100
@@ -135,7 +135,7 @@
return 0;
}
-#elif (defined(LINUX) || defined(FREEBSD) || defined(NETBSD) || defined(OPENBSD))
+#elif (defined(LINUX) || defined(KFREEBSD) || defined(KNETBSD) || defined(OPENBSD))
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
diff -uwr mozilla.orig/nsprpub/pr/src/misc/prnetdb.c mozilla/nsprpub/pr/src/misc/prnetdb.c
--- mozilla.orig/nsprpub/pr/src/misc/prnetdb.c 2004-01-22 23:22:37.000000000 +0100
+++ mozilla/nsprpub/pr/src/misc/prnetdb.c 2004-11-23 13:29:54.000000000 +0100
@@ -105,7 +105,7 @@
#define _PR_HAVE_GETPROTO_R_INT
#endif
-#if (defined(LINUX) && defined(__GLIBC__) && __GLIBC__ >= 2)
+#if ((defined(LINUX)|| defined(GLIBC)) && __GLIBC__ >= 2)
#define _PR_HAVE_GETPROTO_R
#define _PR_HAVE_5_ARG_GETPROTO_R
#endif
Only in mozilla/nsprpub/pr/src/pthreads: Makefile
diff -uwr mozilla.orig/nsprpub/pr/src/pthreads/ptio.c mozilla/nsprpub/pr/src/pthreads/ptio.c
--- mozilla.orig/nsprpub/pr/src/pthreads/ptio.c 2004-02-04 02:31:33.000000000 +0100
+++ mozilla/nsprpub/pr/src/pthreads/ptio.c 2004-11-23 13:29:54.000000000 +0100
@@ -203,7 +203,7 @@
#if defined(SOLARIS)
#define _PRSockOptVal_t char *
#elif defined(IRIX) || defined(OSF1) || defined(AIX) || defined(HPUX) \
- || defined(LINUX) || defined(FREEBSD) || defined(BSDI) || defined(VMS) \
+ || defined(LINUX) || defined(GLIBC) || defined(FREEBSD) || defined(BSDI) || defined(VMS) \
|| defined(NTO) || defined(OPENBSD) || defined(DARWIN) \
|| defined(UNIXWARE) || defined(NETBSD)
#define _PRSockOptVal_t void *
@@ -217,7 +217,7 @@
#define _PRSelectFdSetArg_t void *
#elif defined(IRIX) || (defined(AIX) && !defined(AIX4_1)) \
|| defined(OSF1) || defined(SOLARIS) \
- || defined(HPUX10_30) || defined(HPUX11) || defined(LINUX) \
+ || defined(HPUX10_30) || defined(HPUX11) || defined(LINUX) || defined(GLIBC) \
|| defined(FREEBSD) || defined(NETBSD) || defined(OPENBSD) \
|| defined(BSDI) || defined(VMS) || defined(NTO) || defined(DARWIN) \
|| defined(UNIXWARE)
@@ -301,7 +301,7 @@
* most current systems.
*/
#if defined(HAVE_SOCKLEN_T) \
- || (defined(LINUX) && defined(__GLIBC__) && __GLIBC__ >= 2)
+ || ((defined(LINUX) || defined(GLIBC)) && __GLIBC__ >= 2)
typedef socklen_t pt_SockLen;
#elif (defined(AIX) && !defined(AIX4_1)) \
|| defined(VMS)
@@ -357,14 +357,14 @@
int nbytes_to_send; /* size of header and file */
#endif /* SOLARIS */
-#ifdef LINUX
+#if defined(LINUX) || defined(GLIBC)
/*
* For sendfile()
*/
int in_fd; /* descriptor of file to send */
off_t offset;
size_t count;
-#endif /* LINUX */
+#endif /* LINUX || GLIBC */
PRIntervalTime timeout; /* client (relative) timeout */
@@ -1109,7 +1109,7 @@
}
#endif /* SOLARIS */
-#ifdef LINUX
+#if defined(LINUX)
static PRBool pt_linux_sendfile_cont(pt_Continuation *op, PRInt16 revents)
{
ssize_t rv;
@@ -2544,7 +2544,7 @@
#endif /* SOLARIS */
-#ifdef LINUX
+#if defined(LINUX)
/*
* pt_LinuxSendFile
*
@@ -2983,7 +2983,7 @@
rv = setsockopt(
fd->secret->md.osfd, level, name,
(char*)&value, sizeof(PRIntn));
-#ifdef LINUX
+#if defined(LINUX)
/* for pt_LinuxSendFile */
if (name == TCP_NODELAY && rv == 0) {
fd->secret->md.tcp_nodelay = value;
@@ -3255,7 +3255,7 @@
};
#if defined(HPUX) || defined(OSF1) || defined(SOLARIS) || defined (IRIX) \
- || defined(AIX) || defined(LINUX) || defined(FREEBSD) || defined(NETBSD) \
+ || defined(AIX) || defined(LINUX) || defined(GLIBC) || defined(FREEBSD) || defined(NETBSD) \
|| defined(OPENBSD) || defined(BSDI) || defined(VMS) || defined(NTO) \
|| defined(DARWIN) || defined(UNIXWARE)
#define _PR_FCNTL_FLAGS O_NONBLOCK
@@ -4747,7 +4747,7 @@
#include <sys/types.h>
#include <sys/time.h>
-#if !defined(SUNOS4) && !defined(HPUX) && !defined(LINUX)
+#if !defined(SUNOS4) && !defined(HPUX) && !defined(LINUX) && !defined(GLIBC)
#include <sys/select.h>
#endif
--------------090008040909040108000808
Content-Type: text/x-patch;
name="security_new1.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
filename="security_new1.diff"
diff -uwr mozilla.orig/security/coreconf/Linux.mk mozilla/security/coreconf/Linux.mk
--- mozilla.orig/security/coreconf/Linux.mk 2004-12-03 15:45:18.000000000 +0100
+++ mozilla/security/coreconf/Linux.mk 2004-11-03 14:40:39.000000000 +0100
@@ -30,7 +30,7 @@
# may use your version of this file under either the MPL or the
# GPL.
#
-# Config stuff for Linux
+# Config stuff for GNU and variants
#
include $(CORE_DEPTH)/coreconf/UNIX.mk
@@ -51,70 +51,70 @@
DEFAULT_COMPILER = gcc
ifeq ($(OS_TEST),m68k)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = m68k
else
ifeq ($(OS_TEST),ppc)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = ppc
else
ifeq ($(OS_TEST),alpha)
- OS_REL_CFLAGS = -D_ALPHA_ -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_ALPHA_ -D_XOPEN_SOURCE
CPU_ARCH = alpha
else
ifeq ($(OS_TEST),ia64)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = ia64
else
ifeq ($(OS_TEST),x86_64)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = x86_64
else
ifeq ($(OS_TEST),sparc)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = sparc
else
ifeq ($(OS_TEST),sparc64)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = sparc
else
ifeq (,$(filter-out arm% sa110,$(OS_TEST)))
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = arm
else
ifeq ($(OS_TEST),parisc)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = hppa
else
ifeq ($(OS_TEST),parisc64)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = hppa
else
ifeq ($(OS_TEST),s390)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = s390
else
ifeq ($(OS_TEST),s390x)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = s390x
else
ifeq ($(OS_TEST),mips)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = mips
else
ifeq ($(OS_TEST),parisc)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = hppa
else
ifeq ($(OS_TEST),parisc64)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = hppa
else
ifeq ($(OS_TEST),s390)
- OS_REL_CFLAGS = -DLINUX1_2 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -D_XOPEN_SOURCE
CPU_ARCH = s390
else
- OS_REL_CFLAGS = -DLINUX1_2 -Di386 -D_XOPEN_SOURCE
+ OS_REL_CFLAGS = -Di386 -D_XOPEN_SOURCE
CPU_ARCH = x86
endif
endif
@@ -133,10 +133,13 @@
endif
endif
+ifeq ($(KERNEL),linux)
+OS_REL_CFLAGS = -DLINUX1_2
+endif
LIBC_TAG = _glibc
-ifeq ($(OS_RELEASE),2.0)
+ifeq ($(KERNEL)-$(OS_RELEASE),linux-2.0)
OS_REL_CFLAGS += -DLINUX2_0
MKSHLIB = $(CC) -shared -Wl,-soname -Wl,$(@:$(OBJDIR)/%.so=%.so)
ifdef BUILD_OPT
@@ -153,20 +156,27 @@
OS_PTHREAD = -lpthread
endif
-OS_CFLAGS = $(DSO_CFLAGS) $(OS_REL_CFLAGS) -ansi -Wall -pipe -DLINUX -Dlinux -D_POSIX_SOURCE -D_BSD_SOURCE -DHAVE_STRERROR
+OS_CFLAGS = $(DSO_CFLAGS) $(OS_REL_CFLAGS) -ansi -Wall -pipe -D_POSIX_SOURCE -D_BSD_SOURCE -DHAVE_STRERROR
OS_LIBS = -L/lib $(OS_PTHREAD) -ldl -lc
+ifeq ($(KERNEL),linux)
+OS_CFLAGS += -DLINUX -Dlinux
+endif
ifdef USE_PTHREADS
DEFINES += -D_REENTRANT
endif
+ifeq ($(KERNEL),linux)
ARCH = linux
+else
+ARCH = gnu
+endif
DSO_CFLAGS = -fPIC
DSO_LDOPTS = -shared
DSO_LDFLAGS =
-# INCLUDES += -I/usr/include -Y/usr/include/linux
+# INCLUDES += -I/usr/include
G++INCLUDES = -I/usr/include/g++
#
diff -uwr mozilla.orig/security/coreconf/config.mk mozilla/security/coreconf/config.mk
--- mozilla.orig/security/coreconf/config.mk 2004-01-28 01:01:56.000000000 +0100
+++ mozilla/security/coreconf/config.mk 2004-11-03 14:40:39.000000000 +0100
@@ -59,7 +59,7 @@
#######################################################################
TARGET_OSES = FreeBSD BSD_OS NetBSD OpenUNIX OS2 QNX Darwin BeOS OpenBSD \
- OpenVMS AIX
+ OpenVMS AIX GNU GNU_kFreeBSD GNU_kNetBSD
ifeq (,$(filter-out $(TARGET_OSES),$(OS_TARGET)))
include $(CORE_DEPTH)/coreconf/$(OS_TARGET).mk
diff -uwr mozilla.orig/security/nss/cmd/platlibs.mk mozilla/security/nss/cmd/platlibs.mk
--- mozilla.orig/security/nss/cmd/platlibs.mk 2003-04-20 06:23:14.000000000 +0200
+++ mozilla/security/nss/cmd/platlibs.mk 2004-11-13 19:52:11.000000000 +0100
@@ -182,7 +182,7 @@
# If GNU ld is used, we must use the -rpath-link option to tell
# the linker where to find libsoftokn3.so, an implicit dependency
# of libnss3.so.
-ifeq (,$(filter-out BSD_OS FreeBSD Linux NetBSD, $(OS_ARCH)))
+ifeq (,$(filter-out BSD_OS FreeBSD GNU_kFreeBSD Linux NetBSD, $(OS_ARCH)))
EXTRA_SHARED_LIBS += -Wl,-rpath-link,$(DIST)/lib
endif
diff -uwr mozilla.orig/security/nss/lib/freebl/ecl/Makefile mozilla/security/nss/lib/freebl/ecl/Makefile
--- mozilla.orig/security/nss/lib/freebl/ecl/Makefile 2003-10-17 15:45:34.000000000 +0200
+++ mozilla/security/nss/lib/freebl/ecl/Makefile 2004-11-03 14:40:39.000000000 +0100
@@ -65,7 +65,7 @@
ifeq ($(TARGET),v8SOLARIS)
ECL_USE_FP=1
else
-ifeq ($(TARGET),x86LINUX)
+ifeq (,)
ECL_USE_FP=1
endif
endif
diff -uwr mozilla.orig/security/nss/lib/freebl/mpi/target.mk mozilla/security/nss/lib/freebl/mpi/target.mk
--- mozilla.orig/security/nss/lib/freebl/mpi/target.mk 2003-10-17 15:45:36.000000000 +0200
+++ mozilla/security/nss/lib/freebl/mpi/target.mk 2004-11-03 14:40:39.000000000 +0100
@@ -203,13 +203,13 @@
export OBJECT_MODE
endif
-ifeq ($(TARGET),x86LINUX)
+ifeq (,)
#Linux
AS_OBJS = mpi_x86.o
MPICMN += -DMP_ASSEMBLY_MULTIPLY -DMP_ASSEMBLY_SQUARE -DMP_ASSEMBLY_DIV_2DX1D
MPICMN += -DMP_MONT_USE_MP_MUL
-CFLAGS= -O2 -fPIC -DLINUX1_2 -Di386 -D_XOPEN_SOURCE -DLINUX2_1 -ansi -Wall \
- -pipe -DLINUX -Dlinux -D_POSIX_SOURCE -D_BSD_SOURCE -DHAVE_STRERROR \
+CFLAGS= -O2 -fPIC -Di386 -D_XOPEN_SOURCE -ansi -Wall \
+ -pipe -D_POSIX_SOURCE -D_BSD_SOURCE -DHAVE_STRERROR \
-DXP_UNIX -UDEBUG -DNDEBUG -D_REENTRANT $(MPICMN)
#CFLAGS= -g -fPIC -DLINUX1_2 -Di386 -D_XOPEN_SOURCE -DLINUX2_1 -ansi -Wall \
-pipe -DLINUX -Dlinux -D_POSIX_SOURCE -D_BSD_SOURCE -DHAVE_STRERROR \
diff -uwr mozilla.orig/security/nss/lib/freebl/unix_rand.c mozilla/security/nss/lib/freebl/unix_rand.c
--- mozilla.orig/security/nss/lib/freebl/unix_rand.c 2003-05-31 01:31:19.000000000 +0200
+++ mozilla/security/nss/lib/freebl/unix_rand.c 2004-11-13 19:56:34.000000000 +0100
@@ -78,7 +78,8 @@
}
#if defined(SCO) || defined(UNIXWARE) || defined(BSDI) || defined(FREEBSD) \
- || defined(NETBSD) || defined(NTO) || defined(DARWIN) || defined(OPENBSD)
+ || defined(NETBSD) || defined(NTO) || defined(DARWIN) || defined(OPENBSD) \
+ || (defined(__GLIBC__) && !defined(LINUX))
#include <sys/times.h>
#define getdtablesize() sysconf(_SC_OPEN_MAX)
@@ -804,7 +805,7 @@
#ifdef DO_PS
For now it is considered that it is too expensive to run the ps command
for the small amount of entropy it provides.
-#if defined(__sun) && (!defined(__svr4) && !defined(SVR4)) || defined(bsdi) || defined(LINUX)
+#if defined(__sun) && (!defined(__svr4) && !defined(SVR4)) || defined(bsdi) || defined(LINUX) || defined(__GLIBC__) || defined (__GNU__)
static char ps_cmd[] = "ps aux";
#else
static char ps_cmd[] = "ps -el";
diff -uwr mozilla.orig/security/nss/lib/ssl/sslmutex.c mozilla/security/nss/lib/ssl/sslmutex.c
--- mozilla.orig/security/nss/lib/ssl/sslmutex.c 2003-08-29 00:23:59.000000000 +0200
+++ mozilla/security/nss/lib/ssl/sslmutex.c 2004-11-13 17:52:02.000000000 +0100
@@ -87,7 +87,7 @@
return SECSuccess;
}
-#if defined(LINUX) || defined(AIX) || defined(VMS) || defined(BEOS) || defined(BSDI) || defined(NETBSD) || defined(OPENBSD)
+#if defined(LINUX) || defined(AIX) || defined(VMS) || defined(BEOS) || defined(BSDI) || defined(NETBSD) || defined(OPENBSD) || defined(__GNU__) || defined(__GLIBC__)
#include <unistd.h>
#include <fcntl.h>
diff -uwr mozilla.orig/security/nss/lib/ssl/sslmutex.h mozilla/security/nss/lib/ssl/sslmutex.h
--- mozilla.orig/security/nss/lib/ssl/sslmutex.h 2002-05-18 05:24:17.000000000 +0200
+++ mozilla/security/nss/lib/ssl/sslmutex.h 2004-11-13 17:39:38.000000000 +0100
@@ -77,7 +77,7 @@
typedef int sslPID;
-#elif defined(LINUX) || defined(AIX) || defined(VMS) || defined(BEOS) || defined(BSDI) || defined(NETBSD) || defined(OPENBSD)
+#elif defined(LINUX) || defined(AIX) || defined(VMS) || defined(BEOS) || defined(BSDI) || defined(NETBSD) || defined(OPENBSD) || defined(__GNU__) || defined(__GLIBC__)
#include <sys/types.h>
#include "prtypes.h"
diff -uwNr mozilla/security/coreconf/GNU.mk mozilla.new/security/coreconf/GNU.mk
--- mozilla.orig/security/coreconf/GNU.mk 1970-01-01 01:00:00.000000000 +0100
+++ mozilla/security/coreconf/GNU.mk 2004-11-03 14:40:39.000000000 +0100
@@ -0,0 +1,37 @@
+#
+# The contents of this file are subject to the Mozilla Public
+# License Version 1.1 (the "License"); you may not use this file
+# except in compliance with the License. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS
+# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+# implied. See the License for the specific language governing
+# rights and limitations under the License.
+#
+# The Original Code is the Netscape security libraries.
+#
+# The Initial Developer of the Original Code is Netscape
+# Communications Corporation. Portions created by Netscape are
+# Copyright (C) 1994-2000 Netscape Communications Corporation. All
+# Rights Reserved.
+#
+# Contributor(s):
+#
+# Alternatively, the contents of this file may be used under the
+# terms of the GNU General Public License Version 2 or later (the
+# "GPL"), in which case the provisions of the GPL are applicable
+# instead of those above. If you wish to allow use of your
+# version of this file only under the terms of the GPL and not to
+# allow others to use your version of this file under the MPL,
+# indicate your decision by deleting the provisions above and
+# replace them with the notice and other provisions required by
+# the GPL. If you do not delete the provisions above, a recipient
+# may use your version of this file under either the MPL or the
+# GPL.
+#
+# Config stuff for GNU
+#
+
+KERNEL=gnumach
+include $(CORE_DEPTH)/coreconf/Linux.mk
diff -uwNr mozilla/security/coreconf/GNU_kFreeBSD.mk mozilla.new/security/coreconf/GNU_kFreeBSD.mk
--- mozilla.orig/security/coreconf/GNU_kFreeBSD.mk 1970-01-01 01:00:00.000000000 +0100
+++ mozilla/security/coreconf/GNU_kFreeBSD.mk 2004-11-13 17:33:54.000000000 +0100
@@ -0,0 +1,47 @@
+#
+# The contents of this file are subject to the Mozilla Public
+# License Version 1.1 (the "License"); you may not use this file
+# except in compliance with the License. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS
+# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+# implied. See the License for the specific language governing
+# rights and limitations under the License.
+#
+# The Original Code is the Netscape security libraries.
+#
+# The Initial Developer of the Original Code is Netscape
+# Communications Corporation. Portions created by Netscape are
+# Copyright (C) 1994-2000 Netscape Communications Corporation. All
+# Rights Reserved.
+#
+# Contributor(s):
+#
+# Alternatively, the contents of this file may be used under the
+# terms of the GNU General Public License Version 2 or later (the
+# "GPL"), in which case the provisions of the GPL are applicable
+# instead of those above. If you wish to allow use of your
+# version of this file only under the terms of the GPL and not to
+# allow others to use your version of this file under the MPL,
+# indicate your decision by deleting the provisions above and
+# replace them with the notice and other provisions required by
+# the GPL. If you do not delete the provisions above, a recipient
+# may use your version of this file under either the MPL or the
+# GPL.
+#
+# Config stuff for GNU/kFreeBSD
+#
+
+KERNEL=kfreebsd
+include $(CORE_DEPTH)/coreconf/Linux.mk
+
+MKSHLIB = $(CC) -shared -Wl,-soname -Wl,$(@:$(OBJDIR)/%.so=%.so)
+ifdef BUILD_OPT
+ OPTIMIZER = -O2
+endif
+ifdef MAPFILE
+ MKSHLIB += -Wl,--version-script,$(MAPFILE)
+endif
+PROCESS_MAP_FILE = grep -v ';-' $(LIBRARY_NAME).def | \
+ sed -e 's,;+,,' -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,;,' > $@
diff -uwNr mozilla/security/coreconf/GNU_kNetBSD.mk mozilla.new/security/coreconf/GNU_kNetBSD.mk
--- mozilla.orig/security/coreconf/GNU_kNetBSD.mk 1970-01-01 01:00:00.000000000 +0100
+++ mozilla/security/coreconf/GNU_kNetBSD.mk 2004-11-03 14:40:39.000000000 +0100
@@ -0,0 +1,37 @@
+#
+# The contents of this file are subject to the Mozilla Public
+# License Version 1.1 (the "License"); you may not use this file
+# except in compliance with the License. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS
+# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+# implied. See the License for the specific language governing
+# rights and limitations under the License.
+#
+# The Original Code is the Netscape security libraries.
+#
+# The Initial Developer of the Original Code is Netscape
+# Communications Corporation. Portions created by Netscape are
+# Copyright (C) 1994-2000 Netscape Communications Corporation. All
+# Rights Reserved.
+#
+# Contributor(s):
+#
+# Alternatively, the contents of this file may be used under the
+# terms of the GNU General Public License Version 2 or later (the
+# "GPL"), in which case the provisions of the GPL are applicable
+# instead of those above. If you wish to allow use of your
+# version of this file only under the terms of the GPL and not to
+# allow others to use your version of this file under the MPL,
+# indicate your decision by deleting the provisions above and
+# replace them with the notice and other provisions required by
+# the GPL. If you do not delete the provisions above, a recipient
+# may use your version of this file under either the MPL or the
+# GPL.
+#
+# Config stuff for GNU/kNetBSD
+#
+
+KERNEL=knetbsd
+include $(CORE_DEPTH)/coreconf/Linux.mk
--------------090008040909040108000808--