Ticket #38150: Portfile

File Portfile, 3.1 KB (added by FlorianFranzen@…, 11 years ago)
Line 
1# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
2# $Id$
3PortSystem              1.0
4name                    ndmanager-plugins
5version                 1.4.6
6revision                1
7categories              science
8platforms               darwin
9license                 GPL
10maintainer              gmail.com:FlorianFranzen
11description             A number of scripts and programs to automatically pre-process files recorded with various data acquisition systems.
12long_description        Functions are: file conversion (from vendor-specific, proprietary formats \
13                        to open formats used by e.g. Klusters and NeuroScope), channel resampling \
14                        and reordering, high-pass filtering and spike detection, waveform feature \
15                        extraction (PCA) for subsequent spike sorting, video transcoding and LED \
16                        tracking, etc. The NDManager Plugins are part of a larger data analysis \
17                        framework, see NDManager, Klusters, NeuroScope and FMAToolbox.
18homepage                http://ndmanager.sourceforge.net/
19master_sites            sourceforge:project/ndmanager/${name}/${name}-${version}
20distname                ${name}_${version} 
21worksrcdir              ${name}
22checksums               rmd160 26825396adf799b7555e29488b5c69d2d30bd0ab \
23                        sha256 f4ec4527dc6319a3c88bc7353a08dc4f68be6c39443f8506c0c03d0c941f67fa
24patchfiles              patch-makefile_no-python-plugins.diff \
25                        patch-src-process_extraspikes-strdupa.diff \
26                        patch-src-process_medianthreshold-strdupa.diff \
27                        patch-src-process_pca-makefile.diff \
28                        patch-scripts-colors.diff \
29                        patch-sed.diff
30depends_build           port:docbook-xsl \
31                        port:docbook-xml \
32                        port:libxslt
33# Might also need:      port:argp-standalone
34depends_lib             port:libsdl \
35                        port:libsamplerate \
36                        port:gsl
37configure {
38        ui_warn "In case of failure, make sure your locate database is up to date, i.e. run: sudo /usr/libexec/locate.updatedb"
39        ui_warn "If xslproc throws errors, just rerunning the installation will also help, i.e. run: sudo port install ${name}"
40 
41        # Set install dir correctly
42        system "for file in \$(grep -rl 'INSTALLDIR =' ${worksrcpath}); do \
43                        sed -i '' 's;INSTALLDIR = /usr;INSTALLDIR = ${destroot}${prefix};' \$file; \
44                done"
45
46        # Set man base correctly
47        system "for file in \$(grep -rl 'MAN_BASE =' ${worksrcpath}); do \
48                        sed -i '' 's;MAN_BASE = \$(INSTALLDIR);MAN_BASE = \$(INSTALLDIR)/share;' \$file; \
49                done"     
50        system "for file in \$(grep -rl 'MANBASE =' ${worksrcpath}); do \
51                        sed -i '' 's;MANBASE = \$(INSTALLDIR);MANBASE = \$(INSTALLDIR)/share;' \$file; \
52                done"
53
54        # Set lib dir correctly
55        system "for file in \$(grep -rl 'LIBS' ${worksrcpath}); do \
56                        sed -i '' 's;-L/usr/lib;-L${prefix}/lib;' \$file; \
57                done"
58       
59        # Set incs correctly
60        system "for file in \$(grep -rl 'INCS' ${worksrcpath}); do \
61                        sed -i '' 's;-I/usr/lib;-I${prefix}/include;' \$file; \
62                done"
63       
64        # Remove weird html codes from xml and xsl
65        system "for file in \$(grep -rl ' ' ${worksrcpath}); do \
66                        sed -i '' 's/\\ /\\ /g' \$file; \
67                done"
68           
69        # Removed 'extractled' since it can not be build for x64
70        system "rm -rf ${worksrcpath}/src/process_extractleds"
71
72        ui_warn "The following plugins are unbuildable and were deactivated: process_extractleds, ndm_checkconsistency and ndm_prepare."
73}