From owner-freebsd-ports-bugs@FreeBSD.ORG Sat Dec 2 21:00:24 2006 Return-Path: X-Original-To: freebsd-ports-bugs@hub.freebsd.org Delivered-To: freebsd-ports-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BCDC816A403 for ; Sat, 2 Dec 2006 21:00:24 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [69.147.83.40]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9C75543CA8 for ; Sat, 2 Dec 2006 21:00:01 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id kB2L0NjZ075973 for ; Sat, 2 Dec 2006 21:00:23 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id kB2L0NKr075972; Sat, 2 Dec 2006 21:00:23 GMT (envelope-from gnats) Resent-Date: Sat, 2 Dec 2006 21:00:23 GMT Resent-Message-Id: <200612022100.kB2L0NKr075972@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Bartosz Fabianowski Received: from mx1.FreeBSD.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id C916B16A407 for ; Sat, 2 Dec 2006 20:54:36 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [69.147.83.33]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4B90B43C9D for ; Sat, 2 Dec 2006 20:54:14 +0000 (GMT) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.13.1/8.13.1) with ESMTP id kB2Ksa0k058038 for ; Sat, 2 Dec 2006 20:54:36 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.13.1/8.13.1/Submit) id kB2KsahU058037; Sat, 2 Dec 2006 20:54:36 GMT (envelope-from nobody) Message-Id: <200612022054.kB2KsahU058037@www.freebsd.org> Date: Sat, 2 Dec 2006 20:54:36 GMT From: Bartosz Fabianowski To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.0 Cc: Subject: ports/106232: [PATCH] Add SDL sound support to games/freeciv* X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 02 Dec 2006 21:00:24 -0000 >Number: 106232 >Category: ports >Synopsis: [PATCH] Add SDL sound support to games/freeciv* >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sat Dec 02 21:00:18 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Bartosz Fabianowski >Release: 6.2-PRERELEASE >Organization: >Environment: FreeBSD takahe.local 6.2-PRERELEASE FreeBSD 6.2-PRERELEASE #0: Mon Nov 27 19:22:17 GMT 2006 root@takahe.local:/usr/obj/usr/src/sys/TAKAHE i386 >Description: Although freeciv is able to play sounds, the FreeBSD port does not enable this functionality. The following patch adds optional sound support and also installs the default sound theme (the only one available on the freeciv site). Caveats: * Freeciv supports both SDL and esound. Since I do not have esound installed and have no interest in it, this patch adds SDL support only. However, esound should be trivial to add as the sound theme installation code should work for it as well. * This patch has only seen limited testing on a single 6.2-PRERELEASE i386 machine. Unfortunately, I do not have access to any other releases or architectures for testing purposes. * There appears to be no information on the freeciv site regarding the licensing of the default sound theme. Before integrating this patch, the maintainer may want to contact the freeciv developers and clarify the licensing terms. >How-To-Repeat: >Fix: diff -ruN freeciv.orig/Makefile freeciv/Makefile --- freeciv.orig/Makefile Tue Sep 26 08:40:33 2006 +++ freeciv/Makefile Sat Dec 2 20:30:46 2006 @@ -7,16 +7,17 @@ PORTNAME= freeciv PORTVERSION= 2.0.8 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES= games -MASTER_SITES= ftp://ftp.freeciv.org/pub/freeciv/stable/ SF +MASTER_SITES= ftp://ftp.freeciv.org/pub/freeciv/stable/ SF \ + ftp://ftp.freeciv.org/freeciv/contrib/sounds/sets/:freeciv_sounds +DISTFILES+= ${DISTNAME}.tar.bz2 stdsounds3.tar.gz:freeciv_sounds MAINTAINER= infofarmer@FreeBSD.org COMMENT= Free turn-based multiplayer strategy USE_GCC= 3.4+ USE_GETTEXT= yes -USE_BZIP2= yes USE_PYTHON= yes GNU_CONFIGURE= yes CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ @@ -29,12 +30,20 @@ png.5:${PORTSDIR}/graphics/png USE_XPM= yes WANT_GNOME= yes -CONFIGURE_ENV+= SDL_CONFIG="${SDL_CONFIG}" +WANT_SDL= mixer PLIST_SUB+= X11="" .endif .include +.if !defined(WITHOUT_X11) && (defined(WITH_SDL) || ${HAVE_SDL:Mmixer}!="") +USE_SDL= mixer +SOUND= yes +PLIST_SUB+= SOUND="" +.else +PLIST_SUB+= SOUND="@comment " +.endif + .if !defined(WITH_GTK) && !defined(WITH_GTK12) && !defined(WITH_GTK2) && \ !defined(WITHOUT_GNOME) && !defined(WITHOUT_X11) AUTO_DEPENDS= yes @@ -84,9 +93,17 @@ .endif post-patch: - @${REINPLACE_CMD} -Ee '${CFG_PATCH}' ${WRKSRC}/configure + @${REINPLACE_CMD} -Ee '${CFG_PATCH}' -e 's/-lSDL_mixer /${PTHREAD_LIBS} -lSDL_mixer /g' ${WRKSRC}/configure @${FIND} ${WRKSRC} -name Makefile.in | \ ${XARGS} ${REINPLACE_CMD} -e 's/@program_transform_name@//' + +post-install: +.ifdef SOUND + ${INSTALL_DATA} ${WRKDIR}/data/stdsounds.soundspec ${DATADIR} + ${MKDIR} ${DATADIR}/stdsounds + @cd ${WRKDIR}/data/stdsounds && \ + ${FIND} * -type f -exec ${INSTALL_DATA} "{}" "${DATADIR}/stdsounds/{}" \; +.endif .if ${OSVERSION} < 500000 BROKEN= Does not build on 4.x diff -ruN freeciv.orig/distinfo freeciv/distinfo --- freeciv.orig/distinfo Sat Apr 29 22:40:45 2006 +++ freeciv/distinfo Sat Dec 2 20:30:46 2006 @@ -1,3 +1,6 @@ MD5 (freeciv-2.0.8.tar.bz2) = 9ebd5899c2c78362e0e2c68791673a88 SHA256 (freeciv-2.0.8.tar.bz2) = 85b396c86f977b85f03fa1309733d21f7cc953e005ff1475f9981b77fa9f28f3 SIZE (freeciv-2.0.8.tar.bz2) = 8535513 +MD5 (stdsounds3.tar.gz) = 77215914712f2f351092918f5e41e39e +SHA256 (stdsounds3.tar.gz) = a3cc2be93c006c3a9492349aa4552bf059e45efc94135f09241877c221ae1bfa +SIZE (stdsounds3.tar.gz) = 118278 diff -ruN freeciv.orig/pkg-plist freeciv/pkg-plist --- freeciv.orig/pkg-plist Mon Sep 4 09:45:28 2006 +++ freeciv/pkg-plist Sat Dec 2 20:30:46 2006 @@ -297,6 +297,23 @@ %%X11%%%%DATADIR%%/isophex/terrain2.spec %%X11%%%%DATADIR%%/isophex/tiles.png %%X11%%%%DATADIR%%/isophex/tiles.spec +%%SOUND%%%%DATADIR%%/stdsounds.soundspec +%%SOUND%%%%DATADIR%%/stdsounds/LrgCan.ogg +%%SOUND%%%%DATADIR%%/stdsounds/LrgExpl.ogg +%%SOUND%%%%DATADIR%%/stdsounds/MedCan.ogg +%%SOUND%%%%DATADIR%%/stdsounds/MgBar1.ogg +%%SOUND%%%%DATADIR%%/stdsounds/MgBar2.ogg +%%SOUND%%%%DATADIR%%/stdsounds/MgHeavy.ogg +%%SOUND%%%%DATADIR%%/stdsounds/Mortar.ogg +%%SOUND%%%%DATADIR%%/stdsounds/SmlExpl.ogg +%%SOUND%%%%DATADIR%%/stdsounds/Splash.ogg +%%SOUND%%%%DATADIR%%/stdsounds/THover.ogg +%%SOUND%%%%DATADIR%%/stdsounds/Tread.ogg +%%SOUND%%%%DATADIR%%/stdsounds/foot3.ogg +%%SOUND%%%%DATADIR%%/stdsounds/inh2o.ogg +%%SOUND%%%%DATADIR%%/stdsounds/metbrk.ogg +%%SOUND%%%%DATADIR%%/stdsounds/wall01.ogg +%%SOUND%%%%DATADIR%%/stdsounds/woodbrk.ogg share/locale/da/LC_MESSAGES/freeciv.mo share/locale/ca/LC_MESSAGES/freeciv.mo share/locale/cs/LC_MESSAGES/freeciv.mo @@ -341,6 +358,7 @@ @dirrmtry share/locale/sk @dirrmtry share/locale/uk/LC_MESSAGES @dirrmtry share/locale/uk +%%SOUND%%@dirrm %%DATADIR%%/stdsounds %%X11%%@dirrm %%DATADIR%%/trident @dirrm %%DATADIR%%/scenario @dirrm %%DATADIR%%/nation >Release-Note: >Audit-Trail: >Unformatted: