~ubuntu-branches/ubuntu/wily/net-snmp/wily-proposed

« back to all changes in this revision

Viewing changes to debian/patches/26_kfreebsd.patch

  • Committer: Bazaar Package Importer
  • Author(s): Chuck Short
  • Date: 2010-06-28 14:59:36 UTC
  • mfrom: (1.2.3 upstream) (1.1.12 sid)
  • Revision ID: james.westby@ubuntu.com-20100628145936-cbiallic69pn044g
Tags: 5.4.3~dfsg-1ubuntu1
* Merge from debian unstable.  Remaining changes:
  - Set Ubuntu maintainer address.
  - net-snmp-config: Use bash. (LP: #104738)
  - Removed multiuser option when calling update-rc.d. (LP: #254261)
  - debian/snmpd.init: LSBify the init script.
  - debian/patches/52_fix_snmpcmd_1_typo.patch: Adjust a typo in snmpcmd.1
    (LP: #250459)
  - debian/snmpd.postinst: source debconf before doing work, LP: #589056
  - debian/snmp.preinst, debian/snmp.prerm: kill any/all processes owned by
    snmp user before install/uninstall, LP: #573391
  - Add apport hook (LP: #533603):
  - debian/{snmp,snmpd}.apport: Added.
  - debian/control: Build-depends on dh-apport.
  - debian/rules: 
    + Add --with apport.
    + override_dh_apport to install hook on snmpd package only.
 * Dropped patches:
   - debian/patches/99-fix-ubuntu-div0.patch: Fix dvision by zero.. 

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
only in patch2:
2
2
unchanged:
3
 
--- net-snmp-5.3.1.orig/Makefile.in
4
 
+++ net-snmp-5.3.1/Makefile.in
 
3
Index: net-snmp-5.4.2.1/Makefile.in
 
4
===================================================================
 
5
--- net-snmp-5.4.2.1.orig/Makefile.in   2009-11-27 15:13:25.000000000 +0100
 
6
+++ net-snmp-5.4.2.1/Makefile.in        2009-11-27 15:13:35.000000000 +0100
5
7
@@ -17,8 +17,8 @@
6
8
 INCLUDESUBDIR=system
7
9
 INCLUDESUBDIRHEADERS= aix.h bsd.h bsdi3.h bsdi4.h bsdi.h cygwin.h \
11
13
+       dynix.h freebsd2.h freebsd3.h freebsd4.h freebsd.h generic.h kfreebsd.h \
12
14
+       hpux.h irix.h linux.h mingw32.h mips.h netbsd.h openbsd.h osf5.h \
13
15
        solaris2.3.h solaris2.4.h solaris2.5.h solaris2.6.h \
14
 
        solaris.h sunos.h svr5.h sysv.h ultrix4.h
 
16
        solaris.h sunos.h svr5.h sysv.h ultrix4.h dragonfly.h
15
17
 INCLUDESUBDIR2=machine
16
 
only in patch2:
17
 
unchanged:
18
 
--- net-snmp-5.3.1.orig/include/net-snmp/system/kfreebsd.h
19
 
+++ net-snmp-5.3.1/include/net-snmp/system/kfreebsd.h
 
18
Index: net-snmp-5.4.2.1/include/net-snmp/system/kfreebsd.h
 
19
===================================================================
 
20
--- /dev/null   1970-01-01 00:00:00.000000000 +0000
 
21
+++ net-snmp-5.4.2.1/include/net-snmp/system/kfreebsd.h 2009-11-27 15:13:35.000000000 +0100
20
22
@@ -0,0 +1,65 @@
21
23
+#include "freebsd6.h"
22
24
+#define freebsd6 freebsd6
83
85
+        u_quad_t        xt_alignment_hack;
84
86
+};
85
87
+
 
88
Index: net-snmp-5.4.2.1/agent/mibgroup/hardware/cpu/cpu_sysctl.c
 
89
===================================================================
 
90
--- net-snmp-5.4.2.1.orig/agent/mibgroup/hardware/cpu/cpu_sysctl.c      2009-11-27 15:15:37.000000000 +0100
 
91
+++ net-snmp-5.4.2.1/agent/mibgroup/hardware/cpu/cpu_sysctl.c   2009-11-27 15:19:01.000000000 +0100
 
92
@@ -11,7 +11,7 @@
 
93
 #include <unistd.h>
 
94
 #include <sys/types.h>
 
95
 
 
96
-#if defined(__FreeBSD__)
 
97
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
 
98
 #include <sys/resource.h>
 
99
 #if !defined(CPUSTATES)
 
100
 #include <sys/dkstat.h>
 
101
@@ -73,7 +73,7 @@
 
102
 #define NETSNMP_CPU_STATS uint64_t
 
103
 #endif
 
104
 
 
105
-#elif defined(__FreeBSD__)
 
106
+#elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
 
107
 #define NETSNMP_KERN_CPU  0    /* dummy value - sysctlnametomib(2) should be used */
 
108
 
 
109
 #else
 
110
@@ -107,7 +107,7 @@
 
111
 #define NETSNMP_VM_STATS_TYPE  struct uvmexp
 
112
 #endif  /* VM_UVMEXP2 || VM_UVMEXP */
 
113
 
 
114
-#elif defined(__FreeBSD__)                /* FreeBSD */
 
115
+#elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) /* FreeBSD */
 
116
 #define NETSNMP_VM_STATS       VM_METER
 
117
 #define NETSNMP_VM_STATS_TYPE  struct vmmeter
 
118
     #define NS_VM_INTR         v_intr
 
119
@@ -159,7 +159,7 @@
 
120
     size_t         mem_size  = sizeof(NETSNMP_VM_STATS_TYPE);
 
121
     netsnmp_cpu_info *cpu = netsnmp_cpu_get_byIdx( -1, 0 );
 
122
 
 
123
-#if defined(__FreeBSD__)
 
124
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
 
125
     sysctlbyname("kern.cp_time", cpu_stats, &cpu_size, NULL, 0);
 
126
 #else
 
127
     sysctl(cpu_mib, 2,  cpu_stats, &cpu_size, NULL, 0);