#15551 closed update (fixed)
Patch updating dnsmasq to 2.42
Reported by: | dgilman (David Gilman) | Owned by: | macports-tickets@… |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 1.6.0 |
Keywords: | dnsmasq | Cc: | jmroot (Joshua Root), simon@… |
Port: |
Description
Attached are patches against the port for dnsmasq to bump to version 2.42. I've also added a startupitem to the Portfile.
There is no maintainer for this port.
One question though: the package by default installs an example config file. I think it would be appropriate to remind the user to set this up before loading the package into launchd. What would be the best way to do this?
(macports is really cool, i had no idea about this startupitem option until just a bit ago.)
Attachments (6)
Change History (13)
Changed 16 years ago by dgilman (David Gilman)
Attachment: | patch-Portfile.diff added |
---|
Changed 16 years ago by dgilman (David Gilman)
Attachment: | patch-Makefile.diff added |
---|
patch for the makefile
Changed 16 years ago by dgilman (David Gilman)
Attachment: | patch-config.h.diff added |
---|
patch for an include file
comment:2 Changed 16 years ago by jmroot (Joshua Root)
Cc: | davidgilman1@… removed |
---|---|
Milestone: | Port Submissions → Port Updates |
See the squid port for an example of how to handle generating a real config file from a sample one only when the former doesn't exist. Also, please remove the trailing whitespace from the long_description (port lint should warn about that).
Changed 16 years ago by davidgilman1+macports@…
Attachment: | patch-Portfile.2.diff added |
---|
v2 Portfile with post-activate
comment:3 Changed 16 years ago by davidgilman1+macports@…
Ok, updated the portfile with the post-activate stuff for the config file. The default configuration for dnsmasq is to read and poll /etc/resolv.conf for nameservers. MacOS X updates this file by itself.
comment:4 Changed 16 years ago by jmroot (Joshua Root)
Cc: | jmr@… added |
---|
The config.h patch will need to be changed. MacPorts also works on platforms where __APPLE__
is not defined, and files should still be installed into $prefix on them.
In the portfile, you don't need a foreach loop for one file. This will do:
post-activate { # Make sure initial conf file is present and setup correctly set f dnsmasq.conf if {![file exists ${prefix}/etc/${f}]} { file copy ${prefix}/etc/${f}.example \ ${prefix}/etc/${f} } }
I also notice you're installing it as dnsmasq.conf.sample in the makefile patch but referring to dnsmasq.conf.example in the portfile, so one will need to be changed.
Changed 16 years ago by davidgilman1+macports@…
Attachment: | patch-Portfile.3.diff added |
---|
3rd revision of proposed portfile
Changed 16 years ago by davidgilman1+macports@…
Attachment: | patch-config.h.3.diff added |
---|
3rd revision of proposed config.h patch
comment:5 Changed 16 years ago by simon@…
Cc: | simon@… added |
---|---|
Resolution: | → fixed |
Status: | new → closed |
Committed in r37899. Thanks for your help,
Simon
comment:6 Changed 16 years ago by jmroot (Joshua Root)
Type: | enhancement → update |
---|
diff of the portfile