Bug 174093

Summary: games/odamex: update to 0.6.1
Product: Ports & Packages Reporter: fiziologus
Component: Individual Port(s)Assignee: Guido Falsi <madpilot>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
file.diff
none
patch.txt none

Description fiziologus 2012-12-03 17:40:00 UTC
[games/odamex] update to 0.6.1

Fix: Patch attached with submission follows:
Comment 1 Max Brazhnikov 2013-01-11 01:33:23 UTC
Hi,

Does this port really need custom install target? New version is based on
cmake, it's very unlikely that it can't install files by itself.

Cheers,
Max
Comment 2 Guido Falsi freebsd_committer freebsd_triage 2013-02-19 21:50:42 UTC
Responsible Changed
From-To: freebsd-ports-bugs->madpilot

I'll take it.
Comment 3 Guido Falsi freebsd_committer freebsd_triage 2013-02-20 21:18:17 UTC
I took this PR and prepared n update to newer version 0.6.2.

I'd like to ask you if there is any strong reason why you have removed 
the MIDI option.

Thanks.

-- 
Guido Falsi <madpilot@FreeBSD.org>
Comment 4 fiziologus 2013-02-23 19:57:34 UTC
no need. odamex used sdl-mixer for midi playpack, no timidity.


2013/2/21 Guido Falsi <madpilot@freebsd.org>

> I took this PR and prepared n update to newer version 0.6.2.
>
> I'd like to ask you if there is any strong reason why you have removed the
> MIDI option.
>
> Thanks.
>
> --
> Guido Falsi <madpilot@FreeBSD.org>
>
Comment 5 dfilter service freebsd_committer freebsd_triage 2013-02-24 17:21:05 UTC
Author: madpilot
Date: Sun Feb 24 17:20:49 2013
New Revision: 312882
URL: http://svnweb.freebsd.org/changeset/ports/312882

Log:
  - Update to 0.6.2
  - Remove unneeded option
  - Trim Makefile headers
  
  PR:		ports/174093
  Submitted by:	Green Dog <fiziologus@gmail.com>

Added:
  head/games/odamex/files/patch-CMakeLists.txt   (contents, props changed)
  head/games/odamex/files/patch-client-src-cl_download.cpp   (contents, props changed)
  head/games/odamex/files/patch-common-d_main.cpp   (contents, props changed)
  head/games/odamex/files/patch-odalaunch-CMakeLists.txt   (contents, props changed)
  head/games/odamex/files/patch-odalaunch-src-dlg_main.cpp   (contents, props changed)
Deleted:
  head/games/odamex/files/patch-Makefile
  head/games/odamex/files/patch-client__src__d_main.cpp
  head/games/odamex/files/patch-odalaunch__Makefile
  head/games/odamex/files/patch-server__src__d_main.cpp
Modified:
  head/games/odamex/Makefile   (contents, props changed)
  head/games/odamex/distinfo   (contents, props changed)
  head/games/odamex/pkg-plist   (contents, props changed)

Modified: head/games/odamex/Makefile
==============================================================================
--- head/games/odamex/Makefile	Sun Feb 24 17:09:12 2013	(r312881)
+++ head/games/odamex/Makefile	Sun Feb 24 17:20:49 2013	(r312882)
@@ -1,12 +1,8 @@
-# New ports collection makefile for:	odamex
-# Date created:				2007-12-06
-# Whom:					alepulver
-#
+# Created by: alepulver
 # $FreeBSD$
-#
 
 PORTNAME=	odamex
-PORTVERSION=	0.5.6
+PORTVERSION=	0.6.2
 CATEGORIES=	games
 MASTER_SITES=	SF/${PORTNAME}/Odamex/${PORTVERSION}
 DISTNAME=	odamex-src-${PORTVERSION}
@@ -15,43 +11,40 @@ MAINTAINER=	ports@FreeBSD.org
 COMMENT=	The Standard in Online Multiplayer Doom
 
 USE_BZIP2=	yes
-USE_GMAKE=	yes
 USE_SDL=	sdl mixer
+USE_CMAKE=	yes
+USE_DOS2UNIX=	CMakeLists.txt odalaunch/CMakeLists.txt common/d_main.cpp
 
-OPTIONS_DEFINE= LAUNCHER MIDI
+OPTIONS_DEFINE=	LAUNCHER
 
 LAUNCHER_DESC=	Enable GUI launcher program
-MIDI_DESC=	Enable MIDI support (timidity)
 
 .include <bsd.port.options.mk>
 
 .if ${PORT_OPTIONS:MLAUNCHER}
 USE_WX=		2.6+
-MAKE_ENV+=	WXRC_CMD="${WXRC_CMD}" WITH_LAUNCHER=yes
+CMAKE_ARGS+=	-DODALAUNCH_TARGET=on -DNO_AG-ODALAUNCH_TARGET=off
 PLIST_SUB+=	LAUNCHER=""
 .else
 PLIST_SUB+=	LAUNCHER="@comment "
-.endif
-
-.if ${PORT_OPTIONS:MMIDI}
-RUN_DEPENDS+=	timidity:${PORTSDIR}/audio/timidity
+CMAKE_ARGS+=	-DODALAUNCH_TARGET=off
 .endif
 
 post-patch:
 	@${REINPLACE_CMD} -e 's|%%DMDIR%%|${DMDIR}|; \
 		s|%%DATADIR%%|${DATADIR}|' \
-		${WRKSRC}/client/src/d_main.cpp \
-		${WRKSRC}/server/src/d_main.cpp
-
-.if ${PORT_OPTIONS:MLAUNCHER}
-	@${REINPLACE_CMD} -e 's|\./odamex|odamex|' \
-		${WRKSRC}/odalaunch/src/misc.cpp
-.endif
+		${WRKSRC}/common/d_main.cpp
+	@${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|' \
+		${WRKSRC}/odalaunch/src/dlg_main.cpp
+	@${REINPLACE_CMD} -e 's|%%WX_VER%%|${WX_VERSION}|' \
+		-e 's|%%LOCALBASE%%|${LOCALBASE}|' \
+		${WRKSRC}/odalaunch/CMakeLists.txt
+	@${REINPLACE_CMD} -e 's|-waddir /usr/share/doom||' \
+		${WRKSRC}/installer/arch/odamex.desktop
 
 do-install:
-.for f in odamex odasrv
-	${INSTALL_PROGRAM} ${WRKSRC}/${f} ${PREFIX}/bin
-.endfor
+	${INSTALL_PROGRAM} ${WRKSRC}/client/odamex ${PREFIX}/bin
+	${INSTALL_PROGRAM} ${WRKSRC}/server/odasrv ${PREFIX}/bin
 .if ${PORT_OPTIONS:MLAUNCHER}
 	${INSTALL_PROGRAM} ${WRKSRC}/odalaunch/odalaunch ${PREFIX}/bin
 .endif
@@ -60,6 +53,20 @@ do-install:
 .if ${PORT_OPTIONS:MDOCS}
 	${MKDIR} ${DOCSDIR}
 	${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/LICENSE ${DOCSDIR}
+.endif
+.for f in odamex odasrv
+	${INSTALL_DATA} ${WRKSRC}/media/icon_${f}_*.png ${PREFIX}/share/pixmaps
+.endfor
+.if ${PORT_OPTIONS:MLAUNCHER}
+	${INSTALL_DATA} ${WRKSRC}/media/icon_odalaunch_*.png ${PREFIX}/share/pixmaps
+.endif
+	${MKDIR} ${PREFIX}/share/applications
+.for f in odamex odasrv
+	${INSTALL_DATA} ${WRKSRC}/installer/arch/${f}.desktop ${PREFIX}/share/applications
+.endfor
+.if ${PORT_OPTIONS:MLAUNCHER}
+	${INSTALL_DATA} ${WRKSRC}/installer/arch/odalaunch.desktop ${PREFIX}/share/applications
 .endif
 
 .include "${.CURDIR}/../doom-data/Makefile.include"

Modified: head/games/odamex/distinfo
==============================================================================
--- head/games/odamex/distinfo	Sun Feb 24 17:09:12 2013	(r312881)
+++ head/games/odamex/distinfo	Sun Feb 24 17:20:49 2013	(r312882)
@@ -1,2 +1,2 @@
-SHA256 (odamex-src-0.5.6.tar.bz2) = fc832ac2df2fceeed79b512cd789d0d30c93c46b246f50af973bb867b02a3440
-SIZE (odamex-src-0.5.6.tar.bz2) = 2954090
+SHA256 (odamex-src-0.6.2.tar.bz2) = 70534ee0b88f759269b807190f347acacc1a0ff4f9e9e90edeab9aa99d4f316e
+SIZE (odamex-src-0.6.2.tar.bz2) = 8451290

Added: head/games/odamex/files/patch-CMakeLists.txt
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/odamex/files/patch-CMakeLists.txt	Sun Feb 24 17:20:49 2013	(r312882)
@@ -0,0 +1,13 @@
+--- CMakeLists.txt.orig	2012-12-03 15:03:21.000000000 +0400
++++ CMakeLists.txt	2012-12-03 15:05:49.000000000 +0400
+@@ -43,7 +43,9 @@
+ add_subdirectory(client)
+ add_subdirectory(server)
+ add_subdirectory(master)
+-add_subdirectory(odalaunch)
++if(ODALAUNCH_TARGET)
++  add_subdirectory(odalaunch)
++endif()
+ 
+ # Disable the ag-odalaunch target completely: -DNO_AG-ODALAUNCH_TARGET
+ # This is only really useful when setting up a universal build.

Added: head/games/odamex/files/patch-client-src-cl_download.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/odamex/files/patch-client-src-cl_download.cpp	Sun Feb 24 17:20:49 2013	(r312882)
@@ -0,0 +1,13 @@
+--- client/src/cl_download.cpp.orig	2012-05-11 03:03:43.000000000 +0200
++++ client/src/cl_download.cpp	2013-02-19 23:05:21.932196566 +0100
+@@ -170,8 +170,8 @@
+ 
+     // Try to save to the wad paths in this order -- Hyper_Eye
+     D_AddSearchDir(dirs, Args.CheckValue("-waddir"), separator);
+-    D_AddSearchDir(dirs, getenv("DOOMWADDIR"), separator);
+-    D_AddSearchDir(dirs, getenv("DOOMWADPATH"), separator);
++    D_AddSearchDir(dirs, "%%DATADIR%%", separator);
++    D_AddSearchDir(dirs, "%%DMDIR%%", separator);
+     D_AddSearchDir(dirs, waddirs.cstring(), separator);
+     dirs.push_back(startdir);
+     dirs.push_back(progdir);

Added: head/games/odamex/files/patch-common-d_main.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/odamex/files/patch-common-d_main.cpp	Sun Feb 24 17:20:49 2013	(r312882)
@@ -0,0 +1,13 @@
+--- common/d_main.cpp.orig	2013-02-20 18:09:33.266196581 +0100
++++ common/d_main.cpp	2013-02-20 18:11:13.271203017 +0100
+@@ -490,8 +490,8 @@
+ 	dirs.push_back(progdir);
+ 
+ 	D_AddSearchDir(dirs, Args.CheckValue("-waddir"), separator);
+-	D_AddSearchDir(dirs, getenv("DOOMWADDIR"), separator);
+-	D_AddSearchDir(dirs, getenv("DOOMWADPATH"), separator);
++	D_AddSearchDir(dirs, "%%DATADIR%%", separator);
++	D_AddSearchDir(dirs, "%%DMDIR%%", separator);
+ 	D_AddSearchDir(dirs, getenv("HOME"), separator);
+ 
+ 	// [AM] Search additional paths based on platform

Added: head/games/odamex/files/patch-odalaunch-CMakeLists.txt
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/odamex/files/patch-odalaunch-CMakeLists.txt	Sun Feb 24 17:20:49 2013	(r312882)
@@ -0,0 +1,10 @@
+--- odalaunch/CMakeLists.txt.orig	2012-12-03 16:15:08.000000000 +0400
++++ odalaunch/CMakeLists.txt	2012-12-03 16:20:04.000000000 +0400
+@@ -30,6 +30,7 @@
+ 
+ # Odalaunch target
+ if(wxWidgets_FOUND)
++  set(wxWidgets_wxrc_EXECUTABLE %%LOCALBASE%%/bin/wxrc-gtk2-%%WX_VER%%)
+   add_custom_command(
+     OUTPUT ${XRCRES_HEADER}
+     COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_CURRENT_BINARY_DIR}/res

Added: head/games/odamex/files/patch-odalaunch-src-dlg_main.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/odamex/files/patch-odalaunch-src-dlg_main.cpp	Sun Feb 24 17:20:49 2013	(r312882)
@@ -0,0 +1,11 @@
+--- odalaunch/src/dlg_main.cpp.orig	2012-05-31 03:49:32.000000000 +0400
++++ odalaunch/src/dlg_main.cpp	2012-12-03 21:21:50.000000000 +0400
+@@ -193,7 +193,7 @@
+     launchercfg_s.get_list_on_start = 1;
+     launchercfg_s.show_blocked_servers = 0;
+     launchercfg_s.wad_paths = wxGetCwd();
+-    launchercfg_s.odamex_directory = wxGetCwd();
++    launchercfg_s.odamex_directory = wxString("%%PREFIX%%/bin");
+ 
+     m_LstCtrlServers = XRCCTRL(*this, "Id_LstCtrlServers", LstOdaServerList);
+     m_LstCtrlPlayers = XRCCTRL(*this, "Id_LstCtrlPlayers", LstOdaPlayerList);

Modified: head/games/odamex/pkg-plist
==============================================================================
--- head/games/odamex/pkg-plist	Sun Feb 24 17:09:12 2013	(r312881)
+++ head/games/odamex/pkg-plist	Sun Feb 24 17:20:49 2013	(r312882)
@@ -1,7 +1,24 @@
 %%LAUNCHER%%bin/odalaunch
+%%LAUNCHER%%share/applications/odalaunch.desktop
+%%LAUNCHER%%share/pixmaps/icon_odalaunch_128.png
+%%LAUNCHER%%share/pixmaps/icon_odalaunch_256.png
+%%LAUNCHER%%share/pixmaps/icon_odalaunch_512.png
+%%LAUNCHER%%share/pixmaps/icon_odalaunch_96.png
 bin/odamex
 bin/odasrv
+share/applications/odamex.desktop
+share/applications/odasrv.desktop
+share/pixmaps/icon_odamex_128.png
+share/pixmaps/icon_odamex_256.png
+share/pixmaps/icon_odamex_512.png
+share/pixmaps/icon_odamex_96.png
+share/pixmaps/icon_odasrv_128.png
+share/pixmaps/icon_odasrv_256.png
+share/pixmaps/icon_odasrv_512.png
+share/pixmaps/icon_odasrv_96.png
 %%DATADIR%%/odamex.wad
+%%PORTDOCS%%%%DOCSDIR%%/LICENSE
 %%PORTDOCS%%%%DOCSDIR%%/README
 @dirrm %%DATADIR%%
 %%PORTDOCS%%@dirrm %%DOCSDIR%%
+@dirrmtry share/applications
_______________________________________________
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 6 Guido Falsi freebsd_committer freebsd_triage 2013-02-24 17:21:14 UTC
State Changed
From-To: open->closed

Committed, with changes.  Thanks!