[38812] trunk/dports/editors/vim-app
raimue at macports.org
raimue at macports.org
Thu Jul 31 16:12:41 PDT 2008
Revision: 38812
http://trac.macosforge.org/projects/macports/changeset/38812
Author: raimue at macports.org
Date: 2008-07-31 16:12:41 -0700 (Thu, 31 Jul 2008)
Log Message:
-----------
editors/vim-app:
Use ${applications_dir} if available
Modified Paths:
--------------
trunk/dports/editors/vim-app/Portfile
trunk/dports/editors/vim-app/files/gvim.sh
Modified: trunk/dports/editors/vim-app/Portfile
===================================================================
--- trunk/dports/editors/vim-app/Portfile 2008-07-31 23:10:15 UTC (rev 38811)
+++ trunk/dports/editors/vim-app/Portfile 2008-07-31 23:12:41 UTC (rev 38812)
@@ -49,7 +49,10 @@
http://www.douglas.stebila.ca/files/code/vim/app/:app_aqua \
http://www.douglas.stebila.ca/files/code/vim/doc/:doc_aqua
-set appPath "/Applications/MacPorts/"
+# Can be removed once MacPorts 1.7.0 is released
+if {![info exists applications_dir]} {
+ set applications_dir /Applications/MacPorts
+}
depends_build bin:gnutar:gnutar \
bin:grep:grep
@@ -57,7 +60,7 @@
port:libiconv \
port:ctags
-configure.pre_args --prefix=${appPath}
+configure.pre_args --prefix=${applications_dir}
configure.args --enable-gui=carbon \
--without-x \
--disable-gpm \
@@ -85,20 +88,22 @@
test.run yes
+pre-destroot {
+ xinstall -d ${destroot}${applications_dir}
+}
+
destroot {
- # create the required directories
- xinstall -d -m 755 ${destroot}${appPath}
# copy Vim.app
- file copy ${worksrcpath}/src/Vim.app ${destroot}${appPath}
+ file copy ${worksrcpath}/src/Vim.app ${destroot}${applications_dir}
xinstall -m 644 ${filespath}/vimrc ${filespath}/gvimrc \
- ${destroot}${appPath}Vim.app
+ ${destroot}${applications_dir}/Vim.app
xinstall -m 644 ${workpath}/doc-txt.icns \
- ${destroot}${appPath}Vim.app/Contents/Resources
+ ${destroot}${applications_dir}/Vim.app/Contents/Resources
xinstall -m 644 ${workpath}/app.icns \
- ${destroot}${appPath}Vim.app/Contents/Resources/gui_mac.icns
+ ${destroot}${applications_dir}/Vim.app/Contents/Resources/gui_mac.icns
# remove the broken link to 'runtime', copy the folder instead
set runtimePath \
- "${destroot}${appPath}Vim.app/Contents/Resources/vim/runtime"
+ "${destroot}${applications_dir}/Vim.app/Contents/Resources/vim/runtime"
file delete ${runtimePath}
file copy ${worksrcpath}/runtime ${runtimePath}
# fix permissions
@@ -107,10 +112,10 @@
}
# install launchscript
xinstall -m 755 ${filespath}/gvim.sh ${destroot}/${prefix}/bin/gvim
- reinplace "s|@APPPATH@|${appPath}|g" ${destroot}/${prefix}/bin/gvim
+ reinplace "s|@APPPATH@|${applications_dir}|g" ${destroot}/${prefix}/bin/gvim
# allow for Vim.App to open .nfo, .vim, .latex, .tex, .diff files
- system "patch -d ${destroot}${appPath}Vim.app/Contents/ -p0 < ${filespath}/patch-Info.plist"
+ system "patch -d ${destroot}${applications_dir}/Vim.app/Contents/ -p0 < ${filespath}/patch-Info.plist"
}
# general vim variants
@@ -153,8 +158,8 @@
platform darwin ppc {
post-destroot {
- system "gnutar xvfz ${filespath}/GVim_app.tar.gz -C ${destroot}${appPath}"
- xinstall -m 644 ${workpath}/app.icns ${destroot}${appPath}GVim.app/Contents/Resources/appIcon.icns
+ system "gnutar xvfz ${filespath}/GVim_app.tar.gz -C ${destroot}${applications_dir}/"
+ xinstall -m 644 ${workpath}/app.icns ${destroot}${applications_dir}/Vim.app/Contents/Resources/appIcon.icns
}
}
Modified: trunk/dports/editors/vim-app/files/gvim.sh
===================================================================
--- trunk/dports/editors/vim-app/files/gvim.sh 2008-07-31 23:10:15 UTC (rev 38811)
+++ trunk/dports/editors/vim-app/files/gvim.sh 2008-07-31 23:12:41 UTC (rev 38812)
@@ -12,7 +12,7 @@
# or by un-commenting and editing the following line:
# VIM_APP_DIR=/Applications
-binary="@APPPATH at Vim.app/Contents/MacOS/Vim"
+binary="@APPPATH@/Vim.app/Contents/MacOS/Vim"
# Next, peek at the name used to invoke this script, and set options
# accordingly.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/macports-changes/attachments/20080731/a915e18a/attachment.html
More information about the macports-changes
mailing list