From nobody Thu Aug 03 10:42:12 2023 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4RGllm6wTqzZXF6; Thu, 3 Aug 2023 10:42:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RGllm2M5Bz3Nv3; Thu, 3 Aug 2023 10:42:12 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1691059332; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jrs1H67Ibkgv0jZgb73aFSiOWiqwQ1CwPN76JrgoRxo=; b=mQncaboOzS+n3CHKopE6qFtZ7lqoNdIXaZ7h24mnUHX5rDT26NqFH0ziJGXG7MCAL1SDBS u4ctt8BBxmVKg9johj66W8QVkWoIsW53+qTt3p6uouCaRGOhcbkTtpJHSMcxnn0ARKhveu QZvfYY9j5Bdz4/6LH3FIJ5uS4VytCZodyMZFPTDV2IDw3Jvp73c5MPd8lsxMd1gXkKekAl zwylJLu5PzASA00JAeN85Av1HCdxeyTz93Fpr/Z8HQJQlACkvMEVPxm9mmepQNAzJxqVcM PmyASlB+j8XlNpi415Xm2urZ7vS2289cpqmJ1quqnmwWDuAt6JStno7dyqSR1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1691059332; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=jrs1H67Ibkgv0jZgb73aFSiOWiqwQ1CwPN76JrgoRxo=; b=c2dHswyUPkeCzzjBe0owcmjkOf5Tu+pNwX2q/LgJFT/X3/goE5K7EGaxXBuc35+S/uJAGw OFpDBQnvqBZyIkQeTZ1C6zccxect3HX0Z+5BMQltPzKjyov/JCxQc2UulRPdK3An5D6MXS C2uAR8hk+F7+zqfyeexR+lJrYGkZoe3QfXQrVrISHJOmL6syHghCme4A83/RCzx5lwOD4W rK8dzHe6tNYfBxonUGTe59k0p9yFgMrnzn+QNamgMJBnf+eYDnGqpjkEy/CR9x5cUTGUkS z0R+hM5UErbgkGbNzjl5LNmg5Zgdve2wJPOe0CnzItqkOKyhC1pbSSiDsZuHow== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1691059332; a=rsa-sha256; cv=none; b=fumcfnTZQS7+yHMh+aRT2q+5cEe8QGP+xLSZKCtwxmXCKhz4TRt6V3JUE+t3JMbqQqAhKg qm0EcQPrt7+smst/jMjCB5d9VL+3ZP0fi8fKlVMn7a8Ueflnw6sPHLq7Xl4IMHO/Un2DcR po359PWc18W5WRJKNTzn/pMgR1wCMAi7cbg0qkbW22qvTSOtnP/iTmzVhQrflR5rMfBLbi MXqDi+H6bBChqekrUVilvv3VXZh8kq/bb0PK9crZSw0zclQbvYsgnaE6FdM+6y9Fu6V0Nb Nohjfl4EvZedJUlBL+WjFIEgNnHIVakDZObiffZgSLaQDQKzUGwEXp9cjha1RA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4RGllm154Qz2Nv; Thu, 3 Aug 2023 10:42:12 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 373AgC3j058564; Thu, 3 Aug 2023 10:42:12 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 373AgCII058563; Thu, 3 Aug 2023 10:42:12 GMT (envelope-from git) Date: Thu, 3 Aug 2023 10:42:12 GMT Message-Id: <202308031042.373AgCII058563@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Piotr Kubaj Subject: git: 6483d7e6e5f3 - main - games/oblige: fix build on powerpc* List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: pkubaj X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6483d7e6e5f341dbcc6483d30f353b3fb2dd2c45 Auto-Submitted: auto-generated The branch main has been updated by pkubaj: URL: https://cgit.FreeBSD.org/ports/commit/?id=6483d7e6e5f341dbcc6483d30f353b3fb2dd2c45 commit 6483d7e6e5f341dbcc6483d30f353b3fb2dd2c45 Author: Piotr Kubaj AuthorDate: 2023-08-03 10:39:58 +0000 Commit: Piotr Kubaj CommitDate: 2023-08-03 10:39:58 +0000 games/oblige: fix build on powerpc* gui/sys_endian.h:66:58: error: unsupported inline asm: input with type 'int' matching output with type 'u16_t' (aka 'unsigned short') __asm__("rlwimi %0,%2,8,16,23" : "=&r" (result) : "0" (x >> 8), "r" (x)); ~~~~~~ ^~~~~~ --- games/oblige/Makefile | 3 ++- games/oblige/files/patch-ajpoly__src_pl__endian.h | 14 ++++++++++++++ games/oblige/files/patch-gui_sys__endian.h | 14 ++++++++++++++ 3 files changed, 30 insertions(+), 1 deletion(-) diff --git a/games/oblige/Makefile b/games/oblige/Makefile index d68a02bb80af..7d04609679d7 100644 --- a/games/oblige/Makefile +++ b/games/oblige/Makefile @@ -17,7 +17,8 @@ LIB_DEPENDS= libfltk.so:x11-toolkits/fltk \ libphysfs.so:devel/physfs \ libpng.so:graphics/png -USES= gmake jpeg xorg zip +USES= dos2unix gmake jpeg xorg zip +DOS2UNIX_FILES= ajpoly_src/pl_endian.h gui/sys_endian.h USE_XORG= x11 xcursor xext xfixes xft xinerama xrender WRKSRC= ${WRKDIR}/Oblige-${PORTVERSION}-source diff --git a/games/oblige/files/patch-ajpoly__src_pl__endian.h b/games/oblige/files/patch-ajpoly__src_pl__endian.h new file mode 100644 index 000000000000..c10fb7058fbc --- /dev/null +++ b/games/oblige/files/patch-ajpoly__src_pl__endian.h @@ -0,0 +1,14 @@ +--- ajpoly_src/pl_endian.h.orig 2023-07-31 15:43:19 UTC ++++ ajpoly_src/pl_endian.h +@@ -57,10 +57,7 @@ static inline u16_t UT_Swap16(u16_t x) + #elif defined(__GNUC__) && (defined(__powerpc__) || defined(__ppc__)) + static inline u16_t UT_Swap16(u16_t x) + { +- u16_t result; +- +- __asm__("rlwimi %0,%2,8,16,23" : "=&r" (result) : "0" (x >> 8), "r" (x)); +- return result; ++ return __builtin_bswap16(x); + } + #else + static inline u16_t UT_Swap16(u16_t x) { diff --git a/games/oblige/files/patch-gui_sys__endian.h b/games/oblige/files/patch-gui_sys__endian.h new file mode 100644 index 000000000000..a240f00393e3 --- /dev/null +++ b/games/oblige/files/patch-gui_sys__endian.h @@ -0,0 +1,14 @@ +--- gui/sys_endian.h.orig 2023-07-31 15:43:29 UTC ++++ gui/sys_endian.h +@@ -61,10 +61,7 @@ static inline u16_t UT_Swap16(u16_t x) + #elif defined(__GNUC__) && (defined(__powerpc__) || defined(__ppc__)) + static inline u16_t UT_Swap16(u16_t x) + { +- u16_t result; +- +- __asm__("rlwimi %0,%2,8,16,23" : "=&r" (result) : "0" (x >> 8), "r" (x)); +- return result; ++ return __builtin_bswap16(x); + } + #else + static inline u16_t UT_Swap16(u16_t x) {