From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id UP1VDMBDz2ZKCAAA62LTzQ:P1 (envelope-from ) for ; Wed, 28 Aug 2024 15:35:28 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1.migadu.com with LMTPS id UP1VDMBDz2ZKCAAA62LTzQ (envelope-from ) for ; Wed, 28 Aug 2024 17:35:28 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=ogIzNmyq; dkim=fail ("headers rsa verify failed") header.d=disroot.org header.s=mail header.b=VgFQ7xXU; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gnu.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1724859328; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=/qJYa6NYlvbVNZYe0W/vZZ32NzVsQaHHHg1MwBDTE1c=; b=WfjCXu7L/DPHQs0Glrqsz8VsEUht0acef3v5UcEd/UpqdsifGdrc7QBpZnz2ZuTaGmFApS pc7vUYTdfGuFDpWQmwVZzmzEGtMx7OmBfTnGHKc6DRpD2Z+3oecImHme/UnqB2Q/JxeGKZ OMCilMuaPJ4P9inGT1mrI/AuokxZNXMUmWTl2w5FO3PJp80uTzmwqQPAbeZBQaE1Ax1AoM zINNy3Gmf6vz1Ytv15LimRHToardtWolA6PQx2nOX31DNC0TW7X0uiYgqlD+mgk2joQN7B XwgSvc7fx9rkrNJEQJPHmjq2Py/fTQ3mVJ8yxW/Um8eneESvm3hHGXSRcq+KVQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=debbugs.gnu.org header.s=debbugs-gnu-org header.b=ogIzNmyq; dkim=fail ("headers rsa verify failed") header.d=disroot.org header.s=mail header.b=VgFQ7xXU; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gnu.org ARC-Seal: i=1; s=key1; d=yhetil.org; t=1724859328; a=rsa-sha256; cv=none; b=KyBfaHJ3S6uG3uHKhDy2SAlNpPh79jBWV0vUKkccKioCoP8N80bypSHrtGCn0N3YAYIcZD Qm+gZLpMx/CT8AnP0ev/2yUDjta7ISO+lsusH3r1Ji+vAHvhbb8ONwmQkF0A7/SRsAuR0J 0p848PojEZcDX4i9rPiZjBG2XPDC9GcvLyeCxZRfP+yZ6uNV7LtYZhun89c0h27RjZZrij mN7MGqG28Qc37j1JzxUQKJ42NxnNzddEE5OUw8u2ZPHqHluyar9Vz6uJj/TLk/YbFEvsdp t4YkPFkpngcYKj73BoX5J1YW0Qb9qhWirRoZmu9ZG/acbtkWPkdBIjONEILuWA== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 0183C7E62D for ; Wed, 28 Aug 2024 17:35:28 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sjKhV-0000xv-Ck; Wed, 28 Aug 2024 11:35:13 -0400 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 1sjKhR-0000cx-5N for guix-patches@gnu.org; Wed, 28 Aug 2024 11:35:09 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sjKhQ-0006Vs-QR for guix-patches@gnu.org; Wed, 28 Aug 2024 11:35:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=From:MIME-Version:Date:To:In-Reply-To:References:Subject; bh=/qJYa6NYlvbVNZYe0W/vZZ32NzVsQaHHHg1MwBDTE1c=; b=ogIzNmyqJO+j57yykA2faYXWrBMqARHaStnqWaoTjdJsli4o+Msn65LQ1JLzS2c8uFY5m+xhEKfagCvO0/62fTiS/15lY0FLmEtcuaPmMW/4ZuqkG26JArALmmJu+hrm/Wg+lKr0+3gygZw9xAHzaSrW8kbjPjXtmGnWkYD6/roCO6tfGpW7PMxSvcPQDw6/772KHNdDqF1PJxuBhpR8kaEVBHUriqKXuAC8RKblzNZNxjs73rFFAa/XUPkQuxTAGSgDgSvTkSsZsP0lB4TbW35TRk6yIUb78K6dgmMxGjEjnOQYUP+kpYw2V5eXzM24u2OvEXLmePJ+2R9IUtJ6AQ==; Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sjKiI-000888-EW for guix-patches@gnu.org; Wed, 28 Aug 2024 11:36:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#72569] [PATCH v2 3/4] gnu: openclonk: Fix build. References: <59b04394-4737-6da3-cf9e-3f181431afa8@disroot.org> In-Reply-To: <59b04394-4737-6da3-cf9e-3f181431afa8@disroot.org> Resent-From: Adam Faiz Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Wed, 28 Aug 2024 15:36:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 72569 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 72569@debbugs.gnu.org Cc: Liliana Marie Prikler Received: via spool by 72569-submit@debbugs.gnu.org id=B72569.172485934131217 (code B ref 72569); Wed, 28 Aug 2024 15:36:02 +0000 Received: (at 72569) by debbugs.gnu.org; 28 Aug 2024 15:35:41 +0000 Received: from localhost ([127.0.0.1]:49574 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sjKhw-00087Q-W5 for submit@debbugs.gnu.org; Wed, 28 Aug 2024 11:35:41 -0400 Received: from layka.disroot.org ([178.21.23.139]:50068) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sjKhs-00087F-Ff for 72569@debbugs.gnu.org; Wed, 28 Aug 2024 11:35:40 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id EAE91419FB; Wed, 28 Aug 2024 17:34:40 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from layka.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id c_Bewu6LF1Da; Wed, 28 Aug 2024 17:34:39 +0200 (CEST) Message-ID: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1724859279; bh=3/sXsheWo1eVmMxwxrujEGUtbwX2cej+qVCCeVJd1Js=; h=Date:To:Cc:From:Subject; b=VgFQ7xXU/7f6RQBy0DKTUibp/rk3SGtKUbw1nsbmu6DDoBUGay3NJePn0lLvvGiDb O3NwcIanYNQXBr1haAAqHkWjSyvuLtvFaqU1Q+DTZRJZDiq1Kt9qI9iNXXWNA5r83a KKK+TkA3IiEp+YHaHIWFuSy5BGjrVGfE0ziIJQMup8kSmwFAs2jaO02dDyA2wR9sNc vtGY6ZuM5PGVHCzS4a4Kv+9qHZ4wTXCjpQC4e0ag2swjg8KgAONhZoArVlchE7rHzd AvBhZLi9vTkZaC2QNU8io0juO01fYsAhcAbZoU6NxqFA0ICf22J4NhLBnFDf0+lB+B upfv3qmKCbN+Q== Date: Wed, 28 Aug 2024 23:34:09 +0800 MIME-Version: 1.0 Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Adam Faiz X-ACL-Warn: , Adam Faiz via Guix-patches From: Adam Faiz via Guix-patches via Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Spam-Score: -6.98 X-Migadu-Queue-Id: 0183C7E62D X-Migadu-Scanner: mx10.migadu.com X-Migadu-Spam-Score: -6.98 X-TUID: LenSR619RHLi >From 499630a22aebe8921f317733143e257b09f08be3 Mon Sep 17 00:00:00 2001 Message-ID: <499630a22aebe8921f317733143e257b09f08be3.1724859175.git.adam.faiz@disroot.org> In-Reply-To: <91bf9bff2c3c365d006a0e88024db50f416cd436.1724859175.git.adam.faiz@disroot.org> References: <91bf9bff2c3c365d006a0e88024db50f416cd436.1724859175.git.adam.faiz@disroot.org> From: AwesomeAdam54321 Date: Sun, 11 Aug 2024 09:25:30 +0800 Subject: [PATCH v2 3/4] gnu: openclonk: Fix build. * gnu/packages/games.scm (openclonk): Fix build. [source]: Unbundle dependencies and include the header where necessary to fix the build. [arguments]<#:phases>: Remove workarounds for bundled backward-cpp. [inputs]: Remove dependencies for bundled backward-cpp. Add libb2, pcg-cpp, and c-template-sort. --- gnu/packages/games.scm | 62 ++++++++++++++++++++++-------------------- 1 file changed, 33 insertions(+), 29 deletions(-) diff --git a/gnu/packages/games.scm b/gnu/packages/games.scm index 9ad6eabad2..850d40e66f 100644 --- a/gnu/packages/games.scm +++ b/gnu/packages/games.scm @@ -123,6 +123,7 @@ (define-module (gnu packages games) #:use-module (gnu packages bash) #:use-module (gnu packages bison) #:use-module (gnu packages boost) + #:use-module (gnu packages c) #:use-module (gnu packages check) #:use-module (gnu packages cmake) #:use-module (gnu packages compression) @@ -9622,7 +9623,32 @@ (define-public openclonk "openclonk-" version "-src.tar.bz2")) (sha256 (base32 - "0imkqjp8lww5p0cnqf4k4mb2v682mnsas63qmiz17rspakr7fxik")))) + "0imkqjp8lww5p0cnqf4k4mb2v682mnsas63qmiz17rspakr7fxik")) + (modules '((guix build utils))) + (snippet + #~(begin + (delete-file-recursively "thirdparty") + (substitute* "CMakeLists.txt" + (("add_subdirectory\\(thirdparty/.*\\)") "") + (("set_property\\(.*Third-party.*\\)") "") + (("blake2") "b2") + (("thirdparty/timsort/sort\\.h") "") + (("thirdparty/pcg/.*\\.hpp") "")) + (substitute* '("src/lib/C4Random.cpp" + "src/landscape/C4Particles.h") + (("#include ") + "#include ")) + (substitute* "src/script/C4ScriptLibraries.cpp" + (("blake2b.hash_output.get.., raw_output_length, data, data_length, nullptr, 0.") + "blake2b(hash_output.get(), (const void*)raw_output_length, data, data_length, (size_t)(0), 0)")) + (substitute* '("src/script/C4AulParse.cpp" + "src/editor/C4EditCursor.cpp" + "src/gui/C4ScriptGuiWindow.cpp") + (("#include .C4Include\\.h." all) + (string-append "#include \n" all))) + (substitute* "src/lib/StdMesh.cpp" + (("#include .timsort/sort\\.h.") + "#include ")))))) (build-system cmake-build-system) (arguments `(#:configure-flags '("-DAudio_TK=OpenAL") @@ -9641,30 +9667,7 @@ (define-public openclonk (("PATH_SUFFIXES \"src\" \"gtest\"") "PATH_SUFFIXES \"src\"")) #t)) - (add-after 'unpack 'adjust-backward-cpp-includes - (lambda _ - ;; XXX: The bundled backward-cpp exports a CMake "interface" - ;; that includes external libraries such as libdl from glibc. - ;; By default, CMake interface includes are treated as "system - ;; headers", and GCC behaves poorly when glibc is passed as a - ;; system header (causing #include_next failures). - - ;; Here we prevent targets that consume the Backward::Backward - ;; interface from treating it as "system includes". - (substitute* "CMakeLists.txt" - (("target_link_libraries\\((.+) Backward::Backward\\)" all target) - (string-append "set_property(TARGET " target " PROPERTY " - "NO_SYSTEM_FROM_IMPORTED true)\n" - all))) - #t)) - (add-after 'unpack 'add-libiberty - ;; Build fails upon linking executables without this. - (lambda _ - (substitute* "thirdparty/backward-cpp/BackwardConfig.cmake" - (("set\\(LIBBFD_LIBRARIES (.*?)\\)" _ libraries) - (string-append "set(LIBBFD_LIBRARIES " libraries " iberty)"))) - #t)) - (add-after 'add-libiberty 'lax-freealut-requirement + (add-after 'prepare-gmock 'lax-freealut-requirement ;; TODO: We provide freealut 1.1.0, but pkg-config somehow detects ;; it as 1.0.1. Force minimal version. (lambda _ @@ -9686,10 +9689,11 @@ (define-public openclonk ("googletest" ,googletest) ("pkg-config" ,pkg-config))) (inputs - `(("freealut" ,freealut) + `(("c-template-sort" ,c-template-sort) + ("freealut" ,freealut) ("freetype" ,freetype) ("glew" ,glew) - ("libiberty" ,libiberty) + ("libb2" ,libb2) ("libjpeg" ,libjpeg-turbo) ("libogg" ,libogg) ("libpng" ,libpng) @@ -9698,11 +9702,11 @@ (define-public openclonk ("mesa" ,mesa) ("miniupnpc" ,miniupnpc) ("openal" ,openal) + ("pcg-cpp" ,pcg-cpp) ("qtbase" ,qtbase-5) ("readline" ,readline) ("sdl" ,sdl2) - ("tinyxml" ,tinyxml) - ("zlib" ,zlib))) + ("tinyxml" ,tinyxml))) (home-page "https://www.openclonk.org/") (synopsis "Multiplayer action game where you control small and nimble humanoids") -- 2.41.0