From nobody Sat Mar 12 15:23:42 2022 X-Original-To: dev-commits-ports-all@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 113081A26B7D; Sat, 12 Mar 2022 15:23:43 +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 4KG65V6v5yz4Rxk; Sat, 12 Mar 2022 15:23:42 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1647098623; 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=k8ZAtVtJItWS54dAXRCO9/W3eW+c+z7bB6kQO3SMSEg=; b=rLkavvAjz5bwtZzfqtVumo5kpAwLc6warwGnqWJf4ZZz9cf50xEpFEQzDla9ev8Pxqa9NM pjh+bJghyLw4lH+Auqw6AVcerfRVShwiNdQnBChtvuq5xLFL+wyuSst0vdSKXO+DbRQlLN SwktTfDHp3kPBy0vm33EY9S5If9iHyp/7ZRGjeVABR9Pxw0T277YyryRE9n8AZK6bqeAPf V+I8hdslUuB5/QViqf+cU3LEyW8LAIGRo/Hu5QvMM7wZpOq22d8kuafNC+pFyuOQJ+XhWN QyRdDqmbVR+IGyGWmFFTagTQwofC9JZGfr5E7Ni052z7i/Wi3yLwqb69IxmvDw== 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 CCAAE2F24B; Sat, 12 Mar 2022 15:23:42 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 22CFNgSR034001; Sat, 12 Mar 2022 15:23:42 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 22CFNglU034000; Sat, 12 Mar 2022 15:23:42 GMT (envelope-from git) Date: Sat, 12 Mar 2022 15:23:42 GMT Message-Id: <202203121523.22CFNglU034000@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Jan Beich Subject: git: 68e5efff9900 - main - games/veloren: enable evdev-based joystick support List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: jbeich X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 68e5efff9900ab8ee857edf0d38a5bf65d4fcf18 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1647098623; 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=k8ZAtVtJItWS54dAXRCO9/W3eW+c+z7bB6kQO3SMSEg=; b=TSCg40YkmzQfiB1oiibG735fUhcg1aclIirwhFSF09C3A4hBgJ1vMHcshN+fZEbUsRq9VC 2pc6SflpafmSN3cgXBTGYon7rigQ3UNWV0/Q8ib8yC5cKHm3e/BZmc8PK4eBewyE3fiaYA 4Q0HSKxqgY91+us0ziMTm2rS/dMeUMizMOG7lyICak+v5MRi3Rq9jJZ1gSiLu/cg2TWqmK Y/FJIvF4TpDu29h4qC7wR4TzjkgqVDvg2xzO5wAC04VSqwJuz7SgzrF+ZYvRnctEJ/WDT4 W/f28Y70HhfT1O6VoSD/Dp03V/g3dpmc8ki40Qj0hPUfmARzdMtKTcks4IoaQQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1647098623; a=rsa-sha256; cv=none; b=FYHcIMQTAcjqj66cn8sDFRbplLHR+a1r8qyL7EPPt9q0N5xcQoY4eE6XAp4XO0U8aEzRAY kmxs1N4nTYE1EQT6LSsw/ulBN76j8Frsd+eFAankqe16TYKwIY6BHvJ6RGTMkyrzXsS1D2 gXNYZuD/inPMoD/PnFQ/dVlseLdo/MEJP1AVdm3uKwvbOIeBfQhwSZwSCflqipWHOTeSAh y/lTeC+270aZ1CxhYAxJ0KWne/SsKAwu/DFEI0iU1x76eSbgE3TxIQPqjADdlYN1M46SNW ybzQCtTD9wfKyH2gCH1pEZ5Q+1LLqub7xAuXfWsAhZ9nj3hohUZcEakVZpezrA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by jbeich: URL: https://cgit.FreeBSD.org/ports/commit/?id=68e5efff9900ab8ee857edf0d38a5bf65d4fcf18 commit 68e5efff9900ab8ee857edf0d38a5bf65d4fcf18 Author: Jan Beich AuthorDate: 2021-01-23 14:45:51 +0000 Commit: Jan Beich CommitDate: 2022-03-12 15:21:20 +0000 games/veloren: enable evdev-based joystick support WARN veloren_voxygen::window: Controller input is unsupported on this platform. Note, requires hgame(4) on FreeBSD >= 13.0, sysutils/iichid or multimedia/webcamd. --- games/veloren/Makefile | 4 +- games/veloren/files/patch-gilrs-evdev | 81 +++++++++++++++++++++++++++++++++++ 2 files changed, 84 insertions(+), 1 deletion(-) diff --git a/games/veloren/Makefile b/games/veloren/Makefile index d5a013392478..800cab10f4ac 100644 --- a/games/veloren/Makefile +++ b/games/veloren/Makefile @@ -1,6 +1,7 @@ PORTNAME= veloren DISTVERSIONPREFIX= v DISTVERSION= 0.12.0 +PORTREVISION= 1 CATEGORIES= games MASTER_SITES= LOCAL/jbeich @@ -18,7 +19,8 @@ BUILD_DEPENDS= glslang>0:graphics/glslang \ shaderc>0:graphics/shaderc \ spirv-tools>0:graphics/spirv-tools \ libxkbcommon>0:x11/libxkbcommon -LIB_DEPENDS= libasound.so:audio/alsa-lib +LIB_DEPENDS= libasound.so:audio/alsa-lib \ + libudev.so:devel/libudev-devd RUN_DEPENDS= ${LOCALBASE}/lib/alsa-lib/libasound_module_pcm_oss.so:audio/alsa-plugins \ ${LOCALBASE}/lib/libvulkan.so:graphics/vulkan-loader diff --git a/games/veloren/files/patch-gilrs-evdev b/games/veloren/files/patch-gilrs-evdev new file mode 100644 index 000000000000..819316ded7e6 --- /dev/null +++ b/games/veloren/files/patch-gilrs-evdev @@ -0,0 +1,81 @@ +https://gitlab.com/gilrs-project/gilrs/-/merge_requests/56 + +--- cargo-crates/gilrs-0.8.1/src/mapping/mod.rs.orig 1970-01-01 00:00:00 UTC ++++ cargo-crates/gilrs-0.8.1/src/mapping/mod.rs +@@ -24,14 +24,14 @@ use vec_map::VecMap; + use self::parser::{Error as ParserError, ErrorKind as ParserErrorKind, Parser, Token}; + + /// Platform name used by SDL mappings +-#[cfg(target_os = "linux")] ++#[cfg(any(target_os = "linux", target_os = "dragonfly", target_os = "freebsd"))] + const SDL_PLATFORM_NAME: &str = "Linux"; + #[cfg(target_os = "macos")] + const SDL_PLATFORM_NAME: &'static str = "Mac OS X"; + #[cfg(target_os = "windows")] + const SDL_PLATFORM_NAME: &'static str = "Windows"; + #[cfg(all( +- not(target_os = "linux"), ++ not(any(target_os = "linux", target_os = "dragonfly", target_os = "freebsd")), + not(target_os = "macos"), + not(target_os = "windows") + ))] +--- cargo-crates/gilrs-core-0.3.1/Cargo.toml.orig 1970-01-01 00:00:00 UTC ++++ cargo-crates/gilrs-core-0.3.1/Cargo.toml +@@ -54,16 +54,16 @@ optional = true + [target."cfg(target_arch = \"wasm32\")".dev-dependencies.wasm-bindgen-rs] + version = "0.2" + package = "wasm-bindgen" +-[target."cfg(target_os = \"linux\")".dependencies.libc] ++[target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\"))".dependencies.libc] + version = "0.2" + +-[target."cfg(target_os = \"linux\")".dependencies.libudev-sys] ++[target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\"))".dependencies.libudev-sys] + version = "0.1" + +-[target."cfg(target_os = \"linux\")".dependencies.nix] ++[target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\"))".dependencies.nix] + version = "0.20" + +-[target."cfg(target_os = \"linux\")".dependencies.vec_map] ++[target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\"))".dependencies.vec_map] + version = "0.8" + [target."cfg(target_os = \"macos\")".dependencies.core-foundation] + version = "0.6" +--- cargo-crates/gilrs-core-0.3.1/src/platform/linux/ff.rs.orig 1970-01-01 00:00:00 UTC ++++ cargo-crates/gilrs-core-0.3.1/src/platform/linux/ff.rs +@@ -104,10 +104,10 @@ impl Device { + + impl Drop for Device { + fn drop(&mut self) { +- #[cfg(target_pointer_width = "64")] +- let effect = self.effect as u64; +- #[cfg(target_pointer_width = "32")] +- let effect = self.effect as u32; ++ #[cfg(target_os = "linux")] ++ let effect = self.effect as ::libc::c_ulong; ++ #[cfg(not(target_os = "linux"))] ++ let effect = self.effect as ::libc::c_int; + + if let Err(err) = unsafe { ioctl::eviocrmff(self.file.as_raw_fd(), effect) } { + error!( +--- cargo-crates/gilrs-core-0.3.1/src/platform/mod.rs.orig 1970-01-01 00:00:00 UTC ++++ cargo-crates/gilrs-core-0.3.1/src/platform/mod.rs +@@ -21,7 +21,7 @@ + + pub use self::platform::*; + +-#[cfg(target_os = "linux")] ++#[cfg(any(target_os = "linux", target_os = "dragonfly", target_os = "freebsd"))] + #[path = "linux/mod.rs"] + mod platform; + +@@ -38,7 +38,7 @@ mod platform; + mod platform; + + #[cfg(all( +- not(target_os = "linux"), ++ not(any(target_os = "linux", target_os = "dragonfly", target_os = "freebsd")), + not(target_os = "macos"), + not(target_os = "windows"), + not(target_arch = "wasm32")