From owner-svn-ports-head@freebsd.org Thu Jun 30 12:44:34 2016 Return-Path: Delivered-To: svn-ports-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E67C9B87501; Thu, 30 Jun 2016 12:44:34 +0000 (UTC) (envelope-from marino@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id A8F43207F; Thu, 30 Jun 2016 12:44:34 +0000 (UTC) (envelope-from marino@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u5UCiXkR042470; Thu, 30 Jun 2016 12:44:33 GMT (envelope-from marino@FreeBSD.org) Received: (from marino@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u5UCiX2V042467; Thu, 30 Jun 2016 12:44:33 GMT (envelope-from marino@FreeBSD.org) Message-Id: <201606301244.u5UCiX2V042467@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: marino set sender to marino@FreeBSD.org using -f From: John Marino Date: Thu, 30 Jun 2016 12:44:33 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r417824 - in head/multimedia/libva: . files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 30 Jun 2016 12:44:35 -0000 Author: marino Date: Thu Jun 30 12:44:33 2016 New Revision: 417824 URL: https://svnweb.freebsd.org/changeset/ports/417824 Log: multimedia/libva: USES-= alias, augment patches Threading is still broken on DragonFly when alias is used, so fix by augmenting the same patches FreeBSD uses. These are no-op pre-processor changes for FreeBSD. Approved by: non-invasive DF support blanket Modified: head/multimedia/libva/Makefile head/multimedia/libva/files/patch-test__v4l_h264__encode__capture.cpp head/multimedia/libva/files/patch-va_va__trace.c Modified: head/multimedia/libva/Makefile ============================================================================== --- head/multimedia/libva/Makefile Thu Jun 30 12:23:47 2016 (r417823) +++ head/multimedia/libva/Makefile Thu Jun 30 12:44:33 2016 (r417824) @@ -14,7 +14,7 @@ LICENSE_FILE= ${WRKSRC}/COPYING BUILD_DEPENDS= ${LOCALBASE}/include/linux/videodev2.h:multimedia/v4l_compat LIB_DEPENDS= libdrm.so:graphics/libdrm -USES= alias autoreconf gmake libtool localbase pkgconfig tar:bzip2 +USES= autoreconf gmake libtool localbase pkgconfig tar:bzip2 USE_XORG= glproto pciaccess xext xfixes USE_GL= gl GNU_CONFIGURE= yes Modified: head/multimedia/libva/files/patch-test__v4l_h264__encode__capture.cpp ============================================================================== --- head/multimedia/libva/files/patch-test__v4l_h264__encode__capture.cpp Thu Jun 30 12:23:47 2016 (r417823) +++ head/multimedia/libva/files/patch-test__v4l_h264__encode__capture.cpp Thu Jun 30 12:44:33 2016 (r417824) @@ -1,4 +1,4 @@ ---- test/v4l_h264/encode/capture.cpp.orig 2015-07-01 07:54:24 UTC +--- test/v4l_h264/encode/capture.cpp.orig 2016-06-21 01:29:25 UTC +++ test/v4l_h264/encode/capture.cpp @@ -30,6 +30,7 @@ */ @@ -12,7 +12,7 @@ #include /* low-level i/o */ #include #include -+#ifdef __FreeBSD__ ++#if defined __FreeBSD__ || defined __DragonFly__ +#include +#else #include @@ -24,7 +24,7 @@ } for (n_buffers = 0; n_buffers < 4; ++n_buffers) { buffers[n_buffers].length = buffer_size; -+#ifdef __FreeBSD__ ++#if defined __FreeBSD__ || defined __DragonFly__ + if(posix_memalign(&buffers[n_buffers].start, page_size, buffer_size)) + { +#else Modified: head/multimedia/libva/files/patch-va_va__trace.c ============================================================================== --- head/multimedia/libva/files/patch-va_va__trace.c Thu Jun 30 12:23:47 2016 (r417823) +++ head/multimedia/libva/files/patch-va_va__trace.c Thu Jun 30 12:44:33 2016 (r417824) @@ -10,60 +10,70 @@ #include #include #include -@@ -294,7 +297,11 @@ static void add_trace_config_info( +@@ -294,7 +297,13 @@ static void add_trace_config_info( { struct trace_config_info *pconfig_info; int idx = 0; +#ifdef __FreeBSD__ + pid_t thd_id = pthread_getthreadid_np(); ++#elif defined __DragonFly__ ++ pid_t thd_id = syscall(SYS_lwp_gettid); +#else pid_t thd_id = syscall(__NR_gettid); +#endif LOCK_RESOURCE(pva_trace); -@@ -318,7 +325,11 @@ static void delete_trace_config_info( +@@ -318,7 +327,13 @@ static void delete_trace_config_info( { struct trace_config_info *pconfig_info; int idx = 0; +#ifdef __FreeBSD__ + pid_t thd_id = pthread_getthreadid_np(); ++#elif defined __DragonFly__ ++ pid_t thd_id = syscall(SYS_lwp_gettid); +#else pid_t thd_id = syscall(__NR_gettid); +#endif LOCK_RESOURCE(pva_trace); -@@ -663,7 +674,11 @@ static struct trace_log_file *start_trac +@@ -663,7 +678,13 @@ static struct trace_log_file *start_trac { struct trace_log_files_manager *plog_files_mgr = NULL; struct trace_log_file *plog_file = NULL; +#ifdef __FreeBSD__ + pid_t thd_id = pthread_getthreadid_np(); ++#elif defined __DragonFly__ ++ pid_t thd_id = syscall(SYS_lwp_gettid); +#else pid_t thd_id = syscall(__NR_gettid); +#endif int i = 0; LOCK_RESOURCE(pva_trace); -@@ -702,7 +717,11 @@ static void refresh_log_file( +@@ -702,7 +723,13 @@ static void refresh_log_file( struct trace_context *ptra_ctx) { struct trace_log_file *plog_file = NULL; +#ifdef __FreeBSD__ + pid_t thd_id = pthread_getthreadid_np(); ++#elif defined __DragonFly__ ++ pid_t thd_id = syscall(SYS_lwp_gettid); +#else pid_t thd_id = syscall(__NR_gettid); +#endif int i = 0; plog_file = ptra_ctx->plog_file; -@@ -1226,7 +1245,11 @@ static void internal_TraceUpdateContext +@@ -1226,7 +1253,13 @@ static void internal_TraceUpdateContext { struct trace_context *trace_ctx = NULL; int i = 0, delete = 1; +#ifdef __FreeBSD__ + pid_t thd_id = pthread_getthreadid_np(); ++#elif defined __DragonFly__ ++ pid_t thd_id = syscall(SYS_lwp_gettid); +#else pid_t thd_id = syscall(__NR_gettid); +#endif