|Summary:||[patch] Fail to build polkit on FreeBSD|
|Product:||PolicyKit||Reporter:||Ting-Wei Lan <lantw44>|
|Component:||libpolkit||Assignee:||David Zeuthen (not reading bugmail) <zeuthen>|
|Status:||RESOLVED MOVED||QA Contact:||David Zeuthen (not reading bugmail) <zeuthen>|
|Priority:||medium||CC:||ajacoutot, shawn.walker, walters|
|i915 platform:||i915 features:|
Fix build problem on FreeBSD
Correct the patch to fix the build problem
Description Ting-Wei Lan 2014-01-20 07:54:03 UTC
Created attachment 92426 [details] Fix build problem on FreeBSD There are various problems prevent polkit from working on FreeBSD. 1. FreeBSD does not have fdatasync(). 2. setnetgrent() on FreeBSD does not have return value. 3. FreeBSD does not have SIGPOLL. 4. mocklibc cannot be built on FreeBSD.
Comment 1 Allison Lortie (desrt) 2014-01-23 06:52:29 UTC
(In reply to comment #0) > Created attachment 92426 [details] +#ifdef HAVE_SETNETGRENT I think you meant HAVE_SETNETGRENT_RETURN here?
Comment 2 Ting-Wei Lan 2014-01-27 16:36:00 UTC
Created attachment 92867 [details] [review] Correct the patch to fix the build problem Sorry for the typo. I upload the correct patch now.
Comment 3 Colin Walters 2014-02-19 00:26:13 UTC
I don't much care for "--disable-test" as a build option name. What's the conflict? Can we auto-detect whether the platform can support the tests? Nevertheless I'll push this for now. I only made minor tweaks for wording. In the future, split up patches that each do one thing are preferable.
Comment 4 Colin Walters 2014-02-19 00:26:49 UTC
Comment 5 Colin Walters 2014-02-19 00:27:00 UTC
Leaving the bug open for followup.
Comment 6 Allison Lortie (desrt) 2014-02-19 01:34:52 UTC
mocklibc won't build due to a number of issues: - the return type of the mocked functions setnetgrent() and setgrent() are not the same as the headers define them to be on FreeBSD. - we are missing fgetgrent() and fgetpwent() All attempts to track down information about mocklibc and FreeBSD pretty much point to people talking about polkit build failures...
Comment 7 Kamil Rytarowski 2015-06-07 14:50:03 UTC
fgetpwent(3) and fgetgrent(3) are missing on NetBSD as well.
Comment 8 Kamil Rytarowski 2015-06-07 15:16:42 UTC
Example implementations: http://cgit.freedesktop.org/accountsservice/tree/src/fgetpwent.c http://opensource.apple.com/source/freeradius/freeradius-11/freeradius/src/modules/rlm_unix/compat.h?txt http://opensource.apple.com/source/freeradius/freeradius-11/freeradius/src/modules/rlm_unix/compat.c?txt Please make them available as a fallback :)
Comment 9 GitLab Migration User 2018-08-20 21:35:45 UTC
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/polkit/polkit/issues/28.