Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] New package: gimx-8.0
@ 2020-11-07  0:36 amak79
  2020-11-07  0:46 ` [PR REVIEW] " ericonr
                   ` (42 more replies)
  0 siblings, 43 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  0:36 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 301 bytes --]

There is a new pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 8293 bytes --]

From 2edaebd605a3bf7958251785bb8225cc9f3e875a Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 ++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-data               |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx-libs               |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 80 +++++++++++++++++++++++++++++++++
 7 files changed, 172 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-data
 create mode 120000 srcpkgs/gimx-firmware
 create mode 120000 srcpkgs/gimx-libs
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index cba355c3bfa..55ce325c5b0 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3993,3 +3993,21 @@ libSeExpr2Editor.so.3 seexpr-krita-3.4.4.0_1
 libSeExpr2.so.3 seexpr-krita-3.4.4.0_1
 liburing.so.1 liburing-0.7_1
 libbson-1.0.so.0 libbson-1.17.0_1
+libgimxconfigeditor.so gimx-libs-8.0_1
+libgimxconfigupdater.so gimx-libs-8.0_1
+libgimxcontroller.so gimx-libs-8.0_1
+libgimxdownloader.so gimx-libs-8.0_1
+libgimxfile.so gimx-libs-8.0_1
+libgimxgpp.so gimx-libs-8.0_1
+libgimxhid.so gimx-libs-8.0_1
+libgimxinput.so gimx-libs-8.0_1
+libgimxlog.so gimx-libs-8.0_1
+libgimxpoll.so gimx-libs-8.0_1
+libgimxprio.so gimx-libs-8.0_1
+libgimxserial.so gimx-libs-8.0_1
+libgimxtimer.so gimx-libs-8.0_1
+libgimxtime.so gimx-libs-8.0_1
+libgimxudp.so gimx-libs-8.0_1
+libgimxuhid.so gimx-libs-8.0_1
+libgimxupdater.so gimx-libs-8.0_1
+libgimxusb.so gimx-libs-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-data b/srcpkgs/gimx-data
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-data
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-libs b/srcpkgs/gimx-libs
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-libs
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 00000000000..3f8ff7551c9
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 00000000000..b2ebfb38712
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,80 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli-${version}_${revision} gimx-firmware-${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a computer as a hub for your gaming devices"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CPPFLAGS+=" -Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_extract() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	depends="gimx-data-${version}_${revision} gimx-libs-${version}_${revision}"
+	short_desc+=" - cli tools"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+	}
+}
+
+gimx-data_package() {
+	short_desc+=" - common files"
+
+	pkg_install() {
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}
+
+gimx-libs_package() {
+	short_desc+=" - runtime libraries"
+	shlib_provides="libgimxconfigeditor.so libgimxconfigupdater.so libgimxcontroller.so
+	 libgimxdownloader.so libgimxfile.so libgimxgpp.so libgimxhid.so libgimxinput.so
+	 libgimxlog.so libgimxpoll.so libgimxprio.so libgimxserial.so libgimxtimer.so
+	 libgimxtime.so libgimxudp.so libgimxuhid.so libgimxupdater.so libgimxusb.so"
+
+	pkg_install() {
+		vmove "usr/lib/*.so"
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
@ 2020-11-07  0:46 ` ericonr
  2020-11-07  0:46 ` ericonr
                   ` (41 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2020-11-07  0:46 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 164 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519070187

Comment:
Do you have a PR?

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
  2020-11-07  0:46 ` [PR REVIEW] " ericonr
@ 2020-11-07  0:46 ` ericonr
  2020-11-07  0:46 ` ericonr
                   ` (40 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2020-11-07  0:46 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 203 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519070503

Comment:
I'd ask upstream for an option in the makefile for this.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
  2020-11-07  0:46 ` [PR REVIEW] " ericonr
  2020-11-07  0:46 ` ericonr
@ 2020-11-07  0:46 ` ericonr
  2020-11-07  0:47 ` ericonr
                   ` (39 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2020-11-07  0:46 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 280 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519070395

Comment:
Did this work? `CPPFLAGS` are for the preprocessor, not for the compilers themselves.

Also, you should just set it, not add to it.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (2 preceding siblings ...)
  2020-11-07  0:46 ` ericonr
@ 2020-11-07  0:47 ` ericonr
  2020-11-07  0:47 ` ericonr
                   ` (38 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2020-11-07  0:47 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 206 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519070265

Comment:
This isn't the best desc, I can't really tell what it does.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (3 preceding siblings ...)
  2020-11-07  0:47 ` ericonr
@ 2020-11-07  0:47 ` ericonr
  2020-11-07  0:47 ` ericonr
                   ` (37 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2020-11-07  0:47 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 185 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519070672

Comment:
This should be detected automatically.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (4 preceding siblings ...)
  2020-11-07  0:47 ` ericonr
@ 2020-11-07  0:47 ` ericonr
  2020-11-07  2:24 ` amak79
                   ` (36 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2020-11-07  0:47 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 185 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519070637

Comment:
I don't think it needs to be split up.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (5 preceding siblings ...)
  2020-11-07  0:47 ` ericonr
@ 2020-11-07  2:24 ` amak79
  2020-11-07  2:24 ` amak79
                   ` (35 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  2:24 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 187 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083501

Comment:
No I emailed the patch. I could try a PR.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (6 preceding siblings ...)
  2020-11-07  2:24 ` amak79
@ 2020-11-07  2:24 ` amak79
  2020-11-07  2:25 ` amak79
                   ` (34 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  2:24 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 205 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083533

Comment:
That should be `CXXFLAGS` but it does work with `CPPFLAGS`.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (7 preceding siblings ...)
  2020-11-07  2:24 ` amak79
@ 2020-11-07  2:25 ` amak79
  2020-11-07  2:25 ` amak79
                   ` (33 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  2:25 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 418 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083566

Comment:
I could, but I doubt any changes will be made. I asked the author about `ncursesw6-config` support and the response I got was that the "build system is archaic, it does not allow detecting library versions", and that my "only option is to manually edit the core/Makefile".

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (8 preceding siblings ...)
  2020-11-07  2:25 ` amak79
@ 2020-11-07  2:25 ` amak79
  2020-11-07  2:25 ` amak79
                   ` (32 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  2:25 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 395 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083594

Comment:
I checked the locale files and both the gui and cli tools make use of it. I want to have a the gui and cli tools separate, so I thought I needed to split it. Since the gimx base pkg depends on gimx-cli, should it be part of the gimx-cli sub package?

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (9 preceding siblings ...)
  2020-11-07  2:25 ` amak79
@ 2020-11-07  2:25 ` amak79
  2020-11-07  2:26 ` amak79
                   ` (31 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  2:25 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 331 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083636

Comment:
I was getting "SONAME: libgimx*.so <-> UNKNOWN PKG PLEASE FIX!" errors from `xbps-src` even though the libs were added to `common/shlibs`. Removing `shlib_provides` appears to work now.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (10 preceding siblings ...)
  2020-11-07  2:25 ` amak79
@ 2020-11-07  2:26 ` amak79
  2020-11-07  2:28 ` amak79
                   ` (30 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  2:26 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 244 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083708

Comment:
I agree. I just took the description from the homepage. I will come up with some more descriptive.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (11 preceding siblings ...)
  2020-11-07  2:26 ` amak79
@ 2020-11-07  2:28 ` amak79
  2020-11-07  3:09 ` amak79
                   ` (29 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  2:28 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 249 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083708

Comment:
I agree. I just took the description from the homepage. I will come up with something more descriptive.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (12 preceding siblings ...)
  2020-11-07  2:28 ` amak79
@ 2020-11-07  3:09 ` amak79
  2020-11-07  3:18 ` amak79
                   ` (28 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  3:09 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 326 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519087587

Comment:
Actually after removing `shlib_provides` I'm getting:
```Inconsistent shlibs:
  libgimxconfigeditor.so (provided by: gimx-libs; used by: gimx)
```
Not sure how to resolve that.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (13 preceding siblings ...)
  2020-11-07  3:09 ` amak79
@ 2020-11-07  3:18 ` amak79
  2020-11-07  4:06 ` amak79
                   ` (27 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  3:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 328 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519087587

Comment:
Actually after removing `shlib_provides` I'm getting:
```
Inconsistent shlibs:
  libgimxconfigeditor.so (provided by: gimx-libs; used by: gimx)
```
Not sure how to resolve that.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (14 preceding siblings ...)
  2020-11-07  3:18 ` amak79
@ 2020-11-07  4:06 ` amak79
  2020-11-07  6:06 ` amak79
                   ` (26 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  4:06 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 395 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083594

Comment:
I checked the locale files and both the gui and cli tools make use of them. I want to have the gui and cli tools separate, so I thought I needed to split it. Since the gimx base pkg depends on gimx-cli, should it be part of the gimx-cli sub package?

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (15 preceding siblings ...)
  2020-11-07  4:06 ` amak79
@ 2020-11-07  6:06 ` amak79
  2020-11-07  7:56 ` [PR PATCH] [Updated] " amak79
                   ` (25 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  6:06 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 299 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519121151

Comment:
There were `hostdir/binpkgs/gimx/*-stagedata` files that I have never seen before. I just wiped `hostdir/binpkgs/gimx/` and that seems to have solved it.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (16 preceding siblings ...)
  2020-11-07  6:06 ` amak79
@ 2020-11-07  7:56 ` amak79
  2020-11-07  9:04 ` [PR REVIEW] " amak79
                   ` (24 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  7:56 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7987 bytes --]

From 02bd8cfdb431087d2ca9cac7c037143d2ce79251 Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 ++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-data               |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx-libs               |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 ++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 76 +++++++++++++++++++++++++++++++++
 7 files changed, 168 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-data
 create mode 120000 srcpkgs/gimx-firmware
 create mode 120000 srcpkgs/gimx-libs
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index cba355c3bfa..55ce325c5b0 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3993,3 +3993,21 @@ libSeExpr2Editor.so.3 seexpr-krita-3.4.4.0_1
 libSeExpr2.so.3 seexpr-krita-3.4.4.0_1
 liburing.so.1 liburing-0.7_1
 libbson-1.0.so.0 libbson-1.17.0_1
+libgimxconfigeditor.so gimx-libs-8.0_1
+libgimxconfigupdater.so gimx-libs-8.0_1
+libgimxcontroller.so gimx-libs-8.0_1
+libgimxdownloader.so gimx-libs-8.0_1
+libgimxfile.so gimx-libs-8.0_1
+libgimxgpp.so gimx-libs-8.0_1
+libgimxhid.so gimx-libs-8.0_1
+libgimxinput.so gimx-libs-8.0_1
+libgimxlog.so gimx-libs-8.0_1
+libgimxpoll.so gimx-libs-8.0_1
+libgimxprio.so gimx-libs-8.0_1
+libgimxserial.so gimx-libs-8.0_1
+libgimxtimer.so gimx-libs-8.0_1
+libgimxtime.so gimx-libs-8.0_1
+libgimxudp.so gimx-libs-8.0_1
+libgimxuhid.so gimx-libs-8.0_1
+libgimxupdater.so gimx-libs-8.0_1
+libgimxusb.so gimx-libs-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-data b/srcpkgs/gimx-data
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-data
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-libs b/srcpkgs/gimx-libs
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-libs
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 00000000000..3f8ff7551c9
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 00000000000..60ef126a20b
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,76 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli-${version}_${revision} gimx-firmware-${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a game console with a mouse and keyboard by emulating a controller"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS=" -Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_extract() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	depends="gimx-data-${version}_${revision} gimx-libs-${version}_${revision}"
+	short_desc+=" - cli tools"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+	}
+}
+
+gimx-data_package() {
+	short_desc+=" - common files"
+
+	pkg_install() {
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}
+
+gimx-libs_package() {
+	short_desc+=" - runtime libraries"
+
+	pkg_install() {
+		vmove "usr/lib/*.so"
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (17 preceding siblings ...)
  2020-11-07  7:56 ` [PR PATCH] [Updated] " amak79
@ 2020-11-07  9:04 ` amak79
  2020-11-08  0:23 ` [PR PATCH] [Updated] " amak79
                   ` (23 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-07  9:04 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 287 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519155553

Comment:
I suppose that libs shouldn't be split either, and just put both libs and data into the gimx-cli sub package. The libs are only used by gimx.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (18 preceding siblings ...)
  2020-11-07  9:04 ` [PR REVIEW] " amak79
@ 2020-11-08  0:23 ` amak79
  2020-11-08  0:32 ` amak79
                   ` (22 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-08  0:23 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7717 bytes --]

From 715510a058a582182aedeb15f1b455ee09291484 Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-data               |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx-libs               |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 61 ++++++++++++++++++++++++++++
 7 files changed, 153 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-data
 create mode 120000 srcpkgs/gimx-firmware
 create mode 120000 srcpkgs/gimx-libs
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index cba355c3bfa..2439d4a17ab 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3993,3 +3993,21 @@ libSeExpr2Editor.so.3 seexpr-krita-3.4.4.0_1
 libSeExpr2.so.3 seexpr-krita-3.4.4.0_1
 liburing.so.1 liburing-0.7_1
 libbson-1.0.so.0 libbson-1.17.0_1
+libgimxconfigeditor.so gimx-cli-8.0_1
+libgimxconfigupdater.so gimx-cli-8.0_1
+libgimxcontroller.so gimx-cli-8.0_1
+libgimxdownloader.so gimx-cli-8.0_1
+libgimxfile.so gimx-cli-8.0_1
+libgimxgpp.so gimx-cli-8.0_1
+libgimxhid.so gimx-cli-8.0_1
+libgimxinput.so gimx-cli-8.0_1
+libgimxlog.so gimx-cli-8.0_1
+libgimxpoll.so gimx-cli-8.0_1
+libgimxprio.so gimx-cli-8.0_1
+libgimxserial.so gimx-cli-8.0_1
+libgimxtimer.so gimx-cli-8.0_1
+libgimxtime.so gimx-cli-8.0_1
+libgimxudp.so gimx-cli-8.0_1
+libgimxuhid.so gimx-cli-8.0_1
+libgimxupdater.so gimx-cli-8.0_1
+libgimxusb.so gimx-cli-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-data b/srcpkgs/gimx-data
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-data
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-libs b/srcpkgs/gimx-libs
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-libs
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 00000000000..3f8ff7551c9
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 00000000000..6edcfb1478e
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,61 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli-${version}_${revision} gimx-firmware-${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a game console with a mouse and keyboard by emulating a controller"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS=" -Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_extract() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	short_desc+=" - cli tools"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+		vmove "usr/lib/*.so"
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (19 preceding siblings ...)
  2020-11-08  0:23 ` [PR PATCH] [Updated] " amak79
@ 2020-11-08  0:32 ` amak79
  2020-11-08  3:01 ` [PR REVIEW] " amak79
                   ` (21 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-08  0:32 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7183 bytes --]

From 2a739ff4909c085fc635c4bcaec13e71ae3167eb Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 61 ++++++++++++++++++++++++++++
 5 files changed, 151 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-firmware
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index cba355c3bfa..2439d4a17ab 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3993,3 +3993,21 @@ libSeExpr2Editor.so.3 seexpr-krita-3.4.4.0_1
 libSeExpr2.so.3 seexpr-krita-3.4.4.0_1
 liburing.so.1 liburing-0.7_1
 libbson-1.0.so.0 libbson-1.17.0_1
+libgimxconfigeditor.so gimx-cli-8.0_1
+libgimxconfigupdater.so gimx-cli-8.0_1
+libgimxcontroller.so gimx-cli-8.0_1
+libgimxdownloader.so gimx-cli-8.0_1
+libgimxfile.so gimx-cli-8.0_1
+libgimxgpp.so gimx-cli-8.0_1
+libgimxhid.so gimx-cli-8.0_1
+libgimxinput.so gimx-cli-8.0_1
+libgimxlog.so gimx-cli-8.0_1
+libgimxpoll.so gimx-cli-8.0_1
+libgimxprio.so gimx-cli-8.0_1
+libgimxserial.so gimx-cli-8.0_1
+libgimxtimer.so gimx-cli-8.0_1
+libgimxtime.so gimx-cli-8.0_1
+libgimxudp.so gimx-cli-8.0_1
+libgimxuhid.so gimx-cli-8.0_1
+libgimxupdater.so gimx-cli-8.0_1
+libgimxusb.so gimx-cli-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 00000000000..3f8ff7551c9
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 00000000000..6edcfb1478e
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,61 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli-${version}_${revision} gimx-firmware-${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a game console with a mouse and keyboard by emulating a controller"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS=" -Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_extract() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	short_desc+=" - cli tools"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+		vmove "usr/lib/*.so"
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (20 preceding siblings ...)
  2020-11-08  0:32 ` amak79
@ 2020-11-08  3:01 ` amak79
  2020-11-08  4:20 ` [PR PATCH] [Updated] " amak79
                   ` (20 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-08  3:01 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 169 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r519083501

Comment:
No I emailed the patch.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (21 preceding siblings ...)
  2020-11-08  3:01 ` [PR REVIEW] " amak79
@ 2020-11-08  4:20 ` amak79
  2020-11-08  4:48 ` amak79
                   ` (19 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-08  4:20 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7514 bytes --]

From 33f0cc508fb1c6082afadca6dab44a443d6b1745 Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 65 ++++++++++++++++++++++++++++++
 5 files changed, 155 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-firmware
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index cba355c3bfa..2439d4a17ab 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3993,3 +3993,21 @@ libSeExpr2Editor.so.3 seexpr-krita-3.4.4.0_1
 libSeExpr2.so.3 seexpr-krita-3.4.4.0_1
 liburing.so.1 liburing-0.7_1
 libbson-1.0.so.0 libbson-1.17.0_1
+libgimxconfigeditor.so gimx-cli-8.0_1
+libgimxconfigupdater.so gimx-cli-8.0_1
+libgimxcontroller.so gimx-cli-8.0_1
+libgimxdownloader.so gimx-cli-8.0_1
+libgimxfile.so gimx-cli-8.0_1
+libgimxgpp.so gimx-cli-8.0_1
+libgimxhid.so gimx-cli-8.0_1
+libgimxinput.so gimx-cli-8.0_1
+libgimxlog.so gimx-cli-8.0_1
+libgimxpoll.so gimx-cli-8.0_1
+libgimxprio.so gimx-cli-8.0_1
+libgimxserial.so gimx-cli-8.0_1
+libgimxtimer.so gimx-cli-8.0_1
+libgimxtime.so gimx-cli-8.0_1
+libgimxudp.so gimx-cli-8.0_1
+libgimxuhid.so gimx-cli-8.0_1
+libgimxupdater.so gimx-cli-8.0_1
+libgimxusb.so gimx-cli-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 00000000000..3f8ff7551c9
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 00000000000..c7df563a4f1
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,65 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli-${version}_${revision} gimx-firmware-${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a game console with a mouse and keyboard by emulating a controller"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS=" -Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_extract() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	short_desc+=" - cli tools"
+	shlib_provides="libgimxconfigeditor.so libgimxconfigupdater.so libgimxcontroller.so
+	 libgimxdownloader.so libgimxfile.so libgimxgpp.so libgimxhid.so libgimxinput.so
+	 libgimxlog.so libgimxpoll.so libgimxprio.so libgimxserial.so libgimxtimer.so
+	 libgimxtime.so libgimxudp.so libgimxuhid.so libgimxupdater.so libgimxusb.so"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+		vmove "usr/lib/*.so"
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (22 preceding siblings ...)
  2020-11-08  4:20 ` [PR PATCH] [Updated] " amak79
@ 2020-11-08  4:48 ` amak79
  2020-11-11  4:50 ` [PR REVIEW] " amak79
                   ` (18 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-08  4:48 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7491 bytes --]

From a34d47fbe54fd8b33bddccb25011b17761cad4f2 Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 65 ++++++++++++++++++++++++++++++
 5 files changed, 155 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-firmware
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index cba355c3bfa..2439d4a17ab 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3993,3 +3993,21 @@ libSeExpr2Editor.so.3 seexpr-krita-3.4.4.0_1
 libSeExpr2.so.3 seexpr-krita-3.4.4.0_1
 liburing.so.1 liburing-0.7_1
 libbson-1.0.so.0 libbson-1.17.0_1
+libgimxconfigeditor.so gimx-cli-8.0_1
+libgimxconfigupdater.so gimx-cli-8.0_1
+libgimxcontroller.so gimx-cli-8.0_1
+libgimxdownloader.so gimx-cli-8.0_1
+libgimxfile.so gimx-cli-8.0_1
+libgimxgpp.so gimx-cli-8.0_1
+libgimxhid.so gimx-cli-8.0_1
+libgimxinput.so gimx-cli-8.0_1
+libgimxlog.so gimx-cli-8.0_1
+libgimxpoll.so gimx-cli-8.0_1
+libgimxprio.so gimx-cli-8.0_1
+libgimxserial.so gimx-cli-8.0_1
+libgimxtimer.so gimx-cli-8.0_1
+libgimxtime.so gimx-cli-8.0_1
+libgimxudp.so gimx-cli-8.0_1
+libgimxuhid.so gimx-cli-8.0_1
+libgimxupdater.so gimx-cli-8.0_1
+libgimxusb.so gimx-cli-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 00000000000..3f8ff7551c9
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 00000000000..496522d4bfb
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,65 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli-${version}_${revision} gimx-firmware-${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a computer as a hub for your gaming devices"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS=" -Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_extract() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	short_desc+=" - cli tools"
+	shlib_provides="libgimxconfigeditor.so libgimxconfigupdater.so libgimxcontroller.so
+	 libgimxdownloader.so libgimxfile.so libgimxgpp.so libgimxhid.so libgimxinput.so
+	 libgimxlog.so libgimxpoll.so libgimxprio.so libgimxserial.so libgimxtimer.so
+	 libgimxtime.so libgimxudp.so libgimxuhid.so libgimxupdater.so libgimxusb.so"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+		vmove "usr/lib/*.so"
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (23 preceding siblings ...)
  2020-11-08  4:48 ` amak79
@ 2020-11-11  4:50 ` amak79
  2020-11-11  4:55 ` amak79
                   ` (17 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-11  4:50 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 328 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r521111957

Comment:
I had to re-add `shlib_provides`. Without it the pkg fails to install with "gimx-8.0_1: broken, unresolvable shlib 'libgimx*.so'" errors, even with the libs added to `common/shlibs`.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (24 preceding siblings ...)
  2020-11-11  4:50 ` [PR REVIEW] " amak79
@ 2020-11-11  4:55 ` amak79
  2021-01-19  1:49 ` [PR PATCH] [Updated] " amak79
                   ` (16 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2020-11-11  4:55 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 321 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r521113080

Comment:
I changed the description but it was too specific. It's difficult to describe what this software does in 71 characters or less. I reverted to the upstream description for now.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (25 preceding siblings ...)
  2020-11-11  4:55 ` amak79
@ 2021-01-19  1:49 ` amak79
  2021-04-06  1:04 ` amak79
                   ` (15 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-01-19  1:49 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7505 bytes --]

From 01f94bf4b7642e0e36d2ec31444a02ac97fc6d35 Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 65 ++++++++++++++++++++++++++++++
 5 files changed, 155 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-firmware
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index e0601851d65..30b4cddc927 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4045,3 +4045,21 @@ libutil-cmdline-samba4.so samba-libs-4.13.2_1
 libwinbind-client-samba4.so samba-libs-4.13.2_1
 libsixel.so.1 libsixel-1.8.6_1
 libpamtest.so.0 pam_wrapper-1.1.3_1
+libgimxconfigeditor.so gimx-cli-8.0_1
+libgimxconfigupdater.so gimx-cli-8.0_1
+libgimxcontroller.so gimx-cli-8.0_1
+libgimxdownloader.so gimx-cli-8.0_1
+libgimxfile.so gimx-cli-8.0_1
+libgimxgpp.so gimx-cli-8.0_1
+libgimxhid.so gimx-cli-8.0_1
+libgimxinput.so gimx-cli-8.0_1
+libgimxlog.so gimx-cli-8.0_1
+libgimxpoll.so gimx-cli-8.0_1
+libgimxprio.so gimx-cli-8.0_1
+libgimxserial.so gimx-cli-8.0_1
+libgimxtimer.so gimx-cli-8.0_1
+libgimxtime.so gimx-cli-8.0_1
+libgimxudp.so gimx-cli-8.0_1
+libgimxuhid.so gimx-cli-8.0_1
+libgimxupdater.so gimx-cli-8.0_1
+libgimxusb.so gimx-cli-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 00000000000..31428075254
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 00000000000..3f8ff7551c9
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 00000000000..496522d4bfb
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,65 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli-${version}_${revision} gimx-firmware-${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a computer as a hub for your gaming devices"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS=" -Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_extract() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	short_desc+=" - cli tools"
+	shlib_provides="libgimxconfigeditor.so libgimxconfigupdater.so libgimxcontroller.so
+	 libgimxdownloader.so libgimxfile.so libgimxgpp.so libgimxhid.so libgimxinput.so
+	 libgimxlog.so libgimxpoll.so libgimxprio.so libgimxserial.so libgimxtimer.so
+	 libgimxtime.so libgimxudp.so libgimxuhid.so libgimxupdater.so libgimxusb.so"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+		vmove "usr/lib/*.so"
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (26 preceding siblings ...)
  2021-01-19  1:49 ` [PR PATCH] [Updated] " amak79
@ 2021-04-06  1:04 ` amak79
  2021-04-06 11:49 ` [PR REVIEW] " ericonr
                   ` (14 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-04-06  1:04 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7487 bytes --]

From e454350725896cc9977911a73a3592b05c9cefba Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 65 ++++++++++++++++++++++++++++++
 5 files changed, 155 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-firmware
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index 9aa0a601250b..bf2426864c40 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3967,3 +3967,21 @@ libmd.so.0 libmd-1.0.3_1
 libldacBT_abr.so.2 ldacBT-2.0.2.3_1
 libldacBT_enc.so.2 ldacBT-2.0.2.3_1
 libgumbo.so.1 gumbo-parser-0.10.1_2
+libgimxconfigeditor.so gimx-cli-8.0_1
+libgimxconfigupdater.so gimx-cli-8.0_1
+libgimxcontroller.so gimx-cli-8.0_1
+libgimxdownloader.so gimx-cli-8.0_1
+libgimxfile.so gimx-cli-8.0_1
+libgimxgpp.so gimx-cli-8.0_1
+libgimxhid.so gimx-cli-8.0_1
+libgimxinput.so gimx-cli-8.0_1
+libgimxlog.so gimx-cli-8.0_1
+libgimxpoll.so gimx-cli-8.0_1
+libgimxprio.so gimx-cli-8.0_1
+libgimxserial.so gimx-cli-8.0_1
+libgimxtimer.so gimx-cli-8.0_1
+libgimxtime.so gimx-cli-8.0_1
+libgimxudp.so gimx-cli-8.0_1
+libgimxuhid.so gimx-cli-8.0_1
+libgimxupdater.so gimx-cli-8.0_1
+libgimxusb.so gimx-cli-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 000000000000..314280752548
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 000000000000..314280752548
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 000000000000..3f8ff7551c96
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 000000000000..496522d4bfb6
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,65 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli-${version}_${revision} gimx-firmware-${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a computer as a hub for your gaming devices"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS=" -Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_extract() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	short_desc+=" - cli tools"
+	shlib_provides="libgimxconfigeditor.so libgimxconfigupdater.so libgimxcontroller.so
+	 libgimxdownloader.so libgimxfile.so libgimxgpp.so libgimxhid.so libgimxinput.so
+	 libgimxlog.so libgimxpoll.so libgimxprio.so libgimxserial.so libgimxtimer.so
+	 libgimxtime.so libgimxudp.so libgimxuhid.so libgimxupdater.so libgimxusb.so"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+		vmove "usr/lib/*.so"
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (29 preceding siblings ...)
  2021-04-06 11:49 ` ericonr
@ 2021-04-06 11:49 ` ericonr
  2021-04-06 12:33 ` [PR PATCH] [Updated] " amak79
                   ` (11 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2021-04-06 11:49 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 204 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r607778064

Comment:
I think using post_patch is preferred for changing files.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (28 preceding siblings ...)
  2021-04-06 11:49 ` [PR REVIEW] " ericonr
@ 2021-04-06 11:49 ` ericonr
  2021-04-06 11:49 ` ericonr
                   ` (12 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2021-04-06 11:49 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 266 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r607777787

Comment:
There's something wonky making this necessary, because it really shouldn't be. I'd like to look into it before merging.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (27 preceding siblings ...)
  2021-04-06  1:04 ` amak79
@ 2021-04-06 11:49 ` ericonr
  2021-04-06 11:49 ` ericonr
                   ` (13 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: ericonr @ 2021-04-06 11:49 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 246 bytes --]

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r607778434

Comment:
```suggestion
depends="gimx-cli>=${version}_${revision} gimx-firmware>=${version}_${revision}
```

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (30 preceding siblings ...)
  2021-04-06 11:49 ` ericonr
@ 2021-04-06 12:33 ` amak79
  2021-05-10  4:02 ` [PR REVIEW] " amak79
                   ` (10 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-04-06 12:33 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7486 bytes --]

From 0a5472d44d979648fb93c31117edd11b87b1bb16 Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-cli                |  1 +
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 65 ++++++++++++++++++++++++++++++
 5 files changed, 155 insertions(+)
 create mode 120000 srcpkgs/gimx-cli
 create mode 120000 srcpkgs/gimx-firmware
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index 9aa0a601250b..bf2426864c40 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3967,3 +3967,21 @@ libmd.so.0 libmd-1.0.3_1
 libldacBT_abr.so.2 ldacBT-2.0.2.3_1
 libldacBT_enc.so.2 ldacBT-2.0.2.3_1
 libgumbo.so.1 gumbo-parser-0.10.1_2
+libgimxconfigeditor.so gimx-cli-8.0_1
+libgimxconfigupdater.so gimx-cli-8.0_1
+libgimxcontroller.so gimx-cli-8.0_1
+libgimxdownloader.so gimx-cli-8.0_1
+libgimxfile.so gimx-cli-8.0_1
+libgimxgpp.so gimx-cli-8.0_1
+libgimxhid.so gimx-cli-8.0_1
+libgimxinput.so gimx-cli-8.0_1
+libgimxlog.so gimx-cli-8.0_1
+libgimxpoll.so gimx-cli-8.0_1
+libgimxprio.so gimx-cli-8.0_1
+libgimxserial.so gimx-cli-8.0_1
+libgimxtimer.so gimx-cli-8.0_1
+libgimxtime.so gimx-cli-8.0_1
+libgimxudp.so gimx-cli-8.0_1
+libgimxuhid.so gimx-cli-8.0_1
+libgimxupdater.so gimx-cli-8.0_1
+libgimxusb.so gimx-cli-8.0_1
diff --git a/srcpkgs/gimx-cli b/srcpkgs/gimx-cli
new file mode 120000
index 000000000000..314280752548
--- /dev/null
+++ b/srcpkgs/gimx-cli
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 000000000000..314280752548
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 000000000000..3f8ff7551c96
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 000000000000..a95a6785c343
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,65 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+depends="gimx-cli>=${version}_${revision} gimx-firmware>=${version}_${revision}
+ avrdude xdg-utils xterm"
+short_desc="Use a computer as a hub for your gaming devices"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS="-Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_patch() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-cli_package() {
+	short_desc+=" - cli tools"
+	shlib_provides="libgimxconfigeditor.so libgimxconfigupdater.so libgimxcontroller.so
+	 libgimxdownloader.so libgimxfile.so libgimxgpp.so libgimxhid.so libgimxinput.so
+	 libgimxlog.so libgimxpoll.so libgimxprio.so libgimxserial.so libgimxtimer.so
+	 libgimxtime.so libgimxudp.so libgimxuhid.so libgimxupdater.so libgimxusb.so"
+
+	pkg_install() {
+		for bin in bdaddr ds4tool gimx hcirevision sixaddr ; do
+			vmove "usr/bin/${bin}"
+		done
+		vmove "usr/lib/*.so"
+		vmove usr/share/locale
+	}
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (31 preceding siblings ...)
  2021-04-06 12:33 ` [PR PATCH] [Updated] " amak79
@ 2021-05-10  4:02 ` amak79
  2021-05-10  4:20 ` amak79
                   ` (9 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-05-10  4:02 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1252 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r629035587

Comment:
With `shlib_provides` removed I get the following when installing the `gimx` package.
```
# xbps-install gimx
gimx-8.0_1: broken, unresolvable shlib `libgimxconfigeditor.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxconfigupdater.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxcontroller.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxfile.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxgpp.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxhid.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxinput.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxpoll.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxserial.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxtime.so'
gimx-8.0_1: broken, unresolvable shlib `libgimxupdater.so'
Transaction aborted due to unresolved shlibs.
```
I don't get this error when installing the `gimx-cli` package. Could it be caused by the way I have split the package? I move all the shared libraries into the `gimx-cli` package, even those that aren't needed by `gimx-cli`. I figured that was ok since `gimx` has a depend on `gimx-cli`.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (32 preceding siblings ...)
  2021-05-10  4:02 ` [PR REVIEW] " amak79
@ 2021-05-10  4:20 ` amak79
  2021-05-10  6:37 ` amak79
                   ` (8 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-05-10  4:20 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1675 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r629039349

Comment:
Many ignored runtime deps for `gimx-cli`.
```
=> gimx-cli-8.0_1: running pre-pkg hook: 04-generate-runtime-deps ...
   SONAME: libstdc++.so.6 <-> libstdc++>=4.4.0_1
   SONAME: libcurl.so.4 <-> libcurl>=7.75.0_2
   SONAME: libgimxfile.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgcc_s.so.1 <-> libgcc>=4.4.0_1
   SONAME: libc.so.6 <-> glibc>=2.32_1
   SONAME: libgimxlog.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxdownloader.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxhid.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libusb-1.0.so.0 <-> libusb>=1.0.0_1
   SONAME: libxml2.so.2 <-> libxml2>=2.7.0_1
   SONAME: libm.so.6 <-> glibc>=2.32_1
   SONAME: libgimxinput.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxtimer.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxpoll.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxcontroller.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxuhid.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libXi.so.6 <-> libXi>=1.2.1_1
   SONAME: libX11.so.6 <-> libX11>=1.2_1
   SONAME: libgimxusb.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libbluetooth.so.3 <-> libbluetooth>=4.58_1
   SONAME: libgimxgpp.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxtime.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxprio.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxserial.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxudp.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libncursesw.so.6 <-> ncurses-libs>=5.8_1
   SONAME: libmhash.so.2 <-> mhash>=0.9.9.9_1
```

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (33 preceding siblings ...)
  2021-05-10  4:20 ` amak79
@ 2021-05-10  6:37 ` amak79
  2021-05-10  7:20 ` amak79
                   ` (7 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-05-10  6:37 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1705 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r629039349

Comment:
Many ignored runtime deps for `gimx-cli` with `shlib_provides` removed.
```
=> gimx-cli-8.0_1: running pre-pkg hook: 04-generate-runtime-deps ...
   SONAME: libstdc++.so.6 <-> libstdc++>=4.4.0_1
   SONAME: libcurl.so.4 <-> libcurl>=7.75.0_2
   SONAME: libgimxfile.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgcc_s.so.1 <-> libgcc>=4.4.0_1
   SONAME: libc.so.6 <-> glibc>=2.32_1
   SONAME: libgimxlog.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxdownloader.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxhid.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libusb-1.0.so.0 <-> libusb>=1.0.0_1
   SONAME: libxml2.so.2 <-> libxml2>=2.7.0_1
   SONAME: libm.so.6 <-> glibc>=2.32_1
   SONAME: libgimxinput.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxtimer.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxpoll.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxcontroller.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxuhid.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libXi.so.6 <-> libXi>=1.2.1_1
   SONAME: libX11.so.6 <-> libX11>=1.2_1
   SONAME: libgimxusb.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libbluetooth.so.3 <-> libbluetooth>=4.58_1
   SONAME: libgimxgpp.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxtime.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxprio.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxserial.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxudp.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libncursesw.so.6 <-> ncurses-libs>=5.8_1
   SONAME: libmhash.so.2 <-> mhash>=0.9.9.9_1
```

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (34 preceding siblings ...)
  2021-05-10  6:37 ` amak79
@ 2021-05-10  7:20 ` amak79
  2021-05-11  6:20 ` [PR PATCH] [Updated] " amak79
                   ` (6 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-05-10  7:20 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1705 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r629039349

Comment:
Many ignored runtime deps for `gimx-cli` with `shlib_provides` removed.
```
=> gimx-cli-8.0_1: running pre-pkg hook: 04-generate-runtime-deps ...
   SONAME: libstdc++.so.6 <-> libstdc++>=4.4.0_1
   SONAME: libcurl.so.4 <-> libcurl>=7.75.0_2
   SONAME: libgimxfile.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgcc_s.so.1 <-> libgcc>=4.4.0_1
   SONAME: libc.so.6 <-> glibc>=2.32_1
   SONAME: libgimxlog.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxdownloader.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxhid.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libusb-1.0.so.0 <-> libusb>=1.0.0_1
   SONAME: libxml2.so.2 <-> libxml2>=2.7.0_1
   SONAME: libm.so.6 <-> glibc>=2.32_1
   SONAME: libgimxinput.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxtimer.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxpoll.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxcontroller.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxuhid.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libXi.so.6 <-> libXi>=1.2.1_1
   SONAME: libX11.so.6 <-> libX11>=1.2_1
   SONAME: libgimxusb.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libbluetooth.so.3 <-> libbluetooth>=4.58_1
   SONAME: libgimxgpp.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxtime.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxprio.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxserial.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libgimxudp.so <-> gimx-cli-8.0_1 (ignored)
   SONAME: libncursesw.so.6 <-> ncurses-libs>=5.8_1
   SONAME: libmhash.so.2 <-> mhash>=0.9.9.9_1
```

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (35 preceding siblings ...)
  2021-05-10  7:20 ` amak79
@ 2021-05-11  6:20 ` amak79
  2021-05-11  6:33 ` amak79
                   ` (5 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-05-11  6:20 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7431 bytes --]

From af90b844fe2baa4290cc3c4ac9a87f118766be07 Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx-gui                |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 65 ++++++++++++++++++++++++++++++
 5 files changed, 155 insertions(+)
 create mode 120000 srcpkgs/gimx-firmware
 create mode 120000 srcpkgs/gimx-gui
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index b12756eb9130..c1c24a439860 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3990,3 +3990,21 @@ libbasu.so.0 basu-0.2.0_1
 libXcomp.so.3 nx-libs-3.5.99.24_1
 libXcompshad.so.3 nx-libs-3.5.99.24_1
 libNX_X11.so.6 nx-libs-3.5.99.24_1
+libgimxconfigeditor.so gimx-8.0_1
+libgimxconfigupdater.so gimx-8.0_1
+libgimxcontroller.so gimx-8.0_1
+libgimxdownloader.so gimx-8.0_1
+libgimxfile.so gimx-8.0_1
+libgimxgpp.so gimx-8.0_1
+libgimxhid.so gimx-8.0_1
+libgimxinput.so gimx-8.0_1
+libgimxlog.so gimx-8.0_1
+libgimxpoll.so gimx-8.0_1
+libgimxprio.so gimx-8.0_1
+libgimxserial.so gimx-8.0_1
+libgimxtimer.so gimx-8.0_1
+libgimxtime.so gimx-8.0_1
+libgimxudp.so gimx-8.0_1
+libgimxuhid.so gimx-8.0_1
+libgimxupdater.so gimx-8.0_1
+libgimxusb.so gimx-8.0_1
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 000000000000..314280752548
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-gui b/srcpkgs/gimx-gui
new file mode 120000
index 000000000000..314280752548
--- /dev/null
+++ b/srcpkgs/gimx-gui
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 000000000000..3f8ff7551c96
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 000000000000..23787b40dbce
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,65 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+short_desc="Use a computer as a hub for your gaming devices"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+patch_args="-Np1"
+shlib_provides="libgimxconfigeditor.so libgimxconfigupdater.so libgimxcontroller.so
+ libgimxdownloader.so libgimxfile.so libgimxgpp.so libgimxhid.so libgimxinput.so
+ libgimxlog.so libgimxpoll.so libgimxprio.so libgimxserial.so libgimxtimer.so
+ libgimxtime.so libgimxudp.so libgimxuhid.so libgimxupdater.so libgimxusb.so"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS="-Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_patch() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}
+
+gimx-gui_package() {
+	depends="${sourcepkg}>=${version}_${revision} ${sourcepkg}-firmware>=${version}_${revision}
+	 avrdude xdg-utils xterm"
+	short_desc+=" - GUI tools"
+
+	pkg_install() {
+		for bin in config fpsconfig launcher loader ; do
+			vmove "usr/bin/gimx-${bin}"
+		done
+		vmove usr/share/applications
+		vmove usr/share/pixmaps
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (36 preceding siblings ...)
  2021-05-11  6:20 ` [PR PATCH] [Updated] " amak79
@ 2021-05-11  6:33 ` amak79
  2021-05-11  6:41 ` [PR REVIEW] " amak79
                   ` (4 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-05-11  6:33 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 416 bytes --]

New comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#issuecomment-837920755

Comment:
I've changed the way the package is split. I now leave all files in the base package and only split the firmware and gui tools. It didn't seem correct to have a cli package that also installed libs. I also didn't want a libs subpackage since the libs are only used internally.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR REVIEW] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (37 preceding siblings ...)
  2021-05-11  6:33 ` amak79
@ 2021-05-11  6:41 ` amak79
  2021-05-14  0:23 ` amak79
                   ` (3 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-05-11  6:41 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 386 bytes --]

New review comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#discussion_r629886781

Comment:
I had a look at other packages that specify `shlib_provides`. `muffin` for example specifies the same libs in `common/shlibs` and `shlib_provides`. I'm not sure why it does this, but it seems to be the only way to make `xbps-install` happy.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (38 preceding siblings ...)
  2021-05-11  6:41 ` [PR REVIEW] " amak79
@ 2021-05-14  0:23 ` amak79
  2021-06-28  4:32 ` [PR PATCH] [Updated] " amak79
                   ` (2 subsequent siblings)
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-05-14  0:23 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 416 bytes --]

New comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#issuecomment-837920755

Comment:
I've changed the way the package is split. I now leave all files in the base package and only split the firmware and gui tools. It didn't seem correct to have a cli package that also installed libs. I also didn't want a libs subpackage since the libs are only used internally.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Updated] New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (39 preceding siblings ...)
  2021-05-14  0:23 ` amak79
@ 2021-06-28  4:32 ` amak79
  2022-02-15  9:30 ` [PR PATCH] [Closed]: " amak79
  2022-02-15  9:30 ` amak79
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2021-06-28  4:32 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 306 bytes --]

There is an updated pull request by amak79 against master on the void-packages repository

https://github.com/amak79/void-packages gimx
https://github.com/void-linux/void-packages/pull/26190

New package: gimx-8.0


A patch file from https://github.com/void-linux/void-packages/pull/26190.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gimx-26190.patch --]
[-- Type: text/x-diff, Size: 7396 bytes --]

From 9eff18abf70c159c3ac296b2a7eee17d88c33d10 Mon Sep 17 00:00:00 2001
From: amak <amak.git@outlook.com>
Date: Wed, 28 Oct 2020 00:50:20 +1100
Subject: [PATCH] New package: gimx-8.0

---
 common/shlibs                   | 18 +++++++++
 srcpkgs/gimx-firmware           |  1 +
 srcpkgs/gimx-gui                |  1 +
 srcpkgs/gimx/patches/musl.patch | 70 +++++++++++++++++++++++++++++++++
 srcpkgs/gimx/template           | 64 ++++++++++++++++++++++++++++++
 5 files changed, 154 insertions(+)
 create mode 120000 srcpkgs/gimx-firmware
 create mode 120000 srcpkgs/gimx-gui
 create mode 100644 srcpkgs/gimx/patches/musl.patch
 create mode 100644 srcpkgs/gimx/template

diff --git a/common/shlibs b/common/shlibs
index 8a7eef8df8c3..34c1a4e74142 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4013,3 +4013,21 @@ libbasu.so.0 basu-0.2.0_1
 libXcomp.so.3 nx-libs-3.5.99.24_1
 libXcompshad.so.3 nx-libs-3.5.99.24_1
 libNX_X11.so.6 nx-libs-3.5.99.24_1
+libgimxconfigeditor.so gimx-8.0_1
+libgimxconfigupdater.so gimx-8.0_1
+libgimxcontroller.so gimx-8.0_1
+libgimxdownloader.so gimx-8.0_1
+libgimxfile.so gimx-8.0_1
+libgimxgpp.so gimx-8.0_1
+libgimxhid.so gimx-8.0_1
+libgimxinput.so gimx-8.0_1
+libgimxlog.so gimx-8.0_1
+libgimxpoll.so gimx-8.0_1
+libgimxprio.so gimx-8.0_1
+libgimxserial.so gimx-8.0_1
+libgimxtimer.so gimx-8.0_1
+libgimxtime.so gimx-8.0_1
+libgimxudp.so gimx-8.0_1
+libgimxuhid.so gimx-8.0_1
+libgimxupdater.so gimx-8.0_1
+libgimxusb.so gimx-8.0_1
diff --git a/srcpkgs/gimx-firmware b/srcpkgs/gimx-firmware
new file mode 120000
index 000000000000..314280752548
--- /dev/null
+++ b/srcpkgs/gimx-firmware
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx-gui b/srcpkgs/gimx-gui
new file mode 120000
index 000000000000..314280752548
--- /dev/null
+++ b/srcpkgs/gimx-gui
@@ -0,0 +1 @@
+gimx
\ No newline at end of file
diff --git a/srcpkgs/gimx/patches/musl.patch b/srcpkgs/gimx/patches/musl.patch
new file mode 100644
index 000000000000..3f8ff7551c96
--- /dev/null
+++ b/srcpkgs/gimx/patches/musl.patch
@@ -0,0 +1,70 @@
+Upstream: Sent but no response received
+
+diff -urpN gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c
+--- gimx-8.0-a/core/connectors/bluetooth/btstack/btstack_common.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/core/connectors/bluetooth/btstack/btstack_common.c	2020-10-30 17:11:20.954389849 +1100
+@@ -6,6 +6,7 @@
+ #include "btstack_common.h"
+ #include <connectors/tcp_con.h>
+ #include <stdio.h>
++#include <sys/time.h>
+ 
+ #define BTSTACK_TIMEOUT   1 // 1 second
+ 
+diff -urpN gimx-8.0-a/shared/gimxcommon/src/posix/async.c gimx-8.0-b/shared/gimxcommon/src/posix/async.c
+--- gimx-8.0-a/shared/gimxcommon/src/posix/async.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxcommon/src/posix/async.c	2020-10-30 16:45:49.074739922 +1100
+@@ -120,7 +120,7 @@ int async_read_timeout(struct async_devi
+   fd_set readfds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bread != count)
+@@ -164,7 +164,7 @@ int async_write_timeout(struct async_dev
+   fd_set writefds;
+ 
+   time_t sec = timeout / 1000;
+-  __suseconds_t usec = (timeout - sec * 1000) * 1000;
++  suseconds_t usec = (timeout - sec * 1000) * 1000;
+   struct timeval tv = {.tv_sec = sec, .tv_usec = usec};
+ 
+   while(bwritten != count)
+diff -urpN gimx-8.0-a/shared/gimxfile/src/gfile.cpp gimx-8.0-b/shared/gimxfile/src/gfile.cpp
+--- gimx-8.0-a/shared/gimxfile/src/gfile.cpp	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxfile/src/gfile.cpp	2020-10-30 16:34:01.398217034 +1100
+@@ -7,6 +7,7 @@
+ #include <gimxlog/include/glog.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <string.h>
++#include <limits.h>
+ 
+ #ifndef WIN32
+ #include <pwd.h> //to get the homedir + uid and gid
+diff -urpN gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c
+--- gimx-8.0-a/shared/gimxtimer/src/linux/gtimer.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxtimer/src/linux/gtimer.c	2020-10-30 16:51:05.894944798 +1100
+@@ -73,8 +73,8 @@ static int read_callback(void * user) {
+ 
+ struct gtimer * gtimer_start(void * user, unsigned int usec, const GTIMER_CALLBACKS * callbacks) {
+ 
+-  __time_t sec = usec / 1000000;
+-  __time_t nsec = (usec - sec * 1000000) * 1000;
++  time_t sec = usec / 1000000;
++  time_t nsec = (usec - sec * 1000000) * 1000;
+   struct timespec period = { .tv_sec = sec, .tv_nsec = nsec };
+   struct itimerspec new_value = { .it_interval = period, .it_value = period, };
+ 
+diff -urpN gimx-8.0-a/shared/gimxudp/src/posix/gudp.c gimx-8.0-b/shared/gimxudp/src/posix/gudp.c
+--- gimx-8.0-a/shared/gimxudp/src/posix/gudp.c	2020-05-05 22:00:15.000000000 +1000
++++ gimx-8.0-b/shared/gimxudp/src/posix/gudp.c	2020-10-30 16:57:00.111701709 +1100
+@@ -14,6 +14,7 @@
+ #include <stdio.h>
+ #include <unistd.h>
+ #include <string.h>
++#include <sys/time.h>
+ #include <gimxcommon/include/gerror.h>
+ #include <gimxlog/include/glog.h>
+ 
diff --git a/srcpkgs/gimx/template b/srcpkgs/gimx/template
new file mode 100644
index 000000000000..cc0b8cb59b3a
--- /dev/null
+++ b/srcpkgs/gimx/template
@@ -0,0 +1,64 @@
+# Template file for 'gimx'
+pkgname=gimx
+version=8.0
+revision=1
+build_style=gnu-makefile
+make_use_env=yes
+hostmakedepends="gettext pkg-config"
+makedepends="libbluetooth-devel libcurl-devel libusb-devel libX11-devel libXi-devel
+ libxml2-devel mhash-devel ncurses-devel wxWidgets-gtk3-devel"
+short_desc="Use a computer as a hub for your gaming devices"
+maintainer="amak <amak.git@outlook.com>"
+license="GPL-3.0-only"
+homepage="https://blog.gimx.fr/"
+distfiles="https://github.com/matlo/GIMX/releases/download/v${version}/gimx_${version}-1.tar.gz"
+checksum=783673435bd424ba49e6ad5911559a517f746e50dad0f10689f0dc53336a8e1e
+shlib_provides="libgimxconfigeditor.so libgimxconfigupdater.so libgimxcontroller.so
+ libgimxdownloader.so libgimxfile.so libgimxgpp.so libgimxhid.so libgimxinput.so
+ libgimxlog.so libgimxpoll.so libgimxprio.so libgimxserial.so libgimxtimer.so
+ libgimxtime.so libgimxudp.so libgimxuhid.so libgimxupdater.so libgimxusb.so"
+
+# silence unused function errors in loader/gimx-loader.cpp
+# that are triggered by archs not defined in info.h
+CXXFLAGS="-Wno-unused-function"
+
+if [ "$CROSS_BUILD" ]; then
+	hostmakedepends+=" ncurses-devel"
+fi
+
+post_patch() {
+	# fix build with ncurses 6
+	vsed -i -e "s:ncursesw5-config:ncursesw6-config:" core/Makefile
+
+	# fix ncursesw/ncurses.h include
+	vsed -i -e "s:<ncursesw/ncurses.h>:<curses.h>:" core/display.c
+
+	# fix build with wxWidgets-gtk3
+	find . -iname Makefile -exec sed -i -e "s:wx-config:&-gtk3:" "{}" \;
+}
+
+post_install() {
+	vdoc README.md
+}
+
+gimx-firmware_package() {
+	short_desc+=" - firmware files"
+
+	pkg_install() {
+		vmove usr/share/gimx/firmware
+	}
+}
+
+gimx-gui_package() {
+	depends="gimx>=${version}_${revision} gimx-firmware>=${version}_${revision}
+	 avrdude xdg-utils xterm"
+	short_desc+=" - GUI tools"
+
+	pkg_install() {
+		for bin in config fpsconfig launcher loader ; do
+			vmove "usr/bin/gimx-${bin}"
+		done
+		vmove usr/share/applications
+		vmove usr/share/pixmaps
+	}
+}

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (41 preceding siblings ...)
  2022-02-15  9:30 ` [PR PATCH] [Closed]: " amak79
@ 2022-02-15  9:30 ` amak79
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2022-02-15  9:30 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 311 bytes --]

New comment by amak79 on void-packages repository

https://github.com/void-linux/void-packages/pull/26190#issuecomment-1040048972

Comment:
Although I still use this package, I will close this PR because upstream hasn't been active. There are also some remaining issues with the template that need to be fixed.

^ permalink raw reply	[flat|nested] 44+ messages in thread

* Re: [PR PATCH] [Closed]: New package: gimx-8.0
  2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
                   ` (40 preceding siblings ...)
  2021-06-28  4:32 ` [PR PATCH] [Updated] " amak79
@ 2022-02-15  9:30 ` amak79
  2022-02-15  9:30 ` amak79
  42 siblings, 0 replies; 44+ messages in thread
From: amak79 @ 2022-02-15  9:30 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 155 bytes --]

There's a closed pull request on the void-packages repository

New package: gimx-8.0
https://github.com/void-linux/void-packages/pull/26190

Description:


^ permalink raw reply	[flat|nested] 44+ messages in thread

end of thread, other threads:[~2022-02-15  9:30 UTC | newest]

Thread overview: 44+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-07  0:36 [PR PATCH] New package: gimx-8.0 amak79
2020-11-07  0:46 ` [PR REVIEW] " ericonr
2020-11-07  0:46 ` ericonr
2020-11-07  0:46 ` ericonr
2020-11-07  0:47 ` ericonr
2020-11-07  0:47 ` ericonr
2020-11-07  0:47 ` ericonr
2020-11-07  2:24 ` amak79
2020-11-07  2:24 ` amak79
2020-11-07  2:25 ` amak79
2020-11-07  2:25 ` amak79
2020-11-07  2:25 ` amak79
2020-11-07  2:26 ` amak79
2020-11-07  2:28 ` amak79
2020-11-07  3:09 ` amak79
2020-11-07  3:18 ` amak79
2020-11-07  4:06 ` amak79
2020-11-07  6:06 ` amak79
2020-11-07  7:56 ` [PR PATCH] [Updated] " amak79
2020-11-07  9:04 ` [PR REVIEW] " amak79
2020-11-08  0:23 ` [PR PATCH] [Updated] " amak79
2020-11-08  0:32 ` amak79
2020-11-08  3:01 ` [PR REVIEW] " amak79
2020-11-08  4:20 ` [PR PATCH] [Updated] " amak79
2020-11-08  4:48 ` amak79
2020-11-11  4:50 ` [PR REVIEW] " amak79
2020-11-11  4:55 ` amak79
2021-01-19  1:49 ` [PR PATCH] [Updated] " amak79
2021-04-06  1:04 ` amak79
2021-04-06 11:49 ` [PR REVIEW] " ericonr
2021-04-06 11:49 ` ericonr
2021-04-06 11:49 ` ericonr
2021-04-06 12:33 ` [PR PATCH] [Updated] " amak79
2021-05-10  4:02 ` [PR REVIEW] " amak79
2021-05-10  4:20 ` amak79
2021-05-10  6:37 ` amak79
2021-05-10  7:20 ` amak79
2021-05-11  6:20 ` [PR PATCH] [Updated] " amak79
2021-05-11  6:33 ` amak79
2021-05-11  6:41 ` [PR REVIEW] " amak79
2021-05-14  0:23 ` amak79
2021-06-28  4:32 ` [PR PATCH] [Updated] " amak79
2022-02-15  9:30 ` [PR PATCH] [Closed]: " amak79
2022-02-15  9:30 ` amak79

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).