pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc Fix build with Clang.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/bd7aec80b595
branches:  trunk
changeset: 604360:bd7aec80b595
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Tue May 29 20:18:28 2012 +0000

description:
Fix build with Clang.

diffstat:

 databases/db4/distinfo                          |   3 +-
 databases/db4/patches/patch-dbinc_atomic.h      |  38 +++++++++++++++++++++++++
 net/libsoup24/distinfo                          |   3 +-
 net/libsoup24/patches/patch-tests_coding-test.c |  38 +++++++++++++++++++++++++
 4 files changed, 80 insertions(+), 2 deletions(-)

diffs (109 lines):

diff -r c169e7f27040 -r bd7aec80b595 databases/db4/distinfo
--- a/databases/db4/distinfo    Tue May 29 18:33:34 2012 +0000
+++ b/databases/db4/distinfo    Tue May 29 20:18:28 2012 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.38 2011/02/04 12:26:01 obache Exp $
+$NetBSD: distinfo,v 1.39 2012/05/29 20:18:28 joerg Exp $
 
 SHA1 (db-4.8.30.tar.gz) = ab36c170dda5b2ceaad3915ced96e41c6b7e493c
 RMD160 (db-4.8.30.tar.gz) = dd2fcd4c9b857a91e2f491fd4fadb0c51b993a9c
@@ -7,3 +7,4 @@
 SHA1 (patch-ab) = 8f9ecc47527d338e28ee1ce71e694eaf2bdceb92
 SHA1 (patch-ac) = 045a3b83b9c6c164382ec546b06ae248620552cf
 SHA1 (patch-ae) = 43e574154de93dba60392b09d6ebddbca1036849
+SHA1 (patch-dbinc_atomic.h) = ff60e3af41ac1b000ebccc91bc673adde5c7463b
diff -r c169e7f27040 -r bd7aec80b595 databases/db4/patches/patch-dbinc_atomic.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/db4/patches/patch-dbinc_atomic.h        Tue May 29 20:18:28 2012 +0000
@@ -0,0 +1,38 @@
+$NetBSD: patch-dbinc_atomic.h,v 1.1 2012/05/29 20:18:28 joerg Exp $
+
+Don't define inline functions in the protected namespace.
+This conflicts with Clang builtins.
+
+--- dbinc/atomic.h.orig        2012-05-24 10:38:34.000000000 +0000
++++ dbinc/atomic.h
+@@ -141,11 +141,7 @@ typedef LONG volatile *interlocked_val;
+ 
+ #if defined(HAVE_ATOMIC_X86_GCC_ASSEMBLY)
+ /* x86/x86_64 gcc  */
+-#define       atomic_inc(env, p)      __atomic_inc(p)
+-#define       atomic_dec(env, p)      __atomic_dec(p)
+-#define       atomic_compare_exchange(env, p, o, n)   \
+-      __atomic_compare_exchange((p), (o), (n))
+-static inline int __atomic_inc(db_atomic_t *p)
++static inline int atomic_inc(ENV *unused, db_atomic_t *p)
+ {
+       int     temp;
+ 
+@@ -156,7 +152,7 @@ static inline int __atomic_inc(db_atomic
+       return (temp + 1);
+ }
+ 
+-static inline int __atomic_dec(db_atomic_t *p)
++static inline int atomic_dec(ENV *unused, db_atomic_t *p)
+ {
+       int     temp;
+ 
+@@ -176,7 +172,7 @@ static inline int __atomic_dec(db_atomic
+  * http://gcc.gnu.org/onlinedocs/gcc-4.1.0/gcc/Atomic-Builtins.html
+  * which configure could be changed to use.
+  */
+-static inline int __atomic_compare_exchange(
++static inline int atomic_compare_exchange(ENV *unused,
+       db_atomic_t *p, atomic_value_t oldval, atomic_value_t newval)
+ {
+       atomic_value_t was;
diff -r c169e7f27040 -r bd7aec80b595 net/libsoup24/distinfo
--- a/net/libsoup24/distinfo    Tue May 29 18:33:34 2012 +0000
+++ b/net/libsoup24/distinfo    Tue May 29 20:18:28 2012 +0000
@@ -1,5 +1,6 @@
-$NetBSD: distinfo,v 1.27 2012/04/30 14:22:36 drochner Exp $
+$NetBSD: distinfo,v 1.28 2012/05/29 20:21:53 joerg Exp $
 
 SHA1 (libsoup-2.38.1.tar.xz) = 8418440ff59917dee2e5618965cf8683b61258bf
 RMD160 (libsoup-2.38.1.tar.xz) = 6603131f0c1e84225f7b508a18927e3733910ddc
 Size (libsoup-2.38.1.tar.xz) = 620832 bytes
+SHA1 (patch-tests_coding-test.c) = 2b76cf778cf389d9c67abb2b5222656e7e4191fb
diff -r c169e7f27040 -r bd7aec80b595 net/libsoup24/patches/patch-tests_coding-test.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/net/libsoup24/patches/patch-tests_coding-test.c   Tue May 29 20:18:28 2012 +0000
@@ -0,0 +1,38 @@
+$NetBSD: patch-tests_coding-test.c,v 1.1 2012/05/29 20:21:53 joerg Exp $
+
+--- tests/coding-test.c.orig   2012-05-05 16:22:51.000000000 +0000
++++ tests/coding-test.c
+@@ -46,7 +46,7 @@ server_callback (SoupServer *server, Sou
+ 
+       if (codings) {
+               gboolean claim_deflate, claim_gzip;
+-              const char *file_path = NULL, *encoding = NULL;
++              const char *encoding = NULL, *suffix;
+ 
+               claim_deflate = g_slist_find_custom (codings, "deflate", (GCompareFunc)g_ascii_strcasecmp) != NULL;
+               claim_gzip = g_slist_find_custom (codings, "gzip", (GCompareFunc)g_ascii_strcasecmp) != NULL;
+@@ -54,19 +54,19 @@ server_callback (SoupServer *server, Sou
+               if (claim_gzip && (!claim_deflate ||
+                                  (!soup_header_contains (options, "prefer-deflate-zlib") &&
+                                   !soup_header_contains (options, "prefer-deflate-raw")))) {
+-                      file_path = SRCDIR "/resources%s.gz";
++                      suffix = ".gz";
+                       encoding = "gzip";
+               } else if (claim_deflate) {
+                       if (soup_header_contains (options, "prefer-deflate-raw")) {
+-                              file_path = SRCDIR "/resources%s.raw";
++                              suffix = ".raw";
+                               encoding = "deflate";
+                       } else {
+-                              file_path = SRCDIR "/resources%s.zlib";
++                              suffix = ".zlib";
+                               encoding = "deflate";
+                       }
+               }
+-              if (file_path && encoding) {
+-                      file = g_strdup_printf (file_path, path);
++              if (encoding) {
++                      file = g_strdup_printf (SRCDIR "/resources%s%s", path, suffix);
+                       if (g_file_test (file, G_FILE_TEST_EXISTS)) {
+                               soup_message_headers_append (msg->response_headers,
+                                                            "Content-Encoding",



Home | Main Index | Thread Index | Old Index