motion.c: In function ‘motion_init’: motion.c:1146:13: error: unknown type name ‘my_bool’; did you mean ‘bool’? 1146 | my_bool my_true = TRUE; | ^~~~~~~ | bool make: *** [Makefile:105: motion.o] Error 1 make: *** Waiting for unfinished jobs....
This related to the recent version bump of mysql-8 & mysql-connector-c-8. Candidate for tracker: https://bugs.gentoo.org/692570
Created attachment 587764 [details, diff] motion-release-4.1.1-my_bool-error.diff Proposed patch to take care of the issue against >=dev-db/mysql-connector-c-8.0.1
Upstream issue opened: https://github.com/Motion-Project/motion/issues/995 I'll wait to see how upstream decides to resolve this, then backport their solution.
Upstream decided to redefine the my_true to an int datatype. This resolves the issue for MySQL, but I think it may cause problems for MariaDB which has deprecated the mysql_options function. Here's an alternative solution that should satisfy both scenarios: https://github.com/vilhelmgray/motion/commit/79ef57405c49ca1226fc00af1995bdab287ae9ea
(In reply to William Breathitt Gray from comment #4) > Upstream decided to redefine the my_true to an int datatype. This resolves > the issue for MySQL, but I think it may cause problems for MariaDB which has > deprecated the mysql_options function. > > Here's an alternative solution that should satisfy both scenarios: > https://github.com/vilhelmgray/motion/commit/ > 79ef57405c49ca1226fc00af1995bdab287ae9ea The alternative solution seems to take care of MariaDB as well. Looks safer when it comes to side-effects. I would prefer the alternative instead of upstream's int way.
(In reply to William Breathitt Gray from comment #4) > Upstream decided to redefine the my_true to an int datatype. This resolves > the issue for MySQL, but I think it may cause problems for MariaDB which has > deprecated the mysql_options function. > > Here's an alternative solution that should satisfy both scenarios: > https://github.com/vilhelmgray/motion/commit/ > 79ef57405c49ca1226fc00af1995bdab287ae9ea I tried to use this patch w/o success: patching file configure.ac Hunk #1 FAILED at 90. Hunk #2 FAILED at 259. Hunk #3 FAILED at 411. 3 out of 3 hunks FAILED -- saving rejects to file configure.ac.rej can't find file to patch at input line 69 Perhaps you used the wrong -p or --strip option? The text leading up to this was: -------------------------- |diff --git a/src/motion.c b/src/motion.c |index 8f15b041..d4b3666d 100644 |--- a/src/motion.c |+++ b/src/motion.c -------------------------- No file to patch. Skipping patch. 2 out of 2 hunks ignored
Motion-4.1.1 mixed up the client software for MySQL and MariaDB. This is resolved in motion-4.3.1, which is now in portage in the testing branch.
(In reply to Hans Fernhout from comment #7) > Motion-4.1.1 mixed up the client software for MySQL and MariaDB. This is > resolved in motion-4.3.1, which is now in portage in the testing branch. I don't believe this is resolved yet upstream; it looks like they are still calling mysql_options and just assuming MariaDB is compatible with MySQL: https://github.com/Motion-Project/motion/blob/392779e90bf101eeaebb2f95309963281d55395e/src/motion.c#L1062
The release notes of 4.3.1 mention "MariaDB initializations". I have also tested it with both MySQL and MariaDB and it seems to work fine. Do you still encounter compilation errors?
4.1.1 is no longer in the tree. The MySQL/MariaDB issue has been addressed upstream in newer versions of motion.