~ubuntu-branches/ubuntu/vivid/oss4/vivid-proposed

« back to all changes in this revision

Viewing changes to debian/patches/kfreebsd-gnu.patch

  • Committer: Package Import Robot
  • Author(s): Sebastien NOEL
  • Date: 2012-11-19 11:47:24 UTC
  • mfrom: (1.1.6)
  • Revision ID: package-import@ubuntu.com-20121119114724-svu8mq7x3pk64nez
Tags: 4.2-build2007-1
* New upstream release.
* Acknowledge NMU, thanks Michael Gilbert.
* Add debian/patches/110_ld-as-needed.patch: Rearrange order of linker
  arguments to fix building with "ld --as-needed" (closes: #630737).
* Add missing dependency on dpkg-dev to oss4-dkms and oss4-source
  (closes: #687086).
* Fix typo in the changelog (closes: #628876, #675933)
* Add debian/patches/002_fix-linux-oss_native_word.patch (closes: #693657).
  Thanks to Ben Hutchings.
* Add debian/patches/003_linux-error-logging-fixes.patch (closes: #693657).
  Thanks to Ben Hutchings.
* check for /lib/modules/${kernelver}/build in addition of
  /lib/modules/${kernelver}/source (closes: #587191).
* oss4-dkms.dkms.in: fix 'CLEAN' rules (closes: #653374).

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
--- a/include/soundcard.h
2
 
+++ b/include/soundcard.h
3
 
@@ -50,7 +50,7 @@
4
 
 /* In Linux we need to be prepared for cross compiling */
5
 
 #include <linux/ioctl.h>
6
 
 #else
7
 
-# ifdef __FreeBSD__
8
 
+# if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
9
 
 #    include <sys/ioccom.h>
10
 
 # else
11
 
 #    include <sys/ioctl.h>
12
 
--- a/kernel/framework/audio/oss_audio_core.c
13
 
+++ b/kernel/framework/audio/oss_audio_core.c
14
 
@@ -3646,7 +3646,7 @@
15
 
        }
16
 
       return 0;
17
 
 
18
 
-#ifdef __FreeBSD__
19
 
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
20
 
     case FREEBSD_GETBLKSIZE:
21
 
 #endif
22
 
     case SNDCTL_DSP_GETBLKSIZE:
23
 
--- a/kernel/framework/sndstat/oss_sndstat.c
24
 
+++ b/kernel/framework/sndstat/oss_sndstat.c
25
 
@@ -109,9 +109,9 @@
26
 
       put_status ("\n");
27
 
     }
28
 
 
29
 
-#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__)
30
 
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__OpenBSD__) || defined(__NetBSD__)
31
 
   {
32
 
-#if defined(__FreeBSD__)
33
 
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
34
 
     extern char version[];
35
 
 #endif
36
 
 
37
 
--- a/lib/libOSSlib/compile.sh
38
 
+++ b/lib/libOSSlib/compile.sh
39
 
@@ -7,7 +7,7 @@
40
 
        $MAKE libOSSlib.so
41
 
        ;;
42
 
 
43
 
-"FreeBSD")
44
 
+"FreeBSD" | "GNU/kFreeBSD")
45
 
        $MAKE libOSSlib.so
46
 
        ;;
47
 
 
48
 
--- a/setup/srcconf.c
49
 
+++ b/setup/srcconf.c
50
 
@@ -122,7 +122,7 @@
51
 
 #include "srcconf_linux.inc"
52
 
 #endif
53
 
 
54
 
-#ifdef __FreeBSD__
55
 
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
56
 
 #include "srcconf_freebsd.inc"
57
 
 #endif
58
 
 
59
 
@@ -480,7 +480,7 @@
60
 
 #include "gen_driver_linux.inc"
61
 
 #endif
62
 
 
63
 
-#if defined(__FreeBSD__)
64
 
+#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
65
 
 #include "gen_driver_freebsd.inc"
66
 
 #endif
67
 
 
68
 
@@ -1456,6 +1456,8 @@
69
 
     strcpy (un.sysname, "SCO_SV");
70
 
   if (strcmp (un.sysname, "Haiku") == 0)
71
 
     strcpy (un.sysname, "BeOS");
72
 
+  if (strcmp (un.sysname, "GNU/kFreeBSD") == 0)
73
 
+    strcpy (un.sysname, "FreeBSD");
74
 
   printf ("System: %s\n", un.sysname);
75
 
   strcpy (conf->system, un.sysname);
76
 
   sprintf (this_os, "kernel/OS/%s", un.sysname);
77
 
@@ -1549,7 +1551,7 @@
78
 
   if (hostcc == NULL) hostcc = DEFAULT_CC;
79
 
   if (targetcc == NULL) targetcc = DEFAULT_CC;
80
 
 
81
 
-#if defined(linux) || defined(__FreeBSD__) || defined(__SCO_VERSION__)
82
 
+#if defined(linux) || defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__SCO_VERSION__)
83
 
   mkdir ("target", 0755);
84
 
   mkdir ("target/build", 0755);
85
 
   system ("touch target/build/.nomake");
86
 
--- a/setup/setupdir.sh
87
 
+++ b/setup/setupdir.sh
88
 
@@ -33,6 +33,12 @@
89
 
        OS=BeOS
90
 
 fi
91
 
 
92
 
+# Use the same source directories for FreeBSD and GNU/kFreeBSD
93
 
+if test "$OS " = "GNU/kFreeBSD "
94
 
+then
95
 
+       OS=FreeBSD
96
 
+fi
97
 
+
98
 
 # Use Linux24 as the OS name for Linux 2.4.x
99
 
 if test "$OS " = "Linux "
100
 
 then
101
 
--- a/setup/FreeBSD/build.sh
102
 
+++ b/setup/FreeBSD/build.sh
103
 
@@ -150,10 +150,10 @@
104
 
        strip prototype/usr/sbin/osslic
105
 
 
106
 
         BITS=3 # Default to 32 bit ELF format
107
 
-        if test "`uname -m` " = "amd64 "
108
 
-        then
109
 
+        case "`uname -m`" in amd64|x86_64)
110
 
            BITS=6 # Use 64 bit ELF format
111
 
-        fi
112
 
+       ;;
113
 
+       esac
114
 
 
115
 
        prototype/usr/sbin/osslic -q -u -$BITS./prototype/$OSSLIBDIR/build/osscore.lib
116