aboutsummaryrefslogtreecommitdiffstats
path: root/x11/libxshmfence
diff options
context:
space:
mode:
Diffstat (limited to 'x11/libxshmfence')
-rw-r--r--x11/libxshmfence/Makefile3
-rw-r--r--x11/libxshmfence/distinfo4
-rw-r--r--x11/libxshmfence/files/patch-config.h.in16
-rw-r--r--x11/libxshmfence/files/patch-configure34
-rw-r--r--x11/libxshmfence/files/patch-src__xshmfence_alloc.c19
-rw-r--r--x11/libxshmfence/files/patch-src__xshmfence_futex.h47
-rw-r--r--x11/libxshmfence/files/patch-src__xshmfenceint.h4
-rw-r--r--x11/libxshmfence/pkg-plist1
8 files changed, 23 insertions, 105 deletions
diff --git a/x11/libxshmfence/Makefile b/x11/libxshmfence/Makefile
index bcbb547b0c99..ffaecd4cfce7 100644
--- a/x11/libxshmfence/Makefile
+++ b/x11/libxshmfence/Makefile
@@ -1,8 +1,7 @@
# $FreeBSD$
PORTNAME= libxshmfence
-PORTVERSION= 1.1
-PORTREVISION= 3
+PORTVERSION= 1.2
CATEGORIES= x11
MAINTAINER= x11@FreeBSD.org
diff --git a/x11/libxshmfence/distinfo b/x11/libxshmfence/distinfo
index 3b5cd8708404..294441d35545 100644
--- a/x11/libxshmfence/distinfo
+++ b/x11/libxshmfence/distinfo
@@ -1,2 +1,2 @@
-SHA256 (xorg/lib/libxshmfence-1.1.tar.bz2) = dbc2db2925ca9f216fd1e9c63d0974db9f4d49aaf5877ffb606d2d8d7e58cebe
-SIZE (xorg/lib/libxshmfence-1.1.tar.bz2) = 291347
+SHA256 (xorg/lib/libxshmfence-1.2.tar.bz2) = d21b2d1fd78c1efbe1f2c16dae1cb23f8fd231dcf891465b8debe636a9054b0c
+SIZE (xorg/lib/libxshmfence-1.2.tar.bz2) = 267170
diff --git a/x11/libxshmfence/files/patch-config.h.in b/x11/libxshmfence/files/patch-config.h.in
index bbb52e10cc3a..ea93bae1d58a 100644
--- a/x11/libxshmfence/files/patch-config.h.in
+++ b/x11/libxshmfence/files/patch-config.h.in
@@ -1,6 +1,6 @@
---- config.h.in 2013-11-27 00:54:40.000000000 -0500
-+++ config.h.in 2013-12-09 16:56:20.000000000 -0500
-@@ -12,6 +12,9 @@
+--- config.h.in.orig 2015-03-04 15:18:49 UTC
++++ config.h.in
+@@ -22,6 +22,9 @@
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
@@ -10,13 +10,3 @@
/* Use pthread primitives */
#undef HAVE_PTHREAD
-@@ -33,6 +36,9 @@
- /* Define to 1 if you have the <sys/types.h> header file. */
- #undef HAVE_SYS_TYPES_H
-
-+/* Use umtx */
-+#undef HAVE_UMTX
-+
- /* Define to 1 if you have the <unistd.h> header file. */
- #undef HAVE_UNISTD_H
-
diff --git a/x11/libxshmfence/files/patch-configure b/x11/libxshmfence/files/patch-configure
index dda82c69cf4f..60947610abad 100644
--- a/x11/libxshmfence/files/patch-configure
+++ b/x11/libxshmfence/files/patch-configure
@@ -1,34 +1,6 @@
---- configure 2013-11-27 00:54:35.000000000 -0500
-+++ configure 2013-12-09 15:03:55.000000000 -0500
-@@ -17633,11 +17633,27 @@
- ac_fn_c_check_header_mongrel "$LINENO" "linux/futex.h" "ac_cv_header_linux_futex_h" "$ac_includes_default"
- if test "x$ac_cv_header_linux_futex_h" = xyes; then :
- FUTEX=yes
-+fi
-+
-+
-+fi
-+
-+if test "x$FUTEX" = "xauto"; then
-+ ac_fn_c_check_header_compile "$LINENO" "sys/umtx.h" "ac_cv_header_sys_umtx_h" "#include <errno.h>
-+ #include <sys/types.h>
-+"
-+if test "x$ac_cv_header_sys_umtx_h" = xyes; then :
-+ FUTEX=yes
- else
- FUTEX=no
- fi
-
-
-+ if test "x$FUTEX" = "xyes"; then
-+
-+$as_echo "#define HAVE_UMTX 1" >>confdefs.h
-+
-+ fi
- fi
-
- if test "x$FUTEX" = "xyes"; then
-@@ -17717,6 +17733,14 @@
+--- configure.orig 2015-03-04 15:22:23 UTC
++++ configure
+@@ -18104,6 +18104,14 @@ else
fi
diff --git a/x11/libxshmfence/files/patch-src__xshmfence_alloc.c b/x11/libxshmfence/files/patch-src__xshmfence_alloc.c
index 682232029c9a..ea14877817ec 100644
--- a/x11/libxshmfence/files/patch-src__xshmfence_alloc.c
+++ b/x11/libxshmfence/files/patch-src__xshmfence_alloc.c
@@ -1,19 +1,24 @@
---- src/xshmfence_alloc.c.orig 2013-11-20 17:13:08.000000000 -0500
-+++ src/xshmfence_alloc.c 2014-07-08 16:39:18.000000000 -0400
-@@ -39,10 +39,14 @@
+--- src/xshmfence_alloc.c.orig 2015-03-04 15:28:23 UTC
++++ src/xshmfence_alloc.c
+@@ -67,15 +67,19 @@ int
xshmfence_alloc_shm(void)
{
char template[] = SHMDIR "/shmfd-XXXXXX";
- int fd;
+ int fd = -1;
+ #if HAVE_MEMFD_CREATE
+ fd = memfd_create("xshmfence", MFD_CLOEXEC|MFD_ALLOW_SEALING);
+ if (fd < 0)
+ #endif
+ {
-#ifdef O_TMPFILE
+#if defined(O_CLOEXEC)
+#if defined(HAVE_MKOSTEMP)
-+ fd = mkostemp(template, O_CLOEXEC);
++ fd = mkostemp(template, O_CLOEXEC);
+#elif defined(O_TMPFILE)
- fd = open(SHMDIR, O_TMPFILE|O_RDWR|O_CLOEXEC|O_EXCL, 0666);
+ fd = open(SHMDIR, O_TMPFILE|O_RDWR|O_CLOEXEC|O_EXCL, 0666);
+#endif
- if (fd < 0)
+ if (fd < 0)
#endif
- {
+ {
diff --git a/x11/libxshmfence/files/patch-src__xshmfence_futex.h b/x11/libxshmfence/files/patch-src__xshmfence_futex.h
deleted file mode 100644
index 253d9d54f947..000000000000
--- a/x11/libxshmfence/files/patch-src__xshmfence_futex.h
+++ /dev/null
@@ -1,47 +0,0 @@
---- src/xshmfence_futex.h
-+++ src/xshmfence_futex.h
-@@ -1,5 +1,6 @@
- /*
- * Copyright © 2013 Keith Packard
-+ * Copyright © 2013-2014 Jung-uk Kim <jkim@FreeBSD.org>
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
-@@ -24,6 +25,28 @@
- #define _XSHMFENCE_FUTEX_H_
-
- #include <errno.h>
-+
-+#ifdef HAVE_UMTX
-+
-+#include <sys/limits.h>
-+#include <sys/types.h>
-+#include <sys/umtx.h>
-+
-+static inline int sys_futex(void *addr, int op, int32_t val)
-+{
-+ return _umtx_op(addr, op, (uint32_t)val, NULL, NULL) == -1 ? errno : 0;
-+}
-+
-+static inline int futex_wake(int32_t *addr) {
-+ return sys_futex(addr, UMTX_OP_WAKE, INT_MAX);
-+}
-+
-+static inline int futex_wait(int32_t *addr, int32_t value) {
-+ return sys_futex(addr, UMTX_OP_WAIT_UINT, value);
-+}
-+
-+#else
-+
- #include <stdint.h>
- #include <values.h>
- #include <linux/futex.h>
-@@ -43,6 +66,8 @@
- return sys_futex(addr, FUTEX_WAIT, value, NULL, NULL, 0);
- }
-
-+#endif
-+
- #define barrier() __asm__ __volatile__("": : :"memory")
-
- static inline void atomic_store(int32_t *f, int32_t v)
diff --git a/x11/libxshmfence/files/patch-src__xshmfenceint.h b/x11/libxshmfence/files/patch-src__xshmfenceint.h
index bc8aead76698..9e969d54267f 100644
--- a/x11/libxshmfence/files/patch-src__xshmfenceint.h
+++ b/x11/libxshmfence/files/patch-src__xshmfenceint.h
@@ -1,5 +1,5 @@
---- src/xshmfenceint.h 2013-11-20 17:14:05.000000000 -0500
-+++ src/xshmfenceint.h 2013-12-09 15:14:36.000000000 -0500
+--- src/xshmfenceint.h.orig 2015-03-04 15:38:56 UTC
++++ src/xshmfenceint.h
@@ -23,6 +23,7 @@
#ifndef _XSHMFENCEINT_H_
#define _XSHMFENCEINT_H_
diff --git a/x11/libxshmfence/pkg-plist b/x11/libxshmfence/pkg-plist
index 54519a918119..cca5d27cfb98 100644
--- a/x11/libxshmfence/pkg-plist
+++ b/x11/libxshmfence/pkg-plist
@@ -1,6 +1,5 @@
include/X11/xshmfence.h
lib/libxshmfence.a
-lib/libxshmfence.la
lib/libxshmfence.so
lib/libxshmfence.so.1
lib/libxshmfence.so.1.0.0