Date: Wed, 28 May 2014 14:19:10 GMT From: Mickael Maillot <mickael.maillot@gmail.com> To: freebsd-gnats-submit@FreeBSD.org Subject: ports/190345: multimedia/libcec update to 2.1.4 Message-ID: <201405281419.s4SEJA8g013236@cgiserv.freebsd.org> Resent-Message-ID: <201405281420.s4SEK0im041570@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 190345 >Category: ports >Synopsis: multimedia/libcec update to 2.1.4 >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: update >Submitter-Id: current-users >Arrival-Date: Wed May 28 14:20:00 UTC 2014 >Closed-Date: >Last-Modified: >Originator: Mickael Maillot >Release: >Organization: >Environment: >Description: Update multimedia/libcec to 2.1.4 remove the patch (included in upstream) add libtool to USES to remove .la file strip the lib file remove -Wno-psabi from flags because it does not exist on base gcc 4.2 >How-To-Repeat: >Fix: Patch attached with submission follows: diff -urbdN libcec.orig/Makefile libcec/Makefile --- libcec.orig/Makefile 2014-05-28 16:09:07.000000000 +0200 +++ libcec/Makefile 2014-05-28 16:11:00.000000000 +0200 @@ -2,8 +2,7 @@ # $FreeBSD: head/multimedia/libcec/Makefile 342445 2014-02-03 13:57:46Z miwi $ PORTNAME= libcec -PORTVERSION= 2.1.3 -PORTREVISION= 1 +PORTVERSION= 2.1.4 CATEGORIES= multimedia MASTER_SITES= GH @@ -15,14 +14,21 @@ USE_GITHUB= yes GH_ACCOUNT= Pulse-Eight -GH_COMMIT= 54be21e -GH_TAGNAME= ${PORTNAME}-${PORTVERSION} +GH_COMMIT= 81e3821 +GH_TAGNAME= ${PORTNAME}-${PORTVERSION}-repack -USES= pathfix pkgconfig +USES= pathfix pkgconfig libtool PATHFIX_MAKEFILEIN=Makefile.am USE_AUTOTOOLS= aclocal autoheader automake autoconf libtoolize ACLOCAL_ARGS= -I. AUTOMAKE_ARGS= --add-missing USE_LDCONFIG= yes +post-patch: + ${REINPLACE_CMD} 's;-Wno-psabi;;' ${WRKSRC}/configure.ac + +post-install: + ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libcec.so.2 + @${CAT} ${PKGMESSAGE} + .include <bsd.port.mk> diff -urbdN libcec.orig/distinfo libcec/distinfo --- libcec.orig/distinfo 2014-05-28 16:09:07.000000000 +0200 +++ libcec/distinfo 2014-05-28 10:52:57.000000000 +0200 @@ -1,2 +1,2 @@ -SHA256 (libcec-2.1.3.tar.gz) = 2aa88451b528184b02077ee8c6cd10e2f89121a6a05b1b35b4b792b03108a9d1 -SIZE (libcec-2.1.3.tar.gz) = 1087121 +SHA256 (libcec-2.1.4.tar.gz) = b8e869cc16a5c73a0da4443911cfd0e931f17324bdaad8210b0de085db0573ea +SIZE (libcec-2.1.4.tar.gz) = 1093922 diff -urbdN libcec.orig/files/patch-src__lib__adapter__Pulse-Eight__USBCECAdapterDetection.cpp libcec/files/patch-src__lib__adapter__Pulse-Eight__USBCECAdapterDetection.cpp --- libcec.orig/files/patch-src__lib__adapter__Pulse-Eight__USBCECAdapterDetection.cpp 2014-05-28 16:09:07.000000000 +0200 +++ libcec/files/patch-src__lib__adapter__Pulse-Eight__USBCECAdapterDetection.cpp 1970-01-01 01:00:00.000000000 +0100 @@ -1,100 +0,0 @@ ---- ./src/lib/adapter/Pulse-Eight/USBCECAdapterDetection.cpp.orig 2013-05-13 15:09:14.000000000 +0200 -+++ ./src/lib/adapter/Pulse-Eight/USBCECAdapterDetection.cpp 2013-06-12 16:31:03.000000000 +0200 -@@ -61,6 +61,8 @@ - #include <libudev.h> - } - #elif defined(__FreeBSD__) -+#include <sys/param.h> -+#include <sys/sysctl.h> - #include <stdio.h> - #include <unistd.h> - #endif -@@ -434,22 +436,77 @@ - } - #elif defined(__FreeBSD__) - char devicePath[PATH_MAX + 1]; -+ char infos[512]; -+ char sysctlname[32]; -+ char ttyname[8]; -+ char *pos; -+ size_t infos_size = sizeof(infos); - int i; - -- for (i = 0; i < 8; ++i) -+ for (i = 0; ; ++i) - { -- (void)snprintf(devicePath, sizeof(devicePath), "/dev/ttyU%d", i); -- if (strDevicePath && strcmp(devicePath, strDevicePath) != 0) -+ unsigned int iVendor, iProduct; -+ memset(infos, 0, sizeof(infos)); -+ (void)snprintf(sysctlname, sizeof(sysctlname), -+ "dev.umodem.%d.%%pnpinfo", i); -+ if (sysctlbyname(sysctlname, infos, &infos_size, -+ NULL, 0) != 0) -+ break; -+ pos = strstr(infos, "vendor="); -+ if (pos == NULL) - continue; -- if (!access(devicePath, 0)) -- { -- snprintf(deviceList[iFound].strComPath, sizeof(deviceList[iFound].strComPath), "%s", devicePath); -- snprintf(deviceList[iFound].strComName, sizeof(deviceList[iFound].strComName), "%s", devicePath); -- deviceList[iFound].iVendorId = CEC_VID; -- deviceList[iFound].iProductId = CEC_VID; -- deviceList[iFound].adapterType = ADAPTERTYPE_P8_EXTERNAL; // will be overridden when not doing a "quick scan" by the actual type -- iFound++; -+ sscanf(pos, "vendor=%x ", &iVendor); -+ -+ pos = strstr(infos, "product="); -+ if (pos == NULL) -+ continue; -+ sscanf(pos, "product=%x ", &iProduct); -+ -+ if (iVendor != CEC_VID || (iProduct != CEC_PID && iProduct != CEC_PID2)) -+ continue; -+ -+ pos = strstr(infos, "ttyname="); -+ if (pos == NULL) -+ continue; -+ sscanf(pos, "ttyname=%s ", ttyname); -+ -+ (void)snprintf(devicePath, sizeof(devicePath), -+ "/dev/tty%s", ttyname); -+ -+ if (strDevicePath) { -+ char currStrDevicePath[512]; -+ int port = 0; -+ int devaddr = 0; -+ memset(currStrDevicePath, 0, sizeof(currStrDevicePath)); -+ memset(infos, 0, sizeof(infos)); -+ (void)snprintf(sysctlname, sizeof(sysctlname), -+ "dev.umodem.%d.%%location", i); -+ if (sysctlbyname(sysctlname, infos, &infos_size, -+ NULL, 0) != 0) -+ break; -+ -+ pos = strstr(infos, "port="); -+ if (pos == NULL) -+ continue; -+ sscanf(pos, "port=%d ", &port); -+ -+ pos = strstr(infos, "devaddr="); -+ if (pos == NULL) -+ continue; -+ sscanf(pos, "devaddr=%d ", &devaddr); -+ -+ (void)snprintf(currStrDevicePath, sizeof(currStrDevicePath), -+ "/dev/ugen%d.%d", port, devaddr); -+ -+ if (strcmp(currStrDevicePath, strDevicePath) != 0) -+ continue; - } -+ snprintf(deviceList[iFound].strComPath, sizeof(deviceList[iFound].strComPath), "%s", devicePath); -+ snprintf(deviceList[iFound].strComName, sizeof(deviceList[iFound].strComName), "%s", devicePath); -+ deviceList[iFound].iVendorId = iVendor; -+ deviceList[iFound].iProductId = iProduct; -+ deviceList[iFound].adapterType = ADAPTERTYPE_P8_EXTERNAL; // will be overridden when not doing a "quick scan" by the actual type -+ iFound++; - } - #else - //silence "unused" warnings diff -urbdN libcec.orig/pkg-plist libcec/pkg-plist --- libcec.orig/pkg-plist 2014-05-28 16:09:07.000000000 +0200 +++ libcec/pkg-plist 2014-05-28 11:04:51.000000000 +0200 @@ -1,6 +1,5 @@ lib/libcec.so lib/libcec.so.2 -lib/libcec.la lib/libcec.a include/libcec/cec.h include/libcec/cecc.h >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201405281419.s4SEJA8g013236>