source: trunk/dports/editors/MacVim/Portfile @ 103106

Last change on this file since 103106 was 103106, checked in by raimue@…, 7 years ago

editors/vim, editors/vim-app, editors/MacVim:
Remove unnecessary dependency on ctags, see #38044

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 6.5 KB
Line 
1# $Id: Portfile 103106 2013-02-14 13:11:29Z raimue@macports.org $
2
3PortSystem          1.0
4
5name                MacVim
6set vim_version     7.3
7set snapshot        66
8set gitcommit       snapshot-${snapshot}
9version             ${vim_version}.snapshot${snapshot}
10revision            2
11categories          editors
12platforms           darwin
13license             Vim GPL-2+
14maintainers         raimue
15description         MacVim is a GUI version of vim for Mac OS X
16long_description \
17    MacVim is a port of the text editor Vim to Mac OS X that is meant to look \
18    better and integrate more seamlessly with the Mac than vim-app.
19homepage            http://code.google.com/p/macvim
20
21master_sites        http://github.com/b4winckler/macvim/zipball/${gitcommit}
22checksums           rmd160  a5c33364634a349099092cae4b60a115ad94f438 \
23                    sha256  910608b81fbea75495c03472ef2214ed4dd1354279dd7afd9c369a99797332b5
24use_zip             yes
25worksrcdir          ${name}
26
27depends_build       bin:gnutar:gnutar \
28                    bin:grep:grep \
29                    bin:autoconf:autoconf \
30                    port:python27
31depends_lib         port:ncurses \
32                    port:gettext \
33                    port:libiconv
34
35if ![variant_isset python27] {
36    # python is only used for build scripts, no linking
37    license_noconflict  python27
38}
39
40patchfiles          patch-src-MacVim-icons-python.diff \
41                    patch-reverse-7.3.245.diff \
42                    patch-MacVim-GCC-VERSION.diff
43
44pre-fetch {
45    if {${os.platform} == "darwin" && ${os.major} < 10} {
46        ui_error "${name} only runs on Mac OS X 10.6 or greater."
47        return -code error "incompatible Mac OS X version"
48    }
49}
50
51# does not run correctly when build with older clang releases, see #30985
52compiler.blacklist macports-clang-2.9 macports-clang-3.0
53if {[vercmp ${xcodeversion} 4.4] < 0} {
54    compiler.blacklist-append clang
55}
56
57post-extract {
58    # github zipball has root folder including commitish, renaming for ease of use
59    file rename [glob ${workpath}/b4winckler-*] ${worksrcpath}
60
61    # create cache directory
62    file mkdir ${workpath}/caches
63}
64
65post-patch {
66    reinplace "s|^# VIM_APP_DIR=/Applications$|VIM_APP_DIR=${applications_dir}|" \
67         ${worksrcpath}/src/MacVim/mvim
68}
69
70autoconf.dir ${worksrcpath}/src
71
72configure.args      --enable-gui=macvim \
73                    --without-x \
74                    --disable-gpm \
75                    --with-tlib=ncurses \
76                    --enable-multibyte
77
78# Old pre-compiled headers could influence build, #26723
79build.args          XCODEFLAGS="CACHE_ROOT=${workpath}/caches" \
80                    PYTHON=${prefix}/bin/python2.7
81
82destroot {
83    copy ${worksrcpath}/src/MacVim/build/Release/MacVim.app ${destroot}${applications_dir}
84    copy ${worksrcpath}/src/MacVim/mvim ${destroot}${prefix}/bin
85
86    # Create MacVim vimdiff, view, ex equivalents
87    ln -s mvim ${destroot}${prefix}/bin/mvimdiff
88    ln -s mvim ${destroot}${prefix}/bin/mview
89    # Link as mvimex as bin/mex conflicts with texlive
90    ln -s mvim ${destroot}${prefix}/bin/mvimex
91}
92
93test.run            yes
94
95if {![variant_isset big] && ![variant_isset huge]} {
96    default_variants +huge
97}
98
99variant big description {Build big feature set} conflicts huge {
100    configure.args-append --with-features=big
101}
102variant huge description {Build huge feature set} conflicts big {
103    configure.args-append --with-features=huge
104}
105variant xim description {Build with support for X Input Method} {
106    configure.args-append --with-xim
107}
108
109variant perl description {Enable Perl scripting} {
110    configure.args-append   --enable-perlinterp
111    depends_lib-append      path:bin/perl:perl5
112}
113variant python requires python25 description {Compatibility variant, requires +python25} {}
114variant python25 conflicts python26 python27 description {Enable Python scripting} {
115    configure.args-append   --enable-pythoninterp --with-python=${prefix}/bin/python2.5
116    patchfiles-append       patch-python.diff
117    depends_lib-append      port:python25
118
119    use_autoconf yes
120}
121variant python26 conflicts python25 python27 description {Enable Python scripting} {
122    configure.args-append   --enable-pythoninterp --with-python=${prefix}/bin/python2.6
123    patchfiles-append       patch-python.diff
124    depends_lib-append      port:python26
125
126    use_autoconf yes
127}
128variant python27 conflicts python25 python26 description {Enable Python scripting} {
129    configure.args-append   --enable-pythoninterp --with-python=${prefix}/bin/python2.7
130    patchfiles-append       patch-python.diff
131    depends_lib-append      port:python27
132
133    use_autoconf yes
134}
135variant python31 conflicts python32 python33 description {Enable Python scripting} {
136    configure.args-append   --enable-python3interp --with-python3=${prefix}/bin/python3.1
137    patchfiles-append       patch-python3.diff
138    depends_lib-append      port:python31
139
140    use_autoconf yes
141}
142variant python32 conflicts python31 python33 description {Enable Python scripting} {
143    configure.args-append   --enable-python3interp --with-python3=${prefix}/bin/python3.2
144    patchfiles-append       patch-python3.diff
145    depends_lib-append      port:python32
146
147    use_autoconf yes
148    # Overwriting autoconf.cmd above removes dependency, add it again
149    depends_build-append port:autoconf
150}
151variant python33 conflicts python31 python32 description {Enable Python scripting} {
152    configure.args-append   --enable-python3interp --with-python3=${prefix}/bin/python3.3
153    patchfiles-append       patch-python3.diff
154    depends_lib-append      port:python33
155
156    use_autoconf yes
157    # Overwriting autoconf.cmd above removes dependency, add it again
158    depends_build-append port:autoconf
159}
160variant ruby conflicts ruby19 description {Enable Ruby scripting} {
161    configure.args-append   --enable-rubyinterp
162    configure.args-append   --with-ruby-command=${prefix}/bin/ruby
163    depends_lib-append      port:ruby
164}
165variant ruby19 conflicts ruby description {Enable Ruby scripting} {
166    configure.args-append   --enable-rubyinterp
167    configure.args-append   --with-ruby-command=${prefix}/bin/ruby1.9
168    depends_lib-append      port:ruby19
169}
170variant tcl description {Enable Tcl scripting} {
171    configure.args-append   --enable-tclinterp
172    patchfiles-append       patch-tcl.diff
173    depends_lib-append      port:tcl
174
175    use_autoconf yes
176}
177
178variant cscope description {Enable source code browsing with cscope} {
179    configure.args-append   --enable-cscope
180}
181
182livecheck.type          regex
183livecheck.url           http://github.com/b4winckler/macvim/downloads
184livecheck.version       ${snapshot}
185livecheck.regex         snapshot-(\\d+)
Note: See TracBrowser for help on using the repository browser.