24 | | master_sites http://cran.us.r-project.org/src/base/R-2/ \ |
25 | | http://cran.ms.unimelb.edu.au/src/base/R-2/ \ |
26 | | http://cran.at.r-project.org/src/base/R-2/ \ |
27 | | http://cran.hu.r-project.org/src/base/R-2/ \ |
28 | | http://cran.r-project.org/src/base/R-2/ |
29 | | |
30 | | checksums rmd160 d588100f075e3a370a2cd6400e3c61dcc5b7a09e \ |
31 | | sha256 c583a38f8dad3bc012c08116f4ba1eb2182cadfad4b0f8d7bd3cdba24bc255d6 |
32 | | |
33 | | depends_build port:pkgconfig |
34 | | |
35 | | depends_lib port:gettext \ |
36 | | port:icu \ |
37 | | path:lib/pkgconfig/glib-2.0.pc:glib2 \ |
38 | | port:jpeg \ |
39 | | port:libiconv \ |
40 | | path:lib/pkgconfig/cairo.pc:cairo \ |
41 | | path:lib/pkgconfig/pango.pc:pango \ |
42 | | port:readline \ |
43 | | port:tcl \ |
44 | | port:tk \ |
45 | | port:tiff \ |
46 | | port:xorg-libXmu \ |
47 | | port:xorg-libXScrnSaver |
| 27 | master_sites http://cran.us.r-project.org/src/base/R-3/ \ |
| 28 | http://cran.ms.unimelb.edu.au/src/base/R-3/ \ |
| 29 | http://cran.at.r-project.org/src/base/R-3/ \ |
| 30 | http://cran.hu.r-project.org/src/base/R-3/ \ |
| 31 | http://cran.r-project.org/src/base/R-3/ |
66 | | variant gcc45 conflicts gcc43 gcc44 gcc46 gcc47 description {Build with gcc45} { |
67 | | configure.compiler macports-gcc-4.5 |
68 | | depends_lib-append port:gcc45 |
| 50 | configure.pre_args --prefix=${frameworks_dir} |
| 51 | |
| 52 | configure.cflags-append -DOS_OBJECT_USE_OBJC=0 |
| 53 | |
| 54 | configure.args --enable-R-framework \ |
| 55 | --enable-R-shlib \ |
| 56 | --enable-BLAS-shlib \ |
| 57 | --enable-openmp \ |
| 58 | --with-readline \ |
| 59 | --with-aqua \ |
| 60 | --without-tcltk \ |
| 61 | --without-cairo \ |
| 62 | --with-libpng \ |
| 63 | --without-jpeglib \ |
| 64 | --without-recommended-packages \ |
| 65 | --with-ICU \ |
| 66 | --without-x \ |
| 67 | --with-included-gettext |
| 68 | |
| 69 | variant cairo requires x11 description {Use cairo and pango} { |
| 70 | depends_lib-append path:lib/pkgconfig/cairo.pc:cairo \ |
| 71 | path:lib/pkgconfig/pango.pc:pango \ |
| 72 | path:lib/pkgconfig/glib-2.0.pc:glib2 \ |
| 73 | port:freetype \ |
| 74 | port:fontconfig \ |
| 75 | port:gettext |
| 76 | configure.args-delete --without-cairo |
| 77 | configure.args-append --with-cairo |
85 | | variant aqua description {Enable quartz graphics device} { |
86 | | if {${os.platform} == "darwin" && ${os.major} == 10} { |
87 | | # This variant uses a hack in "CFString.h" that does not define the problematic CF_FORMAT_FUNCTION |
88 | | # and CF_FORMAT_ARGUMENT macros if __INTEL_COMPILER is defined. Currently, that is the ONLY place |
89 | | # in the 10.6 SDK where the __INTEL_COMPILER macro is checked, but that may change in the future. |
90 | | # We also need to use Apple's ObjC compiler for the single "qdCocoa.m" file. |
91 | | configure.args-delete --without-aqua |
92 | | configure.args-append --with-aqua |
93 | | patchfiles-append patch-QuartzDevice_h.diff |
94 | | configure.objc /usr/bin/gcc-4.2 |
95 | | } else { |
96 | | ui_error "The +aqua variant is for Snow Leopard (Mac OS X 10.6) only - for Aqua support on Lion (Mac OS X 10.7) use the R-framework port" |
97 | | return -code error "incompatible variant" |
98 | | } |
| 93 | variant gcc45 conflicts gcc46 gcc47 description {build with gcc45} { |
| 94 | depends_lib-append port:gcc45 |
| 95 | configure.compiler macports-gcc-4.5 |
| 96 | configure.objc /usr/bin/gcc |
| 97 | configure.env-append "OBJCXX=/usr/bin/g++" |
| 98 | } |
| 99 | |
| 100 | variant gcc46 conflicts gcc45 gcc47 description {build with gcc46} { |
| 101 | depends_lib-append port:gcc46 |
| 102 | configure.compiler macports-gcc-4.6 |
| 103 | configure.objc /usr/bin/gcc |
| 104 | configure.env-append "OBJCXX=/usr/bin/g++" |
| 105 | } |
| 106 | |
| 107 | variant gcc47 conflicts gcc45 gcc46 description {build with gcc47} { |
| 108 | depends_lib-append port:gcc47 |
| 109 | configure.compiler macports-gcc-4.7 |
| 110 | configure.objc /usr/bin/gcc |
| 111 | configure.env-append "OBJCXX=/usr/bin/g++" |
103 | | if {![variant_isset gcc42] && ![variant_isset gcc43] && ![variant_isset gcc44] && |
104 | | ![variant_isset gcc45] && ![variant_isset gcc46] && ![variant_isset gcc47]} { |
105 | | default_variants-append +gcc47 |
| 119 | variant tcltk requires x11 description {Use tcltk} { |
| 120 | depends_lib-append port:tcl \ |
| 121 | port:tk \ |
| 122 | port:xorg-libXScrnSaver \ |
| 123 | port:xorg-libXext |
| 124 | configure.args-delete --without-tcltk |
| 125 | configure.args-append --with-tcltk \ |
| 126 | --with-tcl-config=${prefix}/lib/tclConfig.sh \ |
| 127 | --with-tk-config=${prefix}/lib/tkConfig.sh |
| 128 | } |
| 129 | |
| 130 | variant x11 description { |
| 131 | depends_lib-append port:xorg-libsm \ |
| 132 | port:xorg-libice \ |
| 133 | port:xorg-libX11 \ |
| 134 | port:xorg-libXt \ |
| 135 | port:tiff \ |
| 136 | port:jpeg \ |
| 137 | port:libpng \ |
| 138 | port:zlib |
| 139 | configure.args-delete --without-x \ |
| 140 | --without-jpeglib |
| 141 | configure.args-append --with-x \ |
| 142 | --with-jpeglib \ |
| 143 | --x-include=${prefix}/include/X11 \ |
| 144 | --x-lib=${prefix}/lib |
133 | | reinplace "s|${dir}=${destroot}|${dir}=|" "${destroot}${prefix}${r}" |
| 167 | reinplace "s|${dir}=${destroot}|${dir}=|" "${destroot}${resources}/bin/R" |
| 168 | } |
| 169 | |
| 170 | reinplace "s|-F${destroot}|-F|" "${destroot}${resources}/etc/Makeconf" |
| 171 | |
| 172 | foreach dylib [ exec find ${destroot}${frameworks_dir}/R.framework -name "\*.dylib" ] { |
| 173 | regsub ":$" ${dylib} "" destroot_dylib_path |
| 174 | regsub ${destroot} ${destroot_dylib_path} "" dylib_path |
| 175 | system "install_name_tool -id ${dylib_path} ${destroot_dylib_path}" |
| 176 | system "install_name_tool -change ${destroot}${resources}/lib/libR.dylib ${resources}/lib/libR.dylib \ |
| 177 | ${destroot_dylib_path}" |
| 178 | system "install_name_tool -change ${destroot}${resources}/lib/libRblas.dylib ${resources}/lib/libRblas.dylib \ |
| 179 | ${destroot_dylib_path}" |
| 180 | system "install_name_tool -change ${destroot}${resources}/lib/libRlapack.dylib ${resources}/lib/libRlapack.dylib \ |
| 181 | ${destroot_dylib_path}" |
| 182 | } |
| 183 | |
| 184 | foreach so [ exec find ${destroot}${frameworks_dir}/R.framework -name "\*.so" ] { |
| 185 | regsub ":$" ${so} "" destroot_so_path |
| 186 | regsub ${destroot} ${destroot_so_path} "" so_path |
| 187 | system "install_name_tool -id ${so_path} ${destroot_so_path}" |
| 188 | system "install_name_tool -change ${destroot}${resources}/lib/libR.dylib ${resources}/lib/libR.dylib \ |
| 189 | ${destroot_so_path}" |
| 190 | system "install_name_tool -change ${destroot}${resources}/lib/libRblas.dylib ${resources}/lib/libRblas.dylib \ |
| 191 | ${destroot_so_path}" |
| 192 | system "install_name_tool -change ${destroot}${resources}/lib/libRlapack.dylib ${resources}/lib/libRlapack.dylib \ |
| 193 | ${destroot_so_path}" |
137 | | foreach v { "rhome" "rincludedir" } { |
138 | | reinplace "s|${v}=${destroot}|${v}=|" "${destroot}${prefix}/lib/pkgconfig/libR.pc" |
139 | | } |
140 | | |
141 | | foreach dylib [ exec find ${destroot}${prefix}/lib/R/lib/${build_arch} -name "\*.dylib" ] { |
142 | | regsub ":$" ${dylib} "" destroot_dylib_path |
143 | | regsub ${destroot} ${destroot_dylib_path} "" dylib_path |
144 | | system "install_name_tool -id ${dylib_path} ${destroot_dylib_path}" |
145 | | system "install_name_tool -change libR.dylib ${prefix}/lib/R/lib/${build_arch}/libR.dylib \ |
146 | | ${destroot_dylib_path}" |
147 | | system "install_name_tool -change libRblas.dylib ${prefix}/lib/R/lib/${build_arch}/libRblas.dylib \ |
148 | | ${destroot_dylib_path}" |
149 | | system "install_name_tool -change libRlapack.dylib ${prefix}/lib/R/lib/${build_arch}/libRlapack.dylib \ |
150 | | ${destroot_dylib_path}" |
151 | | } |
152 | | |
153 | | foreach so [ exec find ${destroot}${prefix}/lib/R -name "\*.so" ] { |
154 | | regsub ":$" ${so} "" destroot_so_path |
155 | | regsub ${destroot} ${destroot_so_path} "" so_path |
156 | | system "install_name_tool -id ${so_path} ${destroot_so_path}" |
157 | | system "install_name_tool -change libR.dylib ${prefix}/lib/R/lib/${build_arch}/libR.dylib \ |
158 | | ${destroot_so_path}" |
159 | | system "install_name_tool -change libRblas.dylib ${prefix}/lib/R/lib/${build_arch}/libRblas.dylib \ |
160 | | ${destroot_so_path}" |
161 | | system "install_name_tool -change libRlapack.dylib ${prefix}/lib/R/lib/${build_arch}/libRlapack.dylib \ |
162 | | ${destroot_so_path}" |
163 | | } |
164 | | |
165 | | system "install_name_tool -change libR.dylib ${prefix}/lib/R/lib/${build_arch}/libR.dylib \ |
166 | | ${destroot}${prefix}/lib/R/bin/exec/${build_arch}/R" |
167 | | system "install_name_tool -change libRblas.dylib ${prefix}/lib/R/lib/${build_arch}/libRblas.dylib \ |
168 | | ${destroot}${prefix}/lib/R/bin/exec/${build_arch}/R" |
| 196 | system "install_name_tool -change ${destroot}${resources}/lib/libR.dylib ${resources}/lib/libR.dylib \ |
| 197 | ${destroot}${resources}/bin/exec/R" |
| 198 | system "install_name_tool -change ${destroot}${resources}/lib/libRblas.dylib ${resources}/lib/libRblas.dylib \ |
| 199 | ${destroot}${resources}/bin/exec/R" |