source: trunk/dports/kde/rkward/Portfile @ 119488

Last change on this file since 119488 was 119488, checked in by mk@…, 5 years ago

rkward: new ports for RKWard (ticket #32837)

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 3.7 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 119488 2014-04-27 10:20:14Z mk@macports.org $
3
4PortSystem          1.0
5fetch.type          svn
6svn.url             http://svn.code.sf.net/p/rkward/code/branches/release_branches/rkward_0.6.1
7svn.revision        4635
8worksrcdir          ${workpath}/rkward_0.6.1
9
10name                rkward
11conflicts           rkward-devel
12version             0.6.1
13categories          kde kde4 math science
14maintainers         hhu.de:meik.michalke
15license             GPL-2
16platforms           darwin
17
18description         KDE frontend to the R statistics language
19
20long_description    RKWard aims to become an easy to use, transparent frontend to R, a powerful system \
21                    for statistical computation and graphics. Besides a convenient GUI for the most important \
22                    statistical functions, future versions will also provide seamless integration with an office-suite.
23
24homepage            http://rkward.sourceforge.net
25
26master_sites        https://sourceforge.net/projects/rkward/files/Current_Stable_Releases
27
28PortGroup           cmake 1.0
29
30depends_lib         port:kdelibs4 \
31                    port:kate \
32                    port:R
33
34# add port:okular once the graphics device is fully functional
35# this needs port:poppler with +qt4 +quartz varaints which cannot be
36# specified with depends_lib-append
37variant okular description {Add okular for nice PDF handling} {
38        depends_lib-append port:okular
39}
40
41if {${configure.compiler} == "clang"} {
42        # force the use of gcc 4.7 to be able to link with R-framework
43        depends_lib-append   port:gcc47
44        configure.compiler   macports-gcc-4.7
45        configure.objc       /usr/bin/gcc
46        configure.env-append "OBJCXX=${configure.objc}"
47}
48
49post-extract {
50        # creates the build dir if it doesn't exist
51        # this won't return errors if directory is already there
52        file mkdir ${worksrcdir}/build
53}
54
55configure.dir       ${worksrcdir}/build
56configure.args-append \
57        -DNO_R_XML=1 \
58        -DRKVERSION_NUMBER=${version} \
59        -DBUNDLE_INSTALL_DIR=${applications_dir} \
60        -DR_EXECUTABLE=${prefix}/Library/Frameworks/R.framework/Resources/R
61# work around moved Qt include dir
62if { ![file exists ${prefix}/include/Qt/qglobal.h] && [file exists ${prefix}/include/QtCore/qglobal.h] } {
63        configure.args-append -DQT_QT_INCLUDE_DIR=${prefix}/include/QtCore
64}
65configure.cmd       cmake ..
66
67# configure R to use Mac binaries by default
68# you must first install the OS X packages of CRAN R, as we'll link against them
69subport rkward-binary {
70        conflicts-append rkward rkward-devel-binary rkward-devel-debug rkward-debug
71        depends_lib-delete   port:gcc47 port:R
72        configure.compiler   llvm-gcc-4.2
73        configure.args-delete \
74               -DR_EXECUTABLE=${prefix}/Library/Frameworks/R.framework/Resources/R
75        configure.args-append \
76               -DUSE_BINARY_PACKAGES=1 \
77               -DR_EXECUTABLE=/Library/Frameworks/R.framework/Resources/R \
78               -DR_LIBDIR=${prefix}/Library/Frameworks/R.framework/Resources/library
79        # create libdir if it doesn't exist
80        file mkdir ${prefix}/Library/Frameworks/R.framework/Resources/library
81}
82
83# compile with full debugging support
84subport rkward-debug {
85        conflicts-append rkward rkward-devel-binary rkward-devel-debug rkward-binary
86        depends_lib-append port:valgrind
87        configure.args-append -DCMAKE_BUILD_TYPE=debugfull
88}
89
90build.dir           ${worksrcdir}/build
91
92pre-pkg {
93        file copy -force -- ${worksrcdir}/macports/postinstall ${package.scripts}/postinstall
94        file attributes ${package.scripts}/postinstall -permissions 0755
95}
Note: See TracBrowser for help on using the repository browser.