[105204] trunk/dports/lang

takeshi at macports.org takeshi at macports.org
Fri Apr 12 20:16:13 PDT 2013


Revision: 105204
          https://trac.macports.org/changeset/105204
Author:   takeshi at macports.org
Date:     2013-04-12 20:16:13 -0700 (Fri, 12 Apr 2013)
Log Message:
-----------
dmd, druntime, phobos, dmd-tools: revamped for 2.062, added livecheck
dmd-tools: use PortGroup github
dmd-doc: added to provide HTML files for dman in dmd-tools

Modified Paths:
--------------
    trunk/dports/lang/dmd/Portfile
    trunk/dports/lang/dmd-tools/Portfile
    trunk/dports/lang/dmd-tools/files/patch-findtags.d.diff
    trunk/dports/lang/druntime/Portfile
    trunk/dports/lang/phobos/Portfile

Added Paths:
-----------
    trunk/dports/lang/dmd-doc/
    trunk/dports/lang/dmd-doc/Portfile

Removed Paths:
-------------
    trunk/dports/lang/dmd/files/

Modified: trunk/dports/lang/dmd/Portfile
===================================================================
--- trunk/dports/lang/dmd/Portfile	2013-04-13 03:14:46 UTC (rev 105203)
+++ trunk/dports/lang/dmd/Portfile	2013-04-13 03:16:13 UTC (rev 105204)
@@ -4,8 +4,7 @@
 PortSystem          1.0
 PortGroup           github 1.0
 
-github.setup        D-Programming-Language dmd 2.060 v
-revision            1
+github.setup        D-Programming-Language dmd 2.062 v
 categories          lang
 platforms           darwin
 supported_archs     i386 x86_64
@@ -17,12 +16,10 @@
     It pragmatically combines efficiency, control, \
     and modeling power, with safety and programmer productivity.
 homepage            http://dlang.org/
-checksums           rmd160  80eaa1e9b56c1873f3fedc06f4d4218ce9a327fe \
-                    sha256  f1bad058aefda510f4d799767444df89af2a09bbe87e2fed2bcac967f959cb00
+checksums           rmd160  82210bd25623897f38ce540ba85b82343a5b5ee0 \
+                    sha256  9fbaf2b633605a5c7d2e0cd197bf92fd7b67a03a91fcf8c9dda3fcb8103058bc
 
-patchfiles          patch-src-root-port.c.diff
 post-patch {
-    reinplace "s|gcc|${configure.cc}|" ${worksrcpath}/src/posix.mak
     reinplace "s|gcc|${configure.cc}|" ${worksrcpath}/src/link.c
     reinplace "s|-m\$(MODEL)||" ${worksrcpath}/src/posix.mak
     reinplace "s|/etc|${prefix}/etc/${name}|" ${worksrcpath}/src/inifile.c
@@ -33,18 +30,23 @@
 use_configure       no
 
 configure.cppflags-append \
-                    -Wno-deprecated -Wstrict-aliasing
+                    -Wno-deprecated \
+                    -Wstrict-aliasing \
+                    -Iroot \
+                    -D__pascal= \
+                    -DMARS=1 \
+                    -DTARGET_OSX=1 \
+                    -DDM_TARGET_CPU_X86=1
 configure.cxxflags-append \
-                    -Iroot -fno-exceptions -x c++\
-                    -D__pascal= -DMARS=1 -DTARGET_OSX=1
+                    -fno-exceptions -x c++
 
 build.dir           ${worksrcpath}/src
 
 build.args          -f posix.mak \
                     HOST_CC=${configure.cxx} \
                     CC=\"${configure.cxx}\" \
-                    CFLAGS=\"${configure.cxxflags}\" \
-                    MFLAGS=\"${configure.cxxflags} -Ibackend -Itk\" \
+                    CFLAGS=\"${configure.cppflags} ${configure.cxxflags}\" \
+                    MFLAGS=\"${configure.cppflags} -Ibackend -Itk ${configure.cxxflags}\" \
                     LDFLAGS=\"${configure.ldflags} -lstdc++ -framework CoreServices\" \
                     ENVP=\"MACOSX_DEPLOYMENT_TARGET=${macosx_deployment_target}\"
 
@@ -74,3 +76,6 @@
     In order to have a complete dmd runtime environment consider installing the following ports:
     druntime phobos dmd-tools }
 
+livecheck.type      regex
+livecheck.url       ${homepage}download.html
+livecheck.regex     {\.([0-9]+\.[0-9]+)\.zip}

Added: trunk/dports/lang/dmd-doc/Portfile
===================================================================
--- trunk/dports/lang/dmd-doc/Portfile	                        (rev 0)
+++ trunk/dports/lang/dmd-doc/Portfile	2013-04-13 03:16:13 UTC (rev 105204)
@@ -0,0 +1,64 @@
+# -*- 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
+# $Id: Portfile 97636 2012-09-10 13:00:36Z takeshi at macports.org $
+
+PortSystem          1.0
+PortGroup           github 1.0
+
+set realname        d-programming-language.org
+github.setup        D-Programming-Language ${realname} 2.062 v
+name                dmd-doc
+categories          lang
+platforms           darwin
+license             DMD
+maintainers         takeshi openmaintainer
+description         HTML files for dman of the D programming language compiler
+long_description \
+    D is a language with C-like syntax and static typing. \
+    It pragmatically combines efficiency, control, \
+    and modeling power, with safety and programmer productivity. \
+    This port provides the html files required to build the dman command of \
+    the D programming language compiler.
+homepage            http://dlang.org/
+checksums           rmd160  9bafeb9c63f0555ac215127745b5248da8d02c69 \
+                    sha256  6f296e11f5b612eaf7e2ccf9a07df9e076b7ae74eebbf162a8b9cab2af1d9ba0
+
+depends_lib         port:phobos
+
+use_configure       no
+
+if {${build_arch}=="x86_64"} {
+    set model 64
+} else {
+    set model 32
+}
+
+set dmd ${prefix}/bin/dmd
+set dflags "-O -d"
+set ddocflags " -c -o- -Df"
+set ddoc "macros.ddoc doc.ddoc"
+set stddoc "std.ddoc"
+set stddocflags "-m${model} -d -c -o- -version=StdDoc"
+build {
+   file mkdir ${worksrcpath}/dmd
+    system "
+        cd ${worksrcpath};
+        ${dmd} ${ddocflags}dmd/expression.html ${ddoc} expression.dd;
+        ${dmd} ${ddocflags}dmd/statement.html ${ddoc} statement.dd 
+    "
+    foreach f [glob ${prefix}/include/phobos/std/*.d] {
+        set html std_[file rootname [file tail ${f}]].html
+        system "
+            cd ${worksrcpath};
+            ${dmd} ${stddocflags} ${stddoc} -Dfdmd/${html} ${f}
+        "
+    }
+}
+
+destroot {
+    xinstall -d -m 755 ${destroot}${prefix}/share/doc
+    file copy ${worksrcpath}/dmd ${destroot}${prefix}/share/doc
+}
+
+livecheck.type      regex
+livecheck.url       ${homepage}download.html
+livecheck.regex     {\.([0-9]+\.[0-9]+)\.zip}

Modified: trunk/dports/lang/dmd-tools/Portfile
===================================================================
--- trunk/dports/lang/dmd-tools/Portfile	2013-04-13 03:14:46 UTC (rev 105203)
+++ trunk/dports/lang/dmd-tools/Portfile	2013-04-13 03:16:13 UTC (rev 105204)
@@ -2,10 +2,11 @@
 # $Id$
 
 PortSystem          1.0
+PortGroup           github 1.0
 
 set realname        tools
+github.setup        D-Programming-Language ${realname} 2.062 v
 name                dmd-${realname}
-version             2.060
 categories          lang
 platforms           darwin
 license             DMD
@@ -19,24 +20,11 @@
 homepage            http://dlang.org/
 set dlang           D-Programming-Language
 set site            d-programming-language.org
-master_sites        https://github.com/${dlang}/${realname}/tarball/v${version}:src \
-                    https://github.com/${dlang}/${site}/tarball/v${version}:doc
-set dbranch-src     f07897
-set dbranch-doc     221d4e
-distname            ${dlang}-${realname}-v${version}-0-g${dbranch-src}
-set src             ${distname}${extract.suffix}
-set doc             ${dlang}-${site}-v${version}-0-g${dbranch-doc}${extract.suffix}
-distfiles           ${src}:src \
-                    ${doc}:doc
-checksums           ${src} \
-                    rmd160  cfb17f072f9ca8315b7196b10fdcaab2fa476fec \
-                    sha256  1aa8d01744de36f74a7979669364fa783cd9c7de5e7b4d8985e5d6c38061973f \
-                    ${doc} \
-                    rmd160  d0ac82cad995374fa7bbb5a2b8583144cc2092dd \
-                    sha256  71698d61c65249fde449c5ddc3f85ebd40cde7a8b1568b350760e1a7f7317694
+checksums           rmd160  ab1a218d2624a1d364fff91fc02eac529a4e6947 \
+                    sha256  1d9c208664f71b07c2a2866daca021ed9df002642a3232ff2216f2f61209fe78
 
 depends_lib         port:phobos
-worksrcdir          ${dlang}-${realname}-d92f5a7/
+depends_build       port:dmd-doc
 
 patchfiles          patch-findtags.d.diff
 
@@ -45,19 +33,34 @@
 set bin "catdoc ddemangle detab findtags rdmd tolf"
 set dmd ${prefix}/bin/dmd
 set dflags "-O -d"
-set ddocflags " -c -o- -Df"
-set ddoc "macros.ddoc doc.ddoc"
+
+if {${build_arch}=="x86_64"} {
+    set model 64
+} else {
+    set model 32
+}
+
+build.args          -f posix.mak \
+                    CC=${configure.cc} \
+                    DFLAGS=${dflags} \
+                    DMD=${dmd} \
+                    MODEL=${model}
 build {
-    system "mv ${workpath}/${dlang}-${site}-* ${workpath}/doc; 
-        cd ${workpath}/doc;
-        ${dmd} ${ddocflags}expression.html ${ddoc} expression.dd
-        ${dmd} ${ddocflags}statement.html ${ddoc} statement.dd
+    system "
         cd ${worksrcpath};
         for f in ${bin}; do
             ${dmd} ${dflags} \$f.d
         done
-        ./findtags ../doc/expression.html > expression.tag
-        ./findtags ../doc/statement.html > statement.tag
+    "
+    foreach f [glob ${prefix}/share/doc/dmd/*.html] {
+        set tag [file rootname [file tail ${f}]].tag
+        system "
+            cd ${worksrcpath};
+            ./findtags ${f} > ${tag}
+        "
+    }
+    system "
+        cd ${worksrcpath};
         ${dmd} ${dflags} -J. dman.d
     "
 }
@@ -68,3 +71,7 @@
             ${destroot}${prefix}/bin
     }
 }
+
+livecheck.type      regex
+livecheck.url       ${homepage}download.html
+livecheck.regex     {\.([0-9]+\.[0-9]+)\.zip}

Modified: trunk/dports/lang/dmd-tools/files/patch-findtags.d.diff
===================================================================
--- trunk/dports/lang/dmd-tools/files/patch-findtags.d.diff	2013-04-13 03:14:46 UTC (rev 105203)
+++ trunk/dports/lang/dmd-tools/files/patch-findtags.d.diff	2013-04-13 03:16:13 UTC (rev 105204)
@@ -1,10 +1,10 @@
---- findtags.d.orig	2012-07-25 03:07:26.000000000 +0900
-+++ findtags.d	2012-09-10 21:44:57.000000000 +0900
-@@ -18,7 +18,7 @@
+--- findtags.d.orig	2012-11-12 19:13:11.000000000 +0900
++++ findtags.d	2013-04-07 15:19:06.000000000 +0900
+@@ -19,7 +19,7 @@
  
      writeln("[");
  
--    foreach (line; File(args[1]).byLine(std.stdio.File.KeepTerminator.no, '<'))
+-    foreach (line; File(args[1]).byLine(std.string.KeepTerminator.no, '<'))
 +    foreach (line; File(args[1]).byLine(KeepTerminator.no, '<'))
      {
          if (!line.skipOver(`a name="`))

Modified: trunk/dports/lang/druntime/Portfile
===================================================================
--- trunk/dports/lang/druntime/Portfile	2013-04-13 03:14:46 UTC (rev 105203)
+++ trunk/dports/lang/druntime/Portfile	2013-04-13 03:16:13 UTC (rev 105204)
@@ -4,7 +4,7 @@
 PortSystem          1.0
 PortGroup           github 1.0
 
-github.setup        D-Programming-Language druntime 2.060 v
+github.setup        D-Programming-Language druntime 2.062 v
 categories          lang
 platforms           darwin
 license             Boost-1
@@ -17,8 +17,8 @@
     startup/shutdown, etc.
 homepage            http://dlang.org/
 
-checksums           rmd160  8ef088b1b7d5c3151962d01bf0005bb8e3b2db4a \
-                    sha256  e66c2908e9415e8ef882f63bfe525b8e1e88331e0ba16fc4b18e23c4d176cc95 \
+checksums           rmd160  786d19d0f04ea7ae83b311f548d7d8c17088a8a8 \
+                    sha256  9b40d095d178a7204ea4c969d8fc001a87c703f595500b0e54afc42af5275e12
 
 depends_lib         port:dmd
 
@@ -40,8 +40,10 @@
 destroot {
     xinstall -m 644 ${worksrcpath}/lib/libdruntime-osx${model}.a \
         ${destroot}${prefix}/lib/libdruntime.a
-    xinstall -m 755 -d ${destroot}${prefix}/include/${name}
-    system "cd ${worksrcpath};
-        cp -r import/* ${destroot}${prefix}/include/${name}
-    "
+    xinstall -m 755 -d ${destroot}${prefix}/include
+    file copy ${worksrcpath}/import ${destroot}${prefix}/include/${name}
 }
+
+livecheck.type      regex
+livecheck.url       ${homepage}download.html
+livecheck.regex     {\.([0-9]+\.[0-9]+)\.zip}

Modified: trunk/dports/lang/phobos/Portfile
===================================================================
--- trunk/dports/lang/phobos/Portfile	2013-04-13 03:14:46 UTC (rev 105203)
+++ trunk/dports/lang/phobos/Portfile	2013-04-13 03:16:13 UTC (rev 105204)
@@ -4,7 +4,7 @@
 PortSystem          1.0
 PortGroup           github 1.0
 
-github.setup        D-Programming-Language phobos 2.060 v
+github.setup        D-Programming-Language phobos 2.062 v
 categories          lang
 platforms           darwin
 license             Boost-1
@@ -14,8 +14,8 @@
     Phobos is the standard runtime library that comes with the D language compiler.
 homepage            http://dlang.org/
 
-checksums           rmd160  8cd11c9fe523fa41eb8b1c644b18a18750ef81d1 \
-                    sha256  cc1909b4dcbea0b5536d2f3eeb975a3b314e67609d2215c5426d65e64b19360b
+checksums           rmd160  8b1654a4d86c1f107be7d907b2946526457a6335 \
+                    sha256  f48336cefb9118cae0a089cf96ed4f0a7bc6dfaeebe4fe880c65cacfcb244b4e
 
 depends_lib         port:druntime
 
@@ -33,14 +33,13 @@
 }
 
 build.args          -f posix.mak \
-                    DRUNTIME_PATH=${prefix}/include/druntime \
                     DRUNTIME=${prefix}/lib/libdruntime.a \
                     CC=${configure.cc} \
-                    CFLAGS="${configure.cflags} [get_canonical_archflags cc]"\
+                    CFLAGS="${configure.cflags} [get_canonical_archflags cc]" \
                     DMD=${prefix}/bin/dmd \
-                    MODEL=${model} \
-                    BUILD=release
-build.target
+                    DFLAGS="-w -d -property -m${model} -O -release" \
+                    MODEL=${model}
+build.target        ""
 
 destroot {
     xinstall -m 755 -d ${destroot}${prefix}/lib
@@ -51,12 +50,10 @@
     foreach f [glob ${worksrcpath}/*.d] {
         xinstall -m 644 ${f} ${destroot}${prefix}/include/${name}
     }
-    xinstall -d -m 755 ${destroot}${prefix}/include/${name}/etc
-    xinstall -d -m 755 ${destroot}${prefix}/include/${name}/etc/c
-    foreach f [glob ${worksrcpath}/etc/c/*.d] {
-        xinstall -m 644 ${f} ${destroot}${prefix}/include/${name}/etc/c
-    }
-    system "cd ${worksrcpath}; \
-        cp -r std ${destroot}${prefix}/include/${name}
-    "
+    file copy ${worksrcpath}/etc ${destroot}${prefix}/include/${name}
+    file copy ${worksrcpath}/std ${destroot}${prefix}/include/${name}
 }
+
+livecheck.type      regex
+livecheck.url       ${homepage}download.html
+livecheck.regex     {\.([0-9]+\.[0-9]+)\.zip}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130412/302abfed/attachment.html>


More information about the macports-changes mailing list