[75195] trunk/dports/devel/redo/Portfile

singingwolfboy at macports.org singingwolfboy at macports.org
Mon Jan 17 11:37:11 PST 2011


Revision: 75195
          http://trac.macports.org/changeset/75195
Author:   singingwolfboy at macports.org
Date:     2011-01-17 11:36:53 -0800 (Mon, 17 Jan 2011)
Log Message:
-----------
redo: if the user wants the documentation and doesn't have pandoc installed, automatically grab the pregenerated documentation

Modified Paths:
--------------
    trunk/dports/devel/redo/Portfile

Modified: trunk/dports/devel/redo/Portfile
===================================================================
--- trunk/dports/devel/redo/Portfile	2011-01-17 19:36:19 UTC (rev 75194)
+++ trunk/dports/devel/redo/Portfile	2011-01-17 19:36:53 UTC (rev 75195)
@@ -41,7 +41,15 @@
 destroot.env-append     DESTDIR=${destroot} PREFIX=${prefix}
 depends_lib             bin:python:python_select
 variant doc description {Build and install man pages} {
-    depends_build       bin:pandoc:pandoc
+    # The documentation requires pandoc to build...    
+    #depends_build       bin:pandoc:pandoc
+    # ... but if we don't have pandoc already installed, we can just grab
+    # the pregenerated documentation.
+    post-fetch {
+        if {[file isfile "${prefix}/bin/pandoc"] == 0} {
+            system "cd ${worksrcpath} && ${build.cmd} Documentation/git-import"
+        }
+    }
 }
 variant bash_completion {
     depends_run         port:bash-completion
@@ -51,5 +59,4 @@
             ${destroot}${prefix}/etc/bash_completion.d/
     }
 }
-# +doc is not a default_variant because pandoc has a LOT of dependencies
-default_variants        +bash_completion
+default_variants        +doc +bash_completion
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20110117/06caf0a2/attachment.html>


More information about the macports-changes mailing list