Subject: [PATCH 1/2] gnu: Add wesnoth-server.

From: Arun Isaac <[email-masked]>
Date: Mon, 22 Jan 2018 00:07:12 +0530

* gnu/packages/games.scm (wesnoth-server): New variable.
---
 gnu/packages/games.scm | 24 +++++++++++++++++++++++-
 1 file changed, 23 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm
index 1213d87a5..5fb4be8e3 100644
--- a/gnu/packages/games.scm
+++ b/gnu/packages/games.scm
@@ -25,7 +25,7 @@
 ;;; Copyright © 2016 Jan Nieuwenhuizen <[email-masked]>
 ;;; Copyright © 2016 Steve Webber <[email-masked]>
 ;;; Copyright © 2017 Adonay "adfeno" Felipe Nogueira <https://libreplanet.org/wiki/User:Adfeno> <[email-masked]>
-;;; Copyright © 2017 Arun Isaac <[email-masked]>
+;;; Copyright © 2017, 2018 Arun Isaac <[email-masked]>
 ;;; Copyright © 2017 Tobias Geerinckx-Rice <[email-masked]>
 ;;; Copyright © 2017 nee <[email-masked]>
 ;;; Copyright © 2017 Clément Lassieur <[email-masked]>
@@ -1801,6 +1801,28 @@ experience and advance levels, and are carried over from one scenario to the
 next campaign.")
     (license license:gpl2+)))
 
+(define-public wesnoth-server
+  (package
+    (inherit wesnoth)
+    (name "wesnoth-server")
+    (inputs
+     `(("boost" ,boost)
+       ("sdl-net" ,sdl-net)))
+    (arguments
+     (append
+      (substitute-keyword-arguments (package-arguments wesnoth)
+        ((#:configure-flags configure-flags)
+         `(append ,configure-flags (list "-DENABLE_GAME=OFF"))))
+      `(#:phases
+        (modify-phases %standard-phases
+          (add-after 'install 'delete-data
+            (lambda* (#:key outputs #:allow-other-keys)
+              (delete-file-recursively (string-append (assoc-ref outputs "out")
+                                                      "/share/wesnoth"))))))))
+    (synopsis "Dedicated Battle for Wesnoth server")
+    (description "This package contains a dedicated server for The Battle for
+Wesnoth.")))
+
 (define-public dosbox
   (package
     (name "dosbox")
-- 
2.15.1