aboutsummaryrefslogtreecommitdiff
path: root/sysutils/cdrkit/files/patch-genisomage
blob: 597de213aa9e5933add0826090889ad3d8c0e86a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
Use <sys/endian.h> instead of the linux-ish <endian.h>

Use __attribute__ ((__nothrow__)) instead of the linux-ish __THROW (from the
linux sys/cdefs.h) macro - should work with clang and gcc on FreeBSD.

--- genisoimage/sha256.c.orig	2009-10-11 12:27:59.000000000 -0600
+++ genisoimage/sha256.c	2011-10-27 14:55:25.000000000 -0600
@@ -24,9 +24,9 @@
 
 /* Written by Ulrich Drepper <drepper@redhat.com>, 2007.  */
 
-#include <endian.h>
 #include <stdlib.h>
 #include <string.h>
+#include <sys/endian.h>
 #include <sys/types.h>
 
 #include "sha256.h"
--- genisoimage/sha256.h.orig	2009-05-10 15:49:54.000000000 -0600
+++ genisoimage/sha256.h	2011-10-27 14:58:30.000000000 -0600
@@ -42,14 +42,14 @@
 
 /* Initialize structure containing state of computation.
    (FIPS 180-2: 5.3.2)  */
-extern void sha256_init_ctx (struct sha256_ctx *ctx) __THROW;
+extern void sha256_init_ctx (struct sha256_ctx *ctx) __attribute__ ((__nothrow__));
 
 /* Starting with the result of former calls of this function (or the
    initialization function update the context for the next LEN bytes
    starting at BUFFER.
    It is NOT required that LEN is a multiple of 64.  */
 extern void sha256_process_bytes (const void *buffer, size_t len,
-				    struct sha256_ctx *ctx) __THROW;
+				    struct sha256_ctx *ctx) __attribute__ ((__nothrow__));
 
 /* Process the remaining bytes in the buffer and put result from CTX
    in first 32 bytes following RESBUF.
@@ -57,6 +57,6 @@
    IMPORTANT: On some systems it is required that RESBUF is correctly
    aligned for a 32 bits value.  */
 extern void *sha256_finish_ctx (struct sha256_ctx *ctx, void *resbuf)
-  __THROW;
+  __attribute__ ((__nothrow__));
 
 #endif /* sha256.h */
--- genisoimage/sha512.h.orig	2009-05-10 15:49:54.000000000 -0600
+++ genisoimage/sha512.h	2011-10-27 14:58:35.000000000 -0600
@@ -42,14 +42,14 @@
 
 /* Initialize structure containing state of computation.
    (FIPS 180-2: 5.3.3)  */
-extern void sha512_init_ctx (struct sha512_ctx *ctx) __THROW;
+extern void sha512_init_ctx (struct sha512_ctx *ctx) __attribute__ ((__nothrow__));
 
 /* Starting with the result of former calls of this function (or the
    initialization function update the context for the next LEN bytes
    starting at BUFFER.
    It is NOT required that LEN is a multiple of 128.  */
 extern void sha512_process_bytes (const void *buffer, size_t len,
-				    struct sha512_ctx *ctx) __THROW;
+				    struct sha512_ctx *ctx) __attribute__ ((__nothrow__));
 
 /* Process the remaining bytes in the buffer and put result from CTX
    in first 64 bytes following RESBUF.
@@ -57,6 +57,6 @@
    IMPORTANT: On some systems it is required that RESBUF is correctly
    aligned for a 64 bits value.  */
 extern void *sha512_finish_ctx (struct sha512_ctx *ctx, void *resbuf)
-  __THROW;
+  __attribute__ ((__nothrow__));
 
 #endif /* sha512.h */
--- genisoimage/sha512.c.orig	2009-10-11 12:27:59.000000000 -0600
+++ genisoimage/sha512.c	2011-10-27 14:59:01.000000000 -0600
@@ -24,9 +24,9 @@
 
 /* Written by Ulrich Drepper <drepper@redhat.com>, 2007.  */
 
-#include <endian.h>
 #include <stdlib.h>
 #include <string.h>
+#include <sys/endian.h>
 #include <sys/types.h>
 
 #include "sha512.h"