~ubuntu-branches/ubuntu/lucid/nss/lucid-security

« back to all changes in this revision

Viewing changes to debian/patches/38_kbsd.patch

  • Committer: Package Import Robot
  • Author(s): Marc Deslauriers
  • Date: 2013-11-15 08:08:08 UTC
  • mfrom: (1.2.7)
  • Revision ID: package-import@ubuntu.com-20131115080808-dba1asgnjl9tc66s
Tags: 3.15.3-0ubuntu0.10.04.1
* SECURITY UPDATE: New upstream release to fix multiple security issues
  and add TLSv1.2 support.
  - CVE-2013-1739
  - CVE-2013-1741
  - CVE-2013-5605
  - CVE-2013-5606
* Adjusted packaging for 3.15.3:
  - debian/patches/*: refreshed.
  - debian/patches/01_dont_build_nspr.patch: removed, changed build
    options in debian/rules instead.
  - debian/libnss3-1d.symbols: added new symbols.
  - debian/rules: updated for new source layout.

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
## DP: GNU/kFreeBSD support. bz#356011
5
5
## DP: Added Hurd support.
6
6
 
7
 
Index: nss-3.14.3/mozilla/security/coreconf/Linux.mk
8
 
===================================================================
9
 
--- nss-3.14.3.orig/mozilla/security/coreconf/Linux.mk  2013-03-13 11:17:44.000000000 -0500
10
 
+++ nss-3.14.3/mozilla/security/coreconf/Linux.mk       2013-03-13 11:20:33.000000000 -0500
 
7
Index: nss/nss/lib/freebl/unix_rand.c
 
8
===================================================================
 
9
--- nss.orig/nss/lib/freebl/unix_rand.c 2013-06-15 19:17:07.382594525 +0900
 
10
+++ nss/nss/lib/freebl/unix_rand.c      2013-06-15 19:17:34.501768732 +0900
 
11
@@ -156,7 +156,8 @@
 
12
 
 
13
 #if defined(SCO) || defined(UNIXWARE) || defined(BSDI) || defined(FREEBSD) \
 
14
     || defined(NETBSD) || defined(DARWIN) || defined(OPENBSD) \
 
15
-    || defined(NTO) || defined(__riscos__)
 
16
+    || defined(NTO) || defined(__riscos__) || defined(__GNU__) \
 
17
+    || defined(__FreeBSD_kernel__) || defined(__NetBSD_kernel__)
 
18
 #include <sys/times.h>
 
19
 
 
20
 #define getdtablesize() sysconf(_SC_OPEN_MAX)
 
21
Index: nss/nss/lib/softoken/softoken.h
 
22
===================================================================
 
23
--- nss.orig/nss/lib/softoken/softoken.h        2013-06-15 19:17:07.382594525 +0900
 
24
+++ nss/nss/lib/softoken/softoken.h     2013-06-15 19:17:34.505768610 +0900
 
25
@@ -295,7 +295,7 @@
 
26
 
 
27
 #define CHECK_FORK_MIXED
 
28
 
 
29
-#elif defined(LINUX)
 
30
+#elif defined(LINUX) || defined (__GLIBC__)
 
31
 
 
32
 #define CHECK_FORK_PTHREAD
 
33
 
 
34
Index: nss/nss/lib/ssl/sslmutex.c
 
35
===================================================================
 
36
--- nss.orig/nss/lib/ssl/sslmutex.c     2013-06-15 19:17:07.382594525 +0900
 
37
+++ nss/nss/lib/ssl/sslmutex.c  2013-06-15 19:17:34.505768610 +0900
 
38
@@ -56,7 +56,7 @@
 
39
     return SECSuccess;
 
40
 }
 
41
 
 
42
-#if defined(LINUX) || defined(AIX) || defined(BEOS) || defined(BSDI) || (defined(NETBSD) && __NetBSD_Version__ < 500000000) || defined(OPENBSD)
 
43
+#if defined(LINUX) || defined(AIX) || defined(BEOS) || defined(BSDI) || (defined(NETBSD) && __NetBSD_Version__ < 500000000) || defined(OPENBSD) || defined(__GLIBC__)
 
44
 
 
45
 #include <unistd.h>
 
46
 #include <fcntl.h>
 
47
Index: nss/nss/lib/ssl/sslmutex.h
 
48
===================================================================
 
49
--- nss.orig/nss/lib/ssl/sslmutex.h     2013-06-15 19:17:07.382594525 +0900
 
50
+++ nss/nss/lib/ssl/sslmutex.h  2013-06-15 19:17:34.505768610 +0900
 
51
@@ -50,7 +50,7 @@
 
52
 
 
53
 typedef int    sslPID;
 
54
 
 
55
-#elif defined(LINUX) || defined(AIX) || defined(BEOS) || defined(BSDI) || (defined(NETBSD) && __NetBSD_Version__ < 500000000) || defined(OPENBSD)
 
56
+#elif defined(LINUX) || defined(AIX) || defined(BEOS) || defined(BSDI) || (defined(NETBSD) && __NetBSD_Version__ < 500000000) || defined(OPENBSD) || defined(__GLIBC__)
 
57
 
 
58
 #include <sys/types.h>
 
59
 #include "prtypes.h"
 
60
Index: nss/nss/coreconf/arch.mk
 
61
===================================================================
 
62
--- nss.orig/nss/coreconf/arch.mk       2013-06-15 19:17:07.382594525 +0900
 
63
+++ nss/nss/coreconf/arch.mk    2013-06-15 19:17:34.501768732 +0900
 
64
@@ -122,6 +122,14 @@
 
65
     ifneq ($(words $(OS_RELEASE)),1)
 
66
        OS_RELEASE := $(word 1,$(OS_RELEASE)).$(word 2,$(OS_RELEASE))
 
67
     endif
 
68
+    KERNEL = linux
 
69
+endif
 
70
+
 
71
+# This check must be last.  Since all uses of OS_ARCH that follow affect only
 
72
+# userland, we can merge other Glibc systems with Linux here.
 
73
+ifneq (, $(filter GNU GNU_%, $(OS_ARCH)))
 
74
+OS_ARCH = Linux
 
75
+OS_RELEASE = 2.6
 
76
 endif
 
77
 
 
78
 #
 
79
Index: nss/nss/coreconf/Linux.mk
 
80
===================================================================
 
81
--- nss.orig/nss/coreconf/Linux.mk      2013-06-15 19:16:59.150845133 +0900
 
82
+++ nss/nss/coreconf/Linux.mk   2013-06-15 19:17:34.501768732 +0900
11
83
@@ -93,7 +93,7 @@
12
84
 LIBC_TAG               = _glibc
13
85
 endif
17
89
        OS_REL_CFLAGS   += -DLINUX2_0
18
90
        MKSHLIB         = $(CC) -shared -Wl,-soname -Wl,$(@:$(OBJDIR)/%.so=%.so) $(RPATH)
19
91
        ifdef MAPFILE
20
 
@@ -128,7 +128,10 @@
 
92
@@ -128,14 +128,21 @@
21
93
 # -ansi on platforms like Android where the system headers are C99 and do
22
94
 # not build with -ansi.
23
95
 STANDARDS_CFLAGS       = -D_POSIX_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE
29
101
 OS_LIBS                        = $(OS_PTHREAD) -ldl -lc
30
102
 
31
103
 ifdef USE_PTHREADS
32
 
@@ -152,7 +155,7 @@
 
104
        DEFINES         += -D_REENTRANT
 
105
 endif
 
106
 
 
107
-ARCH                   = linux
 
108
+ifeq ($(KERNEL),linux)
 
109
+       ARCH            = linux
 
110
+else
 
111
+       ARCH            = gnu
 
112
+endif
 
113
 
 
114
 DSO_CFLAGS             = -fPIC
 
115
 DSO_LDOPTS             = -shared $(ARCHFLAG)
 
116
@@ -152,7 +159,7 @@
33
117
 LDFLAGS                        += -Wl,-rpath-link,/usr/lib:/lib
34
118
 endif
35
119
 
38
122
 G++INCLUDES            = -I/usr/include/g++
39
123
 
40
124
 #
41
 
@@ -187,7 +190,9 @@
 
125
@@ -187,7 +194,9 @@
42
126
 endif
43
127
 endif
44
128
 
48
132
 MKSHLIB         = $(CC) $(DSO_LDOPTS) -Wl,-soname -Wl,$(@:$(OBJDIR)/%.so=%.so) $(RPATH)
49
133
 
50
134
 ifdef MAPFILE
51
 
Index: nss-3.14.3/mozilla/security/coreconf/arch.mk
52
 
===================================================================
53
 
--- nss-3.14.3.orig/mozilla/security/coreconf/arch.mk   2013-03-13 11:17:44.000000000 -0500
54
 
+++ nss-3.14.3/mozilla/security/coreconf/arch.mk        2013-03-13 11:17:44.000000000 -0500
55
 
@@ -122,6 +122,14 @@
56
 
     ifneq ($(words $(OS_RELEASE)),1)
57
 
        OS_RELEASE := $(word 1,$(OS_RELEASE)).$(word 2,$(OS_RELEASE))
58
 
     endif
59
 
+    KERNEL = linux
60
 
+endif
61
 
+
62
 
+# This check must be last.  Since all uses of OS_ARCH that follow affect only
63
 
+# userland, we can merge other Glibc systems with Linux here.
64
 
+ifneq (, $(filter GNU GNU_%, $(OS_ARCH)))
65
 
+OS_ARCH = Linux
66
 
+OS_RELEASE = 2.6
67
 
 endif
68
 
 
69
 
 #
70
 
Index: nss-3.14.3/mozilla/security/coreconf/config.mk
71
 
===================================================================
72
 
--- nss-3.14.3.orig/mozilla/security/coreconf/config.mk 2013-03-13 11:17:44.000000000 -0500
73
 
+++ nss-3.14.3/mozilla/security/coreconf/config.mk      2013-03-13 11:23:38.000000000 -0500
 
135
Index: nss/nss/coreconf/config.mk
 
136
===================================================================
 
137
--- nss.orig/nss/coreconf/config.mk     2013-06-15 19:16:59.154845011 +0900
 
138
+++ nss/nss/coreconf/config.mk  2013-06-15 19:17:34.501768732 +0900
74
139
@@ -31,7 +31,7 @@
75
140
 #######################################################################
76
141
 
80
145
 
81
146
 ifeq (,$(filter-out $(TARGET_OSES),$(OS_TARGET)))
82
147
 include $(CORE_DEPTH)/coreconf/$(OS_TARGET).mk
83
 
Index: nss-3.14.3/mozilla/security/nss/lib/freebl/unix_rand.c
84
 
===================================================================
85
 
--- nss-3.14.3.orig/mozilla/security/nss/lib/freebl/unix_rand.c 2013-03-13 11:17:44.000000000 -0500
86
 
+++ nss-3.14.3/mozilla/security/nss/lib/freebl/unix_rand.c      2013-03-13 11:17:44.000000000 -0500
87
 
@@ -156,7 +156,8 @@
88
 
 
89
 
 #if defined(SCO) || defined(UNIXWARE) || defined(BSDI) || defined(FREEBSD) \
90
 
     || defined(NETBSD) || defined(DARWIN) || defined(OPENBSD) \
91
 
-    || defined(NTO) || defined(__riscos__)
92
 
+    || defined(NTO) || defined(__riscos__) || defined(__GNU__) \
93
 
+    || defined(__FreeBSD_kernel__) || defined(__NetBSD_kernel__)
94
 
 #include <sys/times.h>
95
 
 
96
 
 #define getdtablesize() sysconf(_SC_OPEN_MAX)
97
 
Index: nss-3.14.3/mozilla/security/nss/lib/softoken/softoken.h
98
 
===================================================================
99
 
--- nss-3.14.3.orig/mozilla/security/nss/lib/softoken/softoken.h        2013-03-13 11:17:44.000000000 -0500
100
 
+++ nss-3.14.3/mozilla/security/nss/lib/softoken/softoken.h     2013-03-13 11:17:44.000000000 -0500
101
 
@@ -296,7 +296,7 @@
102
 
 
103
 
 #define CHECK_FORK_MIXED
104
 
 
105
 
-#elif defined(LINUX)
106
 
+#elif defined(LINUX) || defined (__GLIBC__)
107
 
 
108
 
 #define CHECK_FORK_PTHREAD
109
 
 
110
 
Index: nss-3.14.3/mozilla/security/nss/lib/ssl/sslmutex.c
111
 
===================================================================
112
 
--- nss-3.14.3.orig/mozilla/security/nss/lib/ssl/sslmutex.c     2013-03-13 11:17:44.000000000 -0500
113
 
+++ nss-3.14.3/mozilla/security/nss/lib/ssl/sslmutex.c  2013-03-13 11:17:44.000000000 -0500
114
 
@@ -57,7 +57,7 @@
115
 
     return SECSuccess;
116
 
 }
117
 
 
118
 
-#if defined(LINUX) || defined(AIX) || defined(BEOS) || defined(BSDI) || (defined(NETBSD) && __NetBSD_Version__ < 500000000) || defined(OPENBSD)
119
 
+#if defined(LINUX) || defined(AIX) || defined(BEOS) || defined(BSDI) || (defined(NETBSD) && __NetBSD_Version__ < 500000000) || defined(OPENBSD) || defined(__GLIBC__)
120
 
 
121
 
 #include <unistd.h>
122
 
 #include <fcntl.h>
123
 
Index: nss-3.14.3/mozilla/security/nss/lib/ssl/sslmutex.h
124
 
===================================================================
125
 
--- nss-3.14.3.orig/mozilla/security/nss/lib/ssl/sslmutex.h     2013-03-13 11:17:44.000000000 -0500
126
 
+++ nss-3.14.3/mozilla/security/nss/lib/ssl/sslmutex.h  2013-03-13 11:17:44.000000000 -0500
127
 
@@ -51,7 +51,7 @@
128
 
 
129
 
 typedef int    sslPID;
130
 
 
131
 
-#elif defined(LINUX) || defined(AIX) || defined(BEOS) || defined(BSDI) || (defined(NETBSD) && __NetBSD_Version__ < 500000000) || defined(OPENBSD)
132
 
+#elif defined(LINUX) || defined(AIX) || defined(BEOS) || defined(BSDI) || (defined(NETBSD) && __NetBSD_Version__ < 500000000) || defined(OPENBSD) || defined(__GLIBC__)
133
 
 
134
 
 #include <sys/types.h>
135
 
 #include "prtypes.h"