diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2023-01-07 16:20:14 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2023-02-07 20:05:36 +0000 |
commit | eac5d2ab2c062e5ed4d9c67c7490eb4f1f04ecb7 (patch) | |
tree | 501fd8d83b5b068fc5f31ddbbc1bde53176efc43 | |
parent | 92d331fc8c84d14ba92cc0c4f226e306af664bdc (diff) | |
download | ports-eac5d2ab2c062e5ed4d9c67c7490eb4f1f04ecb7.tar.gz ports-eac5d2ab2c062e5ed4d9c67c7490eb4f1f04ecb7.zip |
audio/deadbeef: fix build with clang 15
During an exp-run for llvm 15 (see bug 265425), it turned out that
audio/deadbeef failed to build with clang 15:
threading_pthread.c:57:12: error: incompatible pointer to integer conversion returning 'pthread_t' (aka 'struct pthread *') from a function with result type 'intptr_t' (aka 'long') [-Wint-conversion]
return tid;
^~~
This is because it is trying to implicitly convert a pthread_t into an
integer. Add a cast to suppress the warning.
PR: 268991
Approved by: maintainer timeout (2 weeks)
MFH: 2023Q1
-rw-r--r-- | audio/deadbeef/files/patch-threading__pthread.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/audio/deadbeef/files/patch-threading__pthread.c b/audio/deadbeef/files/patch-threading__pthread.c new file mode 100644 index 000000000000..af7e3a83cced --- /dev/null +++ b/audio/deadbeef/files/patch-threading__pthread.c @@ -0,0 +1,11 @@ +--- threading_pthread.c.orig 2016-06-19 11:26:18 UTC ++++ threading_pthread.c +@@ -54,7 +54,7 @@ thread_start (void (*fn)(void *ctx), void *ctx) { + fprintf (stderr, "pthread_attr_destroy failed: %s\n", strerror (s)); + return 0; + } +- return tid; ++ return (intptr_t)tid; + } + + intptr_t |