| Summary: | x11/xloadimage: Build fails if Samba is installed as PDC | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | Ports & Packages | Reporter: | mail_of_sergey | ||||||
| Component: | Individual Port(s) | Assignee: | Dmitry Marakasov <amdmi3> | ||||||
| Status: | Closed FIXED | ||||||||
| Severity: | Affects Only Me | CC: | ak, amdmi3 | ||||||
| Priority: | --- | Keywords: | needs-qa, patch | ||||||
| Version: | Latest | Flags: | vlad-fbsd:
maintainer-feedback?
(ak) |
||||||
| Hardware: | Any | ||||||||
| OS: | Any | ||||||||
| Attachments: |
|
||||||||
Created attachment 170598 [details]
Proposed fix
Please check out attached patch.
It solves another problem: we're moving towards reproducible port builds, and xloadimage is not compatible with it as it compiles current date and `uname -a` output which changes across different systems into the binary. Also it's unable to detect operating system name correctly. So, don't compile date, uname and `id` output in, fixing both problems, and set OS name correctly for better `xloadimage -version` output
Awaiting maintainer's feedback (In reply to Dmitry Marakasov from comment #1) No, I got the same error. You can't have the same error as `id` output can no longer end up in build.c. Please verify that you've placed the patch properly in files/ subdirectory. After patch phase, work/xloadimage.4.1/build-info should be the following:
---
#!/bin/sh
# this generates the "build.c" file
# try to find out the build date
date='char *BuildDate= (char *)0;'
# try to find out who's doing the build. there are two common places
# for 'id', /bin/id and /usr/bin/id.
user='char *BuildUser= (char *)0;'
# try to find out the system information
uname='char *BuildSystem= "FreeBSD";'
echo '/* THIS FILE IS AUTOMATICALLY GENERATED */' > build.c
echo $uname >> build.c
echo $date >> build.c
echo $user >> build.c
---
(In reply to Dmitry Marakasov from comment #4) Sorry, now all correct. Thanks for testing! Reopening as the patch has not been committed yet. Awaiting maintainer's feedback. A commit references this bug: Author: ak Date: Mon Jun 6 04:42:15 UTC 2016 New revision: 416442 URL: https://svnweb.freebsd.org/changeset/ports/416442 Log: - Regenerate distinfo - Fix build when Samba is installed and configured as PDC [1] - Make build reproducible [2] PR: 209724 Submitted by: mail_of_sergey@mail.ru Submitted by: amdmi3 [1] [2] Changes: head/x11/xloadimage/distinfo head/x11/xloadimage/files/patch-build-info I apologize for my inattention, somehow I failed to get notices from bugzilla for this pr and only discovered it from last weekly reminder. I test by make clean reinstall clean it's works! Thanks for all! |
Created attachment 170583 [details] compiling log If Samba is installed and configured as PDC, xloadimage fail on BUILTIN\users: build.c:4:213: error: \u used with no following hex digits char *BuildUser= "uid=0(root) gid=0(wheel) groups=0(wheel),5(operator),1050(admin_nt_group),1069(domain_users),1083(softholder),1106(printer_admins),1322(winbindd_priv),10189(BUILTIN\administrators),10190(BUILTIN\users)";