From unknown Sat Jun 21 03:24:44 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#59716 <59716@debbugs.gnu.org> To: bug#59716 <59716@debbugs.gnu.org> Subject: Status: [PATCH] Add tes3mp Reply-To: bug#59716 <59716@debbugs.gnu.org> Date: Sat, 21 Jun 2025 10:24:44 +0000 retitle 59716 [PATCH] Add tes3mp reassign 59716 guix-patches submitter 59716 Michal Atlas severity 59716 normal tag 59716 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Wed Nov 30 03:16:01 2022 Received: (at submit) by debbugs.gnu.org; 30 Nov 2022 08:16:01 +0000 Received: from localhost ([127.0.0.1]:59467 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p0IG8-0003Wh-Np for submit@debbugs.gnu.org; Wed, 30 Nov 2022 03:16:01 -0500 Received: from lists.gnu.org ([209.51.188.17]:33494) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p0EqD-0001FM-SY for submit@debbugs.gnu.org; Tue, 29 Nov 2022 23:37:04 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p0EqD-0000gT-Lu for guix-patches@gnu.org; Tue, 29 Nov 2022 23:37:01 -0500 Received: from mout01.posteo.de ([185.67.36.65]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1p0EqA-0005GK-Sb for guix-patches@gnu.org; Tue, 29 Nov 2022 23:37:01 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 568DC240026 for ; Wed, 30 Nov 2022 05:36:55 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1669783015; bh=vteGYpE2Zaq3l3q9UDnTNYNaZIXTxTLN1DUF9UQjl5M=; h=From:To:Cc:Subject:Date:From; b=pARe0fQ/D67v1ljUBNgJYhlfPNW866cGTU/an365DbZ51DU3ZUvpQEAhiTQ1ccq8V udOg+oLWV9aAK26SEiIye6R4fQnRcK4C091TgFb00bmpxMp3iAdHl5lpDWFb9zKSWj qCDuHP39E5mTGMzKcDAjhgDliS3HLOjaq4LbvOw494kt3AzZCqHZsuUMA3f2+aGpvV XQAJE1mFzNLTPioZWGtbBsN6AD7kEwOHkz+p1CeI6xS4XB/PDGmbkiNNwti6J8907B IwzfvttfhXBYD/mb4877gcUEGogRWDbEz0Wy8zWngkNemS7whQFwVydZJMbhYVQKNQ bQezpM91MekeA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NMRHp4ZLLz6tnj; Wed, 30 Nov 2022 05:36:54 +0100 (CET) From: Michal Atlas To: guix-patches@gnu.org Subject: [PATCH] Add tes3mp Date: Wed, 30 Nov 2022 03:59:07 +0000 Message-Id: <20221130035903.30800-1-michal_atlas+git@posteo.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=185.67.36.65; envelope-from=michal_atlas+git@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Wed, 30 Nov 2022 03:16:00 -0500 Cc: Michal Atlas X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) * gnu/packages/game-development.scm (tes3mp-server, tes3mp, tes3mp-corescripts, crabnet): New variables * gnu/packages/game-development.scm (tes3mp-common-arguments): New private variable Hello, here is a patch to add Morrowind Multiplayer packages. I wasn't sure if the client and server should be outputs of one package, or separated, but there were enough differences, so I added them separately. The server setup is also not entirely plug&play so I figured I'd mention that in the description, I'm unsure as to where else to put it, and it should be included, since the original wiki isn't excellent and doesn't talk about the option of running the binary from a different directory than the data is in. Lastly, I'm unsure if the set-default-server-home phase should exist, either the server starts and then kicks a player the moment they are supposed to be saved to disk (since the store isn't writeable), or the server just errors out right away if the default config isn't overriden, neither sounds like a good outcome, I guess we shouldn't include it since it might end up being confusing. Hopefully this patch isn't too bad. Cheers! --- gnu/packages/game-development.scm | 180 ++++++++++++++++++++++++++++++ 1 file changed, 180 insertions(+) diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index 66d0ca316f..8136b22b3e 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -53,6 +53,8 @@ (define-module (gnu packages game-development) #:use-module (guix git-download) #:use-module (guix svn-download) #:use-module (guix utils) + #:use-module (guix build-system) + #:use-module (guix build-system copy) #:use-module (guix build-system cmake) #:use-module (guix build-system gnu) #:use-module (guix build-system python) @@ -66,6 +68,7 @@ (define-module (gnu packages game-development) #:use-module (gnu packages build-tools) #:use-module (gnu packages compression) #:use-module (gnu packages check) + #:use-module (gnu packages commencement) #:use-module (gnu packages curl) #:use-module (gnu packages documentation) #:use-module (gnu packages fltk) @@ -75,6 +78,7 @@ (define-module (gnu packages game-development) #:use-module (gnu packages fribidi) #:use-module (gnu packages dbm) #:use-module (gnu packages gawk) + #:use-module (gnu packages gcc) #:use-module (gnu packages gettext) #:use-module (gnu packages gl) #:use-module (gnu packages glib) @@ -2838,3 +2842,179 @@ (define-public recastnavigation progresses the level, or you may regenerate tiles as the world changes.") (home-page "https://github.com/recastnavigation/recastnavigation") (license license:zlib)))) + +(define-public crabnet + (package + (name "crabnet") + (version "1.001") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/TES3MP/CrabNet") + (commit "19e66190e83f53bcdcbcd6513238ed2e54878a21"))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0l7sqz35jb5m40zqm82wpy1wvdwpjq4h7a5i9yyyk8174j8qk1jq")))) + (build-system cmake-build-system) + (arguments + (list + #:tests? #f)) + (synopsis "CrabNet is a TES3MP specific fork of RakNet") + (description "CrabNet is a cross platform, open source, +C++ networking engine for game programmers") + (home-page "https://github.com/TES3MP/CrabNet") + (license license:bsd-2))) + +(define-public tes3mp-corescripts + (package + (name "tes3mp-corescripts") + (version "0.8.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/TES3MP/CoreScripts") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "01p64494gsqyxx3v2nya5lfj9xyqz3bcviap257x2c0isapx4gzj")))) + (build-system copy-build-system) + (arguments + (list + #:install-plan #~`(("data" "/share/tes3mp/data") + ("lib" "/share/tes3mp/lib") + ("scripts" "/share/tes3mp/scripts")))) + (synopsis "Serverside Lua scripts used to implement core functionality in TES3MP") + (description "These are the scripts used to implement most +of the essential server logic in TES3MP, +including gameplay adjustments for multiplayer +as well as state saving and loading") + (home-page "https://github.com/TES3MP/CoreScripts") + (license license:expat))) + +(define tes3mp-common-arguments + #~(list "-DBUILD_OPENCS=OFF" + "-DBUILD_BSATOOL=OFF" + "-DBUILD_ESMTOOL=OFF" + "-DBUILD_ESSIMPORTER=OFF" + "-DBUILD_LAUNCHER=OFF" + "-DBUILD_MWINIIMPORTER=OFF" + "-DBUILD_MYGUI_PLUGIN=OFF" + "-DBUILD_NIFTEST=OFF" + "-DBUILD_WIZARD=OFF" + (string-append + "-DLuaJit_INCLUDE_DIR=" + #$(file-append + luajit + (string-append "/include/luajit-" + (package-version luajit)))) + (string-append + "-DRakNet_LIBRARY_DEBUG=" + #$(file-append crabnet "/build/lib/libRakNetLibStatic.a")) + "-DOPENMW_USE_SYSTEM_RECASTNAVIGATION=ON")) + +(define-public tes3mp-server + (package + (name "tes3mp-server") + (version "0.8.1") + (propagated-inputs (list tes3mp-corescripts)) + (inputs (list + boost + crabnet + lua-5.1 + luajit + openscenegraph + sdl2 + lz4 + ;; OpenGl and SDL2 are hard dependencies even for the server + ;; unless we do some patching + mesa + recastnavigation)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/TES3MP/TES3MP") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "09gd1zia27fa5phz0xx375y89rdsvf9pgfmw4n38pp108gh6002c")))) + (arguments + (list + #:tests? #f + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'set-default-server-home + (lambda _ + ; This lets the server always at least start up + (substitute* "files/tes3mp/tes3mp-server-default.cfg" + (("home = ./server") + (string-append + "home = " + #$(file-append tes3mp-corescripts "/share/tes3mp"))))))) + #:configure-flags + #~(cons* "-DBUILD_OPENMW_MP=ON" + "-DBUILD_BROWSER=OFF" + "-DBUILD_OPENMW=OFF" + #$tes3mp-common-arguments))) + (build-system (build-system-with-c-toolchain + cmake-build-system `(("toolchain" ,gcc-toolchain-8)))) + (synopsis "Multiplayer for OpenMW, a reimplementation of +The Elder Scrolls 3: Morrowind's engine (Server Package)") + (description "TES3MP is a project adding multiplayer functionality to OpenMW, +an open-source game engine that supports playing +\"The Elder Scrolls III: Morrowind\" by Bethesda Softworks. +To run the server copy /share/tes3mp/ into $XDG_CONFIG_HOME/openmw/ +(must be writeable), +then copy /etc/openmw/tes3mp-server-default.cfg into this new directory +under the name tes3mp-server.cfg. +Set home to the $XDG_CONFIG_HOME/openmw/ directory, now run tes3mp-server and enjoy. +Note that all server data is kept in this directory.") + (home-page "tes3mp.com") + (license license:gpl3))) + +(define-public tes3mp + (package + (name "tes3mp") + (version "0.8.1") + (source (package-source tes3mp-server)) + (build-system cmake-build-system) + (inputs (list + boost + bullet + crabnet + ffmpeg + lz4 + mesa + mygui + openal + openscenegraph + qtbase-5 + recastnavigation + sdl2)) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + ;; The check always fails and reports + ;; version too old + (add-before 'configure 'remove-ffmpeg-version-check + (lambda _ + (substitute* "CMakeLists.txt" + (("NOT FFVER_OK") + "FFVER_OK"))))) + #:tests? #f + #:configure-flags + #~(cons* "-DBUILD_OPENMW_MP=OFF" + "-DBUILD_OPENMW=ON" + "-DBUILD_BROWSER=ON" + #$tes3mp-common-arguments))) + (synopsis "Multiplayer for OpenMW, a reimplementation of +The Elder Scrolls 3: Morrowind's engine (Client Package)") + (description "TES3MP is a project adding multiplayer functionality to OpenMW, +an open-source game engine that supports playing +\"The Elder Scrolls III: Morrowind\" by Bethesda Softworks. +For the setup wizard and general openmw tooling, use the openmw package.") + (home-page "tes3mp.com") + (license license:gpl3))) base-commit: b4be83b6ac7e2139bec5d3eaafcf8af6cbe50856 -- 2.38.1 From debbugs-submit-bounces@debbugs.gnu.org Thu Dec 01 05:31:22 2022 Received: (at 59716) by debbugs.gnu.org; 1 Dec 2022 10:31:22 +0000 Received: from localhost ([127.0.0.1]:38839 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p0gqd-0007Vh-Vi for submit@debbugs.gnu.org; Thu, 01 Dec 2022 05:31:22 -0500 Received: from mout01.posteo.de ([185.67.36.65]:46117) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1p0Y0t-000692-En for 59716@debbugs.gnu.org; Wed, 30 Nov 2022 20:05:21 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 0BBE7240026 for <59716@debbugs.gnu.org>; Thu, 1 Dec 2022 02:05:11 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1669856713; bh=zo2DrUeKcNjekKihrv2UoidlJtpJXDOn0/uGoaFIHmU=; h=From:To:Cc:Subject:Date:From; b=Jn80YVZL/d4CMz3mVf81SkxF5CCQaEchZX24Ka4r4wR4NhQtRDq3sBgqyxOdH8HW3 TIE3Z37w1trzZKMTUktpS8w/Pb1Jyc5FvX5AHw5gDkJbeCokV5eepRArfdUb/oSpZ9 z+1i3LzdMy60gp84V0p7m+Hd7i4vgpC6HhIQEYrSibj9l3RB/l6l6eHmHSqLxmJZbq 42YCSPUDaUQ0iBrPLJlMDpgDCOip90s2D5cuVaiN5lGxkX/0JdFmvbaxFEcQoQV3mA 9tAlFZ3n5ylkvnuuSmxfYi5F18vhQ2lfKKg95QqJIuce+7j8ibyx6E5eSEiX2XnWtJ pHli2Juont+TA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4NMyY33SHBz6tmP; Thu, 1 Dec 2022 02:05:10 +0100 (CET) From: Michal Atlas To: 59716@debbugs.gnu.org Subject: [PATCH] Add tes3mp Date: Wed, 30 Nov 2022 23:31:44 +0000 Message-Id: <20221130233139.13425-1-michal_atlas+git@posteo.net> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 59716 X-Mailman-Approved-At: Thu, 01 Dec 2022 05:31:18 -0500 Cc: Michal Atlas X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) * gnu/packages/game-development.scm (set-openmw-commit-version): New private-variable * gnu/packages/game-development.scm (set-commit-version): New phase in tes3mp and tes3mp-server --- Sorry, I didn't notice that the official release tarball was from tag `tes3mp-0.8.1` and not `0.8.1`. On that note, I forced in version information to be able to connect to standard 0.8.1 server instances from the binary release. They'd refuse connection due to "version mismatch" otherwise. Hardcoding the COMMITHASH is certainly ugly, but the TAGHASH probably needs to be as well anyways, since cmake normally generates it by running `git rev-list --tags --max-count=1` on the repo, which I'm not sure if we want to do or can do in the build itself, this at least ensures that the correct tag is always chosen. Cheers. --- gnu/packages/game-development.scm | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/gnu/packages/game-development.scm b/gnu/packages/game-development.scm index 8136b22b3e..d1de36f93d 100644 --- a/gnu/packages/game-development.scm +++ b/gnu/packages/game-development.scm @@ -2914,6 +2914,16 @@ (define tes3mp-common-arguments #$(file-append crabnet "/build/lib/libRakNetLibStatic.a")) "-DOPENMW_USE_SYSTEM_RECASTNAVIGATION=ON")) +(define set-openmw-commit-version + #~(substitute* "CMakeLists.txt" + ;; Used for version compatibility checks + ;; Commit the project was built with + (("set\\(OPENMW_VERSION_COMMITHASH \"\"\\)") + "set(OPENMW_VERSION_COMMITHASH \"68954091c54d0596037c4fb54d2812313b7582a1\")") + ;; points to 0.8.0 in 0.8.1 Release + (("set\\(OPENMW_VERSION_TAGHASH \"\"\\)") + "set(OPENMW_VERSION_TAGHASH \"000e8724cacaf0176f6220de111ca45098807e78\")"))) + (define-public tes3mp-server (package (name "tes3mp-server") @@ -2935,16 +2945,18 @@ (define-public tes3mp-server (method git-fetch) (uri (git-reference (url "https://github.com/TES3MP/TES3MP") - (commit version))) + (commit (string-append "tes3mp-" version)))) (file-name (git-file-name name version)) (sha256 (base32 - "09gd1zia27fa5phz0xx375y89rdsvf9pgfmw4n38pp108gh6002c")))) + "16k3l2ky0wciy0xaxxm1kvl1z3725l6ikirldiycjhrvrkidbxpk")))) (arguments (list #:tests? #f #:phases #~(modify-phases %standard-phases + (add-before 'configure 'set-commit-version + (lambda _ #$set-openmw-commit-version)) (add-before 'configure 'set-default-server-home (lambda _ ; This lets the server always at least start up @@ -2997,6 +3009,8 @@ (define-public tes3mp (list #:phases #~(modify-phases %standard-phases + (add-before 'configure 'set-commit-version + (lambda _ #$set-openmw-commit-version)) ;; The check always fails and reports ;; version too old (add-before 'configure 'remove-ffmpeg-version-check base-commit: b4be83b6ac7e2139bec5d3eaafcf8af6cbe50856 prerequisite-patch-id: d05b134d12be8b8184cd42f0d7cd435b0718894f -- 2.38.1