[MacPorts] #17979: startupitems using launchd and needing a wrapper fail to create the wrapper
#17979: startupitems using launchd and needing a wrapper fail to create the wrapper ---------------------------------+------------------------------------------ Reporter: blb@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: MacPorts Future Component: base | Version: 1.7.0 Keywords: startupitem launchd | Port: ---------------------------------+------------------------------------------ When a start, stop, restart, or init (but not both start and stop) option is given to startupitem and the system supports launchd, it wants to use a wrapper script ([browser:trunk/base/src/port1.0/portstartupitem.tcl#L416 beginning of section]) and a startup script. The code creates a launchd wrapper which references this startup script ([browser:trunk/base/src/port1.0/portstartupitem.tcl#L424 block which references the startup script]). However, nowhere in {{{proc startupitem_create_darwin_launchd}}} does it actually create this script, {{{${scriptdir}/${portname}.sh}}}. If a port is expected to create this startup script itself, it needs to be documented since the directory for it, {{{${prefix}/etc/startup}}}, does not appear in any documentation I can find. -- Ticket URL: <http://trac.macports.org/ticket/17979> MacPorts <http://www.macports.org/> Ports system for Mac OS
#17979: startupitems using launchd and needing a wrapper fail to create the wrapper ---------------------------------+------------------------------------------ Reporter: blb@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: MacPorts Future Component: base | Version: 1.7.0 Keywords: startupitem launchd | Port: ---------------------------------+------------------------------------------ Comment(by blb@…): See the fix in r45298 for how it was affecting dbus at least... -- Ticket URL: <http://trac.macports.org/ticket/17979#comment:1> MacPorts <http://www.macports.org/> Ports system for Mac OS
#17979: startupitems using launchd and needing a wrapper fail to create the wrapper ---------------------------------+------------------------------------------ Reporter: blb@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: MacPorts Future Component: base | Version: 1.7.0 Keywords: startupitem launchd | Port: ---------------------------------+------------------------------------------ Comment(by markd@…): I hope I've addressed the fact that mp does not create scripts in r45344. But I don't understand what the dbus issue has to do with this. -- Ticket URL: <http://trac.macports.org/ticket/17979#comment:2> MacPorts <http://www.macports.org/> Ports system for Mac OS
#17979: startupitems using launchd and needing a wrapper fail to create the wrapper ---------------------------------+------------------------------------------ Reporter: blb@… | Owner: macports-tickets@… Type: defect | Status: new Priority: Normal | Milestone: MacPorts Future Component: base | Version: 1.7.0 Keywords: startupitem launchd | Port: ---------------------------------+------------------------------------------ Comment(by blb@…): The problem was that dbus had used startupitem.init which then caused the startupitem code to reference the startup script, but never actually created that script, so the launchd item would always fail to launch. I referenced the dbus bit since that's where I ran into this issue. I actually have no idea if that's how startupitem is supposed to work and that script must be created by the port, or if it's a bug with startupitem itself. -- Ticket URL: <http://trac.macports.org/ticket/17979#comment:3> MacPorts <http://www.macports.org/> Ports system for Mac OS
#17979: startupitems using launchd and needing a wrapper fail to create the wrapper -------------------------------+-------------------------------------------- Reporter: blb@… | Owner: macports-tickets@… Type: defect | Status: closed Priority: Normal | Milestone: MacPorts Future Component: base | Version: 1.7.0 Resolution: fixed | Keywords: startupitem launchd Port: | -------------------------------+-------------------------------------------- Changes (by markd@…): * status: new => closed * resolution: => fixed Comment: Ah I see. I think the problem is that startup.init should not be used with startupitem.executable. I fixed the warning note on that in the guide, which has some problems before. Here is the updated text: Note: Since script and executable are mutually exclusive StartupItem types, the startupitem.executable keyword may not be used in a Portfile that uses any keywords listed in the Script StartupItems section. Also, the guide startupitem.init part says: - Shell code that will be executed prior to any of the options startupitem.start startupitem.stop and startupitem.restart. So I think we're covered in the docs now so I'll close this. Thanks for reporting it. -- Ticket URL: <http://trac.macports.org/ticket/17979#comment:4> MacPorts <http://www.macports.org/> Ports system for Mac OS
#17979: startupitems using launchd and needing a wrapper fail to create the wrapper -------------------------------+-------------------------------------------- Reporter: blb@… | Owner: macports-tickets@… Type: defect | Status: closed Priority: Normal | Milestone: Component: guide | Version: 1.7.0 Resolution: fixed | Keywords: startupitem launchd Port: | -------------------------------+-------------------------------------------- Changes (by jmr@…): * component: base => guide * milestone: MacPorts Future => -- Ticket URL: <http://trac.macports.org/ticket/17979#comment:5> MacPorts <http://www.macports.org/> Ports system for Mac OS
participants (1)
-
MacPorts