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$ |
---|
3 | |
---|
4 | PortSystem 1.0 |
---|
5 | |
---|
6 | name mahout |
---|
7 | version 0.4 |
---|
8 | |
---|
9 | categories java science |
---|
10 | platforms darwin |
---|
11 | maintainers gamil.com:hiroshi.umemoto openmaintainer |
---|
12 | license Apache-2.0 |
---|
13 | |
---|
14 | description \ |
---|
15 | A scalable machine learning library that supports large data sets |
---|
16 | |
---|
17 | long_description \ |
---|
18 | Mahout is a scalable machine learning library that implements many \ |
---|
19 | different approaches to machine learning. \ |
---|
20 | The project currently contains implementations of algorithms for \ |
---|
21 | classification, clustering, genetic programming and collaborative \ |
---|
22 | filtering, all enabled to scale by leveraging the power of Hadoop's \ |
---|
23 | Map-Reduce (http://hadoop.apache.org) implementation. |
---|
24 | |
---|
25 | homepage http://mahout.apache.org/ |
---|
26 | master_sites apache:${name}/${version} |
---|
27 | |
---|
28 | distname ${name}-distribution-${version} |
---|
29 | |
---|
30 | checksums sha1 d90ae5387d36defb78fc1d22719a80018ac5030a \ |
---|
31 | rmd160 3831ce991cf17d0c08524bd4a504948e86f1d21d |
---|
32 | |
---|
33 | use_bzip2 yes |
---|
34 | |
---|
35 | depends_lib port:hadoop |
---|
36 | |
---|
37 | use_configure no |
---|
38 | supported_archs noarch |
---|
39 | |
---|
40 | build {} |
---|
41 | |
---|
42 | set mahout_home ${prefix}/share/java/${distname} |
---|
43 | set mahout_log_dir ${prefix}/var/hadoop/log |
---|
44 | |
---|
45 | destroot { |
---|
46 | # Copy the distribution to Mahout home directory. |
---|
47 | xinstall -m 755 -d ${destroot}${prefix}/share/java |
---|
48 | copy ${worksrcpath} ${destroot}${prefix}/share/java/ |
---|
49 | |
---|
50 | # Read the configuration of Hadoop from 'hadoop-bin'. |
---|
51 | set f [open ${prefix}/bin/hadoop-bin] |
---|
52 | set string [read $f] |
---|
53 | close $f |
---|
54 | regexp {JAVA_HOME=(\S+)} $string m java_home |
---|
55 | regexp {HADOOP_HOME=(\S+)} $string m hadoop_home |
---|
56 | regexp {sudo -E -u (\S+)} $string m hadoopuser |
---|
57 | |
---|
58 | # Install an extra script for this port. |
---|
59 | set mahout_bin ${destroot}${prefix}/bin/mahout-bin |
---|
60 | xinstall -m 755 ${filespath}/mahout-bin ${mahout_bin} |
---|
61 | reinplace "s|@java_home@|${java_home}|g" ${mahout_bin} |
---|
62 | reinplace "s|@hadoop_home@|${hadoop_home}|g" ${mahout_bin} |
---|
63 | reinplace "s|@mahout_home@|${mahout_home}|g" ${mahout_bin} |
---|
64 | reinplace "s|@mahout_log_dir@|${mahout_log_dir}|g" ${mahout_bin} |
---|
65 | reinplace "s|@hadoopuser@|${hadoopuser}|g" ${mahout_bin} |
---|
66 | } |
---|
67 | |
---|
68 | livecheck.type regex |
---|
69 | livecheck.url ${homepage} |
---|
70 | livecheck.regex Latest release version: Mahout (\[0-9.\]+) |
---|