source: trunk/dports/devel/jubatus/Portfile

Last change on this file was 138176, checked in by hum@…, 2 years ago

jubatus: update to 0.8.0

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.9 KB
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: Portfile 138176 2015-07-01 11:56:23Z ryandesign@macports.org $
3
4PortSystem          1.0
5PortGroup           github 1.0
6PortGroup           waf 1.0 
7
8github.setup        jubatus jubatus 0.8.0
9
10categories          devel math textproc
11maintainers         hum openmaintainer
12
13description         Distributed Online Machine Learning Framework
14
15long_description    The Jubatus library is a online machine learning framework \
16                    which runs in distributed environment. Jubatus library includes \
17                    these functions: multi-class/binary classification, pre-proccessing \
18                    data (for natural language), and process management.
19
20homepage            http://jubat.us/
21platforms           darwin
22license             {LGPL-2.1 BSD}
23
24checksums           rmd160  d768217d883526ed7781109aeb2b6b040edfb229 \
25                    sha256  a9952174c1cfd4eb2dddab19f3e200b25335fe055f927dfb75dd3854b1a774bd
26
27depends_build-append port:pkgconfig
28
29depends_lib         port:jubatus_core \
30                    port:msgpack \
31                    port:jubatus-mpio \
32                    port:jubatus-msgpack-rpc \
33                    port:log4cxx \
34                    port:mecab-utf8 \
35                    port:ux-trie \
36                    port:libzookeeper
37
38platform darwin {
39    if {${os.major} <= 10} {
40        pre-fetch {
41            ui_error "$name does not build on Snow Leopard or earlier."
42            error "unsupported platform"
43        }
44    } elseif {${os.major} >= 13} {
45        configure.cxxflags-append  "-std=c++11 -DMP_FUNCTIONAL_STANDARD -DMP_MEMORY_STANDARD -DMP_UNORDERED_MAP_STANDARD"
46    }
47}
48
49configure.args-append    --enable-mecab --enable-ux --enable-zookeeper
50
51post-destroot {
52    # fix to install_name for installed libraries.
53    set libdir      ${destroot}${prefix}/lib
54    set plugin_dir  ${libdir}/jubatus/plugin
55    foreach libname [glob -tails -directory ${libdir} *.dylib] {
56        system "install_name_tool -id ${prefix}/lib/${libname} ${libdir}/${libname}"
57    }
58    foreach libname [glob -tails -directory ${plugin_dir} *.dylib] {
59        system "install_name_tool -id ${prefix}/lib/jubatus/plugin/${libname} ${plugin_dir}/${libname}"
60    }
61    set bindir   ${destroot}${prefix}/bin
62    foreach path [concat [glob ${libdir}/*.dylib] [glob ${libdir}/jubatus/plugin/*.dylib] [glob ${bindir}/*]] {
63        set libpathes [regexp -all -inline {\S+\/libjuba\S+dylib \(} [exec otool -L ${path}]]
64        foreach libpath ${libpathes} {
65            regexp {\S+\/(lib[^\/]+dylib)} ${libpath} srcpath libname
66            system "install_name_tool -change ${srcpath} ${prefix}/lib/${libname} ${path}"
67        }
68    }
69    # install additional documents.
70    set doc_dir ${destroot}${prefix}/share/doc/${name}
71    xinstall -d ${doc_dir}
72    xinstall -m 644 -W ${worksrcpath} \
73        CONTRIBUTING.md \
74        ChangeLog.rst \
75        LICENSE \
76        README.rst \
77        ${doc_dir}
78}
Note: See TracBrowser for help on using the repository browser.