Bug 175965 - multimedia/libmpeg2 don't register x11 deps
Summary: multimedia/libmpeg2 don't register x11 deps
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Max Brazhnikov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-02-08 20:30 UTC by Pawel Pekala
Modified: 2013-03-25 14:10 UTC (History)
0 users

See Also:


Attachments
file.diff (591 bytes, patch)
2013-02-08 20:30 UTC, Pawel Pekala
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Pawel Pekala freebsd_committer freebsd_triage 2013-02-08 20:30:00 UTC
This package is built with X11 support but fails to register dependency
correctly:

checking for X... libraries /usr/local/lib, headers /usr/local/include
checking whether -R must be followed by a space... no
checking for gethostbyname... yes
checking for connect... yes
checking for remove... yes
checking for shmat... yes
checking for IceConnectionNumber in -lICE... yes
checking for XShmCreateImage in -lXext... yes
checking for XvShmCreateImage in -lXv... yes
checking ddraw.h usability... no
checking ddraw.h presence... no
checking for ddraw.h... no
checking __attribute__ ((aligned ())) support... 64
configure: creating ./config.status

[corn:~]> ldd /usr/local/bin/mpeg2dec
/usr/local/bin/mpeg2dec:
        libSM.so.6 => /usr/local/lib/libSM.so.6 (0x800824000)
        libICE.so.6 => /usr/local/lib/libICE.so.6 (0x800a2c000)
        libXv.so.1 => /usr/local/lib/libXv.so.1 (0x800c46000)
        libXext.so.6 => /usr/local/lib/libXext.so.6 (0x800e4b000)
        libX11.so.6 => /usr/local/lib/libX11.so.6 (0x80105d000)
        libxcb.so.2 => /usr/local/lib/libxcb.so.2 (0x801394000)
        libXau.so.6 => /usr/local/lib/libXau.so.6 (0x8015b0000)
        libXdmcp.so.6 => /usr/local/lib/libXdmcp.so.6 (0x8017b2000)
        libpthread-stubs.so.0 => /usr/local/lib/libpthread-stubs.so.0 (0x8019b7000)
        librpcsvc.so.5 => /usr/lib/librpcsvc.so.5 (0x801bb8000)
        libmpeg2.so.0 => /usr/local/lib/libmpeg2.so.0 (0x801dc1000)
        libmpeg2convert.so.0 => /usr/local/lib/libmpeg2convert.so.0 (0x801ff0000)
        libc.so.7 => /lib/libc.so.7 (0x8021f6000)

Fix: Patch attached with submission follows:
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2013-02-08 20:30:08 UTC
Responsible Changed
From-To: freebsd-ports-bugs->freebsd-multimedia

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Max Brazhnikov freebsd_committer freebsd_triage 2013-03-25 12:07:10 UTC
Responsible Changed
From-To: freebsd-multimedia->makc

I'm working on this.
Comment 3 dfilter service freebsd_committer freebsd_triage 2013-03-25 14:05:31 UTC
Author: makc
Date: Mon Mar 25 14:05:23 2013
New Revision: 315226
URL: http://svnweb.freebsd.org/changeset/ports/315226

Log:
  - Add dependence on X libraries [1] and make it optional
  - Convert to new option framework
  - Convert to USES
  - Trim Makefile header
  - pet portlint: rename patch
  
  PR:		ports/175965 [1]
  Submitted by:	pawel

Added:
     - copied unchanged from r315215, head/multimedia/libmpeg2/files/patch-libmpeg2::idct_alpha.c
Directory Properties:
  head/multimedia/libmpeg2/files/patch-libmpeg2__idct_alpha.c   (props changed)
Deleted:
  head/multimedia/libmpeg2/files/patch-libmpeg2::idct_alpha.c
Modified:
  head/multimedia/libmpeg2/Makefile   (contents, props changed)

Modified: head/multimedia/libmpeg2/Makefile
==============================================================================
--- head/multimedia/libmpeg2/Makefile	Mon Mar 25 14:01:36 2013	(r315225)
+++ head/multimedia/libmpeg2/Makefile	Mon Mar 25 14:05:23 2013	(r315226)
@@ -1,9 +1,5 @@
-# New ports collection makefile for:	libmpeg2
-# Date created:		Tue Oct 16 17:14:20 BRST 2001
-# Whom:                 Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>
-#
+# Created by: Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>
 # $FreeBSD$
-#
 
 PORTNAME=	libmpeg2
 PORTVERSION=	0.5.1
@@ -12,30 +8,36 @@ CATEGORIES=	multimedia
 MASTER_SITES=	http://libmpeg2.sourceforge.net/files/
 
 MAINTAINER=	multimedia@FreeBSD.org
-COMMENT=	A free library for decoding mpeg-2 and mpeg-1 video streams
+COMMENT=	Free library for decoding mpeg-2 and mpeg-1 video streams
 
+USES=		pathfix
 USE_GNOME=	ltverhack
 USE_AUTOTOOLS=	libtool
 USE_LDCONFIG=	yes
 MAKE_JOBS_SAFE=	yes
 
-CONFIGURE_ARGS=	--enable-shared \
-		--with-x
+CONFIGURE_ARGS=	--enable-shared
 
 MAN1=	extract_mpeg2.1 mpeg2dec.1
 
 PORTDOCS=	libmpeg2.txt README
 
-.ifdef(WITH_SDL)
+OPTIONS_DEFINE=	DOCS SDL X11
+
+.include <bsd.port.options.mk>
+
+.if ${PORT_OPTIONS:MSDL}
 USE_SDL=	yes
 CONFIGURE_ARGS+=	--enable-sdl
 .else
 CONFIGURE_ARGS+=	--disable-sdl
 .endif
 
-# allow build with more warnings enabled
-.if defined(NO_WERROR)
-CONFIGURE_ARGS+=	--disable-warnings
+.if ${PORT_OPTIONS:MX11}
+USE_XORG=	sm xv
+CONFIGURE_ARGS+=	--with-x
+.else
+CONFIGURE_ARGS+=	--without-x
 .endif
 
 .include <bsd.port.pre.mk>
@@ -46,29 +48,17 @@ CONFIGURE_ARGS+=	--disable-warnings
 CFLAGS:=	${CFLAGS:N-mcpu=*}
 .endif
 
-pre-everything::
-	@${ECHO_MSG} "====>"
-.ifndef(WITH_SDL)
-	@${ECHO_MSG} "====> You can enable SDL support by defining WITH_SDL"
-.endif
-.ifndef(WITH_MGA)
-	@${ECHO_MSG} "====> You can enable MGA support by defining WITH_MGA"
-.endif
-	@${ECHO_MSG} "====>"
-
 post-patch:
-	@${REINPLACE_CMD} -e 's|-O3||;s|<termio.h>|<termios.h>|' ${WRKSRC}/configure
+	@${REINPLACE_CMD} -e 's|-O3||;s|<termio.h>|<termios.h>|' \
+		${WRKSRC}/configure
 # AMD64 prefers position independent code
 .if ${ARCH:L} == "amd64"
 	@${REINPLACE_CMD} -e 's|-prefer-non-pic||' \
-		${CONFIGURE_WRKSRC}/${CONFIGURE_SCRIPT}
+		${WRKSRC}/configure
 .endif
-	@${REINPLACE_CMD} -e 's|[(]libdir[)]/pkgconfig|(prefix)/libdata/pkgconfig|g' \
-		${WRKSRC}/libmpeg2/Makefile.in
-	@${REINPLACE_CMD} -e 's|[(]libdir[)]/pkgconfig|(prefix)/libdata/pkgconfig|g' \
-		${WRKSRC}/libmpeg2/convert/Makefile.in
+
 post-install:
-.ifndef(NOPORTDOCS)
+.if ${PORT_OPTIONS:MDOCS}
 	${MKDIR} ${DOCSDIR}
 	${INSTALL_DATA} ${WRKSRC}/doc/libmpeg2.txt ${DOCSDIR}
 	${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}

Copied: head/multimedia/libmpeg2/files/patch-libmpeg2__idct_alpha.c (from r315215, head/multimedia/libmpeg2/files/patch-libmpeg2::idct_alpha.c)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/multimedia/libmpeg2/files/patch-libmpeg2__idct_alpha.c	Mon Mar 25 14:05:23 2013	(r315226, copy of r315215, head/multimedia/libmpeg2/files/patch-libmpeg2::idct_alpha.c)
@@ -0,0 +1,17 @@
+--- libmpeg2/idct_alpha.c.orig	Wed May 14 13:19:19 2003
++++ libmpeg2/idct_alpha.c	Wed May 14 13:19:32 2003
+@@ -24,6 +24,14 @@
+ 
+ #include "config.h"
+ 
++#if (defined(__unix__) || defined(unix)) && !defined(USG)
++#include <sys/param.h>
++#endif
++
++#if defined(__FreeBSD__) && __FreeBSD_version < 500000
++typedef __int32_t int_fast32_t;
++#endif
++
+ #ifdef ARCH_ALPHA
+ 
+ #include <stdlib.h>
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 4 Max Brazhnikov freebsd_committer freebsd_triage 2013-03-25 14:06:03 UTC
State Changed
From-To: open->closed

Committed. Thanks!