1 | # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; truncate-lines: t -*- vim:fenc=utf-8:et:sw=4:ts=4:sts=4 |
---|
2 | # $Id$ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | PortGroup compiler_blacklist_versions 1.0 |
---|
6 | PortGroup github 1.0 |
---|
7 | |
---|
8 | name macvim-devel |
---|
9 | set vim_version 7.4 |
---|
10 | set snapshot 76 |
---|
11 | categories editors |
---|
12 | platforms darwin |
---|
13 | license Vim GPL-2+ |
---|
14 | maintainers gmail.com:starkhalo \ |
---|
15 | openmaintainer |
---|
16 | description MacVim is a GUI version of vim for Mac OS X |
---|
17 | long_description \ |
---|
18 | MacVim is a port of the text editor Vim to Mac OS X that is meant to look \ |
---|
19 | better and integrate more seamlessly with the Mac than vim-app. |
---|
20 | homepage http://code.google.com/p/macvim |
---|
21 | |
---|
22 | github.setup macvim-dev macvim 34192eeed9cb29834f0d37d61767db654d1d7662 |
---|
23 | version ${vim_version}.snapshot${snapshot}-20150429 |
---|
24 | |
---|
25 | conflicts MacVim |
---|
26 | |
---|
27 | checksums rmd160 cc10498af3a5c46a0ade6739f55870f12574fb7d \ |
---|
28 | sha256 2fcd0e3326acaba0cb0a48ad8302e53e74fe3ec93196170ce0f9640ec2c644b1 |
---|
29 | |
---|
30 | depends_build bin:gnutar:gnutar \ |
---|
31 | bin:grep:grep \ |
---|
32 | bin:autoconf:autoconf \ |
---|
33 | port:python27 |
---|
34 | depends_lib port:ncurses \ |
---|
35 | port:gettext \ |
---|
36 | port:libiconv |
---|
37 | |
---|
38 | if ![variant_isset python27] { |
---|
39 | # python is only used for build scripts, no linking |
---|
40 | license_noconflict python27 |
---|
41 | } |
---|
42 | |
---|
43 | patchfiles patch-src-MacVim-icons-python.diff \ |
---|
44 | patch-MacVim-GCC-VERSION.diff |
---|
45 | |
---|
46 | pre-fetch { |
---|
47 | if {${os.platform} eq "darwin" && ${os.major} < 10} { |
---|
48 | ui_error "${name} only runs on Mac OS X 10.6 or greater." |
---|
49 | return -code error "incompatible Mac OS X version" |
---|
50 | } |
---|
51 | } |
---|
52 | |
---|
53 | post-extract { |
---|
54 | # create cache directory |
---|
55 | file mkdir ${workpath}/caches |
---|
56 | } |
---|
57 | |
---|
58 | # does not run correctly when build with older clang releases, see #30985 |
---|
59 | compiler.blacklist macports-clang-2.9 macports-clang-3.0 {clang < 400} |
---|
60 | |
---|
61 | # Patch to fix "conflicting types for 'sigalstack', see #39963 and #41774 |
---|
62 | # as commited in r116417 |
---|
63 | patchfiles-append patch-compat-sigaltstack.diff |
---|
64 | |
---|
65 | post-patch { |
---|
66 | reinplace "s|^# VIM_APP_DIR=/Applications$|VIM_APP_DIR=${applications_dir}|" \ |
---|
67 | ${worksrcpath}/src/MacVim/mvim |
---|
68 | } |
---|
69 | |
---|
70 | autoconf.dir ${worksrcpath}/src |
---|
71 | |
---|
72 | configure.args --enable-gui=macvim \ |
---|
73 | --without-x \ |
---|
74 | --disable-gpm \ |
---|
75 | --with-tlib=ncurses \ |
---|
76 | --enable-multibyte \ |
---|
77 | --enable-fail-if-missing |
---|
78 | |
---|
79 | # Old pre-compiled headers could influence build, #26723 |
---|
80 | build.args XCODEFLAGS="CACHE_ROOT=${workpath}/caches" \ |
---|
81 | PYTHON=${prefix}/bin/python2.7 |
---|
82 | |
---|
83 | destroot { |
---|
84 | copy ${worksrcpath}/src/MacVim/build/Release/MacVim.app ${destroot}${applications_dir} |
---|
85 | copy ${worksrcpath}/src/MacVim/mvim ${destroot}${prefix}/bin |
---|
86 | |
---|
87 | # Create MacVim vimdiff, view, ex equivalents |
---|
88 | ln -s mvim ${destroot}${prefix}/bin/mvimdiff |
---|
89 | ln -s mvim ${destroot}${prefix}/bin/mview |
---|
90 | # Link as mvimex as bin/mex conflicts with texlive |
---|
91 | ln -s mvim ${destroot}${prefix}/bin/mvimex |
---|
92 | } |
---|
93 | |
---|
94 | test.run yes |
---|
95 | |
---|
96 | if {![variant_isset big] && ![variant_isset huge]} { |
---|
97 | default_variants +huge |
---|
98 | } |
---|
99 | |
---|
100 | variant big description {Build big feature set} conflicts huge { |
---|
101 | configure.args-append --with-features=big |
---|
102 | } |
---|
103 | variant huge description {Build huge feature set} conflicts big { |
---|
104 | configure.args-append --with-features=huge |
---|
105 | } |
---|
106 | variant xim description {Build with support for X Input Method} { |
---|
107 | configure.args-append --with-xim |
---|
108 | } |
---|
109 | |
---|
110 | variant perl description {Enable Perl scripting} { |
---|
111 | configure.args-append --enable-perlinterp |
---|
112 | depends_lib-append path:bin/perl:perl5 |
---|
113 | } |
---|
114 | |
---|
115 | # Compatibility variants, can be removed after 2015-12-26. See #46338 |
---|
116 | variant python25 requires python27 description {Legacy variant} {} |
---|
117 | variant python31 requires python34 description {Legacy variant} {} |
---|
118 | variant python32 requires python34 description {Legacy variant} {} |
---|
119 | |
---|
120 | variant python26 conflicts python27 description {Enable Python scripting} { |
---|
121 | configure.args-append --enable-pythoninterp --with-python=${prefix}/bin/python2.6 |
---|
122 | patchfiles-append patch-python.diff |
---|
123 | depends_lib-append port:python26 |
---|
124 | |
---|
125 | use_autoconf yes |
---|
126 | } |
---|
127 | variant python27 conflicts python26 description {Enable Python scripting} { |
---|
128 | configure.args-append --enable-pythoninterp --with-python=${prefix}/bin/python2.7 |
---|
129 | patchfiles-append patch-python.diff |
---|
130 | depends_lib-append port:python27 |
---|
131 | |
---|
132 | use_autoconf yes |
---|
133 | } |
---|
134 | variant python33 conflicts python34 python35 description {Enable Python scripting} { |
---|
135 | configure.args-append --enable-python3interp --with-python3=${prefix}/bin/python3.3 |
---|
136 | patchfiles-append patch-python3.diff |
---|
137 | depends_lib-append port:python33 |
---|
138 | |
---|
139 | use_autoconf yes |
---|
140 | # Overwriting autoconf.cmd above removes dependency, add it again |
---|
141 | depends_build-append port:autoconf |
---|
142 | } |
---|
143 | |
---|
144 | variant python34 conflicts python33 python35 description {Enable Python scripting} { |
---|
145 | configure.args-append --enable-python3interp --with-python3=${prefix}/bin/python3.4 |
---|
146 | patchfiles-append patch-python3.diff |
---|
147 | depends_lib-append port:python34 |
---|
148 | |
---|
149 | use_autoconf yes |
---|
150 | # Overwriting autoconf.cmd above removes dependency, add it again |
---|
151 | depends_build-append port:autoconf |
---|
152 | } |
---|
153 | |
---|
154 | variant python35 conflicts python33 python34 description {Enable Python scripting} { |
---|
155 | configure.args-append --enable-python3interp --with-python3=${prefix}/bin/python3.5 |
---|
156 | patchfiles-append patch-python3.diff |
---|
157 | depends_lib-append port:python35 |
---|
158 | |
---|
159 | use_autoconf yes |
---|
160 | # Overwriting autoconf.cmd above removes dependency, add it again |
---|
161 | depends_build-append port:autoconf |
---|
162 | } |
---|
163 | |
---|
164 | variant ruby requires ruby18 description {Compatibility variant, requires +ruby18} {} |
---|
165 | variant ruby18 conflicts ruby19 ruby20 ruby21 ruby22 description {Enable Ruby scripting} { |
---|
166 | configure.args-append --enable-rubyinterp |
---|
167 | configure.args-append --with-ruby-command=${prefix}/bin/ruby1.8 |
---|
168 | depends_lib-append port:ruby |
---|
169 | } |
---|
170 | |
---|
171 | variant ruby19 conflicts ruby18 ruby20 ruby21 ruby22 description {Enable Ruby scripting} { |
---|
172 | configure.args-append --enable-rubyinterp |
---|
173 | configure.args-append --with-ruby-command=${prefix}/bin/ruby1.9 |
---|
174 | patchfiles-append patch-ruby.diff |
---|
175 | depends_lib-append port:ruby19 |
---|
176 | } |
---|
177 | |
---|
178 | variant ruby20 conflicts ruby18 ruby19 ruby21 ruby22 description {Enable Ruby scripting} { |
---|
179 | configure.args-append --enable-rubyinterp |
---|
180 | configure.args-append --with-ruby-command=${prefix}/bin/ruby2.0 |
---|
181 | patchfiles-append patch-ruby.diff |
---|
182 | depends_lib-append port:ruby20 |
---|
183 | } |
---|
184 | |
---|
185 | variant ruby21 conflicts ruby18 ruby19 ruby20 ruby22 description {Enable Ruby scripting} { |
---|
186 | configure.args-append --enable-rubyinterp |
---|
187 | configure.args-append --with-ruby-command=${prefix}/bin/ruby2.1 |
---|
188 | patchfiles-append patch-ruby.diff |
---|
189 | depends_lib-append port:ruby21 |
---|
190 | } |
---|
191 | |
---|
192 | variant ruby22 conflicts ruby18 ruby19 ruby20 ruby21 description {Enable Ruby scripting} { |
---|
193 | configure.args-append --enable-rubyinterp |
---|
194 | configure.args-append --with-ruby-command=${prefix}/bin/ruby2.2 |
---|
195 | patchfiles-append patch-ruby.diff |
---|
196 | depends_lib-append port:ruby22 |
---|
197 | } |
---|
198 | |
---|
199 | variant tcl description {Enable Tcl scripting} { |
---|
200 | configure.args-append --enable-tclinterp \ |
---|
201 | --with-tclsh=${prefix}/bin/tclsh |
---|
202 | patchfiles-append patch-tcl.diff |
---|
203 | depends_lib-append port:tcl |
---|
204 | |
---|
205 | use_autoconf yes |
---|
206 | } |
---|
207 | |
---|
208 | variant lua description {Enable Lua scripting} { |
---|
209 | configure.args-append --enable-luainterp \ |
---|
210 | --with-lua-prefix=${prefix} |
---|
211 | depends_lib-append port:lua |
---|
212 | } |
---|
213 | |
---|
214 | variant cscope description {Enable source code browsing with cscope} { |
---|
215 | configure.args-append --enable-cscope |
---|
216 | } |
---|
217 | |
---|
218 | livecheck.type regex |
---|
219 | livecheck.url https://github.com/macvim-dev/macvim/releases |
---|
220 | livecheck.version ${snapshot} |
---|
221 | livecheck.regex snapshot-(\\d+) |
---|