Ticket #43256: patch-tftp-hpa-Portfile.2.diff
File patch-tftp-hpa-Portfile.2.diff, 4.7 KB (added by jul_bsd@…, 11 years ago) |
---|
-
net/tftp-hpa/Portfile
old new 2 2 3 3 PortSystem 1.0 4 4 5 name tftp-hpa 6 version 0.48 7 revision 2 8 categories net 9 maintainers markd 10 description Enhanced port of the BSD TFTP server 11 platforms darwin 12 long_description tftp-hpa is an enhanced version of the BSD TFTP client \ 13 and server, possessing a number of bugfixes and enhancements \ 14 over the original. It has been made portable and will work on \ 15 pretty much any modern Unix variant. 16 17 homepage http://www.kernel.org/pub/software/network/tftp/ 18 master_sites ${homepage} 19 use_bzip2 yes 20 checksums md5 f2e0a1ca0c49ae46ecad26a54df3e887 5 name tftp-hpa 6 version 5.2 7 categories net 8 maintainers markd 9 description Enhanced port of the BSD TFTP server 10 platforms darwin 11 long_description tftp-hpa is an enhanced version of the BSD TFTP client \ 12 and server, possessing a number of bugfixes and enhancements \ 13 over the original. It has been made portable and will work on \ 14 pretty much any modern Unix variant. 15 license BSD 16 homepage http://www.kernel.org/pub/software/network/tftp/ 17 master_sites ${homepage}/tftp-hpa/ 18 use_bzip2 yes 21 19 22 set tftp-root ${prefix}/var/${name}/ 20 checksums rmd160 dc3935af75f2919c55cac6c04b61488af425918c \ 21 sha256 0a9f88d4c1c02687b4853b02ab5dd8779d4de4ffdb9b2e5c9332841304d1a269 22 23 patchfiles patch-tftpd-recvfrom.c.diff 24 25 depends_lib port:readline port:ncurses 26 27 set tftp-root ${prefix}/var/${name}/ 23 28 24 29 variant enable_upload description {If invoked with the server variant, tftp uploads \ 25 30 are enabled; without the server variant, this variant has no effect} {} 26 31 27 startupitem.name 32 startupitem.name tftpd 28 33 29 34 variant server description {Install launchd scripts to run tftpd at system boot} { 30 startupitem.createyes31 32 startupitem.executable${prefix}/sbin/tftpd -L -s ${tftp-root}33 34 35 35 startupitem.create yes 36 if { ! [variant_isset enable_upload] } { 37 startupitem.executable ${prefix}/sbin/tftpd -L -s ${tftp-root} 38 } else { 39 startupitem.executable ${prefix}/sbin/tftpd -L -c -s ${tftp-root} 40 } 36 41 } 37 42 38 configure.args 43 configure.args --mandir=\\\${prefix}/share/man 39 44 40 destroot.destdir 45 destroot.destdir prefix=${destroot}${prefix} 41 46 42 post-destroot {43 44 47 post-destroot { 48 file rename ${destroot}${prefix}/sbin/in.tftpd \ 49 ${destroot}${prefix}/sbin/tftpd 45 50 46 47 48 51 file delete ${destroot}${prefix}/share/man/man8/tftpd.8 52 file rename ${destroot}${prefix}/share/man/man8/in.tftpd.8 \ 53 ${destroot}${prefix}/share/man/man8/tftpd.8 49 54 50 51 55 reinplace "s|in.tftpd|tftpd|g" \ 56 ${destroot}${prefix}/share/man/man8/tftpd.8 52 57 53 54 58 xinstall -m 777 -d ${tftp-root} 59 destroot.keepdirs ${tftp-root} 55 60 } 56 61 57 62 # tftp-ha setup instructions 58 post-install { 59 ui_msg "\n 63 notes " 60 64 61 65 ***** Setup Instructions ***** 62 66 … … 64 68 on all local addresses. 65 69 66 70 To run tftpd manually for download only access, use this command: 67 71 sudo tftpd -L -s <tftp-root-dir> 68 72 69 73 To run tftpd manually and support tftp uploads, add \"-c\" to the command: 70 74 sudo tftpd -L -c -s <tftp-root-dir> 71 75 72 76 You may run tftpd at system boot using the startupitem if you installed tftp-hpa 73 77 using the server variant. To load the startupitem using launchctl: 74 78 sudo launchctl load -w /Library/LaunchDaemons/org.macports.tftpd.plist 75 79 76 80 NOTE: When loading tftp-hpa using launchctl, make sure to place the files you want to serve 77 81 in ${tftp-root}, because that is the location set in the StartupItem. … … 82 86 file and replace the one installed by MacPorts in /Library/LaunchDaemons. You 83 87 may use /System/Library/LaunchDaemons/tftp.plist as a template. 84 88 85 \n" 86 } 89 " 87 90