Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Jun 2018 21:29:21 +0000 (UTC)
From:      Dmitry Marakasov <amdmi3@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r473081 - in head/games/linwarrior: . files
Message-ID:  <201806222129.w5MLTLmQ007328@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: amdmi3
Date: Fri Jun 22 21:29:21 2018
New Revision: 473081
URL: https://svnweb.freebsd.org/changeset/ports/473081

Log:
  - Fix build with clang 6
  - Pet portlint
  - Regenerate patches

Added:
  head/games/linwarrior/files/patch-source_cController.cpp   (contents, props changed)
Modified:
  head/games/linwarrior/Makefile
  head/games/linwarrior/files/patch-Makefile

Modified: head/games/linwarrior/Makefile
==============================================================================
--- head/games/linwarrior/Makefile	Fri Jun 22 21:28:52 2018	(r473080)
+++ head/games/linwarrior/Makefile	Fri Jun 22 21:29:21 2018	(r473081)
@@ -16,6 +16,8 @@ USES=		gmake openal:al,alut
 USE_GL=		gl glu
 USE_SDL=	sdl
 
+CFLAGS+=	-Wno-c++11-narrowing
+
 WRKSRC=		${WRKDIR}/${PORTNAME}
 
 PLIST_FILES=	bin/${PORTNAME}
@@ -29,8 +31,8 @@ DESKTOP_ENTRIES="LinWarrior 3D" \
 		false
 
 post-extract:
-	@${FIND} ${WRKSRC} -type d -exec chmod a+rx {} \;
-	@${FIND} ${WRKSRC} -type f -exec chmod a+r {} \;
+	@${FIND} ${WRKSRC} -type d -exec ${CHMOD} a+rx {} \;
+	@${FIND} ${WRKSRC} -type f -exec ${CHMOD} a+r {} \;
 
 post-patch:
 	@${REINPLACE_CMD} -e '/hash_set/ d' ${WRKSRC}/source/cAlert.h

Modified: head/games/linwarrior/files/patch-Makefile
==============================================================================
--- head/games/linwarrior/files/patch-Makefile	Fri Jun 22 21:28:52 2018	(r473080)
+++ head/games/linwarrior/files/patch-Makefile	Fri Jun 22 21:29:21 2018	(r473081)
@@ -1,5 +1,5 @@
---- Makefile.orig	2010-02-05 22:50:30.000000000 +0300
-+++ Makefile	2010-04-04 06:18:24.000000000 +0400
+--- Makefile.orig	2010-02-05 19:50:30 UTC
++++ Makefile
 @@ -2,7 +2,7 @@
  # Makefile with auto-dependency generation
  
@@ -9,7 +9,7 @@
  
  # Automatic searching for source files.
  # Objects to compile are all sources (cpp) and put the .o below build-dir.
-@@ -20,18 +20,17 @@
+@@ -20,18 +20,17 @@ ifneq (,$(findstring Win,$(OS)))
  	LIMITER=$(dir \file)
  	CFLAGS+= -static-libgcc
  else
@@ -30,7 +30,7 @@
  
  # Print warnings when compiling.
  CFLAGS += -Wall
-@@ -40,7 +39,6 @@
+@@ -40,7 +39,6 @@ CFLAGS += -Wall
  CFLAGS += $(INCLUDES)
  
  # Optimizations.

Added: head/games/linwarrior/files/patch-source_cController.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/games/linwarrior/files/patch-source_cController.cpp	Fri Jun 22 21:29:21 2018	(r473081)
@@ -0,0 +1,22 @@
+--- source/cController.cpp.orig	2018-06-22 20:39:57 UTC
++++ source/cController.cpp
+@@ -182,16 +182,16 @@ void cController::attackEnemy() {
+     
+     cObject* target = cWorld::instance->mIndex[entity];
+     if (mDevice->inTargetRange() < 0.01) {
+-        mDevice->do_aimFor(NULL);
++        mDevice->do_aimFor(0);
+         pop();
+         return;
+     }
+     if (target == NULL) { // Target disappeared
+-        mDevice->do_aimFor(NULL);
++        mDevice->do_aimFor(0);
+         pop();
+         return;
+     } else if (target->hasRole(DEAD)) {
+-        mDevice->do_aimFor(NULL);
++        mDevice->do_aimFor(0);
+         pop();
+         return;
+     }



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