Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 16 Apr 2016 18:00:46 +0000 (UTC)
From:      Thomas Zander <riggs@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r413472 - in head/multimedia/libcec: . files
Message-ID:  <201604161800.u3GI0kUC071787@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: riggs
Date: Sat Apr 16 18:00:46 2016
New Revision: 413472
URL: https://svnweb.freebsd.org/changeset/ports/413472

Log:
  Update to upstream version 3.1.0, introduce OPTIONS for PYTHON, X11 and RPI
  
  Details
  - Turn existing python wrapper and X11 support into default OPTIONS
  - Introduce RPI non-default OPTION on armv6
  
  PR:		208161
  Submitted by:	mickael.maillot@gmail.com
  Approved by:	maintainer timeout

Added:
  head/multimedia/libcec/files/patch-src_libcec_cmake_SetBuildInfo.cmake   (contents, props changed)
Deleted:
  head/multimedia/libcec/files/patch-configure.ac
Modified:
  head/multimedia/libcec/Makefile
  head/multimedia/libcec/distinfo
  head/multimedia/libcec/pkg-message
  head/multimedia/libcec/pkg-plist

Modified: head/multimedia/libcec/Makefile
==============================================================================
--- head/multimedia/libcec/Makefile	Sat Apr 16 17:56:03 2016	(r413471)
+++ head/multimedia/libcec/Makefile	Sat Apr 16 18:00:46 2016	(r413472)
@@ -2,9 +2,8 @@
 # $FreeBSD$
 
 PORTNAME=	libcec
-PORTVERSION=	2.2.0
+PORTVERSION=	3.1.0
 DISTVERSIONPREFIX=	${PORTNAME}-
-DISTVERSIONSUFFIX=	-repack
 CATEGORIES=	multimedia
 
 MAINTAINER=	manuel.creach@icloud.com
@@ -13,20 +12,49 @@ COMMENT=	Library to control Pulse-Eight'
 LICENSE=	GPLv2
 LICENSE_FILE=	${WRKSRC}/COPYING
 
+LIB_DEPENDS=	libp8-platform.so:devel/p8-platform
+
 USE_GITHUB=	yes
 GH_ACCOUNT=	Pulse-Eight
 
-GNU_CONFIGURE=	yes
-USES=		alias autoreconf pathfix pkgconfig libtool
-PATHFIX_MAKEFILEIN=Makefile.am
-USE_XORG=	x11 xproto xrandr
+USES=	alias cmake compiler:c++11-lib pkgconfig
 USE_LDCONFIG=	yes
-INSTALL_TARGET=	install-strip
+CMAKE_ARGS=	-DCMAKE_REQUIRED_INCLUDES:PATH="${LOCALBASE}/include" \
+		-DCMAKE_REQUIRED_FLAGS:STRING="-L${LOCALBASE}/lib"
+
+OPTIONS_DEFINE=	PYTHON X11
+OPTIONS_DEFAULT=	PYTHON X11
+OPTIONS_DEFINE_armv6=	RPI
+OPTIONS_DEFAULT_armv6=
+OPTIONS_SUB=	yes
+
+PYTHON_DESC=	build python wrapper
+PYTHON_BUILD_DEPENDS+=	swig3.0:devel/swig30
+RPI_DESC=	build libcec support for raspberrypi
+RPI_CMAKE_ON=	-DRPI_INCLUDE_DIR=${LOCALBASE}/include -DRPI_LIB_DIR=${LOCALBASE}/lib
+RPI_LIB_DEPENDS=	libbcm_host.so:misc/raspberrypi-userland
 
 .include <bsd.port.options.mk>
 
-.if ${ARCH} == armv6
-CONFIGURE_ARGS=	--disable-rpi
+.if ${PORT_OPTIONS:MPYTHON}
+USES+=		python:build
+.else
+CMAKE_ARGS+=	-DSKIP_PYTHON_WRAPPER:BOOL=true
+.endif
+
+.if ${PORT_OPTIONS:MX11}
+USE_XORG=	x11 xproto xrandr
+.endif
+
+post-patch:
+	@${REINPLACE_CMD} 's|$${GIT_REVISION}|${PORTVERSION}|g' \
+		${WRKSRC}/src/libcec/cmake/SetBuildInfo.cmake
+	@${REINPLACE_CMD} -e '/SOVERSION/ s|\.0||' \
+		-e 's|$${CMAKE_INSTALL_LIBDIR_NOARCH}/pkgconfig|libdata/pkgconfig|' \
+		${WRKSRC}/src/libcec/CMakeLists.txt
+.if ! ${PORT_OPTIONS:MPYTHON}
+	@${REINPLACE_CMD} '/pyCecClient/d' \
+		${WRKSRC}/CMakeLists.txt
 .endif
 
 .include <bsd.port.mk>

Modified: head/multimedia/libcec/distinfo
==============================================================================
--- head/multimedia/libcec/distinfo	Sat Apr 16 17:56:03 2016	(r413471)
+++ head/multimedia/libcec/distinfo	Sat Apr 16 18:00:46 2016	(r413472)
@@ -1,2 +1,2 @@
-SHA256 (Pulse-Eight-libcec-libcec-2.2.0-repack_GH0.tar.gz) = 5d8c8de65354de82299c163078538d7b3ba0a59c5789bb4b23619be4d154aecd
-SIZE (Pulse-Eight-libcec-libcec-2.2.0-repack_GH0.tar.gz) = 1099286
+SHA256 (Pulse-Eight-libcec-libcec-3.1.0_GH0.tar.gz) = 09109d21a1b03f42c9e341d12600f2e4c41038d640269fa75408e2d36126f921
+SIZE (Pulse-Eight-libcec-libcec-3.1.0_GH0.tar.gz) = 1097121

Added: head/multimedia/libcec/files/patch-src_libcec_cmake_SetBuildInfo.cmake
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/multimedia/libcec/files/patch-src_libcec_cmake_SetBuildInfo.cmake	Sat Apr 16 18:00:46 2016	(r413472)
@@ -0,0 +1,17 @@
+--- src/libcec/cmake/SetBuildInfo.cmake.orig	2016-01-20 00:52:02 UTC
++++ src/libcec/cmake/SetBuildInfo.cmake
+@@ -14,14 +14,7 @@ else()
+   set(LIB_INFO "")
+ 
+   # add git revision to compile info
+-  find_program(HAVE_GIT_BIN git /bin /usr/bin /usr/local/bin)
+-  if(HAVE_GIT_BIN)
+-    exec_program(${CMAKE_CURRENT_SOURCE_DIR}/../../support/git-rev.sh HEAD OUTPUT_VARIABLE GIT_REVISION)
+-    message(STATUS "git found: ${GIT_REVISION}")
+-  endif()
+-  if (GIT_REVISION)
+     set(LIB_INFO "git revision: ${GIT_REVISION},")
+-  endif()
+ 
+   # add compilation date to compile info
+   find_program(HAVE_DATE_BIN date /bin /usr/bin /usr/local/bin)

Modified: head/multimedia/libcec/pkg-message
==============================================================================
--- head/multimedia/libcec/pkg-message	Sat Apr 16 17:56:03 2016	(r413471)
+++ head/multimedia/libcec/pkg-message	Sat Apr 16 18:00:46 2016	(r413472)
@@ -16,4 +16,4 @@ devfs_system_ruleset="system"
 
 Then restart devfs to load the new rule:
 
-% /etc/rc.d/devfs restart
+% service devfs restart

Modified: head/multimedia/libcec/pkg-plist
==============================================================================
--- head/multimedia/libcec/pkg-plist	Sat Apr 16 17:56:03 2016	(r413471)
+++ head/multimedia/libcec/pkg-plist	Sat Apr 16 18:00:46 2016	(r413472)
@@ -1,10 +1,16 @@
 bin/cec-client
+bin/cec-client-3.1.0
+bin/cecc-client
+bin/cecc-client-3.1.0
+%%PYTHON%%bin/pyCecClient.py
 include/libcec/cec.h
 include/libcec/cecc.h
 include/libcec/cecloader.h
 include/libcec/cectypes.h
-lib/libcec.a
+include/libcec/version.h
 lib/libcec.so
-lib/libcec.so.2
-lib/libcec.so.2.0.1
+lib/libcec.so.3
+lib/libcec.so.3.1.0
+%%PYTHON%%%%PYTHON_LIBDIR%%/dist-packages/cec/__init__.py
+%%PYTHON%%%%PYTHON_LIBDIR%%/dist-packages/cec/_cec.so
 libdata/pkgconfig/libcec.pc



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201604161800.u3GI0kUC071787>