Bug 207361 - ports-mgmt/synth: Fails to build postgresql95-server with dtrace support
Summary: ports-mgmt/synth: Fails to build postgresql95-server with dtrace support
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: John Marino
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-02-19 19:53 UTC by Lacey Powers
Modified: 2016-02-29 19:46 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (marino)


Attachments
synth postgresql95-server build log (28.69 KB, text/x-log)
2016-02-19 19:53 UTC, Lacey Powers
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lacey Powers 2016-02-19 19:53:25 UTC
Created attachment 167203 [details]
synth postgresql95-server build log

postgresql95-server port builds fine with DTrace enabled under portmaster, but fails with synth. Synth log attached.

Version: 10.2-RELEASE-p9
DTrace kmod loaded on boot.
Comment 1 Lacey Powers 2016-02-19 21:52:28 UTC
postgresql95-server also builds correctly under poudriere with DTrace enabled as well.

Please let me know if you need further information. Thank you. =)
Comment 2 John Marino freebsd_committer freebsd_triage 2016-02-19 21:58:04 UTC
i don't know much about dtrace.

did you try "kldload dtraceall" first?
Comment 3 Lacey Powers 2016-02-19 22:20:53 UTC
Yes, the modules are loaded at boot with dtraceall_load="YES" and working. Here's some output for proof.

[0]lacey@talizorah:~$ sudo dtrace -l | wc -l
   65453
[0]lacey@talizorah:~$ kldstat | grep dtraceall
40    1 0xffffffff82adf000 2188     dtraceall.ko
[0]lacey@talizorah:~$ 

From your documentation, it looks like Synth is building within a jail. I'm taking a guess that because of that, the build process can't get at anything in /dev/dtrace which is needed to build dtrace support.
Comment 4 John Marino freebsd_committer freebsd_triage 2016-02-19 22:23:18 UTC
it's not a jail (it's a chroot) but /dev/dtrace doesn't exist I'm fairly sure.
Comment 5 John Marino freebsd_committer freebsd_triage 2016-02-29 16:09:30 UTC
I checked with "test" command with ENTERAFTER=configure set in environment (on another port) and confirmed that /dev/dtrace does exist in jail, so that's not the issue.
Comment 6 John Marino freebsd_committer freebsd_triage 2016-02-29 17:12:37 UTC
based on some google searches, there's a chance that /boot is required to be exposed in builder environment (freebsd-only requirement).  I'll test with that implemented and report back.
Comment 7 John Marino freebsd_committer freebsd_triage 2016-02-29 18:46:35 UTC
with the following change, synth will build postgresql95-server with dtrace options assuming dtrace is loaded in the kernel:

https://github.com/jrmarino/synth/commit/fa953d5d9f80bbf1102bd07dcb521614904c6245

It will be available on the next release (probably 1.03 rather than 1.10 as I've got another couple of fixes already)
Comment 8 Lacey Powers 2016-02-29 18:53:29 UTC
That is awesome! Thank you! I look forward to trying this out.
Comment 9 commit-hook freebsd_committer freebsd_triage 2016-02-29 19:44:49 UTC
A commit references this bug:

Author: marino
Date: Mon Feb 29 19:44:42 UTC 2016
New revision: 409824
URL: https://svnweb.freebsd.org/changeset/ports/409824

Log:
  ports-mgmt/synth: Upgrade version 1.02 => 1.03

  bug fixes:
   * cron operation fixed
     The terminal is unset for cron jobs.  The setting of TERM to "cons25"
     in the environment caused a failure, but it's fixed by changing the
     value to "dumb".  Note that curses must be off in the profile invoked
     by cron.
   * dtrace building fixed [1]
     On FreeBSD, /boot is now read-only null-mounted if it exists in the
     profile's system root.  This fixes building dtrace probes when the
     option is set.
   * fix muted pipe exit status
     Pipes have to be read even when no output is expected in order to get
     the correct exit status
   * fix pipe child exit status
     The previous implementation mixed child and parent exit statuses in
     error; now they are isolated and returned correctly.

  Enhancement:
   If a muted pipe command fails, an appropriate error message is given
   including which command failed.  This helps identify the real error
   instead of repercussions appearing later which mask the problem.

  PR:	207361 [1]

Changes:
  head/ports-mgmt/synth/Makefile
  head/ports-mgmt/synth/distinfo