1 | # $Id: Portfile 24541 2007-04-27 21:57:39Z pipping@macports.org $ |
---|
2 | |
---|
3 | PortSystem 1.0 |
---|
4 | name nano |
---|
5 | version 2.0.6 |
---|
6 | categories editors |
---|
7 | maintainers n.oxyde@gmail.com |
---|
8 | description Nano's ANOther editor - enhanced free Pico Clone |
---|
9 | long_description \ |
---|
10 | GNU nano is a small and friendly text editor. Besides basic text \ |
---|
11 | editing, nano offers many extra features like an interactive search \ |
---|
12 | and replace, goto line number, auto-indentation, feature toggles, \ |
---|
13 | internationalization support, and filename tab completion. |
---|
14 | |
---|
15 | homepage http://www.nano-editor.org/ |
---|
16 | master_sites ${homepage}dist/v[strsed ${version} {/\.[0-9]*$//}]/ gnu |
---|
17 | checksums md5 619107f0fc3c4383d668cef15aa3ca32 \ |
---|
18 | sha1 00102580404cdb1c8594e5f6193000d5acac2249 \ |
---|
19 | rmd160 858dc7cf7137cc2b19e9084a503fe508ef734381 |
---|
20 | |
---|
21 | platforms darwin freebsd |
---|
22 | depends_lib port:ncurses |
---|
23 | |
---|
24 | configure.args --enable-nanorc \ |
---|
25 | --disable-nls \ |
---|
26 | --disable-wrapping-as-root \ |
---|
27 | --disable-mouse \ |
---|
28 | --disable-largefile \ |
---|
29 | --disable-utf8 |
---|
30 | |
---|
31 | destroot.target install-strip |
---|
32 | |
---|
33 | post-destroot { |
---|
34 | xinstall -m 0755 -d ${destroot}${prefix}/share/doc/${name}/docs |
---|
35 | xinstall -m 0644 -W ${worksrcpath} AUTHORS BUGS COPYING ChangeLog INSTALL NEWS \ |
---|
36 | README THANKS TODO doc/faq.html doc/nanorc.sample doc/texinfo/nano.html \ |
---|
37 | ${destroot}${prefix}/share/doc/${name} |
---|
38 | } |
---|
39 | |
---|
40 | post-install { |
---|
41 | ui_msg "A sample configuration file is available at ${prefix}/share/doc/${name}/nanorc.sample ." |
---|
42 | |
---|
43 | if {! [variant_isset no_spell]} { |
---|
44 | ui_msg "Spell-checking support is enabled. To use it, you need a spellchecker e.g. aspell, ispell..." |
---|
45 | } |
---|
46 | } |
---|
47 | |
---|
48 | variant nls { |
---|
49 | configure.args-delete --disable-nls |
---|
50 | depends_lib-append port:gettext \ |
---|
51 | port:libiconv |
---|
52 | } |
---|
53 | |
---|
54 | variant utf8 { |
---|
55 | configure.args-append --enable-utf8 |
---|
56 | configure.args-delete --disable-utf8 |
---|
57 | depends_lib-append port:ncursesw |
---|
58 | depends_lib-delete port:ncurses |
---|
59 | } |
---|
60 | |
---|
61 | variant no_wrap { |
---|
62 | configure.args-append --disable-wrapping |
---|
63 | } |
---|
64 | |
---|
65 | variant no_spell { |
---|
66 | configure.args-append --disable-speller |
---|
67 | } |
---|
68 | |
---|
69 | variant mouse { |
---|
70 | configure.args-delete --disable-mouse |
---|
71 | |
---|
72 | post-install { |
---|
73 | ui_msg "Mouse support is enabled. ${name} need to be launched inside an x11 console to use it." |
---|
74 | } |
---|
75 | } |
---|
76 | |
---|
77 | variant multibuffer { |
---|
78 | configure.args-append --enable-multibuffer |
---|
79 | } |
---|
80 | |
---|
81 | variant color { |
---|
82 | configure.args-append --enable-color |
---|
83 | |
---|
84 | post-install { |
---|
85 | ui_msg "Color syntax is enabled. You should take a look at the syntax definitions in ${prefix}/share/${name} ." |
---|
86 | } |
---|
87 | } |
---|
88 | |
---|
89 | variant largefile { |
---|
90 | configure.args-delete --disable-largefile |
---|
91 | } |
---|
92 | |
---|
93 | livecheck.check regex |
---|
94 | livecheck.url http://ftp.gnu.org/gnu/${name}/?M=D |
---|
95 | livecheck.regex ${name}-(\\d+\\.\\d+\\.\\d+) |
---|