Opened 20 years ago

Closed 19 years ago

Last modified 9 years ago

#2899 closed enhancement (fixed)

RFE: cmake-2.0.6 syntax files for emacs and vim

Reported by: cssdev@… Owned by: cssdev@…
Priority: Normal Milestone:
Component: ports Version: 1.0
Keywords: Cc:
Port: cmake

Description (last modified by ryandesign (Ryan Carsten Schmidt))

This patch for devel/cmake/Portfile downloads Kitware's CMake emacs and vim syntax files for CMakeLists.txt and *.cmake files. These three files are downloaded from the CMake website, and they are installed into emacs and vim directories during the destroot process. These files are not included with the source, but they are provided directly on the download page. It might be preferrable to add these as a variant, but these three files probably are not significant enough to constitute a full variant. The diff below assumes BUG #2898 resolution, bringing the CMake version to 2.0.6. Should the emacs file be byte-compiled prior to installation?

--- Portfile.206        Thu Apr 14 12:53:19 2005
+++ Portfile    Thu Apr 14 13:40:34 2005
@@ -13,6 +13,32 @@
        used in conjunction with the native build environment.
 homepage       http://www.cmake.org/
 platforms      darwin freebsd
-master_sites   http://www.cmake.org/files/v2.0/
-checksums      md5 840ea86d7f1a56b469052c9cabbeac54
+master_sites   http://www.cmake.org/files/v2.0/:source \
+               http://www.cmake.org/CMakeDocs/:syntax
+
+distfiles      ${name}-${version}.tar.gz:source \
+               ${name}-mode.el:syntax \
+               ${name}-indent.vim:syntax \
+               ${name}-syntax.vim:syntax
+
+extract.only   ${name}-${version}.tar.gz
+
+checksums      ${name}-${version}.tar.gz \
+                       md5 840ea86d7f1a56b469052c9cabbeac54 \
+               ${name}-mode.el md5 9e84a1509d5ea5b0c669e0eb016c9b41 \
+               ${name}-indent.vim md5 9ed4a0a1cec2957f2e839fd4b904d55c \
+               ${name}-syntax.vim md5 7337be86138adee979c0e9df216995cd
+
 configure.args --mandir=/share/man
+
+post-destroot  {
+       xinstall -d -m 0755 ${destroot}${prefix}/share/emacs/site-lisp
+       xinstall -m 0644 ${distpath}/${name}-mode.el \
+               ${destroot}${prefix}/share/emacs/site-lisp
+
+       xinstall -d -m 0755 ${destroot}${prefix}/share/vim/syntax
+       xinstall -m 0644 ${distpath}/${name}-indent.vim \
+               ${destroot}${prefix}/share/vim/syntax
+       xinstall -m 0644 ${distpath}/${name}-syntax.vim \
+               ${destroot}${prefix}/share/vim/syntax
+}

Attachments (1)

patch-Portfile.diff (909 bytes) - added by cssdev@… 19 years ago.
Patch Portfile to copy vim syntax files

Download all attachments as: .zip

Change History (9)

comment:1 Changed 19 years ago by snu@…

Owner: changed from jkh@… to darwinports-bugs@…

Jordan has relinquished maintainership of these ports.

comment:2 Changed 19 years ago by olegb@…

is it a good idea to add this to the port ? It seems that these files could changes without notice and doesn't contain any version information.

DEBUG: Changing to port directory: /Users/olegb/HEAD/dports/devel/cmake
DEBUG: Requested variant powerpc is not provided by port cmake.
DEBUG: Requested variant darwin is not provided by port cmake.
DEBUG: Requested variant macosx is not provided by port cmake.
DEBUG: Skipping completed com.apple.main (cmake)
DEBUG: Skipping completed com.apple.fetch (cmake)
--->  Verifying checksum(s) for cmake
DEBUG: Executing com.apple.checksum (cmake)
--->  Checksumming cmake-2.0.6.tar.gz
DEBUG: Correct (md5) checksum for cmake-2.0.6.tar.gz
--->  Checksumming cmake-mode.el
Error: Checksum (md5) mismatch for cmake-mode.el
Portfile checksum: cmake-mode.el md5 9e84a1509d5ea5b0c669e0eb016c9b41
Distfile checksum: cmake-mode.el md5 b6c87c80c2e015df6ff627b080c0f61b
--->  Checksumming cmake-indent.vim
DEBUG: Correct (md5) checksum for cmake-indent.vim
--->  Checksumming cmake-syntax.vim
DEBUG: Correct (md5) checksum for cmake-syntax.vim
Error: Target com.apple.checksum returned: Unable to verify file checksums
Warning: the following items did not execute (for cmake): com.apple.build com.apple.extract 
com.apple.checksum com.apple.patch com.apple.configure
Last edited 9 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:3 Changed 19 years ago by cssdev@…

I found the syntax files within the downloaded tarball, so #2898 handles installing the emacs syntax file in a cleaner way. While emacs syntax files can be installed into the common ${prefix}/share/emacs/site-lisp directory, there doesn't seem to be a similar common place for dropping third-party vim syntax files. What's the recommend approach for handling them?

Changed 19 years ago by cssdev@…

Attachment: patch-Portfile.diff added

Patch Portfile to copy vim syntax files

comment:4 Changed 19 years ago by cssdev@…

Owner: changed from darwinports-bugs@… to cssdev@…

comment:5 Changed 19 years ago by cssdev@…

Status: newassigned

comment:6 Changed 19 years ago by toby@…

Resolution: fixed
Status: assignedclosed

committed

comment:7 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)
Port: cmake added
Type: defectenhancement

comment:8 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Description: modified (diff)
Note: See TracTickets for help on using tickets.