aboutsummaryrefslogtreecommitdiff
path: root/games
diff options
context:
space:
mode:
authorJan Beich <jbeich@FreeBSD.org>2022-02-21 10:41:17 +0000
committerJan Beich <jbeich@FreeBSD.org>2022-02-21 16:10:14 +0000
commitf3d7b45ee594f0dc110358249c8a2c10018319c0 (patch)
treef2efb9ad7e266685414ce6eda1a1295c61a1d284 /games
parent615703b4b3192ad6e3722889a04f28f631e37e95 (diff)
downloadports-f3d7b45ee594f0dc110358249c8a2c10018319c0.tar.gz
ports-f3d7b45ee594f0dc110358249c8a2c10018319c0.zip
games/fishfight: regen patch from upstream
Diffstat (limited to 'games')
-rw-r--r--games/fishfight/files/patch-miniquad165
1 files changed, 99 insertions, 66 deletions
diff --git a/games/fishfight/files/patch-miniquad b/games/fishfight/files/patch-miniquad
index 435804e18990..1e441e6524cc 100644
--- a/games/fishfight/files/patch-miniquad
+++ b/games/fishfight/files/patch-miniquad
@@ -18,7 +18,7 @@ error[E0428]: the name `GL_TIME_ELAPSED` is defined multiple times
kms = ["sapp-kms"]
log-impl = []
-[target."cfg(not(any(target_os=\"linux\", target_os=\"macos\", target_os=\"android\", target_os=\"ios\", target_arch=\"wasm32\", windows)))".dependencies.sapp-dummy]
-+[target."cfg(not(any(unix, target_arch=\"wasm32\", windows)))".dependencies.sapp-dummy]
++[target."cfg(not(any(target_os=\"linux\", target_os=\"dragonfly\", target_os=\"freebsd\", target_os=\"netbsd\", target_os=\"openbsd\", target_os=\"macos\", target_os=\"android\", target_os=\"ios\", target_arch=\"wasm32\", windows)))".dependencies.sapp-dummy]
version = "=0.1.5"
[target."cfg(target_arch = \"wasm32\")".dependencies.sapp-wasm]
version = "=0.1.26"
@@ -27,128 +27,161 @@ error[E0428]: the name `GL_TIME_ELAPSED` is defined multiple times
[target."cfg(target_os = \"ios\")".dependencies.sapp-ios]
version = "=0.1.2"
-[target."cfg(target_os = \"linux\")".dependencies.sapp-kms]
-+[target."cfg(all(unix, not(any(target_os = \"macos\", target_os = \"ios\", target_os = \"android\"))))".dependencies.sapp-kms]
++[target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"netbsd\", target_os = \"openbsd\"))".dependencies.sapp-kms]
version = "=0.1.1"
optional = true
-[target."cfg(target_os = \"linux\")".dependencies.sapp-linux]
-+[target."cfg(all(unix, not(any(target_os = \"macos\", target_os = \"ios\", target_os = \"android\"))))".dependencies.sapp-linux]
++[target."cfg(any(target_os = \"linux\", target_os = \"dragonfly\", target_os = \"freebsd\", target_os = \"netbsd\", target_os = \"openbsd\"))".dependencies.sapp-linux]
version = "=0.1.13"
optional = true
[target."cfg(target_os = \"macos\")".dependencies.sapp-darwin]
-diff --git cargo-crates/miniquad-0.3.0-alpha.42/src/clipboard.rs cargo-crates/miniquad-0.3.0-alpha.42/src/clipboard.rs
-index 3251b24df2b6..a8561a89aeb9 100644
---- cargo-crates/miniquad-0.3.0-alpha.42/src/clipboard.rs
+--- cargo-crates/miniquad-0.3.0-alpha.42/src/clipboard.rs.orig 1970-01-01 00:00:01 UTC
+++ cargo-crates/miniquad-0.3.0-alpha.42/src/clipboard.rs
-@@ -2,7 +2,7 @@
+@@ -2,7 +2,13 @@
use crate::Context;
-#[cfg(all(target_os = "linux", feature = "sapp-linux"))]
-+#[cfg(all(unix, not(any(target_os = "macos", target_os = "ios", target_os = "android")), feature = "sapp-linux"))]
++#[cfg(all(feature = "sapp-linux", any(
++ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
++)))]
mod linux_x11 {
use crate::Context;
-@@ -53,7 +53,7 @@ mod windows {
+@@ -53,7 +59,13 @@ mod windows {
}
#[cfg(not(any(
- all(target_os = "linux", feature = "sapp-linux"),
-+ all(all(unix, not(target_os = "macos"), not(target_os = "ios"), not(target_os = "android")), feature = "sapp-linux"),
++ all(feature = "sapp-linux", any(
++ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
++ )),
target_os = "windows",
target_arch = "wasm32"
)))]
-@@ -68,12 +68,12 @@ mod dummy {
+@@ -68,12 +80,24 @@ mod dummy {
}
#[cfg(not(any(
- all(target_os = "linux", feature = "sapp-linux"),
-+ all(all(unix, not(target_os = "macos"), not(target_os = "ios"), not(target_os = "android")), feature = "sapp-linux"),
++ all(feature = "sapp-linux"), any(
++ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd"
++ ),
target_os = "windows",
target_arch = "wasm32"
)))]
use dummy as clipboard;
-#[cfg(all(target_os = "linux", feature = "sapp-linux"))]
-+#[cfg(all(all(unix, not(target_os = "macos"), not(target_os = "ios"), not(target_os = "android")), feature = "sapp-linux"))]
++#[cfg(all(feature = "sapp-linux", any(
++ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
++)))]
use linux_x11 as clipboard;
#[cfg(target_arch = "wasm32")]
use wasm as clipboard;
-diff --git cargo-crates/miniquad-0.3.0-alpha.42/src/lib.rs cargo-crates/miniquad-0.3.0-alpha.42/src/lib.rs
-index 4718901dd2d8..f69cb15e13c1 100644
---- cargo-crates/miniquad-0.3.0-alpha.42/src/lib.rs
+--- cargo-crates/miniquad-0.3.0-alpha.42/src/lib.rs.orig 1970-01-01 00:00:01 UTC
+++ cargo-crates/miniquad-0.3.0-alpha.42/src/lib.rs
-@@ -7,19 +7,16 @@ pub use sapp_android;
- #[cfg(target_os = "macos")]
+@@ -8,6 +8,10 @@ pub use sapp_android;
extern crate sapp_darwin as sapp;
#[cfg(not(any(
-- target_os = "linux",
-- target_os = "macos",
-- target_os = "ios",
-- target_os = "android",
-+ unix,
- target_arch = "wasm32",
- windows
- )))]
+ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
+ target_os = "macos",
+ target_os = "ios",
+ target_os = "android",
+@@ -17,9 +21,21 @@ extern crate sapp_darwin as sapp;
extern crate sapp_dummy as sapp;
#[cfg(target_os = "ios")]
extern crate sapp_ios as sapp;
-#[cfg(all(target_os = "linux", feature = "kms"))]
-+#[cfg(all(unix, not(any(target_os = "macos", target_os = "ios", target_os = "android")), feature = "kms"))]
++#[cfg(all(feature = "kms", any(
++ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
++)))]
extern crate sapp_kms as sapp;
-#[cfg(all(target_os = "linux", not(feature = "kms")))]
-+#[cfg(all(unix, not(any(target_os = "macos", target_os = "ios", target_os = "android")), not(feature = "kms")))]
++#[cfg(all(not(feature = "kms"), any(
++ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
++)))]
extern crate sapp_linux as sapp;
#[cfg(target_arch = "wasm32")]
-@@ -140,7 +137,7 @@ impl Context {
+@@ -139,7 +155,13 @@ impl Context {
pub fn set_mouse_cursor(&self, _cursor_icon: CursorIcon) {
#[cfg(any(
target_arch = "wasm32",
- all(target_os = "linux", not(feature = "kms")),
-+ all(unix, not(any(target_os = "macos", target_os = "ios", target_os = "android")), not(feature = "kms")),
++ all(not(feature = "kms"), any(
++ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
++ )),
windows,
))]
unsafe {
-@@ -164,12 +161,9 @@ impl Context {
- /// Set the application's window size.
- #[allow(unused_variables)]
+@@ -165,6 +187,10 @@ impl Context {
pub fn set_window_size(&self, new_width: u32, new_height: u32) {
-- #[cfg(not(any(
-- target_os = "linux",
-- target_os = "macos",
-- target_os = "ios",
-- target_os = "android",
-- )))]
-+ #[cfg(not(
-+ unix,
-+ ))]
- unsafe {
- if sapp::sapp_is_fullscreen() {
- #[cfg(feature = "log-impl")]
-@@ -183,10 +177,7 @@ impl Context {
- #[allow(unused_variables)]
+ #[cfg(not(any(
+ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
+ target_os = "macos",
+ target_os = "ios",
+ target_os = "android",
+@@ -184,6 +210,10 @@ impl Context {
pub fn set_fullscreen(&self, fullscreen: bool) {
#[cfg(not(any(
-- target_os = "linux",
-- target_os = "macos",
-- target_os = "ios",
-- target_os = "android",
-+ unix,
- )))]
- unsafe {
- sapp::sapp_set_fullscreen(fullscreen);
+ target_os = "linux",
++ target_os = "dragonfly",
++ target_os = "freebsd",
++ target_os = "netbsd",
++ target_os = "openbsd",
+ target_os = "macos",
+ target_os = "ios",
+ target_os = "android",
--- cargo-crates/sapp-linux-0.1.13/build.rs.orig 1970-01-01 00:00:00 UTC
+++ cargo-crates/sapp-linux-0.1.13/build.rs
-@@ -1,12 +1,6 @@
- use std::env;
-
+@@ -3,7 +3,12 @@ use std::env;
fn main() {
-- let target = env::var("TARGET").unwrap_or_else(|e| panic!("{}", e));
--
+ let target = env::var("TARGET").unwrap_or_else(|e| panic!("{}", e));
+
- if target.contains("linux") == false {
-- panic!("sapp_linux support only linux target");
-- }
--
- println!("cargo:rustc-link-lib=dylib=GL");
- println!("cargo:rustc-link-lib=dylib=X11");
- println!("cargo:rustc-link-lib=dylib=Xi");
++ if target.contains("linux") == false
++ && target.contains("dragonfly") == false
++ && target.contains("freebsd") == false
++ && target.contains("netbsd") == false
++ && target.contains("openbsd") == false
++ {
+ panic!("sapp_linux support only linux target");
+ }
+